vendor: 9,612 bytes, line 1
1if(function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){"use strict";var n=[],r=e.document,o=Object.getPrototypeOf,i=n.slice,a=n.concat,s=n.push,u=n.indexOf,c={},l=c.toString,f=c.hasOwnProperty,d=f.toString,h=d.call(Object),p={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},g=function(e){return null!=e&&e===e.window},v={type:!0,src:!0,noModule:!0};function y(e,t,n){var o,i=(t=t||r).createElement("script");if(i.text=e,n)for(o in v)n[o]&&(i[o]=n[o]);t.head.appendChild(i).parentNode.removeChild(i)}function b(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?c[l.call(e)]||"object":typeof e}var w=function(e,t){return new w.fn.init(e,t)},x=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function C(e){var t=!!e&&"length"in e&&e.length,n=b(e);return!m(e)&&!g(e)&&("array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e)}w.fn=w.prototype={jquery:"3.3.1",constructor:w,length:0,toArray:function(){return i.call(this)},get:function(e){return null==e?i.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=w.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return w.each(this,e)},map:function(e){return this.pushStack(w.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(i.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:s,sort:n.sort,splice:n.splice},w.extend=w.fn.extend=function(){var e,t,n,r,o,i,a=arguments[0]||{},s=1,u=arguments.length,c=!1;for("boolean"==typeof a&&(c=a,a=arguments[s]||{},s++),"object"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)n=a[t],a!==(r=e[t])&&(c&&r&&(w.isPlainObject(r)||(o=Array.isArray(r)))?(o?(o=!1,i=n&&Array.isArray(n)?n:[]):i=n&&w.isPlainObject(n)?n:{},a[t]=w.extend(c,i,r)):void 0!==r&&(a[t]=r));return a},w.extend({expando:"jQuery"+("3.3.1"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==l.call(e)||(t=o(e))&&("function"!=typeof(n=f.call(t,"constructor")&&t.constructor)||d.call(n)!==h))},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e){y(e)},each:function(e,t){var n,r=0;if(C(e))for(n=e.length;r<n&&!1!==t.call(e[r],r,e[r]);r++);else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},trim:function(e){return null==e?"":(e+"").replace(x,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(C(Object(e))?w.merge(n,"string"==typeof e?[e]:e):s.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:u.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,o=e.length;r<n;r++)e[o++]=t[r];return e.length=o,e},grep:function(e,t,n){for(var r=[],o=0,i=e.length,a=!n;o<i;o++)!t(e[o],o)!==a&&r.push(e[o]);return r},map:function(e,t,n){var r,o,i=0,s=[];if(C(e))for(r=e.length;i<r;i++)null!=(o=t(e[i],i,n))&&s.push(o);else for(i in e)null!=(o=t(e[i],i,n))&&s.push(o);return a.apply([],s)},guid:1,support:p}),"function"==typeof Symbol&&(w.fn[Symbol.iterator]=n[Symbol.iterator]),w.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){c["[object "+t+"]"]=t.toLowerCase()});var S=function(e){var t,n,r,o,i,a,s,u,c,l,f,d,h,p,m,g,v,y,b,w="sizzle"+1*new Date,x=e.document,C=0,S=0,T=ae(),E=ae(),k=ae(),N=function(e,t){return e===t&&(f=!0),0},R={}.hasOwnProperty,_=[],A=_.pop,D=_.push,O=_.push,P=_.slice,B=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},I="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",H="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+M+"))|)"+L+"*\\]",F=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+H+")*)|.*)\\)|)",W=new RegExp(L+"+","g"),j=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),$=new RegExp("^"+L+"*,"+L+"*"),z=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),q=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(F),V=new RegExp("^"+M+"$"),X={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+H),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+I+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,K=/^h\d$/i,G=/^[^{]+\{\s*\[native \w/,J=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Q=/[+~]/,Z=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ee=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)},te=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ne=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},re=function(){d()},oe=ye(function(e){return!0===e.disabled&&("form"in e||"label"in e)},{dir:"parentNode",next:"legend"});try{O.apply(_=P.call(x.childNodes),x.childNodes)}catch(e){O={apply:_.length?function(e,t){D.apply(e,P.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}function ie(e,t,r,o){var i,s,c,l,f,p,v,y=t&&t.ownerDocument,C=t?t.nodeType:9;if(r=r||[],"string"!=typeof e||!e||1!==C&&9!==C&&11!==C)return r;if(!o&&((t?t.ownerDocument||t:x)!==h&&d(t),t=t||h,m)){if(11!==C&&(f=J.exec(e)))if(i=f[1]){if(9===C){if(!(c=t.getElementById(i)))return r;if(c.id===i)return r.push(c),r}else if(y&&(c=y.getElementById(i))&&b(t,c)&&c.id===i)return r.push(c),r}else{if(f[2])return O.apply(r,t.getElementsByTagName(e)),r;if((i=f[3])&&n.getElementsByClassName&&t.getElementsByClassName)return O.apply(r,t.getElementsByClassName(i)),r}if(n.qsa&&!k[e+" "]&&(!g||!g.test(e))){if(1!==C)y=t,v=e;else if("object"!==t.nodeName.toLowerCase()){for((l=t.getAttribute("id"))?l=l.replace(te,ne):t.setAttribute("id",l=w),s=(p=a(e)).length;s--;)p[s]="#"+l+" "+ve(p[s]);v=p.join(","),y=Q.test(e)&&me(t.parentNode)||t}if(v)try{return O.apply(r,y.querySelectorAll(v)),r}catch(e){}finally{l===w&&t.removeAttribute("id")}}}return u(e.replace(j,"$1"),t,r,o)}function ae(){var e=[];return function t(n,o){return e.push(n+" ")>r.cacheLength&&delete t[e.shift()],t[n+" "]=o}}function se(e){return e[w]=!0,e}function ue(e){var t=h.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function ce(e,t){for(var n=e.split("|"),o=n.length;o--;)r.attrHandle[n[o]]=t}function le(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function fe(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function de(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function he(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&oe(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function pe(e){return se(function(t){return t=+t,se(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 me(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(t in n=ie.support={},i=ie.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},d=ie.setDocument=function(e){var t,o,a=e?e.ownerDocument||e:x;return a!==h&&9===a.nodeType&&a.documentElement?(p=(h=a).documentElement,m=!i(h),x!==h&&(o=h.defaultView)&&o.top!==o&&(o.addEventListener?o.addEventListener("unload",re,!1):o.attachEvent&&o.attachEvent("onunload",re)),n.attributes=ue(function(e){return e.className="i",!e.getAttribute("className")}),n.getElementsByTagName=ue(function(e){return e.appendChild(h.createComment("")),!e.getElementsByTagName("*").length}),n.getElementsByClassName=G.test(h.getElementsByClassName),n.getById=ue(function(e){return p.appendChild(e).id=w,!h.getElementsByName||!h.getElementsByName(w).length}),n.getById?(r.filter.ID=function(e){var t=e.replace(Z,ee);return function(e){return e.getAttribute("id")===t}},r.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&m){var n=t.getElementById(e);return n?[n]:[]}}):(r.filter.ID=function(e){var t=e.replace(Z,ee);return function(e){var n="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}},r.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&m){var n,r,o,i=t.getElementById(e);if(i){if((n=i.getAttributeNode("id"))&&n.value===e)return[i];for(o=t.getElementsByName(e),r=0;i=o[r++];)if((n=i.getAttributeNode("id"))&&n.value===e)return[i]}return[]}}),r.find.TAG=n.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],o=0,i=t.getElementsByTagName(e);
vendor: 13,865 bytes, line 1
1if("*"===e){for(;n=i[o++];)1===n.nodeType&&r.push(n);return r}return i},r.find.CLASS=n.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&m)return t.getElementsByClassName(e)},v=[],g=[],(n.qsa=G.test(h.querySelectorAll))&&(ue(function(e){p.appendChild(e).innerHTML="<a id='"+w+"'></a><select id='"+w+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&g.push("[*^$]="+L+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||g.push("\\["+L+"*(?:value|"+I+")"),e.querySelectorAll("[id~="+w+"-]").length||g.push("~="),e.querySelectorAll(":checked").length||g.push(":checked"),e.querySelectorAll("a#"+w+"+*").length||g.push(".#.+[+~]")}),ue(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=h.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&g.push("name"+L+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&g.push(":enabled",":disabled"),p.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&g.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),g.push(",.*:")})),(n.matchesSelector=G.test(y=p.matches||p.webkitMatchesSelector||p.mozMatchesSelector||p.oMatchesSelector||p.msMatchesSelector))&&ue(function(e){n.disconnectedMatch=y.call(e,"*"),y.call(e,"[s!='']:x"),v.push("!=",F)}),g=g.length&&new RegExp(g.join("|")),v=v.length&&new RegExp(v.join("|")),t=G.test(p.compareDocumentPosition),b=t||G.test(p.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},N=t?function(e,t){if(e===t)return f=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===r?e===h||e.ownerDocument===x&&b(x,e)?-1:t===h||t.ownerDocument===x&&b(x,t)?1:l?B(l,e)-B(l,t):0:4&r?-1:1)}:function(e,t){if(e===t)return f=!0,0;var n,r=0,o=e.parentNode,i=t.parentNode,a=[e],s=[t];if(!o||!i)return e===h?-1:t===h?1:o?-1:i?1:l?B(l,e)-B(l,t):0;if(o===i)return le(e,t);for(n=e;n=n.parentNode;)a.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;a[r]===s[r];)r++;return r?le(a[r],s[r]):a[r]===x?-1:s[r]===x?1:0},h):h},ie.matches=function(e,t){return ie(e,null,null,t)},ie.matchesSelector=function(e,t){if((e.ownerDocument||e)!==h&&d(e),t=t.replace(q,"='$1']"),n.matchesSelector&&m&&!k[t+" "]&&(!v||!v.test(t))&&(!g||!g.test(t)))try{var r=y.call(e,t);if(r||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){}return ie(t,h,null,[e]).length>0},ie.contains=function(e,t){return(e.ownerDocument||e)!==h&&d(e),b(e,t)},ie.attr=function(e,t){(e.ownerDocument||e)!==h&&d(e);var o=r.attrHandle[t.toLowerCase()],i=o&&R.call(r.attrHandle,t.toLowerCase())?o(e,t,!m):void 0;return void 0!==i?i:n.attributes||!m?e.getAttribute(t):(i=e.getAttributeNode(t))&&i.specified?i.value:null},ie.escape=function(e){return(e+"").replace(te,ne)},ie.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},ie.uniqueSort=function(e){var t,r=[],o=0,i=0;if(f=!n.detectDuplicates,l=!n.sortStable&&e.slice(0),e.sort(N),f){for(;t=e[i++];)t===e[i]&&(o=r.push(i));for(;o--;)e.splice(r[o],1)}return l=null,e},o=ie.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r++];)n+=o(t);return n},(r=ie.selectors={cacheLength:50,createPseudo:se,match:X,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(Z,ee),e[3]=(e[3]||e[4]||e[5]||"").replace(Z,ee),"~="===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]||ie.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]&&ie.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return X.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&U.test(n)&&(t=a(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(Z,ee).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=T[e+" "];return t||(t=new RegExp("(^|"+L+")"+e+"("+L+"|$)"))&&T(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var o=ie.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.replace(W," ")+" ").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),s="of-type"===t;return 1===r&&0===o?function(e){return!!e.parentNode}:function(t,n,u){var c,l,f,d,h,p,m=i!==a?"nextSibling":"previousSibling",g=t.parentNode,v=s&&t.nodeName.toLowerCase(),y=!u&&!s,b=!1;if(g){if(i){for(;m;){for(d=t;d=d[m];)if(s?d.nodeName.toLowerCase()===v:1===d.nodeType)return!1;p=m="only"===e&&!p&&"nextSibling"}return!0}if(p=[a?g.firstChild:g.lastChild],a&&y){for(b=(h=(c=(l=(f=(d=g)[w]||(d[w]={}))[d.uniqueID]||(f[d.uniqueID]={}))[e]||[])[0]===C&&c[1])&&c[2],d=h&&g.childNodes[h];d=++h&&d&&d[m]||(b=h=0)||p.pop();)if(1===d.nodeType&&++b&&d===t){l[e]=[C,h,b];break}}else if(y&&(b=h=(c=(l=(f=(d=t)[w]||(d[w]={}))[d.uniqueID]||(f[d.uniqueID]={}))[e]||[])[0]===C&&c[1]),!1===b)for(;(d=++h&&d&&d[m]||(b=h=0)||p.pop())&&((s?d.nodeName.toLowerCase()!==v:1!==d.nodeType)||!++b||(y&&((l=(f=d[w]||(d[w]={}))[d.uniqueID]||(f[d.uniqueID]={}))[e]=[C,b]),d!==t)););return(b-=o)===r||b%r==0&&b/r>=0}}},PSEUDO:function(e,t){var n,o=r.pseudos[e]||r.setFilters[e.toLowerCase()]||ie.error("unsupported pseudo: "+e);return o[w]?o(t):o.length>1?(n=[e,e,"",t],r.setFilters.hasOwnProperty(e.toLowerCase())?se(function(e,n){for(var r,i=o(e,t),a=i.length;a--;)e[r=B(e,i[a])]=!(n[r]=i[a])}):function(e){return o(e,0,n)}):o}},pseudos:{not:se(function(e){var t=[],n=[],r=s(e.replace(j,"$1"));return r[w]?se(function(e,t,n,o){for(var i,a=r(e,null,o,[]),s=e.length;s--;)(i=a[s])&&(e[s]=!(t[s]=i))}):function(e,o,i){return t[0]=e,r(t,null,i,n),t[0]=null,!n.pop()}}),has:se(function(e){return function(t){return ie(e,t).length>0}}),contains:se(function(e){return e=e.replace(Z,ee),function(t){return(t.textContent||t.innerText||o(t)).indexOf(e)>-1}}),lang:se(function(e){return V.test(e||"")||ie.error("unsupported lang: "+e),e=e.replace(Z,ee).toLowerCase(),function(t){var n;do{if(n=m?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===p},focus:function(e){return e===h.activeElement&&(!h.hasFocus||h.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:he(!1),disabled:he(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!r.pseudos.empty(e)},header:function(e){return K.test(e.nodeName)},input:function(e){return Y.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:pe(function(){return[0]}),last:pe(function(e,t){return[t-1]}),eq:pe(function(e,t,n){return[n<0?n+t:n]}),even:pe(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:pe(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:pe(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:pe(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=r.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[t]=fe(t);for(t in{submit:!0,reset:!0})r.pseudos[t]=de(t);function ge(){}function ve(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function ye(e,t,n){var r=t.dir,o=t.next,i=o||r,a=n&&"parentNode"===i,s=S++;return t.first?function(t,n,o){for(;t=t[r];)if(1===t.nodeType||a)return e(t,n,o);return!1}:function(t,n,u){var c,l,f,d=[C,s];if(u){for(;t=t[r];)if((1===t.nodeType||a)&&e(t,n,u))return!0}else for(;t=t[r];)if(1===t.nodeType||a)if(l=(f=t[w]||(t[w]={}))[t.uniqueID]||(f[t.uniqueID]={}),o&&o===t.nodeName.toLowerCase())t=t[r]||t;else{if((c=l[i])&&c[0]===C&&c[1]===s)return d[2]=c[2];if(l[i]=d,d[2]=e(t,n,u))return!0}return!1}}function be(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 we(e,t,n,r,o){for(var i,a=[],s=0,u=e.length,c=null!=t;s<u;s++)(i=e[s])&&(n&&!n(i,r,o)||(a.push(i),c&&t.push(s)));return a}function xe(e,t,n,r,o,i){return r&&!r[w]&&(r=xe(r)),o&&!o[w]&&(o=xe(o,i)),se(function(i,a,s,u){var c,l,f,d=[],h=[],p=a.length,m=i||function(e,t,n){for(var r=0,o=t.length;r<o;r++)ie(e,t[r],n);return n}(t||"*",s.nodeType?[s]:s,[]),g=!e||!i&&t?m:we(m,d,e,s,u),v=n?o||(i?e:p||r)?[]:a:g;if(n&&n(g,v,s,u),r)for(c=we(v,h),r(c,[],s,u),l=c.length;l--;)(f=c[l])&&(v[h[l]]=!(g[h[l]]=f));if(i){if(o||e){if(o){for(c=[],l=v.length;l--;)(f=v[l])&&c.push(g[l]=f);o(null,v=[],c,u)}for(l=v.length;l--;)(f=v[l])&&(c=o?B(i,f):d[l])>-1&&(i[c]=!(a[c]=f))}}else v=we(v===a?v.splice(p,v.length):v),o?o(null,a,v,u):O.apply(a,v)})}function Ce(e){for(var t,n,o,i=e.length,a=r.relative[e[0].type],s=a||r.relative[" "],u=a?1:0,l=ye(function(e){return e===t},s,!0),f=ye(function(e){return B(t,e)>-1},s,!0),d=[function(e,n,r){var o=!a&&(r||n!==c)||((t=n).nodeType?l(e,n,r):f(e,n,r));return t=null,o}];u<i;u++)if(n=r.relative[e[u].type])d=[ye(be(d),n)];else{if((n=r.filter[e[u].type].apply(null,e[u].matches))[w]){for(o=++u;o<i&&!r.relative[e[o].type];o++);return xe(u>1&&be(d),u>1&&ve(e.slice(0,u-1).concat({value:" "===e[u-2].type?"*":""})).replace(j,"$1"),n,u<o&&Ce(e.slice(u,o)),o<i&&Ce(e=e.slice(o)),o<i&&ve(e))}d.push(n)}return be(d)}function Se(e,t){var n=t.length>0,o=e.length>0,i=function(i,a,s,u,l){var f,p,g,v=0,y="0",b=i&&[],w=[],x=c,S=i||o&&r.find.TAG("*",l),T=C+=null==x?1:Math.random()||.1,E=S.length;for(l&&(c=a===h||a||l);y!==E&&null!=(f=S[y]);y++){if(o&&f){for(p=0,a||f.ownerDocument===h||(d(f),s=!m);g=e[p++];)if(g(f,a||h,s)){u.push(f);break}l&&(C=T)}n&&((f=!g&&f)&&v--,i&&b.push(f))}if(v+=y,n&&y!==v){for(p=0;g=t[p++];)g(b,w,a,s);if(i){if(v>0)for(;y--;)b[y]||w[y]||(w[y]=A.call(u));w=we(w)}O.apply(u,w),l&&!i&&w.length>0&&v+t.length>1&&ie.uniqueSort(u)}return l&&(C=T,c=x),b};return n?se(i):i}return ge.prototype=r.filters=r.pseudos,r.setFilters=new ge,a=ie.tokenize=function(e,t){var n,o,i,a,s,u,c,l=E[e+" "];if(l)return t?0:l.slice(0);for(s=e,u=[],c=r.preFilter;s;){for(a in n&&!(o=$.exec(s))||(o&&(s=s.slice(o[0].length)||s),u.push(i=[])),n=!1,(o=z.exec(s))&&(n=o.shift(),i.push({value:n,type:o[0].replace(j," ")}),s=s.slice(n.length)),r.filter)!(o=X[a].exec(s))||c[a]&&!(o=c[a](o))||(n=o.shift(),i.push({value:n,type:a,matches:o}),s=s.slice(n.length));if(!n)break}return t?s.length:s?ie.error(e):E(e,u).slice(0)},s=ie.compile=function(e,t){var n,r=[],o=[],i=k[e+" "];if(!i){for(t||(t=a(e)),n=t.length;n--;)(i=Ce(t[n]))[w]?r.push(i):o.push(i);(i=k(e,Se(o,r))).selector=e}return i},u=ie.select=function(e,t,n,o){var i,u,c,l,f,d="function"==typeof e&&e,h=!o&&a(e=d.selector||e);if(n=n||[],1===h.length){if((u=h[0]=h[0].slice(0)).length>2&&"ID"===(c=u[0]).type&&9===t.nodeType&&m&&r.relative[u[1].type]){if(!(t=(r.find.ID(c.matches[0].replace(Z,ee),t)||[])[0]))return n;d&&(t=t.parentNode),e=e.slice(u.shift().value.length)}for(i=X.needsContext.test(e)?0:u.length;i--&&!r.relative[l=(c=u[i]).type];)if((f=r.find[l])&&(o=f(c.matches[0].replace(Z,ee),Q.test(u[0].type)&&me(t.parentNode)||t))){if(u.splice(i,1),!(e=o.length&&ve(u)))return O.apply(n,o),n;break}}return(d||s(e,h))(o,t,!m,n,!t||Q.test(e)&&me(t.parentNode)||t),n},n.sortStable=w.split("").sort(N).join("")===w,n.detectDuplicates=!!f,d(),n.sortDetached=ue(function(e){return 1&e.compareDocumentPosition(h.createElement("fieldset"))}),ue(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||ce("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),n.attributes&&ue(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||ce("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ue(function(e){return null==e.getAttribute("disabled")})||ce(I,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),ie}(e);w.find=S,w.expr=S.selectors,w.expr[":"]=w.expr.pseudos,w.uniqueSort=w.unique=S.uniqueSort,w.text=S.getText,w.isXMLDoc=S.isXML,w.contains=S.contains,w.escapeSelector=S.escape;var T=function(e,t,n){for(var r=[],o=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(o&&w(e).is(n))break;r.push(e)}return r},E=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=w.expr.match.needsContext;
vendor: 10,953 bytes, line 1
1function N(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var R=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function _(e,t,n){return m(t)?w.grep(e,function(e,r){return!!t.call(e,r,e)!==n}):t.nodeType?w.grep(e,function(e){return e===t!==n}):"string"!=typeof t?w.grep(e,function(e){return u.call(t,e)>-1!==n}):w.filter(t,e,n)}w.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?w.find.matchesSelector(r,e)?[r]:[]:w.find.matches(e,w.grep(t,function(e){return 1===e.nodeType}))},w.fn.extend({find:function(e){var t,n,r=this.length,o=this;if("string"!=typeof e)return this.pushStack(w(e).filter(function(){for(t=0;t<r;t++)if(w.contains(o[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)w.find(e,o[t],n);return r>1?w.uniqueSort(n):n},filter:function(e){return this.pushStack(_(this,e||[],!1))},not:function(e){return this.pushStack(_(this,e||[],!0))},is:function(e){return!!_(this,"string"==typeof e&&k.test(e)?w(e):e||[],!1).length}});var A,D=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(w.fn.init=function(e,t,n){var o,i;if(!e)return this;if(n=n||A,"string"==typeof e){if(!(o="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:D.exec(e))||!o[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(o[1]){if(w.merge(this,w.parseHTML(o[1],(t=t instanceof w?t[0]:t)&&t.nodeType?t.ownerDocument||t:r,!0)),R.test(o[1])&&w.isPlainObject(t))for(o in t)m(this[o])?this[o](t[o]):this.attr(o,t[o]);return this}return(i=r.getElementById(o[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(w):w.makeArray(e,this)}).prototype=w.fn,A=w(r);var O=/^(?:parents|prev(?:Until|All))/,P={children:!0,contents:!0,next:!0,prev:!0};function B(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}w.fn.extend({has:function(e){var t=w(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(w.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,o=this.length,i=[],a="string"!=typeof e&&w(e);if(!k.test(e))for(;r<o;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&w.find.matchesSelector(n,e))){i.push(n);break}return this.pushStack(i.length>1?w.uniqueSort(i):i)},index:function(e){return e?"string"==typeof e?u.call(w(e),this[0]):u.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(w.uniqueSort(w.merge(this.get(),w(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),w.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return T(e,"parentNode")},parentsUntil:function(e,t,n){return T(e,"parentNode",n)},next:function(e){return B(e,"nextSibling")},prev:function(e){return B(e,"previousSibling")},nextAll:function(e){return T(e,"nextSibling")},prevAll:function(e){return T(e,"previousSibling")},nextUntil:function(e,t,n){return T(e,"nextSibling",n)},prevUntil:function(e,t,n){return T(e,"previousSibling",n)},siblings:function(e){return E((e.parentNode||{}).firstChild,e)},children:function(e){return E(e.firstChild)},contents:function(e){return N(e,"iframe")?e.contentDocument:(N(e,"template")&&(e=e.content||e),w.merge([],e.childNodes))}},function(e,t){w.fn[e]=function(n,r){var o=w.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(o=w.filter(r,o)),this.length>1&&(P[e]||w.uniqueSort(o),O.test(e)&&o.reverse()),this.pushStack(o)}});var I=/[^\x20\t\r\n\f]+/g;function L(e){return e}function M(e){throw e}function H(e,t,n,r){var o;try{e&&m(o=e.promise)?o.call(e).done(t).fail(n):e&&m(o=e.then)?o.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}w.Callbacks=function(e){e="string"==typeof e?function(e){var t={};return w.each(e.match(I)||[],function(e,n){t[n]=!0}),t}(e):w.extend({},e);var t,n,r,o,i=[],a=[],s=-1,u=function(){for(o=o||e.once,r=t=!0;a.length;s=-1)for(n=a.shift();++s<i.length;)!1===i[s].apply(n[0],n[1])&&e.stopOnFalse&&(s=i.length,n=!1);e.memory||(n=!1),t=!1,o&&(i=n?[]:"")},c={add:function(){return i&&(n&&!t&&(s=i.length-1,a.push(n)),function t(n){w.each(n,function(n,r){m(r)?e.unique&&c.has(r)||i.push(r):r&&r.length&&"string"!==b(r)&&t(r)})}(arguments),n&&!t&&u()),this},remove:function(){return w.each(arguments,function(e,t){for(var n;(n=w.inArray(t,i,n))>-1;)i.splice(n,1),n<=s&&s--}),this},has:function(e){return e?w.inArray(e,i)>-1:i.length>0},empty:function(){return i&&(i=[]),this},disable:function(){return o=a=[],i=n="",this},disabled:function(){return!i},lock:function(){return o=a=[],n||t||(i=n=""),this},locked:function(){return!!o},fireWith:function(e,n){return o||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||u()),this},fire:function(){return c.fireWith(this,arguments),this},fired:function(){return!!r}};return c},w.extend({Deferred:function(t){var n=[["notify","progress",w.Callbacks("memory"),w.Callbacks("memory"),2],["resolve","done",w.Callbacks("once memory"),w.Callbacks("once memory"),0,"resolved"],["reject","fail",w.Callbacks("once memory"),w.Callbacks("once memory"),1,"rejected"]],r="pending",o={state:function(){return r},always:function(){return i.done(arguments).fail(arguments),this},catch:function(e){return o.then(null,e)},pipe:function(){var e=arguments;return w.Deferred(function(t){w.each(n,function(n,r){var o=m(e[r[4]])&&e[r[4]];i[r[1]](function(){var e=o&&o.apply(this,arguments);e&&m(e.promise)?e.promise().progress(t.notify).done(t.resolve).fail(t.reject):t[r[0]+"With"](this,o?[e]:arguments)})}),e=null}).promise()},then:function(t,r,o){var i=0;function a(t,n,r,o){return function(){var s=this,u=arguments,c=function(){var e,c;if(!(t<i)){if((e=r.apply(s,u))===n.promise())throw new TypeError("Thenable self-resolution");m(c=e&&("object"==typeof e||"function"==typeof e)&&e.then)?o?c.call(e,a(i,n,L,o),a(i,n,M,o)):c.call(e,a(++i,n,L,o),a(i,n,M,o),a(i,n,L,n.notifyWith)):(r!==L&&(s=void 0,u=[e]),(o||n.resolveWith)(s,u))}},l=o?c:function(){try{c()}catch(e){w.Deferred.exceptionHook&&w.Deferred.exceptionHook(e,l.stackTrace),t+1>=i&&(r!==M&&(s=void 0,u=[e]),n.rejectWith(s,u))}};t?l():(w.Deferred.getStackHook&&(l.stackTrace=w.Deferred.getStackHook()),e.setTimeout(l))}}return w.Deferred(function(e){n[0][3].add(a(0,e,m(o)?o:L,e.notifyWith)),n[1][3].add(a(0,e,m(t)?t:L)),n[2][3].add(a(0,e,m(r)?r:M))}).promise()},promise:function(e){return null!=e?w.extend(e,o):o}},i={};return w.each(n,function(e,t){var a=t[2],s=t[5];o[t[1]]=a.add,s&&a.add(function(){r=s},n[3-e][2].disable,n[3-e][3].disable,n[0][2].lock,n[0][3].lock),a.add(t[3].fire),i[t[0]]=function(){return i[t[0]+"With"](this===i?void 0:this,arguments),this},i[t[0]+"With"]=a.fireWith}),o.promise(i),t&&t.call(i,i),i},when:function(e){var t=arguments.length,n=t,r=Array(n),o=i.call(arguments),a=w.Deferred(),s=function(e){return function(n){r[e]=this,o[e]=arguments.length>1?i.call(arguments):n,--t||a.resolveWith(r,o)}};if(t<=1&&(H(e,a.done(s(n)).resolve,a.reject,!t),"pending"===a.state()||m(o[n]&&o[n].then)))return a.then();for(;n--;)H(o[n],s(n),a.reject);return a.promise()}});var F=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;w.Deferred.exceptionHook=function(t,n){e.console&&e.console.warn&&t&&F.test(t.name)&&e.console.warn("jQuery.Deferred exception: "+t.message,t.stack,n)},w.readyException=function(t){e.setTimeout(function(){throw t})};var W=w.Deferred();function j(){r.removeEventListener("DOMContentLoaded",j),e.removeEventListener("load",j),w.ready()}w.fn.ready=function(e){return W.then(e).catch(function(e){w.readyException(e)}),this},w.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--w.readyWait:w.isReady)||(w.isReady=!0,!0!==e&&--w.readyWait>0||W.resolveWith(r,[w]))}}),w.ready.then=W.then,"complete"===r.readyState||"loading"!==r.readyState&&!r.documentElement.doScroll?e.setTimeout(w.ready):(r.addEventListener("DOMContentLoaded",j),e.addEventListener("load",j));var $=function(e,t,n,r,o,i,a){var s=0,u=e.length,c=null==n;if("object"===b(n))for(s in o=!0,n)$(e,t,s,n[s],!0,i,a);else if(void 0!==r&&(o=!0,m(r)||(a=!0),c&&(a?(t.call(e,r),t=null):(c=t,t=function(e,t,n){return c.call(w(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return o?e:c?t.call(e):u?t(e[0],n):i},z=/^-ms-/,q=/-([a-z])/g;function U(e,t){return t.toUpperCase()}function V(e){return e.replace(z,"ms-").replace(q,U)}var X=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function Y(){this.expando=w.expando+Y.uid++}Y.uid=1,Y.prototype={cache:function(e){var t=e[this.expando];return t||(t={},X(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,o=this.cache(e);if("string"==typeof t)o[V(t)]=n;else for(r in t)o[V(r)]=t[r];return o},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][V(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(V):(t=V(t))in r?[t]:t.match(I)||[]).length;for(;n--;)delete r[t[n]]}(void 0===t||w.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!w.isEmptyObject(t)}};var K=new Y,G=new Y,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Q=/[A-Z]/g;function Z(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(Q,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n=function(e){return"true"===e||"false"!==e&&("null"===e?null:e===+e+""?+e:J.test(e)?JSON.parse(e):e)}(n)}catch(e){}G.set(e,t,n)}else n=void 0;return n}w.extend({hasData:function(e){return G.hasData(e)||K.hasData(e)},data:function(e,t,n){return G.access(e,t,n)},removeData:function(e,t){G.remove(e,t)},_data:function(e,t,n){return K.access(e,t,n)},_removeData:function(e,t){K.remove(e,t)}}),w.fn.extend({data:function(e,t){var n,r,o,i=this[0],a=i&&i.attributes;if(void 0===e){if(this.length&&(o=G.get(i),1===i.nodeType&&!K.get(i,"hasDataAttrs"))){for(n=a.length;n--;)a[n]&&0===(r=a[n].name).indexOf("data-")&&(r=V(r.slice(5)),Z(i,r,o[r]));K.set(i,"hasDataAttrs",!0)}return o}return"object"==typeof e?this.each(function(){G.set(this,e)}):$(this,function(t){var n;if(i&&void 0===t){if(void 0!==(n=G.get(i,e)))return n;if(void 0!==(n=Z(i,e)))return n}else this.each(function(){G.set(this,e,t)})},null,t,arguments.length>1,null,!0)},removeData:function(e){return this.each(function(){G.remove(this,e)})}}),w.extend({queue:function(e,t,n){var r;if(e)return r=K.get(e,t=(t||"fx")+"queue"),n&&(!r||Array.isArray(n)?r=K.access(e,t,w.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){var n=w.queue(e,t=t||"fx"),r=n.length,o=n.shift(),i=w._queueHooks(e,t);"inprogress"===o&&(o=n.shift(),r--),o&&("fx"===t&&n.unshift("inprogress"),delete i.stop,o.call(e,function(){w.dequeue(e,t)}
vendor: 7,982 bytes, line 1
1,i)),!r&&i&&i.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return K.get(e,n)||K.access(e,n,{empty:w.Callbacks("once memory").add(function(){K.remove(e,[t+"queue",n])})})}}),w.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?w.queue(this[0],e):void 0===t?this:this.each(function(){var n=w.queue(this,e,t);w._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&w.dequeue(this,e)})},dequeue:function(e){return this.each(function(){w.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,o=w.Deferred(),i=this,a=this.length,s=function(){--r||o.resolveWith(i,[i])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)(n=K.get(i[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),o.promise(t)}});var ee=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,te=new RegExp("^(?:([+-])=|)("+ee+")([a-z%]*)$","i"),ne=["Top","Right","Bottom","Left"],re=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&w.contains(e.ownerDocument,e)&&"none"===w.css(e,"display")},oe=function(e,t,n,r){var o,i,a={};for(i in t)a[i]=e.style[i],e.style[i]=t[i];for(i in o=n.apply(e,r||[]),t)e.style[i]=a[i];return o};function ie(e,t,n,r){var o,i,a=20,s=r?function(){return r.cur()}:function(){return w.css(e,t,"")},u=s(),c=n&&n[3]||(w.cssNumber[t]?"":"px"),l=(w.cssNumber[t]||"px"!==c&&+u)&&te.exec(w.css(e,t));if(l&&l[3]!==c){for(u/=2,c=c||l[3],l=+u||1;a--;)w.style(e,t,l+c),(1-i)*(1-(i=s()/u||.5))<=0&&(a=0),l/=i;w.style(e,t,(l*=2)+c),n=n||[]}return n&&(l=+l||+u||0,o=n[1]?l+(n[1]+1)*n[2]:+n[2],r&&(r.unit=c,r.start=l,r.end=o)),o}var ae={};function se(e){var t,n=e.ownerDocument,r=e.nodeName,o=ae[r];return o||(t=n.body.appendChild(n.createElement(r)),o=w.css(t,"display"),t.parentNode.removeChild(t),"none"===o&&(o="block"),ae[r]=o,o)}function ue(e,t){for(var n,r,o=[],i=0,a=e.length;i<a;i++)(r=e[i]).style&&(n=r.style.display,t?("none"===n&&(o[i]=K.get(r,"display")||null,o[i]||(r.style.display="")),""===r.style.display&&re(r)&&(o[i]=se(r))):"none"!==n&&(o[i]="none",K.set(r,"display",n)));for(i=0;i<a;i++)null!=o[i]&&(e[i].style.display=o[i]);return e}w.fn.extend({show:function(){return ue(this,!0)},hide:function(){return ue(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){re(this)?w(this).show():w(this).hide()})}});var ce=/^(?:checkbox|radio)$/i,le=/<([a-z][^\/\0>\x20\t\r\n\f]+)/i,fe=/^$|^module$|\/(?:java|ecma)script/i,de={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function he(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&N(e,t)?w.merge([e],n):n}function pe(e,t){for(var n=0,r=e.length;n<r;n++)K.set(e[n],"globalEval",!t||K.get(t[n],"globalEval"))}de.optgroup=de.option,de.tbody=de.tfoot=de.colgroup=de.caption=de.thead,de.th=de.td;var me=/<|&#?\w+;/;function ge(e,t,n,r,o){for(var i,a,s,u,c,l,f=t.createDocumentFragment(),d=[],h=0,p=e.length;h<p;h++)if((i=e[h])||0===i)if("object"===b(i))w.merge(d,i.nodeType?[i]:i);else if(me.test(i)){for(a=a||f.appendChild(t.createElement("div")),s=(le.exec(i)||["",""])[1].toLowerCase(),a.innerHTML=(u=de[s]||de._default)[1]+w.htmlPrefilter(i)+u[2],l=u[0];l--;)a=a.lastChild;w.merge(d,a.childNodes),(a=f.firstChild).textContent=""}else d.push(t.createTextNode(i));for(f.textContent="",h=0;i=d[h++];)if(r&&w.inArray(i,r)>-1)o&&o.push(i);else if(c=w.contains(i.ownerDocument,i),a=he(f.appendChild(i),"script"),c&&pe(a),n)for(l=0;i=a[l++];)fe.test(i.type||"")&&n.push(i);return f}!function(){var e=r.createDocumentFragment().appendChild(r.createElement("div")),t=r.createElement("input");t.setAttribute("type","radio"),t.setAttribute("checked","checked"),t.setAttribute("name","t"),e.appendChild(t),p.checkClone=e.cloneNode(!0).cloneNode(!0).lastChild.checked,e.innerHTML="<textarea>x</textarea>",p.noCloneChecked=!!e.cloneNode(!0).lastChild.defaultValue}();var ve=r.documentElement,ye=/^key/,be=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,we=/^([^.]*)(?:\.(.+)|)/;function xe(){return!0}function Ce(){return!1}function Se(){try{return r.activeElement}catch(e){}}function Te(e,t,n,r,o,i){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Te(e,s,n,r,t[s],i);return e}if(null==r&&null==o?(o=n,r=n=void 0):null==o&&("string"==typeof n?(o=r,r=void 0):(o=r,r=n,n=void 0)),!1===o)o=Ce;else if(!o)return e;return 1===i&&(a=o,(o=function(e){return w().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=w.guid++)),e.each(function(){w.event.add(this,t,o,r,n)})}w.event={global:{},add:function(e,t,n,r,o){var i,a,s,u,c,l,f,d,h,p,m,g=K.get(e);if(g)for(n.handler&&(n=(i=n).handler,o=i.selector),o&&w.find.matchesSelector(ve,o),n.guid||(n.guid=w.guid++),(u=g.events)||(u=g.events={}),(a=g.handle)||(a=g.handle=function(t){return"undefined"!=typeof w&&w.event.triggered!==t.type?w.event.dispatch.apply(e,arguments):void 0}),c=(t=(t||"").match(I)||[""]).length;c--;)h=m=(s=we.exec(t[c])||[])[1],p=(s[2]||"").split(".").sort(),h&&(f=w.event.special[h]||{},f=w.event.special[h=(o?f.delegateType:f.bindType)||h]||{},l=w.extend({type:h,origType:m,data:r,handler:n,guid:n.guid,selector:o,needsContext:o&&w.expr.match.needsContext.test(o),namespace:p.join(".")},i),(d=u[h])||((d=u[h]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(e,r,p,a)||e.addEventListener&&e.addEventListener(h,a)),f.add&&(f.add.call(e,l),l.handler.guid||(l.handler.guid=n.guid)),o?d.splice(d.delegateCount++,0,l):d.push(l),w.event.global[h]=!0)},remove:function(e,t,n,r,o){var i,a,s,u,c,l,f,d,h,p,m,g=K.hasData(e)&&K.get(e);if(g&&(u=g.events)){for(c=(t=(t||"").match(I)||[""]).length;c--;)if(h=m=(s=we.exec(t[c])||[])[1],p=(s[2]||"").split(".").sort(),h){for(f=w.event.special[h]||{},d=u[h=(r?f.delegateType:f.bindType)||h]||[],s=s[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=i=d.length;i--;)l=d[i],!o&&m!==l.origType||n&&n.guid!==l.guid||s&&!s.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(d.splice(i,1),l.selector&&d.delegateCount--,f.remove&&f.remove.call(e,l));a&&!d.length&&(f.teardown&&!1!==f.teardown.call(e,p,g.handle)||w.removeEvent(e,h,g.handle),delete u[h])}else for(h in u)w.event.remove(e,h+t[c],n,r,!0);w.isEmptyObject(u)&&K.remove(e,"handle events")}},dispatch:function(e){var t,n,r,o,i,a,s=w.event.fix(e),u=new Array(arguments.length),c=(K.get(this,"events")||{})[s.type]||[],l=w.event.special[s.type]||{};for(u[0]=s,t=1;t<arguments.length;t++)u[t]=arguments[t];if(s.delegateTarget=this,!l.preDispatch||!1!==l.preDispatch.call(this,s)){for(a=w.event.handlers.call(this,s,c),t=0;(o=a[t++])&&!s.isPropagationStopped();)for(s.currentTarget=o.elem,n=0;(i=o.handlers[n++])&&!s.isImmediatePropagationStopped();)s.rnamespace&&!s.rnamespace.test(i.namespace)||(s.handleObj=i,s.data=i.data,void 0!==(r=((w.event.special[i.origType]||{}).handle||i.handler).apply(o.elem,u))&&!1===(s.result=r)&&(s.preventDefault(),s.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,s),s.result}},handlers:function(e,t){var n,r,o,i,a,s=[],u=t.delegateCount,c=e.target;if(u&&c.nodeType&&!("click"===e.type&&e.button>=1))for(;c!==this;c=c.parentNode||this)if(1===c.nodeType&&("click"!==e.type||!0!==c.disabled)){for(i=[],a={},n=0;n<u;n++)void 0===a[o=(r=t[n]).selector+" "]&&(a[o]=r.needsContext?w(o,this).index(c)>-1:w.find(o,this,null,[c]).length),a[o]&&i.push(r);i.length&&s.push({elem:c,handlers:i})}return c=this,u<t.length&&s.push({elem:c,handlers:t.slice(u)}),s},addProp:function(e,t){Object.defineProperty(w.Event.prototype,e,{enumerable:!0,configurable:!0,get:m(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[e]}
vendor: 2,327 bytes, line 1
1,set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(e){return e[w.expando]?e:new w.Event(e)},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==Se()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===Se()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&N(this,"input"))return this.click(),!1},_default:function(e){return N(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},w.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},w.Event=function(e,t){if(!(this instanceof w.Event))return new w.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?xe:Ce,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&w.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[w.expando]=!0},w.Event.prototype={constructor:w.Event,isDefaultPrevented:Ce,isPropagationStopped:Ce,isImmediatePropagationStopped:Ce,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=xe,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=xe,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=xe,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},w.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&ye.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&be.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},w.event.addProp),w.each({mouseenter:"mouseover",mouseleave:"mou
1seout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){w.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=e.relatedTarget,o=e.handleObj;return r&&(r===this||w.contains(this,r))||(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),w.fn.extend({on:function(e,t,n,r){return Te(this,e,t,n,r)},one:function(e,t,n,r){return Te(this,e,t,n,r,1)},off:function(e,t,n){var r,o;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,w(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(o in e)this.off(o,t,e[o]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Ce),this.each(function(){w.event.remove(this,e,n,t)})}});var Ee=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,ke=/<script|<style|<link/i,Ne=/checked\s*(?:[^=]|=\s*.checked.)/i,Re=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function _e(e,t){return N(e,"table")&&N(11!==t.nodeType?t:t.firstChild,"tr")&&w(e).children("tbody")[0]||e}function Ae(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function De(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,o,i,a,s,u,c;if(1===t.nodeType){if(K.hasData(e)&&(i=K.access(e),a=K.set(t,i),c=i.events))for(o in delete a.handle,a.events={},c)for(n=0,r=c[o].length;n<r;n++)w.event.add(t,o,c[o][n]);G.hasData(e)&&(s=G.access(e),u=w.extend({},s),G.set(t,u))}}function Pe(e,t){var n=t.nodeName.toLowerCase();"input"===n&&ce.test(e.type)?t.checked=e.checked:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}function Be(e,t,n,r){t=a.apply([],t);var o,i,s,u,c,l,f=0,d=e.length,h=d-1,g=t[0],v=m(g);if(v||d>1&&"string"==typeof g&&!p.checkClone&&Ne.test(g))return e.each(function(o){var i=e.eq(o);v&&(t[0]=g.call(this,o,i.html())),Be(i,t,n,r)});if(d&&(i=(o=ge(t,e[0].ownerDocument,!1,e,r)).firstChild,1===o.childNodes.length&&(o=i),i||r)){for(u=(s=w.map(he(o,"script"),Ae)).length;f<d;f++)c=o,f!==h&&(c=w.clone(c,!0,!0),u&&w.merge(s,he(c,"script"))),n.call(e[f],c,f);if(u)for(l=s[s.length-1].ownerDocument,w.map(s,De),f=0;f<u;f++)fe.test((c=s[f]).type||"")&&!K.access(c,"globalEval")&&w.contains(l,c)&&(c.src&&"module"!==(c.type||"").toLowerCase()?w._evalUrl&&w._evalUrl(c.src):y(c.textContent.replace(Re,""),l,c))}return e}function Ie(e,t,n){for(var r,o=t?w.filter(t,e):e,i=0;null!=(r=o[i]);i++)n||1!==r.nodeType||w.cleanData(he(r)),r.parentNode&&(n&&w.contains(r.ownerDocument,r)&&pe(he(r,"script")),r.parentNode.removeChild(r));return e}w.extend({htmlPrefilter:function(e){return e.replace(Ee,"<$1></$2>")},clone:function(e,t,n){var r,o,i,a,s=e.cloneNode(!0),u=w.contains(e.ownerDocument,e);if(!(p.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||w.isXMLDoc(e)))for(a=he(s),r=0,o=(i=he(e)).length;r<o;r++)Pe(i[r],a[r]);if(t)if(n)for(i=i||he(e),a=a||he(s),r=0,o=i.length;r<o;r++)Oe(i[r],a[r]);else Oe(e,s);return(a=he(s,"script")).length>0&&pe(a,!u&&he(e,"script")),s},cleanData:function(e){for(var t,n,r,o=w.event.special,i=0;void 0!==(n=e[i]);
vendor: 6,668 bytes, line 1
1i++)if(X(n)){if(t=n[K.expando]){if(t.events)for(r in t.events)o[r]?w.event.remove(n,r):w.removeEvent(n,r,t.handle);n[K.expando]=void 0}n[G.expando]&&(n[G.expando]=void 0)}}}),w.fn.extend({detach:function(e){return Ie(this,e,!0)},remove:function(e){return Ie(this,e)},text:function(e){return $(this,function(e){return void 0===e?w.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return Be(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||_e(this,e).appendChild(e)})},prepend:function(){return Be(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=_e(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Be(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Be(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(w.cleanData(he(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return w.clone(this,e,t)})},html:function(e){return $(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!ke.test(e)&&!de[(le.exec(e)||["",""])[1].toLowerCase()]){e=w.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(w.cleanData(he(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=[];return Be(this,arguments,function(t){var n=this.parentNode;w.inArray(this,e)<0&&(w.cleanData(he(this)),n&&n.replaceChild(t,this))},e)}}),w.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){w.fn[e]=function(e){for(var n,r=[],o=w(e),i=o.length-1,a=0;a<=i;a++)n=a===i?this:this.clone(!0),w(o[a])[t](n),s.apply(r,n.get());return this.pushStack(r)}});var Le=new RegExp("^("+ee+")(?!px)[a-z%]+$","i"),Me=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)},He=new RegExp(ne.join("|"),"i");function Fe(e,t,n){var r,o,i,a,s=e.style;return(n=n||Me(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||w.contains(e.ownerDocument,e)||(a=w.style(e,t)),!p.pixelBoxStyles()&&Le.test(a)&&He.test(t)&&(r=s.width,o=s.minWidth,i=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=o,s.maxWidth=i)),void 0!==a?a+"":a}function We(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function t(){if(l){c.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",ve.appendChild(c).appendChild(l);var t=e.getComputedStyle(l);o="1%"!==t.top,u=12===n(t.marginLeft),l.style.right="60%",s=36===n(t.right),i=36===n(t.width),l.style.position="absolute",a=36===l.offsetWidth||"absolute",ve.removeChild(c),l=null}}function n(e){return Math.round(parseFloat(e))}var o,i,a,s,u,c=r.createElement("div"),l=r.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",p.clearCloneStyle="content-box"===l.style.backgroundClip,w.extend(p,{boxSizingReliable:function(){return t(),i},pixelBoxStyles:function(){return t(),s},pixelPosition:function(){return t(),o},reliableMarginLeft:function(){return t(),u},scrollboxSize:function(){return t(),a}}))}();var je=/^(none|table(?!-c[ea]).+)/,$e=/^--/,ze={position:"absolute",visibility:"hidden",display:"block"},qe={letterSpacing:"0",fontWeight:"400"},Ue=["Webkit","Moz","ms"],Ve=r.createElement("div").style;function Xe(e){var t=w.cssProps[e];return t||(t=w.cssProps[e]=function(e){if(e in Ve)return e;for(var t=e[0].toUpperCase()+e.slice(1),n=Ue.length;n--;)if((e=Ue[n]+t)in Ve)return e}(e)||e),t}function Ye(e,t,n){var r=te.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ke(e,t,n,r,o,i){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=w.css(e,n+ne[a],!0,o)),r?("content"===n&&(u-=w.css(e,"padding"+ne[a],!0,o)),"margin"!==n&&(u-=w.css(e,"border"+ne[a]+"Width",!0,o))):(u+=w.css(e,"padding"+ne[a],!0,o),"padding"!==n?u+=w.css(e,"border"+ne[a]+"Width",!0,o):s+=w.css(e,"border"+ne[a]+"Width",!0,o));return!r&&i>=0&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-i-u-s-.5))),u}function Ge(e,t,n){var r=Me(e),o=Fe(e,t,r),i="border-box"===w.css(e,"boxSizing",!1,r),a=i;if(Le.test(o)){if(!n)return o;o="auto"}return a=a&&(p.boxSizingReliable()||o===e.style[t]),("auto"===o||!parseFloat(o)&&"inline"===w.css(e,"display",!1,r))&&(o=e["offset"+t[0].toUpperCase()+t.slice(1)],a=!0),(o=parseFloat(o)||0)+Ke(e,t,n||(i?"border":"content"),a,r,o)+"px"}function Je(e,t,n,r,o){return new Je.prototype.init(e,t,n,r,o)}w.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Fe(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,i,a,s=V(t),u=$e.test(t),c=e.style;if(u||(t=Xe(s)),a=w.cssHooks[t]||w.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(o=a.get(e,!1,r))?o:c[t];"string"==(i=typeof n)&&(o=te.exec(n))&&o[1]&&(n=ie(e,t,o),i="number"),null!=n&&n==n&&("number"===i&&(n+=o&&o[3]||(w.cssNumber[s]?"":"px")),p.clearCloneStyle||""!==n||0!==t.indexOf("background")||(c[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?c.setProperty(t,n):c[t]=n))}},css:function(e,t,n,r){var o,i,a,s=V(t);return $e.test(t)||(t=Xe(s)),(a=w.cssHooks[t]||w.cssHooks[s])&&"get"in a&&(o=a.get(e,!0,n)),void 0===o&&(o=Fe(e,t,r)),"normal"===o&&t in qe&&(o=qe[t]),""===n||n?(i=parseFloat(o),!0===n||isFinite(i)?i||0:o):o}}),w.each(["height","width"],function(e,t){w.cssHooks[t]={get:function(e,n,r){if(n)return!je.test(w.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ge(e,t,r):oe(e,ze,function(){return Ge(e,t,r)})},set:function(e,n,r){var o,i=Me(e),a="border-box"===w.css(e,"boxSizing",!1,i),s=r&&Ke(e,t,r,a,i);return a&&p.scrollboxSize()===i.position&&(s-=Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-parseFloat(i[t])-Ke(e,t,"border",!1,i)-.5)),s&&(o=te.exec(n))&&"px"!==(o[3]||"px")&&(e.style[t]=n,n=w.css(e,t)),Ye(0,n,s)}}}
vendor: 4,759 bytes, line 1
1),w.cssHooks.marginLeft=We(p.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Fe(e,"marginLeft"))||e.getBoundingClientRect().left-oe(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),w.each({margin:"",padding:"",border:"Width"},function(e,t){w.cssHooks[e+t]={expand:function(n){for(var r=0,o={},i="string"==typeof n?n.split(" "):[n];r<4;r++)o[e+ne[r]+t]=i[r]||i[r-2]||i[0];return o}},"margin"!==e&&(w.cssHooks[e+t].set=Ye)}),w.fn.extend({css:function(e,t){return $(this,function(e,t,n){var r,o,i={},a=0;if(Array.isArray(t)){for(r=Me(e),o=t.length;a<o;a++)i[t[a]]=w.css(e,t[a],!1,r);return i}return void 0!==n?w.style(e,t,n):w.css(e,t)},e,t,arguments.length>1)}}),w.Tween=Je,(Je.prototype={constructor:Je,init:function(e,t,n,r,o,i){this.elem=e,this.prop=n,this.easing=o||w.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=i||(w.cssNumber[n]?"":"px")},cur:function(){var e=Je.propHooks[this.prop];return e&&e.get?e.get(this):Je.propHooks._default.get(this)},run:function(e){var t,n=Je.propHooks[this.prop];return this.pos=t=this.options.duration?w.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):Je.propHooks._default.set(this),this}}).init.prototype=Je.prototype,(Je.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=w.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){w.fx.step[e.prop]?w.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[w.cssProps[e.prop]]&&!w.cssHooks[e.prop]?e.elem[e.prop]=e.now:w.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=Je.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},w.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},w.fx=Je.prototype.init,w.fx.step={};var Qe,Ze,et=/^(?:toggle|show|hide)$/,tt=/queueHooks$/;function nt(){Ze&&(!1===r.hidden&&e.requestAnimationFrame?e.requestAnimationFrame(nt):e.setTimeout(nt,w.fx.interval),w.fx.tick())}function rt(){return e.setTimeout(function(){Qe=void 0}),Qe=Date.now()}function ot(e,t){var n,r=0,o={height:e};for(t=t?1:0;r<4;r+=2-t)o["margin"+(n=ne[r])]=o["padding"+n]=e;return t&&(o.opacity=o.width=e),o}function it(e,t,n){for(var r,o=(at.tweeners[t]||[]).concat(at.tweeners["*"]),i=0,a=o.length;i<a;i++)if(r=o[i].call(n,t,e))return r}function at(e,t,n){var r,o,i=0,a=at.prefilters.length,s=w.Deferred().always(function(){delete u.elem}),u=function(){if(o)return!1;for(var t=Qe||rt(),n=Math.max(0,c.startTime+c.duration-t),r=1-(n/c.duration||0),i=0,a=c.tweens.length;i<a;i++)c.tweens[i].run(r);return s.notifyWith(e,[c,r,n]),r<1&&a?n:(a||s.notifyWith(e,[c,1,0]),s.resolveWith(e,[c]),!1)},c=s.promise({elem:e,props:w.extend({},t),opts:w.extend(!0,{specialEasing:{},easing:w.easing._default},n),originalProperties:t,originalOptions:n,startTime:Qe||rt(),duration:n.duration,tweens:[],createTween:function(t,n){var r=w.Tween(e,c.opts,t,n,c.opts.specialEasing[t]||c.opts.easing);return c.tweens.push(r),r},stop:function(t){var n=0,r=t?c.tweens.length:0;if(o)return this;for(o=!0;n<r;n++)c.tweens[n].run(1);return t?(s.notifyWith(e,[c,1,0]),s.resolveWith(e,[c,t])):s.rejectWith(e,[c,t]),this}}),l=c.props;for(function(e,t){var n,r,o,i,a;for(n in e)if(o=t[r=V(n)],i=e[n],Array.isArray(i)&&(o=i[1],i=e[n]=i[0]),n!==r&&(e[r]=i,delete e[n]),(a=w.cssHooks[r])&&"expand"in a)for(n in i=a.expand(i),delete e[r],i)n in e||(e[n]=i[n],t[n]=o);else t[r]=o}(l,c.opts.specialEasing);i<a;i++)if(r=at.prefilters[i].call(c,e,l,c.opts))return m(r.stop)&&(w._queueHooks(c.elem,c.opts.queue).stop=r.stop.bind(r)),r;return w.map(l,it,c),m(c.opts.start)&&c.opts.start.call(e,c),c.progress(c.opts.progress).done(c.opts.done,c.opts.complete).fail(c.opts.fail).always(c.opts.always),w.fx.timer(w.extend(u,{elem:e,anim:c,queue:c.opts.queue})),c}w.Animation=w.extend(at,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return ie(n.elem,e,te.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=["*"]):e=e.match(I);for(var n,r=0,o=e.length;r<o;r++)(at.tweeners[n=e[r]]=at.tweeners[n]||[]).unshift(t)},prefilters:[function(e,t,n){var r,o,i,a,s,u,c,l,f="width"in t||"height"in t,d=this,h={},p=e.style,m=e.nodeType&&re(e),g=K.get(e,"fxshow");for(r in n.queue||(null==(a=w._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,d.always(function(){d.always(function(){a.unqueued--,w.queue(e,"fx").length||a.empty.fire()})})),t)if(et.test(o=t[r])){if(delete t[r],i=i||"toggle"===o,o===(m?"hide":"show")){if("show"!==o||
vendor: 5,660 bytes, line 1
1!g||void 0===g[r])continue;m=!0}h[r]=g&&g[r]||w.style(e,r)}if((u=!w.isEmptyObject(t))||!w.isEmptyObject(h))for(r in f&&1===e.nodeType&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],null==(c=g&&g.display)&&(c=K.get(e,"display")),"none"===(l=w.css(e,"display"))&&(c?l=c:(ue([e],!0),c=e.style.display||c,l=w.css(e,"display"),ue([e]))),("inline"===l||"inline-block"===l&&null!=c)&&"none"===w.css(e,"float")&&(u||(d.done(function(){p.display=c}),null==c&&(c="none"===(l=p.display)?"":l)),p.display="inline-block")),n.overflow&&(p.overflow="hidden",d.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]})),u=!1,h)u||(g?"hidden"in g&&(m=g.hidden):g=K.access(e,"fxshow",{display:c}),i&&(g.hidden=!m),m&&ue([e],!0),d.done(function(){for(r in m||ue([e]),K.remove(e,"fxshow"),h)w.style(e,r,h[r])})),u=it(m?g[r]:0,r,d),r in g||(g[r]=u.start,m&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?at.prefilters.unshift(e):at.prefilters.push(e)}}),w.speed=function(e,t,n){var r=e&&"object"==typeof e?w.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return w.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration=r.duration in w.fx.speeds?w.fx.speeds[r.duration]:w.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&w.dequeue(this,r.queue)},r},w.fn.extend({fadeTo:function(e,t,n,r){return this.filter(re).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var o=w.isEmptyObject(e),i=w.speed(t,n,r),a=function(){var t=at(this,w.extend({},e),i);(o||K.get(this,"finish"))&&t.stop(!0)};return a.finish=a,o||!1===i.queue?this.each(a):this.queue(i.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&!1!==e&&this.queue(e||"fx",[]),this.each(function(){var t=!0,o=null!=e&&e+"queueHooks",i=w.timers,a=K.get(this);if(o)a[o]&&a[o].stop&&r(a[o]);else for(o in a)a[o]&&a[o].stop&&tt.test(o)&&r(a[o]);for(o=i.length;o--;)i[o].elem!==this||null!=e&&i[o].queue!==e||(i[o].anim.stop(n),t=!1,i.splice(o,1));!t&&n||w.dequeue(this,e)})},finish:function(e){return!1!==e&&(e=e||"fx"),this.each(function(){var t,n=K.get(this),r=n[e+"queue"],o=n[e+"queueHooks"],i=w.timers,a=r?r.length:0;for(n.finish=!0,w.queue(this,e,[]),o&&o.stop&&o.stop.call(this,!0),t=i.length;t--;)i[t].elem===this&&i[t].queue===e&&(i[t].anim.stop(!0),i.splice(t,1));for(t=0;t<a;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),w.each(["toggle","show","hide"],function(e,t){var n=w.fn[t];w.fn[t]=function(e,r,o){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ot(t,!0),e,r,o)}}),w.each({slideDown:ot("show"),slideUp:ot("hide"),slideToggle:ot("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){w.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),w.timers=[],w.fx.tick=function(){var e,t=0,n=w.timers;for(Qe=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||w.fx.stop(),Qe=void 0},w.fx.timer=function(e){w.timers.push(e),w.fx.start()},w.fx.interval=13,w.fx.start=function(){Ze||(Ze=!0,nt())},w.fx.stop=function(){Ze=null},w.fx.speeds={slow:600,fast:200,_default:400},w.fn.delay=function(t,n){return t=w.fx&&w.fx.speeds[t]||t,this.queue(n=n||"fx",function(n,r){var o=e.setTimeout(n,t);r.stop=function(){e.clearTimeout(o)}})},function(){var e=r.createElement("input"),t=r.createElement("select").appendChild(r.createElement("option"));e.type="checkbox",p.checkOn=""!==e.value,p.optSelected=t.selected,(e=r.createElement("input")).value="t",e.type="radio",p.radioValue="t"===e.value}();var st,ut=w.expr.attrHandle;w.fn.extend({attr:function(e,t){return $(this,w.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){w.removeAttr(this,e)})}}),w.extend({attr:function(e,t,n){var r,o,i=e.nodeType;if(3!==i&&8!==i&&2!==i)return"undefined"==typeof e.getAttribute?w.prop(e,t,n):(1===i&&w.isXMLDoc(e)||(o=w.attrHooks[t.toLowerCase()]||(w.expr.match.bool.test(t)?st:void 0)),void 0!==n?null===n?void w.removeAttr(e,t):o&&"set"in o&&void 0!==(r=o.set(e,n,t))?r:(e.setAttribute(t,n+""),n):o&&"get"in o&&null!==(r=o.get(e,t))?r:null==(r=w.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!p.radioValue&&"radio"===t&&N(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,o=t&&t.match(I);if(o&&1===e.nodeType)for(;n=o[r++];)e.removeAttribute(n)}}),st={set:function(e,t,n){return!1===t?w.removeAttr(e,n):e.setAttribute(n,n),n}},w.each(w.expr.match.bool.source.match(/\w+/g),function(e,t){var n=ut[t]||w.find.attr;ut[t]=function(e,t,r){var o,i,a=t.toLowerCase();return r||(i=ut[a],ut[a]=o,o=null!=n(e,t,r)?a:null,ut[a]=i),o}});var ct=/^(?:input|select|textarea|button)$/i,lt=/^(?:a|area)$/i;function ft(e){return(e.match(I)||[]).join(" ")}function dt(e){return e.getAttribute&&e.getAttribute("class")||""}function ht(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(I)||[]}w.fn.extend({prop:function(e,t){return $(this,w.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each(function(){delete this[w.propFix[e]||e]})}}),w.extend({prop:function(e,t,n){var r,o,i=e.nodeType;if(3!==i&&8!==i&&2!==i)return 1===i&&w.isXMLDoc(e)||(o=w.propHooks[t=w.propFix[t]||t]),void 0!==n?o&&"set"in o&&void 0!==(r=o.set(e,n,t))?r:e[t]=n:o&&"get"in o&&null!==(r=o.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=w.find.attr(e,"tabindex");return t?parseInt(t,10):ct.test(e.nodeName)||lt.test(e.nodeName)&&e.href?
vendor: 8,050 bytes, line 1
10:-1}}},propFix:{for:"htmlFor",class:"className"}}),p.optSelected||(w.propHooks.selected={get:function(e){return null},set:function(e){}}),w.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){w.propFix[this.toLowerCase()]=this}),w.fn.extend({addClass:function(e){var t,n,r,o,i,a,s,u=0;if(m(e))return this.each(function(t){w(this).addClass(e.call(this,t,dt(this)))});if((t=ht(e)).length)for(;n=this[u++];)if(o=dt(n),r=1===n.nodeType&&" "+ft(o)+" "){for(a=0;i=t[a++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");o!==(s=ft(r))&&n.setAttribute("class",s)}return this},removeClass:function(e){var t,n,r,o,i,a,s,u=0;if(m(e))return this.each(function(t){w(this).removeClass(e.call(this,t,dt(this)))});if(!arguments.length)return this.attr("class","");if((t=ht(e)).length)for(;n=this[u++];)if(o=dt(n),r=1===n.nodeType&&" "+ft(o)+" "){for(a=0;i=t[a++];)for(;r.indexOf(" "+i+" ")>-1;)r=r.replace(" "+i+" "," ");o!==(s=ft(r))&&n.setAttribute("class",s)}return this},toggleClass:function(e,t){var n=typeof e,r="string"===n||Array.isArray(e);return"boolean"==typeof t&&r?t?this.addClass(e):this.removeClass(e):m(e)?this.each(function(n){w(this).toggleClass(e.call(this,n,dt(this),t),t)}):this.each(function(){var t,o,i,a;if(r)for(o=0,i=w(this),a=ht(e);t=a[o++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else void 0!==e&&"boolean"!==n||((t=dt(this))&&K.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===e?"":K.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;for(t=" "+e+" ";n=this[r++];)if(1===n.nodeType&&(" "+ft(dt(n))+" ").indexOf(t)>-1)return!0;return!1}});var pt=/\r/g;w.fn.extend({val:function(e){var t,n,r,o=this[0];return arguments.length?(r=m(e),this.each(function(n){var o;1===this.nodeType&&(null==(o=r?e.call(this,n,w(this).val()):e)?o="":"number"==typeof o?o+="":Array.isArray(o)&&(o=w.map(o,function(e){return null==e?"":e+""})),(t=w.valHooks[this.type]||w.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,o,"value")||(this.value=o))})):o?(t=w.valHooks[o.type]||w.valHooks[o.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(o,"value"))?n:"string"==typeof(n=o.value)?n.replace(pt,""):null==n?"":n:void 0}}),w.extend({valHooks:{option:{get:function(e){var t=w.find.attr(e,"value");return null!=t?t:ft(w.text(e))}},select:{get:function(e){var t,n,r,o=e.options,i=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?i+1:o.length;for(r=i<0?u:a?i:0;r<u;r++)if(((n=o[r]).selected||r===i)&&!n.disabled&&(!n.parentNode.disabled||!N(n.parentNode,"optgroup"))){if(t=w(n).val(),a)return t;s.push(t)}return s},set:function(e,t){for(var n,r,o=e.options,i=w.makeArray(t),a=o.length;a--;)((r=o[a]).selected=w.inArray(w.valHooks.option.get(r),i)>-1)&&(n=!0);return n||(e.selectedIndex=-1),i}}}}),w.each(["radio","checkbox"],function(){w.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=w.inArray(w(e).val(),t)>-1}},p.checkOn||(w.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),p.focusin="onfocusin"in e;var mt=/^(?:focusinfocus|focusoutblur)$/,gt=function(e){e.stopPropagation()};w.extend(w.event,{trigger:function(t,n,o,i){var a,s,u,c,l,d,h,p,v=[o||r],y=f.call(t,"type")?t.type:t,b=f.call(t,"namespace")?t.namespace.split("."):[];if(s=p=u=o=o||r,3!==o.nodeType&&8!==o.nodeType&&!mt.test(y+w.event.triggered)&&(y.indexOf(".")>-1&&(y=(b=y.split(".")).shift(),b.sort()),l=y.indexOf(":")<0&&"on"+y,(t=t[w.expando]?t:new w.Event(y,"object"==typeof t&&t)).isTrigger=i?2:3,t.namespace=b.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+b.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=o),n=null==n?[t]:w.makeArray(n,[t]),h=w.event.special[y]||{},i||!h.trigger||!1!==h.trigger.apply(o,n))){if(!i&&!h.noBubble&&!g(o)){for(mt.test((c=h.delegateType||y)+y)||(s=s.parentNode);s;s=s.parentNode)v.push(s),u=s;u===(o.ownerDocument||r)&&v.push(u.defaultView||u.parentWindow||e)}for(a=0;(s=v[a++])&&!t.isPropagationStopped();)p=s,t.type=a>1?c:h.bindType||y,(d=(K.get(s,"events")||{})[t.type]&&K.get(s,"handle"))&&d.apply(s,n),(d=l&&s[l])&&d.apply&&X(s)&&(t.result=d.apply(s,n),!1===t.result&&t.preventDefault());return t.type=y,i||t.isDefaultPrevented()||h._default&&!1!==h._default.apply(v.pop(),n)||!X(o)||l&&m(o[y])&&!g(o)&&((u=o[l])&&(o[l]=null),w.event.triggered=y,t.isPropagationStopped()&&p.addEventListener(y,gt),o[y](),t.isPropagationStopped()&&p.removeEventListener(y,gt),w.event.triggered=void 0,u&&(o[l]=u)),t.result}},simulate:function(e,t,n){var r=w.extend(new w.Event,n,{type:e,isSimulated:!0});w.event.trigger(r,null,t)}}),w.fn.extend({trigger:function(e,t){return this.each(function(){w.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return w.event.trigger(e,t,n,!0)}}),p.focusin||w.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){w.event.simulate(t,e.target,w.event.fix(e))};w.event.special[t]={setup:function(){var r=this.ownerDocument||this,o=K.access(r,t);o||r.addEventListener(e,n,!0),K.access(r,t,(o||0)+1)},teardown:function(){var r=this.ownerDocument||this,o=K.access(r,t)-1;o?K.access(r,t,o):(r.removeEventListener(e,n,!0),K.remove(r,t))}}});var vt=e.location,yt=Date.now(),bt=/\?/;w.parseXML=function(t){var n;if(!t||"string"!=typeof t)return null;try{n=(new e.DOMParser).parseFromString(t,"text/xml")}catch(e){n=void 0}return n&&!n.getElementsByTagName("parsererror").length||w.error("Invalid XML: "+t),n};var wt=/\[\]$/,xt=/\r?\n/g,Ct=/^(?:submit|button|image|reset|file)$/i,St=/^(?:input|select|textarea|keygen)/i;function Tt(e,t,n,r){var o;if(Array.isArray(t))w.each(t,function(t,o){n||wt.test(e)?r(e,o):Tt(e+"["+("object"==typeof o&&null!=o?t:"")+"]",o,n,r)});else if(n||"object"!==b(t))r(e,t);else for(o in t)Tt(e+"["+o+"]",t[o],n,r)}w.param=function(e,t){var n,r=[],o=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(Array.isArray(e)||e.jquery&&!w.isPlainObject(e))w.each(e,function(){o(this.name,this.value)});else for(n in e)Tt(n,e[n],t,o);return r.join("&")},w.fn.extend({serialize:function(){return w.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=w.prop(this,"elements");return e?w.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!w(this).is(":disabled")&&St.test(this.nodeName)&&!Ct.test(e)&&(this.checked||!ce.test(e))}).map(function(e,t){var n=w(this).val();return null==n?null:Array.isArray(n)?w.map(n,function(e){return{name:t.name,value:e.replace(xt,"\r\n")}}):{name:t.name,value:n.replace(xt,"\r\n")}}).get()}});var Et=/%20/g,kt=/#.*$/,Nt=/([?&])_=[^&]*/,Rt=/^(.*?):[ \t]*([^\r\n]*)$/gm,_t=/^(?:GET|HEAD)$/,At=/^\/\//,Dt={},Ot={},Pt="*/".concat("*"),Bt=r.createElement("a");function It(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,o=0,i=t.toLowerCase().match(I)||[];if(m(n))for(;r=i[o++];)"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function Lt(e,t,n,r){var o={},i=e===Ot;function a(s){var u;return o[s]=!0,w.each(e[s]||[],function(e,s){var c=s(t,n,r);return"string"!=typeof c||i||o[c]?i?!(u=c):void 0:(t.dataTypes.unshift(c),a(c),!1)}),u}return a(t.dataTypes[0])||!o["*"]&&a("*")}function Mt(e,t){var n,r,o=w.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((o[n]?e:r||(r={}))[n]=t[n]);return r&&w.extend(!0,e,r),e}Bt.href=vt.href,w.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:vt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(vt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Pt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":w.parseXML}
vendor: 4,099 bytes, line 1
1,flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?Mt(Mt(e,w.ajaxSettings),t):Mt(w.ajaxSettings,e)},ajaxPrefilter:It(Dt),ajaxTransport:It(Ot),ajax:function(t,n){"object"==typeof t&&(n=t,t=void 0);var o,i,a,s,u,c,l,f,d,h,p=w.ajaxSetup({},n=n||{}),m=p.context||p,g=p.context&&(m.nodeType||m.jquery)?w(m):w.event,v=w.Deferred(),y=w.Callbacks("once memory"),b=p.statusCode||{},x={},C={},S="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(l){if(!s)for(s={};t=Rt.exec(a);)s[t[1].toLowerCase()]=t[2];t=s[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return l?a:null},setRequestHeader:function(e,t){return null==l&&(e=C[e.toLowerCase()]=C[e.toLowerCase()]||e,x[e]=t),this},overrideMimeType:function(e){return null==l&&(p.mimeType=e),this},statusCode:function(e){var t;if(e)if(l)T.always(e[T.status]);else for(t in e)b[t]=[b[t],e[t]];return this},abort:function(e){var t=e||S;return o&&o.abort(t),E(0,t),this}};if(v.promise(T),p.url=((t||p.url||vt.href)+"").replace(At,vt.protocol+"//"),p.type=n.method||n.type||p.method||p.type,p.dataTypes=(p.dataType||"*").toLowerCase().match(I)||[""],null==p.crossDomain){c=r.createElement("a");try{c.href=p.url,c.href=c.href,p.crossDomain=Bt.protocol+"//"+Bt.host!=c.protocol+"//"+c.host}catch(e){p.crossDomain=!0}}if(p.data&&p.processData&&"string"!=typeof p.data&&(p.data=w.param(p.data,p.traditional)),Lt(Dt,p,n,T),l)return T;for(d in(f=w.event&&p.global)&&0==w.active++&&w.event.trigger("ajaxStart"),p.type=p.type.toUpperCase(),p.hasContent=!_t.test(p.type),i=p.url.replace(kt,""),p.hasContent?p.data&&p.processData&&0===(p.contentType||"").indexOf("application/x-www-form-urlencoded")&&(p.data=p.data.replace(Et,"+")):(h=p.url.slice(i.length),p.data&&(p.processData||"string"==typeof p.data)&&(i+=(bt.test(i)?"&":"?")+p.data,delete p.data),!1===p.cache&&(i=i.replace(Nt,"$1"),h=(bt.test(i)?"&":"?")+"_="+yt+++h),p.url=i+h),p.ifModified&&(w.lastModified[i]&&T.setRequestHeader("If-Modified-Since",w.lastModified[i]),w.etag[i]&&T.setRequestHeader("If-None-Match",w.etag[i])),(p.data&&p.hasContent&&!1!==p.contentType||n.contentType)&&T.setRequestHeader("Content-Type",p.contentType),T.setRequestHeader("Accept",p.dataTypes[0]&&p.accepts[p.dataTypes[0]]?p.accepts[p.dataTypes[0]]+("*"!==p.dataTypes[0]?", "+Pt+"; q=0.01":""):p.accepts["*"]),p.headers)T.setRequestHeader(d,p.headers[d]);if(p.beforeSend&&(!1===p.beforeSend.call(m,T,p)||l))return T.abort();if(S="abort",y.add(p.complete),T.done(p.success),T.fail(p.error),o=Lt(Ot,p,n,T)){if(T.readyState=1,f&&g.trigger("ajaxSend",[T,p]),l)return T;p.async&&p.timeout>0&&(u=e.setTimeout(function(){T.abort("timeout")},p.timeout));try{l=!1,o.send(x,E)}catch(e){if(l)throw e;E(-1,e)}}else E(-1,"No Transport");function E(t,n,r,s){var c,d,h,x,C,S=n;l||(l=!0,u&&e.clearTimeout(u),o=void 0,a=s||"",T.readyState=t>0?4:0,c=t>=200&&t<300||304===t,r&&(x=function(e,t,n){for(var r,o,i,a,s=e.contents,u=e.dataTypes;"*"===u[0];)u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(o in s)if(s[o]&&s[o].test(r)){u.unshift(o);break}if(u[0]in n)i=u[0];else{for(o in n){if(!u[0]||e.converters[o+" "+u[0]]){i=o;break}a||(a=o)}i=i||a}if(i)return i!==u[0]&&u.unshift(i),n[i]}(p,T,r)),x=function(e,t,n,r){var o,i,a,s,u,c={},l=e.dataTypes.slice();if(l[1])for(a in e.converters)c[a.toLowerCase()]=e.converters[a];for(i=l.shift();i;)if(e.responseFields[i]&&(n[e.responseFields[i]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=i,i=l.shift())if("*"===i)i=u;else if("*"!==u&&u!==i){if(!(a=c[u+" "+i]||c["* "+i]))for(o in c)if((s=o.split(" "))[1]===i&&(a=c[u+" "+s[0]]||c["* "+s[0]])){!0===a?a=c[o]:!0!==c[o]&&(i=s[0],l.unshift(s[1]));break}if(!0!==a)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+i}}}return{state:"success",data:t}}(p,x,T,c),c?(p.ifModified&&((C=T.getResponseHeader("Last-Modified"))&&(w.lastModified[i]=C),(C=T.getResponseHeader("etag"))&&(w.etag[i]=C)),204===t||"HEAD"===p.type?S="nocontent":304===t?S="notmodified":(S=x.state,d=x.data,c=!(h=x.error))):(h=S,
vendor: 3,814 bytes, line 1
1!t&&S||(S="error",t<0&&(t=0))),T.status=t,T.statusText=(n||S)+"",c?v.resolveWith(m,[d,S,T]):v.rejectWith(m,[T,S,h]),T.statusCode(b),b=void 0,f&&g.trigger(c?"ajaxSuccess":"ajaxError",[T,p,c?d:h]),y.fireWith(m,[T,S]),f&&(g.trigger("ajaxComplete",[T,p]),--w.active||w.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return w.get(e,t,n,"json")},getScript:function(e,t){return w.get(e,void 0,t,"script")}}),w.each(["get","post"],function(e,t){w[t]=function(e,n,r,o){return m(n)&&(o=o||r,r=n,n=void 0),w.ajax(w.extend({url:e,type:t,dataType:o,data:n,success:r},w.isPlainObject(e)&&e))}}),w._evalUrl=function(e){return w.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},w.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=w(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(e){return m(e)?this.each(function(t){w(this).wrapInner(e.call(this,t))}):this.each(function(){var t=w(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=m(e);return this.each(function(n){w(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(e){return this.parent(e).not("body").each(function(){w(this).replaceWith(this.childNodes)}),this}}),w.expr.pseudos.hidden=function(e){return!w.expr.pseudos.visible(e)},w.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},w.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch(e){}};var Ht={0:200,1223:204},Ft=w.ajaxSettings.xhr();p.cors=!!Ft&&"withCredentials"in Ft,p.ajax=Ft=!!Ft,w.ajaxTransport(function(t){var n,r;if(p.cors||Ft&&!t.crossDomain)return{send:function(o,i){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];for(a in t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||o["X-Requested-With"]||(o["X-Requested-With"]="XMLHttpRequest"),o)s.setRequestHeader(a,o[a]);n=function(e){return function(){n&&(n=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===e?s.abort():"error"===e?"number"!=typeof s.status?i(0,"error"):i(s.status,s.statusText):i(Ht[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=n(),r=s.onerror=s.ontimeout=n("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&e.setTimeout(function(){n&&r()})},n=n("abort");try{s.send(t.hasContent&&t.data||null)}catch(e){if(n)throw e}},abort:function(){n&&n()}}}),w.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),w.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return w.globalEval(e),e}}}),w.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),w.ajaxTransport("script",function(e){var t,n;if(e.crossDomain)return{send:function(o,i){t=w("<script>").prop({charset:e.scriptCharset,src:e.url}).on("load error",n=function(e){t.remove(),n=null,e&&i("error"===e.type?404:200,e.type)}),r.head.appendChild(t[0])},abort:function(){n&&n()}}});var Wt=[],jt=/(=)\?(?=&|$)|\?\?/;w.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Wt.pop()||w.expando+"_"+yt++;return this[e]=!0,e}}),w.ajaxPrefilter("json jsonp",function(t,n,r){var o,i,a,s=!1!==t.jsonp&&(jt.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&jt.test(t.data)&&"data");
vendor: 4,755 bytes, line 1
1if(s||"jsonp"===t.dataTypes[0])return o=t.jsonpCallback=m(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(jt,"$1"+o):!1!==t.jsonp&&(t.url+=(bt.test(t.url)?"&":"?")+t.jsonp+"="+o),t.converters["script json"]=function(){return a||w.error(o+" was not called"),a[0]},t.dataTypes[0]="json",i=e[o],e[o]=function(){a=arguments},r.always(function(){void 0===i?w(e).removeProp(o):e[o]=i,t[o]&&(t.jsonpCallback=n.jsonpCallback,Wt.push(o)),a&&m(i)&&i(a[0]),a=i=void 0}),"script"}),p.createHTMLDocument=function(){var e=r.implementation.createHTMLDocument("").body;return e.innerHTML="<form></form><form></form>",2===e.childNodes.length}(),w.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(p.createHTMLDocument?((o=(t=r.implementation.createHTMLDocument("")).createElement("base")).href=r.location.href,t.head.appendChild(o)):t=r),i=R.exec(e),a=!n&&[],i?[t.createElement(i[1])]:(i=ge([e],t,a),a&&a.length&&w(a).remove(),w.merge([],i.childNodes)));var o,i,a},w.fn.load=function(e,t,n){var r,o,i,a=this,s=e.indexOf(" ");return s>-1&&(r=ft(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&"object"==typeof t&&(o="POST"),a.length>0&&w.ajax({url:e,type:o||"GET",dataType:"html",data:t}).done(function(e){i=arguments,a.html(r?w("<div>").append(w.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,i||[e.responseText,t,e])})}),this},w.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){w.fn[t]=function(e){return this.on(t,e)}}),w.expr.pseudos.animated=function(e){return w.grep(w.timers,function(t){return e===t.elem}).length},w.offset={setOffset:function(e,t,n){var r,o,i,a,s,u,c=w.css(e,"position"),l=w(e),f={};"static"===c&&(e.style.position="relative"),s=l.offset(),i=w.css(e,"top"),u=w.css(e,"left"),("absolute"===c||"fixed"===c)&&(i+u).indexOf("auto")>-1?(a=(r=l.position()).top,o=r.left):(a=parseFloat(i)||0,o=parseFloat(u)||0),m(t)&&(t=t.call(e,n,w.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+o),"using"in t?t.using.call(e,f):l.css(f)}},w.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){w.offset.setOffset(this,e,t)});var t,n,r=this[0];return r?r.getClientRects().length?{top:(t=r.getBoundingClientRect()).top+(n=r.ownerDocument.defaultView).pageYOffset,left:t.left+n.pageXOffset}:{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],o={top:0,left:0};if("fixed"===w.css(r,"position"))t=r.getBoundingClientRect();else{for(t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;e&&(e===n.body||e===n.documentElement)&&"static"===w.css(e,"position");)e=e.parentNode;e&&e!==r&&1===e.nodeType&&((o=w(e).offset()).top+=w.css(e,"borderTopWidth",!0),o.left+=w.css(e,"borderLeftWidth",!0))}return{top:t.top-o.top-w.css(r,"marginTop",!0),left:t.left-o.left-w.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent;e&&"static"===w.css(e,"position");)e=e.offsetParent;return e||ve})}}),w.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n="pageYOffset"===t;w.fn[e]=function(r){return $(this,function(e,r,o){var i;if(g(e)?i=e:9===e.nodeType&&(i=e.defaultView),void 0===o)return i?i[t]:e[r];i?i.scrollTo(n?i.pageXOffset:o,n?o:i.pageYOffset):e[r]=o},e,r,arguments.length)}}),w.each(["top","left"],function(e,t){w.cssHooks[t]=We(p.pixelPosition,function(e,n){if(n)return n=Fe(e,t),Le.test(n)?w(e).position()[t]+"px":n})}),w.each({Height:"height",Width:"width"},function(e,t){w.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){w.fn[r]=function(o,i){var a=arguments.length&&(n||"boolean"!=typeof o),s=n||(!0===o||!0===i?"margin":"border");return $(this,function(t,n,o){var i;return g(t)?0===r.indexOf("outer")?t["inner"+e]:t.document.documentElement["client"+e]:9===t.nodeType?(i=t.documentElement,Math.max(t.body["scroll"+e],i["scroll"+e],t.body["offset"+e],i["offset"+e],i["client"+e])):void 0===o?w.css(t,n,s):w.style(t,n,o,s)},t,a?o:void 0,a)}})}),w.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,t){w.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),w.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),w.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),w.proxy=function(e,t){var n,r,o;
1if("string"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=i.call(arguments,2),(o=function(){return e.apply(t||this,r.concat(i.call(arguments)))}).guid=e.guid=e.guid||w.guid++,o},w.holdReady=function(e){e?w.readyWait++:w.ready(!0)},w.isArray=Array.isArray,w.parseJSON=JSON.parse,w.nodeName=N,w.isFunction=m,w.isWindow=g,w.camelCase=V,w.type=b,w.now=Date.now,w.isNumeric=function(e){var t=w.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},"function"==typeof define&&define.amd&&define("jquery",[],function(){return w});var $t=e.jQuery,zt=e.$;return w.noConflict=function(t){return e.$===w&&(e.$=zt),t&&e.jQuery===w&&(e.jQuery=$t),w},t||(e.jQuery=e.$=w),w}),function(e,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t(require,exports,module):e.Tether=t()}(this,function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e){var t=e.getBoundingClientRect(),n={};for(var r in t)n[r]=t[r];if(e.ownerDocument!==document){var i=e.ownerDocument.defaultView.frameElement;if(i){var a=o(i);n.top+=a.top,n.bottom+=a.top,n.left+=a.left,n.right+=a.left}}return n}function i(e){var t=(getComputedStyle(e)||{}).position,n=[];if("fixed"===t)return[e];for(var r=e;(r=r.parentNode)&&r&&1===r.nodeType;){var o=void 0;try{o=getComputedStyle(r)}catch(e){}if("undefined"==typeof o||null===o)return n.push(r),n;/(auto|scroll|overlay)/.test(o.overflow+o.overflowY+o.overflowX)&&("absolute"!==t||["relative","absolute","fixed"].indexOf(o.position)>=0)&&n.push(r)}return n.push(e.ownerDocument.body),e.ownerDocument!==document&&n.push(e.ownerDocument.defaultView),n}function a(){T&&document.body.removeChild(T),T=null}function s(e){var t=void 0;e===document?(t=document,e=document.documentElement):t=e.ownerDocument;var n=t.documentElement,r=o(e),i=N();return r.top-=i.top,r.left-=i.left,"undefined"==typeof r.width&&(r.width=document.body.scrollWidth-r.left-r.right),"undefined"==typeof r.height&&(r.height=document.body.scrollHeight-r.top-r.bottom),r.top=r.top-n.clientTop,r.left=r.left-n.clientLeft,r.right=t.body.clientWidth-r.width-r.left,r.bottom=t.body.clientHeight-r.height-r.top,r}function u(e){return e.offsetParent||document.documentElement}function c(){if(R)return R;var e=document.createElement("div");e.style.width="100%",e.style.height="200px";var t=document.createElement("div");l(t.style,{position:"absolute",top:0,left:0,pointerEvents:"none",visibility:"hidden",width:"200px",height:"150px",overflow:"hidden"}),t.appendChild(e),document.body.appendChild(t);var n=e.offsetWidth;t.style.overflow="scroll";var r=e.offsetWidth;n===r&&(r=t.clientWidth),document.body.removeChild(t);var o=n-r;return R={width:o,height:o}}function l(){var e=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],t=[];return Array.prototype.push.apply(t,arguments),t.slice(1).forEach(function(t){if(t)for(var n in t)({}).hasOwnProperty.call(t,n)&&(e[n]=t[n])}),e}function f(e,t){if("undefined"!=typeof e.classList)t.split(" ").forEach(function(t){t.trim()&&e.classList.remove(t)});else{var n=new RegExp("(^| )"+t.split(" ").join("|")+"( |$)","gi"),r=p(e).replace(n," ");m(e,r)}}function d(e,t){if("undefined"!=typeof e.classList)t.split(" ").forEach(function(t){t.trim()&&e.classList.add(t)});else{f(e,t);var n=p(e)+" "+t;m(e,n)}}function h(e,t){if("undefined"!=typeof e.classList)return e.classList.contains(t);var n=p(e);return new RegExp("(^| )"+t+"( |$)","gi").test(n)}function p(e){return e.className instanceof e.ownerDocument.defaultView.SVGAnimatedString?e.className.baseVal:e.className}function m(e,t){e.setAttribute("class",t)}function g(e,t,n){n.forEach(function(n){-1===t.indexOf(n)&&h(e,n)&&f(e,n)}),t.forEach(function(t){h(e,t)||d(e,t)})}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function v(e,t){var n=arguments.length<=2||void 0===arguments[2]?1:arguments[2];return e+n>=t&&t>=e-n}function y(){return"object"==typeof performance&&"function"==typeof performance.now?performance.now():+new Date}function b(){for(var e={top:0,left:0},t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];
1return n.forEach(function(t){var n=t.top,r=t.left;"string"==typeof n&&(n=parseFloat(n,10)),"string"==typeof r&&(r=parseFloat(r,10)),e.top+=n,e.left+=r}),e}function w(e,t){return"string"==typeof e.left&&-1!==e.left.indexOf("%")&&(e.left=parseFloat(e.left,10)/100*t.width),"string"==typeof e.top&&-1!==e.top.indexOf("%")&&(e.top=parseFloat(e.top,10)/100*t.height),e}function x(e,t){return"scrollParent"===t?t=e.scrollParents[0]:"window"===t&&(t=[pageXOffset,pageYOffset,innerWidth+pageXOffset,innerHeight+pageYOffset]),t===document&&(t=t.documentElement),"undefined"!=typeof t.nodeType&&function(){var e=t,n=s(t),r=n,o=getComputedStyle(t);if(t=[r.left,r.top,n.width+r.left,n.height+r.top],e.ownerDocument!==document){var i=e.ownerDocument.defaultView;t[0]+=i.pageXOffset,t[1]+=i.pageYOffset,t[2]+=i.pageXOffset,t[3]+=i.pageYOffset}V.forEach(function(e,n){"Top"===(e=e[0].toUpperCase()+e.substr(1))||"Left"===e?t[n]+=parseFloat(o["border"+e+"Width"]):t[n]-=parseFloat(o["border"+e+"Width"])})}(),t}var C=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),S=void 0;"undefined"==typeof S&&(S={modules:[]});var T=null,E=function(){var e=0;return function(){return++e}}(),k={},N=function(){var e=T;e&&document.body.contains(e)||((e=document.createElement("div")).setAttribute("data-tether-id",E()),l(e.style,{top:0,left:0,position:"absolute"}),document.body.appendChild(e),T=e);var t=e.getAttribute("data-tether-id");return"undefined"==typeof k[t]&&(k[t]=o(e),A(function(){delete k[t]})),k[t]},R=null,_=[],A=function(e){_.push(e)},D=function(){for(var e=void 0;e=_.pop();)e()},O=function(){function e(){r(this,e)}return C(e,[{key:"on",value:function(e,t,n){var r=!(arguments.length<=3||void 0===arguments[3])&&arguments[3];"undefined"==typeof this.bindings&&(this.bindings={}),"undefined"==typeof this.bindings[e]&&(this.bindings[e]=[]),this.bindings[e].push({handler:t,ctx:n,once:r})}},{key:"once",value:function(e,t,n){this.on(e,t,n,!0)}},{key:"off",value:function(e,t){if("undefined"!=typeof this.bindings&&"undefined"!=typeof this.bindings[e])if("undefined"==typeof t)delete this.bindings[e];else for(var n=0;n<this.bindings[e].length;)this.bindings[e][n].handler===t?this.bindings[e].splice(n,1):++n}},{key:"trigger",value:function(e){if("undefined"!=typeof this.bindings&&this.bindings[e]){for(var t=0,n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];for(;t<this.bindings[e].length;){var i=this.bindings[e][t],a=i.once,s=i.ctx;"undefined"==typeof s&&(s=this),i.handler.apply(s,r),a?this.bindings[e].splice(t,1):++t}}}}]),e}();S.Utils={getActualBoundingClientRect:o,getScrollParents:i,getBounds:s,getOffsetParent:u,extend:l,addClass:d,removeClass:f,hasClass:h,updateClasses:g,defer:A,flush:D,uniqueId:E,Evented:O,getScrollBarSize:c,removeUtilElements:a};var P=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{!r&&s.return&&s.return()}finally{if(o)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},B=(C=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),function(e,t,n){for(var r=!0;r;){var o=e,i=t,a=n;r=!1,null===o&&(o=Function.prototype);var s=Object.getOwnPropertyDescriptor(o,i);if(void 0!==s){if("value"in s)return s.value;var u=s.get;if(void 0===u)return;return u.call(a)}var c=Object.getPrototypeOf(o);if(null===c)return;e=c,t=i,n=a,r=!0,s=c=void 0}});if("undefined"==typeof S)throw new Error("You must include the utils.js file before tether.js");var i=(X=S.Utils).getScrollParents,u=(s=X.getBounds,X.getOffsetParent),d=(l=X.extend,X.addClass),f=X.removeClass,c=(g=X.updateClasses,A=X.defer,D=X.flush,X.getScrollBarSize),a=X.removeUtilElements,I=function(){if("undefined"==typeof document)return"";for(var e=document.createElement("div"),t=["transform","WebkitTransform","OTransform","MozTransform","msTransform"],n=0;n<t.length;++n){var r=t[n];if(void 0!==e.style[r])return r}}
1(),L=[],M=function(){L.forEach(function(e){e.position(!1)}),D()};!function(){var e=null,t=null,n=null,r=function r(){return"undefined"!=typeof t&&t>16?(t=Math.min(t-16,250),void(n=setTimeout(r,250))):void("undefined"!=typeof e&&y()-e<10||(null!=n&&(clearTimeout(n),n=null),e=y(),M(),t=y()-e))};"undefined"!=typeof window&&"undefined"!=typeof window.addEventListener&&["resize","scroll","touchmove"].forEach(function(e){window.addEventListener(e,r)})}();var H={center:"center",left:"right",right:"left"},F={middle:"middle",top:"bottom",bottom:"top"},W={top:0,left:0,middle:"50%",center:"50%",bottom:"100%",right:"100%"},j=function(e){var t=e.left,n=e.top;return"undefined"!=typeof W[e.left]&&(t=W[e.left]),"undefined"!=typeof W[e.top]&&(n=W[e.top]),{left:t,top:n}},$=function(e){var t=e.split(" "),n=P(t,2);return{top:n[0],left:n[1]}},z=$,q=function(e){function t(e){var n=this;r(this,t),B(Object.getPrototypeOf(t.prototype),"constructor",this).call(this),this.position=this.position.bind(this),L.push(this),this.history=[],this.setOptions(e,!1),S.modules.forEach(function(e){"undefined"!=typeof e.initialize&&e.initialize.call(n)}),this.position()}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,O),C(t,[{key:"getClass",value:function(){var e=arguments.length<=0||void 0===arguments[0]?"":arguments[0],t=this.options.classes;return"undefined"!=typeof t&&t[e]?this.options.classes[e]:this.options.classPrefix?this.options.classPrefix+"-"+e:e}},{key:"setOptions",value:function(e){var t=this,n=arguments.length<=1||void 0===arguments[1]||arguments[1];this.options=l({offset:"0 0",targetOffset:"0 0",targetAttachment:"auto auto",classPrefix:"tether"},e);var r=this.options,o=r.target,a=r.targetModifier;if(this.element=r.element,this.target=o,this.targetModifier=a,"viewport"===this.target?(this.target=document.body,this.targetModifier="visible"):"scroll-handle"===this.target&&(this.target=document.body,this.targetModifier="scroll-handle"),["element","target"].forEach(function(e){if("undefined"==typeof t[e])throw new Error("Tether Error: Both element and target must be defined");"undefined"!=typeof t[e].jquery?t[e]=t[e][0]:"string"==typeof t[e]&&(t[e]=document.querySelector(t[e]))}),d(this.element,this.getClass("element")),!1!==this.options.addTargetClasses&&d(this.target,this.getClass("target")),!this.options.attachment)throw new Error("Tether Error: You must provide an attachment");this.targetAttachment=z(this.options.targetAttachment),this.attachment=z(this.options.attachment),this.offset=$(this.options.offset),this.targetOffset=$(this.options.targetOffset),"undefined"!=typeof this.scrollParents&&this.disable(),this.scrollParents="scroll-handle"===this.targetModifier?[this.target]:i(this.target),!1!==this.options.enabled&&this.enable(n)}},{key:"getTargetBounds",value:function(){if("undefined"==typeof this.targetModifier)return s(this.target);if("visible"===this.targetModifier)return this.target===document.body?{top:pageYOffset,left:pageXOffset,height:innerHeight,width:innerWidth}:((i={height:(e=s(this.target)).height,width:e.width,top:e.top,left:e.left}).height=Math.min(i.height,e.height-(pageYOffset-e.top)),i.height=Math.min(i.height,e.height-(e.top+e.height-(pageYOffset+innerHeight))),i.height=Math.min(innerHeight,i.height),i.height-=2,i.width=Math.min(i.width,e.width-(pageXOffset-e.left)),i.width=Math.min(i.width,e.width-(e.left+e.width-(pageXOffset+innerWidth))),i.width=Math.min(innerWidth,i.width),i.width-=2,i.top<pageYOffset&&(i.top=pageYOffset),i.left<pageXOffset&&(i.left=pageXOffset),i);if("scroll-handle"===this.targetModifier){var e=void 0,t=this.target;t===document.body?(t=document.documentElement,e={left:pageXOffset,top:pageYOffset,height:innerHeight,width:innerWidth}):e=s(t);var n=getComputedStyle(t),r=0;(t.scrollWidth>t.clientWidth||[n.overflow,n.overflowX].indexOf("scroll")>=0||this.target!==document.body)&&(r=15);var o=e.height-parseFloat(n.borderTopWidth)-parseFloat(n.borderBottomWidth)-r,i={width:15,height:.975*o*(o/t.scrollHeight),left:e.left+e.width-parseFloat(n.borderLeftWidth)-15},a=0;return o<408&&this.target===document.body&&(a=-11e-5*Math.pow(o,2)-.00727*o+22.58),this.target!==document.body&&(i.height=Math.max(i.height,24)),i.top=this.target.scrollTop/(t.scrollHeight-o)*(o-i.height-a)+e.top+parseFloat(n.borderTopWidth),this.target===document.body&&(i.height=Math.max(i.height,24)),i}}},{key:"clearCache",value:function(){this._cache={}}},{key:"cache",value:function(e,t){return"undefined"==typeof this._cache&&(this._cache={}),"undefined"==typeof this._cache[e]&&(this._cache[e]=t.call(this)),this._cache[e]}},{key:"enable",value:function(){var e=this,t=arguments.length<=0||void 0===arguments[0]||arguments[0];!1!==this.options.addTargetClasses&&d(this.target,this.getClass("enabled")),d(this.element,this.getClass("enabled")),this.enabled=!0,this.scrollParents.forEac
1h(function(t){t!==e.target.ownerDocument&&t.addEventListener("scroll",e.position)}),t&&this.position()}},{key:"disable",value:function(){var e=this;f(this.target,this.getClass("enabled")),f(this.element,this.getClass("enabled")),this.enabled=!1,"undefined"!=typeof this.scrollParents&&this.scrollParents.forEach(function(t){t.removeEventListener("scroll",e.position)})}},{key:"destroy",value:function(){var e=this;this.disable(),L.forEach(function(t,n){t===e&&L.splice(n,1)}),0===L.length&&a()}},{key:"updateAttachClasses",value:function(e,t){var n=this;e=e||this.attachment,t=t||this.targetAttachment,"undefined"!=typeof this._addAttachClasses&&this._addAttachClasses.length&&this._addAttachClasses.splice(0,this._addAttachClasses.length),"undefined"==typeof this._addAttachClasses&&(this._addAttachClasses=[]);var r=this._addAttachClasses;e.top&&r.push(this.getClass("element-attached")+"-"+e.top),e.left&&r.push(this.getClass("element-attached")+"-"+e.left),t.top&&r.push(this.getClass("target-attached")+"-"+t.top),t.left&&r.push(this.getClass("target-attached")+"-"+t.left);var o=[];["left","top","bottom","right","middle","center"].forEach(function(e){o.push(n.getClass("element-attached")+"-"+e),o.push(n.getClass("target-attached")+"-"+e)}),A(function(){"undefined"!=typeof n._addAttachClasses&&(g(n.element,n._addAttachClasses,o),!1!==n.options.addTargetClasses&&g(n.target,n._addAttachClasses,o),delete n._addAttachClasses)})}},{key:"position",value:function(){var e=this,t=arguments.length<=0||void 0===arguments[0]||arguments[0];if(this.enabled){this.clearCache();var n=function(e,t){var n=e.left,r=e.top;return"auto"===n&&(n=H[t.left]),"auto"===r&&(r=F[t.top]),{left:n,top:r}}(this.targetAttachment,this.attachment);this.updateAttachClasses(this.attachment,n);var r=this.cache("element-bounds",function(){return s(e.element)}),o=r.width,i=r.height;if(0===o&&0===i&&"undefined"!=typeof this.lastSize){var a=this.lastSize;o=a.width,i=a.height}else this.lastSize={width:o,height:i};var l=this.cache("target-bounds",function(){return e.getTargetBounds()}),f=l,d=w(j(this.attachment),{width:o,height:i}),h=w(j(n),f),p=w(this.offset,{width:o,height:i}),m=w(this.targetOffset,f);d=b(d,p),h=b(h,m);for(var g=l.left+h.left-d.left,v=l.top+h.top-d.top,y=0;y<S.modules.length;++y){var x=S.modules[y].position.call(this,{left:g,top:v,targetAttachment:n,targetPos:l,elementPos:r,offset:d,targetOffset:h,manualOffset:p,manualTargetOffset:m,scrollbarSize:k,attachment:this.attachment});if(!1===x)return!1;"undefined"!=typeof x&&"object"==typeof x&&(v=x.top,g=x.left)}var C={page:{top:v,left:g},viewport:{top:v-pageYOffset,bottom:pageYOffset-v-i+innerHeight,left:g-pageXOffset,right:pageXOffset-g-o+innerWidth}},T=this.target.ownerDocument,E=T.defaultView,k=void 0;return E.innerHeight>T.documentElement.clientHeight&&(k=this.cache("scrollbar-size",c),C.viewport.bottom-=k.height),E.innerWidth>T.documentElement.clientWidth&&(k=this.cache("scrollbar-size",c),C.viewport.right-=k.width),-1!==["","static"].indexOf(T.body.style.position)&&-1!==["","static"].indexOf(T.body.parentElement.style.position)||(C.page.bottom=T.body.scrollHeight-v-i,C.page.right=T.body.scrollWidth-g-o),"undefined"!=typeof this.options.optimizations&&!1!==this.options.optimizations.moveElement&&"undefined"==typeof this.targetModifier&&function(){var t=e.cache("target-offsetparent",function(){return u(e.target)}),n=e.cache("target-offsetparent-bounds",function(){return s(t)}),r=getComputedStyle(t),o=n,i={};["Top","Left","Bottom","Right"].forEach(function(e){i[e.toLowerCase()]=parseFloat(r["border"+e+"Width"])}),n.right=T.body.scrollWidth-n.left-o.width+i.right,n.bottom=T.body.scrollHeight-n.top-o.height+i.bottom,C.page.top>=n.top+i.top&&C.page.bottom>=n.bottom&&C.page.left>=n.left+i.left&&C.page.right>=n.right&&(C.offset={top:C.page.top-n.top+t.scrollTop-i.top,left:C.page.left-n.left+t.scrollLeft-i.left})}(),this.move(C),this.history.unshift(C),this.history.length>3&&this.history.pop(),t&&D(),!0}}},{key:"move",value:function(e){var t=this;if("undefined"!=typeof this.element.parentNode){var n={};for(var r in e)for(var o in n[r]={},e[r]){for(var i=!1,a=0;a<this.history.length;++a){var s=this.history[a];if("undefined"!=typeof s[r]&&!v(s[r][o],e[r][o])){i=!0;break}}i||(n[r][o]=!0)}var c={top:"",left:"",right:"",bottom:""},f=function(e,n){if(!1!==("undefined"!=typeof t.options.optimizations?t.options.optimizations.gpu:null)){var r=void 0,o=void 0;e.top?(c.top=0,r=n.top):(c.bottom=0,r=-n.bottom),e.left?(c.left=0,o=n.left):(c.right=0,o=-n.right),window.matchMedia&&(window.matchMedia("only screen and (min-resolution: 1.3dppx)").matches||window.matchMedia("only screen and (-webkit-min-device-pixel-ratio: 1.3)").matches||(o=Math.round(o),r=Math.round(r))),c[I]="translateX("+o+"px) translateY("+r+"px)","msTransform"!==I&&(c[I]+=" translateZ(0)")}else e.top?c.top=n.top+"px":c.bottom=n.bottom+"px",e.left?c.left=n.left+"px":c.right=n.right+"px"},d=!1;if((n.page.top||n.page.bottom)&&(n.page.left||n.page.right)?(c.position="absolute",f(n.page,e.page)):(n.viewport.top||n.viewport.bottom)&&(n.viewport.left||n.viewport.right)?(c.position="fixed",f(n.viewport,e.viewport)):"undefined"!=typeof n.offset&&n.offset.top&&n.offset.left?function(){c.position="absolute";var r=t.cache("target-offsetparent",function(){return u(t.target)});u(t.element)!==r&&A(function(){t.element.parentNode.removeChild(t.element),r.appendChild(t.element)}),f(n.offset,e.offset),d=!0}():(c.position="absolute",f({top:!0,left:!0},e.page)),!d)if(this.options.bodyElement)this.element.parentNode!==this.options.bodyElement&&this.options.bodyElement.appendChild(this.element);else{for(var h=!0,p=this.element.parentNode;p&&1===p.nodeType&&"BODY"!==p.tagName;){if("static"!==getComputedStyle(p).position){h=!1;break}p=p.parentNode}h||(this.element.parentNode.removeChild(this.element),this.element.ownerDocument.body.appendChild(this.element))}var m={},g=!1;for(var o in c){var y=c[o];this.element.style[o]!==y&&(g=!0,m[o]=y)}g&&A(function(){l(t.element.style,m),t.trigger("repositioned")})}}}]),t}();q.modules=[],S.position=M;var U=l(q,S),l=(P=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{!r&&s.return&&s.return()}finally{if(o)throw i}}return n}(e,t);
1throw new TypeError("Invalid attempt to destructure non-iterable instance")},s=(X=S.Utils).getBounds,X.extend),V=(g=X.updateClasses,A=X.defer,["left","top","right","bottom"]);S.modules.push({position:function(e){var t=this,n=e.top,r=e.left,o=e.targetAttachment;if(!this.options.constraints)return!0;var i=this.cache("element-bounds",function(){return s(t.element)}),a=i.height,u=i.width;if(0===u&&0===a&&"undefined"!=typeof this.lastSize){var c=this.lastSize;u=c.width,a=c.height}var f=this.cache("target-bounds",function(){return t.getTargetBounds()}),d=f.height,h=f.width,p=[this.getClass("pinned"),this.getClass("out-of-bounds")];this.options.constraints.forEach(function(e){var t=e.outOfBoundsClass,n=e.pinnedClass;t&&p.push(t),n&&p.push(n)}),p.forEach(function(e){["left","top","right","bottom"].forEach(function(t){p.push(e+"-"+t)})});var m=[],v=l({},o),y=l({},this.attachment);return this.options.constraints.forEach(function(e){var i=e.to,s=e.attachment,c=e.pin;"undefined"==typeof s&&(s="");var l=void 0,f=void 0;if(s.indexOf(" ")>=0){var p=s.split(" "),g=P(p,2);f=g[0],l=g[1]}else l=f=s;var b=x(t,i);"target"!==f&&"both"!==f||(n<b[1]&&"top"===v.top&&(n+=d,v.top="bottom"),n+a>b[3]&&"bottom"===v.top&&(n-=d,v.top="top")),"together"===f&&("top"===v.top&&("bottom"===y.top&&n<b[1]?(n+=d,v.top="bottom",n+=a,y.top="top"):"top"===y.top&&n+a>b[3]&&n-(a-d)>=b[1]&&(n-=a-d,v.top="bottom",y.top="bottom")),"bottom"===v.top&&("top"===y.top&&n+a>b[3]?(n-=d,v.top="top",n-=a,y.top="bottom"):"bottom"===y.top&&n<b[1]&&n+(2*a-d)<=b[3]&&(n+=a-d,v.top="top",y.top="top")),"middle"===v.top&&(n+a>b[3]&&"top"===y.top?(n-=a,y.top="bottom"):n<b[1]&&"bottom"===y.top&&(n+=a,y.top="top"))),"target"!==l&&"both"!==l||(r<b[0]&&"left"===v.left&&(r+=h,v.left="right"),r+u>b[2]&&"right"===v.left&&(r-=h,v.left="left")),"together"===l&&(r<b[0]&&"left"===v.left?"right"===y.left?(r+=h,v.left="right",r+=u,y.left="left"):"left"===y.left&&(r+=h,v.left="right",r-=u,y.left="right"):r+u>b[2]&&"right"===v.left?"left"===y.left?(r-=h,v.left="left",r-=u,y.left="right"):"right"===y.left&&(r-=h,v.left="left",r+=u,y.left="left"):"center"===v.left&&(r+u>b[2]&&"left"===y.left?(r-=u,y.left="right"):r<b[0]&&"right"===y.left&&(r+=u,y.left="left"))),"element"!==f&&"both"!==f||(n<b[1]&&"bottom"===y.top&&(n+=a,y.top="top"),n+a>b[3]&&"top"===y.top&&(n-=a,y.top="bottom")),"element"!==l&&"both"!==l||(r<b[0]&&("right"===y.left?(r+=u,y.left="left"):"center"===y.left&&(r+=u/2,y.left="left")),r+u>b[2]&&("left"===y.left?(r-=u,y.left="right"):"center"===y.left&&(r-=u/2,y.left="right"))),"string"==typeof c?c=c.split(",").map(function(e){return e.trim()}):!0===c&&(c=["top","left","right","bottom"]),c=c||[];var w=[],C=[];n<b[1]&&(c.indexOf("top")>=0?(n=b[1],w.push("top")):C.push("top")),n+a>b[3]&&(c.indexOf("bottom")>=0?(n=b[3]-a,w.push("bottom")):C.push("bottom")),r<b[0]&&(c.indexOf("left")>=0?(r=b[0],w.push("left")):C.push("left")),r+u>b[2]&&(c.indexOf("right")>=0?(r=b[2]-u,w.push("right")):C.push("right")),w.length&&function(){var e;e="undefined"!=typeof t.options.pinnedClass?t.options.pinnedClass:t.getClass("pinned"),m.push(e),w.forEach(function(t){m.push(e+"-"+t)})}(),C.length&&function(){var e;e="undefined"!=typeof t.options.outOfBoundsClass?t.options.outOfBoundsClass:t.getClass("out-of-bounds"),m.push(e),C.forEach(function(t){m.push(e+"-"+t)})}(),(w.indexOf("left")>=0||w.indexOf("right")>=0)&&(y.left=v.left=!1),(w.indexOf("top")>=0||w.indexOf("bottom")>=0)&&(y.top=v.top=!1),v.top===o.top&&v.left===o.left&&y.top===t.attachment.top&&y.left===t.attachment.left||(t.updateAttachClasses(y,v),t.trigger("update",{attachment:y,targetAttachment:v}))}),A(function(){!1!==t.options.addTargetClasses&&g(t.target,m,p),g(t.element,m,p)}),{top:n,left:r}}});var X,s=(X=S.Utils).getBounds,g=X.updateClasses;return A=X.defer,S.modules.push({position:function(e){var t=this,n=e.top,r=e.left,o=this.cache("element-bounds",function(){return s(t.element)}),i=o.height,a=o.width,u=this.getTargetBounds(),c=n+i,l=r+a,f=[];n<=u.bottom&&c>=u.top&&["left","right"].forEach(function(e){var t=u[e];t!==r&&t!==l||f.push(e)}),r<=u.right&&l>=u.left&&["top","bottom"].forEach(function(e){var t=u[e];t!==n&&t!==c||f.push(e)});var d=[],h=[];return d.push(this.getClass("abutted")),["left","top","right","bottom"].forEach(function(e){d.push(t.getClass("abutted")+"-"+e)}
1),f.length&&h.push(this.getClass("abutted")),f.forEach(function(e){h.push(t.getClass("abutted")+"-"+e)}),A(function(){!1!==t.options.addTargetClasses&&g(t.target,h,d),g(t.element,h,d)}),!0}}),P=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{!r&&s.return&&s.return()}finally{if(o)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},S.modules.push({position:function(e){var t=e.top,n=e.left;if(this.options.shift){var r=this.options.shift;"function"==typeof this.options.shift&&(r=this.options.shift.call(this,{top:t,left:n}));var o=void 0,i=void 0;if("string"==typeof r){(r=r.split(" "))[1]=r[1]||r[0];var a=P(r,2);o=a[0],i=a[1],o=parseFloat(o,10),i=parseFloat(i,10)}else o=r.top,i=r.left;return{top:t+=o,left:n+=i}}}}),U}),function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.Popper=t()}(this,function(){"use strict";function e(e){return e&&"[object Function]"==={}.toString.call(e)}function t(e,t){if(1!==e.nodeType)return[];var n=getComputedStyle(e,null);return t?n[t]:n}function n(e){return"HTML"===e.nodeName?e:e.parentNode||e.host}function r(e){if(!e)return document.body;switch(e.nodeName){case"HTML":case"BODY":return e.ownerDocument.body;case"#document":return e.body}var o=t(e);return/(auto|scroll)/.test(o.overflow+o.overflowY+o.overflowX)?e:r(n(e))}function o(e){var n=e&&e.offsetParent,r=n&&n.nodeName;return r&&"BODY"!==r&&"HTML"!==r?-1!==["TD","TABLE"].indexOf(n.nodeName)&&"static"===t(n,"position")?o(n):n:e?e.ownerDocument.documentElement:document.documentElement}function i(e){return null===e.parentNode?e:i(e.parentNode)}function a(e,t){if(!(e&&e.nodeType&&t&&t.nodeType))return document.documentElement;var n=e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,r=n?e:t,s=n?t:e,u=document.createRange();u.setStart(r,0),u.setEnd(s,0);var c=u.commonAncestorContainer;if(e!==c&&t!==c||r.contains(s))return function(e){var t=e.nodeName;return"BODY"!==t&&("HTML"===t||o(e.firstElementChild)===e)}(c)?c:o(c);var l=i(e);return l.host?a(l.host,t):a(e,i(t).host)}function s(e){var t="top"===(1<arguments.length&&void 0!==arguments[1]?arguments[1]:"top")?"scrollTop":"scrollLeft",n=e.nodeName;return"BODY"===n||"HTML"===n?(e.ownerDocument.scrollingElement||e.ownerDocument.documentElement)[t]:e[t]}function u(e,t){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2],r=s(t,"top"),o=s(t,"left"),i=n?-1:1;return e.top+=r*i,e.bottom+=r*i,e.left+=o*i,e.right+=o*i,e}function c(e,t){var n="x"===t?"Left":"Top",r="Left"==n?"Right":"Bottom";return parseFloat(e["border"+n+"Width"],10)+parseFloat(e["border"+r+"Width"],10)}function l(e,t,n,r){return B(t["offset"+e],t["scroll"+e],n["client"+e],n["offset"+e],n["scroll"+e],j()?n["offset"+e]+r["margin"+("Height"===e?"Top":"Left")]+r["margin"+("Height"===e?"Bottom":"Right")]:0)}function f(){var e=document.body,t=document.documentElement,n=j()&&getComputedStyle(t);return{height:l("Height",e,t,n),width:l("Width",e,t,n)}}function d(e){return U({},e,{right:e.left+e.width,bottom:e.top+e.height})}function h(e){var n={};if(j())try{n=e.getBoundingClientRect();var r=s(e,"top"),o=s(e,"left");n.top+=r,n.left+=o,n.bottom+=r,n.right+=o}catch(e){}else n=e.getBoundingClientRect();var i={left:n.left,top:n.top,width:n.right-n.left,height:n.bottom-n.top},a="HTML"===e.nodeName?f():{},u=e.offsetWidth-(a.width||e.clientWidth||i.right-i.left),l=e.offsetHeight-(a.height||e.clientHeight||i.bottom-i.top);if(u||l){var h=t(e);u-=c(h,"x"),l-=c(h,"y"),i.width-=u,i.height-=l}return d(i)}function p(e,n){var o=j(),i="HTML"===n.nodeName,a=h(e),s=h(n),c=r(e),l=t(n),f=parseFloat(l.borderTopWidth,10),p=parseFloat(l.borderLeftWidth,10),m=d({top:a.top-s.top-f,left:a.left-s.left-p,width:a.width,height:a.height});if(m.marginTop=0,m.marginLeft=0,!o&&i){var g=parseFloat(l.marginTop,10),v=parseFloat(l.marginLeft,10);m.top-=f-g,m.bottom-=f-g,m.left-=p-v,m.right-=p-v,m.marginTop=g,m.marginLeft=v}return(o?n.contains(c):n===c&&"BODY"!==c.nodeName)&&(m=u(m,n)),m}function m(e){var t=e.ownerDocument.documentElement,n=p(e,t),r=B(t.clientWidth,window.innerWidth||0),o=B(t.clientHeight,window.innerHeight||0),i=s(t),a=s(t,"left");
1return d({top:i-n.top+n.marginTop,left:a-n.left+n.marginLeft,width:r,height:o})}function g(e){var r=e.nodeName;return"BODY"!==r&&"HTML"!==r&&("fixed"===t(e,"position")||g(n(e)))}function v(e,t,o,i){var s={top:0,left:0},u=a(e,t);if("viewport"===i)s=m(u);else{var c;"scrollParent"===i?"BODY"===(c=r(n(t))).nodeName&&(c=e.ownerDocument.documentElement):c="window"===i?e.ownerDocument.documentElement:i;var l=p(c,u);if("HTML"!==c.nodeName||g(u))s=l;else{var d=f(),h=d.height,v=d.width;s.top+=l.top-l.marginTop,s.bottom=h+l.top,s.left+=l.left-l.marginLeft,s.right=v+l.left}}return s.left+=o,s.top+=o,s.right-=o,s.bottom-=o,s}function y(e,t,n,r,o){var i=5<arguments.length&&void 0!==arguments[5]?arguments[5]:0;if(-1===e.indexOf("auto"))return e;var a=v(n,r,i,o),s={top:{width:a.width,height:t.top-a.top},right:{width:a.right-t.right,height:a.height},bottom:{width:a.width,height:a.bottom-t.bottom},left:{width:t.left-a.left,height:a.height}},u=Object.keys(s).map(function(e){return U({key:e},s[e],{area:function(e){return e.width*e.height}(s[e])})}).sort(function(e,t){return t.area-e.area}),c=u.filter(function(e){return e.width>=n.clientWidth&&e.height>=n.clientHeight}),l=0<c.length?c[0].key:u[0].key,f=e.split("-")[1];return l+(f?"-"+f:"")}function b(e,t,n){return p(n,a(t,n))}function w(e){var t=getComputedStyle(e),n=parseFloat(t.marginTop)+parseFloat(t.marginBottom),r=parseFloat(t.marginLeft)+parseFloat(t.marginRight);return{width:e.offsetWidth+r,height:e.offsetHeight+n}}function x(e){var t={left:"right",right:"left",bottom:"top",top:"bottom"};return e.replace(/left|right|bottom|top/g,function(e){return t[e]})}function C(e,t,n){n=n.split("-")[0];var r=w(e),o={width:r.width,height:r.height},i=-1!==["right","left"].indexOf(n),a=i?"top":"left",s=i?"left":"top",u=i?"height":"width",c=i?"width":"height";return o[a]=t[a]+t[u]/2-r[u]/2,o[s]=n===s?t[s]-r[c]:t[x(s)],o}function S(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function T(t,n,r){return(void 0===r?t:t.slice(0,function(e,t,n){if(Array.prototype.findIndex)return e.findIndex(function(e){return e[t]===n});var r=S(e,function(e){return e[t]===n});return e.indexOf(r)}(t,"name",r))).forEach(function(t){t.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var r=t.function||t.fn;t.enabled&&e(r)&&(n.offsets.popper=d(n.offsets.popper),n.offsets.reference=d(n.offsets.reference),n=r(n,t))}),n}function E(e,t){return e.some(function(e){return e.enabled&&e.name===t})}function k(e){for(var t=[!1,"ms","Webkit","Moz","O"],n=e.charAt(0).toUpperCase()+e.slice(1),r=0;r<t.length-1;r++){var o=t[r],i=o?""+o+n:e;if("undefined"!=typeof document.body.style[i])return i}return null}function N(e){var t=e.ownerDocument;return t?t.defaultView:window}function R(e){return""!==e&&!isNaN(parseFloat(e))&&isFinite(e)}function _(e,t){Object.keys(t).forEach(function(n){var r="";-1!==["width","height","top","right","bottom","left"].indexOf(n)&&R(t[n])&&(r="px"),e.style[n]=t[n]+r})}function A(e,t,n){var r=S(e,function(e){return e.name===t}),o=!!r&&e.some(function(e){return e.name===n&&e.enabled&&e.order<r.order});if(!o){var i="`"+t+"`";console.warn("`"+n+"` modifier is required by "+i+" modifier in order to work, be sure to include it before "+i+"!")}return o}function D(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1],n=X.indexOf(e),r=X.slice(n+1).concat(X.slice(0,n));return t?r.reverse():r}for(var O=Math.min,P=Math.floor,B=Math.max,I="undefined"!=typeof window&&"undefined"!=typeof document,L=["Edge","Trident","Firefox"],M=0,H=0;H<L.length;H+=1)if(I&&0<=navigator.userAgent.indexOf(L[H])){M=1;break}var F,W=I&&window.Promise?function(e){var t=!1;return function(){t||(t=!0,window.Promise.resolve().then(function(){t=!1,e()}))}}:function(e){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1,e()},M))}},j=function(){return void 0==F&&(F=-1!==navigator.appVersion.indexOf("MSIE 10")),F},$=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},z=function(){function e(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),q=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},U=Object.assign||function(e){for(var t,n=1;n<arguments.length;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}
vendor: 4,811 bytes, line 1
1,V=["auto-start","auto","auto-end","top-start","top","top-end","right-start","right","right-end","bottom-end","bottom","bottom-start","left-end","left","left-start"],X=V.slice(3),Y=function(){function t(n,r){var o=this,i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};$(this,t),this.scheduleUpdate=function(){return requestAnimationFrame(o.update)},this.update=W(this.update.bind(this)),this.options=U({},t.Defaults,i),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=n&&n.jquery?n[0]:n,this.popper=r&&r.jquery?r[0]:r,this.options.modifiers={},Object.keys(U({},t.Defaults.modifiers,i.modifiers)).forEach(function(e){o.options.modifiers[e]=U({},t.Defaults.modifiers[e]||{},i.modifiers?i.modifiers[e]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(e){return U({name:e},o.options.modifiers[e])}).sort(function(e,t){return e.order-t.order}),this.modifiers.forEach(function(t){t.enabled&&e(t.onLoad)&&t.onLoad(o.reference,o.popper,o.options,t,o.state)}),this.update();var a=this.options.eventsEnabled;a&&this.enableEventListeners(),this.state.eventsEnabled=a}return z(t,[{key:"update",value:function(){return(function(){if(!this.state.isDestroyed){var e={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};e.offsets.reference=b(0,this.popper,this.reference),e.placement=y(this.options.placement,e.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),e.originalPlacement=e.placement,e.offsets.popper=C(this.popper,e.offsets.reference,e.placement),e.offsets.popper.position="absolute",e=T(this.modifiers,e),this.state.isCreated?this.options.onUpdate(e):(this.state.isCreated=!0,this.options.onCreate(e))}}).call(this)}},{key:"destroy",value:function(){return(function(){return this.state.isDestroyed=!0,E(this.modifiers,"applyStyle")&&(this.popper.removeAttribute("x-placement"),this.popper.style.left="",this.popper.style.position="",this.popper.style.top="",this.popper.style[k("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}).call(this)}},{key:"enableEventListeners",value:function(){return(function(){this.state.eventsEnabled||(this.state=function(e,t,n,o){n.updateBound=o,N(e).addEventListener("resize",n.updateBound,{passive:!0});var i=r(e);return function e(t,n,o,i){var a="BODY"===t.nodeName,s=a?t.ownerDocument.defaultView:t;s.addEventListener(n,o,{passive:!0}),a||e(r(s.parentNode),n,o,i),i.push(s)}(i,"scroll",n.updateBound,n.scrollParents),n.scrollElement=i,n.eventsEnabled=!0,n}(this.reference,0,this.state,this.scheduleUpdate))}).call(this)}},{key:"disableEventListeners",value:function(){return(function(){var e;this.state.eventsEnabled&&(cancelAnimationFrame(this.scheduleUpdate),this.state=(e=this.state,N(this.reference).removeEventListener("resize",e.updateBound),e.scrollParents.forEach(function(t){t.removeEventListener("scroll",e.updateBound)}),e.updateBound=null,e.scrollParents=[],e.scrollElement=null,e.eventsEnabled=!1,e))}).call(this)}}]),t}();return Y.Utils=("undefined"==typeof window?global:window).PopperUtils,Y.placements=V,Y.Defaults={placement:"bottom",eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(e){var t=e.placement,n=t.split("-")[0],r=t.split("-")[1];if(r){var o=e.offsets,i=o.reference,a=o.popper,s=-1!==["bottom","top"].indexOf(n),u=s?"left":"top",c=s?"width":"height",l={start:q({},u,i[u]),end:q({},u,i[u]+i[c]-a[c])};e.offsets.popper=U({},a,l[r])}return e}},offset:{order:200,enabled:!0,fn:function(e,t){var n,r=t.offset,o=e.offsets,i=o.popper,a=o.reference,s=e.placement.split("-")[0];return n=R(+r)?[+r,0]:function(e,t,n,r){var o=[0,0],i=-1!==["right","left"].indexOf(r),a=e.split(/(\+|\-)/).map(function(e){return e.trim()}),s=a.indexOf(S(a,function(e){return-1!==e.search(/,|\s/)}));a[s]&&-1===a[s].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var u=/\s*,\s*|\s+/,c=-1===s?[a]:[a.slice(0,s).concat([a[s].split(u)[0]]),[a[s].split(u)[1]].concat(a.slice(s+1))];return(c=c.map(function(e,r){var o=(1===r?!i:i)?"height":"width",a=!1;return e.reduce(function(e,t){return""===e[e.length-1]&&-1!==["+","-"].indexOf(t)?(e[e.length-1]=t,a=!0,e):a?(e[e.length-1]+=t,a=!1,e):e.concat(t)},[]).map(function(e){return function(e,t,n,r){var o=e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),i=+o[1],a=o[2];if(!i)return e;if(0===a.indexOf("%")){var s;switch(a){case"%p":s=n;break;case"%":case"%r":default:s=r}return d(s)[t]/100*i}return"vh"===a||"vw"===a?("vh"===a?B(document.documentElement.clientHeight,window.innerHeight||0):B(document.documentElement.clientWidth,window.innerWidth||0))/100*i:i}(e,o,t,n)})}
1)).forEach(function(e,t){e.forEach(function(n,r){R(n)&&(o[t]+=n*("-"===e[r-1]?-1:1))})}),o}(r,i,a,s),"left"===s?(i.top+=n[0],i.left-=n[1]):"right"===s?(i.top+=n[0],i.left+=n[1]):"top"===s?(i.left+=n[0],i.top-=n[1]):"bottom"===s&&(i.left+=n[0],i.top+=n[1]),e.popper=i,e},offset:0},preventOverflow:{order:300,enabled:!0,fn:function(e,t){var n=t.boundariesElement||o(e.instance.popper);e.instance.reference===n&&(n=o(n));var r=v(e.instance.popper,e.instance.reference,t.padding,n);t.boundaries=r;var i=e.offsets.popper,a={primary:function(e){var n=i[e];return i[e]<r[e]&&!t.escapeWithReference&&(n=B(i[e],r[e])),q({},e,n)},secondary:function(e){var n="right"===e?"left":"top",o=i[n];return i[e]>r[e]&&!t.escapeWithReference&&(o=O(i[n],r[e]-("right"===e?i.width:i.height))),q({},n,o)}};return t.priority.forEach(function(e){var t=-1===["left","top"].indexOf(e)?"secondary":"primary";i=U({},i,a[t](e))}),e.offsets.popper=i,e},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(e){var t=e.offsets,n=t.popper,r=t.reference,o=e.placement.split("-")[0],i=P,a=-1!==["top","bottom"].indexOf(o),s=a?"right":"bottom",u=a?"left":"top",c=a?"width":"height";return n[s]<i(r[u])&&(e.offsets.popper[u]=i(r[u])-n[c]),n[u]>i(r[s])&&(e.offsets.popper[u]=i(r[s])),e}},arrow:{order:500,enabled:!0,fn:function(e,n){var r;if(!A(e.instance.modifiers,"arrow","keepTogether"))return e;var o=n.element;if("string"==typeof o){if(!(o=e.instance.popper.querySelector(o)))return e}else if(!e.instance.popper.contains(o))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),e;var i=e.placement.split("-")[0],a=e.offsets,s=a.popper,u=a.reference,c=-1!==["left","right"].indexOf(i),l=c?"height":"width",f=c?"Top":"Left",h=f.toLowerCase(),p=c?"left":"top",m=c?"bottom":"right",g=w(o)[l];u[m]-g<s[h]&&(e.offsets.popper[h]-=s[h]-(u[m]-g)),u[h]+g>s[m]&&(e.offsets.popper[h]+=u[h]+g-s[m]),e.offsets.popper=d(e.offsets.popper);var v=u[h]+u[l]/2-g/2,y=t(e.instance.popper),b=parseFloat(y["margin"+f],10),x=parseFloat(y["border"+f+"Width"],10),C=v-e.offsets.popper[h]-b-x;return C=B(O(s[l]-g,C),0),e.arrowElement=o,e.offsets.arrow=(q(r={},h,Math.round(C)),q(r,p,""),r),e},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(e,t){if(E(e.instance.modifiers,"inner"))return e;if(e.flipped&&e.placement===e.originalPlacement)return e;var n=v(e.instance.popper,e.instance.reference,t.padding,t.boundariesElement),r=e.placement.split("-")[0],o=x(r),i=e.placement.split("-")[1]||"",a=[];switch(t.behavior){case"flip":a=[r,o];break;case"clockwise":a=D(r);break;case"counterclockwise":a=D(r,!0);break;default:a=t.behavior}return a.forEach(function(s,u){if(r!==s||a.length===u+1)return e;r=e.placement.split("-")[0],o=x(r);var c=e.offsets.popper,l=e.offsets.reference,f=P,d="left"===r&&f(c.right)>f(l.left)||"right"===r&&f(c.left)<f(l.right)||"top"===r&&f(c.bottom)>f(l.top)||"bottom"===r&&f(c.top)<f(l.bottom),h=f(c.left)<f(n.left),p=f(c.right)>f(n.right),m=f(c.top)<f(n.top),g=f(c.bottom)>f(n.bottom),v="left"===r&&h||"right"===r&&p||"top"===r&&m||"bottom"===r&&g,y=-1!==["top","bottom"].indexOf(r),b=!!t.flipVariations&&(y&&"start"===i&&h||y&&"end"===i&&p||!y&&"start"===i&&m||!y&&"end"===i&&g);(d||v||b)&&(e.flipped=!0,(d||v)&&(r=a[u+1]),b&&(i="end"===i?"start":"start"===i?"end":i),e.placement=r+(i?"-"+i:""),e.offsets.popper=U({},e.offsets.popper,C(e.instance.popper,e.offsets.reference,e.placement)),e=T(e.instance.modifiers,e,"flip"))}),e},behavior:"flip",padding:5,boundariesElement:"viewport"},inner:{order:700,enabled:!1,fn:function(e){var t=e.placement,n=t.split("-")[0],r=e.offsets,o=r.popper,i=r.reference,a=-1!==["left","right"].indexOf(n),s=-1===["top","left"].indexOf(n);return o[a?"left":"top"]=i[n]-(s?o[a?"width":"height"]:0),e.placement=x(t),e.offsets.popper=d(o),e}},hide:{order:800,enabled:!0,fn:function(e){if(!A(e.instance.modifiers,"hide","preventOverflow"))return e;var t=e.offsets.reference,n=S(e.instance.modifiers,function(e){return"preventOverflow"===e.name}).boundaries;if(t.bottom<n.top||t.left>n.right||t.top>n.bottom||t.right<n.left){if(!0===e.hide)return e;e.hide=!0,e.attributes["x-out-of-boundaries"]=""}else{if(!1===e.hide)return e;e.hide=!1,e.attributes["x-out-of-boundaries"]=!1}return e}},computeStyle:{order:850,enabled:!0,fn:function(e,t){var n=t.x,r=t.y,i=e.offsets.popper,a=S(e.instance.modifiers,function(e){return"applyStyle"===e.name}).gpuAcceleration;void 0!==a&&console.warn("WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!");var s,u,c=void 0===a?t.gpuAcceleration:a,l=h(o(e.instance.popper)),f={position:i.position},d={left:P(i.left),top:P(i.top),bottom:P(i.bottom),right:P(i.right)},p="bottom"===n?"top":"bottom",m="right"===r?"left":"right",g=k("transform");if(u="bottom"==p?-l.height+d.bottom:d.top,s="right"==m?-l.width+d.right:d.left,c&&g)f[g]="translate3d("+s+"px, "+u+"px, 0)",f[p]=0,f[m]=0,f.willChange="transform";else{var v="right"==m?-1:1;f[p]=u*("bottom"==p?-1:1),f[m]=s*v,f.willChange=p+", "+m}return e.attributes=U({},{"x-placement":e.placement},e.attributes),e.styles=U({},f,e.styles),e.arrowStyles=U({},e.offsets.arrow,e.arrowStyles),e},gpuAcceleration:!0,x:"bottom",y:"right"},applyStyle:{order:900,enabled:!0,fn:function(e){return _(e.instance.popper,e.styles),function(e,t){Object.keys(t).forEach(function(n){!1===t[n]?e.removeAttribute(n):e.setAttribute(n,t[n])})}(e.instance.popper,e.attributes),e.arrowElement&&Object.keys(e.arrowStyles).length&&_(e.arrowElement,e.arrowStyles),e},onLoad:function(e,t,n,r,o){var i=b(0,t,e),a=y(n.placement,i,t,e,n.modifiers.flip.boundariesElement,n.modifiers.flip.padding);return t.setAttribute("x-placement",a),_(t,{position:"absolute"}),n},gpuAcceleration:void 0}}},Y}),"undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");!function(e){"use strict";var t=e.fn.jquery.split(" ")[0].split(".");if(t[0]<2&&t[1]<9||1==t[0]&&9==t[1]&&t[2]<1||t[0]>3)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4")}(jQuery),function(e){"use strict";e.fn.emulateTransitionEnd=function(t){var n=!1,r=this;return e(this).one("bsTransitionEnd",function(){n=!0}),setTimeout(function(){n||e(r).trigger(e.support.transition.end)},t),this},e(function(){e.support.transition=function(){var e=document.createElement("bootstrap"),t={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var n in t)if(void 0!==e.style[n])return{end:t[n]};return!1}(),e.support.transition&&(e.event.special.bsTransitionEnd={bindType:e.support.transition.end,delegateType:e.support.transition.end,handle:function(t){if(e(t.target).is(this))return t.handleObj.handler.apply(this,arguments)}})})}(jQuery),function(e){"use strict";var t='[data-dismiss="alert"]',n=function(n){e(n).on("click",t,this.close)};n.VERSION="3.3.7",n.TRANSITION_DURATION=150,n.prototype.close=function(t){function r(){a.detach().trigger("closed.bs.alert").remove()}var o=e(this),i=o.attr("data-target");i||(i=(i=o.attr("href"))&&i.replace(/.*(?=#[^\s]*$)/,""));var a=e("#"===i?[]:i);t&&t.preventDefault(),a.length||(a=o.closest(".alert")),a.trigger(t=e.Event("close.bs.alert")),t.isDefaultPrevented()||(a.removeClass("in"),e.support.transition&&a.hasClass("fade")?a.one("bsTransitionEnd",r).emulateTransitionEnd(n.TRANSITION_DURATION):r())};var r=e.fn.alert;e.fn.alert=function(t){return this.each(function(){var r=e(this),o=r.data("bs.alert");o||r.data("bs.alert",o=new n(this)),"string"==typeof t&&o[t].call(r)})},e.fn.alert.Constructor=n,e.fn.alert.noConflict=function(){return e.fn.alert=r,this},e(document).on("click.bs.alert.data-api",t,n.prototype.close)}(jQuery),function(e){"use strict";function t(t){return this.each(function(){var r=e(this),o=r.data("bs.button");o||r.data("bs.button",o=new n(this,"object"==typeof t&&t)),"toggle"==t?o.toggle():t&&o.setState(t)})}var n=function(t,r){this.$element=e(t),this.options=e.extend({},n.DEFAULTS,r),this.isLoading=!1};n.VERSION="3.3.7",n.DEFAULTS={loadingText:"loading..."},n.prototype.setState=function(t){var n="disabled",r=this.$element,o=r.is("input")?"val":"html",i=r.data();t+="Text",null==i.resetText&&r.data("resetText",r[o]()),setTimeout(e.proxy(function(){r[o](null==i[t]?this.options[t]:i[t]),"loadingText"==t?(this.isLoading=!0,r.addClass(n).attr(n,n).prop(n,!0)):this.isLoading&&(this.isLoading=!1,r.removeClass(n).removeAttr(n).prop(n,!1))},this),0)},n.prototype.toggle=function(){var e=!0,t=this.$element.closest('[data-toggle="buttons"]');if(t.length){var n=this.$element.find("input");"radio"==n.prop("type")?(n.prop("checked")&&(e=!1),t.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==n.prop("type")&&(n.prop("checked")!==this.$element.hasClass("active")&&(e=!1),this.$element.toggleClass("active")),n.prop("checked",this.$element.hasClass("active")),e&&n.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var r=e.fn.button;e.fn.button=t,e.fn.button.Constructor=n,e.fn.button.noConflict=function(){return e.fn.button=r,this},e(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(n){var r=e(n.target).closest(".btn");t.call(r,"toggle"),e(n.target).is('input[type="radio"], input[type="checkbox"]')||(n.preventDefault(),r.is("input,button")?r.trigger("focus"):r.find("input:visible,button:visible").first().trigger("focus"))}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(t){e(t.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(t.type))})}(jQuery),function(e){"use strict";function t(t){return this.each(function(){var r=e(this),o=r.data("bs.carousel"),i=e.extend({},n.DEFAULTS,r.data(),"object"==typeof t&&t),a="string"==typeof t?t:i.slide;o||r.data("bs.carousel",o=new n(this,i)),"number"==typeof t?o.to(t):a?o[a]():i.interval&&o.pause().cycle()})}var n=function(t,n){this.$element=e(t),this.$indicators=this.$element.find(".carousel-indicators"),this.options=n,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("key
1down.bs.carousel",e.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",e.proxy(this.pause,this)).on("mouseleave.bs.carousel",e.proxy(this.cycle,this))};n.VERSION="3.3.7",n.TRANSITION_DURATION=600,n.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},n.prototype.keydown=function(e){if(!/input|textarea/i.test(e.target.tagName)){switch(e.which){case 37:this.prev();break;case 39:this.next();break;default:return}e.preventDefault()}},n.prototype.cycle=function(t){return t||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(e.proxy(this.next,this),this.options.interval)),this},n.prototype.getItemIndex=function(e){return this.$items=e.parent().children(".item"),this.$items.index(e||this.$active)},n.prototype.getItemForDirection=function(e,t){var n=this.getItemIndex(t);return("prev"==e&&0===n||"next"==e&&n==this.$items.length-1)&&!this.options.wrap?t:this.$items.eq((n+("prev"==e?-1:1))%this.$items.length)},n.prototype.to=function(e){var t=this,n=this.getItemIndex(this.$active=this.$element.find(".item.active"));if(!(e>this.$items.length-1||e<0))return this.sliding?this.$element.one("slid.bs.carousel",function(){t.to(e)}):n==e?this.pause().cycle():this.slide(e>n?"next":"prev",this.$items.eq(e))},n.prototype.pause=function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&e.support.transition&&(this.$element.trigger(e.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},n.prototype.next=function(){if(!this.sliding)return this.slide("next")},n.prototype.prev=function(){if(!this.sliding)return this.slide("prev")},n.prototype.slide=function(t,r){var o=this.$element.find(".item.active"),i=r||this.getItemForDirection(t,o),a=this.interval,s="next"==t?"left":"right",u=this;if(i.hasClass("active"))return this.sliding=!1;var c=i[0],l=e.Event("slide.bs.carousel",{relatedTarget:c,direction:s});if(this.$element.trigger(l),!l.isDefaultPrevented()){if(this.sliding=!0,a&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var f=e(this.$indicators.children()[this.getItemIndex(i)]);f&&f.addClass("active")}var d=e.Event("slid.bs.carousel",{relatedTarget:c,direction:s});return e.support.transition&&this.$element.hasClass("slide")?(i.addClass(t),o.addClass(s),i.addClass(s),o.one("bsTransitionEnd",function(){i.removeClass([t,s].join(" ")).addClass("active"),o.removeClass(["active",s].join(" ")),u.sliding=!1,setTimeout(function(){u.$element.trigger(d)},0)}).emulateTransitionEnd(n.TRANSITION_DURATION)):(o.removeClass("active"),i.addClass("active"),this.sliding=!1,this.$element.trigger(d)),a&&this.cycle(),this}};var r=e.fn.carousel;e.fn.carousel=t,e.fn.carousel.Constructor=n,e.fn.carousel.noConflict=function(){return e.fn.carousel=r,this};var o=function(n){var r,o=e(this),i=e(o.attr("data-target")||(r=o.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,""));if(i.hasClass("carousel")){var a=e.extend({},i.data(),o.data()),s=o.attr("data-slide-to");s&&(a.interval=!1),t.call(i,a),s&&i.data("bs.carousel").to(s),n.preventDefault()}};e(document).on("click.bs.carousel.data-api","[data-slide]",o).on("click.bs.carousel.data-api","[data-slide-to]",o),e(window).on("load",function(){e('[data-ride="carousel"]').each(function(){var n=e(this);t.call(n,n.data())})})}(jQuery),function(e){"use strict";function t(t){var n,r=t.attr("data-target")||(n=t.attr("href"))&&n.replace(/.*(?=#[^\s]+$)/,"");return e(r)}function n(t){return this.each(function(){var n=e(this),o=n.data("bs.collapse"),i=e.extend({},r.DEFAULTS,n.data(),"object"==typeof t&&t);!o&&i.toggle&&/show|hide/.test(t)&&(i.toggle=!1),o||n.data("bs.collapse",o=new r(this,i)),"string"==typeof t&&o[t]()})}var r=function(t,n){this.$element=e(t),this.options=e.extend({},r.DEFAULTS,n),this.$trigger=e('[data-toggle="collapse"][href="#'+t.id+'"],[data-toggle="collapse"][data-target="#'+t.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};r.VERSION="3.3.7",r.TRANSITION_DURATION=350,r.DEFAULTS={toggle:!0},r.prototype.dimension=function(){return this.$element.hasClass("width")?"width":"height"},r.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var t,o=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(o&&o.length&&(t=o.data("bs.collapse"),t&&t.transitioning))){var i=e.Event("show.bs.collapse");if(this.$element.trigger(i),!i.isDefaultPrevented()){o&&o.length&&(n.call(o,"hide"),t||o.data("bs.collapse",null));var a=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[a](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var s=function(){this.$element.removeClass("collapsing").addClass("collapse in")[a](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!e.support.transition)return s.call(this);var u=e.camelCase(["scroll",a].join("-"));this.$element.one("bsTransitionEnd",e.proxy(s,this)).emulateTransitionEnd(r.TRANSITION_DURATION)[a](this.$element[0][u])}}}},r.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var t=e.Event("hide.bs.collapse");if(this.$element.trigger(t),!t.isDefaultPrevented()){var n=this.dimension();this.$element[n](this.$element[n]()),this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var o=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};
vendor: 5,397 bytes, line 1
1return e.support.transition?void this.$element[n](0).one("bsTransitionEnd",e.proxy(o,this)).emulateTransitionEnd(r.TRANSITION_DURATION):o.call(this)}}},r.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},r.prototype.getParent=function(){return e(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(e.proxy(function(n,r){var o=e(r);this.addAriaAndCollapsedClass(t(o),o)},this)).end()},r.prototype.addAriaAndCollapsedClass=function(e,t){var n=e.hasClass("in");e.attr("aria-expanded",n),t.toggleClass("collapsed",!n).attr("aria-expanded",n)};var o=e.fn.collapse;e.fn.collapse=n,e.fn.collapse.Constructor=r,e.fn.collapse.noConflict=function(){return e.fn.collapse=o,this},e(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(r){var o=e(this);o.attr("data-target")||r.preventDefault();var i=t(o),a=i.data("bs.collapse")?"toggle":o.data();n.call(i,a)})}(jQuery),function(e){"use strict";function t(t){var n=t.attr("data-target");n||(n=(n=t.attr("href"))&&/#[A-Za-z]/.test(n)&&n.replace(/.*(?=#[^\s]*$)/,""));var r=n&&e(n);return r&&r.length?r:t.parent()}function n(n){n&&3===n.which||(e(r).remove(),e(o).each(function(){var r=e(this),o=t(r),i={relatedTarget:this};o.hasClass("open")&&(n&&"click"==n.type&&/input|textarea/i.test(n.target.tagName)&&e.contains(o[0],n.target)||(o.trigger(n=e.Event("hide.bs.dropdown",i)),n.isDefaultPrevented()||(r.attr("aria-expanded","false"),o.removeClass("open").trigger(e.Event("hidden.bs.dropdown",i)))))}))}var r=".dropdown-backdrop",o='[data-toggle="dropdown"]',i=function(t){e(t).on("click.bs.dropdown",this.toggle)};i.VERSION="3.3.7",i.prototype.toggle=function(r){var o=e(this);if(!o.is(".disabled, :disabled")){var i=t(o),a=i.hasClass("open");if(n(),!a){"ontouchstart"in document.documentElement&&!i.closest(".navbar-nav").length&&e(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(e(this)).on("click",n);var s={relatedTarget:this};if(i.trigger(r=e.Event("show.bs.dropdown",s)),r.isDefaultPrevented())return;o.trigger("focus").attr("aria-expanded","true"),i.toggleClass("open").trigger(e.Event("shown.bs.dropdown",s))}return!1}},i.prototype.keydown=function(n){if(/(38|40|27|32)/.test(n.which)&&!/input|textarea/i.test(n.target.tagName)){var r=e(this);if(n.preventDefault(),n.stopPropagation(),!r.is(".disabled, :disabled")){var i=t(r),a=i.hasClass("open");if(!a&&27!=n.which||a&&27==n.which)return 27==n.which&&i.find(o).trigger("focus"),r.trigger("click");var s=i.find(".dropdown-menu li:not(.disabled):visible a");if(s.length){var u=s.index(n.target);38==n.which&&u>0&&u--,40==n.which&&u<s.length-1&&u++,~u||(u=0),s.eq(u).trigger("focus")}}}};var a=e.fn.dropdown;e.fn.dropdown=function(t){return this.each(function(){var n=e(this),r=n.data("bs.dropdown");r||n.data("bs.dropdown",r=new i(this)),"string"==typeof t&&r[t].call(n)})},e.fn.dropdown.Constructor=i,e.fn.dropdown.noConflict=function(){return e.fn.dropdown=a,this},e(document).on("click.bs.dropdown.data-api",n).on("click.bs.dropdown.data-api",".dropdown form",function(e){e.stopPropagation()}).on("click.bs.dropdown.data-api",o,i.prototype.toggle).on("keydown.bs.dropdown.data-api",o,i.prototype.keydown).on("keydown.bs.dropdown.data-api",".dropdown-menu",i.prototype.keydown)}(jQuery),function(e){"use strict";function t(t,r){return this.each(function(){var o=e(this),i=o.data("bs.modal"),a=e.extend({},n.DEFAULTS,o.data(),"object"==typeof t&&t);i||o.data("bs.modal",i=new n(this,a)),"string"==typeof t?i[t](r):a.show&&i.show(r)})}var n=function(t,n){this.options=n,this.$body=e(document.body),this.$element=e(t),this.$dialog=this.$element.find(".modal-dialog"),this.$backdrop=null,this.isShown=null,this.originalBodyPad=null,this.scrollbarWidth=0,this.ignoreBackdropClick=!1,this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,e.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))};n.VERSION="3.3.7",n.TRANSITION_DURATION=300,n.BACKDROP_TRANSITION_DURATION=150,n.DEFAULTS={backdrop:!0,keyboard:!0,show:!0},n.prototype.toggle=function(e){return this.isShown?this.hide():this.show(e)},n.prototype.show=function(t){var r=this,o=e.Event("show.bs.modal",{relatedTarget:t});this.$element.trigger(o),this.isShown||o.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',e.proxy(this.hide,this)),this.$dialog.on("mousedown.dismiss.bs.modal",function(){r.$element.one("mouseup.dismiss.bs.modal",function(t){e(t.target).is(r.$element)&&(r.ignoreBackdropClick=!0)})}),this.backdrop(function(){var o=e.support.transition&&r.$element.hasClass("fade");r.$element.parent().length||r.$element.appendTo(r.$body),r.$element.show().scrollTop(0),r.adjustDialog(),r.$element.addClass("in"),r.enforceFocus();var i=e.Event("shown.bs.modal",{relatedTarget:t});o?r.$dialog.one("bsTransitionEnd",function(){r.$element.trigger("focus").trigger(i)}).emulateTransitionEnd(n.TRANSITION_DURATION):r.$element.trigger("focus").trigger(i)}))},n.prototype.hide=function(t){t&&t.preventDefault(),t=e.Event("hide.bs.modal"),this.$element.trigger(t),this.isShown&&!t.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),e(document).off("focusin.bs.modal"),this.$element.removeClass("in").off("
1click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"),this.$dialog.off("mousedown.dismiss.bs.modal"),e.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",e.proxy(this.hideModal,this)).emulateTransitionEnd(n.TRANSITION_DURATION):this.hideModal())},n.prototype.enforceFocus=function(){e(document).off("focusin.bs.modal").on("focusin.bs.modal",e.proxy(function(e){document===e.target||this.$element[0]===e.target||this.$element.has(e.target).length||this.$element.trigger("focus")},this))},n.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",e.proxy(function(e){27==e.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")},n.prototype.resize=function(){this.isShown?e(window).on("resize.bs.modal",e.proxy(this.handleUpdate,this)):e(window).off("resize.bs.modal")},n.prototype.hideModal=function(){var e=this;this.$element.hide(),this.backdrop(function(){e.$body.removeClass("modal-open"),e.resetAdjustments(),e.resetScrollbar(),e.$element.trigger("hidden.bs.modal")})},n.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},n.prototype.backdrop=function(t){var r=this,o=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var i=e.support.transition&&o;if(this.$backdrop=e(document.createElement("div")).addClass("modal-backdrop "+o).appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",e.proxy(function(e){return this.ignoreBackdropClick?void(this.ignoreBackdropClick=!1):void(e.target===e.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus():this.hide()))},this)),this.$backdrop.addClass("in"),!t)return;i?this.$backdrop.one("bsTransitionEnd",t).emulateTransitionEnd(n.BACKDROP_TRANSITION_DURATION):t()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var a=function(){r.removeBackdrop(),t&&t()};
vendor: 4,145 bytes, line 1
1e.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",a).emulateTransitionEnd(n.BACKDROP_TRANSITION_DURATION):a()}else t&&t()},n.prototype.handleUpdate=function(){this.adjustDialog()},n.prototype.adjustDialog=function(){var e=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&e?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!e?this.scrollbarWidth:""})},n.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},n.prototype.checkScrollbar=function(){var e=window.innerWidth;if(!e){var t=document.documentElement.getBoundingClientRect();e=t.right-Math.abs(t.left)}this.bodyIsOverflowing=document.body.clientWidth<e,this.scrollbarWidth=this.measureScrollbar()},n.prototype.setScrollbar=function(){var e=parseInt(this.$body.css("padding-right")||0,10);this.originalBodyPad=document.body.style.paddingRight||"",this.bodyIsOverflowing&&this.$body.css("padding-right",e+this.scrollbarWidth)},n.prototype.resetScrollbar=function(){this.$body.css("padding-right",this.originalBodyPad)},n.prototype.measureScrollbar=function(){var e=document.createElement("div");e.className="modal-scrollbar-measure",this.$body.append(e);var t=e.offsetWidth-e.clientWidth;return this.$body[0].removeChild(e),t};var r=e.fn.modal;e.fn.modal=t,e.fn.modal.Constructor=n,e.fn.modal.noConflict=function(){return e.fn.modal=r,this},e(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(n){var r=e(this),o=r.attr("href"),i=e(r.attr("data-target")||o&&o.replace(/.*(?=#[^\s]+$)/,"")),a=i.data("bs.modal")?"toggle":e.extend({remote:!/#/.test(o)&&o},i.data(),r.data());r.is("a")&&n.preventDefault(),i.one("show.bs.modal",function(e){e.isDefaultPrevented()||i.one("hidden.bs.modal",function(){r.is(":visible")&&r.trigger("focus")})}),t.call(i,a,this)})}(jQuery),function(e){"use strict";var t=function(e,t){this.type=null,this.options=null,this.enabled=null,this.timeout=null,this.hoverState=null,this.$element=null,this.inState=null,this.init("tooltip",e,t)};t.VERSION="3.3.7",t.TRANSITION_DURATION=150,t.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},t.prototype.init=function(t,n,r){if(this.enabled=!0,this.type=t,this.$element=e(n),this.options=this.getOptions(r),this.$viewport=this.options.viewport&&e(e.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var o=this.options.trigger.split(" "),i=o.length;i--;){var a=o[i];if("click"==a)this.$element.on("click."+this.type,this.options.selector,e.proxy(this.toggle,this));else if("manual"!=a){var s="hover"==a?"mouseleave":"focusout";this.$element.on(("hover"==a?"mouseenter":"focusin")+"."+this.type,this.options.selector,e.proxy(this.enter,this)),this.$element.on(s+"."+this.type,this.options.selector,e.proxy(this.leave,this))}}this.options.selector?this._options=e.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},t.prototype.getDefaults=function(){return t.DEFAULTS},t.prototype.getOptions=function(t){return(t=e.extend({},this.getDefaults(),this.$element.data(),t)).delay&&"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t},t.prototype.getDelegateOptions=function(){var t={},n=this.getDefaults();return this._options&&e.each(this._options,function(e,r){n[e]!=r&&(t[e]=r)}),t},t.prototype.enter=function(t){var n=t instanceof this.constructor?t:e(t.currentTarget).data("bs."+this.type);return n||(n=new this.constructor(t.currentTarget,this.getDelegateOptions()),e(t.currentTarget).data("bs."+this.type,n)),t instanceof e.Event&&(n.inState["focusin"==t.type?"focu
1s":"hover"]=!0),n.tip().hasClass("in")||"in"==n.hoverState?void(n.hoverState="in"):(clearTimeout(n.timeout),n.hoverState="in",n.options.delay&&n.options.delay.show?void(n.timeout=setTimeout(function(){"in"==n.hoverState&&n.show()},n.options.delay.show)):n.show())},t.prototype.isInStateTrue=function(){for(var e in this.inState)if(this.inState[e])return!0;return!1},t.prototype.leave=function(t){var n=t instanceof this.constructor?t:e(t.currentTarget).data("bs."+this.type);if(n||(n=new this.constructor(t.currentTarget,this.getDelegateOptions()),e(t.currentTarget).data("bs."+this.type,n)),t instanceof e.Event&&(n.inState["focusout"==t.type?"focus":"hover"]=!1),!n.isInStateTrue())return clearTimeout(n.timeout),n.hoverState="out",n.options.delay&&n.options.delay.hide?void(n.timeout=setTimeout(function(){"out"==n.hoverState&&n.hide()},n.options.delay.hide)):n.hide()},t.prototype.show=function(){var n=e.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(n);var r=e.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(n.isDefaultPrevented()||!r)return;var o=this,i=this.tip(),a=this.getUID(this.type);this.setContent(),i.attr("id",a),this.$element.attr("aria-describedby",a),this.options.animation&&i.addClass("fade");var s="function"==typeof this.options.placement?this.options.placement.call(this,i[0],this.$element[0]):this.options.placement,u=/\s?auto?\s?/i,c=u.test(s);c&&(s=s.replace(u,"")||"top"),i.detach().css({top:0,left:0,display:"block"}).addClass(s).data("bs."+this.type,this),this.options.container?i.appendTo(this.options.container):i.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var l=this.getPosition(),f=i[0].offsetWidth,d=i[0].offsetHeight;if(c){var h=s,p=this.getPosition(this.$viewport);s="bottom"==s&&l.bottom+d>p.bottom?"top":"top"==s&&l.top-d<p.top?"bottom":"right"==s&&l.right+f>p.width?"left":"left"==s&&l.left-f<p.left?"right":s,i.removeClass(h).addClass(s)}var m=this.getCalculatedOffset(s,l,f,d);this.applyPlacement(m,s);var g=function(){var e=o.hoverState;o.$element.trigger("shown.bs."+o.type),o.hoverState=null,"out"==e&&o.leave(o)};e.support.transition&&this.$tip.hasClass("fade")?i.one("bsTransitionEnd",g).emulateTransitionEnd(t.TRANSITION_DURATION):g()}},t.prototype.applyPlacement=function(t,n){var r=this.tip(),o=r[0].offsetWidth,i=r[0].offsetHeight,a=parseInt(r.css("margin-top"),10),s=parseInt(r.css("margin-left"),10);isNaN(a)&&(a=0),isNaN(s)&&(s=0),t.top+=a,t.left+=s,e.offset.setOffset(r[0],e.extend({using:function(e){r.css({top:Math.round(e.top),left:Math.round(e.left)})}},t),0),r.addClass("in");var u=r[0].offsetWidth,c=r[0].offsetHeight;"top"==n&&c!=i&&(t.top=t.top+i-c);var l=this.getViewportAdjustedDelta(n,t,u,c);l.left?t.left+=l.left:t.top+=l.top;var f=/top|bottom/.test(n),d=f?2*l.left-o+u:2*l.top-i+c,h=f?"offsetWidth":"offsetHeight";r.offset(t),this.replaceArrow(d,r[0][h],f)},t.prototype.replaceArrow=function(e,t,n){this.arrow().css(n?"left":"top",50*(1-e/t)+"%").css(n?"top":"left","")},t.prototype.setContent=function(){var e=this.tip(),t=this.getTitle();e.find(".tooltip-inner")[this.options.html?"html":"text"](t),e.removeClass("fade in top bottom left right")},t.prototype.hide=function(n){function r(){"in"!=o.hoverState&&i.detach(),o.$element&&o.$element.removeAttr("aria-describedby").trigger("hidden.bs."+o.type),n&&n()}var o=this,i=e(this.$tip),a=e.Event("hide.bs."+this.type);if(this.$element.trigger(a),!a.isDefaultPrevented())return i.removeClass("in"),e.support.transition&&i.hasClass("fade")?i.one("bsTransitionEnd",r).emulateTransitionEnd(t.TRANSITION_DURATION):r(),this.hoverState=null,this},t.prototype.fixTitle=function(){var e=this.$element;(e.attr("title")||"string"!=typeof e.attr("data-original-title"))&&e.attr("data-original-title",e.attr("title")||"").attr("title","")},t.prototype.hasContent=function(){return this.getTitle()},t.prototype.getPosition=function(t){var n=(t=t||this.$element)[0],r="BODY"==n.tagName,o=n.getBoundingClientRect();null==o.width&&(o=e.extend({},o,{width:o.right-o.left,height:o.bottom-o.top}));var i=window.SVGElement&&n instanceof window.SVGElement,a=r?{top:0,left:0}:i?null:t.offset(),s={scroll:r?document.documentElement.scrollTop||document.body.scrollTop:t.scrollTop()},u=r?{width:e(window).width(),height:e(window).height()}:null;return e.extend({},o,s,u,a)},t.prototype.getCalculatedOffset=function(e,t,n,r){return"bottom"==e?{top:t.top+t.height,left:t.left+t.width/2-n/2}:"top"==e?{top:t.top-r,left:t.left+t.width/2-n/2}:"left"==e?{top:t.top+t.height/2-r/2,left:t.left-n}:{top:t.top+t.height/2-r/2,left:t.left+t.width}},t.prototype.getViewportAdjustedDelta=function(e,t,n,r){var o={top:0,left:0};if(!this.$viewport)return o;var i=this.options.viewport&&this.options.viewport.padding||0,a=this.getPosition(this.$viewport);if(/right|left/.test(e)){var s=t.top-i-a.scroll,u=t.top+i-a.scroll+r;s<a.top?o.top=a.top-s:u>a.top+a.height&&(o.top=a.top+a.height-u)}else{var c=t.left-i,l=t.left+i+n;
vendor: 7,195 bytes, line 1
1c<a.left?o.left=a.left-c:l>a.right&&(o.left=a.left+a.width-l)}return o},t.prototype.getTitle=function(){var e=this.$element,t=this.options;return e.attr("data-original-title")||("function"==typeof t.title?t.title.call(e[0]):t.title)},t.prototype.getUID=function(e){do{e+=~~(1e6*Math.random())}while(document.getElementById(e));return e},t.prototype.tip=function(){if(!this.$tip&&(this.$tip=e(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},t.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},t.prototype.enable=function(){this.enabled=!0},t.prototype.disable=function(){this.enabled=!1},t.prototype.toggleEnabled=function(){this.enabled=!this.enabled},t.prototype.toggle=function(t){var n=this;t&&((n=e(t.currentTarget).data("bs."+this.type))||(n=new this.constructor(t.currentTarget,this.getDelegateOptions()),e(t.currentTarget).data("bs."+this.type,n))),t?(n.inState.click=!n.inState.click,n.isInStateTrue()?n.enter(n):n.leave(n)):n.tip().hasClass("in")?n.leave(n):n.enter(n)},t.prototype.destroy=function(){var e=this;clearTimeout(this.timeout),this.hide(function(){e.$element.off("."+e.type).removeData("bs."+e.type),e.$tip&&e.$tip.detach(),e.$tip=null,e.$arrow=null,e.$viewport=null,e.$element=null})};var n=e.fn.tooltip;e.fn.tooltip=function(n){return this.each(function(){var r=e(this),o=r.data("bs.tooltip"),i="object"==typeof n&&n;!o&&/destroy|hide/.test(n)||(o||r.data("bs.tooltip",o=new t(this,i)),"string"==typeof n&&o[n]())})},e.fn.tooltip.Constructor=t,e.fn.tooltip.noConflict=function(){return e.fn.tooltip=n,this}}(jQuery),function(e){"use strict";var t=function(e,t){this.init("popover",e,t)};if(!e.fn.tooltip)throw new Error("Popover requires tooltip.js");t.VERSION="3.3.7",t.DEFAULTS=e.extend({},e.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),(t.prototype=e.extend({},e.fn.tooltip.Constructor.prototype)).constructor=t,t.prototype.getDefaults=function(){return t.DEFAULTS},t.prototype.setContent=function(){var e=this.tip(),t=this.getTitle(),n=this.getContent();e.find(".popover-title")[this.options.html?"html":"text"](t),e.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof n?"html":"append":"text"](n),e.removeClass("fade top bottom left right in"),e.find(".popover-title").html()||e.find(".popover-title").hide()},t.prototype.hasContent=function(){return this.getTitle()||this.getContent()},t.prototype.getContent=function(){var e=this.$element,t=this.options;return e.attr("data-content")||("function"==typeof t.content?t.content.call(e[0]):t.content)},t.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var n=e.fn.popover;e.fn.popover=function(n){return this.each(function(){var r=e(this),o=r.data("bs.popover"),i="object"==typeof n&&n;!o&&/destroy|hide/.test(n)||(o||r.data("bs.popover",o=new t(this,i)),"string"==typeof n&&o[n]())})},e.fn.popover.Constructor=t,e.fn.popover.noConflict=function(){return e.fn.popover=n,this}}(jQuery),function(e){"use strict";function t(n,r){this.$body=e(document.body),this.$scrollElement=e(e(n).is(document.body)?window:n),this.options=e.extend({},t.DEFAULTS,r),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",e.proxy(this.process,this)),this.refresh(),this.process()}function n(n){return this.each(function(){var r=e(this),o=r.data("bs.scrollspy");o||r.data("bs.scrollspy",o=new t(this,"object"==typeof n&&n)),"string"==typeof n&&o[n]()})}t.VERSION="3.3.7",t.DEFAULTS={offset:10},t.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},t.prototype.refresh=function(){var t=this,n="offset",r=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),e.isWindow(this.$scrollElement[0])||(n="position",r=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var t=e(this),o=t.data("target")||t.attr("href"),i=/^#./.test(o)&&e(o);return i&&i.length&&i.is(":visible")&&[[i[n]().top+r,o]]||null}).sort(function(e,t){return e[0]-t[0]}).each(function(){t.offsets.push(this[0]),t.targets.push(this[1])})},t.prototype.process=function(){var e,t=this.$scrollElement.scrollTop()+this.options.offset,n=this.getScrollHeight(),r=this.options.offset+n-this.$scrollElement.height(),o=this.offsets,i=this.targets,a=this.activeTarget;if(this.scrollHeight!=n&&this.refresh(),t>=r)return a!=(e=i[i.length-1])&&this.activate(e);if(a&&t<o[0])return this.activeTarget=null,this.clear();for(e=o.length;e--;)a!=i[e]&&t>=o[e]&&(void 0===o[e+1]||t<o[e+1])&&this.activate(i[e])},t.prototype.activate=function(t){this.activeTarget=t,this.clear();var n=e(this.selector+'[data-target="'+t+'"],'+this.selector+'[href="'+t+'"]').parents("li").addClass("active");n.parent(".dropdown-menu").length&&(n=n.closest("li.dropdown").addClass("active")),n.trigger("activate.bs.scrollspy")},t.prototype.clear=function(){e(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var r=e.fn.scrollspy;e.fn.scrollspy=n,e.fn.scrollspy.Constructor=t,e.fn.scrollspy.noConflict=function(){return e.fn.scrollspy=r,this},e(window).on("load.bs.scrollspy.data-api",function(){e('[data-spy="scroll"]').each(function(){var t=e(this);n.call(t,t.data())})})}(jQuery),function(e){"use strict";function t(t){return this.each(function(){var r=e(this),o=r.data("bs.tab");o||r.data("bs.tab",o=new n(this)),"string"==typeof t&&o[t]()})}var n=function(t){this.element=e(t)};n.VERSION="3.3.7",n.TRANSITION_DURATION=150,n.prototype.show=function(){var t=this.element,n=t.closest("ul:not(.dropdown-menu)"),r=t.data("target");if(r||(r=(r=t.attr("href"))&&r.replace(/.*(?=#[^\s]*$)/,"")),!t.parent("li").hasClass("active")){var o=n.find(".active:last a"),i=e.Event("hide.bs.tab",{relatedTarget:t[0]}),a=e.Event("show.bs.tab",{relatedTarget:o[0]});if(o.trigger(i),t.trigger(a),!a.isDefaultPrevented()&&!i.isDefaultPrevented()){var s=e(r);this.activate(t.closest("li"),n),this.activate(s,s.parent(),function(){o.trigger({type:"hidden.bs.tab",relatedTarget:t[0]}),t.trigger({type:"shown.bs.tab",relatedTarget:o[0]})})}}},n.prototype.activate=function(t,r,o){function i(){a.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),t.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),s?t.addClass("in"):t.removeClass("fade"),t.parent(".dropdown-menu").length&&t.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),o&&o()}var a=r.find("> .active"),s=o&&e.support.transition&&(a.length&&a.hasClass("fade")||!!r.find("> .fade").length);a.length&&s?a.one("bsTransitionEnd",i).emulateTransitionEnd(n.TRANSITION_DURATION):i(),a.removeClass("in")};var r=e.fn.tab;
1e.fn.tab=t,e.fn.tab.Constructor=n,e.fn.tab.noConflict=function(){return e.fn.tab=r,this};var o=function(n){n.preventDefault(),t.call(e(this),"show")};e(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',o).on("click.bs.tab.data-api",'[data-toggle="pill"]',o)}(jQuery),function(e){"use strict";function t(t){return this.each(function(){var r=e(this),o=r.data("bs.affix");o||r.data("bs.affix",o=new n(this,"object"==typeof t&&t)),"string"==typeof t&&o[t]()})}var n=function(t,r){this.options=e.extend({},n.DEFAULTS,r),this.$target=e(this.options.target).on("scroll.bs.affix.data-api",e.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",e.proxy(this.checkPositionWithEventLoop,this)),this.$element=e(t),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};n.VERSION="3.3.7",n.RESET="affix affix-top affix-bottom",n.DEFAULTS={offset:0,target:window},n.prototype.getState=function(e,t,n,r){var o=this.$target.scrollTop(),i=this.$element.offset(),a=this.$target.height();if(null!=n&&"top"==this.affixed)return o<n&&"top";if("bottom"==this.affixed)return null!=n?!(o+this.unpin<=i.top)&&"bottom":!(o+a<=e-r)&&"bottom";var s=null==this.affixed;return null!=n&&o<=n?"top":null!=r&&(s?o:i.top)+(s?a:t)>=e-r&&"bottom"},n.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(n.RESET).addClass("affix");var e=this.$target.scrollTop(),t=this.$element.offset();return this.pinnedOffset=t.top-e},n.prototype.checkPositionWithEventLoop=function(){setTimeout(e.proxy(this.checkPosition,this),1)},n.prototype.checkPosition=function(){if(this.$element.is(":visible")){var t=this.$element.height(),r=this.options.offset,o=r.top,i=r.bottom,a=Math.max(e(document).height(),e(document.body).height());"object"!=typeof r&&(i=o=r),"function"==typeof o&&(o=r.top(this.$element)),"function"==typeof i&&(i=r.bottom(this.$element));var s=this.getState(a,t,o,i);if(this.affixed!=s){null!=this.unpin&&this.$element.css("top","");var u="affix"+(s?"-"+s:""),c=e.Event(u+".bs.affix");if(this.$element.trigger(c),c.isDefaultPrevented())return;this.affixed=s,this.unpin="bottom"==s?this.getPinnedOffset():null,this.$element.removeClass(n.RESET).addClass(u).trigger(u.replace("affix","affixed")+".bs.affix")}"bottom"==s&&this.$element.offset({top:a-t-i})}};var r=e.fn.affix;e.fn.affix=t,e.fn.affix.Constructor=n,e.fn.affix.noConflict=function(){return e.fn.affix=r,this},e(window).on("load",function(){e('[data-spy="affix"]').each(function(){var n=e(this),r=n.data();r.offset=r.offset||{},null!=r.offsetBottom&&(r.offset.bottom=r.offsetBottom),null!=r.offsetTop&&(r.offset.top=r.offsetTop),t.call(n,r)})})}(jQuery),function(){"use strict";var e,t,n,r,o,i,a,s,u,c,l,f,d,h=function(e){return function(){return e}},p={noop:function(){},noarg:function(e){return function(){return e()}},compose:function(e,t){return function(){return e(t.apply(null,arguments))}},constant:h,identity:function(e){return e},tripleEquals:function(e,t){return e===t},curry:function(e){for(var t=new Array(arguments.length-1),n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];var o=t.concat(n);return e.apply(null,o)}},not:function(e){return function(){return!e.apply(null,arguments)}},die:function(e){return function(){throw new Error(e)}},apply:function(e){return e()},call:function(e){e()},never:h(!1),always:h(!0)},m=p.never,g=p.always,v=function(){return y},y=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:m,isSome:m,isNone:g,getOr:n,getOrThunk:t,getOrDie:function(e){throw new Error(e||"error: getOrDie called on none.")},or:n,orThunk:t,map:v,ap:v,each:function(){},bind:v,flatten:v,exists:m,forall:g,filter:v,equals:e,equals_:e,toArray:function(){return[]},toString:p.constant("none()")};return Object.freeze&&Object.freeze(r),r}(),b=function(e){var t=function(){return 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:g,isNone:m,getOr:t,getOrThunk:t,getOrDie:t,or:n,orThunk:n,map:function(t){return b(t(e))},ap:function(t){return t.fold(v,function(t){return b(t(e))})},each:function(t){t(e)},bind:r,flatten:t,exists:r,forall:r,filter:function(t){return t(e)?o:y},equals:function(t){return t.is(e)},equals_:function(t,n){return t.fold(m,function(t){return n(e,t)})},toArray:function(){return[e]},toString:function(){return"some("+e+")"}};return o},w={some:b,none:v,from:function(e){return null===e||void 0===e?y:b(e)}},x=void 0===(e=Array.prototype.indexOf)?function(e,t){return R(e,t)}:function(t,n){return e.call(t,n)},C=function(e,t){return x(e,t)>-1},S=function(e,t){for(var n=e.length,r=new Array(n),o=0;o<n;o++)r[o]=t(e[o],o,e);return r},T=function(e,t){for(var n=0,r=e.length;n<r;n++)t(e[n],n,e)},E=function(e,t){for(var n=e.length-1;n>=0;n--)t(e[n],n,e)},k=function(e,t){for(var n=[],r=0,o=e.length;r<o;r++){var i=e[r];t(i,r,e)&&n.push(i)}return n},N=function(e,t){for(var n=0,r=e.length;n<r;n++)if(t(e[n],n,e))return w.some(n);return w.none()},R=function(e,t){for(var n=0,r=e.length;n<r;++n)if(e[n]===t)return n;return-1},_=Array.prototype.push,A=function(e){for(var t=[],n=0,r=e.length;n<r;++n){if(!Array.prototype.isPrototypeOf(e[n]))throw new Error("Arr.flatten item "+n+" was not an array, input
1: "+e);_.apply(t,e[n])}return t},D=function(e,t){for(var n=0,r=e.length;n<r;++n)if(!0!==t(e[n],n,e))return!1;return!0},O=Array.prototype.slice,P={map:S,each:T,eachr:E,partition:function(e,t){for(var n=[],r=[],o=0,i=e.length;o<i;o++){var a=e[o];(t(a,o,e)?n:r).push(a)}return{pass:n,fail:r}},filter:k,groupBy:function(e,t){if(0===e.length)return[];for(var n=t(e[0]),r=[],o=[],i=0,a=e.length;i<a;i++){var s=e[i],u=t(s);u!==n&&(r.push(o),o=[]),n=u,o.push(s)}return 0!==o.length&&r.push(o),r},indexOf:function(e,t){var n=x(e,t);return-1===n?w.none():w.some(n)},foldr:function(e,t,n){return E(e,function(e){n=t(n,e)}),n},foldl:function(e,t,n){return T(e,function(e){n=t(n,e)}),n},find:function(e,t){for(var n=0,r=e.length;n<r;n++){var o=e[n];if(t(o,n,e))return w.some(o)}return w.none()},findIndex:N,flatten:A,bind:function(e,t){var n=S(e,t);return A(n)},forall:D,exists:function(e,t){return N(e,t).isSome()},contains:C,equal:function(e,t){return e.length===t.length&&D(e,function(e,n){return e===t[n]})},reverse:function(e){var t=O.call(e,0);return t.reverse(),t},chunk:function(e,t){for(var n=[],r=0;r<e.length;r+=t){var o=e.slice(r,r+t);n.push(o)}return n},difference:function(e,t){return k(e,function(e){return!C(t,e)})},mapToObject: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},pure:function(e){return[e]},sort:function(e,t){var n=O.call(e,0);return n.sort(t),n},range:function(e,t){for(var n=[],r=0;r<e;r++)n.push(t(r));return n},head:function(e){return 0===e.length?w.none():w.some(e[0])},last:function(e){return 0===e.length?w.none():w.some(e[e.length-1])}},B="undefined"!=typeof window?window:Function("return this;")(),I={getOrDie:function(e,t){var n=function(e,t){return function(e,t){return function(e,t){for(var n=void 0!==t&&null!==t?t:B,r=0;r<e.length&&void 0!==n&&null!==n;++r)n=n[e[r]];return n}(e.split("."),t)}(e,t)}(e,t);if(void 0===n||null===n)throw e+" not available on this browser";return n}},L=function(){return I.getOrDie("URL")},M={createObjectURL:function(e){return L().createObjectURL(e)},revokeObjectURL:function(e){L().revokeObjectURL(e)}},H=navigator,F=H.userAgent,W=function(e){return"matchMedia"in window&&matchMedia(e).matches};u=/Android/.test(F),n=(n=!(t=/WebKit/.test(F))&&/MSIE/gi.test(F)&&/Explorer/gi.test(H.appName))&&/MSIE (\w+)\./.exec(F)[1],r=-1!==F.indexOf("Trident/")&&(-1!==F.indexOf("rv:")||-1!==H.appName.indexOf("Netscape"))&&11,o=-1!==F.indexOf("Edge/")&&!n&&!r&&12,n=n||r||o,i=!t&&!r&&/Gecko/.test(F),a=-1!==F.indexOf("Mac"),s=/(iPad|iPhone)/.test(F),c="FormData"in window&&"FileReader"in window&&"URL"in window&&!!M.createObjectURL,l=W("only screen and (max-device-width: 480px)")&&(u||s),f=W("only screen and (min-width: 800px)")&&(u||s),d=-1!==F.indexOf("Windows Phone"),o&&(t=!1);var j,$,z,q,U,V,X,Y,K,G,J,Q,Z,ee,te,ne,re,oe,ie,ae={opera:!1,webkit:t,ie:n,gecko:i,mac:a,iOS:s,android:u,contentEditable:!s||c||parseInt(F.match(/AppleWebKit\/(\d*)/)[1],10)>=534,transparentSrc:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",caretAfter:8!==n,range:window.getSelection&&"Range"in window,documentMode:n&&!o?document.documentMode||7:10,fileApi:c,ceFalse:!1===n||n>8,cacheSuffix:"",container:null,overrideViewPort:null,experimentalShadowDom:!1,canHaveCSP:!1===n||n>11,desktop:!l&&!f,windowsPhone:d},se=window.Promise?window.Promise:function(){function e(e,t){return function(){e.apply(t,arguments)}}var t=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},n=function(t){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof t)throw new TypeError("not a function");this._state=null,this._value=null,this._deferreds=[],u(t,e(i,this),e(a,this))},r=n.immediateFn||"function"==typeof setImmediate&&setImmediate||function(e){setTimeout(e,1)};function o(e){var t=this;null!==this._state?r(function(){var n=t._state?e.onFulfilled:e.onRejected;if(null!==n){var r;try{r=n(t._value)}catch(t){return void e.reject(t)}e.resolve(r)}else(t._state?e.resolve:e.reject)(t._value)}):this._deferreds.push(e)}function i(t){try{if(t===this)throw new TypeError("A promise cannot be resolved with itself.");if(t&&("object"==typeof t||"function"==typeof t)){var n=t.then;if("function"==typeof n)return void u(e(n,t),e(i,this),e(a,this))}this._state=!0,this._value=t,s.call(this)}catch(e){a.call(this,e)}}function a(e){this._state=!1,this._value=e,s.call(this)}function s(){for(var e=0,t=this._deferreds.length;e<t;e++)o.call(this,this._deferreds[e]);this._deferreds=null}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(e){if(r)return;r=!0,n(e)}}return n.prototype.catch=function(e){return this.then(null,e)},n.prototype.then=function(e,t){var r=this;return new n(function(n,i){o.call(r,new function(e,t,n,r){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=n,this.reject=r}(e,t,n,i))})},n.all=function(){var e=Array.prototype.slice.call(1===arguments.length&&t(arguments[0])?arguments[0]:arguments);return new n(function(t,n){if(0===e.length)return t([]);var r=e.length;
vendor: 3,650 bytes, line 1
1function o(i,a){try{if(a&&("object"==typeof a||"function"==typeof a)){var s=a.then;if("function"==typeof s)return void s.call(a,function(e){o(i,e)},n)}e[i]=a,0==--r&&t(e)}catch(e){n(e)}}for(var i=0;i<e.length;i++)o(i,e[i])})},n.resolve=function(e){return e&&"object"==typeof e&&e.constructor===n?e:new n(function(t){t(e)})},n.reject=function(e){return new n(function(t,n){n(e)})},n.race=function(e){return new n(function(t,n){for(var r=0,o=e.length;r<o;r++)e[r].then(t,n)})},n}(),ue=function(e,t){return"number"!=typeof t&&(t=0),setTimeout(e,t)},ce=function(e,t){return"number"!=typeof t&&(t=1),setInterval(e,t)},le=function(e,t){var n,r;return(r=function(){var r=arguments;clearTimeout(n),n=ue(function(){e.apply(this,r)},t)}).stop=function(){clearTimeout(n)},r},fe={requestAnimationFrame:function(e,t){j?j.then(e):j=new se(function(e){t||(t=document.body),function(e,t){var n,r=window.requestAnimationFrame,o=["ms","moz","webkit"];for(n=0;n<o.length&&!r;n++)r=window[o[n]+"RequestAnimationFrame"];r||(r=function(e){window.setTimeout(e,0)}),r(e,t)}(e,t)}).then(e)},setTimeout:ue,setInterval:ce,setEditorTimeout:function(e,t,n){return ue(function(){e.removed||t()},n)},setEditorInterval:function(e,t,n){var r;return r=ce(function(){e.removed?clearInterval(r):t()},n)},debounce:le,throttle:le,clearInterval:function(e){return clearInterval(e)},clearTimeout:function(e){return clearTimeout(e)}},de=/^(?:mouse|contextmenu)|click/,he={keyLocation:1,layerX:1,layerY:1,returnValue:1,webkitMovementX:1,webkitMovementY:1,keyIdentifier:1},pe=function(){return!1},me=function(){return!0},ge=function(e,t,n,r){e.addEventListener?e.addEventListener(t,n,r||!1):e.attachEvent&&e.attachEvent("on"+t,n)},ve=function(e,t,n,r){e.removeEventListener?e.removeEventListener(t,n,r||!1):e.detachEvent&&e.detachEvent("on"+t,n)},ye=function(e,t){var n,r,o,i=t||{};for(n in e)he[n]||(i[n]=e[n]);if(i.target||(i.target=i.srcElement||document),ae.experimentalShadowDom&&(i.target=(o=i.target,(r=e.path)&&r.length>0&&(o=r[0]),e.composedPath&&(r=e.composedPath())&&r.length>0&&(o=r[0]),o)),e&&de.test(e.type)&&void 0===e.pageX&&void 0!==e.clientX){var a=i.target.ownerDocument||document,s=a.documentElement,u=a.body;i.pageX=e.clientX+(s&&s.scrollLeft||u&&u.scrollLeft||0)-(s&&s.clientLeft||u&&u.clientLeft||0),i.pageY=e.clientY+(s&&s.scrollTop||u&&u.scrollTop||0)-(s&&s.clientTop||u&&u.clientTop||0)}return i.preventDefault=function(){i.isDefaultPrevented=me,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},i.stopPropagation=function(){i.isPropagationStopped=me,e&&(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0)},i.stopImmediatePropagation=function(){i.isImmediatePropagationStopped=me,i.stopPropagation()},!1===function(e){return e.isDefaultPrevented===me||e.isDefaultPrevented===pe}(i)&&(i.isDefaultPrevented=pe,i.isPropagationStopped=pe,i.isImmediatePropagationStopped=pe),"undefined"==typeof i.metaKey&&(i.metaKey=!1),i},be=function(e,t,n){var r=e.document,o={type:"ready"};if(n.domLoaded)t(o);else{var i=function(){return"complete"===r.readyState||"interactive"===r.readyState&&r.body},a=function(){n.domLoaded||(n.domLoaded=!0,t(o))},s=function(){i()&&(ve(r,"readystatechange",s),a())},u=function(){try{r.documentElement.doScroll("left")}catch(e){return void fe.setTimeout(u)}a()};!r.addEventListener||ae.ie&&ae.ie<11?(ge(r,"readystatechange",s),r.documentElement.doScroll&&e.self===e.top&&u()):i()?a():ge(e,"DOMContentLoaded",a),ge(e,"load",a)}},we=function(){var e,t,n,r,o,i=this,a={};t="mce-data-"+(+new Date).toString(32),r="onmouseenter"in document.documentElement,n="onfocusin"in document.documentElement,o={mouseenter:"mouseover",mouseleave:"mou
1seout"},e=1,i.domLoaded=!1,i.events=a;var s=function(e,t){var n,r,o,i,s=a[t];if(n=s&&s[e.type])for(r=0,o=n.length;r<o;r++)if((i=n[r])&&!1===i.func.call(i.scope,e)&&e.preventDefault(),e.isImmediatePropagationStopped())return};i.bind=function(u,c,l,f){var d,h,p,m,g,v,y,b=window,w=function(e){s(ye(e||b.event),d)};if(u&&3!==u.nodeType&&8!==u.nodeType){for(u[t]?d=u[t]:(d=e++,u[t]=d,a[d]={}),f=f||u,p=(c=c.split(" ")).length;p--;)v=w,g=y=!1,"DOMContentLoaded"===(m=c[p])&&(m="ready"),i.domLoaded&&"ready"===m&&"complete"===u.readyState?l.call(f,ye({type:m})):(r||(g=o[m])&&(v=function(e){var t,n;if(t=e.currentTarget,(n=e.relatedTarget)&&t.contains)n=t.contains(n);else for(;n&&n!==t;)n=n.parentNode;n||((e=ye(e||b.event)).type="mouseout"===e.type?"mouseleave":"mouseenter",e.target=t,s(e,d))}),n||"focusin"!==m&&"focusout"!==m||(y=!0,g="focusin"===m?"focus":"blur",v=function(e){(e=ye(e||b.event)).type="focus"===e.type?"focusin":"focusout",s(e,d)}),(h=a[d][m])?"ready"===m&&i.domLoaded?l({type:m}):h.push({func:l,scope:f}):(a[d][m]=h=[{func:l,scope:f}],h.fakeName=g,h.capture=y,h.nativeHandler=v,"ready"===m?be(u,v,i):ge(u,g||m,v,y)));return u=h=0,l}},i.unbind=function(e,n,r){var o,s,u,c,l,f;if(!e||3===e.nodeType||8===e.nodeType)return i;if(o=e[t]){if(f=a[o],n){for(u=(n=n.split(" ")).length;u--;)if(s=f[l=n[u]]){if(r)for(c=s.length;c--;)if(s[c].func===r){var d=s.nativeHandler,h=s.fakeName,p=s.capture;(s=s.slice(0,c).concat(s.slice(c+1))).nativeHandler=d,s.fakeName=h,s.capture=p,f[l]=s}r&&0!==s.length||(delete f[l],ve(e,s.fakeName||l,s.nativeHandler,s.capture))}}else{for(l in f)ve(e,(s=f[l]).fakeName||l,s.nativeHandler,s.capture);f={}}for(l in f)return i;delete a[o];try{delete e[t]}catch(n){e[t]=null}}return i},i.fire=function(e,n,r){var o;if(!e||3===e.nodeType||8===e.nodeType)return i;(r=ye(null,r)).type=n,r.target=e;do{(o=e[t])&&s(r,o),e=e.parentNode||e.ownerDocument||e.defaultView||e.parentWindow}while(e&&!r.isPropagationStopped());return i},i.clean=function(e){var n,r,o=i.unbind;if(!e||3===e.nodeType||8===e.nodeType)return i;if(e[t]&&o(e),e.getElementsByTagName||(e=e.document),e&&e.getElementsByTagName)for(o(e),n=(r=e.getElementsByTagName("*")).length;n--;)(e=r[n])[t]&&o(e);return i},i.destroy=function(){a={}},i.cancel=function(e){return e&&(e.preventDefault(),e.stopImmediatePropagation()),!1}};(we.Event=new we).bind(window,"ready",function(){});var xe="sizzle"+-new Date,Ce=window.document,Se=0,Te=0,Ee=ot(),ke=ot(),Ne=ot(),Re=function(e,t){return e===t&&(Q=!0),0},_e="undefined",Ae=1<<31,De={}.hasOwnProperty,Oe=[],Pe=Oe.pop,Be=Oe.push,Ie=Oe.push,Le=Oe.slice,Me=Oe.indexOf||function(e){for(var t=0,n=this.length;t<n;t++)if(this[t]===e)return t;return-1},He="[\\x20\\t\\r\\n\\f]",Fe="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",We="\\["+He+"*("+Fe+")(?:"+He+"*([*^$|!~]?=)"+He+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+Fe+"))|)"+He+"*\\]",je=":("+Fe+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+We+")*)|.*)\\)|)",$e=new RegExp("^"+He+"+|((?:^|[^\\\\])(?:\\\\.)*)"+He+"+$","g"),ze=new RegExp("^"+He+"*,"+He+"*"),qe=new RegExp("^"+He+"*([>+~]|"+He+")"+He+"*"),Ue=new RegExp("="+He+"*([^\\]'\"]*?)"+He+"*\\]","g"),Ve=new RegExp(je),Xe=new RegExp("^"+Fe+"$"),Ye={ID:new RegExp("^#("+Fe+")"),CLASS:new RegExp("^\\.("+Fe+")"),TAG:new RegExp("^("+Fe+"|[*])"),ATTR:new RegExp("^"+We),PSEUDO:new RegExp("^"+je),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+He+"*(even|odd|(([+-]|)(\\d*)n|)"+He+"*(?:([+-]|)"+He+"*(\\d+)|))"+He+"*\\)|)","i"),bool:new RegExp("^(?:checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped)$","i"),needsContext:new RegExp("^"+He+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+He+"*((?:-\\d)?\\d*)"+He+"*\\)|)(?=[^-]|$)","i")},Ke=/^(?:input|select|textarea|button)$/i,Ge=/^h\d$/i,Je=/^[^{]+\{\s*\[native \w/,Qe=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Ze=/[+~]/,et=/'|\\/g,tt=new RegExp("\\\\([\\da-f]{1,6}"+He+"?|("+He+")|.)","ig"),nt=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{Ie.apply(Oe=Le.call(Ce.childNodes),Ce.childNodes)}catch(e){Ie={apply:Oe.length?function(e,t){Be.apply(e,Le.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}var rt=function(e,t,n,r){var o,i,a,s,u,c,l,f,d,h;if((t?t.ownerDocument||t:Ce)!==ee&&Z(t),t=t||ee,n=n||[],!e||"string"!=typeof e)return n;if(1!==(s=t.nodeType)&&9!==s)return[];
vendor: 4,982 bytes, line 1
1if(ne&&!r){if(o=Qe.exec(e))if(a=o[1]){if(9===s){if(!(i=t.getElementById(a))||!i.parentNode)return n;if(i.id===a)return n.push(i),n}else if(t.ownerDocument&&(i=t.ownerDocument.getElementById(a))&&ie(t,i)&&i.id===a)return n.push(i),n}else{if(o[2])return Ie.apply(n,t.getElementsByTagName(e)),n;if((a=o[3])&&z.getElementsByClassName)return Ie.apply(n,t.getElementsByClassName(a)),n}if(z.qsa&&(!re||!re.test(e))){if(f=l=xe,d=t,h=9===s&&e,1===s&&"object"!==t.nodeName.toLowerCase()){for(c=X(e),(l=t.getAttribute("id"))?f=l.replace(et,"\\$&"):t.setAttribute("id",f),f="[id='"+f+"'] ",u=c.length;u--;)c[u]=f+dt(c[u]);d=Ze.test(e)&<(t.parentNode)||t,h=c.join(",")}if(h)try{return Ie.apply(n,d.querySelectorAll(h)),n}catch(e){}finally{l||t.removeAttribute("id")}}}return K(e.replace($e,"$1"),t,n,r)};function ot(){var e=[];return function t(n,r){return e.push(n+" ")>q.cacheLength&&delete t[e.shift()],t[n+" "]=r}}function it(e){return e[xe]=!0,e}function at(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||Ae)-(~e.sourceIndex||Ae);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function st(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function ut(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function ct(e){return it(function(t){return t=+t,it(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 lt(e){return e&&typeof e.getElementsByTagName!==_e&&e}for($ in z=rt.support={},V=rt.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},Z=rt.setDocument=function(e){var t,n=e?e.ownerDocument||e:Ce,r=n.defaultView;return n!==ee&&9===n.nodeType&&n.documentElement?(ee=n,te=n.documentElement,ne=!V(n),r&&r!==function(e){try{return e.top}catch(e){}return null}(r)&&(r.addEventListener?r.addEventListener("unload",function(){Z()},!1):r.attachEvent&&r.attachEvent("onunload",function(){Z()})),z.attributes=!0,z.getElementsByTagName=!0,z.getElementsByClassName=Je.test(n.getElementsByClassName),z.getById=!0,q.find.ID=function(e,t){if(typeof t.getElementById!==_e&&ne){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},q.filter.ID=function(e){var t=e.replace(tt,nt);return function(e){return e.getAttribute("id")===t}},q.find.TAG=z.getElementsByTagName?function(e,t){if(typeof t.getElementsByTagName!==_e)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},q.find.CLASS=z.getElementsByClassName&&function(e,t){if(ne)return t.getElementsByClassName(e)},oe=[],re=[],z.disconnectedMatch=!0,re=re.length&&new RegExp(re.join("|")),oe=oe.length&&new RegExp(oe.join("|")),t=Je.test(te.compareDocumentPosition),ie=t||Je.test(te.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},Re=t?function(e,t){if(e===t)return Q=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!z.sortDetached&&t.compareDocumentPosition(e)===r?e===n||e.ownerDocument===Ce&&ie(Ce,e)?-1:t===n||t.ownerDocument===Ce&&ie(Ce,t)?1:J?Me.call(J,e)-Me.call(J,t):0:4&r?-1:1)}:function(e,t){if(e===t)return Q=!0,0;var r,o=0,i=e.parentNode,a=t.parentNode,s=[e],u=[t];if(!i||!a)return e===n?-1:t===n?1:i?-1:a?1:J?Me.call(J,e)-Me.call(J,t):0;if(i===a)return at(e,t);for(r=e;r=r.parentNode;)s.unshift(r);for(r=t;r=r.parentNode;)u.unshift(r);for(;s[o]===u[o];)o++;return o?at(s[o],u[o]):s[o]===Ce?-1:u[o]===Ce?1:0},n):ee},rt.matches=function(e,t){return rt(e,null,null,t)},rt.matchesSelector=function(e,t){if((e.ownerDocument||e)!==ee&&Z(e),t=t.replace(Ue,"='$1']"),z.matchesSelector&&ne&&(!oe||!oe.test(t))&&(!re||!re.test(t)))try{var n=(void 0).call(e,t);if(n||z.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){}return rt(t,ee,null,[e]).length>0},rt.contains=function(e,t){return(e.ownerDocument||e)!==ee&&Z(e),ie(e,t)},rt.attr=function(e,t){(e.ownerDocument||e)!==ee&&Z(e);var n=q.attrHandle[t.toLowerCase()],r=n&&De.call(q.attrHandle,t.toLowerCase())?n(e,t,!ne):void 0;return void 0!==r?r:z.attributes||!ne?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},rt.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},rt.uniqueSort=function(e){var t,n=[],r=0,o=0;if(Q=!z.detectDuplicates,J=!z.sortStable&&e.slice(0),e.sort(Re),Q){for(;t=e[o++];)t===e[o]&&(r=n.push(o));for(;r--;)e.splice(n[r],1)}return J=null,e},U=rt.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+=U(e)}
vendor: 2,559 bytes, line 1
1else if(3===o||4===o)return e.nodeValue}else for(;t=e[r++];)n+=U(t);return n},(q=rt.selectors={cacheLength:50,createPseudo:it,match:Ye,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(tt,nt),e[3]=(e[3]||e[4]||e[5]||"").replace(tt,nt),"~="===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]||rt.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]&&rt.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return Ye.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&Ve.test(n)&&(t=X(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(tt,nt).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=Ee[e+" "];return t||(t=new RegExp("(^|"+He+")"+e+"("+He+"|$)"))&&Ee(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==_e&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var o=rt.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),s="of-type"===t;return 1===r&&0===o?function(e){return!!e.parentNode}:function(t,n,u){var c,l,f,d,h,p,m=i!==a?"nextSibling":"previousSibling",g=t.parentNode,v=s&&t.nodeName.toLowerCase(),y=!u&&!s;if(g){if(i){for(;m;){for(f=t;f=f[m];)if(s?f.nodeName.toLowerCase()===v:1===f.nodeType)return!1;p=m="only"===e&&!p&&"nextSibling"}return!0}if(p=[a?g.firstChild:g.lastChild],a&&y){for(h=(c=(l=g[xe]||(g[xe]={}))[e]||[])[0]===Se&&c[1],d=c[0]===Se&&c[2],f=h&&g.childNodes[h];f=++h&&f&&f[m]||(d=h=0)||p.pop();)if(1===f.nodeType&&++d&&f===t){l[e]=[Se,h,d];break}}else if(y&&(c=(t[xe]||(t[xe]={}))[e])&&c[0]===Se)d=c[1];else for(;(f=++h&&f&&f[m]||(d=h=0)||p.pop())&&((s?f.nodeName.toLowerCase()!==v:1!==f.nodeType)||!++d||(y&&((f[xe]||(f[xe]={}))[e]=[Se,d]),f!==t)););return(d-=o)===r||d%r==0&&d/r>=0}}},PSEUDO:function(e,t){var n,r=q.pseudos[e]||q.setFilters[e.toLowerCase()]||rt.error("unsupported pseudo: "+e);return r[xe]?r(t):r.length>
vendor: 4,273 bytes, line 1
11?(n=[e,e,"",t],q.setFilters.hasOwnProperty(e.toLowerCase())?it(function(e,n){for(var o,i=r(e,t),a=i.length;a--;)e[o=Me.call(e,i[a])]=!(n[o]=i[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:it(function(e){var t=[],n=[],r=Y(e.replace($e,"$1"));return r[xe]?it(function(e,t,n,o){for(var i,a=r(e,null,o,[]),s=e.length;s--;)(i=a[s])&&(e[s]=!(t[s]=i))}):function(e,o,i){return t[0]=e,r(t,null,i,n),!n.pop()}}),has:it(function(e){return function(t){return rt(e,t).length>0}}),contains:it(function(e){return e=e.replace(tt,nt),function(t){return(t.textContent||t.innerText||U(t)).indexOf(e)>-1}}),lang:it(function(e){return Xe.test(e||"")||rt.error("unsupported lang: "+e),e=e.replace(tt,nt).toLowerCase(),function(t){var n;do{if(n=ne?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(e){var t=window.location&&window.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===te},focus:function(e){return e===ee.activeElement&&(!ee.hasFocus||ee.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return!1===e.disabled},disabled:function(e){return!0===e.disabled},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!q.pseudos.empty(e)},header:function(e){return Ge.test(e.nodeName)},input:function(e){return Ke.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:ct(function(){return[0]}),last:ct(function(e,t){return[t-1]}),eq:ct(function(e,t,n){return[n<0?n+t:n]}),even:ct(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ct(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ct(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:ct(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=q.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})q.pseudos[$]=st($);for($ in{submit:!0,reset:!0})q.pseudos[$]=ut($);function ft(){}function dt(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function ht(e,t,n){var r=t.dir,o=n&&"parentNode"===r,i=Te++;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 s,u,c=[Se,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((s=(u=t[xe]||(t[xe]={}))[r])&&s[0]===Se&&s[1]===i)return c[2]=s[2];if(u[r]=c,c[2]=e(t,n,a))return!0}}}function pt(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 mt(e,t,n,r,o){for(var i,a=[],s=0,u=e.length,c=null!=t;s<u;s++)(i=e[s])&&(n&&!n(i,r,o)||(a.push(i),c&&t.push(s)));return a}function gt(e,t,n,r,o,i){return r&&!r[xe]&&(r=gt(r)),o&&!o[xe]&&(o=gt(o,i)),it(function(i,a,s,u){var c,l,f,d=[],h=[],p=a.length,m=i||function(e,t,n){for(var r=0,o=t.length;r<o;r++)rt(e,t[r],n);return n}(t||"*",s.nodeType?[s]:s,[]),g=!e||!i&&t?m:mt(m,d,e,s,u),v=n?o||(i?e:p||r)?[]:a:g;if(n&&n(g,v,s,u),r)for(c=mt(v,h),r(c,[],s,u),l=c.length;l--;)(f=c[l])&&(v[h[l]]=!(g[h[l]]=f));if(i){if(o||e){if(o){for(c=[],l=v.length;l--;)(f=v[l])&&c.push(g[l]=f);o(null,v=[],c,u)}for(l=v.length;l--;)(f=v[l])&&(c=o?Me.call(i,f):d[l])>-1&&(i[c]=!(a[c]=f))}}else v=mt(v===a?v.splice(p,v.length):v),o?o(null,a,v,u):Ie.apply(a,v)})}function vt(e){for(var t,n,r,o=e.length,i=q.relative[e[0].type],a=i||q.relative[" "],s=i?1:0,u=ht(function(e){return e===t},a,!0),c=ht(function(e){return Me.call(t,e)>-1},a,!0),l=[function(e,n,r){return!i&&(r||n!==G)||((t=n).nodeType?u(e,n,r):c(e,n,r))}];s<o;s++)if(n=q.relative[e[s].type])l=[ht(pt(l),n)];else{if((n=q.filter[e[s].type].apply(null,e[s].matches))[xe]){for(r=++s;r<o&&!q.relative[e[r].type];r++);return gt(s>1&&pt(l),s>1&&dt(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace($e,"$1"),n,s<r&&vt(e.slice(s,r)),r<o&&vt(e=e.slice(r)),r<o&&dt(e))}
vendor: 4,897 bytes, line 1
1l.push(n)}return pt(l)}ft.prototype=q.filters=q.pseudos,q.setFilters=new ft,X=rt.tokenize=function(e,t){var n,r,o,i,a,s,u,c=ke[e+" "];if(c)return t?0:c.slice(0);for(a=e,s=[],u=q.preFilter;a;){for(i in n&&!(r=ze.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(o=[])),n=!1,(r=qe.exec(a))&&(n=r.shift(),o.push({value:n,type:r[0].replace($e," ")}),a=a.slice(n.length)),q.filter)!(r=Ye[i].exec(a))||u[i]&&!(r=u[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?rt.error(e):ke(e,s).slice(0)},Y=rt.compile=function(e,t){var n,r=[],o=[],i=Ne[e+" "];if(!i){for(t||(t=X(e)),n=t.length;n--;)(i=vt(t[n]))[xe]?r.push(i):o.push(i);(i=Ne(e,function(e,t){var n=t.length>0,r=e.length>0,o=function(o,i,a,s,u){var c,l,f,d=0,h="0",p=o&&[],m=[],g=G,v=o||r&&q.find.TAG("*",u),y=Se+=null==g?1:Math.random()||.1,b=v.length;for(u&&(G=i!==ee&&i);h!==b&&null!=(c=v[h]);h++){if(r&&c){for(l=0;f=e[l++];)if(f(c,i,a)){s.push(c);break}u&&(Se=y)}n&&((c=!f&&c)&&d--,o&&p.push(c))}if(d+=h,n&&h!==d){for(l=0;f=t[l++];)f(p,m,i,a);if(o){if(d>0)for(;h--;)p[h]||m[h]||(m[h]=Pe.call(s));m=mt(m)}Ie.apply(s,m),u&&!o&&m.length>0&&d+t.length>1&&rt.uniqueSort(s)}return u&&(Se=y,G=g),p};return n?it(o):o}(o,r))).selector=e}return i},K=rt.select=function(e,t,n,r){var o,i,a,s,u,c="function"==typeof e&&e,l=!r&&X(e=c.selector||e);if(n=n||[],1===l.length){if((i=l[0]=l[0].slice(0)).length>2&&"ID"===(a=i[0]).type&&z.getById&&9===t.nodeType&&ne&&q.relative[i[1].type]){if(!(t=(q.find.ID(a.matches[0].replace(tt,nt),t)||[])[0]))return n;c&&(t=t.parentNode),e=e.slice(i.shift().value.length)}for(o=Ye.needsContext.test(e)?0:i.length;o--&&!q.relative[s=(a=i[o]).type];)if((u=q.find[s])&&(r=u(a.matches[0].replace(tt,nt),Ze.test(i[0].type)&<(t.parentNode)||t))){if(i.splice(o,1),!(e=r.length&&dt(i)))return Ie.apply(n,r),n;break}}return(c||Y(e,l))(r,t,!ne,n,Ze.test(e)&<(t.parentNode)||t),n},z.sortStable=xe.split("").sort(Re).join("")===xe,z.detectDuplicates=!!Q,Z(),z.sortDetached=!0;var yt=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},bt=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(!1===t.call(n,e[r],r,e))return 0}else for(r in e)if(e.hasOwnProperty(r)&&!1===t.call(n,e[r],r,e))return 0;return 1},wt=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},xt={isArray:yt,toArray:function(e){var t,n,r=e;if(!yt(e))for(r=[],t=0,n=e.length;t<n;t++)r[t]=e[t];return r},each:bt,map:function(e,t){var n=[];return bt(e,function(r,o){n.push(t(r,o,e))}),n},filter:function(e,t){var n=[];return bt(e,function(r,o){t&&!t(r,o,e)||n.push(r)}),n},indexOf: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},reduce: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},findIndex:wt,find:function(e,t,n){var r=wt(e,t,n);if(-1!==r)return e[r]},last:function(e){return e[e.length-1]}},Ct=/^\s*|\s*$/g,St=function(e){return null===e||void 0===e?"":(""+e).replace(Ct,"")},Tt=function(e,t){return t?!("array"!==t||!xt.isArray(e))||typeof e===t:void 0!==e},Et=function(e,t,n,r){r=r||this,e&&(n&&(e=e[n]),xt.each(e,function(e,o){if(!1===t.call(r,e,o,n))return!1;Et(e,t,n,r)}))},kt={trim:St,isArray:xt.isArray,is:Tt,toArray:xt.toArray,makeMap: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},each:xt.each,map:xt.map,grep:xt.filter,inArray:xt.indexOf,hasOwn:function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},extend:function(e,t){for(var n,r,o,i=[],a=2;a<arguments.length;a++)i[a-2]=arguments[a];var s,u=arguments;for(n=1,r=u.length;n<r;n++)for(o in t=u[n])t.hasOwnProperty(o)&&void 0!==(s=t[o])&&(e[o]=s);return e},create:function(e,t,n){var r,o,i,a,s,u=0;if(e=/^((static) )?([\w.]+)(:([\w.]+))?/.exec(e),i=e[3].match(/(^|\.)(\w+)$/i)[2],!(o=this.createNS(e[3].replace(/\.\w+$/,""),n))[i]){if("static"===e[2])return o[i]=t,void(this.onCreate&&this.onCreate(e[2],e[3],o[i]));t[i]||(t[i]=function(){},u=1),o[i]=t[i],this.extend(o[i].prototype,t),e[5]&&(r=this.resolve(e[5]).prototype,a=e[5].match(/\.(\w+)$/i)[1],s=o[i],o[i]=u?function(){return r[a].apply(this,arguments)}:function(){return this.parent=r[a],s.apply(this,arguments)},o[i].prototype[i]=o[i],this.each(r,function(e,t){o[i].prototype[t]=r[t]}),this.each(t,function(e,t){r[t]?o[i].prototype[t]=function(){return this.parent=r[t],e.apply(this,arguments)}:t!==i&&(o[i].prototype[t]=e)})),this.each(t.static,function(e,t){o[i][t]=e})}},walk:Et,createNS:function(e,t){var n,r;for(t=t||window,e=e.split("."),n=0;n<e.length;n++)t[r=e[n]]||(t[r]={}),t=t[r];return t},resolve:function(e,t){var n,r;for(t=t||window,n=0,r=(e=e.split(".")).length;n<r&&(t=t[e[n]]);n++);return t},explode:function(e,t){return!e||Tt(e,"array")?e:xt.map(e.split(t||","),St)}
1,_addCacheSuffix:function(e){var t=ae.cacheSuffix;return t&&(e+=(-1===e.indexOf("?")?"?":"&")+t),e}},Nt=document,Rt=Array.prototype.push,_t=Array.prototype.slice,At=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,Dt=we.Event,Ot=kt.makeMap("children,contents,next,prev"),Pt=function(e){return"undefined"!=typeof e},Bt=function(e){return"string"==typeof e},It=function(e,t){var n,r,o;for(o=(t=t||Nt).createElement("div"),n=t.createDocumentFragment(),o.innerHTML=e;r=o.firstChild;)n.appendChild(r);return n},Lt=function(e,t,n,r){var o;if(Bt(t))t=It(t,Gt(e[0]));else if(t.length&&!t.nodeType){if(t=Ut.makeArray(t),r)for(o=t.length-1;o>=0;o--)Lt(e,t[o],n,r);else for(o=0;o<t.length;o++)Lt(e,t[o],n,r);return e}if(t.nodeType)for(o=e.length;o--;)n.call(e[o],t);return e},Mt=function(e,t){return e&&t&&-1!==(" "+e.className+" ").indexOf(" "+t+" ")},Ht=function(e,t,n){var r,o;return t=Ut(t)[0],e.each(function(){n&&r===this.parentNode?o.appendChild(this):(r=this.parentNode,o=t.cloneNode(!1),this.parentNode.insertBefore(o,this),o.appendChild(this))}),e},Ft=kt.makeMap("fillOpacity fontWeight lineHeight opacity orphans widows zIndex zoom"," "),Wt=kt.makeMap("checked compact declare defer disabled ismap multiple nohref noshade nowrap readonly selected"," "),jt={for:"htmlFor",class:"className",readonly:"readOnly"},$t={float:"cssFloat"},zt={},qt={},Ut=function(e,t){return new Ut.fn.init(e,t)},Vt=/^\s*|\s*$/g,Xt=function(e){return null===e||void 0===e?"":(""+e).replace(Vt,"")},Yt=function(e,t){var n,r,o,i;if(e)if(void 0===(n=e.length)){for(r in e)if(e.hasOwnProperty(r)&&!1===t.call(i=e[r],r,i))break}else for(o=0;o<n&&!1!==t.call(i=e[o],o,i);o++);return e},Kt=function(e,t){var n=[];return Yt(e,function(e,r){t(r,e)&&n.push(r)}),n},Gt=function(e){return e?9===e.nodeType?e:e.ownerDocument:Nt};Ut.fn=Ut.prototype={constructor:Ut,selector:"",context:null,length:0,init:function(e,t){var n,r;if(!e)return this;if(e.nodeType)return this.context=this[0]=e,this.length=1,this;if(t&&t.nodeType)this.context=t;else{if(t)return Ut(e).attr(t);this.context=t=document}if(Bt(e)){if(this.selector=e,!(n="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:At.exec(e)))return Ut(t).find(e);if(n[1])for(r=It(e,Gt(t)).firstChild;r;)Rt.call(this,r),r=r.nextSibling;else{if(!(r=Gt(t).getElementById(n[2])))return this;if(r.id!==n[2])return this.find(e);this.length=1,this[0]=r}}else this.add(e,!1);return this},toArray:function(){return kt.toArray(this)},add:function(e,t){var n,r;if(Bt(e))return this.add(Ut(e));if(!1!==t)for(n=Ut.unique(this.toArray().concat(Ut.makeArray(e))),this.length=n.length,r=0;r<n.length;r++)this[r]=n[r];else Rt.apply(this,Ut.makeArray(e));return this},attr:function(e,t){var n,r=this;if("object"==typeof e)Yt(e,function(e,t){r.attr(e,t)});else{if(!Pt(t)){if(r[0]&&1===r[0].nodeType){if((n=zt[e])&&n.get)return n.get(r[0],e);if(Wt[e])return r.prop(e)?e:void 0;null===(t=r[0].getAttribute(e,2))&&(t=void 0)}return t}this.each(function(){var n;if(1===this.nodeType){if((n=zt[e])&&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("object"==typeof(e=jt[e]||e))Yt(e,function(e,t){n.prop(e,t)});else{if(!Pt(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)Yt(e,function(e,t){o.css(e,t)});else if(Pt(t))e=i(e),"number"!=typeof t||Ft[e]||(t=t.toString()+"px"),o.each(function(){var n=this.style;if((r=qt[e])&&r.set)r.set(this,t);else{try{this.style[$t[e]||e]=t}catch(e){}null!==t&&""!==t||(n.removeProperty?n.removeProperty(a(e)):n.removeAttribute(e))}});else{if(n=o[0],(r=qt[e])&&r.get)return r.get(n);if(n.ownerDocument.defaultView)try{return n.ownerDocument.defaultView.getComputedStyle(n,null).getPropertyValue(a(e))}catch(e){return}else if(n.currentStyle)return n.currentStyle[i(e)]}return o},remove:function(){for(var e,t=this.length;t--;)Dt.clean(e=this[t]),e.parentNode&&e.parentNode.removeChild(e);return this},empty:function(){for(var e,t=this.length;t--;)for(e=this[t];e.firstChild;)e.removeChild(e.firstChild);return this},html:function(e){var t;if(Pt(e)){t=this.length;try{for(;t--;)this[t].innerHTML=e}catch(n){Ut(this[t]).empty().append(e)}return this}return this[0]?this[0].innerHTML:""},text:function(e){var t;if(Pt(e)){for(t=this.length;t--;)"innerText"in this[t]?this[t].innerText=e:this[0].textContent=e;return this}return this[0]?this[0].innerText||this[0].textContent:""},append:function(){return Lt(this,arguments,function(e){(1===this.nodeType||this.host&&1===this.host.nodeType)&&this.appendChild(e)})},prepend:function(){return Lt(this,arguments,function(e){(1===this.nodeType||this.host&&1===this.host.nodeType)&&this.insertBefore(e,this.firstChild)},!0)},before:function(){return this[0]&&this[0].parentNode?Lt(this,arguments,function(e){this.parentNode.insertBefore(e,this)}):this},after:function(){return this[0]&&this[0].parentNode?Lt(this,arguments,function(e){this.parentNode.insertBefore(e,this.nextSibling)},!0):this},appendTo:function(e){return Ut(e).append(this),this},prependTo:function(e){return Ut(e).prepend(this),this},replaceWith:function(e){return this.before(e).remove()},wrap:function(e){return Ht(this,e)},wrapAll:function(e){return Ht(this,e,!0)},wrapInner:function(e){return this.each(function(){Ut(this).contents().wrapAll(e)}),this},unwrap:function(){return this.parent().each(function(){Ut(this).replaceWith(this.childNodes)})},clone:function(){var e=[];return this.each(function(){e.push(this.cloneNode(!0))}),Ut(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:(-1!==e.indexOf(" ")?Yt(e.split(" "),function(){n.toggleClass(this,t)}):n.each(function(n,r){var o,i;(i=Mt(r,e))!==t&&(o=r.className,i?r.className=Xt((" "+o+" ").replace(" "+e+" "," ")):r.className+=o?" "+e:e)}),n)},hasClass:function(e){return Mt(this[0],e)},each:function(e){return Yt(this,e)},on:function(e,t){return this.each(function(){Dt.bind(this,e,t)})},off:function(e,t){return this.each(function(){Dt.unbind(this,e,t)})},trigger:function(e){return this.each(function(){"object"==typeof e?Dt.fire(this,e.type,e):Dt.fire(this,e)})},show:function(){return this.css("display","")},hide:function(){return this.css("display","none")},slice:function(){return new Ut(_t.apply(this,arguments))},eq:function(e){return-1===e?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++)Ut.find(e,this[t],r);return Ut(r)},filter:function(e){return Ut("function"==typeof e?Kt(this.toArray(),function(t,n){return e(n,t)}):Ut.filter(e,this.toArray()))},closest:function(e){var t=[];return e instanceof Ut&&(e=e[0]),this.each(function(n,r){for(;r;){if("string"==typeof e&&Ut(r).is(e)){t.push(r);break}if(r===e){t.push(r);break}r=r.parentNode}}),Ut(t)},offset:function(e){var t,n,r,o,i=0,a=0;return e?this.css(e):((t=this[0])&&(r=(n=t.ownerDocument).documentElement,t.getBoundingClientRect&&(i=(o=t.getBoundingClientRect()).left+(r.scrollLeft||n.body.scrollLeft)-r.clientLeft,a=o.top+(r.scrollTop||n.body.scrollTop)-r.clientTop)),{left:i,top:a})},push:Rt,sort:[].sort,splice:[].splice},kt.extend(Ut,{extend:kt.extend,makeArray:function(e){return(t=e)&&t===t.window||e.nodeType?[e]:kt.toArray(e);var t},inArray: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}
1,isArray:kt.isArray,each:Yt,trim:Xt,grep:Kt,find:rt,expr:rt.selectors,unique:rt.uniqueSort,text:rt.getText,contains:rt.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 1===t.length?Ut.find.matchesSelector(t[0],e)?[t[0]]:[]:Ut.find.matches(e,t)}});var Jt=function(e,t,n){var r=[],o=e[t];for("string"!=typeof n&&n instanceof Ut&&(n=n[0]);o&&9!==o.nodeType;){if(void 0!==n){if(o===n)break;if("string"==typeof n&&Ut(o).is(n))break}1===o.nodeType&&r.push(o),o=o[t]}return r},Qt=function(e,t,n,r){var o=[];for(r instanceof Ut&&(r=r[0]);e;e=e[t])if(!n||e.nodeType===n){if(void 0!==r){if(e===r)break;if("string"==typeof r&&Ut(e).is(r))break}o.push(e)}return o},Zt=function(e,t,n){for(e=e[t];e;e=e[t])if(e.nodeType===n)return e;return null};Yt({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return Jt(e,"parentNode")},next:function(e){return Zt(e,"nextSibling",1)},prev:function(e){return Zt(e,"previousSibling",1)},children:function(e){return Qt(e.firstChild,"nextSibling",1)},contents:function(e){return kt.toArray(("iframe"===e.nodeName?e.contentDocument||e.contentWindow.document:e).childNodes)}},function(e,t){Ut.fn[e]=function(n){var r=[];return this.each(function(){var e=t.call(r,this,n,r);e&&(Ut.isArray(e)?r.push.apply(r,e):r.push(e))}),this.length>1&&(Ot[e]||(r=Ut.unique(r)),0===e.indexOf("parents")&&(r=r.reverse())),r=Ut(r),n?r.filter(n):r}}),Yt({parentsUntil:function(e,t){return Jt(e,"parentNode",t)},nextUntil:function(e,t){return Qt(e,"nextSibling",1,t).slice(1)},prevUntil:function(e,t){return Qt(e,"previousSibling",1,t).slice(1)}},function(e,t){Ut.fn[e]=function(n,r){var o=[];return this.each(function(){var e=t.call(o,this,n,o);e&&(Ut.isArray(e)?o.push.apply(o,e):o.push(e))}),this.length>1&&(o=Ut.unique(o),0!==e.indexOf("parents")&&"prevUntil"!==e||(o=o.reverse())),o=Ut(o),r?o.filter(r):o}}),Ut.fn.is=function(e){return!!e&&this.filter(e).length>0},Ut.fn.init.prototype=Ut.fn,Ut.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 Ut.extend(n,this),n};var en=function(e,t,n){Yt(n,function(n,r){e[n]=e[n]||{},e[n][t]=r})};ae.ie&&ae.ie<8&&(en(zt,"get",{maxlength:function(e){var t=e.maxLength;if(2147483647!==t)return t},size:function(e){var t=e.size;if(20!==t)return t},class:function(e){return e.className},style:function(e){var t=e.style.cssText;if(0!==t.length)return t}}),en(zt,"set",{class:function(e,t){e.className=t},style:function(e,t){e.style.cssText=t}})),ae.ie&&ae.ie<9&&($t.float="styleFloat",en(qt,"set",{opacity:function(e,t){var n=e.style;null===t||""===t?n.removeAttribute("filter"):(n.zoom=1,n.filter="alpha(opacity="+100*t+")")}})),Ut.attrHooks=zt,Ut.cssHooks=qt;var tn,nn=function(e){var t,n=!1;return function(){return n||(n=!0,t=e.apply(null,arguments)),t}},rn=function(){return on(0,0)},on=function(e,t){return{major:e,minor:t}},an=function(e,t){var n=String(t).toLowerCase();return 0===e.length?rn():function(t,n){var r=function(e,t){for(var n=0;n<e.length;n++){var r=e[n];if(r.test(t))return r}}(e,n);if(!r)return{major:0,minor:0};var o=function(e){return Number(n.replace(r,"$"+e))};return on(o(1),o(2))}(0,n)},sn=rn,un=function(e,t){return function(){return t===e}},cn=function(e){var t=e.current;return{current:t,version:e.version,isEdge:un("Edge",t),isChrome:un("Chrome",t),isIE:un("IE",t),isOpera:un("Opera",t),isFirefox:un("Firefox",t),isSafari:un("Safari",t)}},ln=function(){return cn({current:void 0,version:sn()})},fn=cn,dn=(p.constant("Edge"),p.constant("Chrome"),p.constant("IE"),p.constant("Opera"),p.constant("Firefox"),p.constant("Safari"),function(e,t){return function(){return t===e}}),hn=function(e){var t=e.current;return{current:t,version:e.version,isWindows:dn("Windows",t),isiOS:dn("iOS",t),isAndroid:dn("Android",t),isOSX:dn("OSX",t),isLinux:dn("Linux",t),isSolaris:dn("Solaris",t),isFreeBSD:dn("FreeBSD",t)}},pn=function(){return hn({current:void 0,version:sn()})},mn=hn,gn=(p.constant("Windows"),p.constant("iOS"),p.constant("Android"),p.constant("Linux"),p.constant("OSX"),p.constant("Solaris"),p.constant("FreeBSD"),function(e,t){var n=String(t).toLowerCase();return P.find(e,function(e){return e.search(n)})}),vn=function(e,t){return-1!==e.indexOf(t)},yn=function(e){return e.replace(/^\s+|\s+$/g,"")},bn=/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,wn=function(e){return function(t){return vn(t,e)}},xn=[{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]+).*/,bn],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:[bn,/.*?opera\/([0-9]+)\.([0-9]+).*/],search:wn("opera")},{name:"Firefox",versionRegexes:[/.*?firefox\/\ ?([0-9]+)\.([0-9]+).*/],search:wn("firefox")},{name:"Safari",versionRegexes:[bn,/.*?cpu os ([0-9]+)_([0-9]+).*/],search:function(e){return(vn(e,"safari")||vn(e,"mobile/"))&&vn(e,"applewebkit")}}],Cn=[{name:"Windows",search:wn("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:wn("android"),versionRegexes:[/.*?android\ ?([0-9]+)\.([0-9]+).*/]},{name:"OSX",search:wn("os x"),versionRegexes:[/.*?os\ x\ ?([0-9]+)_([0-9]+).*/]},{name:"Linux",search:wn("linux"),versionRegexes:[]},{name:"Solaris",search:wn("sunos"),versionRegexes:[]},{name:"FreeBSD",search:wn("freebsd"),versionRegexes:[]}],Sn={browsers:p.constant(xn),oses:p.constant(Cn)},Tn={detect:nn(function(){return function(e){var t=Sn.browsers(),n=Sn.oses(),r=function(e,t){return gn(e,t).map(function(e){var n=an(e.versionRegexes,t);return{current:e.name,version:n}})}(t,e).fold(ln,fn),o=function(e,t){return gn(e,t).map(function(e){var n=an(e.versionRegexes,t);return{current:e.name,version:n}})}(n,e).fold(pn,mn);return{browser:r,os:o,deviceType:function(e,t,n){var r=e.isiOS()&&!0===/ipad/i.test(n),o=e.isiOS()&&!r,i=e.isAndroid()&&3===e.version.major,a=e.isAndroid()&&4===e.version.major,s=r||i||a&&!0===/mobile/i.test(n),u=e.isiOS()||e.isAndroid(),c=u&&!s,l=t.isSafari()&&e.isiOS()&&!1===/safari/i.test(n);return{isiPad:p.constant(r),isiPhone:p.constant(o),isTablet:p.constant(s),isPhone:p.constant(c),isTouch:p.constant(u),isAndroid:e.isAndroid,isiOS:e.isiOS,isWebView:p.constant(l)}}(o,r,e)}}(navigator.userAgent)})},En=function(e){if(null===e||void 0===e)throw new Error("Node cannot be null or undefined");
1return{dom:p.constant(e)}},kn=function(e,t){var n=(t||document).createElement("div");if(n.innerHTML=e,!n.hasChildNodes()||n.childNodes.length>1)throw console.error("HTML does not have a single root node",e),"HTML must have a single root node";return En(n.childNodes[0])},Nn=function(e,t){var n=(t||document).createElement(e);return En(n)},Rn=function(e,t){var n=(t||document).createTextNode(e);return En(n)},_n=En,An=function(e){return e.dom().nodeName.toLowerCase()},Dn=function(e){return e.dom().nodeType},On=function(e){return function(t){return Dn(t)===e}},Pn=On(1),Bn=On(3),In=On(9),Ln={name:An,type:Dn,value:function(e){return e.dom().nodeValue},isElement:Pn,isText:Bn,isDocument:In,isComment:function(e){return 8===Dn(e)||"#comment"===An(e)}},Mn=function(e){return function(t){return function(e){if(null===e)return"null";var t=typeof e;return"object"===t&&Array.prototype.isPrototypeOf(e)?"array":"object"===t&&String.prototype.isPrototypeOf(e)?"string":t}(t)===e}},Hn={isString:Mn("string"),isObject:Mn("object"),isArray:Mn("array"),isNull:Mn("null"),isBoolean:Mn("boolean"),isUndefined:Mn("undefined"),isFunction:Mn("function"),isNumber:Mn("number")},Fn=void 0===(tn=Object.keys)?function(e){var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}:tn,Wn=function(e,t){for(var n=Fn(e),r=0,o=n.length;r<o;r++){var i=n[r];t(e[i],i,e)}},jn=function(e,t){var n={};return Wn(e,function(r,o){var i=t(r,o,e);n[i.k]=i.v}),n},$n=function(e,t){var n=[];return Wn(e,function(e,r){n.push(t(e,r))}),n},zn=function(e){return $n(e,function(e){return e})},qn={bifilter:function(e,t){var n={},r={};return Wn(e,function(e,o){(t(e,o)?n:r)[o]=e}),{t:n,f:r}},each:Wn,map:function(e,t){return jn(e,function(e,n,r){return{k:n,v:t(e,n,r)}})},mapToArray:$n,tupleMap:jn,find:function(e,t){for(var n=Fn(e),r=0,o=n.length;r<o;r++){var i=n[r],a=e[i];if(t(a,i,e))return w.some(a)}return w.none()},keys:Fn,values:zn,size:function(e){return zn(e).length}},Un=function(e,t,n){if(!(Hn.isString(n)||Hn.isBoolean(n)||Hn.isNumber(n)))throw console.error("Invalid call to Attr.set. Key ",t,":: Value ",n,":: Element ",e),new Error("Attribute value was not simple");e.setAttribute(t,n+"")},Vn=function(e,t,n){Un(e.dom(),t,n)},Xn=function(e,t){var n=e.dom();qn.each(t,function(e,t){Un(n,t,e)})},Yn=function(e,t){var n=e.dom().getAttribute(t);return null===n?void 0:n},Kn=function(e,t){e.dom().removeAttribute(t)},Gn=(nn(function(){return Gn(_n(document))}),function(e){var t=e.dom().body;if(null===t||void 0===t)throw"Body is not available yet";return _n(t)}),Jn=function(e){var t=Ln.isText(e)?e.dom().parentNode:e.dom();return void 0!==t&&null!==t&&t.ownerDocument.body.contains(t)},Qn=function(e){return void 0!==e.style},Zn=function(e,t){var n=e.dom(),r=window.getComputedStyle(n).getPropertyValue(t),o=""!==r||Jn(e)?r:function(e,t){return Qn(e)?e.style.getPropertyValue(t):""}(n,t);return null===o?void 0:o},er=function(){var e=arguments;return function(){for(var t=new Array(arguments.length),n=0;n<t.length;n++)t[n]=arguments[n];if(e.length!==t.length)throw new Error('Wrong number of arguments to struct. Expected "['+e.length+']", got '+t.length+" arguments");var r={};return P.each(e,function(e,n){r[e]=p.constant(t[n])}),r}},tr=function(e){return 1!==e.nodeType&&9!==e.nodeType||0===e.childElementCount},nr={all:function(e,t){var n=void 0===t?document:t.dom();return tr(n)?[]:P.map(n.querySelectorAll(e),_n)},is:function(e,t){var n=e.dom();if(1!==n.nodeType)return!1;if(void 0!==n.matches)return n.matches(t);if(void 0!==n.msMatchesSelector)return n.msMatchesSelector(t);if(void 0!==n.webkitMatchesSelector)return n.webkitMatchesSelector(t);if(void 0!==n.mozMatchesSelector)return n.mozMatchesSelector(t);throw new Error("Browser lacks native selectors")},one:function(e,t){var n=void 0===t?document:t.dom();return tr(n)?w.none():w.from(n.querySelector(e)).map(_n)}},rr=function(e,t){return e.dom()===t.dom()},or=Tn.detect().browser.isIE()?function(e,t){return n=e.dom(),r=t.dom(),function(e,t,n){return 0!=(e.compareDocumentPosition(t)&n)}(n,r,I.getOrDie("Node").DOCUMENT_POSITION_CONTAINED_BY);var n,r}:function(e,t){var n=e.dom(),r=t.dom();return n!==r&&n.contains(r)},ir={eq:rr,isEqualNode:function(e,t){return e.dom().isEqualNode(t.dom())},member:function(e,t){return P.exists(t,p.curry(rr,e))},contains:or,is:nr.is},ar=function(e){return _n(e.dom().ownerDocument)},sr=function(e){var t=e.dom();return w.from(t.nextSibling).map(_n)},ur=function(e,t){var n=e.dom().childNodes;return w.from(n[t]).map(_n)},cr=(er("element","offset"),ar),lr=function(e){var t=e.dom();return _n(t.ownerDocument.defaultView)},fr=function(e){var t=e.dom();return w.from(t.parentNode).map(_n)},dr=function(e,t){for(var n=Hn.isFunction(t)?t:p.constant(!1),r=e.dom(),o=[];null!==r.parentNode&&void 0!==r.parentNode;){var i=r.parentNode,a=_n(i);if(o.push(a),!0===n(a))break;r=i}return o},hr=function(e){var t=e.dom();return w.from(t.previousSibling).map(_n)},pr=sr,mr=function(e){var t=e.dom();return P.map(t.childNodes,_n)},gr=ur,vr=function(e){return ur(e,e.dom().childNodes.length-1)},yr=Tn.detect().browser,br=function(e){return P.find(e,Ln.isElement)},wr=function(e){var t=w.none(),n=[],r=function(e){o()?i(e):n.push(e)},o=function(){return t.isSome()},i=function(e){t.each(function(t){setTimeout(function(){e(t)},0)})};return e(function(e){t=w.some(e),P.each(n,i),n=[]}),{get:r,map:function(e){return wr(function(t){r(function(n){t(e(n))})})},isReady:o}},xr={nu:wr,pure:function(e){return wr(function(t){t(e)})}},Cr=function(e){var t=function(t){var n;e((n=t,function(){var e=Array.prototype.slice.call(arguments),t=this;setTimeout(function(){n.apply(t,e)},0)}))};return{map:function(e){return Cr(function(n){t(function(t){var r=e(t);n(r)})})},bind:function(e){return Cr(function(n){t(function(t){e(t).get(n)})})},anonBind:function(e){return Cr(function(n){t(function(t){e.get(n)})})},toLazy:function(){return xr.nu(t)},get:t}},Sr={nu:Cr,pure:function(e){return Cr(function(t){t(e)})}},Tr=function(e){return t=e,(0,Sr.nu)(function(e){var n=[],r=0;0===t.length?e([]):P.each(t,function(o,i){o.get(function(o){return function(i){n[o]=i,++r>=t.length&&e(n)}}(i))})});var t},Er=function(e){return{is:function(t){return e===t},isValue:p.always,isError:p.never,getOr:p.constant(e),getOrThunk:p.constant(e),getOrDie:p.constant(e),or:function(t){return Er(e)},orThunk:function(t){return Er(e)},fold:function(t,n){return n(e)},map:function(t){return Er(t(e))},each:function(t){t(e)},bind:function(t){return t(e)},exists:function(t){return t(e)},forall:function(t){return t(e)},toOption:function(){return w.some(e)}}},kr=function(e){return{is:p.never,isValue:p.never,isError:p.always,getOr:p.identity,getOrThunk:function(e){return e()},getOrDie:function(){return p.die(e)()},or:function(e){return e},orThunk:function(e){return e()},fold:function(t,n){return t(e)},map:function(t){return kr(e)},each:p.noop,bind:function(t){return kr(e)},exists:p.never,forall:p.always,toOption:w.none}},Nr={value:Er,error:kr};function Rr(e,t){var n=e,r=function(e,n,r,o){var i,a;if(e){if(!o&&e[n])return e[n];if(e!==t){if(i=e[r])return i;for(a=e.parentNode;a&&a!==t;a=a.parentNode)if(i=a[r])return i}}};this.current=function(){return n},this.next=function(e){return n=r(n,"firstChild","nextSibling",e)},this.prev=function(e){return n=r(n,"lastChild","previousSibling",e)},this.prev2=function(e){return n=function(e,n,r,o){var i,a,s;if(e){if(i=e.previousSibling,t&&i===t)return;if(i){if(!o)for(s=i.lastChild;s;s=s.lastChild)if(!s.lastChild)return s;return i}if((a=e.parentNode)&&a!==t)return a}}(n,0,0,e)}}var _r,Ar,Dr,Or=function(e){var t;return function(n){return(t=t||P.mapToObject(e,p.constant(!0))).hasOwnProperty(Ln.name(n))}},Pr=Or(["h1","h2","h3","h4","h5","h6"]),Br=Or(["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"]),Ir=function(e){return Ln.isElement(e)&&!Br(e)},Lr=function(e){return Ln.isElement(e)&&"br"===Ln.name(e)},Mr=Or(["h1","h2","h3","h4","h5","h6","p","div","address","pre","form","blockquote","center","dir","fieldset","header","footer","article","section","hgroup","aside","nav","figure"]),Hr=Or(["ul","ol","dl"]),Fr=Or(["li","dd","dt"]),Wr=Or(["area","base","basefont","br","col","frame","hr","
1img","input","isindex","link","meta","param","embed","source","wbr","track"]),jr=Or(["thead","tbody","tfoot"]),$r=Or(["td","th"]),zr=function(e){return function(t){return!!t&&t.nodeType===e}},qr=zr(1),Ur=function(e){var t=e.toLowerCase().split(" ");return function(e){var n,r;if(e&&e.nodeType)for(r=e.nodeName.toLowerCase(),n=0;n<t.length;n++)if(r===t[n])return!0;return!1}},Vr=function(e){return function(t){if(qr(t)){if(t.contentEditable===e)return!0;if(t.getAttribute("data-mce-contenteditable")===e)return!0}return!1}},Xr=zr(3),Yr=zr(8),Kr=zr(9),Gr=Ur("br"),Jr=Vr("true"),Qr=Vr("false"),Zr={isText:Xr,isElement:qr,isComment:Yr,isDocument:Kr,isBr:Gr,isContentEditableTrue:Jr,isContentEditableFalse:Qr,matchNodeNames:Ur,hasPropValue:function(e,t){return function(n){return qr(n)&&n[e]===t}},hasAttribute:function(e,t){return function(t){return qr(t)&&t.hasAttribute(e)}},hasAttributeValue:function(e,t){return function(n){return qr(n)&&n.getAttribute(e)===t}},matchStyleValues:function(e,t){var n=t.toLowerCase().split(" ");return function(t){var r;if(qr(t))for(r=0;r<n.length;r++)if(t.ownerDocument.defaultView.getComputedStyle(t,null).getPropertyValue(e)===n[r])return!0;return!1}},isBogus:function(e){return qr(e)&&e.hasAttribute("data-mce-bogus")},isBogusAll:function(e){return qr(e)&&"all"===e.getAttribute("data-mce-bogus")},isTable:function(e){return qr(e)&&"TABLE"===e.tagName}},eo=function(e){return e&&"SPAN"===e.tagName&&"bookmark"===e.getAttribute("data-mce-type")},to=function(e,t){var n,r=t.childNodes;if(!Zr.isElement(t)||!eo(t)){for(n=r.length-1;n>=0;n--)to(e,r[n]);if(!1===Zr.isDocument(t)){if(Zr.isText(t)&&t.nodeValue.length>0){var o=kt.trim(t.nodeValue).length;if(e.isBlock(t.parentNode)||o>0)return;if(0===o&&function(e){return e.previousSibling&&"SPAN"===e.previousSibling.nodeName&&e.nextSibling&&"SPAN"===e.nextSibling.nodeName}(t))return}else if(Zr.isElement(t)&&(1===(r=t.childNodes).length&&eo(r[0])&&t.parentNode.insertBefore(r[0],t),r.length||Wr(_n(t))))return;e.remove(t)}return t}},no={trimNode:to},ro=kt.makeMap,oo=/[&<>\"\u0060\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,io=/[<>&\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,ao=/[<>&\"\']/g,so=/&#([a-z0-9]+);?|&([a-z0-9]+);/gi,uo={128:"\u20ac",130:"\u201a",131:"\u0192",132:"\u201e",133:"\u2026",134:"\u2020",135:"\u2021",136:"\u02c6",137:"\u2030",138:"\u0160",139:"\u2039",140:"\u0152",142:"\u017d",145:"\u2018",146:"\u2019",147:"\u201c",148:"\u201d",149:"\u2022",150:"\u2013",151:"\u2014",152:"\u02dc",153:"\u2122",154:"\u0161",155:"\u203a",156:"\u0153",158:"\u017e",159:"\u0178"};Ar={'"':""","'":"'","<":"<",">":">","&":"&","`":"`"},Dr={"<":"<",">":">","&":"&",""":'"',"'":"'"};var co=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)),Ar[r]||(i[r]=o="&"+e[n+1]+";",i[o]=r);return i}};_r=co("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,8
1k4,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);var lo=function(e,t){return e.replace(t?oo:io,function(e){return Ar[e]||e})},fo=function(e,t){return e.replace(t?oo:io,function(e){return e.length>1?"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";":Ar[e]||"&#"+e.charCodeAt(0)+";"})},ho=function(e,t,n){return n=n||_r,e.replace(t?oo:io,function(e){return Ar[e]||n[e]||e})},po={encodeRaw:lo,encodeAllRaw:function(e){return(""+e).replace(ao,function(e){return Ar[e]||e})},encodeNumeric:fo,encodeNamed:ho,getEncodeFunc:function(e,t){var n=co(t)||_r,r=ro(e.replace(/\+/g,","));return r.named&&r.numeric?function(e,t){return e.replace(t?oo:io,function(e){return void 0!==Ar[e]?Ar[e]:void 0!==n[e]?n[e]:e.length>1?"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";":"&#"+e.charCodeAt(0)+";"})}
vendor: 15,897 bytes, line 1
1:r.named?t?function(e,t){return ho(e,t,n)}:ho:r.numeric?fo:lo},decode:function(e){return e.replace(so,function(e,t){return t?(t="x"===t.charAt(0).toLowerCase()?parseInt(t.substr(1),16):parseInt(t,10))>65535?(t-=65536,String.fromCharCode(55296+(t>>10),56320+(1023&t))):uo[t]||String.fromCharCode(t):Dr[e]||_r[e]||(n=e,(r=Nn("div").dom()).innerHTML=n,r.textContent||r.innerText||n);var n,r})}},mo={},go={},vo=kt.makeMap,yo=kt.each,bo=kt.extend,wo=kt.explode,xo=kt.inArray,Co=function(e,t){return(e=kt.trim(e))?e.split(t||" "):[]},So=function(e){var t,n,r,o,i,a,s={},u=function(e,n,r){var o,i,a,u=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=Co(r)),o=(e=Co(e)).length;o--;)a={attributes:u(i=Co([t,n].join(" "))),attributesOrder:i,children:u(r,go)},s[e[o]]=a},c=function(e,t){var n,r,o,i;for(n=(e=Co(e)).length,t=Co(t);n--;)for(r=s[e[n]],o=0,i=t.length;o<i;o++)r.attributes[t[o]]={},r.attributesOrder.push(t[o])};return mo[e]?mo[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 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",r=[r,a="acronym applet basefont big font strike tt"].join(" "),yo(Co(a),function(e){u(e,"",r)}),n=[n,i="center dir isindex noframes"].join(" "),o=[n,r].join(" "),yo(Co(i),function(e){u(e,"",o)})),o=o||[n,r].join(" "),u("html","manifest","head body"),u("head","","base command link meta noscript script style title"),u("title hr noscript br"),u("base","href target"),u("link","href rel media hreflang type sizes hreflang"),u("meta","name http-equiv content charset"),u("style","media type scoped"),u("script","src async defer type charset"),u("body","onafterprint onbeforeprint onbeforeunload onblur onerror onfocus onhashchange onload onmessage onoffline ononline onpagehide onpageshow onpopstate onresize onscroll onstorage onunload",o),u("address dt dd div caption","",o),u("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),u("blockquote","cite",o),u("ol","reversed start type","li"),u("ul","","li"),u("li","value",o),u("dl","","dt dd"),u("a","href target rel media hreflang type",r),u("q","cite",r),u("ins del","cite datetime",o),u("img","src sizes srcset alt usemap ismap width height"),u("iframe","src name width height",o),u("embed","src type width height"),u("object","data type typemustmatch name usemap form width height",[o,"param"].join(" ")),u("param","name value"),u("map","name",[o,"area"].join(" ")),u("area","alt coords shape href target rel media hreflang type"),u("table","border","caption colgroup thead tfoot tbody tr"+("html4"===e?" col":"")),u("colgroup","span","col"),u("col","span"),u("tbody thead tfoot","","tr"),u("tr","","td th"),u("td","colspan rowspan headers",o),u("th","colspan rowspan headers scope abbr",o),u("form","accept-charset action autocomplete enctype method name novalidate target",o),u("fieldset","disabled form name",[o,"legend"].join(" ")),u("label","form for",r),u("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"),u("button","disabled form formaction formenctype formmethod formnovalidate formtarget name type value","html4"===e?o:r),u("select","disabled form multiple name required size","option optgroup"),u("optgroup","disabled label","option"),u("option","disabled label selected value"),u("textarea","cols dirname disabled form maxlength name readonly required rows wrap"),u("menu","type label",[o,"li"].join(" ")),u("noscript","",o),"html4"!==e&&(u("wbr"),u("ruby","",[r,"rt rp"].join(" ")),u("figcaption","",o),u("mark rt rp summary bdi","",r),u("canvas","width height",o),u("video","src crossorigin poster preload autoplay mediagroup loop muted controls width height buffered",[o,"track source"].join(" ")),u("audio","src crossorigin preload autoplay mediagroup loop muted controls buffered volume",[o,"track source"].join(" ")),u("picture","","img source"),u("source","src srcset type media sizes"),u("track","kind src srclang label default"),u("datalist","",[r,"option"].join(" ")),u("article section nav aside header footer","",o),u("hgroup","","h1 h2 h3 h4 h5 h6"),u("figure","",[o,"figcaption"].join(" ")),u("time","datetime",r),u("dialog","open",o),u("command","type label icon disabled checked radiogroup command"),u("output","for form name",r),u("progress","value max",r),u("meter","value min max low high optimum",r),u("details","open",[o,"summary"].join(" ")),u("keygen","autofocus challenge disabled form keytype name")),"html5-strict"!==e&&(c("script","language xml:space"),c("style","xml:space"),c("object","declare classid code codebase codetype archive standby align border hspace vspace"),c("embed","align name hspace vspace"),c("param","valuetype type"),c("a","charset name rev shape coords"),c("br","clear"),c("applet","codebase archive code object alt name width height align hspace vspace"),c("img","name longdesc align border hspace vspace"),c("iframe","longdesc frameborder marginwidth marginheight scrolling align"),c("font basefont","size color face"),c("input","usemap align"),c("select","onchange"),c("textarea"),c("h1 h2 h3 h4 h5 h6 div p legend caption","align"),c("ul","type compact"),c("li","type"),c("ol dl menu dir","compact"),c("pre","width xml:space"),c("hr","align noshade size width"),c("isindex","prompt"),c("table","summary width frame rules cellspacing cellpadding align bgcolor"),c("col","width align char charoff valign"),c("colgroup","width align char charoff valign"),c("thead","align char charoff valign"),c("tr","align char charoff valign bgcolor"),c("th","axis align char charoff valign nowrap bgcolor width height"),c("form","accept"),c("td","abbr axis scope align char charoff valign nowrap bgcolor width height"),c("tfoot","align char charoff valign"),c("tbody","align char charoff valign"),c("area","nohref"),c("body","background bgcolor text link vlink alink")),"html4"!==e&&(c("input button select textarea","autofocus"),c("input textarea","placeholder"),c("a","download"),c("link script img","crossorigin"),c("iframe","sandbox seamless allowfullscreen")),yo(Co("a form meter progress dfn"),function(e){s[e]&&delete s[e].children[e]}),delete s.caption.children.table,delete s.script,mo[e]=s,s)},To=function(e,t){var n;return e&&(n={},"string"==typeof e&&(e={"*":e}),yo(e,function(e,r){n[r]=n[r.toUpperCase()]="map"===t?vo(e,/[, ]/):wo(e,/[, ]/)})),n};function Eo(e){var t,n,r,o,i,a,s,u,c,l,f,d,h,p={},m={},g=[],v={},y={},b=function(t,n,r){var o=e[t];return o?o=vo(o,/[, ]/,vo(o.toUpperCase(),/[, ]/)):(o=mo[t])||(o=vo(n," ",vo(n.toUpperCase()," ")),o=bo(o,r),mo[t]=o),o};r=So((e=e||{}).schema),!1===e.verify_html&&(e.valid_elements="*[*]"),t=To(e.valid_styles),n=To(e.invalid_styles,"map"),u=To(e.valid_classes,"map"),o=b("whitespace_elements","pre script noscript style textarea video audio iframe object code"),i=b("self_closing_elements","colgroup dd dt li option p td tfoot th thead tr"),a=b("short_ended_elements","area base basefont br col frame hr img input isindex link meta param embed source wbr track"),s=b("boolean_attributes","checked compact declare defer disabled ismap multiple nohref noresize noshade nowrap readonly selected autoplay loop controls"),l=b("non_empty_elements","td th iframe video audio object script pre code",a),f=b("move_caret_before_on_enter_elements","table",l),d=b("text_block_elements","h1 h2 h3 h4 h5 h6 p div address pre form blockquote center dir fieldset header footer article section hgroup aside nav figure"),c=b("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",d),h=b("text_inline_elements","span strong b em i font strike u var cite dfn code mark q sup sub samp"),yo((e.special||"script noscript noframes noembed title style textarea xmp").split(" "),function(e){y[e]=new RegExp("</"+e+"[^>]*>","gi")});var w=function(e){return new RegExp("^"+e.replace(/([?+*])/g,".$1")+"$")},x=function(e){var t,n,r,o,i,a,s,u,c,l,f,d,h,m,v,y,b,x,C,S=/^([#+\-])?([^\[!\/]+)(?:\/([^\[!]+))?(?:(!?)\[([^\]]+)\])?$/,T=/^([!\-])?(\w+[\\:]:\w+|[^=:<]+)?(?:([=:<])(.*))?$/,E=/[*?+]/;if(e)for(e=Co(e,","),p["@"]&&(y=p["@"].attributes,b=p["@"].attributesOrder),t=0,n=e.length;t<n;t++)if(i=S.exec(e[t])){if(c=i[2],v=i[3],u=i[5],a={attributes:d={},attributesOrder:h=[]},"#"===(m=i[1])&&(a.paddEmpty=!0),"-"===m&&(a.removeEmpty=!0),"!"===i[4]&&(a.removeEmptyAttrs=!0),y){for(x in y)d[x]=y[x];h.push.apply(h,b)}if(u)for(r=0,o=(u=Co(u,"|")).length;r<o;r++)if(i=T.exec(u[r])){if(s={},f=i[1],l=i[2].replace(/[\\:]:/g,":"),m=i[3],C=i[4],"!"===f&&(a.attributesRequired=a.attributesRequired||[],a.attributesRequired.push(l),s.required=!0),"-"===f){delete d[l],h.splice(xo(h,l),1);continue}m&&("="===m&&(a.attributesDefault=a.attributesDefault||[],a.attributesDefault.push({name:l,value:C}),s.defaultValue=C),":"===m&&(a.attributesForced=a.attributesForced||[],a.attributesForced.push({name:l,value:C}),s.forcedValue=C),"<"===m&&(s.validValues=vo(C,"?"))),E.test(l)?(a.attributePatterns=a.attributePatterns||[],s.pattern=w(l),a.attributePatterns.push(s)):(d[l]||h.push(l),d[l]=s)}y||"@"!==c||(y=d,b=h),v&&(a.outputName=c,p[v]=a),E.test(c)?(a.pattern=w(c),g.push(a)):p[c]=a}},C=function(e){p={},g=[],x(e),yo(r,function(e,t){m[t]=e.children})},S=function(e){var t=/^(~)?(.+)$/;e&&(mo.text_block_elements=mo.block_elements=null,yo(Co(e,","),function(e){var n=t.exec(e),r="~"===n[1],o=r?"span":"div",i=n[2];if(m[i]=m[o],v[i]=o,r||(c[i.toUpperCase()]={},c[i]={}),!p[i]){var a=p[o];delete(a=bo({},a)).removeEmptyAttrs,delete a.removeEmpty,p[i]=a}yo(m,function(e,t){e[o]&&(m[t]=e=bo({},m[t]),e[i]=e[o])})}))},T=function(t){var n=/^([+\-]?)(\w+)\[([^\]]+)\]$/;mo[e.schema]=null,t&&yo(Co(t,","),function(e){var t,r,o=n.exec(e);o&&(t=(r=o[1])?m[o[2]]:m[o[2]]={"#comment":{}},t=m[o[2]],yo(Co(o[3],"|"),function(e){"-"===r?delete t[e]:t[e]={}}))})},E=function(e){var t,n=p[e];if(n)return n;for(t=g.length;t--;)if((n=g[t]).pattern.test(e))return n};return e.valid_elements?C(e.valid_elements):(yo(r,function(e,t){p[t]={attributes:e.attributes,attributesOrder:e.attributesOrder},m[t]=e.children}),"html5"!==e.schema&&yo(Co("strong/b em/i"),function(e){e=Co(e,"/"),p[e[1]].outputName=e[0]}),yo(Co("ol ul sub sup blockquote span font a table tbody tr strong em b i"),function(e){p[e]&&(p[e].removeEmpty=!0)}),yo(Co("p h1 h2 h3 h4 h5 h6 th td pre div address caption li"),function(e){p[e].paddEmpty=!0}),yo(Co("span"),function(e){p[e].removeEmptyAttrs=!0})),S(e.custom_elements),T(e.valid_children),x(e.extended_valid_elements),T("+ol[ul|ol],+ul[ul|ol]"),yo({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,t){p[t]&&(p[t].parentsRequired=Co(e))}),e.invalid_elements&&yo(wo(e.invalid_elements),function(e){p[e]&&delete p[e]}),E("span")||x("span[!data-mce-type|*]"),{children:m,elements:p,getValidStyles:function(){return t},getValidClasses:function(){return u},getBlockElements:function(){return c},getInvalidStyles:function(){return n},getShortEndedElements:function(){return a},getTextBlockElements:function(){return d},getTextInlineElements:function(){return h},getBoolAttrs:function(){return s},getElementRule:E,getSelfClosingElements:function(){return i},getNonEmptyElements:function(){return l},getMoveCaretBeforeOnEnterElements:function(){return f},getWhiteSpaceElements:function(){return o},getSpecialElements:function(){return y},isValidChild:function(e,t){var n=m[e.toLowerCase()];return!(!n||!n[t.toLowerCase()])},isValid: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},getCustomElements:function(){return v},addValidElements:x,setValidElements:C,addCustomElements:S,addValidChildren:T}}var ko=function(e,t,n,r){var o=function(e){return(e=parseInt(e,10).toString(16)).length>1?e:"0"+e};return"#"+o(t)+o(n)+o(r)};function No(e,t){var n,r,o,i,a=/rgb\s*\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/gi,s=/(?:url(?:(?:\(\s*\"([^\"]+)\"\s*\))|(?:\(\s*\'([^\']+)\'\s*\))|(?:\(\s*([^)\s]+)\s*\))))|(?:\'([^\']+)\')|(?:\"([^\"]+)\")/gi,u=/\s*([^:]+):\s*([^;]+);?/g,c=/\s+$/,l={};for(e=e||{},t&&(o=t.getValidStyles(),i=t.getInvalidStyles()),r="\\\" \\' \\; \\: ; : \ufeff".split(" "),n=0;n<r.length;n++)l[r[n]]="\ufeff"+n,l["\ufeff"+n]=r[n];return{toHex:function(e){return e.replace(a,ko)},parse:function(t){var r,o,i,f,d,h,p,m,g={},v=e.url_converter,y=e.url_converter_scope||this,b=function(e,t,r){var o,i,a,s;if((o=g[e+"-top"+t])&&(i=g[e+"-right"+t])&&(a=g[e+"-bottom"+t])&&(s=g[e+"-left"+t])){var u=[o,i,a,s];for(n=u.length-1;n--&&u[n]===u[n+1];);n>-1&&r||(g[e+t]=-1===n?u[0]:u.join(" "),delete g[e+"-top"+t],delete g[e+"-right"+t],delete g[e+"-bottom"+t],delete g[e+"-left"+t])}},w=function(e){var t,n=g[e];if(n){for(t=(n=n.split(" ")).length;t--;)if(n[t]!==n[0])return!1;return g[e]=n[0],!0}},x=function(e){return f=!0,l[e]},C=function(e,t){return f&&(e=e.replace(/\uFEFF[0-9]/g,function(e){return l[e]})),t||(e=e.replace(/\\([\'\";:])/g,"$1")),e},S=function(e){return String.fromCharCode(parseInt(e.slice(1),16))},T=function(e){return e.replace(/\\[0-9a-f]+/gi,S)},E=function(t,n,r,o,i,a){if(i=i||a)return"'"+(i=C(i)).replace(/\'/g,"\\'")+"'";if(n=C(n||r||o),!e.allow_script_urls){var s=n.replace(/[\s\r\n]+/g,"");if(/(java|vb)script:/i.test(s))return"";if(!e.allow_svg_data_urls&&/^data:image\/svg/i.test(s))return""}return v&&(n=v.call(y,n,"style")),"url('"+n.replace(/\'/g,"\\'")+"')"};if(t){for(t=(t=t.replace(/[\u0000-\u001F]/g,"")).replace(/\\[\"\';:\uFEFF]/g,x).replace(/\"[^\"]+\"|\'[^\']+\'/g,function(e){return e.replace(/[;:]/g,x)});r=u.exec(t);)if(u.lastIndex=r.index+r[0].length,o=r[1].replace(c,"").toLowerCase(),i=r[2].replace(c,""),o&&i){if(o=T(o),i=T(i),-1!==o.indexOf("\ufeff")||-1!==o.indexOf('"'))continue;if(!e.allow_script_urls&&("behavior"===o||/expression\s*\(|\/\*|\*\//.test(i)))continue;"font-weight"===o&&"700"===i?i="bold":"color"!==o&&"background-color"!==o||(i=i.toLowerCase()),i=(i=i.replace(a,ko)).replace(s,E),g[o]=f?C(i,!0):i}b("border","",!0),b("border","-width"),b("border","-color"),b("border","-style"),b("padding",""),b("margin",""),d="border",p="border-style",m="border-color",w(h="border-width")&&w(p)&&w(m)&&(g[d]=g[h]+" "+g[p]+" "+g[m],delete g[h],delete g[p],delete g[m]),"medium none"===g.border&&delete g.border,"none"===g["border-image"]&&delete g["border-image"]}return g},serialize:function(e,t){var n,r,a="",s=function(t){var n,r,i,s;if(n=o[t])for(r=0,i=n.length;r<i;r++)(s=e[t=n[r]])&&(a+=(a.length>0?" ":"")+t+": "+s+";")},u=function(e,t){var n;return!((n=i["*"])&&n[e]||(n=i[t])&&n[e])};if(t&&o)s("*"),s(t);else for(n in e)!(r=e[n])||i&&!u(n,t)||(a+=(a.length>0?" ":"")+n+": "+r+";");return a}}}var Ro=kt.each,_o=kt.is,Ao=kt.grep,Do=ae.ie,Oo=/^([a-z0-9],?)+$/i,Po=/^[ \t\r\n]*$/,Bo=function(e,t){var n=t.attr("style");(n=e.serializeStyle(e.parseStyle(n),t[0].nodeName))||(n=null),t.attr("data-mce-style",n)},Io=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},Lo=function(e,t){var n,r=this;
1r.doc=e,r.win=window,r.files={},r.counter=0,r.stdMode=!Do||e.documentMode>=8,r.boxModel=!Do||"CSS1Compat"===e.compatMode||r.stdMode,r.styleSheetLoader=function(e,t){var n,r=0,o={};n=(t=t||{}).maxLoadTime||5e3;var i=function(t){e.getElementsByTagName("head")[0].appendChild(t)},a=function(t,a,s){var u,c,l,f,d=function(){for(var e=f.passed,t=e.length;t--;)e[t]();f.status=2,f.passed=[],f.failed=[]},h=function(){for(var e=f.failed,t=e.length;t--;)e[t]();f.status=3,f.passed=[],f.failed=[]},p=function(e,t){e()||((new Date).getTime()-l<n?fe.setTimeout(t):h())},m=function(){p(function(){for(var t,n,r=e.styleSheets,o=r.length;o--;)if((n=(t=r[o]).ownerNode?t.ownerNode:t.owningElement)&&n.id===u.id)return d(),!0},m)},g=function(){p(function(){try{var e=c.sheet.cssRules;return d(),!!e}catch(e){}},g)};if(t=kt._addCacheSuffix(t),o[t]?f=o[t]:o[t]=f={passed:[],failed:[]},a&&f.passed.push(a),s&&f.failed.push(s),1!==f.status)if(2!==f.status)if(3!==f.status){if(f.status=1,(u=e.createElement("link")).rel="stylesheet",u.type="text/css",u.id="u"+r++,u.async=!1,u.defer=!1,l=(new Date).getTime(),"onload"in u&&!((v=navigator.userAgent.match(/WebKit\/(\d*)/))&&parseInt(v[1],10)<536))u.onload=m,u.onerror=h;else{if(navigator.userAgent.indexOf("Firefox")>0)return(c=e.createElement("style")).textContent='@import "'+t+'"',g(),void i(c);m()}var v;i(u),u.href=t}else h();else d()},s=function(e){return Sr.nu(function(t){a(e,p.compose(t,p.constant(Nr.value(e))),p.compose(t,p.constant(Nr.error(e))))})},u=function(e){return e.fold(p.identity,p.identity)};return{load:a,loadAll:function(e,t,n){Tr(P.map(e,s)).get(function(e){var r=P.partition(e,function(e){return e.isValue()});r.fail.length>0?n(r.fail.map(u)):t(r.pass.map(u))})}}}(e),r.boundEvents=[],r.settings=t=t||{},r.schema=t.schema?t.schema:Eo({}),r.styles=No({url_converter:t.url_converter,url_converter_scope:t.url_converter_scope},t.schema),r.fixDoc(e),r.events=t.ownEvents?new we(t.proxy):we.Event,r.attrHooks=function(e,t){var n={},r=t.keep_values;return n={style:{set:function(e,t){null===t||"object"!=typeof t?(r&&e.attr("data-mce-style",t),e.attr("style",t)):e.css(t)},get:function(t){var n=t.attr("data-mce-style")||t.attr("style");return e.serializeStyle(e.parseStyle(n),t[0].nodeName)}}},r&&(n.href=n.src={set:function(n,r,o){t.url_converter&&(r=t.url_converter.call(t.url_converter_scope||e,r,o,n[0])),n.attr("data-mce-"+o,r).attr(o,r)},get:function(e,t){return e.attr("data-mce-"+t)||e.attr(t)}}),n}(r,t),n=r.schema.getBlockElements(),r.$=Ut.overrideDefaults(function(){return{context:e,element:r.getRoot()}}),r.isBlock=function(e){if(!e)return!1;var t=e.nodeType;return t?!(1!==t||!n[e.nodeName]):!!n[e]}};Lo.prototype={$$:function(e){return"string"==typeof e&&(e=this.get(e)),this.$(e)},root:null,fixDoc:function(e){},clone:function(e,t){var n,r=this;return!Do||1!==e.nodeType||t?e.cloneNode(t):t?n.firstChild:(n=r.doc.createElement(e.nodeName),Ro(r.getAttribs(e),function(t){r.setAttrib(n,t.nodeName,r.getAttrib(e,t.nodeName))}),n)},getRoot:function(){return this.settings.root_element||this.doc.body},getViewPort:function(e){var t,n;return t=(e=e||this.win).document,n=this.boxModel?t.documentElement:t.body,{x:e.pageXOffset||n.scrollLeft,y:e.pageYOffset||n.scrollTop,w:e.innerWidth||n.clientWidth,h:e.innerHeight||n.clientHeight}},getRect:function(e){var t,n;return e=this.get(e),t=this.getPos(e),n=this.getSize(e),{x:t.x,y:t.y,w:n.w,h:n.h}},getSize:function(e){var t,n;return e=this.get(e),t=this.getStyle(e,"width"),n=this.getStyle(e,"height"),-1===t.indexOf("px")&&(t=0),-1===n.indexOf("px")&&(n=0),{w:parseInt(t,10)||e.offsetWidth||e.clientWidth,h:parseInt(n,10)||e.offsetHeight||e.clientHeight}},getParent:function(e,t,n){return this.getParents(e,t,n,!1)},getParents:function(e,t,n,r){var o,i=this,a=[];for(e=i.get(e),r=void 0===r,n=n||("BODY"!==i.getRoot().nodeName?i.getRoot().parentNode:null),_o(t,"string")&&(o=t,t="*"===t?function(e){return 1===e.nodeType}:function(e){return i.is(e,o)});e&&e!==n&&e.nodeType&&9!==e.nodeType;){if(!t||t(e)){if(!r)return e;a.push(e)}e=e.parentNode}return r?a:null},get:function(e){var t;return e&&this.doc&&"string"==typeof e&&(t=e,(e=this.doc.getElementById(e))&&e.id!==t)?this.doc.getElementsByName(t)[1]:e},getNext:function(e,t){return this._findSib(e,t,"nextSibling")},getPrev:function(e,t){return this._findSib(e,t,"previousSibling")},select:function(e,t){return rt(e,this.get(t)||this.settings.root_element||this.doc,[])},is:function(e,t){var n;if(!e)return!1;if(void 0===e.length){if("*"===t)return 1===e.nodeType;if(Oo.test(t)){for(t=t.toLowerCase().split(/,/),e=e.nodeName.toLowerCase(),n=t.length-1;n>=0;n--)if(t[n]===e)return!0;return!1}}if(e.nodeType&&1!==e.nodeType)return!1;var r=e.nodeType?[e]:e;return rt(t,r[0].ownerDocument||r[0],null,r).length>0},add:function(e,t,n,r,o){var i=this;return this.run(e,function(e){var a;return a=_o(t,"string")?i.doc.createElement(t):t,i.setAttribs(a,n),r&&(r.nodeType?a.appendChild(r):i.setHTML(a,r)),o?a:e.appendChild(a)})},create:function(e,t,n){return this.add(this.doc.createElement(e),e,t,n,1)},createHTML:function(e,t,n){var r,o="";for(r in o+="<"+e,t)t.hasOwnProperty(r)&&null!==t[r]&&"undefined"!=typeof t[r]&&(o+=" "+r+'="'+this.encode(t[r])+'"');return"undefined"!=typeof n?o+">"+n+"</"+e+">":o+" />"},createFragment:function(e){var t,n,r,o=this.doc;for(r=o.createElement("div"),t=o.createDocumentFragment(),e&&(r.innerHTML=e);n=r.firstChild;)t.appendChild(n);return t},remove:function(e,t){return e=this.$$(e),t?e.each(function(){for(var e;e=this.firstChild;)3===e.nodeType&&0===e.data.length?this.removeChild(e):this.parentNode.insertBefore(e,this)}).remove():e.remove(),e.length>1?e.toArray():e[0]},setStyle:function(e,t,n){e=this.$$(e).css(t,n),this.settings.update_styles&&Bo(this,e)},getStyle:function(e,t,n){return e=this.$$(e),n?e.css(t):("float"===(t=t.replace(/-(\D)/g,function(e,t){return t.toUpperCase()}))&&(t=ae.ie&&ae.ie<12?"styleFloat":"cssFloat"),e[0]&&e[0].style?e[0].style[t]:void 0)},setStyles:function(e,t){e=this.$$(e).css(t),this.settings.update_styles&&Bo(this,e)},removeAllAttribs:function(e){return this.run(e,function(e){var t,n=e.attributes;for(t=n.length-1;t>=0;t--)e.removeAttributeNode(n.item(t))})},setAttrib:function(e,t,n){var r,o,i=this.settings;""===n&&(n=null),r=(e=this.$$(e)).attr(t),e.length&&((o=this.attrHooks[t])&&o.set?o.set(e,n,t):e.attr(t,n),r!==n&&i.onSetAttrib&&i.onSetAttrib({attrElm:e,attrName:t,attrValue:n}))},setAttribs:function(e,t){var n=this;n.$$(e).each(function(e,r){Ro(t,function(e,t){n.setAttrib(r,t,e)})})},getAttrib:function(e,t,n){var r,o;return(e=this.$$(e)).length&&(o=(r=this.attrHooks[t])&&r.get?r.get(e,t):e.attr(t)),"undefined"==typeof o&&(o=n||""),o},getPos:function(e,t){return function(e,t,n){var r,o,i=0,a=0,s=e.ownerDocument;if(n=n||e,t){if(n===e&&t.getBoundingClientRect&&"static"===Zn(_n(e),"position"))return{x:i=(o=t.getBoundingClientRect()).left+(s.documentElement.scrollLeft||e.scrollLeft)-s.documentElement.clientLeft,y:a=o.top+(s.documentElement.scrollTop||e.scrollTop)-s.documentElement.clientTop};for(r=t;r&&r!==n&&r.nodeType;)i+=r.offsetLeft||0,a+=r.offsetTop||0,r=r.offsetParent;for(r=t.parentNode;r&&r!==n&&r.nodeType;)i-=r.scrollLeft||0,a-=r.scrollTop||0,r=r.parentNode;a+=function(e){return yr.isFirefox()&&"table"===Ln.name(e)?br(mr(e)).filter(function(e){return"caption"===Ln.name(e)}).bind(function(e){return br((t=e,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}(t,sr))).map(function(t){var n=t.dom().offsetTop,r=e.dom().offsetTop,o=e.dom().offsetHeight;return n<=r?-o:0});var t}).getOr(0):0}(_n(t))}return{x:i,y:a}}(this.doc.body,this.get(e),t)},parseStyle:function(e){return this.styles.parse(e)},serializeStyle:function(e,t){return this.styles.serialize(e,t)},addStyle:function(e){var t,n,r=this.doc;if(this!==Lo.DOM&&r===document){var o=Lo.DOM.addedStyles;if((o=o||[])[e])return;o[e]=!0,Lo.DOM.addedStyles=o}(n=r.getElementById("mceDefaultStyles"))||((n=r.createElement("style")).id="mceDefaultStyles",n.type="text/css",(t=r.getElementsByTagName("head")[0]).firstChild?t.insertBefore(n,t.firstChild):t.appendChild(n)),n.styleSheet?n.styleSheet.cssText+=e:n.appendChild(r.createTextNode(e))},loadCSS:function(e){var t,n=this,r=n.doc;n===Lo.DOM||r!==document?(e||(e=""),t=r.getElementsByTagName("head")[0],Ro(e.split(","),function(e){var o;e=kt._addCacheSuffix(e),n.files[e]||(n.files[e]=!0,o=n.create("link",{rel:"stylesheet",href:e}),Do&&r.documentMode&&r.recalc&&(o.onload=function(){r.recalc&&r.recalc(),o.onload=null}),t.appendChild(o))})):Lo.DOM.loadCSS(e)},addClass:function(e,t){this.$$(e).addClass(t)},removeClass:function(e,t){this.toggleClass(e,t,!1)},hasClass:function(e,t){return this.$$(e).hasClass(t)},toggleClass:function(e,t,n){this.$$(e).toggleClass(t,n).each(function(){""===this.className&&Ut(this).attr("class",null)})},show:function(e){this.$$(e).show()},hide:function(e){this.$$(e).hide()},isHidden:function(e){return"none"===this.$$(e).css("display")},uniqueId:function(e){return(e||"mce_")+this.counter++},setHTML:function(e,t){e=this.$$(e),Do?e.each(function(e,n){if(!1!==n.canHaveHTML){for(;n.firstChild;)n.removeChild(n.firstChild);try{n.innerHTML="<br>"+t,n.removeChild(n.firstChild)}catch(e){Ut("<div></div>").html("<br>"+t).contents().slice(1).appendTo(n)}return t}}):e.html(t)}
1,getOuterHTML:function(e){return 1===(e=this.get(e)).nodeType&&"outerHTML"in e?e.outerHTML:Ut("<div></div>").append(Ut(e).clone()).html()},setOuterHTML:function(e,t){var n=this;n.$$(e).each(function(){try{if("outerHTML"in this)return void(this.outerHTML=t)}catch(e){}n.remove(Ut(this).html(t),!0)})},decode:po.decode,encode:po.encodeAllRaw,insertAfter:function(e,t){return t=this.get(t),this.run(e,function(e){var n,r;return n=t.parentNode,(r=t.nextSibling)?n.insertBefore(e,r):n.appendChild(e),e})},replace:function(e,t,n){return this.run(t,function(t){return _o(t,"array")&&(e=e.cloneNode(!0)),n&&Ro(Ao(t.childNodes),function(t){e.appendChild(t)}),t.parentNode.replaceChild(e,t)})},rename:function(e,t){var n,r=this;return e.nodeName!==t.toUpperCase()&&(n=r.create(t),Ro(r.getAttribs(e),function(t){r.setAttrib(n,t.nodeName,r.getAttrib(e,t.nodeName))}),r.replace(n,e,1)),n||e},findCommonAncestor: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},toHex:function(e){return this.styles.toHex(kt.trim(e))},run:function(e,t,n){var r,o=this;return"string"==typeof e&&(e=o.get(e)),!!e&&(n=n||this,e.nodeType||!e.length&&0!==e.length?t.call(n,e):(r=[],Ro(e,function(e,i){e&&("string"==typeof e&&(e=o.get(e)),r.push(t.call(n,e,i)))}),r))},getAttribs:function(e){var t;return(e=this.get(e))?Do?(t=[],"OBJECT"===e.nodeName?e.attributes:("OPTION"===e.nodeName&&this.getAttrib(e,"selected")&&t.push({specified:1,nodeName:"selected"}),e.cloneNode(!1).outerHTML.replace(/<\/?[\w:\-]+ ?|=[\"][^\"]+\"|=\'[^\']+\'|=[\w\-]+|>/gi,"").replace(/[\w:\-]+/gi,function(e){t.push({specified:1,nodeName:e})}),t)):e.attributes:[]},isEmpty:function(e,t){var n,r,o,i,a,s,u=0;if(e=e.firstChild){a=new Rr(e,e.parentNode),t=t||(this.schema?this.schema.getNonEmptyElements():null),i=this.schema?this.schema.getWhiteSpaceElements():{};do{if(1===(o=e.nodeType)){var c=e.getAttribute("data-mce-bogus");if(c){e=a.next("all"===c);continue}if(s=e.nodeName.toLowerCase(),t&&t[s]){if("br"===s){u++,e=a.next();continue}return!1}for(n=(r=this.getAttribs(e)).length;n--;)if("name"===(s=r[n].nodeName)||"data-mce-bookmark"===s)return!1}if(8===o)return!1;if(3===o&&!Po.test(e.nodeValue))return!1;if(3===o&&e.parentNode&&i[e.parentNode.nodeName]&&Po.test(e.nodeValue))return!1;e=a.next()}while(e)}return u<=1},createRng:function(){return this.doc.createRange()},nodeIndex:Io,split:function(e,t,n){var r,o,i,a=this.createRng();if(e&&t)return a.setStart(e.parentNode,this.nodeIndex(e)),a.setEnd(t.parentNode,this.nodeIndex(t)),r=a.extractContents(),(a=this.createRng()).setStart(t.parentNode,this.nodeIndex(t)+1),a.setEnd(e.parentNode,this.nodeIndex(e)+1),o=a.extractContents(),(i=e.parentNode).insertBefore(no.trimNode(this,r),e),i.insertBefore(n||t,e),i.insertBefore(no.trimNode(this,o),e),this.remove(e),n||t},bind:function(e,t,n,r){if(kt.isArray(e)){for(var o=e.length;o--;)e[o]=this.bind(e[o],t,n,r);return e}return!this.settings.collect||e!==this.doc&&e!==this.win||this.boundEvents.push([e,t,n,r]),this.events.bind(e,t,n,r||this)},unbind:function(e,t,n){var r;if(kt.isArray(e)){for(r=e.length;r--;)e[r]=this.unbind(e[r],t,n);return e}if(this.boundEvents&&(e===this.doc||e===this.win))for(r=this.boundEvents.length;r--;){var o=this.boundEvents[r];e!==o[0]||t&&t!==o[1]||n&&n!==o[2]||this.events.unbind(o[0],o[1],o[2])}return this.events.unbind(e,t,n)},fire:function(e,t,n){return this.events.fire(e,t,n)},getContentEditable:function(e){var t;return e&&1===e.nodeType?(t=e.getAttribute("data-mce-contenteditable"))&&"inherit"!==t?t:"inherit"!==e.contentEditable?e.contentEditable:null:null},getContentEditableParent:function(e){for(var t=this.getRoot(),n=null;e&&e!==t&&null===(n=this.getContentEditable(e));e=e.parentNode);return n},destroy:function(){if(this.boundEvents){for(var e=this.boundEvents.length;e--;){var t=this.boundEvents[e];this.events.unbind(t[0],t[1],t[2])}this.boundEvents=null}rt.setDocument&&rt.setDocument(),this.win=this.doc=this.root=this.events=this.frag=null},isChildOf:function(e,t){for(;e;){if(t===e)return!0;e=e.parentNode}return!1},dumpRng:function(e){return"startContainer: "+e.startContainer.nodeName+", startOffset: "+e.startOffset+", endContainer: "+e.endContainer.nodeName+", endOffset: "+e.endOffset},_findSib:function(e,t,n){var r=this,o=t;if(e)for("string"==typeof o&&(o=function(e){return r.is(e,t)}),e=e[n];e;e=e[n])if(o(e))return e;return null}},Lo.DOM=new Lo(document),Lo.nodeIndex=Io;var Mo=Lo.DOM,Ho=kt.each,Fo=kt.grep,Wo=function(e){return"function"==typeof e},jo=function(){var e={},t=[],n={},r=[],o=0;this.isDone=function(t){return 2===e[t]},this.markDone=function(t){e[t]=2},this.add=this.load=function(r,o,i,a){void 0===e[r]&&(t.push(r),e[r]=0),o&&(n[r]||(n[r]=[]),n[r].push({success:o,failure:a,scope:i||this}))},this.remove=function(t){delete e[t],delete n[t]},this.loadQueue=function(e,n,r){this.loadScripts(t,e,n,r)},this.loadScripts=function(t,i,a,s){var u,c=[],l=function(e,t){Ho(n[t],function(t){Wo(t[e])&&t[e].call(t.scope)}),n[t]=void 0};
1r.push({success:i,failure:s,scope:a||this}),(u=function(){var n=Fo(t);if(t.length=0,Ho(n,function(t){2!==e[t]?3!==e[t]?1!==e[t]&&(e[t]=1,o++,function(e,t,n){var r,o,i=Mo,a=function(){i.remove(o),r&&(r.onreadystatechange=r.onload=r=null),t()};o=i.uniqueId(),(r=document.createElement("script")).id=o,r.type="text/javascript",r.src=kt._addCacheSuffix(e),"onreadystatechange"in r?r.onreadystatechange=function(){/loaded|complete/.test(r.readyState)&&a()}:r.onload=a,r.onerror=function(){Wo(n)?n():"undefined"!=typeof console&&console.log&&console.log("Failed to load script: "+e)},(document.getElementsByTagName("head")[0]||document.body).appendChild(r)}(t,function(){e[t]=2,o--,l("success",t),u()},function(){e[t]=3,o--,c.push(t),l("failure",t),u()})):l("failure",t):l("success",t)}),!o){var i=r.slice(0);r.length=0,Ho(i,function(e){0===c.length?Wo(e.success)&&e.success.call(e.scope):Wo(e.failure)&&e.failure.call(e.scope,c)})}})()}};jo.ScriptLoader=new jo;var $o=kt.each,zo=function(){this.items=[],this.urls={},this.lookup={},this._listeners=[]};zo.prototype={get:function(e){if(this.lookup[e])return this.lookup[e].instance},dependencies:function(e){var t;return this.lookup[e]&&(t=this.lookup[e].dependencies),t||[]},requireLangPack:function(e,t){var n=zo.language;if(n&&!1!==zo.languageLoad){if(t)if(-1!==(t=","+t+",").indexOf(","+n.substr(0,2)+","))n=n.substr(0,2);else if(-1===t.indexOf(","+n+","))return;jo.ScriptLoader.add(this.urls[e]+"/langs/"+n+".js")}},add:function(e,t,n){this.items.push(t),this.lookup[e]={instance:t,dependencies:n};var r=P.partition(this._listeners,function(t){return t.name===e});return this._listeners=r.fail,$o(r.pass,function(e){e.callback()}),t},remove:function(e){delete this.urls[e],delete this.lookup[e]},createUrl:function(e,t){return"object"==typeof t?t:{prefix:e.prefix,resource:t,suffix:e.suffix}},addComponents:function(e,t){var n=this.urls[e];$o(t,function(e){jo.ScriptLoader.add(n+"/"+e)})},load:function(e,t,n,r,o){var i=this,a=t,s=function(){var o=i.dependencies(e);$o(o,function(e){var n=i.createUrl(t,e);i.load(n.resource,n,void 0,void 0)}),n&&n.call(r||jo)};i.urls[e]||("object"==typeof t&&(a=t.prefix+t.resource+t.suffix),0!==a.indexOf("/")&&-1===a.indexOf("://")&&(a=zo.baseURL+"/"+a),i.urls[e]=a.substring(0,a.lastIndexOf("/")),i.lookup[e]?s():jo.ScriptLoader.add(a,s,r,o))},waitFor:function(e,t){this.lookup.hasOwnProperty(e)?t():this._listeners.push({name:e,callback:t})}},zo.PluginManager=new zo,zo.ThemeManager=new zo;var qo=function(e){return e.replace(new RegExp("\ufeff","g"),"")},Uo=Zr.isElement,Vo=Zr.isText,Xo=function(e){return Vo(e)&&(e=e.parentNode),Uo(e)&&e.hasAttribute("data-mce-caret")},Yo=function(e){return Vo(e)&&"\ufeff"===e.data},Ko=function(e){return Xo(e)||Yo(e)},Go=function(e){return e.firstChild!==e.lastChild||!Zr.isBr(e.firstChild)},Jo=function(e){var t=e.container();return e&&Zr.isText(t)&&"\ufeff"===t.data.charAt(e.offset())},Qo=function(e){var t=e.container();return e&&Zr.isText(t)&&"\ufeff"===t.data.charAt(e.offset()-1)},Zo=function(e){return Vo(e)&&"\ufeff"===e.data[0]},ei=function(e){return Vo(e)&&"\ufeff"===e.data[e.data.length-1]},ti=function(e){return e&&e.hasAttribute("data-mce-caret")?(t=e.getElementsByTagName("br"),Zr.isBogus(n=t[t.length-1])&&n.parentNode.removeChild(n),e.removeAttribute("data-mce-caret"),e.removeAttribute("data-mce-bogus"),e.removeAttribute("style"),e.removeAttribute("_moz_abspos"),e):null;var t,n},ni=Zr.isContentEditableTrue,ri=Zr.isContentEditableFalse,oi=Zr.isBr,ii=Zr.isText,ai=Zr.matchNodeNames("script style textarea"),si=Zr.matchNodeNames("img input textarea hr iframe video audio object"),ui=Zr.matchNodeNames("table"),ci=Ko,li=function(e){return!ci(e)&&(ii(e)?!ai(e.parentNode):si(e)||oi(e)||ui(e)||ri(e))},fi=function(e,t){return li(e)&&function(e,t){for(e=e.parentNode;e&&e!==t;e=e.parentNode){if(ri(e))return!1;if(ni(e))return!0}return!0}(e,t)},di=Math.round,hi=function(e){return e?{left:di(e.left),top:di(e.top),bottom:di(e.bottom),right:di(e.right),width:di(e.width),height:di(e.height)}:{left:0,top:0,bottom:0,right:0,width:0,height:0}},pi=function(e,t){return e=hi(e),t?e.right=e.left:(e.left=e.left+e.width,e.right=e.left),e.width=0,e},mi=function(e,t,n){return e>=0&&e<=Math.min(t.height,n.height)/2},gi=function(e,t){return e.bottom-e.height/2<t.top||!(e.top>t.bottom)&&mi(t.top-e.bottom,e,t)},vi=function(e,t){return e.top>t.bottom||!(e.bottom<t.top)&&mi(t.bottom-e.top,e,t)},yi=function(e){var t=e.startContainer,n=e.startOffset;return t.hasChildNodes()&&e.endOffset===n+1?t.childNodes[n]:null},bi=function(e,t){return 1===e.nodeType&&e.hasChildNodes()&&(t>=e.childNodes.length&&(t=e.childNodes.length-1),e=e.childNodes[t]),e}
1,wi=new RegExp("[\u0300-\u036f\u0483-\u0487\u0488-\u0489\u0591-\u05bd\u05bf\u05c1-\u05c2\u05c4-\u05c5\u05c7\u0610-\u061a\u064b-\u065f\u0670\u06d6-\u06dc\u06df-\u06e4\u06e7-\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0859-\u085b\u08e3-\u0902\u093a\u093c\u0941-\u0948\u094d\u0951-\u0957\u0962-\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2-\u09e3\u0a01-\u0a02\u0a3c\u0a41-\u0a42\u0a47-\u0a48\u0a4b-\u0a4d\u0a51\u0a70-\u0a71\u0a75\u0a81-\u0a82\u0abc\u0ac1-\u0ac5\u0ac7-\u0ac8\u0acd\u0ae2-\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62-\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c00\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55-\u0c56\u0c62-\u0c63\u0c81\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc-\u0ccd\u0cd5-\u0cd6\u0ce2-\u0ce3\u0d01\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62-\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb-\u0ebc\u0ec8-\u0ecd\u0f18-\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86-\u0f87\u0f8d-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039-\u103a\u103d-\u103e\u1058-\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085-\u1086\u108d\u109d\u135d-\u135f\u1712-\u1714\u1732-\u1734\u1752-\u1753\u1772-\u1773\u17b4-\u17b5\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927-\u1928\u1932\u1939-\u193b\u1a17-\u1a18\u1a1b\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1ab0-\u1abd\u1abe\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80-\u1b81\u1ba2-\u1ba5\u1ba8-\u1ba9\u1bab-\u1bad\u1be6\u1be8-\u1be9\u1bed\u1bef-\u1bf1\u1c2c-\u1c33\u1c36-\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1cf4\u1cf8-\u1cf9\u1dc0-\u1df5\u1dfc-\u1dff\u200c-\u200d\u20d0-\u20dc\u20dd-\u20e0\u20e1\u20e2-\u20e4\u20e5-\u20f0\u2cef-\u2cf1\u2d7f\u2de0-\u2dff\u302a-\u302d\u302e-\u302f\u3099-\u309a\ua66f\ua670-\ua672\ua674-\ua67d\ua69e-\ua69f\ua6f0-\ua6f1\ua802\ua806\ua80b\ua825-\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\ua9e5\uaa29-\uaa2e\uaa31-\uaa32\uaa35-\uaa36\uaa43\uaa4c\uaa7c\uaab0\uaab2-\uaab4\uaab7-\uaab8\uaabe-\uaabf\uaac1\uaaec-\uaaed\uaaf6\uabe5\uabe8\uabed\ufb1e\ufe00-\ufe0f\ufe20-\ufe2f\uff9e-\uff9f]"),xi=function(e){return"string"==typeof e&&e.charCodeAt(0)>=768&&wi.test(e)},Ci=[].slice,Si=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Ci.call(arguments);return r.length-1>=e.length?e.apply(this,r.slice(1)):function(){var e=r.concat([].slice.call(arguments));return Si.apply(this,e)}},Ti={constant:function(e){return function(){return e}},negate:function(e){return function(t){return!e(t)}},and:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Ci.call(arguments);return function(e){for(var t=0;t<n.length;t++)if(!n[t](e))return!1;return!0}},or:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Ci.call(arguments);return function(e){for(var t=0;t<n.length;t++)if(n[t](e))return!0;return!1}},curry:Si,compose:function(e,t){return function(n){return e(t(n))}},noop:function(){}},Ei=Zr.isElement,ki=li,Ni=Zr.matchStyleValues("display","block table"),Ri=Zr.matchStyleValues("float","left right"),_i=Ti.and(Ei,ki,Ti.negate(Ri)),Ai=Ti.negate(Zr.matchStyleValues("white-space","pre pre-line pre-wrap")),Di=Zr.isText,Oi=Zr.isBr,Pi=Lo.nodeIndex,Bi=bi,Ii=function(e){return"createRange"in e?e.createRange():Lo.DOM.createRng()},Li=function(e){return e&&/[\r\n\t ]/.test(e)},Mi=function(e){return!!e.setStart&&!!e.setEnd},Hi=function(e){var t,n=e.startContainer,r=e.startOffset;return!!(Li(e.toString())&&Ai(n.parentNode)&&Zr.isText(n)&&(Li((t=n.data)[r-1])||Li(t[r+1])))},Fi=function(e){return 0===e.left&&0===e.right&&0===e.top&&0===e.bottom},Wi=function(e){var t,n;return n=e.getClientRects(),t=hi(n.length>0?n[0]:e.getBoundingClientRect()),!Mi(e)&&Oi(e)&&Fi(t)?function(e){var t,n=e.ownerDocument,r=Ii(n),o=n.createTextNode("\xa0"),i=e.parentNode;return i.insertBefore(o,e),r.setStart(o,0),r.setEnd(o,1),t=hi(r.getBoundingClientRect()),i.removeChild(o),t}(e):Fi(t)&&Mi(e)?function(e){var t=e.endContainer,n=e.startOffset,r=e.endOffset;if(e.startContainer===t&&Zr.isText(t)&&0===n&&1===r){var o=e.cloneRange();return o.setEndAfter(t),Wi(o)}return null}(e):t},ji=function(e,t){var n=pi(e,t);return n.width=1,n.right=n.left+1,n},$i=function(e){var t,n,r=[],o=function(e){var t,n;0!==e.height&&(r.length>0&&(t=e).left===(n=r[r.length-1]).left&&t.top===n.top&&t.bottom===n.bottom&&t.right===n.right||r.push(e))},i=function(e,t){var n=Ii(e.ownerDocument);if(t<e.data.length){if(xi(e.data[t]))return r;if(xi(e.data[t-1])&&(n.setStart(e,t),n.setEnd(e,t+1),!Hi(n)))return o(ji(Wi(n),!1)),r}t>0&&(n.setStart(e,t-1),n.setEnd(e,t),Hi(n)||o(ji(Wi(n),!1))),t<e.data.length&&(n.setStart(e,t),n.setEnd(e,t+1),Hi(n)||o(ji(Wi(n),!0)))};if(Di(e.container()))return i(e.container(),e.offset()),r;if(Ei(e.container()))if(e.isAtEnd())n=Bi(e.container(),e.offset()),Di(n)&&i(n,n.data.length),_i(n)&&!Oi(n)&&o(ji(Wi(n),!1));else{if(n=Bi(e.container(),e.offset()),Di(n)&&i(n,0),_i(n)&&e.isAtEnd())return o(ji(Wi(n),!1)),r;t=Bi(e.container(),e.offset()-1),_i(t)&&!Oi(t)&&(Ni(t)||Ni(n)||!_i(n))&&o(ji(Wi(t),!1)),_i(n)&&o(ji(Wi(n),!0))}return r};function zi(e,t,n){var r=function(){return n||(n=$i(zi(e,t))),n};return{container:Ti.constant(e),offset:Ti.constant(t),toRange:function(){var n;return(n=Ii(e.ownerDocument)).setStart(e,t),n.setEnd(e,t),n},getClientRects:r,isVisible:function(){return r().length>0},isAtStart:function(){return Di(e),0===t}
1,isAtEnd:function(){return Di(e)?t>=e.data.length:t>=e.childNodes.length},isEqual:function(n){return n&&e===n.container()&&t===n.offset()},getNode:function(n){return Bi(e,n?t-1:t)}}}!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,Pi(t)+1)},e.before=function(t){return e(t.parentNode,Pi(t))},e.isAtStart=function(e){return!!e&&e.isAtStart()},e.isAtEnd=function(e){return!!e&&e.isAtEnd()},e.isTextPosition=function(e){return!!e&&Zr.isText(e.container())}}(zi||(zi={}));var qi,Ui=zi,Vi=Zr.isElement,Xi=Zr.isText,Yi=function(e){var t=e.parentNode;t&&t.removeChild(e)},Ki=function(e,t){0===t.length?Yi(e):e.nodeValue=t},Gi=function(e){var t=qo(e);return{count:e.length-t.length,text:t}},Ji=function(e,t){return Qi(e),t},Qi=function(e){if(Vi(e)&&Ko(e)&&(Go(e)?e.removeAttribute("data-mce-caret"):Yi(e)),Xi(e)){var t=qo(function(e){try{return e.nodeValue}catch(e){return""}}(e));Ki(e,t)}},Zi={removeAndReposition:function(e,t){return Ui.isTextPosition(t)?function(e,t){return Xi(e)&&t.container()===e?function(e,t){var n=Gi(e.data.substr(0,t.offset())),r=Gi(e.data.substr(t.offset())),o=n.text+r.text;return o.length>0?(Ki(e,o),Ui(e,t.offset()-n.count)):t}(e,t):Ji(e,t)}(e,t):function(e,t){return t.container()===e.parentNode?function(e,t){var n=t.container(),r=P.indexOf(n.childNodes,e).map(function(e){return e<t.offset()?Ui(n,t.offset()-1):t}).getOr(t);return Qi(e),r}(e,t):Ji(e,t)}(e,t)},remove:Qi},ea=function(e){return Ui.isTextPosition(e)?0===e.offset():li(e.getNode())},ta=function(e){if(Ui.isTextPosition(e)){var t=e.container();return e.offset()===t.data.length}return li(e.getNode(!0))},na=function(e,t){return!Ui.isTextPosition(e)&&!Ui.isTextPosition(t)&&e.getNode()===t.getNode(!0)},ra=function(e,t,n){var r=Cs(t);return w.from(e?r.next(n):r.prev(n))},oa=function(e,t){var n,r=e?t.firstChild:t.lastChild;return Zr.isText(r)?w.some(Ui(r,e?0:r.data.length)):r?li(r)?w.some(e?Ui.before(r):Zr.isBr(n=r)?Ui.before(n):Ui.after(n)):function(e,t,n){var r=e?Ui.before(n):Ui.after(n);return ra(e,t,r)}(e,t,r):w.none()},ia={fromPosition:ra,nextPosition:p.curry(ra,!0),prevPosition:p.curry(ra,!1),navigate:function(e,t,n){return ra(e,t,n).bind(function(r){return Ga(n,r,t)&&function(e,t,n){return e?!na(t,n)&&!(!Ui.isTextPosition(r=t)&&Zr.isBr(r.getNode()))&&ta(t)&&ea(n):!na(n,t)&&ea(t)&&ta(n);var r}(e,n,r)?ra(e,t,r):w.some(r)})},positionIn:oa,firstPositionIn:p.curry(oa,!0),lastPositionIn:p.curry(oa,!1)},aa=Zr.isContentEditableTrue,sa=Zr.isContentEditableFalse,ua=function(e,t,n,r){return t._selectionOverrides.showCaret(e,n,r)},ca=function(e,t){return e.fire("BeforeObjectSelected",{target:t}).isDefaultPrevented()?null:function(e){var t=e.ownerDocument.createRange();return t.selectNode(e),t}(t)},la=function(e,t){var n,r;return t=rs(1,e.getBody(),t),n=Ui.fromRangeStart(t),sa(n.getNode())?ua(1,e,n.getNode(),!n.isAtEnd()):sa(n.getNode(!0))?ua(1,e,n.getNode(!0),!1):(r=e.dom.getParent(n.getNode(),function(e){return sa(e)||aa(e)}),sa(r)?ua(1,e,r,!1):null)},fa=function(e,t){return t&&t.collapsed&&la(e,t)||t},da=function(e,t){for(var n=[],r=0;r<e.length;r++){var o=e[r];if(!o.isSome())return w.none();n.push(o.getOrDie())}return w.some(t.apply(null,n))};!function(e){e[e.Br=0]="Br",e[e.Block=1]="Block",e[e.Wrap=2]="Wrap",e[e.Eol=3]="Eol"}(qi||(qi={}));var ha,pa=function(e,t){return e===ha.Backwards?t.reverse():t},ma=function(e,t,n){return e===ha.Forwards?t.next(n):t.prev(n)},ga=function(e,t,n,r){return Zr.isBr(r.getNode(t===ha.Forwards))?qi.Br:!1===Ga(n,r)?qi.Block:qi.Wrap},va=function(e,t,n,r){for(var o,i=Cs(n),a=r,s=[];a&&(o=ma(t,i,a));){if(Zr.isBr(o.getNode(!1)))return t===ha.Forwards?{positions:pa(t,s).concat([o]),breakType:qi.Br,breakAt:w.some(o)}:{positions:pa(t,s),breakType:qi.Br,breakAt:w.some(o)};if(o.isVisible()){if(e(a,o)){var u=ga(0,t,a,o);return{positions:pa(t,s),breakType:u,breakAt:w.some(o)}}s.push(o),a=o}else a=o}return{positions:pa(t,s),breakType:qi.Eol,breakAt:w.none()}},ya=function(e,t,n,r){return t(n,r).breakAt.map(function(r){var o=t(n,r).positions;return e===ha.Backwards?o.concat(r):[r].concat(o)}).getOr([])},ba=function(e,t){return P.foldl(e,function(e,n){return e.fold(function(){return w.some(n)},function(r){return da([P.head(r.getClientRects()),P.head(n.getClientRects())],function(e,o){var i=Math.abs(t-e.left);return Math.abs(t-o.left)<=i?n:r}).or(e)})},w.none())},wa=function(e,t){return P.head(t.getClientRects()).bind(function(t){return ba(e,t.left)})},xa=p.curry(va,function(e,t){return da([P.head(t.getClientRects()),P.last(e.getClientRects())],gi).getOr(!1)},-1),Ca=p.curry(va,function(e,t){return da([P.last(t.getClientRects()),P.head(e.getClientRects())],function(e,t){return vi(e,t)}).getOr(!1)}
1,1),Sa=p.curry(ya,-1,xa),Ta=p.curry(ya,1,Ca),Ea=function(e,t){return nr.all(t,e)},ka=function(e,t,n,r,o){var i=Ea(_n(n),"td,th").map(function(e){return e.dom()});return function(e,t,n){return P.foldl(e,function(e,r){return e.fold(function(){return w.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 w.some(i<o?r:e)})},w.none())}(P.filter(function(e,t){return P.bind(i,function(t){var n=function(e,t){return{left:e.left- -1,top:e.top- -1,right:e.right+-2,bottom:e.bottom+-2,width:e.width+-1,height:e.height+-1}}(t.getBoundingClientRect());return[{x:n.left,y:e(n),cell:t},{x:n.right,y:e(n),cell:t}]})}(e),function(e){return t(e,o)}),r,o).map(function(e){return e.cell})},Na=p.curry(ka,function(e){return e.bottom},function(e,t){return e.y<t}),Ra=p.curry(ka,function(e){return e.top},function(e,t){return e.y>t}),_a=Tn.detect().browser,Aa=function(){return _a.isIE()||_a.isEdge()||_a.isFirefox()},Da=function(e,t,n){var r=e(t,n);return r.breakType===qi.Wrap&&0===r.positions.length?r.breakAt.map(function(n){return e(t,n).breakAt.isNone()}).getOr(!0):r.breakAt.isNone()},Oa=Ti.curry(Da,xa),Pa=Ti.curry(Da,Ca),Ba=function(e,t){return function(){return w.from(e.dom.getParent(e.selection.getNode(),"td,th")).bind(function(n){return w.from(e.dom.getParent(n,"table")).map(function(n){return function(e,t,n,r){var o=e.selection.getRng(),i=t?1:-1;if(Aa()&&function(e,t,n){var r=Ui.fromRangeStart(t);return ia.positionIn(!e,n).map(function(e){return e.isEqual(r)}).getOr(!1)}(t,o,n)){var a=ua(i,e,n,!t);return e.selection.setRng(a),!0}return!1}(e,t,n)})}).getOr(!1)}},Ia=function(e,t){return function(){return w.from(e.dom.getParent(e.selection.getNode(),"td,th")).bind(function(n){return w.from(e.dom.getParent(n,"table")).map(function(r){return function(e,t,n,r){var o=e.selection.getRng(),i=Ui.fromRangeStart(o),a=e.getBody();if(!t&&Oa(r,i)){var s=function(e,t,n){return function(e,t){return P.head(t.getClientRects()).bind(function(t){return Na(e,t.left,t.top)}).bind(function(e){return wa(ia.lastPositionIn(n=e).map(function(e){return xa(n,e).positions.concat(e)}).getOr([]),t);var n})}(t,n).orThunk(function(){return P.head(n.getClientRects()).bind(function(n){return ba(Sa(e,Ui.before(t)),n.left)})}).getOr(Ui.before(t))}(a,n,i);return e.selection.setRng(s.toRange()),!0}return!(!t||!Pa(r,i)||(s=function(e,t,n){return function(e,t){return P.last(t.getClientRects()).bind(function(t){return Ra(e,t.left,t.top)}).bind(function(e){return wa(ia.firstPositionIn(n=e).map(function(e){return[e].concat(Ca(n,e).positions)}).getOr([]),t);var n})}(t,n).orThunk(function(){return P.head(n.getClientRects()).bind(function(n){return ba(Ta(e,Ui.after(t)),n.left)})}).getOr(Ui.after(t))}(a,n,i),e.selection.setRng(s.toRange()),0))}(e,t,r,n)})}).getOr(!1)}},La=Zr.isContentEditableFalse,Ma=function(e){return La(e)||Zr.isTable(e)&&Aa()},Ha=Zr.isContentEditableFalse,Fa=Zr.matchStyleValues("display","block table table-cell table-caption list-item"),Wa=Ko,ja=Xo,$a=Ti.curry,za=Zr.isElement,qa=li,Ua=function(e){return e>0},Va=function(e){return e<0},Xa=function(e,t){for(var n;n=e(t);)if(!ja(n))return n;return null},Ya=function(e,t,n,r,o){var i=new Rr(e,r);if(Va(t)){if((Ha(e)||ja(e))&&n(e=Xa(i.prev,!0)))return e;for(;e=Xa(i.prev,o);)if(n(e))return e}if(Ua(t)){if((Ha(e)||ja(e))&&n(e=Xa(i.next,!0)))return e;for(;e=Xa(i.next,o);)if(n(e))return e}return null},Ka=function(e,t){for(;e&&e!==t;){if(Fa(e))return e;e=e.parentNode}return null},Ga=function(e,t,n){return Ka(e.container(),n)===Ka(t.container(),n)},Ja=function(e,t){var n,r;return t?(n=t.container(),r=t.offset(),za(n)?n.childNodes[r+e]:null):null},Qa=function(e,t){var n=t.ownerDocument.createRange();return e?(n.setStartBefore(t),n.setEndBefore(t)):(n.setStartAfter(t),n.setEndAfter(t)),n},Za=function(e,t,n){return Ka(t,e)===Ka(n,e)},es=function(e,t,n){var r,o;for(o=e?"previousSibling":"nextSibling";n&&n!==t;){if(Wa(r=n[o])&&(r=r[o]),Ha(r)){if(Za(t,r,n))return r;break}if(qa(r))break;n=n.parentNode}return null},ts=$a(Qa,!0),ns=$a(Qa,!1),rs=function(e,t,n){var r,o,i,a,s=$a(es,!0,t),u=$a(es,!1,t);if(i=n.startOffset,Xo(o=n.startContainer)){if(za(o)||(o=o.parentNode),"before"===(a=o.getAttribute("data-mce-caret"))&&Ma(r=o.nextSibling))return ts(r);if("after"===a&&Ma(r=o.previousSibling))return ns(r)}if(!n.collapsed)return n;if(Zr.isText(o)){if(Wa(o)){if(1===e){if(r=u(o))return ts(r);if(r=s(o))return ns(r)}if(-1===e){if(r=s(o))return ns(r);if(r=u(o))return ts(r)}return n}if(ei(o)&&i>=o.data.length-1)return 1===e&&(r=u(o))?ts(r):n;if(Zo(o)&&i<=1)return-1===e&&(r=s(o))?ns(r):n;if(i===o.data.length)return(r=u(o))?ts(r):n;if(0===i)return(r=s(o))?ns(r):n}return n},os=function(e,t){var n=Ja(e,t);return Ha(n)&&!Zr.isBogusAll(n)},is=function(e,t){return Zr.isTable(Ja(e,t))},as=function(e,t){return w.from(Ja(e?0:-1,t)).filter(Ha)}
1,ss=function(e,t,n){var r=rs(e,t,n);return-1===e?zi.fromRangeStart(r):zi.fromRangeEnd(r)},us=$a(os,0),cs=$a(os,-1),ls=$a(is,0),fs=$a(is,-1);!function(e){e[e.Backwards=-1]="Backwards",e[e.Forwards=1]="Forwards"}(ha||(ha={}));var ds=Zr.isContentEditableFalse,hs=Zr.isText,ps=Zr.isElement,ms=Zr.isBr,gs=li,vs=function(e){return si(e)||function(e){return!!ri(e)&&!0!==xt.reduce(e.getElementsByTagName("*"),function(e,t){return e||ni(t)},!1)}(e)},ys=fi,bs=function(e,t){return e.hasChildNodes()&&t<e.childNodes.length?e.childNodes[t]:null},ws=function(e,t){if(Ua(e)){if(gs(t.previousSibling)&&!hs(t.previousSibling))return Ui.before(t);if(hs(t))return Ui(t,0)}if(Va(e)){if(gs(t.nextSibling)&&!hs(t.nextSibling))return Ui.after(t);if(hs(t))return Ui(t,t.data.length)}return Va(e)?ms(t)?Ui.before(t):Ui.after(t):Ui.before(t)},xs=function(e,t,n){var r,o,i,a,s;if(!ps(n)||!t)return null;if(t.isEqual(Ui.after(n))&&n.lastChild){if(s=Ui.after(n.lastChild),Va(e)&&gs(n.lastChild)&&ps(n.lastChild))return ms(n.lastChild)?Ui.before(n.lastChild):s}else s=t;var u=s.container(),c=s.offset();if(hs(u)){if(Va(e)&&c>0)return Ui(u,--c);if(Ua(e)&&c<u.length)return Ui(u,++c);r=u}else{if(Va(e)&&c>0&&(o=bs(u,c-1),gs(o)))return!vs(o)&&(i=Ya(o,e,ys,o))?hs(i)?Ui(i,i.data.length):Ui.after(i):hs(o)?Ui(o,o.data.length):Ui.before(o);if(Ua(e)&&c<u.childNodes.length&&(o=bs(u,c),gs(o)))return function(e,t){var n;return!!Zr.isBr(e)&&!!(n=xs(1,Ui.after(e),t))&&!Ga(Ui.before(e),Ui.before(n),t)}(o,n)?xs(e,Ui.after(o),n):!vs(o)&&(i=Ya(o,e,ys,o))?hs(i)?Ui(i,0):Ui.before(i):hs(o)?Ui(o,0):Ui.after(o);r=o||s.getNode()}return(Ua(e)&&s.isAtEnd()||Va(e)&&s.isAtStart())&&(r=Ya(r,e,Ti.constant(!0),n,!0),ys(r,n))?ws(e,r):(o=Ya(r,e,ys,n),!(a=xt.last(xt.filter(function(e,t){for(var n=[];e&&e!==t;)n.push(e),e=e.parentNode;return n}(u,n),ds)))||o&&a.contains(o)?o?ws(e,o):null:s=Ua(e)?Ui.after(a):Ui.before(a))},Cs=function(e){return{next:function(t){return xs(ha.Forwards,t,e)},prev:function(t){return xs(ha.Backwards,t,e)}}},Ss=function(e,t){var n=e.getParent(t,e.isBlock);return n&&"LI"===n.nodeName?n:null},Ts=function(e,t){var n=Ui.after(e),r=Cs(t).prev(n);return r?r.toRange():null},Es=function(e,t,n,r){var o=function(e,t,n){var r=t.serialize(n);return 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}(e.createFragment(r))}(t,e,r),i=Ss(t,n.startContainer),a=function(e){return e.length>0&&(!(n=e[e.length-1]).firstChild||(t=n)&&t.firstChild&&t.firstChild===t.lastChild&&function(e){return"\xa0"===e.data||Zr.isBr(e)}(t.firstChild))?e.slice(0,-1):e;var t,n}(kt.grep(o.firstChild.childNodes,function(e){return"LI"===e.nodeName})),s=t.getRoot(),u=function(e){var r=Ui.fromRangeStart(n),o=Cs(t.getRoot()),a=1===e?o.prev(r):o.next(r);return!a||Ss(t,a.getNode())!==i};return u(1)?function(e,t,n){var r=e.parentNode;return kt.each(a,function(t){r.insertBefore(t,e)}),function(t,n){var r=Ui.before(e),o=Cs(n).next(r);return o?o.toRange():null}(0,n)}(i,0,s):u(2)?function(e,t,n,r){return r.insertAfter(t.reverse(),e),Ts(t[0],n)}(i,a,s,t):function(e,t,n,r){var o=function(e,t){var n=t.cloneRange(),r=t.cloneRange();return n.setStartBefore(e),r.setEndAfter(e),[n.cloneContents(),r.cloneContents()]}(e,r),i=e.parentNode;return i.insertBefore(o[0],e),kt.each(t,function(t){i.insertBefore(t,e)}),i.insertBefore(o[1],e),i.removeChild(e),Ts(t[t.length-1],n)}(i,a,s,n)},ks=Zr.isText,Ns=Zr.isBogus,Rs=Lo.nodeIndex,_s=function(e){var t=e.parentNode;return Ns(t)?_s(t):t},As=function(e){return e?xt.reduce(e.childNodes,function(e,t){return Ns(t)&&"BR"!==t.nodeName?e=e.concat(As(t)):e.push(t),e},[]):[]},Ds=function(e){return function(t){return e===t}},Os=function(e){return(ks(e)?"text()":e.nodeName.toLowerCase())+"["+function(e){var t,n,r;return t=As(_s(e)),n=xt.findIndex(t,Ds(e),e),t=t.slice(0,n+1),r=xt.reduce(t,function(e,n,r){return ks(n)&&ks(t[r-1])&&e++,e},0),t=xt.filter(t,Zr.matchNodeNames(e.nodeName)),(n=xt.findIndex(t,Ds(e),e))-r}(e)+"]"},Ps=function(e,t){var n,r,o,i,a,s=[];return n=t.container(),r=t.offset(),ks(n)?o=function(e,t){for(;(e=e.previousSibling)&&ks(e);)t+=e.data.length;return t}(n,r):(r>=(i=n.childNodes).length?(o="after",r=i.length-1):o="before",n=i[r]),s.push(Os(n)),a=function(e,t,n){var r=[];for(t=t.parentNode;t!==e;t=t.parentNode)r.push(t);return r}(e,n),a=xt.filter(a,Ti.negate(Zr.isBogus)),(s=s.concat(xt.map(a,function(e){return Os(e)}))).reverse().join("/")+","+o},Bs=function(e,t){var n,r,o;return t?(t=(n=t.split(","))[0].split("/"),o=n.length>1?n[1]:"before",(r=xt.reduce(t,function(e,t){return(t=/([\w\-\(\)]+)\[([0-9]+)\]/.exec(t))?("text()"===t[1]&&(t[1]="#text"),n=e,r=t[1],o=parseInt(t[2],10),i=As(n),i=xt.filter(i,function(e,t){return!ks(e)||!ks(i[t-1])}),(i=xt.filter(i,Zr.matchNodeNames(r)))[o]):null;var n,r,o,i},e))?ks(r)?function(e,t){for(var n,r=e,o=0;ks(r);){if(n=r.data.length,t>=o&&t<=o+n){e=r,t-=o;break}if(!ks(r.nextSibling)){e=r,t=n;break}o+=n,r=r.nextSibling}return ks(e)&&t>e.data.length&&(t=e.data.length),Ui(e,t)}(r,parseInt(o,10)):(o="after"===o?Rs(r)+1:Rs(r),Ui(r.parentNode,o)):null):null},Is=Zr.isContentEditableFalse,Ls=function(e,t,n,r,o){var i,a=r[o?"startContainer":"endContainer"],s=r[o?"startOffset":"endOffset"],u=[],c=0,l=e.getRoot();for(Zr.isText(a)?u.push(n?function(e,t,n){var r,o;for(o=e(t.data.slice(0,n)).length,r=t.previousSibling;r&&Zr.isText(r);r=r.previousSibling)o+=e(r.data).length;return o}(t,a,s):s):(s>=(i=a.childNodes).length&&i.length&&(c=1,s=Math.max(0,i.length-1)),u.push(e.nodeIndex(i[s],n)+c));a&&a!==l;a=a.parentNode)u.push(e.nodeIndex(a,n));return u}
1,Ms=function(e){Zr.isText(e)&&0===e.data.length&&e.parentNode.removeChild(e)},Hs=function(e,t,n){var r=0;return kt.each(e.select(t),function(e){if("all"!==e.getAttribute("data-mce-bogus"))return e!==n&&void r++}),r},Fs=function(e,t){var n,r,o,i=t?"start":"end";r=e[i+"Offset"],Zr.isElement(n=e[i+"Container"])&&"TR"===n.nodeName&&(n=(o=n.childNodes)[Math.min(t?r:r-1,o.length-1)])&&(r=t?0:n.childNodes.length,e["set"+(t?"Start":"End")](n,r))},Ws=function(e){return Fs(e,!0),Fs(e,!1),e},js=function(e,t){var n;if(Zr.isElement(e)&&(e=bi(e,t),Is(e)))return e;if(Ko(e)){if(Zr.isText(e)&&Xo(e)&&(e=e.parentNode),Is(n=e.previousSibling))return n;if(Is(n=e.nextSibling))return n}},$s=function(e,t,n){var r=n.getNode(),o=r?r.nodeName:null,i=n.getRng();return Is(r)||"IMG"===o?{name:o,index:Hs(n.dom,o,r)}:(r=function(e){return js(e.startContainer,e.startOffset)||js(e.endContainer,e.endOffset)}(i))?{name:o=r.tagName,index:Hs(n.dom,o,r)}:function(e,t,n,r){var o=t.dom,i={};return i.start=Ls(o,e,n,r,!0),t.isCollapsed()||(i.end=Ls(o,e,n,r,!1)),i}(e,n,t,i)},zs={getBookmark:function(e,t,n){return 2===t?$s(qo,n,e):3===t?function(e){var t=e.getRng();return{start:Ps(e.dom.getRoot(),Ui.fromRangeStart(t)),end:Ps(e.dom.getRoot(),Ui.fromRangeEnd(t))}}(e):t?function(e){return{rng:e.getRng()}}(e):function(e){var t=e.dom,n=e.getRng(),r=t.uniqueId(),o=e.isCollapsed(),i="overflow:hidden;line-height:0px",a=e.getNode(),s=a.nodeName;if("IMG"===s)return{name:s,index:Hs(t,s,a)};var u=Ws(n.cloneRange());if(!o){u.collapse(!1);var c=t.create("span",{"data-mce-type":"bookmark",id:r+"_end",style:i},"");u.insertNode(c),Ms(c.nextSibling)}(n=Ws(n)).collapse(!0);var l=t.create("span",{"data-mce-type":"bookmark",id:r+"_start",style:i},"");return n.insertNode(l),Ms(l.previousSibling),e.moveToBookmark({id:r,keep:1}),{id:r}}(e)},getUndoBookmark:p.curry($s,p.identity,!0)},qs=function(e,t){return!e.isBlock(t)||t.innerHTML||ae.ie||(t.innerHTML='<br data-mce-bogus="1" />'),t},Us=function(e,t,n,r){var o,i,a,s,u=n[t?"start":"end"],c=e.getRoot();if(u){for(a=u[0],i=c,o=u.length-1;o>=1;o--){if(u[o]>(s=i.childNodes).length-1)return;i=s[u[o]]}3===i.nodeType&&(a=Math.min(u[0],i.nodeValue.length)),1===i.nodeType&&(a=Math.min(u[0],i.childNodes.length)),t?r.setStart(i,a):r.setEnd(i,a)}return!0},Vs=function(e,t,n){var r,o,i,a,s,u,c=e.get(n.id+"_"+t),l=n.keep;if(c){if(r=c.parentNode,l?(r=c.firstChild,o=1):o=e.nodeIndex(c),s=r,u=o,!l){for(a=c.previousSibling,i=c.nextSibling,kt.each(kt.grep(c.childNodes),function(e){Zr.isText(e)&&(e.nodeValue=e.nodeValue.replace(/\uFEFF/g,""))});c=e.get(n.id+"_"+t);)e.remove(c,1);a&&i&&a.nodeType===i.nodeType&&Zr.isText(a)&&!ae.opera&&(o=a.nodeValue.length,a.appendData(i.nodeValue),e.remove(i),s=a,u=o)}return w.some(Ui(s,u))}return w.none()},Xs={getBookmark:function(e,t,n){return zs.getBookmark(e,t,n)},moveToBookmark:function(e,t){(function(e,t){var n=e.dom;if(t){if(kt.isArray(t.start))return function(e,t){var n=e.createRng();return Us(e,!0,t,n)&&Us(e,!1,t,n)?w.some(n):w.none()}(n,t);if("string"==typeof t.start)return w.some(function(e,t){var n,r;return n=e.createRng(),r=Bs(e.getRoot(),t.start),n.setStart(r.container(),r.offset()),r=Bs(e.getRoot(),t.end),n.setEnd(r.container(),r.offset()),n}(n,t));if(t.id)return function(e,t){var n,r,o=Vs(e,"start",t),i=Vs(e,"end",t);return da([o,(n=i,r=o,n.isSome()?n:r)],function(t,n){var r=e.createRng();return r.setStart(qs(e,t.container()),t.offset()),r.setEnd(qs(e,n.container()),n.offset()),r})}(n,t);if(t.name)return function(e,t){return w.from(e.select(t.name)[t.index]).map(function(t){var n=e.createRng();return n.selectNode(t),n})}(n,t);if(t.rng)return w.some(t.rng)}return w.none()})(e,t).each(function(t){e.setRng(t)})},isBookmarkNode:function(e){return Zr.isElement(e)&&"SPAN"===e.tagName&&"bookmark"===e.getAttribute("data-mce-type")}},Ys=kt.each,Ks=function(e){this.compare=function(t,n){if(t.nodeName!==n.nodeName)return!1;var r=function(t){var n={};return Ys(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("undefined"==typeof(n=t[r]))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")))||Xs.isBookmarkNode(t)||Xs.isBookmarkNode(n))}},Gs=function(e,t){fr(e).each(function(n){n.dom().insertBefore(t.dom(),e.dom())})},Js=function(e,t){e.dom().appendChild(t.dom())},Qs=Gs,Zs=function(e,t){pr(e).fold(function(){fr(e).each(function(e){Js(e,t)})},function(e){Gs(e,t)})},eu=Js,tu=function(e,t){P.each(t,function(t){eu(e,t)})},nu=function(e){var t=e.dom();null!==t.parentNode&&t.parentNode.removeChild(t)},ru=function(e){e.dom().textContent="",P.each(mr(e),function(e){nu(e)})}
1,ou=nu,iu=function(e,t){var n=function(t){return e(t)?w.from(t.dom().nodeValue):w.none()},r=Tn.detect().browser,o=r.isIE()&&10===r.version.major?function(e){try{return n(e)}catch(e){return w.none()}}:n;return{get:function(t){if(!e(t))throw new Error("Can only get text value of a text node");return o(t).getOr("")},getOption:o,set:function(t,n){if(!e(t))throw new Error("Can only set raw text value of a text node");t.dom().nodeValue=n}}}(Ln.isText),au=function(e){ru(e),eu(e,kn('<br data-mce-bogus="1">'))},su=function(e){vr(e).each(function(t){hr(t).each(function(n){Br(e)&&Lr(t)&&Br(n)&&ou(t)})})},uu=kt.makeMap;function cu(e){var t,n,r,o,i,a=[];return t=(e=e||{}).indent,n=uu(e.indent_before||""),r=uu(e.indent_after||""),o=po.getEncodeFunc(e.entity_encoding||"raw",e.entities),i="html"===e.element_format,{start:function(e,s,u){var c,l,f,d;if(t&&n[e]&&a.length>0&&(d=a[a.length-1]).length>0&&"\n"!==d&&a.push("\n"),a.push("<",e),s)for(c=0,l=s.length;c<l;c++)a.push(" ",(f=s[c]).name,'="',o(f.value,!0),'"');a[a.length]=!u||i?">":" />",u&&t&&r[e]&&a.length>0&&(d=a[a.length-1]).length>0&&"\n"!==d&&a.push("\n")},end:function(e){var n;a.push("</",e,">"),t&&r[e]&&a.length>0&&(n=a[a.length-1]).length>0&&"\n"!==n&&a.push("\n")},text:function(e,t){e.length>0&&(a[a.length]=t?e:o(e))},cdata:function(e){a.push("<![CDATA[",e,"]]>")},comment:function(e){a.push("\x3c!--",e,"--\x3e")}
1,pi:function(e,n){n?a.push("<?",e," ",o(n),"?>"):a.push("<?",e,"?>"),t&&a.push("\n")},doctype:function(e){a.push("<!DOCTYPE",e,">",t?"\n":"")},reset:function(){a.length=0},getContent:function(){return a.join("").replace(/\n$/,"")}}}function lu(e,t){void 0===t&&(t=Eo());var n=cu(e);return(e=e||{}).validate=!("validate"in e)||e.validate,{serialize:function(r){var o,i;i=e.validate,o={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,s,u,c,l,f,d,h,p,m=o[e.type];if(m)m(e);else{if(r=e.name,s=e.shortEnded,u=e.attributes,i&&u&&u.length>1&&((f=[]).map={},p=t.getElementRule(e.name))){for(d=0,h=p.attributesOrder.length;d<h;d++)(c=p.attributesOrder[d])in u.map&&(f.map[c]=l=u.map[c],f.push({name:c,value:l}));for(d=0,h=u.length;d<h;d++)(c=u[d].name)in f.map||(f.map[c]=l=u.map[c],f.push({name:c,value:l}));u=f}if(n.start(e.name,u,s),!s){if(e=e.firstChild)do{a(e)}while(e=e.next);n.end(r)}}};return 1!==r.type||e.inner?o[11](r):a(r),n.getContent()}}}var fu=function(e){return function(e){return e.collapsed?e:function(e){var t=Ui.fromRangeStart(e),n=Ui.fromRangeEnd(e),r=e.commonAncestorContainer;return ia.fromPosition(!1,r,n).map(function(o){return!Ga(t,n,r)&&Ga(t,o,r)?function(e,t,n,r){var o=document.createRange();return o.setStart(e,t),o.setEnd(n,r),o}(t.container(),t.offset(),o.container(),o.offset()):e}).getOr(e)}(e)}(e)},du=Zr.matchNodeNames("td th"),hu={insertAtCaret:function(e,t){var n=function(e){var t;return"string"!=typeof e?(t=kt.extend({paste:e.paste,data:{paste:e.paste}},e),{content:e.content,details:t}):{content:e,details:{}}}(t);!function(e,t,n){var r,o,i,a,s,u,c,l,f,d,h,p,m=e.schema.getTextInlineElements(),g=e.selection,v=e.dom;if(/^ | $/.test(t)&&(t=function(e){var t,n,r;r=(t=g.getRng()).startOffset;var o=function(e){return n[e]&&3===n[e].nodeType};return 3===(n=t.startContainer).nodeType&&(r>0?e=e.replace(/^ /," "):o("previousSibling")||(e=e.replace(/^ /," ")),r<n.length?e=e.replace(/ (<br>|)$/," "):o("nextSibling")||(e=e.replace(/( | )(<br>|)$/," "))),e}(t)),r=e.parser,p=n.merge,o=lu({validate:e.settings.validate},e.schema),h='<span id="mce_marker" data-mce-type="bookmark">​</span>',(u=e.fire("BeforeSetContent",u={content:t,format:"html",selection:!0,paste:n.paste})).isDefaultPrevented())e.fire("SetContent",{content:u.content,format:"html",selection:!0,paste:n.paste});else{-1===(t=u.content).indexOf("{$caret}")&&(t+="{$caret}"),t=t.replace(/\{\$caret\}/,h);var y=(l=g.getRng()).startContainer||(l.parentElement?l.parentElement():null),b=e.getBody();y===b&&g.isCollapsed()&&v.isBlock(b.firstChild)&&function(t){return t&&!e.schema.getShortEndedElements()[t.nodeName]}(b.firstChild)&&v.isEmpty(b.firstChild)&&((l=v.createRng()).setStart(b.firstChild,0),l.setEnd(b.firstChild,0),g.setRng(l)),g.isCollapsed()||(e.selection.setRng(fu(e.selection.getRng())),e.getDoc().execCommand("Delete",!1,null),function(){var e,n,r;r=(e=g.getRng()).startOffset,3===(n=e.startContainer).nodeType&&e.collapsed&&("\xa0"===n.data[r]?(n.deleteData(r,1),/[\u00a0| ]$/.test(t)||(t+=" ")):"\xa0"===n.data[r-1]&&(n.deleteData(r-1,1),/[\u00a0| ]$/.test(t)||(t=" "+t)))}());var x,C={context:(i=g.getNode()).nodeName.toLowerCase(),data:n.data,insert:!0};if(s=r.parse(t,C),!0===n.paste&&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),function(e,t){var n=e.getNonEmptyElements();return t&&(t.isEmpty(n)||function(e,t){return e.getBlockElements()[t.name]&&function(e){return e.firstChild&&e.firstChild===e.lastChild}(t)&&function(e){return"br"===e.name||"\xa0"===e.value}(t.firstChild)}(e,t))}(e,r)&&(r=r.prev),!(!n||n!==r||"ul"!==n.name&&"ol"!==n.name)}(e.schema,s)&&function(e,t){return!!Ss(e,i)}(v))return l=Es(o,v,e.selection.getRng(!0),s),e.selection.setRng(l),void e.fire("SetContent",u);if(function(e){for(var t=e;t=t.walk();)1===t.type&&t.attr("data-mce-fragment","1")}(s),"mce_marker"===(f=s.lastChild).attr("id"))for(c=f,f=f.prev;f;f=f.walk(!0))if(3===f.type||!v.isBlock(f.name)){e.schema.isValidChild(f.parent.name,"span")&&f.parent.insert(c,f,"br"===f.name);break}if(e._selectionOverrides.showBlockCaretContainer(i),C.invalid){for(g.setContent(h),i=g.getNode(),a=e.getBody(),9===i.nodeType?i=f=a:f=i;f!==a;)i=f,f=f.parentNode;t=i===a?a.innerHTML:v.getOuterHTML(i),t=o.serialize(r.parse(t.replace(/<span (id="mce_marker"|id=mce_marker).+?<\/span>/i,function(){return o.serialize(s)}))),i===a?v.setHTML(a,t):v.setOuterHTML(i,t)}else t=o.serialize(s),function(e,t,n){if("all"===n.getAttribute("data-mce-bogus"))n.parentNode.insertBefore(e.dom.createFragment(t),n);else{var r=n.firstChild;!r||r===n.lastChild&&"BR"===r.nodeName?e.dom.setHTML(n,t):e.selection.setContent(t)}}(e,t,i);!function(){if(p){var t=e.getBody(),n=new Ks(v);kt.each(v.select("*[data-mce-fragment]"),function(e){for(var r=e.parentNode;r&&r!==t;r=r.parentNode)m[e.nodeName.toLowerCase()]&&n.compare(r,e)&&v.remove(e,!0)})}}(),function(t){var n,r,o;
1if(t){if(g.scrollIntoView(t),n=function(t){for(var n=e.getBody();t&&t!==n;t=t.parentNode)if("false"===e.dom.getContentEditable(t))return t;return null}(t))return v.remove(t),void g.select(n);l=v.createRng(),(f=t.previousSibling)&&3===f.nodeType?(l.setStart(f,f.nodeValue.length),ae.ie||(d=t.nextSibling)&&3===d.nodeType&&(f.appendData(d.data),d.parentNode.removeChild(d))):(l.setStartBefore(t),l.setEndBefore(t)),r=v.getParent(t,v.isBlock),v.remove(t),r&&v.isEmpty(r)&&(e.$(r).empty(),l.setStart(r,0),l.setEnd(r,0),du(r)||r.getAttribute("data-mce-fragment")||!(o=function(t){var n=Ui.fromRangeStart(t);if(n=Cs(e.getBody()).next(n))return n.toRange()}(l))?v.add(r,v.create("br",{"data-mce-bogus":"1"})):(l=o,v.remove(r))),g.setRng(l)}}(v.get("mce_marker")),x=e.getBody(),kt.each(x.getElementsByTagName("*"),function(e){e.removeAttribute("data-mce-fragment")}),function(e,t){w.from(e.getParent(t,"td,th")).map(_n).each(su)}(e.dom,e.selection.getStart()),e.fire("SetContent",u),e.addVisual()}}(e,n.content,n.details)}};function pu(e,t,n,r,o){return e(n,r)?w.some(n):Hn.isFunction(o)&&o(n)?w.none():t(n,r,o)}var mu=function(e,t,n){for(var r=e.dom(),o=Hn.isFunction(n)?n:p.constant(!1);r.parentNode;){var i=_n(r=r.parentNode);if(t(i))return w.some(i);if(o(i))break}return w.none()},gu=mu,vu=er("sections","settings"),yu=Tn.detect().deviceType.isTouch(),bu=["lists","autolink","autosave"],wu={theme:"mobile"},xu=function(e){var t=Hn.isArray(e)?e.join(" "):e,n=P.map(Hn.isString(t)?t.split(" "):[],yn);return P.filter(n,function(e){return e.length>0})},Cu=function(e,t){var n=qn.bifilter(t,function(t,n){return P.contains(e,n)});return vu(n.t,n.f)},Su=function(e,t){return e.sections().hasOwnProperty(t)},Tu=function(e,t,n){return w.from(t.settings[n]).filter(e)},Eu=p.curry(Tu,Hn.isString),ku=/[\u0591-\u07FF\uFB1D-\uFDFF\uFE70-\uFEFC]/,Nu=function(e,t){var n=t.container(),r=t.offset();return e?Yo(n)?Zr.isText(n.nextSibling)?Ui(n.nextSibling,0):Ui.after(n):Jo(t)?Ui(n,r+1):t:Yo(n)?Zr.isText(n.previousSibling)?Ui(n.previousSibling,n.previousSibling.data.length):Ui.before(n):Qo(t)?Ui(n,r-1):t},Ru={isInlineTarget:function(e,t){var n=Eu(e,"inline_boundaries_selector").getOr("a[href],code");return nr.is(_n(t),n)},findRootInline:function(e,t,n){var r=function(e,t,n){return P.filter(Lo.DOM.getParents(n.container(),"*",t),e)}(e,t,n);return w.from(r[r.length-1])},isRtl:function(e){return"rtl"===Lo.DOM.getStyle(e,"direction",!0)||ku.test(e.textContent)},isAtZwsp:function(e){return Jo(e)||Qo(e)},normalizePosition:Nu,normalizeForwards:p.curry(Nu,!0),normalizeBackwards:p.curry(Nu,!1),hasSameParentBlock:function(e,t,n){var r=Ka(t,e),o=Ka(n,e);return r&&r===o}},_u=function(e,t){return ir.contains(e,t)?(n=t,r=function(e){return Mr(e)||Fr(e)},o=function(e){return function(t){return ir.eq(e,_n(t.dom().parentNode))}}(e),pu(function(e){return r(e)},mu,n,r,o)):w.none();var n,r,o},Au=function(e){e.dom.isEmpty(e.getBody())&&(e.setContent(""),function(e){var t=e.getBody(),n=t.firstChild&&e.dom.isBlock(t.firstChild)?t.firstChild:t;e.selection.setCursorLocation(n,0)}(e))},Du=function(e,t,n){return gu(e,function(e){return nr.is(e,t)},n)},Ou=Du,Pu=function(e,t){return nr.one(t,e)},Bu=function(e,t){return li(t)&&!1===function(e,t){return Zr.isText(t)&&/^[ \t\r\n]*$/.test(t.data)&&!1===function(e,t){var n,r,o=_n(e);return n=_n(t),r=p.curry(ir.eq,o),Ou(n,"pre,code",r).isSome()}(e,t)}(e,t)||function(e){return Zr.isElement(e)&&"A"===e.nodeName&&e.hasAttribute("name")}(t)||Iu(t)},Iu=Zr.hasAttribute("data-mce-bookmark"),Lu=Zr.hasAttribute("data-mce-bogus"),Mu=Zr.hasAttributeValue("data-mce-bogus","all"),Hu=function(e){return function(e){var t,n,r=0;if(Bu(e,e))return!1;if(!(n=e.firstChild))return!0;t=new Rr(n,e);do{if(Mu(n))n=t.next(!0);else if(Lu(n))n=t.next();else if(Zr.isBr(n))r++,n=t.next();else{if(Bu(e,n))return!1;n=t.next()}}while(n);return r<=1}(e.dom())},Fu=er("block","position"),Wu=er("from","to"),ju=function(e,t){var n=_n(e),r=_n(t.container());return _u(n,r).map(function(e){return Fu(e,t)})},$u=function(e,t){return function(e,t,n){return ir.contains(t,e)?dr(e,function(e){return n(e)||ir.eq(e,t)}).slice(0,-1):[]}(e,t,p.constant(!1))},zu=$u,qu=function(e,t){return[e].concat($u(e,t))},Uu=function(e,t){ia.positionIn(e,t.dom()).each(function(e){var t=e.getNode();Zr.isBr(t)&&ou(_n(t))})},Vu=function(e,t){var n=qu(t,e);return P.find(n.reverse(),Hu).each(ou)},Xu=function(e,t,n){if(Hu(n))return ou(n),Hu(t)&&au(t),ia.firstPositionIn(t.dom());
1Uu(!0,t),Uu(!1,n);var r,o=(r=function(e){var n=mr(t);return P.findIndex(n,Br).fold(function(){return n},function(e){return n.slice(0,e)})}(),P.each(r,function(e){ou(e)}),r);return function(e,t){return ir.contains(t,e)?fr(e).bind(function(n){return ir.eq(n,t)?w.some(e):function(t,n){var r=dr(e,function(e){return ir.eq(e,t)});return w.from(r[r.length-2])}(t)}):w.none()}(t,n).fold(function(){Vu(e,t);var r=ia.lastPositionIn(n.dom());return P.each(o,function(e){eu(n,e)}),r},function(r){var i=ia.prevPosition(n.dom(),Ui.before(r.dom()));return P.each(o,function(e){Qs(r,e)}),Vu(e,t),i})},Yu=function(e,t,n,r){return t?Xu(e,r,n):Xu(e,n,r)},Ku=function(e,t){var n,r=_n(e.getBody());return(n=function(e,t,n){return n.collapsed?function(e,t,n){var r=ju(e,Ui.fromRangeStart(n)),o=r.bind(function(n){return ia.fromPosition(t,e,n.position()).bind(function(n){return ju(e,n).map(function(n){return function(e,t,n){return Zr.isBr(n.position().getNode())&&!1===Hu(n.block())?ia.positionIn(!1,n.block().dom()).bind(function(r){return r.isEqual(n.position())?ia.fromPosition(t,e,r).bind(function(t){return ju(e,t)}):w.some(n)}).getOr(n):n}(e,t,n)})})});return da([r,o],Wu).filter(function(e){return function(e){return!1===ir.eq(e.from().block(),e.to().block())}(e)&&function(e){return fr(e.from().block()).bind(function(t){return fr(e.to().block()).filter(function(e){return ir.eq(t,e)})}).isSome()}(e)&&function(e){return!1===Zr.isContentEditableFalse(e.from().block())&&!1===Zr.isContentEditableFalse(e.to().block())}(e)})}(e,t,n):w.none()}(r.dom(),t,e.selection.getRng()).bind(function(e){return Yu(r,t,e.from().block(),e.to().block())})).each(function(t){e.selection.setRng(t.toRange())}),n.isSome()},Gu=function(e,t){var n=_n(t),r=p.curry(ir.eq,e);return gu(n,$r,r).isSome()},Ju=function(e,t){return!e.selection.isCollapsed()&&function(e){var t=_n(e.getBody());return n=t,r=e.selection.getRng(),o=ia.prevPosition(n.dom(),Ui.fromRangeStart(r)).isNone(),i=ia.nextPosition(n.dom(),Ui.fromRangeEnd(r)).isNone(),!function(e,t){return Gu(e,t.startContainer)||Gu(e,t.endContainer)}(n,r)&&o&&i?function(e){return e.setContent(""),e.selection.setCursorLocation(),!0}(e):function(e,t){var n=t.getRng();return da([_u(e,_n(n.startContainer)),_u(e,_n(n.endContainer))],function(r,o){return!1===ir.eq(r,o)&&(n.deleteContents(),Yu(e,!0,r,o).each(function(e){t.setRng(e.toRange())}),!0)}).getOr(!1)}(t,e.selection);var n,r,o,i}(e)},Qu=function(e){if(!Hn.isArray(e))throw new Error("cases must be an array");if(0===e.length)throw new Error("there must be at least one case");var t=[],n={};return P.each(e,function(r,o){var i=qn.keys(r);if(1!==i.length)throw new Error("one and only one name per case");var a=i[0],s=r[a];if(void 0!==n[a])throw new Error("duplicate key detected:"+a);if("cata"===a)throw new Error("cannot have a case named cata (sorry)");if(!Hn.isArray(s))throw new Error("case arguments must be an array");t.push(a),n[a]=function(){var n=arguments.length;if(n!==s.length)throw new Error("Wrong number of arguments to case "+a+". Expected "+s.length+" ("+s+"), got "+n);for(var r=new Array(n),i=0;i<r.length;i++)r[i]=arguments[i];return{fold:function(){if(arguments.length!==e.length)throw new Error("Wrong number of arguments to fold. Expected "+e.length+", got "+arguments.length);return arguments[o].apply(null,r)},match:function(e){var n=qn.keys(e);if(t.length!==n.length)throw new Error("Wrong number of arguments to match. Expected: "+t.join(",")+"\nActual: "+n.join(","));if(!P.forall(t,function(e){return P.contains(n,e)}))throw new Error("Not all branches were specified when using match. Specified: "+n.join(", ")+"\nRequired: "+t.join(", "));return e[a].apply(null,r)},log:function(e){console.log(e,{constructors:t,constructor:a,params:r})}}}}),n},Zu=Qu([{remove:["element"]},{moveToElement:["element"]},{moveToPosition:["position"]}]),ec=function(e,t,n,r){var o=r.getNode(!1===t);return _u(_n(e),_n(n.getNode())).map(function(e){return Hu(e)?Zu.remove(e.dom()):Zu.moveToElement(o)}).orThunk(function(){return w.some(Zu.moveToElement(o))})},tc=function(e,t,n){return ia.fromPosition(t,e,n).bind(function(r){return o=r.getNode(),$r(_n(o))||Fr(_n(o))?w.none():function(e,t,n,r){var o=function(t){return Ir(_n(t))&&!Ga(n,r,e)};return as(!t,n).fold(function(){return as(t,r).fold(p.constant(!1),o)},o)}(e,t,n,r)?w.none():t&&Zr.isContentEditableFalse(r.getNode())?ec(e,t,n,r):!1===t&&Zr.isContentEditableFalse(r.getNode(!0))?ec(e,t,n,r):t&&cs(n)?w.some(Zu.moveToPosition(r)):!1===t&&us(n)?w.some(Zu.moveToPosition(r)):w.none();var o})},nc=function(e,t){return function(e,t){var n=e.container(),r=e.offset();return!1===Ui.isTextPosition(e)&&n===t.parentNode&&r>Ui.before(t).offset()}(t,e)?Ui(t.container(),t.offset()-1):t},rc=function(e){return li(e.previousSibling)?w.some(Zr.isText(t=e.previousSibling)?Ui(t,t.data.length):Ui.after(t)):e.previousSibling?ia.lastPositionIn(e.previousSibling):w.none();var t},oc=function(e){return li(e.nextSibling)?w.some(Zr.isText(t=e.nextSibling)?Ui(t,0):Ui.before(t)):e.nextSibling?ia.firstPositionIn(e.nextSibling):w.none();var t},ic=function(e,t,n){n.fold(function(){e.focus()}
1,function(n){e.selection.setRng(n.toRange(),t)})},ac=function(e,t){return t&&e.schema.getBlockElements().hasOwnProperty(Ln.name(t))},sc=function(e){if(Hu(e)){var t=kn('<br data-mce-bogus="1">');return ru(e),eu(e,t),w.some(Ui.before(t.dom()))}return w.none()},uc=function(e,t,n){var r,o=function(e,t,n){return function(e,t,n){return e?function(e,t){return oc(t).orThunk(function(){return rc(t)}).orThunk(function(){return function(e,t){return ia.nextPosition(e,Ui.after(t)).fold(function(){return ia.prevPosition(e,Ui.before(t))},w.some)}(e,t)})}(t,n):function(e,t){return rc(t).orThunk(function(){return oc(t)}).orThunk(function(){return function(e,t){var n=Ui.before(t.previousSibling?t.previousSibling:t.parentNode);return ia.prevPosition(e,n).fold(function(){return ia.nextPosition(e,Ui.after(t))},w.some)}(e,t)})}(t,n)}(e,t,n).map(p.curry(nc,n))}(t,e.getBody(),n.dom()),i=gu(n,p.curry(ac,e),(r=e.getBody(),function(e){return e.dom()===r})),a=function(e,t){return da([hr(e),pr(e),t],function(t,n,r){var o,i=t.dom(),a=n.dom();return Zr.isText(i)&&Zr.isText(a)?(o=i.data.length,i.appendData(a.data),ou(n),ou(e),r.container()===a?Ui(i,o):r):(ou(e),r)}).orThunk(function(){return ou(e),t})}(n,o);e.dom.isEmpty(e.getBody())?(e.setContent(""),e.selection.setCursorLocation()):i.bind(sc).fold(function(){ic(e,t,a)},function(n){ic(e,t,w.some(n))})},cc=function(e,t){return e.selection.isCollapsed()?function(e,t){return function(e,t,n){var r=rs(t?1:-1,e,n),o=Ui.fromRangeStart(r);return!1===t&&cs(o)?w.some(Zu.remove(o.getNode(!0))):t&&us(o)?w.some(Zu.remove(o.getNode())):function(e,t,n){return function(e,t){var n=t.getNode(!1===e),r=e?"after":"before";return Zr.isElement(n)&&n.getAttribute("data-mce-caret")===r}(t,n)?function(e,t){return e&&Zr.isContentEditableFalse(t.nextSibling)?w.some(Zu.moveToElement(t.nextSibling)):!1===e&&Zr.isContentEditableFalse(t.previousSibling)?w.some(Zu.moveToElement(t.previousSibling)):w.none()}(t,n.getNode(!1===t)).fold(function(){return tc(e,t,n)},w.some):tc(e,t,n).bind(function(t){return function(e,t,n){return n.fold(function(e){return w.some(Zu.remove(e))},function(e){return w.some(Zu.moveToElement(e))},function(n){return Ga(t,n,e)?w.none():w.some(Zu.moveToPosition(n))})}(e,n,t)})}(e,t,o)}(e.getBody(),t,e.selection.getRng()).map(function(n){return n.fold(function(e,t){return function(n){return e._selectionOverrides.hideFakeCaret(),uc(e,t,_n(n)),!0}}(e,t),function(e,t){return function(n){var r=t?Ui.before(n):Ui.after(n);return e.selection.setRng(r.toRange()),!0}}(e,t),function(e){return function(t){return e.selection.setRng(t.toRange()),!0}}(e))}).getOr(!1)}(e,t):function(e,t){var n,r=e.selection.getNode();return!!Zr.isContentEditableFalse(r)&&(n=_n(e.getBody()),P.each(Ea(n,".mce-offscreen-selection"),ou),uc(e,t,_n(e.selection.getNode())),Au(e),!0)}(e,t)},lc=function(e){var t,n=function(e,t){for(;t&&t!==e;){if(Zr.isContentEditableTrue(t)||Zr.isContentEditableFalse(t))return t;t=t.parentNode}return null}(e.getBody(),e.selection.getNode());return Zr.isContentEditableTrue(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(Ui.before(t).toRange())),!0},fc=Zr.isText,dc=function(e){return fc(e)&&"\ufeff"===e.data[0]},hc=function(e){return fc(e)&&"\ufeff"===e.data[e.data.length-1]},pc=function(e){return e.ownerDocument.createTextNode("\ufeff")},mc=function(e,t){return e?function(e){if(fc(e.previousSibling))return hc(e.previousSibling)?e.previousSibling:(e.previousSibling.appendData("\ufeff"),e.previousSibling);if(fc(e))return dc(e)?e:(e.insertData(0,"\ufeff"),e);var t=pc(e);return e.parentNode.insertBefore(t,e),t}(t):function(e){if(fc(e.nextSibling))return dc(e.nextSibling)?e.nextSibling:(e.nextSibling.insertData(0,"\ufeff"),e.nextSibling);if(fc(e))return hc(e)?e:(e.appendData("\ufeff"),e);var t=pc(e);return e.nextSibling?e.parentNode.insertBefore(t,e.nextSibling):e.parentNode.appendChild(t),t}(t)},gc=p.curry(mc,!0),vc=p.curry(mc,!1),yc=function(e,t){return Zr.isText(e.container())?mc(t,e.container()):mc(t,e.getNode())},bc=function(e,t){var n=t.get();return n&&e.container()===n&&Yo(n)},wc=function(e,t){return t.fold(function(t){Zi.remove(e.get());var n=gc(t);return e.set(n),w.some(Ui(n,n.length-1))},function(t){return ia.firstPositionIn(t).map(function(t){if(bc(t,e))return Ui(e.get(),1);Zi.remove(e.get());var n=yc(t,!0);return e.set(n),Ui(n,1)})},function(t){return ia.lastPositionIn(t).map(function(t){if(bc(t,e))return Ui(e.get(),e.get().length-1);Zi.remove(e.get());var n=yc(t,!1);return e.set(n),Ui(n,n.length-1)})},function(t){Zi.remove(e.get());var n=vc(t);return e.set(n),w.some(Ui(n,1))})}
1,xc=function(e){return e&&3===e.nodeType&&/^([\t \r\n]+|)$/.test(e.nodeValue)},Cc=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},Sc=function(e,t,n){var r,o,i,a=n.startContainer,s=n.startOffset;if((n.startContainer!==n.endContainer||!function(e){return e&&/^(IMG)$/.test(e.nodeName)}(n.startContainer.childNodes[n.startOffset]))&&(3===a.nodeType&&s>=a.nodeValue.length&&(s=e.nodeIndex(a),a=a.parentNode),1===a.nodeType))for(s<(i=a.childNodes).length?r=new Rr(a=i[s],e.getParent(a,e.isBlock)):(r=new Rr(a=i[i.length-1],e.getParent(a,e.isBlock))).next(!0),o=r.current();o;o=r.next())if(3===o.nodeType&&!xc(o))return n.setStart(o,0),void t.setRng(n)},Tc=function(e,t,n){if(e)for(t=t?"nextSibling":"previousSibling",e=n?e:e[t];e;e=e[t])if(1===e.nodeType||!xc(e))return e},Ec=function(e,t){return t.nodeType&&(t=t.nodeName),!!e.schema.getTextBlockElements()[t.toLowerCase()]},kc=function(e,t,n){return e.schema.isValidChild(t,n)},Nc=xc,Rc=function(e,t){return"string"!=typeof e?e=e(t):t&&(e=e.replace(/%(\w+)/g,function(e,n){return t[n]||e})),e},_c=function(e,t){return e=e||"",t=t||"",e=""+(e.nodeName||e),t=""+(t.nodeName||t),e.toLowerCase()===t.toLowerCase()},Ac=Cc,Dc=function(e,t,n){return Cc(e,e.getStyle(t,n),n)},Oc=function(e,t){var n;return e.getParent(t,function(t){return(n=e.getStyle(t,"text-decoration"))&&"none"!==n}),n},Pc=function(e,t,n){return e.getParents(t,n,e.getRoot())},Bc=Xs.isBookmarkNode,Ic=Pc,Lc=Nc,Mc=Ec,Hc=function(e,t){for("undefined"==typeof t&&(t=3===e.nodeType?e.length:e.childNodes.length);e&&e.hasChildNodes();)(e=e.childNodes[t])&&(t=3===e.nodeType?e.length:e.childNodes.length);return{node:e,offset:t}},Fc=function(e,t){for(var n=t;n;){if(1===n.nodeType&&e.getContentEditable(n))return"false"===e.getContentEditable(n)?n:t;n=n.parentNode}return t},Wc=function(e,t,n,r){var o,i,a=n.nodeValue;return"undefined"==typeof r&&(r=e?a.length:0),e?-1===(o=(o=a.lastIndexOf(" ",r))>(i=a.lastIndexOf("\xa0",r))?o:i)||t||o++:(o=a.indexOf(" ",r),i=a.indexOf("\xa0",r),o=-1!==o&&(-1===i||o<i)?o:i),o},jc=function(e,t,n,r,o,i){var a,s,u,c;if(3===n.nodeType){if(-1!==(u=Wc(o,i,n,r)))return{container:n,offset:u};c=n}for(a=new Rr(n,e.getParent(n,e.isBlock)||t);s=a[o?"prev":"next"]();)if(3===s.nodeType){if(c=s,-1!==(u=Wc(o,i,s)))return{container:s,offset:u}}else if(e.isBlock(s))break;if(c)return{container:c,offset:r=o?0:c.length}},$c=function(e,t,n,r,o){var i,a,s,u;for(3===r.nodeType&&0===r.nodeValue.length&&r[o]&&(r=r[o]),i=Ic(e,r),a=0;a<i.length;a++)for(s=0;s<t.length;s++)if(!("collapsed"in(u=t[s])&&u.collapsed!==n.collapsed)&&e.is(i[a],u.selector))return i[a];return r},zc=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 s=i.getParent(n,"LI,TD,TH");o=i.getParent(3===n.nodeType?n.parentNode:n,function(t){return t!==a&&Mc(e,t)},s)}if(o&&t[0].wrapper&&(o=Ic(i,o,"ul,ol").reverse()[0]||o),!o)for(o=n;o[r]&&!i.isBlock(o[r])&&!_c(o=o[r],"br"););return o||n},qc=function(e,t,n,r,o,i,a){var s,u,c,l,f,d;if(s=u=a?n:o,l=a?"previousSibling":"nextSibling",f=e.getRoot(),3===s.nodeType&&!Lc(s)&&(a?r>0:i<s.nodeValue.length))return s;for(;;){if(!t[0].block_expand&&e.isBlock(u))return u;for(c=u[l];c;c=c[l])if(!Bc(c)&&!Lc(c)&&("BR"!==(d=c).nodeName||!d.getAttribute("data-mce-bogus")||d.nextSibling))return u;if(u===f||u.parentNode===f){s=u;break}u=u.parentNode}return s},Uc=function(e,t,n,r){var o,i=t.startContainer,a=t.startOffset,s=t.endContainer,u=t.endOffset,c=e.dom;return 1===i.nodeType&&i.hasChildNodes()&&3===(i=bi(i,a)).nodeType&&(a=0),1===s.nodeType&&s.hasChildNodes()&&3===(s=bi(s,t.collapsed?u:u-1)).nodeType&&(u=s.nodeValue.length),i=Fc(c,i),s=Fc(c,s),(Bc(i.parentNode)||Bc(i))&&3===(i=(i=Bc(i)?i:i.parentNode).nextSibling||i).nodeType&&(a=0),(Bc(s.parentNode)||Bc(s))&&3===(s=(s=Bc(s)?s:s.parentNode).previousSibling||s).nodeType&&(u=s.length),n[0].inline&&(t.collapsed&&((o=jc(c,e.getBody(),i,a,!0,r))&&(i=o.container,a=o.offset),(o=jc(c,e.getBody(),s,u,!1,r))&&(s=o.container,u=o.offset)),s=r?s:function(e,t){var n=Hc(e,t);if(n.node){for(;n.node&&0===n.offset&&n.node.previousSibling;)n=Hc(n.node.previousSibling);n.node&&n.offset>0&&3===n.node.nodeType&&" "===n.node.nodeValue.charAt(n.offset-1)&&n.offset>1&&(e=n.node).splitText(n.offset-1)}return e}(s,u)),(n[0].inline||n[0].block_expand)&&(n[0].inline&&3===i.nodeType&&0!==a||(i=qc(c,n,i,a,s,u,!0)),n[0].inline&&3===s.nodeType&&u!==s.nodeValue.length||(s=qc(c,n,i,a,s,u,!1))),n[0].selector&&!1!==n[0].expand&&!n[0].inline&&(i=$c(c,n,t,i,"previousSibling"),s=$c(c,n,t,s,"nextSibling")),(n[0].block||n[0].selector)&&(i=zc(e,n,i,"previousSibling"),s=zc(e,n,s,"nextSibling"),n[0].block&&(c.isBlock(i)||(i=qc(c,n,i,a,s,u,!0)),c.isBlock(s)||(s=qc(c,n,i,a,s,u,!1)))),1===i.nodeType&&(a=c.nodeIndex(i),i=i.parentNode),1===s.nodeType&&(u=c.nodeIndex(s)+1,s=s.parentNode),{startContainer:i,startOffset:a,endContainer:s,endOffset:u}},Vc=_c,Xc=function(e,t,n){var r=e.formatter.get(n);if(r)for(var o=0;o<r.length;o++)if(!1===r[o].inherit&&e.dom.is(t,r[o].selector))return!0;return!1},Yc=function(e,t,n,r){var o=e.dom.getRoot();return t!==o&&(t=e.dom.getParent(t,function(t){return!!Xc(e,t,n)||t.parentNode===o||
vendor: 1,469 bytes, line 1
1!!Jc(e,t,n,r,!0)}),Jc(e,t,n,r))},Kc=function(e,t,n){return!!Vc(t,n.inline)||!!Vc(t,n.block)||(n.selector?1===t.nodeType&&e.is(t,n.selector):void 0)},Gc=function(e,t,n,r,o,i){var a,s,u,c=n[r];if(n.onmatch)return n.onmatch(t,n,r);if(c)if("undefined"==typeof c.length){for(a in c)if(c.hasOwnProperty(a)){if(s="attributes"===r?e.getAttrib(t,a):Dc(e,t,a),o&&!s&&!n.exact)return;if((!o||n.exact)&&!Vc(s,Ac(e,Rc(c[a],i),a)))return}}else for(u=0;u<c.length;u++)if("attributes"===r?e.getAttrib(t,c[u]):Dc(e,t,c[u]))return n;return n},Jc=function(e,t,n,r,o){var i,a,s,u,c=e.formatter.get(n),l=e.dom;if(c&&t)for(a=0;a<c.length;a++)if(Kc(e.dom,t,i=c[a])&&Gc(l,t,i,"attributes",o,r)&&Gc(l,t,i,"styles",o,r)){if(u=i.classes)for(s=0;s<u.length;s++)if(!e.dom.hasClass(t,u[s]))return;return i}},Qc={matchNode:Jc,matchName:Kc,match:function(e,t,n,r){var o;return r?Yc(e,r,t,n):(r=e.selection.getNode(),!!Yc(e,r,t,n)||!((o=e.selection.getStart())===r||!Yc(e,o,t,n)))},matchAll:function(e,t,n){var r,o=[],i={};return r=e.selection.getStart(),e.dom.getParent(r,function(r){var a,s;for(a=0;a<t.length;a++)!i[s=t[a]]&&Jc(e,r,s,n)&&(i[s]=!0,o.push(s))},e.dom.getRoot()),o},canApply:function(e,t){var n,r,o,i,a,s=e.formatter.get(t),u=e.dom;if(s)for(n=e.selection.getStart(),r=Pc(u,n),i=s.length-1;i>=0;i--){if(!(a=s[i].selector)||s[i].defaultBlock)return!0;for(o=r.length-1;o>=0;o--)if(u.is(r[o],a))return!0}return!1},matchesUnInheritedFormatSelector:Xc},Zc=function(e,t){return e.splitText(t)}
1,el={split:function(e){var t=e.startContainer,n=e.startOffset,r=e.endContainer,o=e.endOffset;return t===r&&Zr.isText(t)?n>0&&n<t.nodeValue.length&&(t=(r=Zc(t,n)).previousSibling,o>n?(t=r=Zc(r,o-=n).previousSibling,o=r.nodeValue.length,n=0):o=0):(Zr.isText(t)&&n>0&&n<t.nodeValue.length&&(t=Zc(t,n),n=0),Zr.isText(r)&&o>0&&o<r.nodeValue.length&&(o=(r=Zc(r,o).previousSibling).nodeValue.length)),{startContainer:t,startOffset:n,endContainer:r,endOffset:o}}},tl=function(e){return 1===e.nodeType&&"_mce_caret"===e.id},nl=function(e){var t;if(e)for(e=(t=new Rr(e,e)).current();e;e=t.next())if(3===e.nodeType)return e;return null},rl=function(e){var t=Nn("span");return Xn(t,{id:"_mce_caret","data-mce-bogus":"1","data-mce-type":"format-caret"}),e&&eu(t,Rn("\ufeff")),t},ol=function(e,t){for(;t&&t!==e;){if("_mce_caret"===t.id)return t;t=t.parentNode}return null},il=function(e,t,n,r){var o,i,a;o=t.getRng(!0),i=e.getParent(n,e.isBlock),function(e){return function(e){for(var t=[];e;){if(3===e.nodeType&&"\ufeff"!==e.nodeValue||e.childNodes.length>1)return[];1===e.nodeType&&t.push(e),e=e.firstChild}return t}(e).length>0}(n)?(!1!==r&&(o.setStartBefore(n),o.setEndBefore(n)),e.remove(n)):(a=function(e){var t=nl(n);return t&&"\ufeff"===t.nodeValue.charAt(0)&&t.deleteData(0,1),t}(),o.startContainer===a&&o.startOffset>0&&o.setStart(a,o.startOffset-1),o.endContainer===a&&o.endOffset>0&&o.setEnd(a,o.endOffset-1),e.remove(n,!0)),i&&e.isEmpty(i)&&au(_n(i)),t.setRng(o)},al=function(e,t,n,r,o){if(r)il(t,n,r,o);else if(!(r=ol(e,n.getStart())))for(;r=t.get("_mce_caret");)il(t,n,r,!1)},sl=function(e,t){return e.appendChild(t),t},ul=function(e,t){var n=P.foldr(e,function(e,t){return sl(e,t.cloneNode(!1))},t);return sl(n,n.ownerDocument.createTextNode("\ufeff"))},cl={setup:function(e){var t=e.dom,n=e.selection,r=e.getBody();e.on("mouseup keydown",function(e){!function(e,t,n,r){al(e,t,n,null,!1),8===r&&n.isCollapsed()&&"\ufeff"===n.getStart().innerHTML&&al(e,t,n,ol(e,n.getStart())),37!==r&&39!==r||al(e,t,n,ol(e,n.getStart()))}(r,t,n,e.keyCode)})},applyCaretFormat:function(e,t,n){var r,o,i,a,s,u,c=e.selection;a=(r=c.getRng(!0)).startOffset,u=r.startContainer.nodeValue,(o=ol(e.getBody(),c.getStart()))&&(i=nl(o));var l,f,d=/[^\s\u00a0\u00ad\u200b\ufeff]/;u&&a>0&&a<u.length&&d.test(u.charAt(a))&&d.test(u.charAt(a-1))?(s=c.getBookmark(),r.collapse(!0),r=Uc(e,r,e.formatter.get(t)),r=el.split(r),e.formatter.apply(t,n,r),c.moveToBookmark(s)):(o&&"\ufeff"===i.nodeValue?e.formatter.apply(t,n,o):(l=e.getDoc(),f=rl(!0).dom(),i=(o=l.importNode(f,!0)).firstChild,r.insertNode(o),a=1,e.formatter.apply(t,n,o)),c.setCursorLocation(i,a))},removeCaretFormat:function(e,t,n,r){var o,i,a,s,u,c,l=e.dom,f=e.selection,d=[],h=f.getRng();for(s=o=h.startContainer,3===o.nodeType&&(h.startOffset!==o.nodeValue.length&&(a=!0),s=s.parentNode);s;){if(Qc.matchNode(e,s,t,n,r)){u=s;break}s.nextSibling&&(a=!0),d.push(s),s=s.parentNode}if(u)if(a){i=f.getBookmark(),h.collapse(!0);var p=Uc(e,h,e.formatter.get(t),!0);p=el.split(p),e.formatter.remove(t,n,p),f.moveToBookmark(i)}else{c=ol(e.getBody(),u);var m=rl(!1).dom(),g=ul(d,m);(function(e,t,n){var r,o,i,a=e.dom,s=a.getParent(n,Ti.curry(Ec,e));s&&a.isEmpty(s)?n.parentNode.replaceChild(t,n):(r=_n(n),o=Ea(r,"br"),i=P.filter(function(e){for(var t=[],n=e.dom();n;)t.push(_n(n)),n=n.lastChild;return t}(r).slice(-1),Lr),o.length===i.length&&P.each(i,ou),a.isEmpty(n)?n.parentNode.replaceChild(t,n):a.insertAfter(t,n))})(e,m,c||u),il(l,f,c,!1),f.setCursorLocation(g,1),l.isEmpty(u)&&l.remove(u)}},isCaretNode:tl,getParentCaretContainer:ol,replaceWithCaretFormat:function(e,t){var n=rl(!1),r=ul(t,n.dom());return Qs(_n(e),n),ou(_n(e)),Ui(r,0)},isFormatElement:function(e,t){return e.schema.getTextInlineElements().hasOwnProperty(Ln.name(t))&&!tl(t.dom())&&!Zr.isBogus(t.dom())}},ll=function(e,t){for(var n=0;n<e.length;n++){var r=e[n].apply(null,t);if(r.isSome())return r}return w.none()},fl=Qu([{before:["element"]},{start:["element"]},{end:["element"]},{after:["element"]}]),dl=function(e,t){return Ka(t,e)||e},hl=function(e,t,n){var r=Ru.normalizeForwards(n),o=dl(t,r.container());return Ru.findRootInline(e,o,r).fold(function(){return ia.nextPosition(o,r).bind(p.curry(Ru.findRootInline,e,o)).map(function(e){return fl.before(e)})},w.none)},pl=function(e,t){return null===cl.getParentCaretContainer(e,t)},ml=function(e,t,n){return Ru.findRootInline(e,t,n).filter(p.curry(
1pl,t))},gl=function(e,t,n){var r=Ru.normalizeBackwards(n);return ml(e,t,r).bind(function(e){return ia.prevPosition(e,r).isNone()?w.some(fl.start(e)):w.none()})},vl=function(e,t,n){var r=Ru.normalizeForwards(n);return ml(e,t,r).bind(function(e){return ia.nextPosition(e,r).isNone()?w.some(fl.end(e)):w.none()})},yl=function(e,t,n){var r=Ru.normalizeBackwards(n),o=dl(t,r.container());return Ru.findRootInline(e,o,r).fold(function(){return ia.prevPosition(o,r).bind(p.curry(Ru.findRootInline,e,o)).map(function(e){return fl.after(e)})},w.none)},bl=function(e){return!1===Ru.isRtl(xl(e))},wl=function(e,t,n){return ll([hl,gl,vl,yl],[e,t,n]).filter(bl)},xl=function(e){return e.fold(p.identity,p.identity,p.identity,p.identity)},Cl=function(e){return e.fold(p.constant("before"),p.constant("start"),p.constant("end"),p.constant("after"))},Sl=function(e){return e.fold(fl.before,fl.before,fl.after,fl.after)},Tl=function(e,t,n,r,o,i){return da([Ru.findRootInline(t,n,r),Ru.findRootInline(t,n,o)],function(t,r){return t!==r&&Ru.hasSameParentBlock(n,t,r)?fl.after(e?t:r):i}).getOr(i)},El=function(e,t){return e.fold(p.constant(!0),function(e){return r=t,!(Cl(n=e)===Cl(r)&&xl(n)===xl(r));var n,r})},kl=function(e,t){return e?t.fold(p.compose(w.some,fl.start),w.none,p.compose(w.some,fl.after),w.none):t.fold(w.none,p.compose(w.some,fl.before),w.none,p.compose(w.some,fl.end))},Nl=function(e,t,n,r){var o=Ru.normalizePosition(e,r),i=wl(t,n,o);return wl(t,n,o).bind(p.curry(kl,e)).orThunk(function(){return function(e,t,n,r,o){var i=Ru.normalizePosition(e,o);return ia.fromPosition(e,n,i).map(p.curry(Ru.normalizePosition,e)).fold(function(){return r.map(Sl)},function(o){return wl(t,n,o).map(p.curry(Tl,e,t,n,i,o)).filter(p.curry(El,r))}).filter(bl)}(e,t,n,i,r)})},Rl=wl,_l=Nl,Al=(p.curry(Nl,!1),p.curry(Nl,!0),Sl),Dl=function(e){return e.fold(fl.start,fl.start,fl.end,fl.end)},Ol=function(e){var t=e,n=function(){return t};return{get:n,set:function(e){t=e},clone:function(){return Ol(n())}}},Pl=function(e,t,n){var r=e?1:-1;return t.setRng(Ui(n.container(),n.offset()+r).toRange()),t.getSel().modify("move",e?"forward":"backward","word"),!0},Bl=function(e,t){var n=e.dom.createRng();n.setStart(t.container(),t.offset()),n.setEnd(t.container(),t.offset()),e.selection.setRng(n)},Il=function(e){return!1!==e.settings.inline_boundaries},Ll=function(e,t){e?t.setAttribute("data-mce-selected","inline-boundary"):t.removeAttribute("data-mce-selected")},Ml=function(e,t,n){return wc(t,n).map(function(t){return Bl(e,t),n})},Hl=function(e,t,n){return function(){return!!Il(t)&&function(e,t){var n=t.selection.getRng(),r=e?Ui.fromRangeEnd(n):Ui.fromRangeStart(n);return!!function(e){return Hn.isFunction(e.selection.getSel().modify)}(t)&&(e&&Jo(r)?Pl(!0,t.selection,r):!(e||!Qo(r))&&Pl(!1,t.selection,r))}(e,t)}},Fl={move:function(e,t,n){return function(){return!!Il(e)&&function(e,t,n){var r=e.getBody(),o=Ui.fromRangeStart(e.selection.getRng()),i=p.curry(Ru.isInlineTarget,e);return _l(n,i,r,o).bind(function(n){return Ml(e,t,n)})}(e,t,n).isSome()}},moveNextWord:p.curry(Hl,!0),movePrevWord:p.curry(Hl,!1),setupSelectedState:function(e){var t=new Ol(null),n=p.curry(Ru.isInlineTarget,e);return e.on("NodeChange",function(r){Il(e)&&(function(t,n,r){var o=P.filter(e.dom.select('*[data-mce-selected="inline-boundary"]'),t),i=P.filter(r,t);P.each(P.difference(o,i),p.curry(Ll,!1)),P.each(P.difference(i,o),p.curry(Ll,!0))}(n,0,r.parents),function(e,t){if(e.selection.isCollapsed()&&!0!==e.composing&&t.get()){var n=Ui.fromRangeStart(e.selection.getRng());Ui.isTextPosition(n)&&!1===Ru.isAtZwsp(n)&&(Bl(e,Zi.removeAndReposition(t.get(),n)),t.set(null))}}(e,t),function(e,t,n,r){if(t.selection.isCollapsed()){var o=P.filter(r,e);P.each(o,function(r){var o=Ui.fromRangeStart(t.selection.getRng());Rl(e,t.getBody(),o).bind(function(e){return Ml(t,n,e)})})}}(n,e,t,r.parents))}),t},setCaretPosition:Bl},Wl=function(e,t){return function(n){return wc(t,n).map(function(t){return Fl.setCaretPosition(e,t),!0}).getOr(!1)}},jl=function(e,t,n,r){var o=e.getBody(),i=p.curry(Ru.isInlineTarget,e);e.undoManager.ignore(function(){e.selection.setRng(function(e,t){var n=document.createRange();return n.setStart(e.container(),e.offset()),n.setEnd(t.container(),t.offset()),n}(n,r)),e.execCommand("Delete"),Rl(i,o,Ui.fromRangeStart(e.selection.getRng())).map(Dl).map(Wl(e,t))}),e.nodeChanged()},$l=function(e,t,n){return!(!e.selection.isCollapsed()||!function(e){return!1!==e.settings.inline_boundaries}(e))&&function(e,t,n,r){var o=function(e,t){return Ka(t,e)||e}(e.getBody(),r.container()),i=p.curry(Ru.isInlineTarget,e),a=Rl(i,o,r);return a.bind(function(e){return n?e.fold(p.constant(w.some(Dl(e))),w.none,p.constant(w.some(Al(e))),w.none):e.fold(w.none,p.constant(w.some(Al(e))),w.none,p.constant(w.some(Dl(e))))}).map(Wl(e,t)).getOrThunk(function(){var s=ia.navigate(n,o,r),u=s.bind(function(e){return Rl(i,o,e)});return a.isSome()&&u.isSome()?Ru.findRootInline(i,o,r).map(function(t){return!!function(e){return da([ia.firstPositionIn(e),ia.lastPositionIn(e)],function(t,n){var r=Ru.normalizePosition(!0,t),o=Ru.normalizePosition(!1,n);return ia.nextPosition(e,r).map(function(e){return e.isEqual(o)}).getOr(!0)}).getOr(!0)}(t)&&(uc(e,n,_n(t)),!0)}).getOr(!1):u.bind(function(o){return s.map(function(o){return n?jl(e,t,r,o):jl(e,t,o,r),!0})}).getOr(!1)})}(e,t,n,Ui.fromRangeStart(e.selection.getRng()))},zl=er("start","end"),ql=er("rng","table","cells"),Ul=Qu([{removeTable:["element"]},{emptyCells:["cells"]}]),Vl=function(e,t){return function(e,t,n){return pu(nr.is,Du,e,"td,th",n)}(_n(e),0,t)},Xl=function(e,t){return Ou(e,"table",t)},Yl=function(e){return!1===ir.eq(e.start(),e.end())},Kl=function(e,t){return P.findIndex(e,function(e){return ir.eq(e,t)})},Gl=function(e){return function(e){return da([Kl(e.cells(),e.rng().start()),Kl(e.cells(),e.rng().end())],function(t,n){return e.cells().slice(t,n+1)})}(e).bind(function(t){var n=e.cells();return t.length===n.length?Ul.removeTable(e.table()):Ul.emptyCells(t)})},Jl=function(e){var t=[];if(e)for(var n=0;n<e.rangeCount;n++)t.push(e.getRangeAt(n));return t},Ql=Jl,Zl=function(e,t){var n=Ea(t,"td[data-mce-selected],th[data-mce-selected]"),r=function(e){return P.filter(function(e){return P.bind(e,function(e){var t=yi(e);return t?[_n(t)]:[]})}(e),$r)}(e);return n.length>0?n:r},ef=Zl,tf=function(e,t){return P.each(t,au),e.selection.setCursorLocation(t[0].dom(),0),!0},nf=function(e,t){return uc(e,!1,t),!0},rf=function(e,t,n,r){return af(t,r).fold(function(){return function(e,t,n){return function(e,n){return function(e,t){var n=p.curry(ir.eq,e);return function(e,t){return da([Vl(e.startContainer,t),Vl(e.endContainer,t)],zl).filter(Yl)}(t,n).map(function(e){return function(e,t){return function(e,t){return Xl(e.start(),t).bind(function(n){return Xl(e.end(),t).bind(function(e){return ir.eq(n,e)?w.some(n):w.none()})})}(e,t).bind(function(t){var n=Ea(t,"td,th");return ql(e,t,n)})}
1(e,n)})}(t,n).map(Gl)}(0,n).map(function(t){return t.fold(p.curry(nf,e),p.curry(tf,e))})}(e,t,n)},function(t){return function(e,t){return sf(e,t)}(e,t)}).getOr(!1)},of=function(e,t){return P.find(qu(t,e),$r)},af=function(e,t){return P.find(qu(t,e),function(e){return"caption"===Ln.name(e)})},sf=function(e,t){return au(t),e.selection.setCursorLocation(t.dom(),0),w.some(!0)},uf=function(e,t){var n=_n(e.selection.getStart(!0));return e.selection.isCollapsed()?function(e,t,n){var r=_n(e.getBody());return af(r,n).fold(function(){return function(e,t,n,r){var o=Ui.fromRangeStart(e.selection.getRng());return of(n,r).bind(function(r){return Hu(r)?sf(e,r):function(e,t,n,r,o){return ia.navigate(n,e.getBody(),o).bind(function(e){return of(t,_n(e.getNode())).map(function(e){return!1===ir.eq(e,r)})})}(e,n,t,r,o)})}(e,t,r,n)},function(n){return function(e,t,n,r){var o=Ui.fromRangeStart(e.selection.getRng());return Hu(r)?sf(e,r):function(e,t,n,r,o){return ia.navigate(n,e.getBody(),o).bind(function(i){return function(e,t,n,r){return ia.firstPositionIn(e.dom()).bind(function(o){return ia.lastPositionIn(e.dom()).map(function(e){return t?n.isEqual(o)&&r.isEqual(e):n.isEqual(e)&&r.isEqual(o)})}).getOr(!0)}(r,n,o,i)?function(e,t){return sf(e,r)}(e):function(e,t,n){return af(e,_n(n.getNode())).map(function(e){return!1===ir.eq(e,t)})}(t,r,i)}).or(w.some(!0))}(e,n,t,r,o)}(e,t,r,n)}).getOr(!1)}(e,t,n):function(e,t){var n=_n(e.getBody()),r=e.selection.getRng(),o=function(e){return Zl(Ql(e.selection.getSel()),_n(e.getBody()))}(e);return 0!==o.length?tf(e,o):rf(e,n,r,t)}(e,n)},cf=function(e,t){e.getDoc().execCommand(t,!1,null)},lf={deleteCommand:function(e){cc(e,!1)||$l(e,!1)||Ku(e,!1)||uf(e)||Ju(e)||(cf(e,"Delete"),Au(e))},forwardDeleteCommand:function(e){cc(e,!0)||$l(e,!0)||Ku(e,!0)||uf(e)||Ju(e)||cf(e,"ForwardDelete")}},ff=function(e,t){return e&&t&&e.startContainer===t.startContainer&&e.startOffset===t.startOffset&&e.endContainer===t.endContainer&&e.endOffset===t.endOffset},df=er("container","offset"),hf=function(e,t,n){return null!==function(e,t,n){for(;e&&e!==t;){if(n(e))return e;e=e.parentNode}return null}(e,t,n)},pf=function(e,t,n){return hf(e,t,function(e){return e.nodeName===n})},mf=function(e){return e&&"TABLE"===e.nodeName},gf=function(e){return e&&/^(TD|TH|CAPTION)$/.test(e.nodeName)},vf=function(e,t){return Ko(e)&&!1===hf(e,t,cl.isCaretNode)},yf=function(e,t,n){for(var r=new Rr(t,e.getParent(t.parentNode,e.isBlock)||e.getRoot());t=r[n?"prev":"next"]();)if(Zr.isBr(t))return!0},bf=function(e,t,n,r,o){var i,a,s,u,c=e.getRoot(),l=e.schema.getNonEmptyElements();if(s=e.getParent(o.parentNode,e.isBlock)||c,r&&Zr.isBr(o)&&t&&e.isEmpty(s))return w.some(df(o.parentNode,e.nodeIndex(o)));for(i=new Rr(o,s);u=i[r?"prev":"next"]();){if("false"===e.getContentEditableParent(u)||vf(u,c))return w.none();if(Zr.isText(u)&&u.nodeValue.length>0)return!1===pf(u,c,"A")?w.some(df(u,r?u.nodeValue.length:0)):w.none();if(e.isBlock(u)||l[u.nodeName.toLowerCase()])return w.none();a=u}return n&&a?w.some(df(a,0)):w.none()},wf=function(e,t,n,r){var o,i,a,s,u,c,l,f=e.getRoot(),d=!1;if(o=r[(n?"start":"end")+"Container"],i=r[(n?"start":"end")+"Offset"],l=Zr.isElement(o)&&i===o.childNodes.length,u=e.schema.getNonEmptyElements(),c=n,Ko(o))return w.none();if(Zr.isElement(o)&&i>o.childNodes.length-1&&(c=!1),Zr.isDocument(o)&&(o=f,i=0),o===f){if(c&&(s=o.childNodes[i>0?i-1:0])){if(Ko(s))return w.none();if(u[s.nodeName]||mf(s))return w.none()}if(o.hasChildNodes()){if(i=Math.min(!c&&i>0?i-1:i,o.childNodes.length-1),i=Zr.isText(o=o.childNodes[i])&&l?o.data.length:0,!t&&o===f.lastChild&&mf(o))return w.none();if(function(e,t){for(;t&&t!==e;){if(Zr.isContentEditableFalse(t))return!0;t=t.parentNode}return!1}(f,o)||Ko(o))return w.none();if(o.hasChildNodes()&&!1===mf(o)){s=o,a=new Rr(o,f);do{if(Zr.isContentEditableFalse(s)||Ko(s)){d=!1;break}if(Zr.isText(s)&&s.nodeValue.length>0){i=c?0:s.nodeValue.length,o=s,d=!0;break}if(u[s.nodeName.toLowerCase()]&&!gf(s)){i=e.nodeIndex(s),o=s.parentNode,"IMG"!==s.nodeName&&"PRE"!==s.nodeName||c||i++,d=!0;break}}while(s=c?a.next():a.prev())}}}return t&&(Zr.isText(o)&&0===i&&bf(e,l,t,!0,o).each(function(e){o=e.container(),i=e.offset(),d=!0}),Zr.isElement(o)&&((s=o.childNodes[i])||(s=o.childNodes[i-1]),!s||!Zr.isBr(s)||function(e,t){return e.previousSibling&&"A"===e.previousSibling.nodeName}(s)||yf(e,s,!1)||yf(e,s,!0)||bf(e,l,t,!0,s).each(function(e){o=e.container(),i=e.offset(),d=!0}))),c&&!t&&Zr.isText(o)&&i===o.nodeValue.length&&bf(e,l,t,!1,o).each(function(e){o=e.container(),i=e.offset(),d=!0}),d?w.some(df(o,i)):w.none()},xf={normalize:function(e,t){var n=t.collapsed,r=t.cloneRange();return wf(e,n,!0,r).each(function(e){r.setStart(e.container(),e.offset())}),n||wf(e,n,!1,r).each(function(e){r.setEnd(e.container(),e.offset())}),n&&r.collapse(!0),ff(t,r)?w.none():w.some(r)}},Cf=function(e,t,n){var r=e.create("span",{}," ");n.parentNode.insertBefore(r,n),t.scrollIntoView(r),e.remove(r)},Sf=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)},Tf=function(e,t){var n=Nn("br");Qs(_n(t),n),e.undoManager.add()},Ef=function(e,t){kf(e.getBody(),t)||Zs(_n(t),Nn("br"));var n=Nn("br");Zs(_n(t),n),Cf(e.dom,e.selection,n.dom()),Sf(e.dom,e.selection,n.dom(),!1),e.undoManager.add()},kf=function(e,t){return n=Ui.after(t),!!Zr.isBr(n.getNode())||ia.nextPosition(e,Ui.after(t)).map(function(e){return Zr.isBr(e.getNode())}).getOr(!1);var n},Nf=function(e){return e&&"A"===e.nodeName&&"href"in e},Rf=function(e){return e.fold(p.constant(!1),Nf,Nf,p.constant(!1))},_f=function(e,t){t.fold(p.noop,p.curry(Tf,e),p.curry(Ef,e),p.noop)},Af={insert:function(e,t){var n=function(e){var t=p.curry(Ru.isInlineTarget,e),n=Ui.fromRangeStart(e.selection.getRng());return Rl(t,e.getBody(),n).filter(Rf)}(e);n.isSome()?n.each(p.curry(_f,e)):function(e,t){var n,r,o=e.selection,i=e.dom,a=o.getRng();xf.normalize(i,a).each(function(e){a.setStart(e.startContainer,e.startOffset),a.setEnd(e.endContainer,e.endOffset)});var s=a.startOffset,u=a.startContainer;if(1===u.nodeType&&u.hasChildNodes()){var c=s>u.childNodes.length-1;u=u.childNodes[Math.min(s,u.childNodes.length-1)]||u,s=c&&3===u.nodeType?u.nodeValue.length:0}var l=i.getParent(u,i.isBlock),f=l?i.getParent(l.parentNode,i.isBlock):null;"LI"!==(f?f.nodeName.toUpperCase():"")||t&&t.ctrlKey||(l=f),u&&3===u.nodeType&&s>=u.nodeValue.length&&(function(e,t,n){for(var r,o=new Rr(t,n),i=e.getNonEmptyElements();r=o.next();)if(i[r.nodeName.toLowerCase()]||r.length>0)return!0}(e.schema,u,l)||(n=i.create("br"),a.insertNode(n),a.setStartAfter(n),a.setEndAfter(n),r=!0)),n=i.create("br"),a.insertNode(n),Cf(i,o,n),Sf(i,o,n,r),e.undoManager.add()}(e,t)}},Df=(Qu([{before:["element"]},{on:["element","offset"]},{after:["element"]}]),function(e){return e.fold(p.identity,p.identity,p.identity)}),Of=Qu([{domRange:["rng"]},{relative:["startSitu","finishSitu"]},{exact:["start","soffset","finish","foffset"]}]),Pf=er("start","soffset","finish","foffset"),Bf={domRange:Of.domRange,relative:Of.relative,exact:Of.exact,exactFromRange:function(e){return Of.exact(e.start(),e.soffset(),e.finish(),e.foffset())},range:Pf,getWin:function(e){var t=function(e){return e.match({domRange:function(e){return _n(e.startContainer)},relative:function(e,t){return Df(e)},exact:function(e,t,n,r){return e}})}(e);return lr(t)}},If=Tn.detect().browser,Lf=function(e,t){var n=Ln.isText(t)?function(e){return iu.get(e)}(t).length:mr(t).length+1;return e>n?n:e<0?0:e},Mf=function(e){return Bf.range(e.start(),Lf(e.soffset(),e.start()),e.finish(),Lf(e.foffset(),e.finish()))},Hf=function(e,t){return ir.contains(e,t)||ir.eq(e,t)},Ff=function(e){return function(t){return Hf(e,t.start())&&Hf(e,t.finish())}},Wf=function(e){return!0===e.inline||If.isIE()},jf=function(e){return Bf.range(_n(e.startContainer),e.startOffset,_n(e.endContainer),e.endOffset)},$f=function(e){var t=e.getSelection();return(t&&0!==t.rangeCount?w.from(t.getRangeAt(0)):w.none()).map(jf)},zf=function(e){var t=lr(e);return $f(t.dom()).filter(Ff(e))},qf=function(e,t){return w.from(t).filter(Ff(e)).map(Mf)},Uf=function(e){var t=document.createRange();
1return t.setStart(e.start().dom(),e.soffset()),t.setEnd(e.finish().dom(),e.foffset()),w.some(t)},Vf=function(e){return(e.bookmark?e.bookmark:w.none()).bind(p.curry(qf,_n(e.getBody()))).bind(Uf)},Xf={store:function(e){var t=Wf(e)?zf(_n(e.getBody())):w.none();e.bookmark=t.isSome()?t:e.bookmark},storeNative:function(e,t){var n=_n(e.getBody()),r=(Wf(e)?w.from(t):w.none()).map(jf).filter(Ff(n));e.bookmark=r.isSome()?r:e.bookmark},readRange:$f,restore:function(e){Vf(e).each(function(t){e.selection.setRng(t)})},getRng:Vf,getBookmark:zf,validate:qf},Yf=function(e,t){var n=e.settings,r=e.dom,o=e.selection,i=e.formatter,a=/[a-z%]+$/i.exec(n.indentation)[0],s=parseInt(n.indentation,10),u=e.getParam("indent_use_margin",!1);e.queryCommandState("InsertUnorderedList")||e.queryCommandState("InsertOrderedList")||(n.forced_root_block||r.getParent(o.getNode(),r.isBlock)||i.apply("div"),P.each(o.getSelectedBlocks(),function(e){return function(e,t,n,r,o,i){if("false"!==e.getContentEditable(i)&&"LI"!==i.nodeName){var a=n?"margin":"padding";if(a="TABLE"===i.nodeName?"margin":a,a+="rtl"===e.getStyle(i,"direction",!0)?"Right":"Left","outdent"===t){var s=Math.max(0,parseInt(i.style[a]||0,10)-r);e.setStyle(i,a,s?s+o:"")}else s=parseInt(i.style[a]||0,10)+r+o,e.setStyle(i,a,s)}}(r,t,u,s,a,e)}))},Kf=kt.each,Gf=kt.extend,Jf=kt.map,Qf=kt.inArray,Zf=kt.explode,ed=!0,td=!1;function nd(e){var t,n,r,o,i={state:{},exec:{},value:{}},a=e.settings;e.on("PreInit",function(){t=e.dom,n=e.selection,a=e.settings,r=e.formatter});var s=function(t){var n;if(!e.quirks.isHidden()&&!e.removed){if(t=t.toLowerCase(),n=i.state[t])return n(t);try{return e.getDoc().queryCommandState(t)}catch(e){}return!1}},u=function(e,t){t=t||"exec",Kf(e,function(e,n){Kf(n.toLowerCase().split(","),function(n){i[t][n]=e})})};Gf(this,{execCommand:function(t,n,r,o){var a,s,u=!1;if(!e.removed){if(/^(mceAddUndoLevel|mceEndUndoLevel|mceBeginUndoLevel|mceRepaint)$/.test(t)||o&&o.skip_focus?Xf.restore(e):e.focus(),(o=e.fire("BeforeExecCommand",{command:t,ui:n,value:r})).isDefaultPrevented())return!1;if(s=t.toLowerCase(),a=i.exec[s])return a(s,n,r),e.fire("ExecCommand",{command:t,ui:n,value:r}),!0;if(Kf(e.plugins,function(o){if(o.execCommand&&o.execCommand(t,n,r))return e.fire("ExecCommand",{command:t,ui:n,value:r}),u=!0,!1}),u)return u;if(e.theme&&e.theme.execCommand&&e.theme.execCommand(t,n,r))return e.fire("ExecCommand",{command:t,ui:n,value:r}),!0;try{u=e.getDoc().execCommand(t,n,r)}catch(e){}return!!u&&(e.fire("ExecCommand",{command:t,ui:n,value:r}),!0)}},queryCommandState:s,queryCommandValue:function(t){var n;if(!e.quirks.isHidden()&&!e.removed){if(t=t.toLowerCase(),n=i.value[t])return n(t);try{return e.getDoc().queryCommandValue(t)}catch(e){}}},queryCommandSupported:function(t){if(t=t.toLowerCase(),i.exec[t])return!0;try{return e.getDoc().queryCommandSupported(t)}catch(e){}return!1},addCommands:u,addCommand:function(t,n,r){t=t.toLowerCase(),i.exec[t]=function(t,o,i,a){return n.call(r||e,o,i,a)}},addQueryStateHandler:function(t,n,r){t=t.toLowerCase(),i.state[t]=function(){return n.call(r||e)}},addQueryValueHandler:function(t,n,r){t=t.toLowerCase(),i.value[t]=function(){return n.call(r||e)}},hasCustomCommand:function(e){return e=e.toLowerCase(),!!i.exec[e]}});var c=function(t,n,r){return void 0===n&&(n=td),void 0===r&&(r=null),e.getDoc().execCommand(t,n,r)},l=function(e){return r.match(e)},f=function(t,n){r.toggle(t,n?{value:n}:void 0),e.nodeChanged()},d=function(e){o=n.getBookmark(e)},h=function(){n.moveToBookmark(o)};u({"mceResetDesignMode,mceBeginUndoLevel":function(){},"mceEndUndoLevel,mceAddUndoLevel":function(){e.undoManager.add()},"Cut,Copy,Paste":function(t){var n,r=e.getDoc();try{c(t)}catch(e){n=ed}if("paste"!==t||r.queryCommandEnabled(t)||(n=!0),n||!r.queryCommandSupported(t)){var o=e.translate("Your browser doesn't support direct access to the clipboard. Please use the Ctrl+X/C/V keyboard shortcuts instead.");ae.mac&&(o=o.replace(/Ctrl\+/g,"\u2318+")),e.notificationManager.open({text:o,type:"error"})}},unlink:function(){if(n.isCollapsed()){var t=e.dom.getParent(e.selection.getStart(),"a");t&&e.dom.remove(t,!0)}else r.remove("link")},"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull,JustifyNone":function(e){var t=e.substring(7);"full"===t&&(t="justify"),Kf("left,center,right,justify".split(","),function(e){t!==e&&r.remove("align"+e)}
1),"none"!==t&&f("align"+t)},"InsertUnorderedList,InsertOrderedList":function(e){var r,o;c(e),(r=t.getParent(n.getNode(),"ol,ul"))&&/^(H[1-6]|P|ADDRESS|PRE)$/.test((o=r.parentNode).nodeName)&&(d(),t.split(o,r),h())},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(e){f(e)},"ForeColor,HiliteColor,FontName":function(e,t,n){f(e,n)},FontSize:function(e,t,n){var r,o;n>=1&&n<=7&&(o=Zf(a.font_size_style_values),n=(r=Zf(a.font_size_classes))?r[n-1]||n:o[n-1]||n),f(e,n)},RemoveFormat:function(e){r.remove(e)},mceBlockQuote:function(){f("blockquote")},FormatBlock:function(e,t,n){return f(n||"p")},mceCleanup:function(){var t=n.getBookmark();e.setContent(e.getContent({cleanup:ed}),{cleanup:ed}),n.moveToBookmark(t)},mceRemoveNode:function(t,r,o){var i=o||n.getNode();i!==e.getBody()&&(d(),e.dom.remove(i,ed),h())},mceSelectNodeDepth:function(r,o,i){var a=0;t.getParent(n.getNode(),function(e){if(1===e.nodeType&&a++===i)return n.select(e),td},e.getBody())},mceSelectNode:function(e,t,r){n.select(r)},mceInsertContent:function(t,n,r){hu.insertAtCaret(e,r)},mceInsertRawHTML:function(t,r,o){n.setContent("tiny_mce_marker"),e.setContent(e.getContent().replace(/tiny_mce_marker/g,function(){return o}))},mceToggleFormat:function(e,t,n){f(n)},mceSetContent:function(t,n,r){e.setContent(r)},"Indent,Outdent":function(t){Yf(e,t)},mceRepaint:function(){},InsertHorizontalRule:function(){e.execCommand("mceInsertContent",!1,"<hr />")},mceToggleVisualAid:function(){e.hasVisual=!e.hasVisual,e.addVisual()},mceReplaceContent:function(t,r,o){e.execCommand("mceInsertContent",!1,o.replace(/\{\$selection\}/g,n.getContent({format:"text"})))},mceInsertLink:function(e,o,i){var a;"string"==typeof i&&(i={href:i}),a=t.getParent(n.getNode(),"a"),i.href=i.href.replace(" ","%20"),a&&i.href||r.remove("link"),i.href&&r.apply("link",i,a)},selectAll:function(){var e=t.getParent(n.getStart(),Zr.isContentEditableTrue);if(e){var r=t.createRng();r.selectNodeContents(e),n.setRng(r)}},delete:function(){lf.deleteCommand(e)},forwardDelete:function(){lf.forwardDeleteCommand(e)},mceNewDocument:function(){e.setContent("")},InsertLineBreak:function(t,n,r){return Af.insert(e,r),!0}}),u({"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull":function(e){var o="align"+e.substring(7),i=n.isCollapsed()?[t.getParent(n.getNode(),t.isBlock)]:n.getSelectedBlocks(),a=Jf(i,function(e){return!!r.matchNode(e,o)});return-1!==Qf(a,ed)},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(e){return l(e)},mceBlockQuote:function(){return l("blockquote")},Outdent:function(){var e;if(a.inline_styles){if((e=t.getParent(n.getStart(),t.isBlock))&&parseInt(e.style.paddingLeft,10)>0)return ed;if((e=t.getParent(n.getEnd(),t.isBlock))&&parseInt(e.style.paddingLeft,10)>0)return ed}return s("InsertUnorderedList")||s("InsertOrderedList")||!a.inline_styles&&!!t.getParent(n.getNode(),"BLOCKQUOTE")},"InsertUnorderedList,InsertOrderedList":function(e){var r=t.getParent(n.getNode(),"ul,ol");return r&&("insertunorderedlist"===e&&"UL"===r.tagName||"insertorderedlist"===e&&"OL"===r.tagName)}},"state"),u({"FontSize,FontName":function(e){var r,o=0;return(r=t.getParent(n.getNode(),"span"))&&(o="fontsize"===e?r.style.fontSize:r.style.fontFamily.replace(/, /g,",").replace(/[\'\"]/g,"").toLowerCase()),o}},"value"),u({Undo:function(){e.undoManager.undo()},Redo:function(){e.undoManager.redo()}})}var rd=kt.makeMap("focus blur focusin focusout click dblclick mousedown mouseup mousemove mouseover beforepaste paste cut copy selectionchange mouseout mouseenter mouseleave wheel keydown keypress keyup input contextmenu dragstart dragend dragover draggesture dragdrop drop drag submit compositionstart compositionend compositionupdate touchstart touchmove touchend"," "),od=function(e){var t,n,r=this,o={},i=function(){return!1},a=function(){return!0};t=(e=e||{}).scope||r,n=e.toggleEvent||i;var s=function(e,t,a,s){var u,c,l;if(!1===t&&(t=i),t)for(t={func:t},s&&kt.extend(t,s),l=(c=e.toLowerCase().split(" ")).length;l--;)(u=o[e=c[l]])||(u=o[e]=[],n(e,!0)),a?u.unshift(t):u.push(t);return r},u=function(e,t){var i,a,s,u,c;if(e)for(i=(u=e.toLowerCase().split(" ")).length;i--;){if(a=o[e=u[i]],!e){for(s in o)n(s,!1),delete o[s];return r}if(a){if(t)for(c=a.length;c--;)a[c].func===t&&(a=a.slice(0,c).concat(a.slice(c+1)),o[e]=a);else a.length=0;a.length||(n(e,!1),delete o[e])}}else{for(e in o)n(e,!1);o={}}return r};r.fire=function(n,r){var s,c,l,f;if(n=n.toLowerCase(),(r=r||{}).type=n,r.target||(r.target=t),r.preventDefault||(r.preventDefault=function(){r.isDefaultPrevented=a},r.stopPropagation=function(){r.isPropagationStopped=a},r.stopImmediatePropagation=function(){r.isImmediatePropagationStopped=a},r.isDefaultPrevented=i,r.isPropagationStopped=i,r.isImmediatePropagationStopped=i),e.beforeFire&&e.beforeFire(r),s=o[n])for(c=0,l=s.length;c<l;c++){if((f=s[c]).once&&u(n,f.func),r.isImmediatePropagationStopped())return r.stopPropagation(),r;if(!1===f.func.call(t,r))return r.preventDefault(),r}return r},r.on=s,r.off=u,r.once=function(e,t,n){return s(e,t,n,{once:!0})},r.has=function(e){return e=e.toLowerCase(),!(!o[e]||0===o[e].length)}};od.isNative=function(e){return!!rd[e.toLowerCase()]};var id,ad=function(e){return e._eventDispatcher||(e._eventDispatcher=new od({scope:e,toggleEvent:function(t,n){od.isNative(t)&&e.toggleNativeEvent&&e.toggleNativeEvent(t,n)}})),e._eventDispatcher},sd={fire:function(e,t,n){if(this.removed&&"remove"!==e)return t;if(t=ad(this).fire(e,t,n),!1!==n&&this.parent)for(var r=this.parent();r&&!t.isPropagationStopped();)r.fire(e,t,!1),r=r.parent();return t},on:function(e,t,n){return ad(this).on(e,t,n)},off:function(e,t){return ad(this).off(e,t)},once:function(e,t){return ad(this).once(e,t)},hasEventListeners:function(e){return ad(this).has(e)}},ud=Lo.DOM,cd=function(e,t){return"selectionchange"===t?e.getDoc():!e.inline&&/^mouse|touch|click|contextmenu|drop|dragover|dragend/.test(t)?e.getDoc().documentElement:e.settings.event_root?(e.eventRoot||(e.eventRoot=ud.select(e.settings.event_root)[0]),e.eventRoot):e.getBody()},ld=function(e,t){var n,r,o=function(e){return!e.hidden&&!e.readonly};if(e.delegates||(e.delegates={}),!e.delegates[t]&&!e.removed)if(n=cd(e,t),e.settings.event_root){if(id||(id={},e.editorManager.on("removeEditor",function(){var t;if(!e.editorManager.activeEditor&&id){for(t in id)e.dom.unbind(cd(e,t));id=null}})),id[t])return;id[t]=r=function(n){for(var r=n.target,i=e.editorManager.get(),a=i.length;a--;){var s=i[a].getBody();(s===r||ud.isChildOf(r,s))&&o(i[a])&&i[a].fire(t,n)}},ud.bind(n,t,r)}else ud.bind(n,t,r=function(n){o(e)&&e.fire(t,n)}),e.delegates[t]=r},fd={bindPendingEventDelegates:function(){var e=this;kt.each(e._pendingNativeEvents,function(t){ld(e,t)})},toggleNativeEvent:function(e,t){"focus"!==e&&"blur"!==e&&(t?this.initialized?ld(this,e):this._pe
1ndingNativeEvents?this._pendingNativeEvents.push(e):this._pendingNativeEvents=[e]:this.initialized&&(this.dom.unbind(cd(this,e),e,this.delegates[e]),delete this.delegates[e]))},unbindAllNativeEvents:function(){var e,t=this.getBody(),n=this.dom;if(this.delegates){for(e in this.delegates)this.dom.unbind(cd(this,e),e,this.delegates[e]);delete this.delegates}!this.inline&&t&&n&&(t.onload=null,n.unbind(this.getWin()),n.unbind(this.getDoc())),n&&(n.unbind(t),n.unbind(this.getContainer()))}},dd=fd=kt.extend({},sd,fd),hd=function(e,t,n){try{e.getDoc().execCommand(t,!1,n)}catch(e){}},pd=function(e,t){e._clickBlocker&&(e._clickBlocker.unbind(),e._clickBlocker=null),t?(e._clickBlocker=function(e){var t,n;return t=e.getBody(),e.dom.bind(t,"click",n=function(t){e.dom.getParents(t.target,"a").length>0&&t.preventDefault()}),{unbind:function(){e.dom.unbind(t,"click",n)}}}(e),e.selection.controlSelection.hideResizeRect(),e.readonly=!0,e.getBody().contentEditable=!1):(e.readonly=!1,e.getBody().contentEditable=!0,hd(e,"StyleWithCSS",!1),hd(e,"enableInlineTableEditing",!1),hd(e,"enableObjectResizing",!1),e.focus(),e.nodeChanged())},md=kt.each,gd=kt.explode,vd={f9:120,f10:121,f11:122},yd=kt.makeMap("alt,ctrl,shift,meta,access");function bd(e){var t={},n=[],r=function(e){var t,n,r={};for(n in md(gd(e,"+"),function(e){e in yd?r[e]=!0:/^[0-9]{2,}$/.test(e)?r.keyCode=parseInt(e,10):(r.charCode=e.charCodeAt(0),r.keyCode=vd[e]||e.toUpperCase().charCodeAt(0))}),t=[r.keyCode],yd)r[n]?t.push(n):r[n]=!1;return r.id=t.join(","),r.access&&(r.alt=!0,ae.mac?r.ctrl=!0:r.shift=!0),r.meta&&(ae.mac?r.meta=!0:(r.ctrl=!0,r.meta=!1)),r},o=function(t,n,o,i){var a;return(a=kt.map(gd(t,">"),r))[a.length-1]=kt.extend(a[a.length-1],{func:o,scope:i||e}),kt.extend(a[0],{desc:e.translate(n),subpatterns:a.slice(1)})},i=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)},a=function(e){return e.func?e.func.call(e.scope):null};e.on("keyup keypress keydown",function(e){!function(e){return e.altKey||e.ctrlKey||e.metaKey}(e)&&!function(e){return"keydown"===e.type&&e.keyCode>=112&&e.keyCode<=123}(e)||e.isDefaultPrevented()||(md(t,function(t){if(i(e,t))return n=t.subpatterns.slice(0),"keydown"===e.type&&a(t),!0}),i(e,n[0])&&(1===n.length&&"keydown"===e.type&&a(n[0]),n.shift()))}),this.add=function(n,r,i,a){var s;return s=i,"string"==typeof i?i=function(){e.execCommand(s,!1,null)}:kt.isArray(s)&&(i=function(){e.execCommand(s[0],s[1],s[2])}),md(gd(kt.trim(n.toLowerCase())),function(e){var n=o(e,r,i,a);t[n.id]=n}),!0},this.remove=function(e){var n=o(e);return!!t[n.id]&&(delete t[n.id],!0)}}var wd=function(e){var t=cr(e).dom();return e.dom()===t.activeElement},xd=function(e,t){(function(e,t){return function(e){return e.collapsed?w.from(bi(e.startContainer,e.startOffset)).map(_n):w.none()}(t).bind(function(t){return jr(t)?w.some(t):!1===ir.contains(e,t)?w.some(e):w.none()})})(_n(e.getBody()),t).bind(function(e){return ia.firstPositionIn(e.dom())}).fold(function(){return e.selection.normalize()},function(t){return e.selection.setRng(t.toRange())})},Cd=function(e){if(e.setActive)try{e.setActive()}catch(t){e.focus()}else e.focus()},Sd=function(e){return e.inline?function(e){var t,n,r,o,i=e.getBody();return i&&(t=_n(i),wd(t)||(n=t,(r=cr(n),o=void 0!==r?r.dom():document,w.from(o.activeElement).map(_n)).filter(function(e){return n.dom().contains(e.dom())})).isSome())}(e):function(e){return e.iframeElement&&wd(_n(e.iframeElement))}(e)},Td=function(e){e.editorManager.setActive(e)},Ed=Sd,kd=function(e,t){return t.dom()[e]},Nd=function(e,t){return parseInt(Zn(t,e),10)},Rd=p.curry(kd,"clientWidth"),_d=p.curry(kd,"clientHeight"),Ad=p.curry(Nd,"margin-top"),Dd=p.curry(Nd,"margin-left"),Od={isXYInContentArea:function(e,t,n){var r,o=_n(e.getBody()),i=e.inline?o:(r=ar(o),_n(r.dom().documentElement)),a=function(e,t,n,r){var o=function(e){return e.dom().getBoundingClientRect()}(t);return{x:n-(e?o.left+t.dom().clientLeft+Dd(t):0),y:r-(e?o.top+t.dom().clientTop+Ad(t):0)}}(e.inline,i,t,n);return function(e,t,n){var r=Rd(e),o=_d(e);return t>=0&&n>=0&&t<=r&&n<=o}(i,a.x,a.y)},isEditorAttachedToDom:function(e){var t;return(t=e.inline?e.getBody():e.getContentAreaContainer(),w.from(t).map(_n)).map(function(e){return ir.contains(cr(e),e)}).getOr(!1)}};function Pd(e){var t=[],n=function(){var t,n=e.theme;return n&&n.getNotificationManagerImpl?n.getNotificationManagerImpl():{open:t=function(){throw new Error("Theme did n
1ot provide a NotificationManager implementation.")},close:t,reposition:t,getArgs:t}},r=function(){t.length>0&&n().reposition(t)},o=function(e){P.findIndex(t,function(t){return t===e}).each(function(e){t.splice(e,1)})},i=function(i){if(!e.removed&&Od.isEditorAttachedToDom(e))return P.find(t,function(e){return!((t=n().getArgs(e)).type!==(r=i).type||t.text!==r.text||t.progressBar||t.timeout||r.progressBar||r.timeout);var t,r}).getOrThunk(function(){e.editorManager.setActive(e);var a=n().open(i,function(){o(a),r()});return function(e){t.push(e)}(a),r(),a})};return function(e){e.on("SkinLoaded",function(){var t=e.settings.service_message;t&&i({text:t,type:"warning",timeout:0,icon:""})}),e.on("ResizeEditor ResizeWindow",function(){fe.requestAnimationFrame(r)}),e.on("remove",function(){P.each(t,function(e){n().close(e)})})}(e),{open:i,close:function(){w.from(t[0]).each(function(e){n().close(e),o(e),r()})},getNotifications:function(){return t}}}function Bd(e){var t=[],n=function(){var t,n=e.theme;return n&&n.getWindowManagerImpl?n.getWindowManagerImpl():{open:t=function(){throw new Error("Theme did not provide a WindowManager implementation.")},alert:t,confirm:t,close:t,getParams:t,setParams:t}},r=function(e,t){return function(){return t?t.apply(e,arguments):void 0}},o=function(n){t.push(n),function(t){e.fire("OpenWindow",{win:t})}(n)},i=function(n){P.findIndex(t,function(e){return e===n}).each(function(r){t.splice(r,1),function(t){e.fire("CloseWindow",{win:t})}(n),0===t.length&&e.focus()})},a=function(){return w.from(t[t.length-1])};return e.on("remove",function(){P.each(t.slice(0),function(e){n().close(e)})}),{windows:t,open:function(t,r){e.editorManager.setActive(e),Xf.store(e);var a=n().open(t,r,i);return o(a),a},alert:function(e,t,a){var s=n().alert(e,r(a||this,t),i);o(s)},confirm:function(e,t,a){var s=n().confirm(e,r(a||this,t),i);o(s)},close:function(){a().each(function(e){n().close(e),i(e)})},getParams:function(){return a().map(n().getParams).getOr(null)},setParams:function(e){a().each(function(t){n().setParams(t,e)})},getWindows:function(){return t}}}var Id=zo.PluginManager,Ld=function(e,t){e.notificationManager.open({type:"error",text:t})},Md=function(e,t){e._skinLoaded?Ld(e,t):e.on("SkinLoaded",function(){Ld(e,t)})},Hd={pluginLoadError:function(e,t){Md(e,function(e,t){var n=function(e,t){for(var n in Id.urls)if(Id.urls[n]+"/plugin"+t+".js"===e)return n;return null}(t,e.suffix);return n?"Failed to load plugin: "+n+" from url "+t:"Failed to load plugin url: "+t}(e,t))},uploadError:function(e,t){Md(e,"Failed to upload image: "+t)},displayError:Md,initError:function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=window.console;r&&(r.error?r.error.apply(r,arguments):r.log.apply(r,arguments))}},Fd=zo.PluginManager,Wd=zo.ThemeManager;function jd(){return new(I.getOrDie("XMLHttpRequest"))}function $d(e,t){return new(I.getOrDie("Blob"))(e,t)}var zd=function(e){var t,n;return e=decodeURIComponent(e).split(","),(n=/data:([^;]+)/.exec(e[0]))&&(t=n[1]),{type:t,data:e[1]}},qd=function(e){return 0===e.indexOf("blob:")?function(e){return new se(function(t,n){var r=function(){n("Cannot convert "+e+" to Blob. Resource might not exist or is inaccessible.")};try{var o=new jd;o.open("GET",e,!0),o.responseType="blob",o.onload=function(){200===this.status?t(this.response):r()},o.onerror=r,o.send()}catch(e){r()}})}(e):0===e.indexOf("data:")?(t=e,new se(function(e){var n,r,o,i;t=zd(t);try{i=t.data,n=I.getOrDie("atob")(i)}catch(t){return void e(new $d([]))}for(r=new function(e){return new(I.getOrDie("Uint8Array"))(e)}(n.length),o=0;o<r.length;o++)r[o]=n.charCodeAt(o);e(new $d([r],{type:t.type}))})):null;var t},Ud=zd,Vd=0,Xd=function(e){return(e||"blobid")+Vd++},Yd=function(e,t,n,r){var o,i;0!==t.src.indexOf("blob:")?(o=Ud(t.src).data,(i=e.findFirst(function(e){return e.base64()===o}))?n({image:t,blobInfo:i}):qd(t.src).then(function(r){i=e.create(Xd(),r,o),e.add(i),n({image:t,blobInfo:i})},function(e){r(e)})):(i=e.getByUri(t.src))?n({image:t,blobInfo:i}):qd(t.src).then(function(r){(function(e){return new se(function(t){var n=new function(){return new(I.getOrDie("FileReader"))};n.onloadend=function(){t(n.result)},n.readAsDataURL(e)})})(r).then(function(a){o=Ud(a).data,i=e.create(Xd(),r,o),e.add(i),n({image:t,blobInfo:i})})},function(e){r(e)})},Kd=function(e){return e?e.getElementsByTagName("img"):[]},Gd=0,Jd={uuid:function(e){return e+Gd+++(t=function(){return Math.round(4294967295*Math.random()).toString(36)},"s"+(new Date).getTime().toString(36)+t()+t()+t());var t}};function Qd(e){var t,n,r,o,i,a,s,u,c,l,f=(t=[],n=Ti.constant,r=function(e){var t,r,o;if(!e.blob||!e.base64)throw new Error("blob and base64 representations of the image are required for BlobInfo to be created");return t=e.id||Jd.uuid("blobid"),r=e.name||t,{id:n(t),name:n(r),filename:n(r+"."+(o=e.blob.type,{"image/jpeg":"jpg","
1image/jpg":"jpg","image/gif":"gif","image/png":"png"}[o.toLowerCase()]||"dat")),blob:n(e.blob),base64:n(e.base64),blobUri:n(e.blobUri||M.createObjectURL(e.blob)),uri:n(e.uri)}},{create:function(e,t,n,o){return r("object"==typeof e?e:{id:e,name:o,blob:t,base64:n})},add:function(e){o(e.id())||t.push(e)},get:o=function(e){return i(function(t){return t.id()===e})},getByUri:function(e){return i(function(t){return t.blobUri()===e})},findFirst:i=function(e){return xt.filter(t,e)[0]},removeByUri:function(e){t=xt.filter(t,function(t){return t.blobUri()!==e||(M.revokeObjectURL(t.blobUri()),!1)})},destroy:function(){xt.each(t,function(e){M.revokeObjectURL(e.blobUri())}),t=[]}}),d=e.settings,h=(u={},c=function(e,t){return{status:e,resultUri:t}},{hasBlobUri:l=function(e){return e in u},getResultUri:function(e){var t=u[e];return t?t.resultUri:null},isPending:function(e){return!!l(e)&&1===u[e].status},isUploaded:function(e){return!!l(e)&&2===u[e].status},markPending:function(e){u[e]=c(1,null)},markUploaded:function(e,t){u[e]=c(2,t)},removeFailed:function(e){delete u[e]},destroy:function(){u={}}}),p=function(t){return function(n){return e.selection?t(n):[]}},m=function(e,t,n){var r=0;do{-1!==(r=e.indexOf(t,r))&&(e=e.substring(0,r)+n+e.substr(r+t.length),r+=n.length-t.length+1)}while(-1!==r);return e},g=function(e,t,n){return e=m(e,'src="'+t+'"','src="'+n+'"'),m(e,'data-mce-src="'+t+'"','data-mce-src="'+n+'"')},v=function(t,n){xt.each(e.undoManager.data,function(e){"fragmented"===e.type?e.fragments=xt.map(e.fragments,function(e){return g(e,t,n)}):e.content=g(e.content,t,n)})},y=function(){return e.notificationManager.open({text:e.translate("Image uploading..."),type:"info",timeout:-1,progressBar:!0})},b=function(t){return a||(a=function(e,t){var n={},r=function(e,n,r,o){var i,a;(i=new jd).open("POST",t.url),i.withCredentials=t.credentials,i.upload.onprogress=function(e){o(e.loaded/e.total*100)},i.onerror=function(){r("Image upload failed due to a XHR Transport error. Code: "+i.status)},i.onload=function(){var e,o,a;i.status<200||i.status>=300?r("HTTP Error: "+i.status):(e=JSON.parse(i.responseText))&&"string"==typeof e.location?n((a=e.location,(o=t.basePath)?o.replace(/\/$/,"")+"/"+a.replace(/^\//,""):a)):r("Invalid JSON: "+i.responseText)},(a=new FormData).append("file",e.blob(),e.filename()),i.send(a)},o=function(e,t){return{url:t,blobInfo:e,status:!0}},i=function(e,t){return{url:"",blobInfo:e,status:!1,error:t}},a=function(e,t){kt.each(n[e],function(e){e(t)}),delete n[e]};return t=kt.extend({credentials:!1,handler:r},t),{upload:function(s,u){return t.url||t.handler!==r?function(r,s){return r=kt.grep(r,function(t){return!e.isUploaded(t.blobUri())}),se.all(kt.map(r,function(r){return e.isPending(r.blobUri())?function(e){var t=e.blobUri();return new se(function(e){n[t]=n[t]||[],n[t].push(e)})}(r):function(t,n,r){return e.markPending(t.blobUri()),new se(function(s){var u;try{var c=function(){u&&u.close()};n(t,function(n){c(),e.markUploaded(t.blobUri(),n),a(t.blobUri(),o(t,n)),s(o(t,n))},function(n){c(),e.removeFailed(t.blobUri()),a(t.blobUri(),i(t,n)),s(i(t,n))},function(e){e<0||e>100||(u||(u=r()),u.progressBar.value(e))})}catch(e){s(i(t,e.message))}})}(r,t.handler,s)}))}(s,u):new se(function(e){e([])})}}}(h,{url:d.images_upload_url,basePath:d.images_upload_base_path,credentials:d.images_upload_credentials,handler:d.images_upload_handler})),C().then(p(function(n){var r;return r=xt.map(n,function(e){return e.blobInfo}),a.upload(r,y).then(p(function(r){var o=xt.map(r,function(t,r){var o=n[r].image;return t.status&&!1!==e.settings.images_replace_blob_uris?function(t,n){f.removeByUri(t.src),v(t.src,n),e.$(t).attr({src:d.images_reuse_filename?n+"?"+(new Date).getTime():n,"data-mce-src":e.convertURL(n,"src")})}(o,t.url):t.error&&Hd.uploadError(e,t.error),{element:o,status:t.status}});return t&&t(o),o}))}))},w=function(e){if(!1!==d.automatic_uploads)return b(e)},x=function(e){return!d.images_dataimg_filter||d.images_dataimg_filter(e)},C=function(){return s||(s=function(e,t){var n={};return{findAll:function(r,o){var i,a;return o||(o=Ti.constant(!0)),i=xt.filter(Kd(r),function(t){var n=t.src;return!!ae.fileApi&&!t.hasAttribute("data-mce-bogus")&&!t.hasAttribute("data-mce-placeholder")&&!(!n||n===ae.transparentSrc)&&(0===n.indexOf("blob:")?!e.isUploaded(n):0===n.indexOf("data:")&&o(t))}),a=xt.map(i,function(e){var r;return n[e.src]?new se(function(t){n[e.src].then(function(n){if("string"==typeof n)return n;t({image:e,blobInfo:n.blobInfo})})}):(r=new se(function(n,r){Yd(t,e,n,r)}).then(function(e){return delete n[e.image.src],e}).catch(function(t){return delete n[e.src],t}),n[e.src]=r,r)}),se.all(a)}}}(h,f)),s.findAll(e.getBody(),x).then(p(function(t){return t=xt.filter(t,function(t){return"string"!=typeof t||(Hd.displayError(e,t),!1)}
1),xt.each(t,function(e){v(e.image.src,e.blobInfo.blobUri()),e.image.src=e.blobInfo.blobUri(),e.image.removeAttribute("data-mce-src")}),t}))},S=function(t){return t.replace(/src="(blob:[^"]+)"/g,function(t,n){var r=h.getResultUri(n);if(r)return'src="'+r+'"';var o=f.getByUri(n);return o||(o=xt.reduce(e.editorManager.get(),function(e,t){return e||t.editorUpload&&t.editorUpload.blobCache.getByUri(n)},null)),o?'src="data:'+o.blob().type+";base64,"+o.base64()+'"':t})};return e.on("setContent",function(){!1!==e.settings.automatic_uploads?w():C()}),e.on("RawSaveContent",function(e){e.content=S(e.content)}),e.on("getContent",function(e){e.source_view||"raw"===e.format||(e.content=S(e.content))}),e.on("PostRender",function(){e.parser.addNodeFilter("img",function(e){xt.each(e,function(e){var t=e.attr("src");if(!f.getByUri(t)){var n=h.getResultUri(t);n&&e.attr("src",n)}})})}),{blobCache:f,uploadImages:b,uploadImagesAuto:w,scanForImages:C,destroy:function(){f.destroy(),h.destroy(),s=a=null}}}var Zd,eh=function(e,t){return e.hasOwnProperty(t.nodeName)},th=function(e,t){return!!Zr.isText(t)||!!Zr.isElement(t)&&!eh(e,t)&&!Xs.isBookmarkNode(t)},nh=function(e,t){if(Zr.isText(t)){if(0===t.nodeValue.length)return!0;if(/^\s+$/.test(t.nodeValue)&&(!t.nextSibling||eh(e,t.nextSibling)))return!0}return!1},rh=function(e){var t,n,r,o,i,a,s,u,c,l,f,d=e.settings,h=e.dom,p=e.selection,m=e.schema,g=m.getBlockElements(),v=p.getStart(),y=e.getBody();if(f=d.forced_root_block,v&&Zr.isElement(v)&&f&&(l=y.nodeName.toLowerCase(),m.isValidChild(l,f.toLowerCase())&&!function(e,t,n){return P.exists(zu(_n(n),_n(t)),function(t){return eh(e,t.dom())})}(g,y,v))){for(n=(t=p.getRng()).startContainer,r=t.startOffset,o=t.endContainer,i=t.endOffset,c=Ed(e),v=y.firstChild;v;)if(th(g,v)){if(nh(g,v)){s=v,v=v.nextSibling,h.remove(s);continue}a||(a=h.create(f,e.settings.forced_root_block_attrs),v.parentNode.insertBefore(a,v),u=!0),s=v,v=v.nextSibling,a.appendChild(s)}else a=null,v=v.nextSibling;u&&c&&(t.setStart(n,r),t.setEnd(o,i),p.setRng(t),e.nodeChanged())}},oh=function(e){var t,n,r,o;return{top:(o=e.getBoundingClientRect()).top+(r=(t=e.ownerDocument).defaultView).pageYOffset-(n=t.documentElement).clientTop,left:o.left+r.pageXOffset-n.clientLeft}},ih=Zr.isContentEditableFalse,ah=Zr.isContentEditableTrue,sh=function(e){e&&e.parentNode&&e.parentNode.removeChild(e)},uh=function(e){e.dragging=!1,e.element=null,sh(e.ghost)},ch=function(e){return xt.reduce(e,function(e,t){return e.concat(function(e){var t=function(t){return xt.map(t,function(t){return(t=hi(t)).node=e,t})};if(Zr.isElement(e))return t(e.getClientRects());if(Zr.isText(e)){var n=e.ownerDocument.createRange();return n.setStart(e,0),n.setEnd(e,e.data.length),t(n.getClientRects())}}(t))},[])};!function(e){e[e.Up=-1]="Up",e[e.Down=1]="Down"}(Zd||(Zd={}));var lh=function(e,t,n,r,o,i){var a,s,u=0,c=[],l=function(r){var i,a,l;for(l=ch([r]),-1===e&&(l=l.reverse()),i=0;i<l.length;i++)if(!n(a=l[i],s)){if(c.length>0&&t(a,xt.last(c))&&u++,a.line=u,o(a))return!0;c.push(a)}};return(s=xt.last(i.getClientRects()))?(l(a=i.getNode()),function(e,t,n,r){for(;r=Ya(r,e,fi,t);)if(n(r))return}(e,r,l,a),c):c},fh=p.curry(lh,Zd.Up,gi,vi),dh=p.curry(lh,Zd.Down,vi,gi),hh=function(e){return function(t){return function(e,t){return t.line>e}(e,t)}},ph=function(e){return function(t){return function(e,t){return t.line===e}(e,t)}},mh=Zr.isContentEditableFalse,gh=Ya,vh=function(e,t){return Math.abs(e.left-t)},yh=function(e,t){return Math.abs(e.right-t)},bh=function(e,t){return e>=t.left&&e<=t.right},wh=function(e,t){return xt.reduce(e,function(e,n){var r,o;return r=Math.min(vh(e,t),yh(e,t)),o=Math.min(vh(n,t),yh(n,t)),bh(t,n)?n:bh(t,e)?e:o===r&&mh(n.node)?n:o<r?n:e})},xh=function(e,t,n,r){for(;r=gh(r,e,fi,t);)if(n(r))return},Ch=function(e,t,n){return!n.collapsed&&P.foldl(n.getClientRects(),function(n,r){return n||function(e,t,n){return t>=e.left&&t<=e.right&&n>=e.top&&n<=e.bottom}(r,e,t)},!1)},Sh=function(e,t){var n=null;return{cancel:function(){null!==n&&(clearTimeout(n),n=null)},throttle:function(){var r=arguments;null===n&&(n=setTimeout(function(){e.apply(null,r),n=null,r=null},t))}}},Th={BACKSPACE:8,DELETE:46,DOWN:40,ENTER:13,LEFT:37,RIGHT:39,SPACEBAR:32,TAB:9,UP:38,modifierPressed:function(e){return e.shiftKey||e.ctrlKey||e.altKey||this.metaKeyPressed(e)},metaKeyPressed:function(e){return ae.mac?e.metaKey:e.ctrlKey&&!e.altKey}},Eh=Zr.isContentEditableTrue,kh=Zr.isContentEditableFalse,Nh=cs,Rh=us,_h=function(e){var t,n,r,o,i,a,s,u,c,l=e.getBody(),f=(r=e.getBody(),o=function(t){return e.dom.isBlock(t)},s=null,{show:function(e,t){var n,c,l;return u(),Zr.isElement(l=t)&&/^(TD|TH)$/i.test(l.tagName)?null:o(t)?(a=function(e,t,n){var r,o,i;return(r=t.ownerDocument.createElement("p")).setAttribute("data-mce-caret",n?"before":"after"),r.setAttribute("data-mce-bogus","all"),r.appendChild(((i=document.createElement("br")).setAttribute("data-mce-bogus","1"),i)),o=t.parentNode,n?o.insertBefore(r,t):t.nextSibling?o.insertBefore(r,t.nextSibling):o.appendChild(r),r}(0,t,e),n=function(e,t,n){var r,o,i,a,s,u=pi(t.getBoundingClientRect(),n);return"BODY"===e.tagName?(r=e.ownerDocument.documentElement,o=e.scrollLeft||r.scrollLeft,i=e.scrollTop||r.scrollTop):(s=e.getBoundingClientRect(),o=e.scrollLeft-s.left,i=e.scrollTop-s.top),u.left+=o,u.right+=o,u.top+=i,u.bottom+=i,u.width=1,(a=t.offsetWidth-t.clientWidth)>0&&(n&&(a*=-1),u.left+=a,u.right+=a),u}(r,t,e),Ut(a).css("top",n.top),s=Ut('<div class="mce-visual-caret" data-mce-bogus="all"></div>').css(n).appendTo(r),e&&s.addClass("mce-visual-caret-before"),i=fe.setInterval(function(){!function(e){return e.ownerDocument.activeElement===e}(r)?Ut("div.mce-visual-caret",r).addClass("mce-visual-caret-hidden"):Ut("div.mce-visual-caret",r).toggleClass("mce-visual-caret-hidden")},500),(c=t.ownerDocument.createRange()).setStart(a,0),c.setEnd(a,0),c):(a=function(e,t){var n,r,o;
1if(r=e.ownerDocument.createTextNode("\ufeff"),o=e.parentNode,t){if(Vo(n=e.previousSibling)){if(Ko(n))return n;if(ei(n))return n.splitText(n.data.length-1)}o.insertBefore(r,e)}else{if(Vo(n=e.nextSibling)){if(Ko(n))return n;if(Zo(n))return n.splitText(1),n}e.nextSibling?o.insertBefore(r,e.nextSibling):o.appendChild(r)}return r}(t,e),c=t.ownerDocument.createRange(),La(a.nextSibling)?(c.setStart(a,0),c.setEnd(a,0)):(c.setStart(a,1),c.setEnd(a,1)),c)},hide:u=function(){!function(e){var t,n,r,o,i;for(t=Ut("*[contentEditable=false]",e),o=0;o<t.length;o++)ei(r=(n=t[o]).previousSibling)&&(1===(i=r.data).length?r.parentNode.removeChild(r):r.deleteData(i.length-1,1)),Zo(r=n.nextSibling)&&(1===(i=r.data).length?r.parentNode.removeChild(r):r.deleteData(0,1))}(r),a&&(Zi.remove(a),a=null),s&&(s.remove(),s=null),clearInterval(i)},getCss: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;}"},destroy:function(){return fe.clearInterval(i)}}),d="sel-"+e.dom.uniqueId(),h=function(t){t&&e.selection.setRng(t)},m=function(){return e.selection.getRng()},g=function(t,n){e.selection.scrollIntoView(t,n)},v=function(t,n,r){return e.fire("ShowCaret",{target:n,direction:t,before:r}).isDefaultPrevented()?null:(g(n,-1===t),f.show(r,n))},y=function(e,t){return t=rs(e,l,t),-1===e?Ui.fromRangeStart(t):Ui.fromRangeEnd(t)},b=function(e){return Ko(e)||Zo(e)||ei(e)},w=function(e){return b(e.startContainer)||b(e.endContainer)},x=function(n,r){var o,i,a,s,u,c,l,f,h,p,m=e.$,g=e.dom;if(!n)return null;if(n.collapsed){if(!w(n))if(!1===r){if(f=y(-1,n),Ma(f.getNode(!0)))return v(-1,f.getNode(!0),!1);if(Ma(f.getNode()))return v(-1,f.getNode(),!f.isAtEnd())}else{if(f=y(1,n),Ma(f.getNode()))return v(1,f.getNode(),!f.isAtEnd());if(Ma(f.getNode(!0)))return v(1,f.getNode(!0),!1)}return null}return u=n.startOffset,c=n.endOffset,3===(s=n.startContainer).nodeType&&0===u&&kh(s.parentNode)&&(u=g.nodeIndex(s=s.parentNode),s=s.parentNode),1!==s.nodeType?null:(c===u+1&&(o=s.childNodes[u]),kh(o)?(h=p=o.cloneNode(!0),(l=e.fire("ObjectSelected",{target:o,targetClone:h})).isDefaultPrevented()?null:(i=Pu(_n(e.getBody()),"#"+d).fold(function(){return m([])},function(e){return m([e.dom()])}),h=l.targetClone,0===i.length&&(i=m('<div data-mce-bogus="all" class="mce-offscreen-selection"></div>').attr("id",d)).appendTo(e.getBody()),n=e.dom.createRng(),h===p&&ae.ie?(i.empty().append('<p style="font-size: 0" data-mce-bogus="all">\xa0</p>').append(h),n.setStartAfter(i[0].firstChild.firstChild),n.setEndAfter(h)):(i.empty().append("\xa0").append(h).append("\xa0"),n.setStart(i[0].firstChild,1),n.setEnd(i[0].lastChild,0)),i.css({top:g.getPos(o,e.getBody()).y}),i[0].focus(),(a=e.selection.getSel()).removeAllRanges(),a.addRange(n),P.each(Ea(_n(e.getBody()),"*[data-mce-selected]"),function(e){Kn(e,"data-mce-selected")}),o.setAttribute("data-mce-selected","1"),t=o,S(),n)):null)},C=function(){t&&(t.removeAttribute("data-mce-selected"),Pu(_n(e.getBody()),"#"+d).each(ou),t=null)},S=function(){f.hide()};return ae.ceFalse&&(c=function(t){for(var n=e.getBody();t&&t!==n;){if(Eh(t)||kh(t))return t;t=t.parentNode}return null},e.on("mouseup",function(t){var n=m();n.collapsed&&Od.isXYInContentArea(e,t.clientX,t.clientY)&&h(la(e,n))}),e.on("click",function(t){var n;(n=c(t.target))&&(kh(n)&&(t.preventDefault(),e.focus()),Eh(n)&&e.dom.isChildOf(n,e.selection.getNode())&&C())}),e.on("blur NewBlock",function(){C()}),function(e){var t=!1;e.on("touchstart",function(){t=!1}),e.on("touchmove",function(){t=!0}),e.on("touchend",function(n){var r=c(n.target);kh(r)&&(t||(n.preventDefault(),x(ca(e,r))))})}(e),e.on("mousedown",function(t){var n,r,o,i,a,s,u,f,d,m,g,y=t.target;if((y===l||"HTML"===y.nodeName||e.dom.isChildOf(y,l))&&!1!==Od.isXYInContentArea(e,t.clientX,t.clientY))if(n=c(y))kh(n)?(t.preventDefault(),x(ca(e,n))):(C(),Eh(n)&&t.shiftKey||Ch(t.clientX,t.clientY,e.selection.getRng())||e.selection.placeCaretAt(t.clientX,t.clientY));else if(!1===Ma(y)){C(),S();var b=(u=t.clientX,f=t.clientY,m=ch(function(e){return xt.filter(xt.toArray(e.getElementsByTagName("*")),Ma)}(s=l)),g=xt.filter(m,function(e){return f>=e.top&&f<=e.bottom}),(d=wh(g,u))&&(d=wh(function(e,t){var n=[],r=function(e,r){var o;return o=xt.filter(ch([r]),function(n){return!e(n,t)}),n=n.concat(o),0===o.length};return n.push(t),xh(Zd.Up,e,p.curry(r,gi),t.node),xh(Zd.Down,e,p.curry(r,vi),t.node),n}(s,d),u))&&Ma(d.node)?function(e,t){return{node:e.node,before:vh(e,t)<yh(e,t)}}(d,u):null);b&&(r=b.node,i=e.dom.getParent(t.target,e.dom.isBlock),a=e.dom.getParent(r,e.dom.isBlock),i&&(o=a,e.dom.getParent(i,e.dom.isBlock)!==e.dom.getParent(o,e.dom.isBlock))&&function(e){var t=Cs(e);if(!e.firstChild)return!1;var n=Ui.before(e.firstChild),r=t.next(n);return r&&!Rh(r)&&!Nh(r)}(i)||(t.preventDefault(),e.getBody().focus(),h(v(1,b.node,b.before))))}}),e.on("keypress",function(t){Th.modifierPressed(t)||kh(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()).selectNode(t),e.range=n}}),e.on("setSelectionRange",function(e){var t;(t=x(e.range,e.forward))&&(e.range=t)}),e.on("AfterSetSelectionRange",function(t){var n=t.range;w(n)||S(),e.dom.hasClass(n.startContainer.parentNode,"mce-offscreen-selection")||C()}),e.on("copy",function(t){var n,r=t.clipboardData;if(!t.isDefaultPrevented()&&t.clipboardData&&!ae.ie){var o=(n=e.dom.get(d))?n.getElementsByTagName("*")[0]:n;o&&(t.preventDefault(),r.clearData(),r.setData("text/html",o.outerHTML),r.setData("text/plain",o.outerText))}}),function(e){(function(e){var t,n,r,o,i,a,s={};t=Lo.DOM,a=document,n=function(e,t){return function(n){if(function(e){return 0===e.button}(n)){var r=xt.find(t.dom.getParents(n.target),Ti.or(ih,ah));if(s=t.getBody(),ih(u=r)&&u!==s){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=function(e,t,n,o){var i=r.cloneNode(!0);e.dom.setStyles(i,{width:n,height:o}),e.dom.setAttrib(i,"data-mce-selected",null);var a=e.dom.create("div",{class:"mce-drag-container","data-mce-bogus":"all",unselectable:"on",contenteditable:"false"});return e.dom.setStyles(a,{position:"absolute",opacity:.5,overflow:"hidden",border:0,padding:0,margin:0,width:n,height:o}),e.dom.setStyles(i,{margin:0,boxSizing:"border-box"}),a.appendChild(i),a}(t,0,e.width,e.height)}}var s,u}}(s,e),r=function(e,t){var n=fe.throttle(function(e,n){t._selectionOverrides.hideFakeCaret(),t.selection.placeCaretAt(e,n)},0);return function(r){var o,i,a=Math.max(Math.abs(r.screenX-e.screenX),Math.abs(r.screenY-e.screenY));if(function(e){return e.element}(e)&&!e.dragging&&a>10){if(t.fire("dragstart",{target:e.element}).isDefaultPrevented())return;
1e.dragging=!0,t.focus()}if(e.dragging){var s=function(e,t){return{pageX:t.pageX-e.relX,pageY:t.pageY+5}}(e,function(e,t){return n=function(e){return e.inline?oh(e.getBody()):{left:0,top:0}}(e),r=function(e){var t=e.getBody();return e.inline?{left:t.scrollLeft,top:t.scrollTop}:{left:0,top:0}}(e),{pageX:(o=function(e,t){if(t.target.ownerDocument!==e.getDoc()){var n=oh(e.getContentAreaContainer()),r=function(e){var t=e.getBody(),n=e.getDoc().documentElement;return e.inline?{left:t.scrollLeft,top:t.scrollTop}:{left:t.scrollLeft||n.scrollLeft,top:t.scrollTop||n.scrollTop}}(e);return{left:t.pageX-n.left+r.left,top:t.pageY-n.top+r.top}}return{left:t.pageX,top:t.pageY}}(e,t)).left-n.left+r.left,pageY:o.top-n.top+r.top};var n,r,o}(t,r));o=e.ghost,i=t.getBody(),o.parentNode!==i&&i.appendChild(o),function(e,t,n,r,o,i){var a=0,s=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&&(s=t.pageY+r-i),e.style.width=n-a+"px",e.style.height=r-s+"px"}(e.ghost,s,e.width,e.height,e.maxX,e.maxY),n(r.clientX,r.clientY)}}}(s,e),o=function(e,t){return function(n){if(e.dragging&&function(e,t,n){return t!==n&&!e.dom.isChildOf(t,n)&&!ih(t)}(t,3===(a=t.selection.getSel().getRangeAt(0).startContainer).nodeType?a.parentNode:a,e.element)){var r=((i=e.element.cloneNode(!0)).removeAttribute("data-mce-selected"),i),o=t.fire("drop",{targetClone:r,clientX:n.clientX,clientY:n.clientY});o.isDefaultPrevented()||(r=o.targetClone,t.undoManager.transact(function(){sh(e.element),t.insertContent(t.dom.getOuterHTML(r)),t._selectionOverrides.hideFakeCaret()}))}var i,a;uh(e)}}(s,e),i=function(e,t){return function(){uh(e),e.dragging&&t.fire("dragend")}}(s,e),e.on("mousedown",n),e.on("mousemove",r),e.on("mouseup",o),t.bind(a,"mousemove",r),t.bind(a,"mouseup",i),e.on("remove",function(){t.unbind(a,"mousemove",r),t.unbind(a,"mouseup",i)})})(e),function(e){e.on("drop",function(t){var n="undefined"!=typeof t.clientX?e.getDoc().elementFromPoint(t.clientX,t.clientY):null;(ih(n)||ih(e.dom.getContentEditableParent(n)))&&t.preventDefault()})}(e)}(e),function(e){var t=Sh(function(){if(!e.removed&&e.selection.getRng().collapsed){var t=fa(e,e.selection.getRng());e.selection.setRng(t)}},0);e.on("focus",function(){t.throttle()}),e.on("blur",function(){t.cancel()})}(e),(n=e.contentStyles).push(f.getCss()),n.push(".mce-content-body .mce-offscreen-selection {position: absolute;left: -9999999999px;max-width: 1000000px;}.mce-content-body *[contentEditable=false] {cursor: default;}.mce-content-body *[contentEditable=true] {cursor: text;}")),{showCaret:v,showBlockCaretContainer:function(e){e.hasAttribute("data-mce-caret")&&(ti(e),h(m()),g(e[0]))},hideFakeCaret:S,destroy:function(){f.destroy(),t=null}}},Ah=kt.each,Dh=function(e){return 0===e.indexOf("data-")||0===e.indexOf("aria-")},Oh=function(e){return e.replace(/<!--|-->/g,"")},Ph=function(e,t,n){var r,o,i,a,s=1;for(a=e.getShortEndedElements(),(i=/<([!?\/])?([A-Za-z0-9\-_\:\.]+)((?:\s+[^"\'>]+(?:(?:"[^"]*")|(?:\'[^\']*\')|[^>]*))*|\/|\s+)>/g).lastIndex=r=n;o=i.exec(t);){if(r=i.lastIndex,"/"===o[1])s--;else if(!o[1]){if(o[2]in a)continue;s++}if(0===s)break}return r};function Bh(e,t){void 0===t&&(t=Eo());var n=function(){};!1!==(e=e||{}).fix_self_closing&&(e.fix_self_closing=!0),Ah("comment cdata text start end pi doctype".split(" "),function(t){t&&(self[t]=e[t]||n)});var r=e.comment?e.comment:n,o=e.cdata?e.cdata:n,i=e.text?e.text:n,a=e.start?e.start:n,s=e.end?e.end:n,u=e.pi?e.pi:n,c=e.doctype?e.doctype:n;return{parse:function(n){var l,f,d,h,p,m,g,v,y,b,w,x,C,S,T,E,k,N,R,_,A,D,O,P,B,I,L,M,H,F=0,W=[],j=0,$=po.decode,z=kt.makeMap("src,href,data,background,formaction,poster"),q=/((java|vb)script|mhtml):/i,U=/^data:/i,V=function(e){var t,n;for(t=W.length;t--&&W[t].name!==e;);if(t>=0){for(n=W.length-1;n>=t;n--)(e=W[n]).valid&&s(e.name);W.length=t}},X=function(t,n,r,o,i){var a,s;if(r=(n=n.toLowerCase())in w?n:$(r||o||i||""),C&&!v&&!1===Dh(n)){if(!(a=N[n])&&R){for(s=R.length;s--&&!(a=R[s]).pattern.test(n););-1===s&&(a=null)}if(!a)return;if(a.validValues&&!(r in a.validValues))return}if(z[n]&&!e.allow_script_urls){var u=r.replace(/[\s\u0000-\u001F]+/g,"");try{u=decodeURIComponent(u)}catch(e){u=unescape(u)}if(q.test(u))return;if(!e.allow_html_data_urls&&U.test(u)&&!/^data:image\//i.test(u))return}v&&(n in z||0===n.indexOf("on"))||(h.map[n]=r,h.push({name:n,value:r}))};
1for(B=new RegExp("<(?:(?:!--([\\w\\W]*?)--\x3e)|(?:!\\[CDATA\\[([\\w\\W]*?)\\]\\]>)|(?:!DOCTYPE([\\w\\W]*?)>)|(?:\\?([^\\s\\/<>]+) ?([\\w\\W]*?)[?/]>)|(?:\\/([A-Za-z][A-Za-z0-9\\-_\\:\\.]*)>)|(?:([A-Za-z][A-Za-z0-9\\-_\\:\\.]*)((?:\\s+[^\"'>]+(?:(?:\"[^\"]*\")|(?:'[^']*')|[^>]*))*|\\/|\\s+)>))","g"),I=/([\w:\-]+)(?:\s*=\s*(?:(?:\"((?:[^\"])*)\")|(?:\'((?:[^\'])*)\')|([^>\s]+)))?/g,b=t.getShortEndedElements(),P=e.self_closing_elements||t.getSelfClosingElements(),w=t.getBoolAttrs(),C=e.validate,y=e.remove_internals,H=e.fix_self_closing,L=t.getSpecialElements(),O=n+">";l=B.exec(O);){if(F<l.index&&i($(n.substr(F,l.index-F))),f=l[6])":"===(f=f.toLowerCase()).charAt(0)&&(f=f.substr(1)),V(f);else if(f=l[7]){if(l.index+l[0].length>n.length){i($(n.substr(l.index))),F=l.index+l[0].length;continue}if(":"===(f=f.toLowerCase()).charAt(0)&&(f=f.substr(1)),x=f in b,H&&P[f]&&W.length>0&&W[W.length-1].name===f&&V(f),!C||(S=t.getElementRule(f))){if(T=!0,C&&(N=S.attributes,R=S.attributePatterns),(k=l[8])?((v=-1!==k.indexOf("data-mce-type"))&&y&&(T=!1),(h=[]).map={},k.replace(I,X)):(h=[]).map={},C&&!v){if(_=S.attributesRequired,A=S.attributesDefault,D=S.attributesForced,S.removeEmptyAttrs&&!h.length&&(T=!1),D)for(p=D.length;p--;)g=(E=D[p]).name,"{$uid}"===(M=E.value)&&(M="mce_"+j++),h.map[g]=M,h.push({name:g,value:M});if(A)for(p=A.length;p--;)(g=(E=A[p]).name)in h.map||("{$uid}"===(M=E.value)&&(M="mce_"+j++),h.map[g]=M,h.push({name:g,value:M}));if(_){for(p=_.length;p--&&!(_[p]in h.map););-1===p&&(T=!1)}if(E=h.map["data-mce-bogus"]){if("all"===E){F=Ph(t,n,B.lastIndex),B.lastIndex=F;continue}T=!1}}T&&a(f,h,x)}else T=!1;if(d=L[f]){d.lastIndex=F=l.index+l[0].length,(l=d.exec(n))?(T&&(m=n.substr(F,l.index-F)),F=l.index+l[0].length):(m=n.substr(F),F=n.length),T&&(m.length>0&&i(m,!0),s(f)),B.lastIndex=F;continue}x||(k&&k.indexOf("/")===k.length-1?T&&s(f):W.push({name:f,valid:T}))}else(f=l[1])?(">"===f.charAt(0)&&(f=" "+f),e.allow_conditional_comments||"[if"!==f.substr(0,3).toLowerCase()||(f=" "+f),r(f)):(f=l[2])?o(Oh(f)):(f=l[3])?c(f):(f=l[4])&&u(f,l[5]);F=l.index+l[0].length}for(F<n.length&&i($(n.substr(F))),p=W.length-1;p>=0;p--)(f=W[p]).valid&&s(f.name)}}}!function(e){e.findEndTag=Ph}(Bh||(Bh={}));var Ih=Bh,Lh=function(e,t){var n,r,o,i,a,s=t,u=/<(\w+) [^>]*data-mce-bogus="all"[^>]*>/g,c=e.schema;for(s=function(e,t){var n=new RegExp(["\\s?("+e.join("|")+')="[^"]+"'].join("|"),"gi");return t.replace(n,"")}(e.getTempAttrs(),s),a=c.getShortEndedElements();i=u.exec(s);)r=u.lastIndex,o=i[0].length,n=a[i[1]]?r:Ih.findEndTag(c,s,r),s=s.substring(0,r-o)+s.substring(n),u.lastIndex=r-o;return s},Mh=Lh,Hh=function(e){return 1===e.nodeType?e.outerHTML:3===e.nodeType?po.encodeRaw(e.data,!1):8===e.nodeType?"\x3c!--"+e.data+"--\x3e":""},Fh=function(e){return{type:"fragmented",fragments:e,content:"",bookmark:null,beforeBookmark:null}},Wh=function(e){return{type:"complete",fragments:null,content:e,bookmark:null,beforeBookmark:null}},jh=function(e){return"fragmented"===e.type?e.fragments.join(""):e.content},$h={createFragmentedLevel:Fh,createCompleteLevel:Wh,createFromEditor:function(e){var t,n,r,o;return o=e.getBody(),t=xt.filter(xt.map(o.childNodes,Hh),function(e){return e.length>0}),-1!==(n=(r=P.bind(t,function(t){var n=Mh(e.serializer,t);return n.length>0?[n]:[]})).join("")).indexOf("</iframe>")?Fh(r):Wh(n)},applyToEditor:function(e,t,n){var r,o,i,a,s,u,c,l,f,d,h,p;"fragmented"===t.type?(r=t.fragments,o=e.getBody(),p=xt.map(o.childNodes,Hh),function(e,t){var n=0;xt.each(e,function(e){0===e[0]?n++:1===e[0]?(function(t,n,r){var o=function(e){var t,n,r;for(r=document.createElement("div"),t=document.createDocumentFragment(),e&&(r.innerHTML=e);n=r.firstChild;)t.appendChild(n);return t}(e[1]);if(t.hasChildNodes()&&r<t.childNodes.length){var i=t.childNodes[r];i.parentNode.insertBefore(o,i)}else t.appendChild(o)}(t,0,n),n++):2===e[0]&&function(e,t){if(e.hasChildNodes()&&t<e.childNodes.length){var n=e.childNodes[t];n.parentNode.removeChild(n)}}(t,n)})}((s=(i=p).length+(a=r).length+2,u=new Array(s),c=new Array(s),l=function(e,t,n,r,o){var s=d(e,t,n,r);if(null===s||s.start===t&&s.diag===t-r||s.end===e&&s.diag===e-n)for(var u=e,c=n;u<t||c<r;)u<t&&c<r&&i[u]===a[c]?(o.push([0,i[u]]),++u,++c):t-e>r-n?(o.push([2,i[u]]),++u):(o.push([1,a[c]]),++c);else{l(e,s.start,n,s.start-s.diag,o);for(var f=s.start;f<s.end;++f)o.push([0,i[f]]);l(s.end,t,s.end-s.diag,r,o)}},f=function(e,t,n,r){for(var o=e;o-t<r&&o<n&&i[o]===a[o-t];)++o;return function(e,t,n){return{start:e,end:t,diag:n}}(e,o,t)},d=function(e,t,n,r){var o=t-e,s=r-n;if(0===o||0===s)return null;var l,d,h,p,m,g=o-s,v=s+o,y=(v%2==0?v:v+1)/2;for(u[1+y]=e,c[1+y]=t+1,l=0;l<=y;++l){for(d=-l;d<=l;d+=2){for(u[h=d+y]=d===-l||d!==l&&u[h-1]<u[h+1]?u[h+1]:u[h-1]+1,m=(p=u[h])-e+n-d;p<t&&m<r&&i[p]===a[m];)u[h]=++p,++m;if(g%2!=0&&g-l<=d&&d<=g+l&&c[h-g]<=u[h])return f(c[h-g],d+e-n,t,r)}for(d=g-l;d<=g+l;d+=2){for(c[h=d+y-g]=d===g-l||d!==g+l&&c[h+1]<=c[h-1]?c[h+1]-1:c[h-1],m=(p=c[h]-1)-e+n-d;p>=e&&m>=n&&i[p]===a[m];)c[h]=p--,m--;if(g%2==0&&-l<=d&&d<=l&&c[h]<=u[h+g])return f(c[h],d+e-n,t,r)}}},l(0,i.length,0,a.length,h=[]),h),o)):e.setContent(t.content,{format:"raw"}),e.selection.moveToBookmark(n?t.beforeBookmark:t.bookmark)},isEq:function(e,t){return!!e&&!!t&&jh(e)===jh(t)}};function zh(e){var t,n,r=this,o=0,i=[],a=0,s=function(){return 0===a},u=function(e){s()&&(r.typing=e)},c=function(t){e.setDirty(t)},l=function(e){u(!1),r.add({},e)},f=function(){r.typing&&(u(!1),r.add())};return e.on("init",function(){r.add()}),e.on("BeforeExecCommand",function(e){var t=e.command;"Undo"!==t&&"Redo"!==t&&"mceRepaint"!==t&&(f(),r.beforeChange())}),e.on("ExecCommand",function(e){var t=e.command;"Undo"!==t&&"Redo"!==t&&"mceRepaint"!==t&&l(e)}
1),e.on("ObjectResizeStart Cut",function(){r.beforeChange()}),e.on("SaveContent ObjectResized blur",l),e.on("DragEnd",l),e.on("KeyUp",function(t){var o=t.keyCode;t.isDefaultPrevented()||((o>=33&&o<=36||o>=37&&o<=40||45===o||t.ctrlKey)&&(l(),e.nodeChanged()),46!==o&&8!==o||e.nodeChanged(),n&&r.typing&&!1===$h.isEq($h.createFromEditor(e),i[0])&&(!1===e.isDirty()&&(c(!0),e.fire("change",{level:i[0],lastLevel:null})),e.fire("TypingUndo"),n=!1,e.nodeChanged()))}),e.on("KeyDown",function(e){var t=e.keyCode;e.isDefaultPrevented()||(t>=33&&t<=36||t>=37&&t<=40||45===t?r.typing&&l(e):!(t<16||t>20)||224===t||91===t||r.typing||e.ctrlKey&&!e.altKey||e.metaKey||(r.beforeChange(),u(!0),r.add({},e),n=!0))}),e.on("MouseDown",function(e){r.typing&&l(e)}),e.addShortcut("meta+z","","Undo"),e.addShortcut("meta+y,meta+shift+z","","Redo"),e.on("AddUndo Undo Redo ClearUndos",function(t){t.isDefaultPrevented()||e.nodeChanged()}),r={data:i,typing:!1,beforeChange:function(){s()&&(t=zs.getUndoBookmark(e.selection))},add:function(n,r){var a,u,l,f=e.settings;if(l=$h.createFromEditor(e),n=kt.extend(n=n||{},l),!1===s()||e.removed)return null;if(e.fire("BeforeAddUndo",{level:n,lastLevel:u=i[o],originalEvent:r}).isDefaultPrevented())return null;if(u&&$h.isEq(u,n))return null;if(i[o]&&(i[o].beforeBookmark=t),f.custom_undo_redo_levels&&i.length>f.custom_undo_redo_levels){for(a=0;a<i.length-1;a++)i[a]=i[a+1];i.length--,o=i.length}n.bookmark=zs.getUndoBookmark(e.selection),o<i.length-1&&(i.length=o+1),i.push(n),o=i.length-1;var d={level:n,lastLevel:u,originalEvent:r};return e.fire("AddUndo",d),o>0&&(c(!0),e.fire("change",d)),n},undo:function(){var t;return r.typing&&(r.add(),r.typing=!1,u(!1)),o>0&&(t=i[--o],$h.applyToEditor(e,t,!0),c(!0),e.fire("undo",{level:t})),t},redo:function(){var t;return o<i.length-1&&(t=i[++o],$h.applyToEditor(e,t,!1),c(!0),e.fire("redo",{level:t})),t},clear:function(){i=[],o=0,r.typing=!1,r.data=i,e.fire("ClearUndos")},hasUndo:function(){return o>0||r.typing&&i[0]&&!$h.isEq($h.createFromEditor(e),i[0])},hasRedo:function(){return o<i.length-1&&!r.typing},transact:function(e){return f(),r.beforeChange(),r.ignore(e),r.add()},ignore:function(e){try{a++,e()}finally{a--}},extra:function(t,n){var a;r.transact(t)&&(a=i[o].bookmark,$h.applyToEditor(e,i[o-1],!0),r.transact(n)&&(i[o-1].beforeBookmark=a))}}}var qh={},Uh=xt.filter,Vh=xt.each;qh.pre||(qh.pre=[]),qh.pre.push(function(e){var t,n,r=e.selection.getRng();t=Zr.matchNodeNames("pre"),r.collapsed||(n=e.selection.getSelectedBlocks(),Vh(Uh(Uh(n,t),function(e){return t(e.previousSibling)&&-1!==xt.indexOf(n,e.previousSibling)}),function(e){var t,n;t=e.previousSibling,Ut(n=e).remove(),Ut(t).append("<br><br>").append(n.childNodes)}))});var Xh=kt.each,Yh={walk:function(e,t,n){var r,o,i,a,s,u,c,l=t.startContainer,f=t.startOffset,d=t.endContainer,h=t.endOffset;if((c=e.select("td[data-mce-selected],th[data-mce-selected]")).length>0)Xh(c,function(e){n([e])});else{var p,m,g,v=function(e){var t;return 3===(t=e[0]).nodeType&&t===l&&f>=t.nodeValue.length&&e.splice(0,1),t=e[e.length-1],0===h&&e.length>0&&t===d&&3===t.nodeType&&e.splice(e.length-1,1),e},y=function(e,t,n){for(var r=[];e&&e!==n;e=e[t])r.push(e);return r},b=function(e,t){do{if(e.parentNode===t)return e;e=e.parentNode}while(e)},w=function(e,t,r){var o=r?"nextSibling":"previousSibling";for(s=(a=e).parentNode;a&&a!==t;a=s)s=a.parentNode,(u=y(a===e?a:a[o],o)).length&&(r||u.reverse(),n(v(u)))};if(1===l.nodeType&&l.hasChildNodes()&&(l=l.childNodes[f]),1===d.nodeType&&d.hasChildNodes()&&(m=h,--m>(g=(p=d).childNodes).length-1?m=g.length-1:m<0&&(m=0),d=g[m]||p),l===d)return n(v([l]));for(r=e.findCommonAncestor(l,d),a=l;a;a=a.parentNode){if(a===d)return w(l,r,!0);if(a===r)break}for(a=d;a;a=a.parentNode){if(a===l)return w(d,r);if(a===r)break}o=b(l,r)||l,i=b(d,r)||d,w(l,o,!0),(u=y(o===l?o:o.nextSibling,"nextSibling",i===d?i.nextSibling:i)).length&&n(v(u)),w(d,i)}}},Kh=/^(src|href|style)$/,Gh=kt.each,Jh=_c,Qh=function(e){return/^(TH|TD)$/.test(e.nodeName)},Zh=function(e,t,n){var r,o,i;return r=t[n?"startContainer":"endContainer"],o=t[n?"startOffset":"endOffset"],Zr.isElement(r)&&(i=r.childNodes.length-1,!n&&o&&o--,r=r.childNodes[o>i?i:o]),Zr.isText(r)&&n&&o>=r.nodeValue.length&&(r=new Rr(r,e.getBody()).next()||r),Zr.isText(r)&&!n&&0===o&&(r=new Rr(r,e.getBody()).prev()||r),r},ep=function(e,t,n,r){var o=e.create(n,r);return t.parentNode.insertBefore(o,t),o.appendChild(t),o},tp=function(e,t,n,r){return!(t=Tc(t,n,r))||"BR"===t.nodeName||e.
vendor: 6,140 bytes, line 1
1isBlock(t)},np=function(e,t,n,r,o){var i,a,s,u=e.dom;if(!function(e,t,n){return!!Jh(t,n.inline)||!!Jh(t,n.block)||(n.selector?Zr.isElement(t)&&e.is(t,n.selector):void 0)}(u,r,t)&&!function(e,t){return t.links&&"A"===e.tagName}(r,t))return!1;if("all"!==t.remove)for(Gh(t.styles,function(e,i){e=Ac(u,Rc(e,n),i),"number"==typeof i&&(i=e,o=0),(t.remove_similar||!o||Jh(Dc(u,o,i),e))&&u.setStyle(r,i,""),s=1}),s&&""===u.getAttrib(r,"style")&&(r.removeAttribute("style"),r.removeAttribute("data-mce-style")),Gh(t.attributes,function(e,t){var i;if(e=Rc(e,n),"number"==typeof t&&(t=e,o=0),!o||Jh(u.getAttrib(o,t),e)){if("class"===t&&(e=u.getAttrib(r,t))&&(i="",Gh(e.split(/\s+/),function(e){/mce\-\w+/.test(e)&&(i+=(i?" ":"")+e)}),i))return void u.setAttrib(r,t,i);"class"===t&&r.removeAttribute("className"),Kh.test(t)&&r.removeAttribute("data-mce-"+t),r.removeAttribute(t)}}),Gh(t.classes,function(e){e=Rc(e,n),o&&!u.hasClass(o,e)||u.removeClass(r,e)}),a=u.getAttribs(r),i=0;i<a.length;i++){var c=a[i].nodeName;if(0!==c.indexOf("_")&&0!==c.indexOf("data-"))return!1}return"none"!==t.remove?(function(e,t,n){var r,o=t.parentNode,i=e.dom,a=e.settings.forced_root_block;n.block&&(a?o===i.getRoot()&&(n.list_block&&Jh(t,n.list_block)||Gh(kt.grep(t.childNodes),function(t){kc(e,a,t.nodeName.toLowerCase())?r?r.appendChild(t):(r=ep(i,t,a),i.setAttribs(r,e.settings.forced_root_block_attrs)):r=0})):i.isBlock(t)&&!i.isBlock(o)&&(tp(i,t,!1)||tp(i,t.firstChild,!0,1)||t.insertBefore(i.create("br"),t.firstChild),tp(i,t,!0)||tp(i,t.lastChild,!1,1)||t.appendChild(i.create("br")))),n.selector&&n.inline&&!Jh(n.inline,t)||i.remove(t,1)}(e,r,t),!0):void 0},rp={removeFormat:np,remove:function(e,t,n,r,o){var i,a,s=e.formatter.get(t),u=s[0],c=!0,l=e.dom,f=e.selection,d=function(r){var i=function(e,t,n,r,o){var i;return Gh(Pc(e.dom,t.parentNode).reverse(),function(t){var a;i||"_start"===t.id||"_end"===t.id||(a=Qc.matchNode(e,t,n,r,o))&&!1!==a.split&&(i=t)}),i}(e,r,t,n,o);return function(e,t,n,r,o,i,a,s){var u,c,l,f,d,h,p=e.dom;if(n){for(h=n.parentNode,u=r.parentNode;u&&u!==h;u=u.parentNode){for(c=p.clone(u,!1),d=0;d<t.length;d++)if(np(e,t[d],s,c,c)){c=0;break}c&&(l&&c.appendChild(l),f||(f=c),l=c)}a.mixed&&p.isBlock(n)||(r=p.split(n,r)),l&&(o.parentNode.insertBefore(l,o),f.appendChild(o))}return r}(e,s,i,r,r,0,u,n)},h=function(t){var r,o,i,a,f;if(Zr.isElement(t)&&l.getContentEditable(t)&&(a=c,c="true"===l.getContentEditable(t),f=!0),r=kt.grep(t.childNodes),c&&!f)for(o=0,i=s.length;o<i&&!np(e,s[o],n,t,t);o++);if(u.deep&&r.length){for(o=0,i=r.length;o<i;o++)h(r[o]);f&&(c=a)}},p=function(e){var t=l.get(e?"_start":"_end"),n=t[e?"firstChild":"lastChild"];return Xs.isBookmarkNode(n)&&(n=n[e?"firstChild":"lastChild"]),Zr.isText(n)&&0===n.data.length&&(n=e?t.previousSibling||t.nextSibling:t.nextSibling||t.previousSibling),l.remove(t,!0),n},m=function(t){var n,r,o=t.commonAncestorContainer;if(t=Uc(e,t,s,!0),u.split){if((n=Zh(e,t,!0))!==(r=Zh(e,t))){if(/^(TR|TH|TD)$/.test(n.nodeName)&&n.firstChild&&(n="TR"===n.nodeName?n.firstChild.firstChild||n:n.firstChild||n),o&&/^T(HEAD|BODY|FOOT|R)$/.test(o.nodeName)&&Qh(r)&&r.firstChild&&(r=r.firstChild||r),l.isChildOf(n,r)&&n!==r&&!l.isBlock(r)&&!Qh(n)&&!Qh(r))return n=ep(l,n,"span",{id:"_start","data-mce-type":"bookmark"}),d(n),void(n=p(!0));n=ep(l,n,"span",{id:"_start","data-mce-type":"bookmark"}),r=ep(l,r,"span",{id:"_end","data-mce-type":"bookmark"}),d(n),d(r),n=p(!0),r=p()}else n=r=d(n);t.startContainer=n.parentNode?n.parentNode:n,t.startOffset=l.nodeIndex(n),t.endContainer=r.parentNode?r.parentNode:r,t.endOffset=l.nodeIndex(r)+1}Yh.walk(l,t,function(t){Gh(t,function(t){h(t),Zr.isElement(t)&&"underline"===e.dom.getStyle(t,"text-decoration")&&t.parentNode&&"underline"===Oc(l,t.parentNode)&&np(e,{deep:!1,exact:!0,inline:"span",styles:{textDecoration:"underline"}},null,t)})})};if(r)r.nodeType?((a=l.createRng()).setStartBefore(r),a.setEndAfter(r),m(a)):m(r);else if("false"!==l.getContentEditable(f.getNode()))f.isCollapsed()&&u.inline&&!l.select("td[data-mce-selected],th[data-mce-selected]").length?cl.removeCaretFormat(e,t,n,o):(i=f.getBookmark(),m(f.getRng()),f.moveToBookmark(i),u.inline&&Qc.match(e,t,n,f.getStart())&&Sc(l,f,f.getRng()),e.nodeChanged());else{r=f.getNode();for(var g=0,v=s.length;g<v&&(!s[g].ceFalseOverride||!np(e,s[g],n,r,r));g++);}}},op=kt.each,ip=function(e){return e&&1===e.nodeType&&!Xs.isBookmarkNode(e)&&!cl.isCaretNode(e)&&!Zr.isBogus(e)},ap=function(e,t){var n;for(n=e;n;n=n[t]){if(3===n.nodeType&&0!==n.nodeValue.length)return e;if(1===n.nodeType&&!Xs.isBookmarkNode(n))return n}return e},sp=function(e,t,n){var r,o,i=new Ks(e);if(t&&n&&(t=ap(t,"previousSibling"),n=ap(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),kt.each(kt.grep(n.childNodes),function(e){t.appendChild(e)}),t}return n},up=function(e,t,n){op(e.childNodes,function(e){ip(e)&&(t(e)&&n(e),e.hasChildNodes()&&up(e,t,n))})},cp=function(e,t){return p.curry(function(t,n){return!(!n||!Dc(e,n,t))},t)},lp=function(e,t,n){return p.curry(function(t,n,r){e.setStyle(r,t,n),""===r.getAttribute("style")&&r.removeAttribute("style"),fp(e,r)},t,n)},fp=function(e,t){"SPAN"===t.nodeName&&0===e.getAttribs(t).length&&e.remove(t,!0)},dp=function(e,t){var n;1===t.nodeType&&t.parentNode&&1===t.parentNode.nodeType&&(n=Oc(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))},hp=kt.each,pp=function(e,t,n,r){var o,i,a=e.formatter.get(t),s=a[0],u=!r&&e.selection.isCollapsed(),c=e.dom,l=e.selection,f=function(e,t){if(t=t||s,e){if(t.onformat&&t.onformat(e,t,n,r),hp(t.styles,function(t,r){c.setStyle(e,r,Rc(t,n))}),t.styles){var o=c.getAttrib(e,"style");o&&e.setAttribute("data-mce-style",o)}hp(t.attributes,function(t,r){c.setAttrib(e,r,Rc(t,n))}),hp(t.classes,function(t){t=Rc(t,n),c.hasClass(e,t)||c.addClass(e,t)})}},d=function(e,t){var n=!1;return!!s.selector&&(hp(e,function(e){if(!("collapsed"in e&&e.collapsed!==u))return c.is(t,e.selector)&&!cl.isCaretNode(t)?(f(t,e),n=!0,!1):void 0}),n)},h=function(r,o,i,u){var c,l,h=[],p=!0;
1l=r.create(c=s.inline||s.block),f(l),Yh.walk(r,o,function(o){var i,m=function(o){var g,v,y,b;if(b=p,g=o.nodeName.toLowerCase(),v=o.parentNode.nodeName.toLowerCase(),1===o.nodeType&&r.getContentEditable(o)&&(b=p,p="true"===r.getContentEditable(o),y=!0),_c(g,"br"))return i=0,void(s.block&&r.remove(o));if(s.wrapper&&Qc.matchNode(e,o,t,n))i=0;else{if(p&&!y&&s.block&&!s.wrapper&&Ec(e,g)&&kc(e,v,c))return o=r.rename(o,c),f(o),h.push(o),void(i=0);if(s.selector){var w=d(a,o);if(!s.inline||w)return void(i=0)}!p||y||!kc(e,c,g)||!kc(e,v,c)||!u&&3===o.nodeType&&1===o.nodeValue.length&&65279===o.nodeValue.charCodeAt(0)||cl.isCaretNode(o)||s.inline&&r.isBlock(o)?(i=0,hp(kt.grep(o.childNodes),m),y&&(p=b),i=0):(i||(i=r.clone(l,!1),o.parentNode.insertBefore(i,o),h.push(i)),i.appendChild(o))}};hp(o,m)}),!0===s.links&&hp(h,function(e){var t=function(e){"A"===e.nodeName&&f(e,s),hp(kt.grep(e.childNodes),t)};t(e)}),hp(h,function(o){var i;i=function(e){var t=0;return hp(e.childNodes,function(e){Nc(e)||Xs.isBookmarkNode(e)||t++}),t}(o),!(h.length>1)&&r.isBlock(o)||0!==i?(s.inline||s.wrapper)&&(s.exact||1!==i||(o=function(e){var t,n;return(t=function(t){var n=!1;return hp(e.childNodes,function(e){if(function(e){return e&&1===e.nodeType&&!Xs.isBookmarkNode(e)&&!cl.isCaretNode(e)&&!Zr.isBogus(e)}(e))return n=e,!1}),n}())&&!Xs.isBookmarkNode(t)&&Qc.matchName(r,t,s)&&(n=r.clone(t,!1),f(n),r.replace(n,e,!0),r.remove(t,1)),n||e}(o)),function(e,t,n,r){op(t,function(t){op(e.dom.select(t.inline,r),function(r){ip(r)&&rp.removeFormat(e,t,n,r,t.exact?r:null)}),function(e,t,n){t.clear_child_styles&&op(e.select(t.links?"*:not(a)":"*",n),function(n){ip(n)&&op(t.styles,function(t,r){e.setStyle(n,r,"")})})}(e.dom,t,r)})}(e,a,n,o),function(e,t,n,r,o){Qc.matchNode(e,o.parentNode,n,r)&&rp.removeFormat(e,t,r,o)||t.merge_with_parents&&e.dom.getParent(o.parentNode,function(i){if(Qc.matchNode(e,i,n,r))return rp.removeFormat(e,t,r,o),!0})}(e,s,t,n,o),function(e,t,n,r){t.styles&&t.styles.backgroundColor&&up(r,cp(e,"fontSize"),lp(e,"backgroundColor",Rc(t.styles.backgroundColor,n)))}(r,s,n,o),function(e,t,n,r){"sub"!==t.inline&&"sup"!==t.inline||(up(r,cp(e,"fontSize"),lp(e,"fontSize","")),e.remove(e.select("sup"===t.inline?"sub":"sup",r),!0))}(r,s,0,o),function(e,t,n,r){r&&!1!==t.merge_siblings&&(r=sp(e,Tc(r),r),r=sp(e,r,Tc(r,!0)))}(r,s,0,o)):r.remove(o,1)})};if("false"!==c.getContentEditable(l.getNode())){if(s){if(r)r.nodeType?d(a,r)||((i=c.createRng()).setStartBefore(r),i.setEndAfter(r),h(c,Uc(e,i,a),0,!0)):h(c,r,0,!0);else if(u&&s.inline&&!c.select("td[data-mce-selected],th[data-mce-selected]").length)cl.applyCaretFormat(e,t,n);else{var m=e.selection.getNode();e.settings.forced_root_block||!a[0].defaultBlock||c.getParent(m,c.isBlock)||pp(e,a[0].defaultBlock),e.selection.setRng(fu(e.selection.getRng())),o=l.getBookmark(),h(c,Uc(e,l.getRng(),a)),s.styles&&function(e,t,n,r){(t.styles.color||t.styles.textDecoration)&&(kt.walk(r,p.curry(dp,e),"childNodes"),dp(e,r))}(c,s,0,m),l.moveToBookmark(o),Sc(c,l,l.getRng()),e.nodeChanged()}!function(e,t){Vh(qh[e],function(e){e(t)})}(t,e)}}else{r=l.getNode();for(var g=0,v=a.length;g<v;g++)if(a[g].ceFalseOverride&&c.is(r,a[g].selector))return void f(r,a[g])}},mp={applyFormat:pp},gp=kt.each,vp={formatChanged:function(e,t,n,r,o){null===t.get()&&function(e,t){var n={};e.set({}),t.on("NodeChange",function(r){var o=Pc(t.dom,r.element),i={};o=kt.grep(o,function(e){return 1===e.nodeType&&!e.getAttribute("data-mce-bogus")}),gp(e.get(),function(e,r){gp(o,function(a){return t.formatter.matchNode(a,r,{},e.similar)?(n[r]||(gp(e,function(e){e(!0,{node:a,format:r,parents:o})}),n[r]=e),i[r]=e,!1):!Qc.matchesUnInheritedFormatSelector(t,a,r)&&void 0})}),gp(n,function(e,t){i[t]||(delete n[t],gp(e,function(e){e(!1,{node:r.element,format:t,parents:o})}))})})}(t,e),function(e,t,n,r){var o=e.get();gp(t.split(","),function(e){o[e]||(o[e]=[],o[e].similar=r),o[e].push(n)}),e.set(o)}(t,n,r,o)}},yp={get: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"},{inline:"span",styles:{fontWeight:"bold"}},{inline:"b",remove:"all"}],italic:[{inline:"em",remove:"all"},{inline:"span",styles:{fontStyle:"italic"}},{inline:"i",remove:"all"}],underline:[{inline:"span",styles:{textDecoration:"underline"},exact:!0},{inline:"u",remove:"all"}],strikethrough:[{inline:"span",styles:{textDecoration:"line-through"},exact:!0},{inline:"strike",remove:"all"}],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",styles:{fontFamily:"%value"},clear_child_styles:!0},fontsize:{inline:"span",styles:{fontSize:"%value"},clear_child_styles:!0},fontsize_class:{inline:"span",attributes:{class:"%value"}},blockquote:{block:"blockquote",wrapper:1,remove:"all"},subscript:{inline:"sub"},superscript:{inline:"sup"},code:{inline:"code"},link:{inline:"a",selector:"a",remove:"all",split:!0,deep:!0,onmatch:function(){return!0},onformat:function(t,n,r){kt.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 kt.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}},bp=kt.each,wp=Lo.DOM,xp=function(e,t){var n,r,o,i=t&&t.schema||Eo({}),a=function(e){var t;return function(e,t){t.classes.length&&wp.addClass(e,t.classes.join(" ")),wp.setAttribs(e,t.attrs)}(t=wp.create((r="string"==typeof e?{name:e,classes:[],attrs:{}}:e).name),r),t},s=function(e,t,n){var r,o,u,c=t.length>0&&t[0],l=c&&c.name;if(u=function(e,t){var n="string"!=typeof e?e.nodeName.toLowerCase():e,r=i.getElementRule(n),o=r&&r.parentsRequired;
vendor: 16,061 bytes, line 1
1return!(!o||!o.length)&&(t&&-1!==kt.inArray(o,t)?t:o[0])}(e,l))l===u?(o=t[0],t=t.slice(1)):o=u;else if(c)o=t[0],t=t.slice(1);else if(!n)return e;return o&&(r=a(o)).appendChild(e),n&&(r||(r=wp.create("div")).appendChild(e),kt.each(n,function(t){var n=a(t);r.insertBefore(n,e)})),s(r,t,o&&o.siblings)};return e&&e.length?(n=a(r=e[0]),(o=wp.create("div")).appendChild(s(n,e.slice(1),r.siblings)),o):""},Cp=function(e){var t,n={classes:[],attrs:{}};return"*"!==(e=n.selector=kt.trim(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":":-1!==kt.inArray("checked disabled enabled read-only required".split(" "),r)&&(n.attrs[r]=r)}if("["===o){var a=i.match(/([\w\-]+)(?:\=\"([^\"]+))?/);a&&(n.attrs[a[1]]=a[2])}return""})),n.name=t||"div",n},Sp=function(e){return e&&"string"==typeof e?(e=(e=e.split(/\s*,\s*/)[0]).replace(/\s*(~\+|~|\+|>)\s*/g,"$1"),kt.map(e.split(/(?:>|\s+(?![^\[\]]+\]))/),function(e){var t=kt.map(e.split(/(?:~\+|~|\+)/),Cp),n=t.pop();return t.length&&(n.siblings=t),n}).reverse()):[]},Tp={getCssText:function(e,t){var n,r,o,i,a,s,u="";if(!1===(s=e.settings.preview_styles))return"";"string"!=typeof s&&(s="font-family font-size font-weight font-style text-decoration text-transform color background-color border border-radius outline text-shadow");var c=function(e){return e.replace(/%(\w+)/g,"")};if("string"==typeof t){if(!(t=e.formatter.get(t)))return;t=t[0]}return"preview"in t&&!1===(s=t.preview)?"":(n=t.block||t.inline||"span",(i=Sp(t.selector)).length?(i[0].name||(i[0].name=n),n=t.selector,r=xp(i,e)):r=xp([n],e),o=wp.select(n,r)[0]||r.firstChild,bp(t.styles,function(e,t){(e=c(e))&&wp.setStyle(o,t,e)}),bp(t.attributes,function(e,t){(e=c(e))&&wp.setAttrib(o,t,e)}),bp(t.classes,function(e){e=c(e),wp.hasClass(o,e)||wp.addClass(o,e)}),e.fire("PreviewFormats"),wp.setStyles(r,{position:"absolute",left:-65535}),e.getBody().appendChild(r),a=wp.getStyle(e.getBody(),"fontSize",!0),a=/px$/.test(a)?parseInt(a,10):0,bp(s.split(" "),function(t){var n=wp.getStyle(o,t,!0);if(!("background-color"===t&&/transparent|rgba\s*\([^)]+,\s*0\)/.test(n)&&(n=wp.getStyle(e.getBody(),t,!0),"#ffffff"===wp.toHex(n).toLowerCase())||"color"===t&&"#000000"===wp.toHex(n).toLowerCase())){if("font-size"===t&&/em|%$/.test(n)){if(0===a)return;n=(n=parseFloat(n)/(/%$/.test(n)?100:1))*a+"px"}"border"===t&&n&&(u+="padding:0 2px;"),u+=t+":"+n+";"}}),e.fire("AfterPreviewFormats"),wp.remove(r),u)},parseSelector:Sp,selectorToHtml:function(e,t){return xp(Sp(e),t)}},Ep={toggle:function(e,t,n,r,o){var i=t.get(n);!Qc.match(e,n,r,o)||"toggle"in i[0]&&!i[0].toggle?mp.applyFormat(e,n,r,o):rp.remove(e,n,r,o)}},kp={setup: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"])}};function Np(e){var t=function(e){var t={},n=function(e,r){e&&("string"!=typeof e?kt.each(e,function(e,t){n(t,e)}):(kt.each(r=r.length?r:[r],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]=r))};return n(yp.get(e.dom)),n(e.settings.formats),{get:function(e){return e?t[e]:t},register:n,unregister:function(e){return e&&t[e]&&delete t[e],t}}}(e),n=Ol(null);return kp.setup(e),cl.setup(e),{get:t.get,register:t.register,unregister:t.unregister,apply:p.curry(mp.applyFormat,e),remove:p.curry(rp.remove,e),toggle:p.curry(Ep.toggle,e,t),match:p.curry(Qc.match,e),matchAll:p.curry(Qc.matchAll,e),matchNode:p.curry(Qc.matchNode,e),canApply:p.curry(Qc.canApply,e),formatChanged:p.curry(vp.formatChanged,e,n),getCssText:p.curry(Tp.getCssText,e)}}var Rp=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)i.hasOwnProperty(a)&&(r[a]=e(r[a],i[a]))}return r}},_p=Rp(function(e,t){return Hn.isObject(e)&&Hn.isObject(t)?_p(e,t):t}),Ap=Rp(function(e,t){return t}),Dp={deepMerge:_p,merge:Ap},Op={register:function(e,t,n){e.addAttributeFilter("data-mce-tabindex",function(e,t){for(var n,r=e.length;r--;)(n=e[r]).attr("tabindex",n.attributes.map["data-mce-tabindex"]),n.attr(t,null)}),e.addAttributeFilter("src,href,style",function(e,r){for(var o,i,a=e.length,s="data-mce-"+r,u=t.url_converter,c=t.url_converter_scope;a--;)void 0!==(i=(o=e[a]).attributes.map[s])?(o.attr(r,i.length>0?i:null),o.attr(s,null)):(i=o.attributes.map[r],"style"===r?i=n.serializeStyle(n.parseStyle(i),o.name):u&&(i=u.call(c,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--;)(n=(t=e[r]).attr("class"))&&(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--;)"bookmark"!==(r=e[o]).attributes.map["data-mce-type"]||n.cleanup||r.remove()}),e.addNodeFilter("noscript",function(e){for(var t,n=e.length;n--;)(t=e[n].firstChild)&&(t.value=po.decode(t.value))}),e.addNodeFilter("script,style",function(e,n){for(var r,o,i,a=e.length,s=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--;)o=(r=e[a]).firstChild?r.firstChild.value:"","script"===n?((i=r.attr("type"))&&r.attr("type","mce-no/type"===i?null:i.replace(/^mce\-/,"")),"xhtml"===t.element_format&&o.length>0&&(r.firstChild.value="// <![CDATA[\n"+s(o)+"\n// ]]>")):"xhtml"===t.element_format&&o.length>0&&(r.firstChild.value="\x3c!--\n"+s(o)+"\n--\x3e")}),e.addNodeFilter("#comment",function(e){for(var t,n=e.length;n--;)0===(t=e[n]).value.indexOf("[CDATA[")?(t.name="#cdata",t.type=4,t.value=t.value.replace(/^\[CDATA\[|\]\]$/g,"")):0===t.value.indexOf("mce:protected ")&&(t.name="#text",t.type=3,t.raw=!0,t.value=unescape(t.value).substr(14))}),e.addNodeFilter("xml:namespace,input",function(e,t){for(var n,r=e.length;r--;)7===(n=e[r]).type?n.remove():1===n.type&&("input"!==t||"type"in n.attributes.map||n.attr("type","text"))}),e.addAttributeFilter("data-mce-type",function(t){P.each(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",function(e,t){for(var n=e.length;n--;)e[n].attr(t,null)})},trimTrailingBr:function(e){var t,n,r=function(e){return e&&"br"===e.name};r(t=e.lastChild)&&r(n=t.prev)&&(t.remove(),n.remove())}},Pp={process:function(e,t,n){return function(e,t){return e&&e.hasEventListeners("PreProcess")&&!t.no_events}(e,n)?function(e,t,n){var r,o,i,a=e.dom;return t=t.cloneNode(!0),(r=document.implementation).createHTMLDocument&&(o=r.createHTMLDocument(""),kt.each("BODY"===t.nodeName?t.childNodes:[t],function(e){o.body.appendChild(o.importNode(e,!0))}),t="BODY"!==t.nodeName?o.body.firstChild:o.body,i=a.doc,a.doc=o),function(e,t){e.fire("PreProcess",t)}(e,Dp.merge(n,{node:t})),i&&(a.doc=i),t}(e,t,n):t}},Bp={register:function(e,t){t.inline_styles&&function(e,t){var n=No();t.convert_fonts_to_spans&&function(e,t,n){e.addNodeFilter("font",function(e){P.each(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)),function(e,t){P.each(["color","face","size"],function(t){e.attr(t,null)})}(e)})})}(e,n,kt.explode(t.font_size_legacy_values)),function(e,t){e.addNodeFilter("strike",function(e){P.each(e,function(e){var n=t.parse(e.attr("style"));n["text-decoration"]="line-through",e.name="span",e.attr("style",t.serialize(n))})})}(e,n)}(e,t)}},Ip=/^[ \t\r\n]*$/,Lp={"#text":3,"#comment":8,"#cdata":4,"#pi":7,"#doctype":10,"#document-fragment":11},Mp=function(e,t,n){var r,o,i=n?"lastChild":"firstChild",a=n?"prev":"next";if(e[i])return e[i];if(e!==t){if(r=e[a])return r;for(o=e.parent;o&&o!==t;o=o.parent)if(r=o[a])return r}},Hp=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,o;if(r=new e(t,Lp[t]||1),n)for(o in n)r.attr(o,n[o]);return r},e.prototype.replace=function(e){return e.parent&&e.remove(),this.insert(e,this),this.remove(),this},e.prototype.attr=function(e,t){var n,r;if("string"!=typeof e){for(r in e)this.attr(r,e[r]);return this}if(n=this.attributes){if(void 0!==t){if(null===t){if(e in n.map)for(delete n.map[e],r=n.length;r--;)if(n[r].name===e)return n=n.splice(r,1),this;return this}if(e in n.map){for(r=n.length;r--;)if(n[r].name===e){n[r].value=t;break}}else n.push({name:e,value:t});return n.map[e]=t,this}return n.map[e]}},e.prototype.clone=function(){var t,n,r,o,i,a=new e(this.name,this.type);if(r=this.attributes){for((i=[]).map={},t=0,n=r.length;t<n;t++)"id"!==(o=r[t]).name&&(i[i.length]={name:o.name,value:o.value},i.map[o.name]=o.value);a.attributes=i}return a.value=this.value,a.shortEnded=this.shortEnded,a},e.prototype.wrap=function(e){return this.parent.insert(e,this),e.append(this),this},e.prototype.unwrap=function(){var e,t;for(e=this.firstChild;e;)t=e.next,this.insert(e,this,!0),e=t;this.remove()},e.prototype.remove=function(){var e=this.parent,t=this.next,n=this.prev;return e&&(e.firstChild===this?(e.firstChild=t,t&&(t.prev=null)):n.next=t,e.lastChild===this?(e.lastChild=n,n&&(n.next=null)):t.prev=n,this.parent=this.next=this.prev=null),this},e.prototype.append=function(e){var t;return e.parent&&e.remove(),(t=this.lastChild)?(t.next=e,e.prev=t,this.lastChild=e):this.lastChild=this.firstChild=e,e.parent=this,e},e.prototype.insert=function(e,t,n){var r;return e.parent&&e.remove(),r=t.parent||this,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){var t,n=[];for(t=this.firstChild;t;t=Mp(t,this))t.name===e&&n.push(t);return n},e.prototype.empty=function(){var e,t,n;if(this.firstChild){for(e=[],n=this.firstChild;n;n=Mp(n,this))e.push(n);for(t=e.length;t--;)(n=e[t]).parent=n.firstChild=n.lastChild=n.next=n.prev=null}return this.firstChild=this.lastChild=null,this},e.prototype.isEmpty=function(e,t,n){var r,o,i=this.firstChild;if(t=t||{},i)do{if(1===i.type){if(i.attributes.map["data-mce-bogus"])continue;if(e[i.name])return!1;for(r=i.attributes.length;r--;)if("name"===(o=i.attributes[r].name)||0===o.indexOf("data-mce-bookmark"))return!1}if(8===i.type)return!1;if(3===i.type&&!Ip.test(i.value))return!1;if(3===i.type&&i.parent&&t[i.parent.name]&&Ip.test(i.value))return!1;if(n&&n(i))return!1}while(i=Mp(i,this));return!0},e.prototype.walk=function(e){return Mp(this,null,e)},e}(),Fp=function(e,t,n,r){(e.padd_empty_with_br||t.insert)&&n[r.name]?r.empty().append(new Hp("br",1)).shortEnded=!0:r.empty().append(new Hp("#text",3)).value="\xa0"},Wp=function(e){return jp(e,"#text")&&"\xa0"===e.firstChild.value},jp=function(e,t){return e&&e.firstChild&&e.firstChild===e.lastChild&&e.firstChild.name===t},$p=function(e,t,n,r){return r.isEmpty(t,n,function(t){return function(e,t){var n=e.getElementRule(t.name);return n&&n.paddEmpty}(e,t)})},zp=function(e,t){return e&&(t[e.name]||"br"===e.name)},qp=function(e,t){var n=e.schema;t.remove_trailing_brs&&e.addNodeFilter("br",function(e,r,o){var i,a,s,u,c,l,f,d,h=e.length,p=kt.extend({},n.getBlockElements()),m=n.getNonEmptyElements(),g=n.getNonEmptyElements();for(p.body=1,i=0;i<h;i++)if(s=(a=e[i]).parent,p[a.parent.name]&&a===s.lastChild){for(c=a.prev;c;){if("span"!==(l=c.name)||"bookmark"!==c.attr("data-mce-type")){if("br"!==l)break;if("br"===l){a=null;break}}c=c.prev}a&&(a.remove(),$p(n,m,g,s)&&(f=n.getElementRule(s.name))&&(f.removeEmpty?s.remove():f.paddEmpty&&Fp(t,o,p,s)))}else{for(u=a;s&&s.firstChild===u&&s.lastChild===u&&(u=s,!p[s.name]);)s=s.parent;u===s&&!0!==t.padd_empty_with_br&&((d=new Hp("#text",3)).value="\xa0",a.replace(d))}}),e.addAttributeFilter("href",function(e){var n,r,o,i=e.length;if(!t.allow_unsafe_link_target)for(;i--;)"a"===(n=e[i]).name&&"_blank"===n.attr("target")&&n.attr("rel",(o=(r=n.attr("rel"))?kt.trim(r):"",/\b(noopener)\b/g.test(o)?o:o.split(" ").filter(function(e){return e.length>0}).concat(["noopener"]).sort().join(" ")))}),t.allow_html_in_named_anchor||e.addAttributeFilter("id,name",function(e){for(var t,n,r,o,i=e.length;i--;)if("a"===(o=e[i]).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("ul"===(n=(t=e[r]).parent).name||"ol"===n.name)if(t.prev&&"li"===t.prev.name)t.prev.append(t);else{var o=new Hp("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,s,u,c=e.length,l=n.getValidClasses();c--;){for(r=(t=e[c]).attr("class").split(" "),a="",o=0;o<r.length;o++)i=r[o],u=!1,(s=l["*"])&&s[i]&&(u=!0),s=l[t.name],!u&&s&&s[i]&&(u=!0),u&&(a&&(a+=" "),a+=i);a.length||(a=null),t.attr("class",a)}})},Up=kt.makeMap,Vp=kt.each,Xp=kt.explode,Yp=kt.extend;function Kp(e,t){void 0===t&&(t=Eo());var n={},r=[],o={},i={};(e=e||{}).validate=!("validate"in e)||e.validate,e.root_name=e.root_name||"body";var a=function(e){var t,a,s;a in n&&((s=o[a])?s.push(e):o[a]=[e]),t=r.length;for(;t--;)(a=r[t].name)in e.attributes.map&&((s=i[a])?s.push(e):i[a]=[e]);return e},s={schema:t,addAttributeFilter:function(e,t){Vp(Xp(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]})})},getAttributeFilters:function(){return[].concat(r)},addNodeFilter:function(e,t){Vp(Xp(e),function(e){var r=n[e];r||(n[e]=r=[]),r.push(t)})},getNodeFilters:function(){var e=[];for(var t in n)n.hasOwnProperty(t)&&e.push({name:t,callbacks:n[t]});return e},filterNode:a,parse:function(s,u){var c,l,f,d,h,p,m,g,v,y,b,w=[];u=u||{},o={},i={},v=Yp(Up("script,style,head,html,body,title,meta,param"),t.getBlockElements());var x=t.getNonEmptyElements(),C=t.children,S=e.validate,T="forced_root_block"in u?u.forced_root_block:e.forced_root_block,E=t.getWhiteSpaceElements(),k=/^[ \t\r\n]+/,N=/[ \t\r\n]+$/,R=/[ \t\r\n]+/g,_=/^[ \t\r\n]+$/,A=function(e,t){var r,i=new Hp(e,t);return e in n&&((r=o[e])?r.push(i):o[e]=[i]),i},D=function(e){var n,r,o,i,a=t.getBlockElements();for(n=e.prev;n&&3===n.type;){if((o=n.value.replace(N,"")).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}};c=Ih({validate:S,allow_script_urls:e.allow_script_urls,allow_conditional_comments:e.allow_conditional_comments,self_closing_elements:function(e){var t,n={};for(t in e)"li"!==t&&"p"!==t&&(n[t]=e[t]);return n}(t.getSelfClosingElements()),cdata:function(e){b.append(A("#cdata",4)).value=e},text:function(e,t){var n;y||(e=e.replace(R," "),zp(b.lastChild,v)&&(e=e.replace(k,""))),0!==e.length&&((n=A("#text",3)).raw=!!t,b.append(n).value=e)},comment:function(e){b.append(A("#comment",8)).value=e},pi:function(e,t){b.append(A(e,7)).value=t,D(b)},doctype:function(e){b.append(A("#doctype",10)).value=e,D(b)},start:function(e,n,o){var a,s,u,c,l;if(u=S?t.getElementRule(e):{}
1){for((a=A(u.outputName||e,1)).attributes=n,a.shortEnded=o,b.append(a),(l=C[b.name])&&C[a.name]&&!l[a.name]&&w.push(a),s=r.length;s--;)(c=r[s].name)in n.map&&((m=i[c])?m.push(a):i[c]=[a]);v[e]&&D(a),o||(b=a),!y&&E[e]&&(y=!0)}},end:function(n){var r,o,i,a,s;if(o=S?t.getElementRule(n):{}){if(v[n]&&!y){if((r=b.firstChild)&&3===r.type)if((i=r.value.replace(k,"")).length>0)r.value=i,r=r.next;else for(a=r.next,r.remove(),r=a;r&&3===r.type;)a=r.next,(0===(i=r.value).length||_.test(i))&&(r.remove(),r=a),r=a;if((r=b.lastChild)&&3===r.type)if((i=r.value.replace(N,"")).length>0)r.value=i,r=r.prev;else for(a=r.prev,r.remove(),r=a;r&&3===r.type;)a=r.prev,(0===(i=r.value).length||_.test(i))&&(r.remove(),r=a),r=a}if(y&&E[n]&&(y=!1),o.removeEmpty&&$p(t,x,E,b)&&!b.attributes.map.name&&!b.attr("id"))return s=b.parent,v[b.name]?b.empty().remove():b.unwrap(),void(b=s);o.paddEmpty&&(Wp(b)||$p(t,x,E,b))&&Fp(e,u,v,b),b=b.parent}}},t);var O=b=new Hp(u.context||e.root_name,11);if(c.parse(s),S&&w.length&&(u.context?u.invalid=!0:function(e){var n,r,o,i,s,u,c,l,f,d,h,p,m,g,v,y;for(p=Up("tr,td,th,tbody,thead,tfoot,table"),d=t.getNonEmptyElements(),h=t.getWhiteSpaceElements(),m=t.getTextBlockElements(),g=t.getSpecialElements(),n=0;n<e.length;n++)if((r=e[n]).parent&&!r.fixed)if(m[r.name]&&"li"===r.parent.name){for(v=r.next;v&&m[v.name];)v.name="li",v.fixed=!0,r.parent.insert(v,r.parent),v=v.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(),s=u=a(i[0].clone()),f=0;f<i.length-1;f++){for(t.isValidChild(u.name,i[f].name)?(c=a(i[f].clone()),u.append(c)):c=u,l=i[f].firstChild;l&&l!==i[f+1];)y=l.next,c.append(l),l=y;u=c}$p(t,d,h,s)?o.insert(r,i[0],!0):(o.insert(s,i[0],!0),o.insert(r,s)),($p(t,d,h,o=i[0])||jp(o,"br"))&&o.empty().remove()}else if(r.parent){if("li"===r.name){if((v=r.prev)&&("ul"===v.name||"ul"===v.name)){v.append(r);continue}if((v=r.next)&&("ul"===v.name||"ul"===v.name)){v.insert(r,v.firstChild,!0);continue}r.wrap(a(new Hp("ul",1)));continue}t.isValidChild(r.parent.name,"div")&&t.isValidChild("div",r.name)?r.wrap(a(new Hp("div",1))):g[r.name]?r.empty().remove():r.unwrap()}}}(w)),T&&("body"===O.name||u.isRootContent)&&function(){var n,r,o=O.firstChild,i=function(e){e&&((o=e.firstChild)&&3===o.type&&(o.value=o.value.replace(k,"")),(o=e.lastChild)&&3===o.type&&(o.value=o.value.replace(N,"")))};if(t.isValidChild(O.name,T.toLowerCase())){for(;o;)n=o.next,3===o.type||1===o.type&&"p"!==o.name&&!v[o.name]&&!o.attr("data-mce-type")?r?r.append(o):((r=A(T,1)).attr(e.forced_root_block_attrs),O.insert(r,o),r.append(o)):(i(r),r=null),o=n;i(r)}}(),!u.invalid){for(g in o){for(m=n[g],h=(l=o[g]).length;h--;)l[h].parent||l.splice(h,1);for(f=0,d=m.length;f<d;f++)m[f](l,g,u)}for(f=0,d=r.length;f<d;f++)if((m=r[f]).name in i){for(h=(l=i[m.name]).length;h--;)l[h].parent||l.splice(h,1);for(h=0,p=m.callbacks.length;h<p;h++)m.callbacks[h](l,m.name,u)}}return O}};return qp(s,e),Bp.register(s,e),s}var Gp=function(e,t,n){-1===kt.inArray(t,n)&&(e.addAttributeFilter(n,function(e,t){for(var n=e.length;n--;)e[n].attr(t,null)}),t.push(n))},Jp=function(e,t,n){var r=qo(n.getInner?t.innerHTML:e.getOuterHTML(t));return n.selection?r:kt.trim(r)},Qp=function(e,t,n,r){var o=r.selection?Dp.merge({forced_root_block:!1},r):r,i=e.parse(n,o);return Op.trimTrailingBr(i),i},Zp=function(e,t,n,r,o){return function(e,t,n){return!t.no_events&&e?function(e,t){return e.fire("PostProcess",t)}(e,Dp.merge(t,{content:n})).content:n}(e,o,function(e,t,n){return lu(e,t).serialize(n)}(t,n,r))};function em(e,t){var n=function(e,t){var n,r,o,i=["data-mce-selected"];return n=t&&t.dom?t.dom:Lo.DOM,r=t&&t.schema?t.schema:Eo(e),e.entity_encoding=e.entity_encoding||"named",e.remove_trailing_brs=!("remove_trailing_brs"in e)||e.remove_trailing_brs,o=Kp(e,r),Op.register(o,e,n),{schema:r,addNodeFilter:o.addNodeFilter,addAttributeFilter:o.addAttributeFilter,serialize:function(i,a){var s=Dp.merge({format:"html"},a||{}),u=Pp.process(t,i,s),c=Jp(n,u,s),l=Qp(o,n,c,s);return"tree"===s.format?l:Zp(t,e,r,l,s)},addRules:function(e){r.addValidElements(e)},setRules:function(e){r.setValidElements(e)},addTempAttr:p.curry(Gp,o,i),getTempAttrs:function(){return i}}}(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}}var tm=function(e,t){t.hasAttribute("data-mce-caret")&&(ti(t),function(e){e.selection.setRng(e.selection.getRng())}(e),e.selection.scrollIntoView(t))},nm=function(e,t){var n=function(e){return Pu(_n(e.getBody()),"*[data-mce-caret]").fold(p.constant(null),function(e){return e.dom()})}(e);if(n)return"compositionstart"===t.type?(t.preventDefault(),t.stopPropagation(),void tm(e,n)):void(Go(n)&&tm(e,n))};function rm(e){return{getBookmark:p.curry(Xs.getBookmark,e),moveToBookmark:p.curry(Xs.moveToBookmark,e)}}!function(e){e.isBookmarkNode=Xs.isBookmarkNode}(rm||(rm={}));var om=rm,im=Zr.isContentEditableFalse,am=Zr.isContentEditableTrue,sm=function(e,t){var n,r,o,i,a,s,u,c,l,f,d,h,p,m,g,v,y,b=t.dom,w=kt.each,x=t.getDoc(),C=document,S=Math.abs,T=Math.round,E=t.getBody();i={nw:[0,0,-1,-1],ne:[1,0,1,-1],se:[1,1,1,1],sw:[0,1,-1,1]};var k=".mce-content-body";t.contentStyles.push(k+" div.mce-resizehandle {position: absolute;border: 1px solid black;box-sizing: content-box;background: #FFF;width: 7px;height: 7px;z-index: 10000}"+k+" .mce-resizehandle:hover {background: #000}"+k+" img[data-mce-selected],"+k+" hr[data-mce-selected] {outline: 1px solid black;resize: none}"+k+" .mce-clonedresizable {position: absolute;"+(ae.gecko?"":"outline: 1px dashed black;")+"opacity: .5;filter: alpha(opacity=50);z-index: 10000}"+k+" .mce-resize-helper {background: #555;background: rgba(0,0,0,0.75);border-radius: 3px;border: 1px;color: white;display: none;font-family: sans-serif;font-size: 12px;white-space: nowrap;line-height: 14px;margin: 5px 10px;padding: 5px;position: absolute;z-index: 10001}");var N=function(e){return e&&("IMG"===e.nodeName||t.dom.is(e,"figure.image"))},R=function(e){var n=e.target;(function(e,t){return N(e.target)&&!Ch(e.clientX,e.clientY,t)})(e,t.selection.getRng())&&!e.isDefaultPrevented()&&(e.preventDefault(),t.selection.select(n))},_=function(e){return t.dom.is(e,"figure.image")?e.querySelector("img"):e},A=function(e){var n=t.settings.object_resizing;return!1!==n&&!ae.iOS&&("string"!=typeof n&&(n="table,img,figure.image,div"),"false"!==e.getAttribute("data-mce-resize")&&e!==t.getBody()&&nr.is(_n(e),n))},D=function(e){var i,w,x,C;g=(w=e.screenY-u)*a[3]+d,m=(m=(i=e.screenX-s)*a[2]+f)<5?5:m,g=g<5?5:g,(N(n)&&!1!==t.settings.resize_img_proportional?!Th.modifierPressed(e):Th.modifierPressed(e)||N(n)&&a[2]*a[3]!=0)&&(S(i)>
vendor: 6,695 bytes, line 1
1S(w)?(g=T(m*h),m=T(g/h)):(m=T(g/h),g=T(m*h))),b.setStyles(_(r),{width:m,height:g}),C=a.startPos.y+w,b.setStyles(o,{left:x=(x=a.startPos.x+i)>0?x:0,top:C=C>0?C:0,display:"block"}),o.innerHTML=m+" × "+g,a[2]<0&&r.clientWidth<=m&&b.setStyle(r,"left",c+(f-m)),a[3]<0&&r.clientHeight<=g&&b.setStyle(r,"top",l+(d-g)),(i=E.scrollWidth-v)+(w=E.scrollHeight-y)!=0&&b.setStyles(o,{left:x-i,top:C-w}),p||(t.fire("ObjectResizeStart",{target:n,width:f,height:d}),p=!0)},O=function(){p=!1;var e=function(e,r){r&&(n.style[e]||!t.schema.isValid(n.nodeName.toLowerCase(),e)?b.setStyle(_(n),e,r):b.setAttrib(_(n),e,r))};e("width",m),e("height",g),b.unbind(x,"mousemove",D),b.unbind(x,"mouseup",O),C!==x&&(b.unbind(C,"mousemove",D),b.unbind(C,"mouseup",O)),b.remove(r),b.remove(o),P(n),t.fire("ObjectResized",{target:n,width:m,height:g}),b.setAttrib(n,"style",b.getAttrib(n,"style")),t.nodeChanged()},P=function(e){var p,S,T,k,N;B(),M(),p=b.getPos(e,E),c=p.x,l=p.y,N=e.getBoundingClientRect(),S=N.width||N.right-N.left,T=N.height||N.bottom-N.top,n!==e&&(n=e,m=g=0),k=t.fire("ObjectSelected",{target:e}),A(e)&&!k.isDefaultPrevented()?w(i,function(e,t){var i;(i=b.get("mceResizeHandle"+t))&&b.remove(i),i=b.add(E,"div",{id:"mceResizeHandle"+t,"data-mce-bogus":"all",class:"mce-resizehandle",unselectable:!0,style:"cursor:"+t+"-resize; margin:0; padding:0"}),ae.ie&&(i.contentEditable=!1),b.bind(i,"mousedown",function(t){t.stopImmediatePropagation(),t.preventDefault(),function(t){s=t.screenX,u=t.screenY,f=_(n).clientWidth,d=_(n).clientHeight,h=d/f,a=e,e.startPos={x:S*e[0]+c,y:T*e[1]+l},v=E.scrollWidth,y=E.scrollHeight,r=n.cloneNode(!0),b.addClass(r,"mce-clonedresizable"),b.setAttrib(r,"data-mce-bogus","all"),r.contentEditable=!1,r.unSelectabe=!0,b.setStyles(r,{left:c,top:l,margin:0}),r.removeAttribute("data-mce-selected"),E.appendChild(r),b.bind(x,"mousemove",D),b.bind(x,"mouseup",O),C!==x&&(b.bind(C,"mousemove",D),b.bind(C,"mouseup",O)),o=b.add(E,"div",{class:"mce-resize-helper","data-mce-bogus":"all"},f+" × "+d)}(t)}),e.elm=i,b.setStyles(i,{left:S*e[0]+c-i.offsetWidth/2,top:T*e[1]+l-i.offsetHeight/2})}):B(),n.setAttribute("data-mce-selected","1")},B=function(){var e,t;for(e in M(),n&&n.removeAttribute("data-mce-selected"),i)(t=b.get("mceResizeHandle"+e))&&(b.unbind(t),b.remove(t))},I=function(n){var r,o=function(e,t){if(e)do{if(e===t)return!0}while(e=e.parentNode)};p||t.removed||(w(b.select("img[data-mce-selected],hr[data-mce-selected]"),function(e){e.removeAttribute("data-mce-selected")}),r="mousedown"===n.type?n.target:e.getNode(),o(r=b.$(r).closest("table,img,figure.image,hr")[0],E)&&(H(),o(e.getStart(!0),r)&&o(e.getEnd(!0),r))?P(r):B())},L=function(e){return im(function(e,t){for(;t&&t!==e;){if(am(t)||im(t))return t;t=t.parentNode}return null}(t.getBody(),e))},M=function(){for(var e in i){var t=i[e];t.elm&&(b.unbind(t.elm),delete t.elm)}},H=function(){try{t.getDoc().execCommand("enableObjectResizing",!1,!1)}catch(e){}};return t.on("init",function(){H(),ae.ie&&ae.ie>=11&&(t.on("mousedown click",function(e){var n=e.target,r=n.nodeName;p||!/^(TABLE|IMG|HR)$/.test(r)||L(n)||(2!==e.button&&t.selection.select(n,"TABLE"===r),"mousedown"===e.type&&t.nodeChanged())}),t.dom.bind(E,"mscontrolselect",function(e){var n=function(e){fe.setEditorTimeout(t,function(){t.selection.select(e)})};if(L(e.target))return e.preventDefault(),void n(e.target);/^(TABLE|IMG|HR)$/.test(e.target.nodeName)&&(e.preventDefault(),"IMG"===e.target.tagName&&n(e.target))}));var e=fe.throttle(function(e){t.composing||I(e)});t.on("nodechange ResizeEditor ResizeWindow drop FullscreenStateChanged",e),t.on("keyup compositionend",function(t){n&&"TABLE"===n.nodeName&&e(t)}),t.on("hide blur",B),t.on("contextmenu",R)}),t.on("remove",M),{isResizable:A,showResizeRect:P,hideResizeRect:B,updateResizeRect:I,destroy:function(){n=r=null}}},um=function(e){for(var t=0,n=0,r=e;r&&r.nodeType;)t+=r.offsetLeft||0,n+=r.offsetTop||0,r=r.offsetParent;return{x:t,y:n}},cm=function(e){return Zr.isContentEditableTrue(e)||Zr.isContentEditableFalse(e)},lm=function(e,t,n){var r,o,i=n;if(i.caretPositionFromPoint)(o=i.caretPositionFromPoint(e,t))&&((r=n.createRange()).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(o){r=function(e,t,n){var r,o,i;if(r=n.elementFromPoint(e,t),o=n.body.createTextRange(),r&&"HTML"!==r.tagName||(r=n.body),o.moveToElementText(r),(i=(i=kt.toArray(o.getClientRects())).sort(function(e,n){return(e=Math.abs(Math.max(e.top-t,e.bottom-t)))-Math.abs(Math.max(n.top-t,n.bottom-t))})).length>0){t=(i[0].bottom+i[0].top)/2;try{return o.moveToPoint(e,t),o.collapse(!0),o}catch(e){}}return null}(e,t,n)}return function(e,t){var n=e&&e.parentElement?e.parentElement():null;return Zr.isContentEditableFalse(function(e,t,n){for(;e&&e!==t;){if(n(e))return e;e=e.parentNode}return null}(n,t,cm))?null:e}(r,n.body)}return r},fm=function(e,t){return P.map(t,function(t){var n=e.fire("GetSelectionRange",{range:t});return n.range!==t?n.range:t})},dm=function(e,t){return _n(e.dom().cloneNode(t))},hm=function(e){return dm(e,!1)},pm=function(e){return dm(e,!0)},mm=function(e,t){var n=(t||document).createDocumentFragment();return P.each(e,function(e){n.appendChild(e.dom())}),_n(n)},gm=function(e){return(t=e,ur(t,0)).fold(p.constant([e]),function(t){return[e].concat(gm(t))});var t},vm=function(e){return vr(e).fold(p.constant([e]),function(t){return"br"===Ln.name(t)?hr(t).map(function(t){return[e].concat(vm(t))}).getOr([]):[e].concat(vm(t))})},ym=function(e,t,n,r){var o=n,i=new Rr(n,o),a=e.schema.getNonEmptyElements();do{if(3===n.nodeType&&0!==kt.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));if(ae.ie&&ae.ie<11&&e.isBlock(n)&&e.isEmpty(n))return void(r?t.setStart(n,0):t.setEnd(n,0))}while(n=r?i.next():i.prev());"BODY"===o.nodeName&&(r?t.setStart(o,0):t.setEnd(o,o.childNodes.length))},bm=er("element","width","rows"),wm=er("element","cells"),xm=er("x","y"),Cm=function(e,t){var n=parseInt(Yn(e,t),10);return isNaN(n)?1:n},Sm=function(e,t,n){var r=e.rows();return!!(r[n]?r[n].cells():[])[t]},Tm=function(e){return P.foldl(e,function(e,t){return t.cells().length>e?t.cells().length:e},0)},Em=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(ir.eq(o[i],t))return w.some(xm(i,r));return w.none()},km=function(e,t,n,r,o){for(var i=[],a=e.rows(),s=n;s<=o;s++){var u=a[s].cells(),c=t<r?u.slice(t,r+1):u.slice(r,t+1);
1i.push(wm(a[s].element(),c))}return i},Nm=function(){return mm([])},Rm=function(e,t){return n=_n(t.cloneContents()),r=function(e,t){var n=_n(t.commonAncestorContainer),r=qu(n,e),o=P.filter(r,function(e){return Ir(e)||Pr(e)}),i=function(e,t){return P.find(e,function(e){return"li"===Ln.name(e)&&function(e,t){return da([function(e){var t=e.startContainer,n=e.startOffset;return Zr.isText(t)?0===n?w.some(_n(t)):w.none():w.from(t.childNodes[n]).map(_n)}(t),function(e){var t=e.endContainer,n=e.endOffset;return Zr.isText(t)?n===t.data.length?w.some(_n(t)):w.none():w.from(t.childNodes[n-1]).map(_n)}(t)],function(t,n){var r=P.find(gm(e),p.curry(ir.eq,t)),o=P.find(vm(e),p.curry(ir.eq,n));return r.isSome()&&o.isSome()}).getOr(!1)}(e,t)}).fold(p.constant([]),function(t){return function(e){return P.find(e,function(e){return"ul"===Ln.name(e)||"ol"===Ln.name(e)})}(e).map(function(e){return[Nn("li"),Nn(Ln.name(e))]}).getOr([])})}(r,t),a=o.concat(i.length?i:function(e){return Fr(e)?fr(e).filter(Hr).fold(p.constant([]),function(t){return[e,t]}):Hr(e)?[e]:[]}(n));return P.map(a,hm)}(e,t),o=P.foldl(r,function(e,t){return eu(t,e),t},n),r.length>0?mm([o]):o;var n,r,o},_m=function(e,t){var n,r=e.selection.getRng(),o=e.dom.create("body"),i=e.selection.getSel(),a=fm(e,Ql(i));if((t=t||{}).get=!0,t.format=t.format||"html",t.selection=!0,(t=e.fire("BeforeGetContent",t)).isDefaultPrevented())return e.fire("GetContent",t),t.content;if("text"===t.format)return e.selection.isCollapsed()?"":qo(r.text||(i.toString?i.toString():""));r.cloneContents?(n=t.contextual?function(e,t){var n=ef(t,e);return n.length>0?function(e,t){return(n=e,r=t[0],Ou(r,"table",p.curry(ir.eq,n))).bind(function(e){var n,r,o,i=t[0],a=t[t.length-1],s=function(e){var t=bm(hm(e),0,[]);return P.each(Ea(e,"tr"),function(e,n){P.each(Ea(e,"td,th"),function(r,o){!function(e,t,n,r,o){for(var i=Cm(o,"rowspan"),a=Cm(o,"colspan"),s=e.rows(),u=n;u<n+i;u++){s[u]||(s[u]=wm(pm(r),[]));for(var c=t;c<t+a;c++)s[u].cells()[c]=u===n&&c===t?o:hm(o)}}(t,function(e,t,n){for(;Sm(e,t,n);)t++;return t}(t,o,n),n,e,r)})}),bm(t.element(),Tm(t.rows()),t.rows())}(e);return(n=s,r=i,o=a,Em(n,r).bind(function(e){return Em(n,o).map(function(t){return function(e,t,n){var r=t.x(),o=t.y(),i=n.x(),a=n.y(),s=o<a?km(e,r,o,i,a):km(e,r,a,i,o);return bm(e.element(),Tm(s),s)}(n,e,t)})})).map(function(e){return mm([(t=e,function(e,t){var n=hm(e.element()),r=Nn("tbody");return tu(r,t),eu(n,r),n}(t,function(e){return P.map(e.rows(),function(e){var t=P.map(e.cells(),function(e){var t=pm(e);return Kn(t,"colspan"),Kn(t,"rowspan"),t}),n=hm(e.element());return tu(n,t),n})}(t)))]);var t})}).getOrThunk(Nm);var n,r}(e,n):function(e,t){return t.length>0&&t[0].collapsed?Nm():Rm(e,t[0])}(e,t)}(_n(e.getBody()),a).dom():r.cloneContents())&&o.appendChild(n):void 0!==r.item||void 0!==r.htmlText?(o.innerHTML="<br>"+(r.item?r.item(0).outerHTML:r.htmlText),o.removeChild(o.firstChild)):o.innerHTML=r.toString(),t.getInner=!0;var s=e.selection.serializer.serialize(o,t);return"tree"===t.format?s:(t.content=e.selection.isCollapsed()?"":s,e.fire("GetContent",t),t.content)},Am=function(e,t,n,r,o){var i=n?t.startOffset:t.endOffset;return w.from(n?t.startContainer:t.endContainer).map(_n).map(function(e){return r&&t.collapsed?e:gr(e,o(e,i)).getOr(e)}).bind(function(e){return Ln.isElement(e)?w.some(e):fr(e)}).map(function(e){return e.dom()}).getOr(e)},Dm=function(e,t,n){return Am(e,t,!0,n,function(e,t){return Math.min(e.dom().childNodes.length,t)})},Om=function(e,t,n){return Am(e,t,!1,n,function(e,t){return t>0?t-1:t})},Pm=function(e,t){for(var n=e;e&&Zr.isText(e)&&0===e.length;)e=t?e.nextSibling:e.previousSibling;return e||n},Bm=kt.each,Im=function(e){return!!e.select},Lm=function(e){return!(!e||!e.ownerDocument)&&ir.contains(_n(e.ownerDocument),_n(e))},Mm=function(e,t,n,r){var o,i,a,s,u,c=function(e,t){return function(e,t,n){var r,o,i,a=e.selection.getRng(),s=e.getDoc();if((n=n||{format:"html"}).set=!0,n.selection=!0,n.content=t,n.no_events||!(n=e.fire("BeforeSetContent",n)).isDefaultPrevented()){if(t=n.content,a.insertNode){t+='<span id="__caret">_</span>',a.startContainer===s&&a.endContainer===s?s.body.innerHTML=t:(a.deleteContents(),0===s.body.childNodes.length?s.body.innerHTML=t:a.createContextualFragment?a.insertNode(a.createContextualFragment(t)):(o=s.createDocumentFragment(),i=s.createElement("div"),o.appendChild(i),i.outerHTML=t,a.insertNode(o))),r=e.dom.get("__caret"),(a=s.createRange()).setStartBefore(r),a.setEndBefore(r),e.selection.setRng(a),e.dom.remove("__caret");try{e.selection.setRng(a)}catch(e){}}else a.item&&(s.execCommand("Delete",!1,null),a=e.getRng()),/^\s+/.test(t)?(a.pasteHTML('<span id="__mce_tmp">_</span>'+t),e.dom.remove("__mce_tmp")):a.pasteHTML(t);n.no_events||e.fire("SetContent",n)}else e.fire("SetContent",n)}(r,e,t)},l=function(e){var t=d();t.collapse(!!e),h(t)},f=function(){return t.getSelection?t.getSelection():t.document.selection},d=function(){var n,o,i,u,c=function(e,t,n){try{return t.compareBoundaryPoints(e,n
1)}catch(e){return-1}};if(!t)return null;if("undefined"==typeof(u=t.document)||null===u)return null;if(void 0!==r.bookmark&&!1===Ed(r)){var l=Xf.getRng(r);if(l.isSome())return l.map(function(e){return fm(r,[e])[0]}).getOr(u.createRange())}try{(n=f())&&(o=n.rangeCount>0?n.getRangeAt(0):n.createRange?n.createRange():u.createRange())}catch(e){}return(o=fm(r,[o])[0])||(o=u.createRange?u.createRange():u.body.createTextRange()),o.setStart&&9===o.startContainer.nodeType&&o.collapsed&&(i=e.getRoot(),o.setStart(i,0),o.setEnd(i,0)),a&&s&&(0===c(o.START_TO_START,o,a)&&0===c(o.END_TO_END,o,a)?o=s:(a=null,s=null)),o},h=function(e,t){var n,o;if(function(e){return!!e&&(!!Im(e)||Lm(e.startContainer)&&Lm(e.endContainer))}(e)){var i=Im(e)?e:null;if(i){s=null;try{i.select()}catch(e){}}else{if(n=f(),e=r.fire("SetSelectionRange",{range:e,forward:t}).range,n){s=e;try{n.removeAllRanges(),n.addRange(e)}catch(e){}!1===t&&n.extend&&(n.collapse(e.endContainer,e.endOffset),n.extend(e.startContainer,e.startOffset)),a=n.rangeCount>0?n.getRangeAt(0):null}e.collapsed||e.startContainer!==e.endContainer||!n.setBaseAndExtent||ae.ie||e.endOffset-e.startOffset<2&&e.startContainer.hasChildNodes()&&(o=e.startContainer.childNodes[e.startOffset])&&"IMG"===o.tagName&&(n.setBaseAndExtent(e.startContainer,e.startOffset,e.endContainer,e.endOffset),n.anchorNode===e.startContainer&&n.focusNode===e.endContainer||n.setBaseAndExtent(o,0,o,1)),r.fire("AfterSetSelectionRange",{range:e,forward:t})}}},p=function(){var t,n,r=f();return!(r&&r.anchorNode&&r.focusNode)||((t=e.createRng()).setStart(r.anchorNode,r.anchorOffset),t.collapse(!0),(n=e.createRng()).setStart(r.focusNode,r.focusOffset),n.collapse(!0),t.compareBoundaryPoints(t.START_TO_START,n)<=0)},m={bookmarkManager:null,controlSelection:null,dom:e,win:t,serializer:n,editor:r,collapse:l,setCursorLocation:function(t,n){var o=e.createRng();t?(o.setStart(t,n),o.setEnd(t,n),h(o),l(!1)):(ym(e,o,r.getBody(),!0),h(o))},getContent:function(e){return _m(r,e)},setContent:c,getBookmark:function(e,t){return o.getBookmark(e,t)},moveToBookmark:function(e){return o.moveToBookmark(e)},select:function(t,n){return function(e,t,n){return w.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&&(ym(e,o,t,!0),ym(e,o,t,!1)),o})}(e,t,n).each(h),t},isCollapsed:function(){var e=d(),t=f();return!(!e||e.item)&&(e.compareEndPoints?0===e.compareEndPoints("StartToEnd",e):!t||e.collapsed)},isForward:p,setNode:function(t){return c(e.getOuterHTML(t)),t},getNode:function(){return e=r.getBody(),(t=d())?(o=t.startContainer,i=t.endContainer,a=t.startOffset,s=t.endOffset,n=t.commonAncestorContainer,!t.collapsed&&(o===i&&s-a<2&&o.hasChildNodes()&&(n=o.childNodes[a]),3===o.nodeType&&3===i.nodeType&&(o=o.length===a?Pm(o.nextSibling,!0):o.parentNode,i=0===s?Pm(i.previousSibling,!1):i.parentNode,o&&o===i))?o:n&&3===n.nodeType?n.parentNode:n):e;var e,t,n,o,i,a,s},getSel:f,setRng:h,getRng:d,getStart:function(e){return Dm(r.getBody(),d(),e)},getEnd:function(e){return Om(r.getBody(),d(),e)},getSelectedBlocks:function(t,n){return function(e,t,n,r){var o,i,a=[];if(i=e.getRoot(),n=e.getParent(n||Dm(i,t,!1),e.isBlock),r=e.getParent(r||Om(i,t,!1),e.isBlock),n&&n!==i&&a.push(n),n&&r&&n!==r){o=n;for(var s=new Rr(n,i);(o=s.next())&&o!==r;)e.isBlock(o)&&a.push(o)}return r&&n!==r&&r!==i&&a.push(r),a}(e,d(),t,n)},normalize:function(){var t,n=d();if(t=f(),!(Jl(t).length>1)){var r=xf.normalize(e,n);return r.each(function(e){h(e,p())}),r.getOr(n)}return n},selectorChanged:function(t,n){var o;return u||(u={},o={},r.on("NodeChange",function(t){var n=t.element,r=e.getParents(n,null,e.getRoot()),i={};Bm(u,function(t,n){Bm(r,function(a){if(e.is(a,n))return o[n]||(Bm(t,function(e){e(!0,{node:a,selector:n,parents:r})}),o[n]=t),i[n]=t,!1})}),Bm(o,function(e,t){i[t]||(delete o[t],Bm(e,function(e){e(!1,{node:n,selector:t,parents:r})}))})})),u[t]||(u[t]=[]),u[t].push(n),m},getScrollContainer:function(){for(var t,n=e.getRoot();n&&"BODY"!==n.nodeName;){if(n.scrollHeight>n.clientHeight){t=n;break}n=n.parentNode}return t},scrollIntoView:function(e,t){return function(e,t,n){var r,o,i,a,s=e.dom,u=s.getRoot(),c=0;
1if(!function(e,t,n){var r={elm:t,alignToTop:n};return e.fire("scrollIntoView",r),r.isDefaultPrevented()}(e,t,n)&&Zr.isElement(t)){if(!1===n&&(c=t.offsetHeight),"BODY"!==u.nodeName){var l=e.selection.getScrollContainer();if(l)return r=um(t).y-um(l).y+c,a=l.clientHeight,void((r<(i=l.scrollTop)||r+25>i+a)&&(l.scrollTop=r<i?r:r-a+25))}o=s.getViewPort(e.getWin()),r=s.getPos(t).y+c,i=o.y,a=o.h,(r<o.y||r+25>i+a)&&e.getWin().scrollTo(0,r<i?r:r-a+25)}}(r,e,t)},placeCaretAt:function(e,t){return h(lm(e,t,r.getDoc()))},getBoundingClientRect:function(){var e=d();return e.collapsed?Ui.fromRangeStart(e).getClientRects()[0]:e.getBoundingClientRect()},destroy:function(){t=null,i.destroy()}};return o=om(m),i=sm(m,r),m.bookmarkManager=o,m.controlSelection=i,m},Hm=Zr.isContentEditableFalse,Fm=yi,Wm=cs,jm=us,$m=function(e,t){for(;t=e(t);)if(t.isVisible())return t;return t},zm=function(e,t,n){var r,o,i=Cs(e.getBody()),a=Ti.curry($m,i.next),s=Ti.curry($m,i.prev);if(n.collapsed&&e.settings.forced_root_block){if(!(r=e.dom.getParent(n.startContainer,"PRE")))return;(1===t?a(Ui.fromRangeStart(n)):s(Ui.fromRangeStart(n)))||(o=function(e){var t=e.dom.create(e.settings.forced_root_block);return(!ae.ie||ae.ie>=11)&&(t.innerHTML='<br data-mce-bogus="1">'),t}(e),1===t?e.$(r).after(o):e.$(r).before(o),e.selection.select(o,!0),e.selection.collapse())}},qm=function(e,t){return function(){var n=function(e,t){var n,r=Cs(e.getBody()),o=Ti.curry($m,r.next),i=Ti.curry($m,r.prev),a=t?ha.Forwards:ha.Backwards,s=t?o:i,u=e.selection.getRng();return(n=function(e,t,n,r){var o,i,a,s,u,c,l=e===ha.Forwards,f=l?jm:Wm;return!r.collapsed&&(o=Fm(r),Hm(o))?ua(e,t,o,e===ha.Backwards):(s=function(e){return Xo(e.startContainer)}(r),f(i=ss(e,t.getBody(),r))?ca(t,i.getNode(!l)):(i=n(i))?f(i)?ua(e,t,i.getNode(!l),l):f(a=n(i))&&(!(c=Ga(u=i,a))&&Zr.isBr(u.getNode())||c)?ua(e,t,a.getNode(!l),l):s?fa(t,i.toRange()):null:s?r:null)}(a,e,s,u))?n:(n=zm(e,a,u))||null}(e,t);return!!n&&(e.selection.setRng(n),!0)}},Um=function(e,t){return function(){var n=function(e,t){var n,r=t?1:-1,o=t?dh:fh,i=e.selection.getRng();return(n=function(e,t,n,r){var o,i,a,s,u,c,l,f,d;if(d=Fm(r),o=ss(e,t.getBody(),r),i=n(t.getBody(),hh(1),o),a=xt.filter(i,ph(1)),u=xt.last(o.getClientRects()),(jm(o)||ls(o))&&(d=o.getNode()),(Wm(o)||fs(o))&&(d=o.getNode(!0)),!u)return null;if((s=wh(a,c=u.left))&&Hm(s.node))return l=Math.abs(c-s.left),f=Math.abs(c-s.right),ua(e,t,s.node,l<f);if(d){var h=function(e,t,n,r){var o,i,a,s,u,c,l=Cs(t),f=[],d=0,h=function(e){return xt.last(e.getClientRects())};1===e?(o=l.next,i=vi,a=gi,s=Ui.after(r)):(o=l.prev,i=gi,a=vi,s=Ui.before(r)),c=h(s);do{if(s.isVisible()&&!a(u=h(s),c)){if(f.length>0&&i(u,xt.last(f))&&d++,(u=hi(u)).position=s,u.line=d,n(u))return f;f.push(u)}}while(s=o(s));return f}(e,t.getBody(),hh(1),d);if(s=wh(xt.filter(h,ph(1)),c))return fa(t,s.position.toRange());if(s=xt.last(xt.filter(h,ph(0))))return fa(t,s.position.toRange())}}(r,e,o,i))?n:(n=zm(e,r,i))||null}(e,t);return!!n&&(e.selection.setRng(n),!0)}},Vm=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,r)}},Xm=function(e,t){return P.find(function(e,t){return P.bind(function(e){return P.map(e,function(e){return Dp.merge({shiftKey:!1,altKey:!1,ctrlKey:!1,metaKey:!1,keyCode:0,action:p.noop},e)})}(e),function(e){return function(e,t){return t.keyCode===e.keyCode&&t.shiftKey===e.shiftKey&&t.altKey===e.altKey&&t.ctrlKey===e.ctrlKey&&t.metaKey===e.metaKey}(e,t)?[e]:[]})}(e,t),function(e){return e.action()})},Ym=function(e){return 1===mr(e).length},Km=function(e,t){return!!e.selection.isCollapsed()&&function(e,t){var n=_n(e.getBody()),r=_n(e.selection.getStart()),o=P.filter(function(e,t){var n=qu(t,e);return P.findIndex(n,Br).fold(p.constant(n),function(e){return n.slice(0,e)})}(n,r),Ym);return P.last(o).map(function(n){var r=Ui.fromRangeStart(e.selection.getRng());return!!function(e,t,n){return da([ia.firstPositionIn(n),ia.lastPositionIn(n)],function(r,o){var i=Ru.normalizePosition(!0,r),a=Ru.normalizePosition(!1,o),s=Ru.normalizePosition(!1,t);return e?ia.nextPosition(n,s).map(function(e){return e.isEqual(a)&&t.isEqual(i)}).getOr(!1):ia.prevPosition(n,s).map(function(e){return e.isEqual(i)&&t.isEqual(a)}).getOr(!1)}).getOr(!0)}(t,r,n.dom())&&(function(e,t,n,r){var o=p.curry(cl.isFormatElement,t),i=P.map(P.filter(r,o),function(e){return e.dom()});if(0===i.length)uc(t,e,n);else{var a=cl.replaceWithCaretFormat(n.dom(),i);t.selection.setRng(a.toRange())}}(t,e,n,o),!0)}).getOr(!1)}(e,t)},Gm=function(e,t,n){var r=e.getParam(t,n);if(-1!==r.indexOf("=")){var o=e.getParam(t,"","hash");return o.hasOwnProperty(e.id)?o[e.id]:n}return r},Jm=function(e){return e.getParam("content_security_policy","")},Qm=function(e){if(e.getParam("force_p_newlines",!1))return"p";var t=e.getParam("forced_root_block","p");return!1===t?"":t},Zm=function(e){return w.from(e.dom.getParent(e.selection.getStart(!0),e.dom.isBlock))},eg=function(e,t){var n,r,o,i=t,a=e.dom,s=e.schema.getMoveCaretBeforeOnEnterElements();
1if(t){if(/^(LI|DT|DD)$/.test(t.nodeName)){var u=function(e){for(;e;){if(1===e.nodeType||3===e.nodeType&&e.data&&/[\r\n\s]/.test(e.data))return e;e=e.nextSibling}}(t.firstChild);u&&/^(UL|OL|DL)$/.test(u.nodeName)&&t.insertBefore(a.doc.createTextNode("\xa0"),t.firstChild)}if(o=a.createRng(),t.normalize(),t.hasChildNodes()){for(n=new Rr(t,t);r=n.current();){if(Zr.isText(r)){o.setStart(r,0),o.setEnd(r,0);break}if(s[r.nodeName.toLowerCase()]){o.setStartBefore(r),o.setEndBefore(r);break}i=r,r=n.next()}r||(o.setStart(i,0),o.setEnd(i,0))}else Zr.isBr(t)?t.nextSibling&&a.isBlock(t.nextSibling)?(o.setStartBefore(t),o.setEndBefore(t)):(o.setStartAfter(t),o.setEndAfter(t)):(o.setStart(t,0),o.setEnd(t,0));e.selection.setRng(o),a.remove(void 0),e.selection.scrollIntoView(t)}},tg=Zm,ng=function(e,t){return e&&e.parentNode&&e.parentNode.nodeName===t},rg=function(e){return e&&/^(OL|UL|LI)$/.test(e.nodeName)},og=function(e){var t=e.parentNode;return/^(LI|DT|DD)$/.test(t.nodeName)?t:e},ig=function(e,t,n){for(var r=e[n?"firstChild":"lastChild"];r&&!Zr.isElement(r);)r=r[n?"nextSibling":"previousSibling"];return r===t},ag=function(e){e.innerHTML='<br data-mce-bogus="1">'},sg=function(e,t){return e.nodeName===t||e.previousSibling&&e.previousSibling.nodeName===t},ug=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)},cg=function(e,t,n){return!1===Zr.isText(t)?n:e?1===n&&"\ufeff"===t.data.charAt(n-1)?0:n:n===t.data.length-1&&"\ufeff"===t.data.charAt(n)?t.data.length:n},lg=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},fg=function(e,t){var n=Qm(e);n&&n.toLowerCase()===t.tagName.toLowerCase()&&e.dom.setAttribs(t,function(e){return e.getParam("forced_root_block_attrs",{})}(e))},dg=function(e,t){return tg(e).filter(function(e){return t.length>0&&nr.is(_n(e),t)}).isSome()},hg=Qu([{br:[]},{block:[]},{none:[]}]),pg=function(e,t){return function(e){return dg(e,function(e){return e.getParam("no_newline_selector","")}(e))}(e)},mg=function(e){return function(t,n){return""===Qm(t)===e}},gg=function(e){return function(t,n){return function(e){return Zm(e).filter(function(e){return Fr(_n(e))}).isSome()}(t)===e}},vg=function(e){return function(t,n){return"PRE"===function(e){return Zm(e).fold(p.constant(""),function(e){return e.nodeName.toUpperCase()})}(t)===e}},yg=function(e){return function(t,n){return function(e){return e.getParam("br_in_pre",!0)}(t)===e}},bg=function(e,t){return function(e){return dg(e,function(e){return e.getParam("br_newline_selector",".mce-toc h2,figcaption,caption")}(e))}(e)},wg=function(e,t){return t},xg=function(e){var t=Qm(e),n=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}(e.dom,e.selection.getStart());return n&&e.schema.isValidChild(n.nodeName,t||"P")},Cg=function(e,t){return function(n,r){return P.foldl(e,function(e,t){return e&&t(n,r)},!0)?w.some(t):w.none()}},Sg=function(e,t){(function(e,t){return ll([Cg([pg],hg.none()),Cg([vg(!0),yg(!1),wg],hg.br()),Cg([vg(!0),yg(!1)],hg.block()),Cg([vg(!0),yg(!0),wg],hg.block()),Cg([vg(!0),yg(!0)],hg.br()),Cg([gg(!0),wg],hg.br()),Cg([gg(!0)],hg.block()),Cg([mg(!0),wg,xg],hg.block()),Cg([mg(!0)],hg.br()),Cg([bg],hg.br()),Cg([mg(!1),wg],hg.br()),Cg([xg],hg.block())],[e,t.shiftKey]).getOr(hg.none())})(e,t).fold(function(){Af.insert(e,t)},function(){!function(e,t){var n,r,o,i,a,s,u,c,l,f,d,h,p,m=e.dom,g=e.schema,v=g.getNonEmptyElements(),y=e.selection.getRng(),b=function(t){var n,i,s,u=o,c=g.getTextInlineElements();if(t||"TABLE"===f||"HR"===f?(n=m.create(t||h),fg(e,n)):n=a.cloneNode(!1),s=n,!1===function(e){return e.getParam("keep_styles",!0)}(e))m.setAttrib(n,"style",null),m.setAttrib(n,"class",null);else do{if(c[u.nodeName]){if(cl.isCaretNode(u))continue;i=u.cloneNode(!1),m.setAttrib(i,"id",""),n.hasChildNodes()?(i.appendChild(n.firstChild),n.appendChild(i)):(s=i,n.appendChild(i))}}while((u=u.parentNode)&&u!==r);return ag(s),n},w=function(e){var t,n,r,s;
1if(s=cg(e,o,i),Zr.isText(o)&&(e?s>0:s<o.nodeValue.length))return!1;if(o.parentNode===a&&p&&!e)return!0;if(e&&Zr.isElement(o)&&o===a.firstChild)return!0;if(sg(o,"TABLE")||sg(o,"HR"))return p&&!e||!p&&e;for(t=new Rr(o,a),Zr.isText(o)&&(e&&0===s?t.prev():e||s!==o.nodeValue.length||t.next());n=t.current();){if(Zr.isElement(n)){if(!n.getAttribute("data-mce-bogus")&&(r=n.nodeName.toLowerCase(),v[r]&&"br"!==r))return!1}else if(Zr.isText(n)&&!/^[ \t\r\n]*$/.test(n.nodeValue))return!1;e?t.prev():t.next()}return!0},x=function(){u=/^(H[1-6]|PRE|FIGURE)$/.test(f)&&"HGROUP"!==d?b(h):b(),function(e){return e.getParam("end_container_on_empty_block",!1)}(e)&&ug(m,l)&&m.isEmpty(a)?u=m.split(l,a):m.insertAfter(u,a),eg(e,u)};xf.normalize(m,y).each(function(e){y.setStart(e.startContainer,e.startOffset),y.setEnd(e.endContainer,e.endOffset)}),o=y.startContainer,i=y.startOffset,h=Qm(e),s=t.shiftKey,Zr.isElement(o)&&o.hasChildNodes()&&(p=i>o.childNodes.length-1,o=o.childNodes[Math.min(i,o.childNodes.length-1)]||o,i=p&&Zr.isText(o)?o.nodeValue.length:0),(r=lg(m,o))&&((h&&!s||!h&&s)&&(o=function(e,t,n,r,o){var i,a,s,u,c,l,f=t||"P",d=e.dom,h=lg(d,r);if(!(a=d.getParent(r,d.isBlock))||!ug(d,a)){if(l=(a=a||h)===e.getBody()||a&&/^(TD|TH|CAPTION)$/.test(a.nodeName)?a.nodeName.toLowerCase():a.parentNode.nodeName.toLowerCase(),!a.hasChildNodes())return i=d.create(f),fg(e,i),a.appendChild(i),n.setStart(i,0),n.setEnd(i,0),i;for(u=r;u.parentNode!==a;)u=u.parentNode;for(;u&&!d.isBlock(u);)s=u,u=u.previousSibling;if(s&&e.schema.isValidChild(l,f.toLowerCase())){for(i=d.create(f),fg(e,i),s.parentNode.insertBefore(i,s),u=s;u&&!d.isBlock(u);)c=u.nextSibling,i.appendChild(u),u=c;n.setStart(r,o),n.setEnd(r,o)}}return r}(e,h,y,o,i)),a=m.getParent(o,m.isBlock),l=a?m.getParent(a.parentNode,m.isBlock):null,f=a?a.nodeName.toUpperCase():"","LI"!==(d=l?l.nodeName.toUpperCase():"")||t.ctrlKey||(a=l,l=l.parentNode,f=d),/^(LI|DT|DD)$/.test(f)&&m.isEmpty(a)?function(e,t,n,r,o){var i=e.dom,a=e.selection.getRng();if(n!==e.getBody()){var s;rg(s=n)&&rg(s.parentNode)&&(o="LI");var u=o?t(o):i.create("BR");if(ig(n,r,!0)&&ig(n,r,!1))ng(n,"LI")?i.insertAfter(u,og(n)):i.replace(u,n);else if(ig(n,r,!0))ng(n,"LI")?(i.insertAfter(u,og(n)),u.appendChild(i.doc.createTextNode(" ")),u.appendChild(n)):n.parentNode.insertBefore(u,n);else if(ig(n,r,!1))i.insertAfter(u,og(n));else{n=og(n);var c=a.cloneRange();c.setStartAfter(r),c.setEndAfter(n);var l=c.extractContents();"LI"===o&&l.firstChild&&"LI"===l.firstChild.nodeName?(u=l.firstChild,i.insertAfter(l,n)):(i.insertAfter(l,n),i.insertAfter(u,n))}i.remove(r),eg(e,u)}}(e,b,l,a,h):h&&a===e.getBody()||(h=h||"P",Xo(a)?(u=ti(a),m.isEmpty(a)&&ag(a),eg(e,u)):w()?x():w(!0)?(u=a.parentNode.insertBefore(b(),a),eg(e,sg(a,"HR")?u:a)):((n=function(e){var t=e.cloneRange();return t.setStart(e.startContainer,cg(!0,e.startContainer,e.startOffset)),t.setEnd(e.endContainer,cg(!1,e.endContainer,e.endOffset)),t}(y).cloneRange()).setEndAfter(a),function(e){do{Zr.isText(e)&&(e.nodeValue=e.nodeValue.replace(/^[\r\n]+/,"")),e=e.firstChild}while(e)}(c=n.extractContents()),u=c.firstChild,m.insertAfter(c,a),function(e,t,n){var r,o=u,i=[];if(o){for(;o=o.firstChild;){if(e.isBlock(o))return;Zr.isElement(o)&&!t[o.nodeName.toLowerCase()]&&i.push(o)}for(r=i.length;r--;)!(o=i[r]).hasChildNodes()||o.firstChild===o.lastChild&&""===o.firstChild.nodeValue?e.remove(o):(a=o)&&"A"===a.nodeName&&0===kt.trim(qo(a.innerText||a.textContent)).length&&e.remove(o);var a}}(m,v),function(e,t){var n;t.normalize(),(n=t.lastChild)&&!/^(left|right)$/gi.test(e.getStyle(n,"float",!0))||e.add(t,"br")}(m,a),m.isEmpty(a)&&ag(a),u.normalize(),m.isEmpty(u)?(m.remove(u),x()):eg(e,u)),m.setAttrib(u,"id",""),e.fire("NewBlock",{newBlock:u})))}(e,t)},p.noop)},Tg=function(e,t,n){return!!function(e,t){return Eg(e)&&Zr.isText(t.container())}(n,t)&&(function(e,t){var n=t.container(),r=t.offset();n.insertData(r,"\xa0"),e.selection.setCursorLocation(n,r+1)}(e,t),!0)},Eg=function(e){return e.fold(p.constant(!1),p.constant(!0),p.constant(!0),p.constant(!1))},kg=function(e){return!!e.selection.isCollapsed()&&function(e){var t=p.curry(Ru.isInlineTarget,e),n=Ui.fromRangeStart(e.selection.getRng());return Rl(t,e.getBody(),n).map(p.curry(Tg,e,n)).getOr(!1)}(e)},Ng=Lo.DOM,Rg=function(e){e.bindPendingEventDelegates(),e.initialized=!0,e.fire("init"),e.focus(!0),e.nodeChanged({initial:!0}),e.execCallback("init_instance_callback",e),function(e){e.settings.auto_focus&&fe.setEditorTimeout(e,function(){var t;(t=!0===e.settings.auto_focus?e:e.editorManager.get(e.settings.auto_focus)).destroyed||t.focu
vendor: 4,256 bytes, line 1
1s()},100)}(e)},_g=function(e,t){var n,r,o=e.settings,i=e.getElement(),a=e.getDoc();o.inline||(e.getElement().style.visibility=e.orgVisibility),t||o.content_editable||(a.open(),a.write(e.iframeHTML),a.close()),o.content_editable&&(e.on("remove",function(){var e=this.getBody();Ng.removeClass(e,"mce-content-body"),Ng.removeClass(e,"mce-edit-focus"),Ng.setAttrib(e,"contentEditable",null)}),Ng.addClass(i,"mce-content-body"),e.contentDocument=a=o.content_document||document,e.contentWindow=o.content_window||window,e.bodyElement=i,o.content_document=o.content_window=null,o.root_name=i.nodeName.toLowerCase()),(n=e.getBody()).disabled=!0,e.readonly=o.readonly,e.readonly||(e.inline&&"static"===Ng.getStyle(n,"position",!0)&&(n.style.position="relative"),n.contentEditable=e.getParam("content_editable_state",!0)),n.disabled=!1,e.editorUpload=Qd(e),e.schema=Eo(o),e.dom=new Lo(a,{keep_values:!0,url_converter:e.convertURL,url_converter_scope:e,hex_colors:o.force_hex_style_colors,class_filter:o.class_filter,update_styles:!0,root_element:e.inline?e.getBody():null,collect:o.content_editable,schema:e.schema,onSetAttrib:function(t){e.fire("SetAttrib",t)}}),e.parser=function(e){var t=Kp(e.settings,e.schema);return t.addAttributeFilter("src,href,style,tabindex",function(t,n){for(var r,o,i,a=t.length,s=e.dom;a--;)if(o=(r=t[a]).attr(n),!r.attributes.map[i="data-mce-"+n]){if(0===o.indexOf("data:")||0===o.indexOf("blob:"))continue;"style"===n?((o=s.serializeStyle(s.parseStyle(o),r.name)).length||(o=null),r.attr(i,o),r.attr(n,o)):"tabindex"===n?(r.attr(i,o),r.attr(n,null)):r.attr(i,e.convertURL(o,n,r.name))}}),t.addNodeFilter("script",function(e){for(var t,n,r=e.length;r--;)0!==(n=(t=e[r]).attr("type")||"no/type").indexOf("mce-")&&t.attr("type","mce-"+n)}),t.addNodeFilter("#cdata",function(e){for(var t,n=e.length;n--;)(t=e[n]).type=8,t.name="#comment",t.value="[CDATA["+t.value+"]]"}),t.addNodeFilter("p,h1,h2,h3,h4,h5,h6,div",function(t){for(var n,r=t.length,o=e.schema.getNonEmptyElements();r--;)(n=t[r]).isEmpty(o)&&0===n.getAll("br").length&&(n.append(new Hp("br",1)).shortEnded=!0)}),t}(e),e.serializer=em(o,e),e.selection=Mm(e.dom,e.getWin(),e.serializer,e),e.formatter=Np(e),e.undoManager=zh(e),e._nodeChangeDispatcher=new function(e){var t,n=[];"onselectionchange"in e.getDoc()||e.on("NodeChange Click MouseUp KeyUp Focus",function(n){var r,o;o={startContainer:(r=e.selection.getRng()).startContainer,startOffset:r.startOffset,endContainer:r.endContainer,endOffset:r.endOffset},"nodechange"!==n.type&&ff(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||!ae.range&&e.selection.isCollapsed()||!function(t){var r,o;if((o=e.$(t).parentsUntil(e.getBody()).add(t)).length===n.length){for(r=o.length;r>=0&&o[r]===n[r];r--);if(-1===r)return n=o,!0}return n=o,!1}(t)&&e.dom.isChildOf(t,e.getBody())&&e.nodeChanged({selectionChange:!0})}),e.on("MouseUp",function(t){t.isDefaultPrevented()||("IMG"===e.selection.getNode().nodeName?fe.setEditorTimeout(e,function(){e.nodeChanged()}):e.nodeChanged())}),this.nodeChanged=function(t){var n,r,o,i=e.selection;e.initialized&&i&&!e.settings.disable_nodechange&&!e.readonly&&(o=e.getBody(),(n=i.getStart(!0)||o).ownerDocument===e.getDoc()&&e.dom.isChildOf(n,o)||(n=o),r=[],e.dom.getParent(n,function(e){if(e===o)return!0;r.push(e)}),(t=t||{}).element=n,t.parents=r,e.fire("NodeChange",t))}}(e),e._selectionOverrides=_h(e),function(e){e.on("keyup compositionstart",p.curry(nm,e))}(e),function(e){var t=Fl.setupSelectedState(e);(function(e,t){e.on("keydown",function(n){!1===n.isDefaultPrevented()&&function(e,t,n){var r=Tn.detect().os;Xm([{keyCode:Th.RIGHT,action:qm(e,!0)},{keyCode:Th.LEFT,action:qm(e,!1)},{keyCode:Th.UP,action:Um(e,!1)},{keyCode:Th.DOWN,action:Um(e,!0)},{keyCode:Th.RIGHT,action:Ba(e,!0)},{keyCode:Th.LEFT,action:Ba(e,!1)},{keyCode:Th.UP,action:Ia(e,!1)},{keyCode:Th.DOWN,action:Ia(e,!0)},{keyCode:Th.RIGHT,action:Fl.move(e,t,!0)},{keyCode:Th.LEFT,action:Fl.move(e,t,!1)},{keyCode:Th.RIGHT,ctrlKey:!r.isOSX(),altKey:r.isOSX(),action:Fl.moveNextWord(e,t)},{keyCode:Th.LEFT,ctrlKey:!r.isOSX(),altKey:r.isOSX(),action:Fl.movePrevWord(e,t)}],n).each(function(e){n.preventDefault()})}
1(e,t,n)})})(e,t),function(e,t){e.on("keydown",function(n){!1===n.isDefaultPrevented()&&function(e,t,n){Xm([{keyCode:Th.BACKSPACE,action:Vm(cc,e,!1)},{keyCode:Th.DELETE,action:Vm(cc,e,!0)},{keyCode:Th.BACKSPACE,action:Vm($l,e,t,!1)},{keyCode:Th.DELETE,action:Vm($l,e,t,!0)},{keyCode:Th.BACKSPACE,action:Vm(Ju,e,!1)},{keyCode:Th.DELETE,action:Vm(Ju,e,!0)},{keyCode:Th.BACKSPACE,action:Vm(Ku,e,!1)},{keyCode:Th.DELETE,action:Vm(Ku,e,!0)},{keyCode:Th.BACKSPACE,action:Vm(uf,e,!1)},{keyCode:Th.DELETE,action:Vm(uf,e,!0)},{keyCode:Th.BACKSPACE,action:Vm(Km,e,!1)},{keyCode:Th.DELETE,action:Vm(Km,e,!0)}],n).each(function(e){n.preventDefault()})}(e,t,n)}),e.on("keyup",function(t){!1===t.isDefaultPrevented()&&function(e,t){Xm([{keyCode:Th.BACKSPACE,action:Vm(lc,e)},{keyCode:Th.DELETE,action:Vm(lc,e)}],t)}(e,t)})}(e,t),function(e){e.on("keydown",function(t){t.keyCode===Th.ENTER&&function(e,t){var n;t.isDefaultPrevented()||(t.preventDefault(),(n=e.undoManager).typing&&(n.typing=!1,n.add()),e.undoManager.transact(function(){!1===e.selection.isCollapsed()&&e.execCommand("Delete"),Sg(e,t)}))}(e,t)})}(e),function(e){e.on("keydown",function(t){!1===t.isDefaultPrevented()&&function(e,t){Xm([{keyCode:Th.SPACEBAR,action:Vm(kg,e)}],t).each(function(e){t.preventDefault()})}(e,t)})}(e)}(e),function(e){e.settings.forced_root_block&&e.on("NodeChange",p.curry(rh,e))}(e),e.fire("PreInit"),o.browser_spellcheck||o.gecko_spellcheck||(a.body.spellcheck=!1,Ng.setAttrib(n,"spellcheck","false")),e.quirks=function(e){var t,n,r,o=kt.each,i=Th.BACKSPACE,a=Th.DELETE,s=e.dom,u=e.selection,c=e.settings,l=e.parser,f=ae.gecko,d=ae.webkit,h=ae.ie?"Text":"URL",p=function(t,n){try{e.getDoc().execCommand(t,!1,n)}catch(e){}},m=function(e){return e.isDefaultPrevented()},g=function(){e.shortcuts.add("meta+a",null,"SelectAll")},v=function(){e.on("keydown",function(e){if(!m(e)&&e.keyCode===i&&u.isCollapsed()&&0===u.getRng().startOffset){var t=u.getNode().previousSibling;if(t&&t.nodeName&&"table"===t.nodeName.toLowerCase())return e.preventDefault(),!1}})},y=function(){e.inline||(e.contentStyles.push("body {min-height: 150px}"),e.on("click",function(t){var n;if("HTML"===t.target.nodeName){if(ae.ie>11)return void e.getBody().focus();n=e.selection.getRng(),e.getBody().focus(),e.selection.setRng(n),e.selection.normalize(),e.nodeChanged()}}))};return e.on("keydown",function(t){var n,r,o,i,a;if(!m(t)&&t.keyCode===Th.BACKSPACE&&(r=(n=u.getRng()).startContainer,o=n.startOffset,i=s.getRoot(),a=r,n.collapsed&&0===o)){for(;a&&a.parentNode&&a.parentNode.firstChild===a&&a.parentNode!==i;)a=a.parentNode;"BLOCKQUOTE"===a.tagName&&(e.formatter.toggle("blockquote",null,a),(n=s.createRng()).setStart(r,0),n.setEnd(r,0),u.setRng(n))}}),t=function(e){var t=s.create("body"),n=e.cloneContents();return t.appendChild(n),u.serializer.serialize(t,{format:"html"})},e.on("keydown",function(n){var r,o,u,c,l,f=n.keyCode;if(!m(n)&&(f===a||f===i)){if(r=e.selection.isCollapsed(),o=e.getBody(),r&&!s.isEmpty(o))return;if(!r&&(u=e.selection.getRng(),c=t(u),(l=s.createRng()).selectNode(e.getBody()),c!==t(l)))return;n.preventDefault(),e.setContent(""),o.firstChild&&s.isBlock(o.firstChild)?e.selection.setCursorLocation(o.firstChild,0):e.selection.setCursorLocation(o,0),e.nodeChanged()}}),ae.windowsPhone||e.on("keyup focusin mouseup",function(e){Th.modifierPressed(e)||u.normalize()},!0),d&&(e.settings.content_editable||s.bind(e.getDoc(),"mousedown mouseup",function(t){var n;if(t.target===e.getDoc().documentElement)if(n=u.getRng(),e.getBody().focus(),"mousedown"===t.type){if(Ko(n.startContainer))return;u.placeCaretAt(t.clientX,t.clientY)}else u.setRng(n)}),e.on("click",function(t){var n=t.target;/^(IMG|HR)$/.test(n.nodeName)&&"false"!==s.getContentEditableParent(n)&&(t.preventDefault(),e.selection.select(n),e.nodeChanged()),"A"===n.nodeName&&s.hasClass(n,"mce-item-anchor")&&(t.preventDefault(),u.select(n))}),c.forced_root_block&&e.on("init",function(){p("DefaultParagraphSeparator",c.forced_root_block)}),e.on("init",function(){e.dom.bind(e.getBody(),"submit",function(e){e.preventDefault()})}),v(),l.addNodeFilter("br",function(e){for(var t=e.length;t--;)"Apple-interchange-newline"===e[t].attr("class")&&e[t].remove()}
1),ae.iOS?(e.inline||e.on("keydown",function(){document.activeElement===document.body&&e.getWin().focus()}),y(),e.on("click",function(e){var t=e.target;do{if("A"===t.tagName)return void e.preventDefault()}while(t=t.parentNode)}),e.contentStyles.push(".mce-content-body {-webkit-touch-callout: none}")):g()),ae.ie>=11&&(y(),v()),ae.ie&&(g(),p("AutoUrlDetect",!1),e.on("dragstart",function(t){!function(t){var n,r;t.dataTransfer&&(e.selection.isCollapsed()&&"IMG"===t.target.tagName&&u.select(t.target),(n=e.selection.getContent()).length>0&&(r="data:text/mce-internal,"+escape(e.id)+","+escape(n),t.dataTransfer.setData(h,r)))}(t)}),e.on("drop",function(t){if(!m(t)){var n=function(e){var t;return e.dataTransfer&&(t=e.dataTransfer.getData(h))&&t.indexOf("data:text/mce-internal,")>=0?(t=t.substr("data:text/mce-internal,".length).split(","),{id:unescape(t[0]),html:unescape(t[1])}):null}(t);if(n&&n.id!==e.id){t.preventDefault();var r=lm(t.x,t.y,e.getDoc());u.setRng(r),o=n.html,e.queryCommandSupported("mceInsertClipboardContent")?e.execCommand("mceInsertClipboardContent",!1,{content:o,internal:!0}):e.execCommand("mceInsertContent",!1,o)}}var o})),f&&(e.on("keydown",function(t){if(!m(t)&&t.keyCode===i){if(!e.getBody().getElementsByTagName("hr").length)return;if(u.isCollapsed()&&0===u.getRng().startOffset){var n=u.getNode(),r=n.previousSibling;if("HR"===n.nodeName)return s.remove(n),void t.preventDefault();r&&r.nodeName&&"hr"===r.nodeName.toLowerCase()&&(s.remove(r),t.preventDefault())}}}),Range.prototype.getClientRects||e.on("mousedown",function(t){if(!m(t)&&"HTML"===t.target.nodeName){var n=e.getBody();n.blur(),fe.setEditorTimeout(e,function(){n.focus()})}}),n=function(){var t=s.getAttribs(u.getStart().cloneNode(!1));return function(){var n=u.getStart();n!==e.getBody()&&(s.setAttrib(n,"style",null),o(t,function(e){n.setAttributeNode(e.cloneNode(!0))}))}},r=function(){return!u.isCollapsed()&&s.getParent(u.getStart(),s.isBlock)!==s.getParent(u.getEnd(),s.isBlock)},e.on("keypress",function(t){var o;if(!m(t)&&(8===t.keyCode||46===t.keyCode)&&r())return o=n(),e.getDoc().execCommand("delete",!1,null),o(),t.preventDefault(),!1}),s.bind(e.getDoc(),"cut",function(t){var o;!m(t)&&r()&&(o=n(),fe.setEditorTimeout(e,function(){o()}))}),c.readonly||e.on("BeforeExecCommand MouseDown",function(){p("StyleWithCSS",!1),p("enableInlineTableEditing",!1),c.object_resizing||p("enableObjectResizing",!1)}),e.on("SetContent ExecCommand",function(e){"setcontent"!==e.type&&"mceInsertLink"!==e.command||o(s.select("a"),function(e){var t=e.parentNode,n=s.getRoot();if(t.lastChild===e){for(;t&&!s.isBlock(t);){if(t.parentNode.lastChild!==t||t===n)return;t=t.parentNode}s.add(t,"br",{"data-mce-bogus":1})}})}),e.contentStyles.push("img:-moz-broken {-moz-force-broken-image-icon:1;min-width:24px;min-height:24px}"),ae.mac&&e.on("keydown",function(t){!Th.metaKeyPressed(t)||t.shiftKey||37!==t.keyCode&&39!==t.keyCode||(t.preventDefault(),e.selection.getSel().modify("move",37===t.keyCode?"backward":"forward","lineboundary"))}),v()),{refreshContentEditable:function(){},isHidden:function(){var t;return!f||e.removed?0:!(t=e.selection.getSel())||!t.rangeCount||0===t.rangeCount}}}(e),e.fire("PostRender"),o.directionality&&(n.dir=o.directionality),o.nowrap&&(n.style.whiteSpace="nowrap"),o.protect&&e.on("BeforeSetContent",function(e){kt.each(o.protect,function(t){e.content=e.content.replace(t,function(e){return"\x3c!--mce:protected "+escape(e)+"--\x3e"})})}),e.on("SetContent",function(){e.addVisual(e.getBody())}),o.padd_empty_editor&&e.on("PostProcess",function(e){e.content=e.content.replace(/^(<p[^>]*>( | |\s|\u00a0|<br \/>|)<\/p>[\r\n]*|<br \/>[\r\n]*)$/,"")}),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&&(r="",kt.each(e.contentStyles,function(e){r+=e+"\r\n"}),e.dom.addStyle(r)),function(e){return e.inline?Ng.styleSheetLoader:e.dom.styleSheetLoader}(e).loadAll(e.contentCSS,function(t){Rg(e)},function(t){Rg(e)}),o.content_style&&function(e,t){var n=_n(e.getDoc().head),r=Nn("style");Vn(r,"type","text/css"),eu(r,Rn(t)),eu(n,r)}(e,o.content_style)},Ag=Lo.DOM,Dg=function(e,t){var n=e.editorManager.translate("Rich Text Area. Press ALT
1-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help"),r=function(e,t,n,r){var o,i,a,s=Nn("iframe");return Xn(s,r),Xn(s,{id:e+"_ifr",frameBorder:"0",allowTransparency:"true",title:t}),o=s,i={width:"100%",height:function(e){return("number"==typeof e?e+"px":e)||""}(n),display:"block"},a=o.dom(),qn.each(i,function(e,t){!function(e,t,n){if(!Hn.isString(n))throw console.error("Invalid call to CSS.set. Property ",t,":: Value ",n,":: Element ",e),new Error("CSS value must be a string: "+n);Qn(e)&&e.style.setProperty(t,n)}(a,t,e)}),s}(e.id,n,t.height,function(e){return e.getParam("iframe_attrs",{})}(e)).dom();r.onload=function(){r.onload=null,e.fire("load")};var o=function(e,t){if(document.domain!==window.location.hostname&&ae.ie&&ae.ie<12){var n=Jd.uuid("mce");e[n]=function(){_g(e)};var r='javascript:(function(){document.open();document.domain="'+document.domain+'";var ed = window.parent.tinymce.get("'+e.id+'");document.write(ed.iframeHTML);document.close();ed.'+n+"(true);})()";return Ag.setAttrib(t,"src",r),!0}return!1}(e,r);return e.contentAreaContainer=t.iframeContainer,e.iframeElement=r,e.iframeHTML=function(e){var t,n,r;return r=function(e){return e.getParam("doctype","<!DOCTYPE html>")}(e)+"<html><head>",function(e){return e.getParam("document_base_url","")}(e)!==e.documentBaseUrl&&(r+='<base href="'+e.documentBaseURI.getURI()+'" />'),r+='<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />',t=function(e){return Gm(e,"body_id","tinymce")}(e),n=function(e){return Gm(e,"body_class","")}(e),Jm(e)&&(r+='<meta http-equiv="Content-Security-Policy" content="'+Jm(e)+'" />'),r+'</head><body id="'+t+'" class="mce-content-body '+n+'" data-id="'+e.id+'"><br></body></html>'}(e),Ag.add(t.iframeContainer,r),o},Og=Lo.DOM,Pg=function(e,t,n){var r,o,i=Fd.get(n);if(r=Fd.urls[n]||e.documentBaseUrl.replace(/\/$/,""),n=kt.trim(n),i&&-1===kt.inArray(t,n)){if(kt.each(Fd.dependencies(n),function(n){Pg(e,t,n)}),e.plugins[n])return;o=new i(e,r,e.$),e.plugins[n]=o,o.init&&(o.init(e,r),t.push(n))}},Bg=function(e){return e.replace(/^\-/,"")},Ig=function(e){return{editorContainer:e,iframeContainer:e}},Lg=function(e){var t,n=e.settings,r=e.getElement();return e.rtl=n.rtl_ui||e.editorManager.i18n.rtl,e.editorManager.i18n.setCode(n.language),n.aria_label=n.aria_label||Og.getAttrib(r,"aria-label",e.getLang("aria.rich_text_area")),e.fire("ScriptsLoaded"),function(e){var t,n=e.settings.theme;Hn.isString(n)?(e.settings.theme=Bg(n),t=Wd.get(n),e.theme=new t(e,Wd.urls[n]),e.theme.init&&e.theme.init(e,Wd.urls[n]||e.documentBaseUrl.replace(/\/$/,""),e.$)):e.theme={}}(e),function(e){var t=[];kt.each(e.settings.plugins.split(/[ ,]/),function(n){Pg(e,t,Bg(n))})}(e),t=function(e){var t=e.settings,n=e.getElement();return e.orgDisplay=n.style.display,Hn.isString(t.theme)?function(e){var t,n,r,o,i,a=e.settings,s=e.getElement();return t=a.width||Og.getStyle(s,"width")||"100%",n=a.height||Og.getStyle(s,"height")||s.offsetHeight,r=a.min_height||100,(o=/^[0-9\.]+(|px)$/i).test(""+t)&&(t=Math.max(parseInt(t,10),100)),o.test(""+n)&&(n=Math.max(parseInt(n,10),r)),i=e.theme.renderUI({targetNode:s,width:t,height:n,deltaWidth:a.delta_width,deltaHeight:a.delta_height}),a.content_editable||(n=(i.iframeHeight||n)+("number"==typeof n?i.deltaHeight||0:""))<r&&(n=r),i.height=n,i}(e):Hn.isFunction(t.theme)?function(e){var t,n=e.getElement();return(t=e.settings.theme(e,n)).editorContainer.nodeType&&(t.editorContainer.id=t.editorContainer.id||e.id+"_parent"),t.iframeContainer&&t.iframeContainer.nodeType&&(t.iframeContainer.id=t.iframeContainer.id||e.id+"_iframecontainer"),t.height=t.iframeHeight?t.iframeHeight:n.offsetHeight,t}(e):function(e){var t=e.getElement();return e.inline?Ig(null):function(e){var t=Og.create("div");return Og.insertAfter(t,e),Ig(t)}(t)}(e)}(e),e.editorContainer=t.editorContainer?t.editorContainer:null,n.content_css&&kt.each(kt.explode(n.content_css),function(t){e.contentCSS.push(e.documentBaseURI.toAbsolute(t))}),n.content_editable?_g(e):function(e,t){var n=Dg(e,t);t.editorContainer&&(Ag.get(t.editorContainer).style.display=e.orgDisplay,e.hidden=Ag.isHidden(t.editorContainer)),e.getElement().style.display="none",Ag.setAttrib(e.id,"aria-hidden",!0),n||_g(e)}(e,t)},Mg=Lo.DOM,Hg=function(e){return"-"===e.charAt(0)},Fg=kt.each,Wg=kt.trim,jg="source protocol authority userInfo user password host port relative path directory file query anchor".split(" "),$g={ftp:21,http:80,https:443,mailto:25},zg=function(e,t){var n,r,o=this;if(e=Wg(e),n=(t=o.settings=t||{}).base_uri,/^([\w\-]+):([^\/]{2})/i.test(e)||/^\s*#/.test(e))o.source=e;else{var i=0===e.indexOf("//");0!==e.indexOf("/")||i||(e=(n&&n.protocol||"http")+"://mce_host"+e),/^[\w\-]*:?\/\//.test(e)||(r=t.base_uri?t.base_uri.path:new zg(document.location.href).directory,""==t.base_uri.protocol?e="//mce_host"+o.toAbsPath(r,e):(e=/([^#?]*)([#?]?.*)/.exec(e),e=(n&&n.protocol||"http")+"://mce_host"+o.toAbsPath(r,e[1])+e[2])),e=e.replace(/@@/g,"(mce_at)"),e=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@\/]*):?([^:@\/]*))?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/.exec(e),Fg(jg,function(t,n){var r=e[n];r&&(r=r.replace(/\(mce_at\)/g,"@@")),o[t]=r}),n&&(o.protocol||(o.protocol=n.protocol),o.userInfo||(o.userInfo=n.userInfo),o.port||"mce_host"!==o.host||(o.port=n.port),o.host&&"mce_host"!==o.host||(o.host=n.host),o.source=""),i&&(o.protocol="")}};zg.prototype={setPath:function(e){e=/^(.*?)\/?(\w+)?$/.exec(e),this.path=e[0],this.directory=e[1],this.file=e[2],this.source="",this.getURI()},toRelative:function(e){var t;if("./"===e)return e;if("mce_host"!==(e=new zg(e,{base_uri:this})).host&&this.host!==e.host&&e.host||this.port!==e.port||this.protocol!==e.protocol&&""!==e.protocol)return e.getURI();var n=this.getURI(),r=e.getURI();return n===r||"/"===n.charAt(n.length-1)&&n.substr(0,n.length-1)===r?n:(t=this.toRelPath(this.path,e.path),e.query&&(t+="?"+e.query),e.anchor&&(t+="#"+e.anchor),t)},toAbsolute:function(e,t){return(e=new zg(e,{base_uri:this})).getURI(t&&this.isSameOrigin(e))},isSameOrigin:function(e){if(this.host==e.host&&this.protocol==e.protocol){if(this.port==e.port)return!0;var t=$g[this.protocol];if(t&&(this.port||t)==(e.port||t))return!0}return!1},toRelPath:function(e,t){var n,r,o,i=0,a="";if(e=(e=e.substring(0,e.lastIndexOf("/"))).split("/"),n=t.split("/"),e.length>=n.length)for(r=0,o=e.length;r<o;r++)if(r>=n.length||e[r]!==n[r]){i=r+1;break}if(e.length<n.length)for(r=0,o=n.length;r<o;r++)if(r>=e.length||e[r]!==n[r]){i=r+1;break}if(1===i)return t;for(r=0,o=e.length-(i-1);r<o;r++)a+="../";
1for(r=i-1,o=n.length;r<o;r++)a+=r!==i-1?"/"+n[r]:n[r];return a},toAbsPath:function(e,t){var n,r,o,i=0,a=[];for(r=/\/$/.test(t)?"/":"",e=e.split("/"),t=t.split("/"),Fg(e,function(e){e&&a.push(e)}),e=a,n=t.length-1,a=[];n>=0;n--)0!==t[n].length&&"."!==t[n]&&(".."!==t[n]?i>0?i--:a.push(t[n]):i++);return 0!==(o=(n=e.length-i)<=0?a.reverse().join("/"):e.slice(0,n).join("/")+"/"+a.reverse().join("/")).indexOf("/")&&(o="/"+o),r&&o.lastIndexOf("/")!==o.length-1&&(o+=r),o},getURI:function(e){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}},zg.parseDataUri=function(e){var t,n;return e=decodeURIComponent(e).split(","),(n=/data:([^;]+)/.exec(e[0]))&&(t=n[1]),{type:t,data:e[1]}},zg.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};var qg=function(e,t){t(e),e.firstChild&&qg(e.firstChild,t),e.next&&qg(e.next,t)},Ug=function(e){return e instanceof Hp},Vg=Lo.DOM,Xg=function(e){return w.from(e).each(function(e){return e.destroy()})},Yg=Lo.DOM,Kg=kt.extend,Gg=kt.each,Jg=kt.resolve,Qg=ae.ie,Zg=function(e,t,n){var r,o,i=this;r=i.documentBaseUrl=n.documentBaseURL,o=n.baseURI,t=function(e,t,n,r,o){var a=function(e,t,n){return{id:e,theme:"modern",delta_width:0,delta_height:0,popup_css:"",plugins:"",document_base_url:t,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_style_values:"xx-small,x-small,small,medium,large,x-large,xx-large",font_size_legacy_values:"xx-small,small,medium,large,x-large,xx-large,300%",forced_root_block:"p",hidden_input:!0,padd_empty_editor:!0,render_ui:!0,indentation:"30px",inline_styles:!0,convert_fonts_to_spans:!0,indent:"simple",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,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,article,hgroup,aside,figure,figcaption,option,optgroup,datalist",entity_encoding:"named",url_converter:i.convertURL,url_converter_scope:i,ie7_compat:!0}}(t,n);return function(e,t,n,r){var o=Cu(["mobile"],r);return function(e,t,n,r){var o=xu(n.forced_plugins),i=xu(r.plugins),a=function(e,t){return[].concat(xu(e)).concat(xu(t))}(o,e&&Su(t,"mobile")?function(e){return P.filter(e,p.curry(P.contains,bu))}(i):i);return kt.extend(r,{plugins:a.join(" ")})}(e,o,n,kt.extend(t,n,o.settings(),function(e,t){var n=t.settings().inline;return e&&Su(t,"mobile")&&!n}(e,o)?function(e,t,n){var r=e.sections(),o=r.hasOwnProperty("mobile")?r.mobile:{};return kt.extend({},n,o)}(o,0,wu):{},{validate:!0,content_editable:o.settings().inline,external_plugins:function(e,t){var n=t.external_plugins?t.external_plugins:{};return e&&e.external_plugins?kt.extend({},e.external_plugins,n):n}(n,o.settings())}))}(yu,a,r,o)}(0,e,r,n.defaultSettings,t),i.settings=t,zo.language=t.language||"en",zo.languageLoad=t.language_load,zo.baseURL=n.baseURL,i.id=e,i.setDirty(!1),i.plugins={},i.documentBaseURI=new zg(t.document_base_url,{base_uri:o}),i.baseURI=o,i.contentCSS=[],i.contentStyles=[],i.shortcuts=new bd(i),i.loadedCSS={},i.editorCommands=new nd(i),i.suffix=n.suffix,i.editorManager=n,i.inline=t.inline,i.buttons={},i.menuItems={},t.cache_suffix&&(ae.cacheSuffix=t.cache_suffix.replace(/^[\?\&]+/,"")),!1===t.override_viewport&&(ae.overrideViewPort=!1),n.fire("SetupEditor",{editor:i}),i.execCallback("setup",i),i.$=Ut.overrideDefaults(function(){return{context:i.inline?i.getBody():i.getDoc(),element:i.getBody()}})};Kg(Zg.prototype={render:function(){!function(e){var t=e.settings,n=e.id,r=function(){Mg.unbind(window,"ready",r),e.render()};if(we.Event.domLoaded){if(e.getElement()&&ae.contentEditable){t.inline?e.inline=!0:(e.orgVisibility=e.getElement().style.visibility,e.getElement().style.visibility="hidden");var o=e.getElement().form||Mg.getParent(n,"form");o&&(e.formElement=o,t.hidden_input&&!/TEXTAREA|INPUT/i.test(e.getElement().nodeName)&&(Mg.insertAfter(Mg.create("input",{type:"hidden",name:n}),n),e.hasHiddenInput=!0),e.formEventDelegate=function(t){e.fire(t.type,t)},Mg.bind(o,"submit reset",e.formEventDelegate),e.on("reset",function(){e.setContent(e.startContent,{format:"raw"})}),!t.submit_patch||o.submit.nodeType||o.submit.length||o._mceOldSubmit||(o._mceOldSubmit=o.submit,o.submit=function(){return e.editorManager.triggerSave(),e.setDirty(!1),o._mceOldSubmit(o)})),e.windowManager=Bd(e),e.notificationManager=Pd(e),"xml"===t.encoding&&e.on("GetContent",function(e){e.save&&(e.content=Mg.encode(e.content))}),t.add_form_submit_trigger&&e.on("submit",function(){e.initialized&&e.save()}),t.add_unload_trigger&&(e._beforeUnload=function(){!e.initialized||e.destroyed||e.isHidden()||e.save({format:"raw",no_events:!0,set_dirty:!1})},e.editorManager.on("BeforeUnload",e._beforeUnload)),e.editorManager.add(e),function(e,t){var n=jo.ScriptLoader;!function(e,t,n,r){var o=t.settings,i=o.theme;
1if(Hn.isString(i)){if(!Hg(i)&&!Wd.urls.hasOwnProperty(i)){var a=o.theme_url;Wd.load(i,a?t.documentBaseURI.toAbsolute(a):"themes/"+i+"/theme"+n+".js")}e.loadQueue(function(){Wd.waitFor(i,r)})}else r()}(n,e,t,function(){!function(e,t){var n=t.settings;n.language&&"en"!==n.language&&!n.language_url&&(n.language_url=t.editorManager.baseURL+"/langs/"+n.language+".js"),n.language_url&&!t.editorManager.i18n.data[n.language]&&e.add(n.language_url)}(n,e),function(e,t){kt.isArray(e.plugins)&&(e.plugins=e.plugins.join(" ")),kt.each(e.external_plugins,function(t,n){Fd.load(n,t),e.plugins+=" "+n}),kt.each(e.plugins.split(/[ ,]/),function(e){if((e=kt.trim(e))&&!Fd.urls[e])if(Hg(e)){e=e.substr(1,e.length);var n=Fd.dependencies(e);kt.each(n,function(e){e=Fd.createUrl({prefix:"plugins/",resource:e,suffix:"/plugin"+t+".js"},e),Fd.load(e.resource,e)})}else Fd.load(e,{prefix:"plugins/",resource:e,suffix:"/plugin"+t+".js"})})}(e.settings,t),n.loadQueue(function(){e.removed||Lg(e)},e,function(t){Hd.pluginLoadError(e,t[0]),e.removed||Lg(e)})})}(e,e.suffix)}}else Mg.bind(window,"ready",r)}(this)},focus:function(e){!function(e,t){e.removed||(t?Td(e):function(e){var t,n=e.selection,r=e.settings.content_editable,o=e.getBody(),i=n.getRng();if(e.quirks.refreshContentEditable(),t=function(e,t){return e.dom.getParent(t,function(t){return"true"===e.dom.getContentEditable(t)})}(e,n.getNode()),e.$.contains(o,t))return Cd(t),xd(e,i),void Td(e);void 0!==e.bookmark&&!1===Sd(e)&&Xf.getRng(e).each(function(t){e.selection.setRng(t),i=t}),r||(ae.opera||Cd(o),e.getWin().focus()),(ae.gecko||r)&&(Cd(o),xd(e,i)),Td(e)}(e))}(this,e)},execCallback:function(e){var t,n=this.settings[e];if(n)return this.callbackLookup&&(t=this.callbackLookup[e])&&(n=t.func,t=t.scope),"string"==typeof n&&(t=(t=n.replace(/\.\w+$/,""))?Jg(t):0,n=Jg(n),this.callbackLookup=this.callbackLookup||{},this.callbackLookup[e]={func:n,scope:t}),n.apply(t||this,Array.prototype.slice.call(arguments,1))},translate:function(e){if(e&&kt.is(e,"string")){var t=this.settings.language||"en",n=this.editorManager.i18n;e=n.data[t+"."+e]||e.replace(/\{\#([^\}]+)\}/g,function(e,r){return n.data[t+"."+r]||"{#"+r+"}"})}return this.editorManager.translate(e)},getLang:function(e,t){return this.editorManager.i18n.data[(this.settings.language||"en")+"."+e]||(void 0!==t?t:"{#"+e+"}")},getParam:function(e,t,n){return function(e,t,n,r){var o=t in e.settings?e.settings[t]:n;return"hash"===r?function(e){var t={};return"string"==typeof e?P.each(e.indexOf("=")>0?e.split(/[;,](?![^=;,]*(?:[;,]|$))/):e.split(","),function(e){e=e.split("="),t[kt.trim(e[0])]=kt.trim(e.length>1?e[1]:e)}):t=e,t}(o):"string"===r?Tu(Hn.isString,e,t).getOr(n):"number"===r?Tu(Hn.isNumber,e,t).getOr(n):"boolean"===r?Tu(Hn.isBoolean,e,t).getOr(n):"object"===r?Tu(Hn.isObject,e,t).getOr(n):"array"===r?Tu(Hn.isArray,e,t).getOr(n):"function"===r?Tu(Hn.isFunction,e,t).getOr(n):o}(this,e,t,n)},nodeChanged:function(e){this._nodeChangeDispatcher.nodeChanged(e)},addButton:function(e,t){var n=this;t.cmd&&(t.onclick=function(){n.execCommand(t.cmd)}),t.stateSelector&&"undefined"==typeof t.active&&(t.active=!1),t.text||t.icon||(t.icon=e),n.buttons=n.buttons,t.tooltip=t.tooltip||t.title,n.buttons[e]=t},addSidebar:function(e,t){return function(e,t,n){var r=e.sidebars?e.sidebars:[];r.push({name:t,settings:n}),e.sidebars=r}(this,e,t)},addMenuItem:function(e,t){var n=this;t.cmd&&(t.onclick=function(){n.execCommand(t.cmd)}),n.menuItems=n.menuItems,n.menuItems[e]=t},addContextToolbar:function(e,t){var n,r=this;r.contextToolbars=r.contextToolbars||[],"string"==typeof e&&(n=e,e=function(e){return r.dom.is(e,n)}),r.contextToolbars.push({id:Jd.uuid("mcet"),predicate:e,items:t})},addCommand:function(e,t,n){this.editorCommands.addCommand(e,t,n)},addQueryStateHandler:function(e,t,n){this.editorCommands.addQueryStateHandler(e,t,n)},addQueryValueHandler:function(e,t,n){this.editorCommands.addQueryValueHandler(e,t,n)},addShortcut:function(e,t,n,r){this.shortcuts.add(e,t,n,r)},execCommand:function(e,t,n,r){return this.editorCommands.execCommand(e,t,n,r)},queryCommandState:function(e){return this.editorCommands.queryCommandState(e)},queryCommandValue:function(e){return this.editorCommands.queryCommandValue(e)},queryCommandSupported:function(e){return this.editorCommands.queryCommandSupported(e)},show:function(){this.hidden&&(this.hidden=!1,this.inline?this.getBody().contentEditable=!0:(Yg.show(this.getContainer()),Yg.hide(this.id
1)),this.load(),this.fire("show"))},hide:function(){var e=this.getDoc();this.hidden||(Qg&&e&&!this.inline&&e.execCommand("SelectAll"),this.save(),this.inline?(this.getBody().contentEditable=!1,this===this.editorManager.focusedEditor&&(this.editorManager.focusedEditor=null)):(Yg.hide(this.getContainer()),Yg.setStyle(this.id,"display",this.orgDisplay)),this.hidden=!0,this.fire("hide"))},isHidden:function(){return!!this.hidden},setProgressState:function(e,t){this.fire("ProgressState",{state:e,time:t})},load:function(e){var t,n=this.getElement();return this.removed?"":n?((e=e||{}).load=!0,t=this.setContent(void 0!==n.value?n.value:n.innerHTML,e),e.element=n,e.no_events||this.fire("LoadContent",e),e.element=n=null,t):void 0},save:function(e){var t,n,r=this,o=r.getElement();if(o&&r.initialized&&!r.removed)return(e=e||{}).save=!0,e.element=o,e.content=r.getContent(e),e.no_events||r.fire("SaveContent",e),"raw"===e.format&&r.fire("RawSaveContent",e),t=e.content,/TEXTAREA|INPUT/i.test(o.nodeName)?o.value=t:(r.inline||(o.innerHTML=t),(n=Yg.getParent(r.id,"form"))&&Gg(n.elements,function(e){if(e.name===r.id)return e.value=t,!1})),e.element=o=null,!1!==e.set_dirty&&r.setDirty(!1),t},setContent:function(e,t){return function(e,t,n){return void 0===n&&(n={}),n.format=n.format?n.format:"html",n.set=!0,n.content=Ug(t)?"":t,Ug(t)||n.no_events||(e.fire("BeforeSetContent",n),t=n.content),Ug(t)?function(e,t,n){var r;r=function(e,t,n){var r={},o={},i=[];for(var a in n.firstChild&&qg(n.firstChild,function(n){P.each(e,function(e){e.name===n.name&&(r[e.name]?r[e.name].nodes.push(n):r[e.name]={filter:e,nodes:[n]})}),P.each(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]})})}),r)r.hasOwnProperty(a)&&i.push(r[a]);for(var s in o)o.hasOwnProperty(s)&&i.push(o[s]);return i}(e.parser.getNodeFilters(),e.parser.getAttributeFilters(),t),P.each(r,function(e){P.each(e.filter.callbacks,function(t){t(e.nodes,e.filter.name,{})})});var o=lu({validate:e.validate},e.schema).serialize(t);return n.content=kt.trim(o),e.dom.setHTML(e.getBody(),n.content),n.no_events||e.fire("SetContent",n),t}(e,t,n):function(e,t,n){var r,o,i=e.getBody();return 0===t.length||/^\s+$/.test(t)?(o='<br data-mce-bogus="1">',"TABLE"===i.nodeName?t="<tr><td>"+o+"</td></tr>":/^(UL|OL)$/.test(i.nodeName)&&(t="<li>"+o+"</li>"),(r=e.settings.forced_root_block)&&e.schema.isValidChild(i.nodeName.toLowerCase(),r.toLowerCase())?t=e.dom.createHTML(r,e.settings.forced_root_block_attrs,t=o):t||(t='<br data-mce-bogus="1">'),e.dom.setHTML(i,t),e.fire("SetContent",n)):("raw"!==n.format&&(t=lu({validate:e.validate},e.schema).serialize(e.parser.parse(t,{isRootContent:!0,insert:!0}))),n.content=kt.trim(t),e.dom.setHTML(i,n.content),n.no_events||e.fire("SetContent",n)),n.content}(e,t,n)}(this,e,t)},getContent:function(e){return function(e,t){var n;void 0===t&&(t={});var r=e.getBody();if(e.removed)return"";if(t.format=t.format?t.format:"html",t.get=!0,t.getInner=!0,t.no_events||e.fire("BeforeGetContent",t),"raw"===t.format)n=kt.trim(qo(Lh(e.serializer,r.innerHTML)));else if("text"===t.format)n=r.innerText||r.textContent;else{if("tree"===t.format)return e.serializer.serialize(r,t);n=e.serializer.serialize(r,t)}return t.content="text"!==t.format?kt.trim(n):n,t.no_events||e.fire("GetContent",t),t.content}(this,e)},insertContent:function(e,t){t&&(e=Kg({content:e},t)),this.execCommand("mceInsertContent",!1,e)},isDirty:function(){return!this.isNotDirty},setDirty:function(e){var t=!this.isNotDirty;this.isNotDirty=!e,e&&e!==t&&this.fire("dirty")},setMode:function(e){!function(e,t){t!==(e.readonly?"readonly":"design")&&(e.initialized?pd(e,"readonly"===t):e.on("init",function(){pd(e,"readonly"===t)}),e.fire("SwitchMode",{mode:t}))}(this,e)},getContainer:function(){return this.container||(this.container=Yg.get(this.editorContainer||this.id+"_parent")),this.container},getContentAreaContainer:function(){return this.contentAreaContainer},getElement:function(){return this.targetElm||(this.targetElm=Yg.get(this.id)),this.targetElm},getWin:function(){var e;return this.contentWindow||(e=this.iframeElement)&&(this.contentWindow=e.contentWindow),this.contentWindow},getDoc:function(){var e;return this.contentDocument||(e=this.getWin())&&(this.contentDocument=e.document),this.contentDocument},getBody:function(){var e=this.getDoc();return this.bodyElement||(e?e.body:null)},convertURL:function(e,t,n){var r=this.settings;return r.urlconverter_callback?this.execCallback("urlconverter_callback",e,n,!0,t):!r.convert_urls||n&&"LINK"===n.nodeName||0===e.indexOf("file:")||0===e.length?e:r.relative_urls?this.documentBaseURI.toRelative(e):e=this.documentBaseURI.toAbsolute(e,r.remove_script_host)},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),Gg(o.select("table,a",e),function(e){var i;switch(e.nodeName){case"TABLE":return t=r.visual_table_class||"mce-item-table",void((i=o.getAttrib(e,"border"))&&"0"!==i||!n.hasVisual?o.removeClass(e,t):o.addClass(e,t));case"A":return void(o.getAttrib(e,"href",!1)||(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})},remove:function(){!function(e){if(!e.removed){var t=e._selectionOverrides,n=e.editorUpload,r
1=e.getBody(),o=e.getElement();r&&e.save(),e.removed=1,e.unbindAllNativeEvents(),e.hasHiddenInput&&o&&Vg.remove(o.nextSibling),!e.inline&&r&&function(e){e.orgDisplay&&Vg.setStyle(e.id,"display",e.orgDisplay)}(e),function(e){e.fire("remove")}(e),e.editorManager.remove(e),Vg.remove(e.getContainer()),Xg(t),Xg(n),e.destroy()}}(this)},destroy:function(e){!function(e,t){var n=e.selection,r=e.dom;e.destroyed||(t||e.removed?(t||(e.editorManager.off("beforeunload",e._beforeUnload),e.theme&&e.theme.destroy&&e.theme.destroy(),Xg(n),Xg(r)),function(e){var t=e.formElement;t&&(t._mceOldSubmit&&(t.submit=t._mceOldSubmit,t._mceOldSubmit=null),Vg.unbind(t,"submit reset",e.formEventDelegate))}(e),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)}(e),e.destroyed=1):e.remove())}(this,e)},uploadImages:function(e){return this.editorUpload.uploadImages(e)},_scanForImages:function(){return this.editorUpload.scanForImages()}},dd);var ev,tv,nv,rv={isEditorUIElement:function(e){return-1!==e.className.toString().indexOf("mce-")}},ov=Lo.DOM,iv=function(e,t){var n=e?e.settings.custom_ui_selector:"";return null!==ov.getParent(t,function(t){return function(e){return rv.isEditorUIElement(e)}(t)||!!n&&e.dom.is(t,n)})},av=function(e,t){var n=t.editor;(function(e){var t=Sh(function(){Xf.store(e)},0);e.inline&&function(e,t){var n=function(){t.throttle()};Lo.DOM.bind(document,"mouseup",n),e.on("remove",function(){Lo.DOM.unbind(document,"mouseup",n)})}(e,t),e.on("init",function(){!function(e,t){var n=Tn.detect().browser;
vendor: 5,728 bytes, line 1
1n.isIE()||n.isEdge()?function(e){e.on("focusout",function(){Xf.store(e)})}(e):function(e,t){e.on("mouseup touchend",function(e){t.throttle()})}(e,t),e.on("keyup nodechange",function(t){(function(e){return"nodechange"===e.type&&e.selectionChange})(t)||Xf.store(e)})}(e,t)}),e.on("remove",function(){t.cancel()})})(n),n.on("focusin",function(){var t=e.focusedEditor;t!==this&&(t&&t.fire("blur",{focusedEditor:this}),e.setActive(this),e.focusedEditor=this,this.fire("focus",{blurredEditor:t}),this.focus(!0))}),n.on("focusout",function(){var t=this;fe.setEditorTimeout(t,function(){var n=e.focusedEditor;iv(t,function(){try{return document.activeElement}catch(e){return document.body}}())||n!==t||(t.fire("blur",{focusedEditor:null}),e.focusedEditor=null)})}),ev||(ev=function(t){var n,r=e.activeEditor;n=t.target,r&&n.ownerDocument===document&&(n===document.body||iv(r,n)||e.focusedEditor!==r||(r.fire("blur",{focusedEditor:null}),e.focusedEditor=null))},ov.bind(document,"focusin",ev))},sv=function(e,t){e.focusedEditor===t.editor&&(e.focusedEditor=null),e.activeEditor||(ov.unbind(document,"focusin",ev),ev=null)},uv={},cv="en",lv={setCode:function(e){e&&(cv=e,this.rtl=!!this.data[e]&&"rtl"===this.data[e]._dir)},getCode:function(){return cv},rtl:!1,add:function(e,t){var n=uv[e];for(var r in n||(uv[e]=n={}),t)n[r]=t[r];this.setCode(e)},translate:function(e){var t=uv[cv]||{},n=function(e){return kt.is(e,"function")?Object.prototype.toString.call(e):r(e)?"":""+e},r=function(e){return""===e||null===e||kt.is(e,"undefined")},o=function(e){return e=n(e),kt.hasOwn(t,e)?n(t[e]):e};if(r(e))return"";if(kt.is(e,"object")&&kt.hasOwn(e,"raw"))return n(e.raw);if(kt.is(e,"array")){var i=e.slice(1);e=o(e[0]).replace(/\{([0-9]+)\}/g,function(e,t){return kt.hasOwn(i,t)?n(i[t]):e})}return o(e).replace(/{context:\w+}$/,"")},data:uv},fv=Lo.DOM,dv=kt.explode,hv=kt.each,pv=kt.extend,mv=0,gv=!1,vv=[],yv=[],bv=function(e){hv(nv.get(),function(t){t.fire("scroll"===e.type?"ScrollWindow":"ResizeWindow",e)})},wv=function(e){e!==gv&&(e?Ut(window).on("resize scroll",bv):Ut(window).off("resize scroll",bv),gv=e)},xv=function(e){var t=yv;delete vv[e.id];for(var n=0;n<vv.length;n++)if(vv[n]===e){vv.splice(n,1);break}return yv=P.filter(yv,function(t){return e!==t}),nv.activeEditor===e&&(nv.activeEditor=yv.length>0?yv[0]:null),nv.focusedEditor===e&&(nv.focusedEditor=null),t.length!==yv.length};pv(nv={defaultSettings:{},$:Ut,majorVersion:"4",minorVersion:"7.7",releaseDate:"2018-02-19",editors:vv,i18n:lv,activeEditor:null,settings:{},setup:function(){var e,t,n,r,o,i="";if(t=zg.getDocumentBaseUrl(document.location),/^[^:]+:\/\/\/?[^\/]+\//.test(t)&&(t=t.replace(/[\?#].*$/,"").replace(/[\/\\][^\/]+$/,""),/[\/\\]$/.test(t)||(t+="/")),n=window.tinymce||window.tinyMCEPreInit)e=n.base||n.baseURL,i=n.suffix;else{for(var a=document.getElementsByTagName("script"),s=0;s<a.length;s++){var u=(r=a[s].src).substring(r.lastIndexOf("/"));if(/tinymce(\.full|\.jquery|)(\.min|\.dev|)\.js/.test(r)){-1!==u.indexOf(".min")&&(i=".min"),e=r.substring(0,r.lastIndexOf("/"));break}}!e&&document.currentScript&&(-1!==(r=document.currentScript.src).indexOf(".min")&&(i=".min"),e=r.substring(0,r.lastIndexOf("/")))}this.baseURL=new zg(t).toAbsolute(e),this.documentBaseURL=t,this.baseURI=new zg(this.baseURL),this.suffix=i,(o=this).on("AddEditor",p.curry(av,o)),o.on("RemoveEditor",p.curry(sv,o))},overrideDefaults:function(e){var t;(t=e.base_url)&&(this.baseURL=new zg(this.documentBaseURL).toAbsolute(t.replace(/\/+$/,"")),this.baseURI=new zg(this.baseURL)),e.suffix&&(this.suffix=e.suffix),this.defaultSettings=e;var n=e.plugin_base_urls;for(var r in n)zo.PluginManager.urls[r]=n[r]},init:function(e){var t,n,r=this;n=kt.makeMap("area base basefont br col frame hr img input isindex link meta param embed source wbr track colgroup option tbody tfoot thead tr script noscript style textarea video audio iframe object menu"," ");var o=function(e){var t=e.id;return t||(t=(t=e.name)&&!fv.get(t)?e.name:fv.uniqueId(),e.setAttribute("id",t)),t},i=function(e,t){return t.constructor===RegExp?t.test(e.className):fv.hasClass(e,t)},a=function(e){t=e},s=function(){var t,u=0,c=[],l=function(e,n,o){var i=new Zg(e,n,r);c.push(i),i.on("init",function(){++u===t.length&&a(c)}),i.targetElm=i.targetElm||o,i.render()};fv.unbind(window,"ready",s),function(t){var n=e[t];n&&n.apply(r,Array.prototype.slice.call(arguments,2))}("onpageload"),t=Ut.unique(function(e){var t,n=[];if(ae.ie&&ae.ie<11)return Hd.initError("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(e.types)return hv(e.types,function(e){n=n.concat(fv.select(e.selector))}),n;if(e.selector)return fv.select(e.selector);if(e.target)return[e.target];switch(e.mode){case"exact":(t=e.elements||"").length>0&&hv(dv(t),function(e){var t;(t=fv.get(e))?n.push(t):hv(document.forms,function(t){hv(t.elements,function(t){t.name===e&&(e="mce_editor_"+mv++,fv.setAttrib(t,"id",e),n.push(t))})})});break;case"textareas":case"specific_textareas":hv(fv.select("textarea"),function(t){e.editor_deselector&&i(t,e.editor_deselector)||e.editor_selector&&!i(t,e.editor_selector)||n.push(t)})}return n}(e)),e.types?hv(e.types,function(n){kt.each(t,function(t){return!fv.is(t,n.selector)||(l(o(t),pv({},e,n),t),!1)})}):(kt.each(t,function(e){var t;(t=r.get(e.id))&&t.initialized&&!(t.getContainer()||t.getBody()).parentNode&&(xv(t),t.unbindAllNativeEvents(),t.destroy(!0),t.removed=!0,t=null)}),0===(t=kt.grep(t,function(e){return!r.get(e.id)})).length?a([]):hv(t,function(t){!function(e,t){return e.inline&&t.tagName.toLowerCase()in n}(e,t)?l(o(t),e,t):Hd.initError("Could not initialize inline editor on invali
1d inline target element",t)}))};return r.settings=e,fv.bind(window,"ready",s),new se(function(e){t?e(t):a=function(t){e(t)}})},get:function(e){return 0===arguments.length?yv.slice(0):Hn.isString(e)?P.find(yv,function(t){return t.id===e}).getOr(null):Hn.isNumber(e)&&yv[e]?yv[e]:null},add:function(e){var t=this;return vv[e.id]===e?e:(null===t.get(e.id)&&("length"!==e.id&&(vv[e.id]=e),vv.push(e),yv.push(e)),wv(!0),t.activeEditor=e,t.fire("AddEditor",{editor:e}),tv||(tv=function(){t.fire("BeforeUnload")},fv.bind(window,"beforeunload",tv)),e)},createEditor:function(e,t){return this.add(new Zg(e,t,this))},remove:function(e){var t,n,r=this;if(e){if(!Hn.isString(e))return Hn.isNull(r.get((n=e).id))?null:(xv(n)&&r.fire("RemoveEditor",{editor:n}),0===yv.length&&fv.unbind(window,"beforeunload",tv),n.remove(),wv(yv.length>0),n);hv(fv.select(e=e.selector||e),function(e){(n=r.get(e.id))&&r.remove(n)})}else for(t=yv.length-1;t>=0;t--)r.remove(yv[t])},execCommand:function(e,t,n){var r=this.get(n);switch(e){case"mceAddEditor":return this.get(n)||new Zg(n,this.settings,this).render(),!0;case"mceRemoveEditor":return r&&r.remove(),!0;case"mceToggleEditor":return r?(r.isHidden()?r.show():r.hide(),!0):(this.execCommand("mceAddEditor",0,n),!0)}return!!this.activeEditor&&this.activeEditor.execCommand(e,t,n)},triggerSave:function(){hv(yv,function(e){e.save()})},addI18n:function(e,t){lv.add(e,t)},translate:function(e){return lv.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}},sd),nv.setup();var Cv=nv;function Sv(e){return{walk:function(t,n){return Yh.walk(e,t,n)},split:el.split,normalize:function(t){return xf.normalize(e,t).fold(p.constant(!1),function(e){return t.setStart(e.startContainer,e.startOffset),t.setEnd(e.endContainer,e.endOffset),!0})}}}!function(e){e.compareRanges=ff,e.getCaretRangeFromPoint=lm,e.getSelectedNode=yi,e.getNode=bi}(Sv||(Sv={}));var Tv,Ev,kv=Sv,Nv=Math.min,Rv=Math.max,_v=Math.round,Av=function(e,t,n){var r,o,i,a,s,u;return r=t.x,o=t.y,i=e.w,a=e.h,s=t.w,u=t.h,"b"===(n=(n||"").split(""))[0]&&(o+=u),"r"===n[1]&&(r+=s),"c"===n[0]&&(o+=_v(u/2)),"c"===n[1]&&(r+=_v(s/2)),"b"===n[3]&&(o-=a),"r"===n[4]&&(r-=i),"c"===n[3]&&(o-=_v(a/2)),"c"===n[4]&&(r-=_v(i/2)),Dv(r,o,i,a)},Dv=function(e,t,n,r){return{x:e,y:t,w:n,h:r}},Ov={inflate:function(e,t,n){return Dv(e.x-t,e.y-n,e.w+2*t,e.h+2*n)},relativePosition:Av,findBestRelativePosition:function(e,t,n,r){var o,i;for(i=0;i<r.length;i++)if((o=Av(e,t,r[i])).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},intersect:function(e,t){var n,r,o,i;return n=Rv(e.x,t.x),r=Rv(e.y,t.y),o=Nv(e.x+e.w,t.x+t.w),i=Nv(e.y+e.h,t.y+t.h),o-n<0||i-r<0?null:Dv(n,r,o-n,i-r)},clamp:function(e,t,n){var r,o,i,a,s,u,c,l,f,d;return u=e.y,c=e.x+e.w,l=e.y+e.h,f=t.x+t.w,d=t.y+t.h,r=Rv(0,t.x-(s=e.x)),o=Rv(0,t.y-u),i=Rv(0,c-f),a=Rv(0,l-d),s+=r,u+=o,n&&(c+=r,l+=o,s-=i,u-=a),Dv(s,u,(c-=i)-s,(l-=a)-u)},create:Dv,fromClientRect:function(e){return Dv(e.left,e.top,e.width,e.height)}},Pv={},Bv={add:function(e,t){Pv[e.toLowerCase()]=t},has:function(e){return!!Pv[e.toLowerCase()]},get:function(e){var t=e.toLowerCase(),n=Pv.hasOwnProperty(t)?Pv[t]:null;if(null===n)throw new Error("Could not find module for type: "+e);return n},create:function(e,t){var n;if("string"==typeof e?(t=t||{}).type=e:e=(t=e).type,e=e.toLowerCase(),!(n=Pv[e]))throw new Error("Could not find control by type: "+e);return(n=new n(t)).type=e,n}},Iv=kt.each,Lv=kt.extend,Mv=function(){};Mv.extend=Tv=function(e){var t,n,r,o=this.prototype,i=function(){var e,t,n;if(!Ev&&(this.init&&this.init.apply(this,arguments),t=this.Mixins))for(e=t.length;e--;)(n=t[e]).init&&n.init.apply(this,arguments)},a=function(){return this},s=function(e,t){return function(){var n,r=this._super;return this._super=o[e],n=t.apply(this,arguments),this._super=r,n}};for(n in Ev=!0,t=new this,Ev=!1,e.Mixins&&(Iv(e.Mixins,function(t){for(var n in t)"init"!==n&&(e[n]=t[n])}),o.Mixins&&(e.Mixins=o.Mixins.concat(e.Mixins))),e.Methods&&Iv(e.Methods.split(","),function(t){e[t]=a}),e.Properties&&Iv(e.Properties.split(","),function(t){var n="_"+t;e[t]=function(e){return void 0!==e?(this[n]=e,this):this[n]}}),e.Statics&&Iv(e.Statics,function(e,t){i[t]=e}),e.Defaults&&o.Defaults&&(e.Defaults=Lv({},o.Defaults,e.Defaults)),e)t[n]="function"==typeof(r=e[n])&&o[n]?s(n,r):r;return i.prototype=t,i.constructor=i,i.extend=Tv,i};var Hv=Math.min,Fv=Math.max,Wv=Math.round,jv=function(e,t){var n,r,o,i;if(t=t||'"',null===e)return"null";if("string"==(o=typeof e))return r="\bb\tt\nn\ff\rr\"\"''\\\\",t+e.replace(/([\u0080-\uFFFF\x00-\x1f\"\'\\])/g,function(e,o){return'"'===t&&"'"===e?e:(n=r.indexOf(o))+1?"\\"+r.charAt(n+1):(e=o.charCo
vendor: 2,908 bytes, line 1
1deAt().toString(16),"\\u"+"0000".substring(e.length)+e)})+t;if("object"===o){if(e.hasOwnProperty&&"[object Array]"===Object.prototype.toString.call(e)){for(n=0,r="[";n<e.length;n++)r+=(n>0?",":"")+jv(e[n],t);return r+"]"}for(i in r="{",e)e.hasOwnProperty(i)&&(r+="function"!=typeof e[i]?(r.length>1?","+t:t)+i+t+":"+jv(e[i],t):"");return r+"}"}return""+e},$v={serialize:jv,parse:function(e){try{return JSON.parse(e)}catch(e){}}},zv={callbacks:{},count:0,send:function(e){var t=this,n=Lo.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++}},qv={send:function(e){var t,n=0,r=function(){!e.async||4===t.readyState||n++>1e4?(e.success&&n<1e4&&200===t.status?e.success.call(e.success_scope,""+t.responseText,t,e):e.error&&e.error.call(e.error_scope,n>1e4?"TIMED_OUT":"GENERAL",t,e),t=null):setTimeout(r,10)};if(e.scope=e.scope||this,e.success_scope=e.success_scope||e.scope,e.error_scope=e.error_scope||e.scope,e.async=!1!==e.async,e.data=e.data||"",qv.fire("beforeInitialize",{settings:e}),t=new jd){if(t.overrideMimeType&&t.overrideMimeType(e.content_type),t.open(e.type||(e.data?"POST":"GET"),e.url,e.async),e.crossDomain&&(t.withCredentials=!0),e.content_type&&t.setRequestHeader("Content-Type",e.content_type),e.requestheaders&&kt.each(e.requestheaders,function(e){t.setRequestHeader(e.key,e.value)}),t.setRequestHeader("X-Requested-With","XMLHttpRequest"),(t=qv.fire("beforeSend",{xhr:t,settings:e}).xhr).send(e.data),!e.async)return r();setTimeout(r,10)}}};kt.extend(qv,sd);var Uv=kt.extend,Vv=function(e){this.settings=Uv({},e),this.count=0};Vv.sendRPC=function(e){return(new Vv).send(e)},Vv.prototype={send:function(e){var t=e.error,n=e.success;(e=Uv(this.settings,e)).success=function(r,o){"undefined"==typeof(r=$v.parse(r))&&(r={error:"JSON Parse error."}),r.error?t.call(e.error_scope||e.scope,r.error,o):n.call(e.success_scope||e.scope,r.result)},e.error=function(n,r){t&&t.call(e.error_scope||e.scope,n,r)},e.data=$v.serialize({id:e.id||"c"+this.count++,method:e.method,params:e.params}),e.content_type="application/json",qv.send(e)}};var Xv=window.localStorage,Yv=kt.extend(Cv,{geom:{Rect:Ov},util:{Promise:se,Delay:fe,Tools:kt,VK:Th,URI:zg,Class:Mv,EventDispatcher:od,Observable:sd,I18n:lv,XHR:qv,JSON:$v,JSONRequest:Vv,JSONP:zv,LocalStorage:Xv,Color:function(e){var t={},n=0,r=0,o=0,i=function(e){var i;return"object"==typeof e?"r"in e?(n=e.r,r=e.g,o=e.b):"v"in e&&function(e,t,i){var a,s,u,c;if(e=(parseInt(e,10)||0)%360,t=parseInt(t,10)/100,i=parseInt(i,10)/100,t=Fv(0,Hv(t,1)),i=Fv(0,Hv(i,1)),0!==t){switch(a=e/60,u=(s=i*t)*(1-Math.abs(a%2-1)),c=i-s,Math.floor(a)){case 0:n=s,r=u,o=0;break;case 1:n=u,r=s,o=0;break;case 2:n=0,r=s,o=u;break;case 3:n=0,r=u,o=s;break;case 4:n=u,r=0,o=s;break;case 5:n=s,r=0,o=u;break;default:n=r=o=0}
1n=Wv(255*(n+c)),r=Wv(255*(r+c)),o=Wv(255*(o+c))}else n=r=o=Wv(255*i)}(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&&i(e),t.toRgb=function(){return{r:n,g:r,b:o}},t.toHsv=function(){return function(e,t,n){var r,o,i,a;return o=0,(i=Hv(e/=255,Hv(t/=255,n/=255)))===(a=Fv(e,Fv(t,n)))?{h:0,s:0,v:100*(o=i)}:(r=(a-i)/a,o=a,{h:Wv(60*((e===i?3:n===i?1:5)-(e===i?t-n:n===i?e-t:n-e)/(a-i))),s:Wv(100*r),v:Wv(100*o)})}(n,r,o)},t.toHex=function(){var e=function(e){return(e=parseInt(e,10).toString(16)).length>1?e:"0"+e};return"#"+e(n)+e(r)+e(o)},t.parse=i,t}},dom:{EventUtils:we,Sizzle:rt,DomQuery:Ut,TreeWalker:Rr,DOMUtils:Lo,ScriptLoader:jo,RangeUtils:kv,Serializer:em,ControlSelection:sm,BookmarkManager:om,Selection:Mm,Event:we.Event},html:{Styles:No,Entities:po,Node:Hp,Schema:Eo,SaxParser:Ih,DomParser:Kp,Writer:cu,Serializer:lu},ui:{Factory:Bv},Env:ae,AddOnManager:zo,Formatter:Np,UndoManager:zh,EditorCommands:nd,WindowManager:Bd,NotificationManager:Pd,EditorObservable:dd,Shortcuts:bd,Editor:Zg,FocusManager:rv,EditorManager:Cv,DOM:Lo.DOM,ScriptLoader:jo.ScriptLoader,PluginManager:zo.PluginManager,ThemeManager:zo.ThemeManager,trim:kt.trim,isArray:kt.isArray,is:kt.is,toArray:kt.toArray,makeMap:kt.makeMap,each:kt.each,map:kt.map,grep:kt.grep,inArray:kt.
1inArray,extend:kt.extend,create:kt.create,walk:kt.walk,createNS:kt.createNS,resolve:kt.resolve,explode:kt.explode,_addCacheSuffix:kt._addCacheSuffix,isOpera:ae.opera,isWebKit:ae.webkit,isIE:ae.ie,isGecko:ae.gecko,isMac:ae.mac});!function(e){window.tinymce=e,window.tinyMCE=e}(Yv),function(e){if("object"==typeof module)try{module.exports=e}catch(e){}}(Yv)}(),function(){"use strict";var e,t=tinymce.util.Tools.resolve("tinymce.ThemeManager"),n=tinymce.util.Tools.resolve("tinymce.EditorManager"),r=tinymce.util.Tools.resolve("tinymce.util.Tools"),o=function(e){return!1!==i(e)},i=function(e){return e.getParam("menubar")},a=function(e){return e.getParam("toolbar_items_size")},s=function(e){return e.getParam("menu")},u=function(e){return!1===e.settings.skin},c=function(e){var t=e.getParam("resize","vertical");return!1===t?"none":"both"===t?"both":"vertical"},l=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),f=tinymce.util.Tools.resolve("tinymce.ui.Factory"),d=tinymce.util.Tools.resolve("tinymce.util.I18n"),h=function(e){return e.fire("ResizeEditor")},p=function(e){return e.fire("BeforeRenderUI")},m=function(e,t){return function(){var n=e.find(t)[0];n&&n.focus(!0)}},g=function(e,t){e.shortcuts.add("Alt+F9","",m(t,"menubar")),e.shortcuts.add("Alt+F10,F10","",m(t,"toolbar")),e.shortcuts.add("Alt+F11","",m(t,"elementpath")),t.on("cancel",function(){e.focus()})},v=tinymce.util.Tools.resolve("tinymce.geom.Rect"),y=tinymce.util.Tools.resolve("tinymce.util.Delay"),b=function(e){return function(){return e}},w={noop:function(){},noarg:function(e){return function(){return e()}},compose:function(e,t){return function(){return e(t.apply(null,arguments))}},constant:b,identity:function(e){return e},tripleEquals:function(e,t){return e===t},curry:function(e){for(var t=new Array(arguments.length-1),n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];var o=t.concat(n);return e.apply(null,o)}},not:function(e){return function(){return!e.apply(null,arguments)}},die:function(e){return function(){throw new Error(e)}},apply:function(e){return e()},call:function(e){e()},never:b(!1),always:b(!0)},x=w.never,C=w.always,S=function(){return T},T=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:x,isSome:x,isNone:C,getOr:n,getOrThunk:t,getOrDie:function(e){throw new Error(e||"error: getOrDie called on none.")},or:n,orThunk:t,map:S,ap:S,each:function(){},bind:S,flatten:S,exists:x,forall:C,filter:S,equals:e,equals_:e,toArray:function(){return[]},toString:w.constant("none()")};return Object.freeze&&Object.freeze(r),r}(),E=function(e){var t=function(){return 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:C,isNone:x,getOr:t,getOrThunk:t,getOrDie:t,or:n,orThunk:n,map:function(t){return E(t(e))},ap:function(t){return t.fold(S,function(t){return E(t(e))})},each:function(t){t(e)},bind:r,flatten:t,exists:r,forall:r,filter:function(t){return t(e)?o:T},equals:function(t){return t.is(e)},equals_:function(t,n){return t.fold(x,function(t){return n(e,t)})},toArray:function(){return[e]},toString:function(){return"some("+e+")"}};return o},k={some:E,none:S,from:function(e){return null===e||void 0===e?T:E(e)}},N=function(e){return e?e.getRoot().uiContainer:null},R={getUiContainerDelta:function(e){var t=N(e);if(t&&"static"!==l.DOM.getStyle(t,"position",!0)){var n=l.DOM.getPos(t);return k.some({x:t.scrollLeft-n.x,y:t.scrollTop-n.y})}return k.none()},setUiContainer:function(e,t){var n=l.DOM.select(e.settings.ui_container)[0];t.getRoot().uiContainer=n},getUiContainer:N,inheritUiContainer:function(e,t){return t.uiContainer=N(e)}},_=function(e,t,n){var o,i=[];if(t)return r.each(t.split(/[ ,]/),function(t){var r=function(){var n=e.selection;t.settings.stateSelector&&n.selectorChanged(t.settings.stateSelector,function(e){t.active(e)},!0),t.settings.disabledStateSelector&&n.selectorChanged(t.settings.disabledStateSelector,function(e){t.disabled(e)})};"|"===t?o=null:(o||i.push(o={type:"buttongroup",items:[]}),e.buttons[t]&&("function"==typeof(t=e.buttons[t])&&(t=t()),t.type=t.type||"button",t.size=n,t=f.create(t),o.items.push(t),e.initialized?r():e.on("init",r)))}),{type:"toolbar",layout:"flow",items:i}},A=_,D=function(e,t){var n=[];if(r.each(function(e){var t=e.getParam("toolbar");return!1===t?[]:r.isArray(t)?r.grep(t,function(e){return e.length>0}):function(e,t){for(var n=[],r=1;r<10;r++){var o=e["toolbar"+r];if(!o)break;n.push(o)}return n.length>0?n:e.toolbar?[e.toolbar]:["undo redo | styleselect | bold italic | alignleft aligncenter alignright al
1ignjustify | bullist numlist outdent indent | link image"]}(e.settings)}(e),function(r){var o;(o=r)&&n.push(_(e,o,t))}),n.length)return{type:"panel",layout:"stack",classes:"toolbar-grp",ariaRoot:!0,ariaRemember:!0,items:n}},O=l.DOM,P=function(e){return{left:e.x,top:e.y,width:e.w,height:e.h,right:e.x+e.w,bottom:e.y+e.h}},B=function(e,t){e.moveTo(t.left,t.top)},I=function(e,t,n,r,o,i){return i=P({x:t,y:n,w:i.w,h:i.h}),e&&(i=e({elementRect:P(r),contentAreaRect:P(o),panelRect:i})),i},L=function(e){var t,n=function(){return e.contextToolbars||[]},o=function(t,n){var o,i,a,s,u,c,l,f=function(e){return e.getParam("inline_toolbar_position_handler")}(e);if(!e.removed)if(t&&t.toolbar.panel){var d,h,p,m;l=["bc-tc","tc-bc","tl-bl","bl-tl","tr-br","br-tr"],u=t.toolbar.panel,n&&u.show(),d=t.element,h=O.getPos(e.getContentAreaContainer()),p=e.dom.getRect(d),"BODY"===(m=e.dom.getRoot()).nodeName&&(p.x-=m.ownerDocument.documentElement.scrollLeft||m.scrollLeft,p.y-=m.ownerDocument.documentElement.scrollTop||m.scrollTop),p.x+=h.x,p.y+=h.y,a=p,i=O.getRect(u.getEl()),s=O.getRect(e.getContentAreaContainer()||e.getBody());var g=R.getUiContainerDelta(u).getOr({x:0,y:0});if(a.x+=g.x,a.y+=g.y,i.x+=g.x,i.y+=g.y,s.x+=g.x,s.y+=g.y,"inline"!==O.getStyle(t.element,"display",!0)){var y=t.element.getBoundingClientRect();a.w=y.width,a.h=y.height}e.inline||(s.w=e.getDoc().documentElement.offsetWidth),e.selection.controlSelection.isResizable(t.element)&&a.w<25&&(a=v.inflate(a,0,8)),o=v.findBestRelativePosition(i,a,s,l),a=v.clamp(a,s),o?(c=v.relativePosition(i,a,o),B(u,I(f,c.x,c.y,a,s,i))):(s.h+=i.h,(a=v.intersect(s,a))?(o=v.findBestRelativePosition(i,a,s,["bc-tc","bl-tl","br-tr"]))?(c=v.relativePosition(i,a,o),B(u,I(f,c.x,c.y,a,s,i))):B(u,I(f,a.x,a.y,a,s,i)):u.hide()),function(e,t,n){t=t?t.substr(0,2):"",r.each({t:"down",b:"up"},function(r,o){e.classes.toggle("arrow-"+r,n(o,t.substr(0,1)))}),r.each({l:"left",r:"right"},function(r,o){e.classes.toggle("arrow-"+r,n(o,t.substr(1,1)))})}(u,o,function(e,t){return e===t})}else!function(e){r.each(e.contextToolbars,function(e){e.panel&&e.panel.hide()})}(e)},i=function(t){return function(){y.requestAnimationFrame(function(){e.selection&&o(s(e.selection.getNode()),t)})}},a=function(){r.each(n(),function(e){e.panel&&e.panel.hide()})},s=function(t){var r,o,i,a=n();for(r=(i=e.$(t).parents().add(t)).length-1;r>=0;r--)for(o=a.length-1;o>=0;o--)if(a[o].predicate(i[r]))return{toolbar:a[o],element:i[r]};return null};e.on("click keyup setContent ObjectResized",function(n){("setcontent"!==n.type||n.selection)&&y.setEditorTimeout(e,function(){var n;(n=s(e.selection.getNode()))?(a(),function(n){var r;if(n.toolbar.panel)return n.toolbar.panel.show(),void o(n);r=f.create({type:"floatpanel",role:"dialog",classes:"tinymce tinymce-inline arrow",ariaLabel:"Inline toolbar",layout:"flex",direction:"column",align:"stretch",autohide:!1,autofix:!0,fixed:!0,border:1,items:A(e,n.toolbar.items),oncancel:function(){e.focus()}}),R.setUiContainer(e,r),function(n){if(!t){var r=i(!0),o=R.getUiContainer(n);t=e.selection.getScrollContainer()||e.getWin(),O.bind(t,"scroll",r),O.bind(o,"scroll",r),e.on("remove",function(){O.unbind(t,"scroll",r),O.unbind(o,"scroll",r)})}}(r),n.toolbar.panel=r,r.renderTo().reflow(),o(n)}(n)):a()})}),e.on("blur hide contextmenu",a),e.on("ObjectResizeStart",function(){var t=s(e.selection.getNode());t&&t.toolbar.panel&&t.toolbar.panel.hide()}),e.on("ResizeEditor ResizeWindow",i(!0)),e.on("nodeChange",i(!1)),e.on("remove",function(){r.each(n(),function(e){e.panel&&e.panel.remove()}),e.contextToolbars={}}),e.shortcuts.add("ctrl+shift+e > ctrl+shift+p","",function(){var t=s(e.selection.getNode());t&&t.toolbar.panel&&t.toolbar.panel.items()[0].focus()})},M=void 0===(e=Array.prototype.indexOf)?function(e,t){return $(e,t)}:function(t,n){return e.call(t,n)},H=function(e,t){for(var n=e.length,r=new Array(n),o=0;o<n;o++)r[o]=t(e[o],o,e);return r},F=function(e,t){for(var n=0,r=e.length;n<r;n++)t(e[n],n,e)},W=function(e,t){for(var n=[],r=0,o=e.length;r<o;r++){var i=e[r];t(i,r,e)&&n.push(i)}return n},j=function(e,t){for(var n=0,r=e.length;n<r;n++)if(t(e[n],n,e))return k.some(n);return k.none()},$=function(e,t){for(var n=0,r=e.length;n<r;++n)if(e[n]===t)return n;return-1},z=Array.prototype.push,q=function(e){for(var t=[],n=0,r=e.length;n<r;++n){if(!Array.prototype.isPrototypeOf(e[n]))throw new Error("Arr.flatten item "+n+" was not an array, input
1: "+e);z.apply(t,e[n])}return t},U=(Array,H),V=F,X=W,Y=function(e,t){var n=M(e,t);return-1===n?k.none():k.some(n)},K=function(e,t,n){return F(e,function(e){n=t(n,e)}),n},G=function(e,t){for(var n=0,r=e.length;n<r;n++){var o=e[n];if(t(o,n,e))return k.some(o)}return k.none()},J=j,Q=q,Z=function(e,t){return j(e,t).isSome()},ee={file:{title:"File",items:"newdocument restoredraft | preview | print"},edit:{title:"Edit",items:"undo redo | cut copy paste pastetext | selectall"},view:{title:"View",items:"code | visualaid visualchars visualblocks | spellchecker | preview fullscreen"},insert:{title:"Insert",items:"image link media template codesample inserttable | charmap hr | pagebreak nonbreaking anchor toc | insertdatetime"},format:{title:"Format",items:"bold italic underline strikethrough superscript subscript codeformat | blockformats align | removeformat"},tools:{title:"Tools",items:"spellchecker spellcheckerlanguage | a11ycheck"},table:{title:"Table"},help:{title:"Help"}},te=function(e,t){return"|"===e?{name:"|",item:{text:"|"}}:t?{name:e,item:t}:null},ne=function(e){return e&&"|"===e.item.text},re=function(e,t,n,o){var i,a,s,u;return t?(a=t[o],u=!0):a=ee[o],a&&(i={text:a.title},s=[],r.each((a.items||"").split(/[ ,]/),function(t){var n=te(t,e[t]);n&&s.push(n)}),u||r.each(e,function(e,t){e.context!==o||function(e,t){return J(e,function(e){return e.name===t}).isSome()}(s,t)||("before"===e.separator&&s.push({name:"|",item:{text:"|"}}),e.prependToContext?s.unshift(te(t,e)):s.push(te(t,e)),"after"===e.separator&&s.push({name:"|",item:{text:"|"}}))}),i.menu=U(function(e,t){var n=X(e,function(e){return!1===t.hasOwnProperty(e.name)}),r=X(n,function(e,t,n){return!ne(e)||!ne(n[t-1])});return X(r,function(e,t,n){return!ne(e)||t>0&&t<n.length-1})}(s,n),function(e){return e.item}),!i.menu.length)?null:i},oe=function(e){for(var t=[],n=function(e){var t,n=[],r=s(e);if(r)for(t in r)n.push(t);else for(t in ee)n.push(t);return n}(e),o=r.makeMap(function(e){return e.getParam("removed_menuitems","")}(e).split(/[ ,]/)),a=i(e),u="string"==typeof a?a.split(/[ ,]/):n,c=0;c<u.length;c++){var l=u[c],f=re(e.menuItems,s(e),o,l);f&&t.push(f)}return t},ie=l.DOM,ae=function(e){return{width:e.clientWidth,height:e.clientHeight}},se=function(e,t,n){var r,o,i,a;r=e.getContainer(),o=e.getContentAreaContainer().firstChild,i=ae(r),a=ae(o),null!==t&&(t=Math.max(function(e){return e.getParam("min_width",100,"number")}(e),t),t=Math.min(function(e){return e.getParam("max_width",65535,"number")}(e),t),ie.setStyle(r,"width",t+(i.width-a.width)),ie.setStyle(o,"width",t)),n=Math.max(function(e){return e.getParam("min_height",100,"number")}(e),n),n=Math.min(function(e){return e.getParam("max_height",65535,"number")}(e),n),ie.setStyle(o,"height",n),h(e)},ue=se,ce=tinymce.util.Tools.resolve("tinymce.Env"),le=function(e,t,n){var r,o=e.settings[n];o&&o((r=t.getEl("body"),{element:function(){return r}}))},fe=function(e){var t=function(){e._skinLoaded=!0,function(e){e.fire("SkinLoaded")}(e)};return function(){e.initialized?t():e.on("init",t)}},de=l.DOM,he=function(e){return{type:"panel",name:"iframe",layout:"stack",classes:"edit-area",border:e,html:""}},pe=function(e,t,n){var i,s,l;if(!1===u(e)&&n.skinUiCss?de.styleSheetLoader.load(n.skinUiCss,fe(e)):fe(e)(),i=t.panel=f.create({type:"panel",role:"application",classes:"tinymce",style:"visibility: hidden",layout:"stack",border:1,items:[{type:"container",classes:"top-part",items:[!1===o(e)?null:{type:"menubar",border:"0 0 1 0",items:oe(e)},D(e,a(e))]},function(e){return!(ce.ie&&!(ce.ie>=11)||!e.sidebars)&&e.sidebars.length>0}(e)?function(e){return{type:"panel",layout:"stack",classes:"edit-aria-container",border:"1 0 0 0",items:[he("0"),function(e){return{type:"panel",name:"sidebar",layout:"stack",classes:"sidebar",items:[{type:"toolbar",layout:"stack",classes:"sidebar-toolbar",items:r.map(e.sidebars,function(t){var n=t.settings;return{type:"button",icon:n.icon,image:n.image,tooltip:n.tooltip,onclick:function(e,t,n){return function(o){var i=o.control,a=i.parents().filter("panel")[0],s=a.find("#"+t)[0],u=function(e,t){return r.grep(e,function(e){return e.name===t})[0]}(n,t);!function(e,t,n){r.each(n,function(n){var r=t.items().filter("#"+n.name)[0];r&&r.visible()&&n.name!==e&&(le(n,r,"onhide"),r.visible(!1))})}(t,a,n),i.parent().items().each(function(e){e.active(!1)}),s&&s.visible()?(le(u,s,"onhide"),s.hide(),i.active(!1)):(s?(s.show(),le(u,s,"onshow")):(s=f.create({type:"container",name:t,layout:"stack",classes:"sidebar-panel",html:""}),a.prepend(s),le(u,s,"onrender"),le(u,s,"onshow")),i.active(!0)),h(e)}}(e,t.name,e.sidebars)}})}]}}(e)]}}(e):he("1 0 0 0")]}),R.setUiContainer(e,i),"none"!==c(e)&&(s={type:"resizehandle",direction:c(e),onResizeStart:function(){var t=e.getContentAreaContainer().firstChild;l={width:t.clientWidth,height:t.clientHeight}},onResize:function(t){"both"===c(e)?ue(e,l.width+t.deltaX,l.height+t.deltaY):ue(e,null,l.height+t.deltaY)}}),function(e){return e.getParam("statusbar",!0,"boolean")}(e)){var m=d.translate(["Powered by {0}",'<a href="https://www.tinymce.com/?utm_campaign=editor_referral&utm_medium=poweredby&utm_source=tinymce" rel="noopener" target="_blank" role="presentation" tabindex="-1">tinymce</a>']),v=function(e){return e.getParam("branding",!0,"boolean")}(e)?{type:"label",classes:"branding",html:" "+m}:null;i.add({type:"panel",name:"statusbar",classes:"statusbar",layout:"flow",border:"1 0 0 0",ariaRoot:!0,items:[{type:"elementpath",editor:e},s,v]})}return p(e),e.on("SwitchMode",function(e){return function(t){e.find("*").disabled("readonly"===t.mode)}}(i)),i.renderBefore(n.targetNode).reflow(),function(e){return e.getParam("readonly",!1,"boolean")}(e)&&e.setMode("readonly"),n.width&&de.setStyle(i.getEl(),"width",n.width),e.on("remove",function(){i.remove(),i=null}
vendor: 11,222 bytes, line 1
1),g(e,i),L(e),{iframeContainer:i.find("#iframe")[0].getEl(),editorContainer:i.getEl()}},me=tinymce.util.Tools.resolve("tinymce.dom.DomQuery"),ge=0,ve={id:function(){return"mceu_"+ge++},create:function(e,t,n){var o=document.createElement(e);return l.DOM.setAttribs(o,t),"string"==typeof n?o.innerHTML=n:r.each(n,function(e){e.nodeType&&o.appendChild(e)}),o},createFragment:function(e){return l.DOM.createFragment(e)},getWindowSize:function(){return l.DOM.getViewPort()},getSize:function(e){var t,n;if(e.getBoundingClientRect){var r=e.getBoundingClientRect();t=Math.max(r.width||r.right-r.left,e.offsetWidth),n=Math.max(r.height||r.bottom-r.bottom,e.offsetHeight)}else t=e.offsetWidth,n=e.offsetHeight;return{width:t,height:n}},getPos:function(e,t){return l.DOM.getPos(e,t||ve.getContainer())},getContainer:function(){return ce.container?ce.container:document.body},getViewPort:function(e){return l.DOM.getViewPort(e)},get:function(e){return document.getElementById(e)},addClass:function(e,t){return l.DOM.addClass(e,t)},removeClass:function(e,t){return l.DOM.removeClass(e,t)},hasClass:function(e,t){return l.DOM.hasClass(e,t)},toggleClass:function(e,t,n){return l.DOM.toggleClass(e,t,n)},css:function(e,t,n){return l.DOM.setStyle(e,t,n)},getRuntimeStyle:function(e,t){return l.DOM.getStyle(e,t,!0)},on:function(e,t,n,r){return l.DOM.bind(e,t,n,r)},off:function(e,t,n){return l.DOM.unbind(e,t,n)},fire:function(e,t,n){return l.DOM.fire(e,t,n)},innerHtml:function(e,t){l.DOM.setHTML(e,t)}},ye=function(e){return"static"===ve.getRuntimeStyle(e,"position")},be=function(e){return e.state.get("fixed")};function we(e,t,n){var r,o,i,a,s,u,c,l,f,d;return f=xe(),i=(o=ve.getPos(t,R.getUiContainer(e))).x,a=o.y,be(e)&&ye(document.body)&&(i-=f.x,a-=f.y),r=e.getEl(),s=(d=ve.getSize(r)).width,u=d.height,c=(d=ve.getSize(t)).width,l=d.height,"b"===(n=(n||"").split(""))[0]&&(a+=l),"r"===n[1]&&(i+=c),"c"===n[0]&&(a+=Math.round(l/2)),"c"===n[1]&&(i+=Math.round(c/2)),"b"===n[3]&&(a-=u),"r"===n[4]&&(i-=s),"c"===n[3]&&(a-=Math.round(u/2)),"c"===n[4]&&(i-=Math.round(s/2)),{x:i,y:a,w:s,h:u}}var xe=function(){return{x:0,y:0,w:Math.max(document.body.scrollWidth,document.documentElement.scrollWidth,document.defaultView.innerWidth),h:Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.defaultView.innerHeight)}},Ce=function(e){var t=R.getUiContainer(e);return t&&!be(e)?function(e){return{x:0,y:0,w:e.scrollWidth-1,h:e.scrollHeight-1}}(t):xe()},Se={testMoveRel:function(e,t){for(var n=Ce(this),r=0;r<t.length;r++){var o=we(this,e,t[r]);if(be(this)){if(o.x>0&&o.x+o.w<n.w&&o.y>0&&o.y+o.h<n.h)return t[r]}else if(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 t[r]}return t[0]},moveRel:function(e,t){"string"!=typeof t&&(t=this.testMoveRel(e,t));var n=we(this,e,t);return this.moveTo(n.x,n.y)},moveBy:function(e,t){var n=this.layoutRect();return this.moveTo(n.x+e,n.y+t),this},moveTo:function(e,t){function n(e,t,n){return e<0?0:e+n>t&&(e=t-n)<0?0:e}if(this.settings.constrainToViewport){var r=Ce(this),o=this.layoutRect();e=n(e,r.w+r.x,o.w),t=n(t,r.h+r.y,o.h)}var i=R.getUiContainer(this);return i&&ye(i)&&!be(this)&&(e-=i.scrollLeft,t-=i.scrollTop),i&&(e+=1,t+=1),this.state.get("rendered")?this.layoutRect({x:e,y:t}).repaint():(this.settings.x=e,this.settings.y=t),this.fire("move",{x:e,y:t}),this}},Te=tinymce.util.Tools.resolve("tinymce.util.Class"),Ee=tinymce.util.Tools.resolve("tinymce.util.EventDispatcher"),ke=function(e){var t;if(e)return"number"==typeof e?{top:e=e||0,left:e,bottom:e,right:e}:(1===(t=(e=e.split(" ")).length)?e[1]=e[2]=e[3]=e[0]:2===t?(e[2]=e[0],e[3]=e[1]):3===t&&(e[3]=e[1]),{top:parseInt(e[0],10)||0,right:parseInt(e[1],10)||0,bottom:parseInt(e[2],10)||0,left:parseInt(e[3],10)||0})},Ne=function(e,t){function n(t){var n=parseFloat(function(t){var n=e.ownerDocument.defaultView;if(n){var r=n.getComputedStyle(e,null);return r?(t=t.replace(/[A-Z]/g,function(e){return"-"+e}),r.getPropertyValue(t)):null}return e.currentStyle[t]}(t));return isNaN(n)?0:n}return{top:n(t+"TopWidth"),right:n(t+"RightWidth"),bottom:n(t+"BottomWidth"),left:n(t+"LeftWidth")}};function Re(){}function _e(e){this.cls=[],this.cls._map={},this.onchange=e||Re,this.prefix=""}r.extend(_e.prototype,{add:function(e){return e&&!this.contains(e)&&(this.cls._map[e]=!0,this.cls.push(e),this._change()),this},remove:function(e){if(this.contains(e)){var t=void 0;for(t=0;t<this.cls.length&&this.cls[t]!==e;t++);this.cls.splice(t,1),delete this.cls._map[e],this._change()}return this},toggle:function(e,t){var n=this.contains(e);return n!==t&&(n?this.remove(e):this.add(e),this._change()),this},contains:function(e){return!!this.cls._map[e]},_change:function(){delete this.clsValue,this.onchange.call(this)}}),_e.prototype.toString=function(){var e;if(this.clsValue)return this.clsValue;e="";for(var t=0;t<this.cls.length;t++)t>0&&(e+=" "),e+=this.prefix+this.cls[t];return e};var Ae,De,Oe,Pe=/^([\w\\*]+)?(?:#([\w\-\\]+))?(?:\.([\w\\\.]+))?(?:\[\@?([\w\\]+)([\^\$\*!~]?=)([\w\\]+)\])?(?:\:(.+))?/i,Be=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,Ie=/^\s*|\s*$/g,Le=Te.extend({init:function(e){var t=this.match;function n(e,n,o){var i;function a(e){e&&n.push(e)}return a(function(e){if(e)return e=e.toLowerCase(),function(t){return"*"===e||t.type===e}}((i=Pe.exec(e.replace(Ie,"")))[1])),a(function(e){if(e)return function(t){return t._name===e}}(i[2])),a(function(e){if(e)return e=e.split("."),function(t){for(var n=e.length;n--;)if(!t.classes.contains(e[n]))return!1;return!0}}(i[3])),a(function(e,t,n){if(e)return function(r){var o=r[e]?r[e]():"";return t?"="===t?o===n:"*="===t?o.indexOf(n)>=0:"~="===t?(" "+o+" ").indexOf(" "+n+" ")>=0:"!="===t?o!==n:"^="===t?0===o.indexOf(n):"$="===t&&o.substr(o.length-n.length)===n:!!n}}(i[4],i[5],i[6])),a(function(e){var n;if(e)return(e=/(?:not\((.+)\))|(.+)/i.exec(e))[1]?(n=r(e[1],[]),function(e){return!t(e,n)}):(e=e[2],function(t,n,r){return"first"===e?0===n:"last"===e?n===r-1:"even"===e?n%2==0:"odd"===e?n%2==1:!!t[e]&&t[e]()})}(i[7])),n.pseudo=!!i[7],n.direct=o,n}function r(e,t){var o,i,a,s=[];do{if(Be.exec(""),(i=Be.exec(e))&&(e=i[3],s.push(i[1]),i[2])){o=i[3];break}}while(i);for(o&&r(o,t),e=[],a=0;a<s.length;a++)">"!==s[a]&&e.push(n(s[a],[],">"===s[a-1]));return t.push(e),t}this._selectors=r(e,[])},match:function(e,t){var n,r,o,i,a,s,u,c,l,f,d,h,p;for(n=0,r=(t=t||this._selectors).length;n<r;n++){for(p=e,h=0,o=(i=(a=t[n]).length)-1;o>=0;o--)for(c=a[o];p;){if(c.pseudo)for(l=f=(d=p.parent().items()).length;l--&&d[l]!==p;);for(s=0,u=c.length;s<u;s++)if(!c[s](p,l,f)){s=u+1;break}if(s===u){h++;break}if(o===i-1)break;p=p.parent()}if(h===i)return!0}return!1},find:function(e){var t,n,r=[],o=this._selectors;function i(e,t,n){var o,a,s,u,c,l=t[n];for(o=0,a=e.length;o<a;o++){for(c=e[o],s=0,u=l.length;s<u;s++)if(!l[s](c,o,a)){s=u+1;break}if(s===u)n===t.length-1?r.push(c):c.items&&i(c.items(),t,n+1);else if(l.direct)return;c.items&&i(c.items(),t,n)}}if(e.items){for(t=0,n=o.length;t<n;t++)i(e.items(),o[t],0);n>1&&(r=function(e){for(var t,n=[],r=e.length;r--;)(t=e[r]).__checked||(n.push(t),t.__checked=1);for(r=n.length;r--;)delete n[r].__checked;return n}(r))}return Ae||(Ae=Le.Collection),new Ae(r)}}),Me=Array.prototype.push,He=Array.prototype.slice;Oe={length:0,init:function(e){e&&this.add(e)},add:function(e){return r.isArray(e)?Me.apply(this,e):e instanceof De?this.add(e.toArray()):Me.call(this,e),this},set:function(e){var t,n=this.length;for(this.length=0,this.add(e),t=this.length;t<n;t++)delete this[t];return this},filter:function(e){var t,n,r,o,i=[];for("string"==typeof e?(e=new Le(e),o=function(t){return e.match(t)}):o=e,t=0,n=this.length;t<n;t++)o(r=this[t])&&i.push(r);return new De(i)},slice:function(){return new De(He.apply(this,arguments))},eq:function(e){return-1===e?this.slice(e):this.slice(e,+e+1)},each:function(e){return r.each(this,e),this},toArray:function(){return r.toArray(this)},indexOf:function(e){for(var t=this.length;t--&&this[t]!==e;);return t},reverse:function(){return new De(r.toArray(this).reverse())},hasClass:function(e){return!!this[0]&&this[0].classes.contains(e)},prop:function(e,t){var n;return void 0!==t?(this.each(function(n){n[e]&&n[e](t)}),this):(n=this[0])&&n[e]?n[e]():void 0},exec:function(e){var t=r.toArray(arguments).slice(1);return this.each(function(n){n[e]&&n[e].apply(n,t)}),this},remove:function(){for(var e=this.length;e--;)this[e].remove();return this},addClass:function(e){return this.each(function(t){t.classes.add(e)})},removeClass:function(e){return this.each(function(t){t.classes.remove(e)})}},r.each("fire on off show hide append prepend before after reflow".split(" "),function(e){Oe[e]=function(){var t=r.toArray(arguments);return this.each(function(n){e in n&&n[e].apply(n,t)}),this}}),r.each("text name disabled active selected checked visible parent value data".split(" "),function(e){Oe[e]=function(t){return this.prop(e,t)}}),De=Te.extend(Oe),Le.Collection=De;var Fe=De,We=function(e){this.create=e.create};We.create=function(e,t){return new We({create:function(n,r){var o,i=function(e){n.set(r,e.value)};return n.on("change:"+r,function(n){e.set(t,n.value)}),e.on("change:"+t,i),(o=n._bindings)||(o=n._bindings=[],n.on("destroy",function(){for(var e=o.length;e--;)o[e]()})),o.push(function(){e.off("change:"+t,i)}),e.get(t)}})};var je=tinymce.util.Tools.resolve("tinymce.util.Observable");function $e(e){return e.nodeType>0}var ze,qe,Ue=Te.extend({Mixins:[je],init:function(e){var t,n;for(t in e=e||{})(n=e[t])instanceof We&&(e[t]=n.create(this,t));this.data=e},set:function(e,t){var n,o,i=this.data[e];if(t instanceof We&&(t=t.create(this,e)),"object"==typeof e){for(n in e)this.set(n,e[n]);return this}return function e(t,n){var o,i;if(t===n)return!0;if(null===t||null===n)return t===n;if("object"!=typeof t||"object"!=typeof n)return t===n;if(r.isArray(n)){if(t.length!==n.length)return!1;for(o=t.length;o--;)if(!e(t[o],n[o]))return!1}if($e(t)||$e(n))return t===n;for(o in i={},n){if(!e(t[o],n[o]))return!1;i[o]=!0}for(o in t)if(!i[o]&&!e(t[o],n[o]))return!1;return!0}(i,t)||(this.data[e]=t,this.fire("change:"+e,o={target:this,name:e,value:t,oldValue:i}),this.fire("change",o)),this},get:function(e){return this.data[e]},has:function(e){return e in this.data},bind:function(e){return We.create(this,e)},destroy:function(){this.fire("destroy")}}),Ve={},Xe={add:function(e){var t=e.parent();if(t){if(!t._layout||t._layout.isNative())return;Ve[t._id]||(Ve[t._id]=t),ze||(ze=!0,y.requestAnimationFrame(function(){var e,t;for(e in ze=!1,Ve)(t=Ve[e]).state.get("rendered")&&t.reflow();Ve={}},document.body))}},remove:function(e){Ve[e._id]&&delete Ve[e._id]}},Ye="onmousewheel"in document,Ke=!1,Ge=0,Je={Statics:{classPrefix:"mce-"},isRtl:function(){return qe.rtl},classPrefix:"mce-",init:function(e){var t,n,o=this;function i(e){var t;for(e=e.split(" "),t=0;t<e.length;t++)o.classes.add(e[t])}o.settings=e=r.extend({},o.Defaults,e),o._id=e.id||"mceu_"+Ge++,o._aria={role:e.role},o._elmCache={},o.$=me,o.state=new Ue({visible:!0,active:!1,disabled:!1,value:""}),o.data=new Ue(e.data),o.classes=new _e(function(){o.state.get("rendered")&&(o.getEl().className=this.toString())}
1),o.classes.prefix=o.classPrefix,(t=e.classes)&&(o.Defaults&&(n=o.Defaults.classes)&&t!==n&&i(n),i(t)),r.each("title text name visible disabled active value".split(" "),function(t){t in e&&o[t](e[t])}),o.on("click",function(){if(o.disabled())return!1}),o.settings=e,o.borderBox=ke(e.border),o.paddingBox=ke(e.padding),o.marginBox=ke(e.margin),e.hidden&&o.hide()},Properties:"parent,name",getContainerElm:function(){return R.getUiContainer(this)||ve.getContainer()},getParentCtrl:function(e){for(var t,n=this.getRoot().controlIdLookup;e&&n&&!(t=n[e.id]);)e=e.parentNode;return t},initLayoutRect:function(){var e,t,n,r,o,i,a,s,u,c,l=this.settings,f=this.getEl();e=this.borderBox=this.borderBox||Ne(f,"border"),this.paddingBox=this.paddingBox||Ne(f,"padding"),this.marginBox=this.marginBox||Ne(f,"margin"),c=ve.getSize(f),u=l.minHeight,o=(s=l.minWidth)||c.width,i=u||c.height,n=l.width,r=l.height,a="undefined"!=typeof(a=l.autoResize)?a:!n&&!r,n=n||o,r=r||i;var d=e.left+e.right,h=e.top+e.bottom,p=l.maxWidth||65535,m=l.maxHeight||65535;return this._layoutRect=t={x:l.x||0,y:l.y||0,w:n,h:r,deltaW:d,deltaH:h,contentW:n-d,contentH:r-h,innerW:n-d,innerH:r-h,startMinWidth:s||0,startMinHeight:u||0,minW:Math.min(o,p),minH:Math.min(i,m),maxW:p,maxH:m,autoResize:a,scrollW:0},this._lastLayoutRect={},t},layoutRect:function(e){var t,n,r,o,i,a=this._layoutRect;return a||(a=this.initLayoutRect()),e?(r=a.deltaW,o=a.deltaH,void 0!==e.x&&(a.x=e.x),void 0!==e.y&&(a.y=e.y),void 0!==e.minW&&(a.minW=e.minW),void 0!==e.minH&&(a.minH=e.minH),void 0!==(n=e.w)&&(a.w=n=(n=n<a.minW?a.minW:n)>a.maxW?a.maxW:n,a.innerW=n-r),void 0!==(n=e.h)&&(a.h=n=(n=n<a.minH?a.minH:n)>a.maxH?a.maxH:n,a.innerH=n-o),void 0!==(n=e.innerW)&&(a.innerW=n=(n=n<a.minW-r?a.minW-r:n)>a.maxW-r?a.maxW-r:n,a.w=n+r),void 0!==(n=e.innerH)&&(a.innerH=n=(n=n<a.minH-o?a.minH-o:n)>a.maxH-o?a.maxH-o:n,a.h=n+o),void 0!==e.contentW&&(a.contentW=e.contentW),void 0!==e.contentH&&(a.contentH=e.contentH),(t=this._lastLayoutRect).x===a.x&&t.y===a.y&&t.w===a.w&&t.h===a.h||((i=qe.repaintControls)&&i.map&&!i.map[this._id]&&(i.push(this),i.map[this._id]=!0),t.x=a.x,t.y=a.y,t.w=a.w,t.h=a.h),this):a},repaint:function(){var e,t,n,r,o,i,a,s,u,c;u=document.createRange?function(e){return e}:Math.round,e=this.getEl().style,i=(o=this.borderBox).left+o.right,a=o.top+o.bottom,(r=this._layoutRect).x!==(s=this._lastRepaintRect||{}).x&&(e.left=u(r.x)+"px",s.x=r.x),r.y!==s.y&&(e.top=u(r.y)+"px",s.y=r.y),r.w!==s.w&&(c=u(r.w-i),e.width=(c>=0?c:0)+"px",s.w=r.w),r.h!==s.h&&(c=u(r.h-a),e.height=(c>=0?c:0)+"px",s.h=r.h),this._hasBody&&r.innerW!==s.innerW&&(c=u(r.innerW),(n=this.getEl("body"))&&((t=n.style).width=(c>=0?c:0)+"px"),s.innerW=r.innerW),this._hasBody&&r.innerH!==s.innerH&&(c=u(r.innerH),(n=n||this.getEl("body"))&&((t=t||n.style).height=(c>=0?c:0)+"px"),s.innerH=r.innerH),this._lastRepaintRect=s,this.fire("repaint",{},!1)},updateLayoutRect:function(){this.parent()._lastRect=null,ve.css(this.getEl(),{width:"",height:""}),this._layoutRect=this._lastRepaintRect=this._lastLayoutRect=null,this.initLayoutRect()},on:function(e,t){var n=this;return Qe(n).on(e,function(e){var t,r;return"string"!=typeof e?e:function(o){return t||n.parentsAndSelf().each(function(n){var o=n.settings.callbacks;if(o&&(t=o[e]))return r=n,!1}),t?t.call(r,o):(o.action=e,void this.fire("execute",o))}}(t)),n},off:function(e,t){return Qe(this).off(e,t),this},fire:function(e,t,n){if((t=t||{}).control||(t.control=this),t=Qe(this).fire(e,t),!1!==n&&this.parent)for(var r=this.parent();r&&!t.isPropagationStopped();)r.fire(e,t,!1),r=r.parent();return t},hasEventListeners:function(e){return Qe(this).has(e)},parents:function(e){var t,n=new Fe;for(t=this.parent();t;t=t.parent())n.add(t);return e&&(n=n.filter(e)),n},parentsAndSelf:function(e){return new Fe(this).add(this.parents(e))},next:function(){var e=this.parent().items();return e[e.indexOf(this)+1]},prev:function(){var e=this.parent().items();return e[e.indexOf(this)-1]},innerHtml:function(e){return this.$el.html(e),this},getEl:function(e){var t=e?this._id+"-"+e:this._id;return this._elmCache[t]||(this._elmCache[t]=me("#"+t)[0]),this._elmCache[t]},show:function(){return this.visible(!0)},hide:function(){return this.visible(!1)},focus:function(){try{this.getEl().focus()}catch(e){}return this},blur:function(){return this.getEl().blur(),this},aria:function(e,t){var n=this.getEl(this.ariaTarget);return"undefined"==typeof t?this._aria[e]:(this._aria[e]=t,this.state.get("rendered")&&n.setAttribute("role"===e?e:"aria-"+e,t),this)},encode:function(e,t){return!1!==t&&(e=this.translate(e)),(e||"").replace(/[&<>"]/g,function(e){return"&#"+e.charCodeAt(0)+";"})},translate:function(e){return qe.translate?qe.translate(e):e},before:function(e){var t=this.parent();return t&&t.insert(e,t.items().indexOf(this),!0),this},after:function(e){var t=this.parent();return t&&t.insert(e,t.items().indexOf(this)),this},remove:function(){var e,t,n=this,r=n.getEl(),o=n.parent();if(n.items){var i=n.items().toArray();for(t=i.length;t--;)i[t].remove()}o&&o.items&&(e=[],o.items().each(function(t){t!==n&&e.push(t)}),o.items().set(e),o._lastRect=null),n._eventsRoot&&n._eventsRoot===n&&me(r).off();var a=n.getRoot().controlIdLookup;return a&&delete a[n._id],r&&r.parentNode&&r.parentNode.removeChild(r),n.state.set("rendered",!1),n.state.destroy(),n.fire("remove"),n},renderBefore:function(e){return me(e).before(this.renderHtml()),this.postRender(),this},renderTo:function(e){return me(e||this.getContainerElm()).append(this.renderHtml()),this.postRender(),this},preRender:function(){},render:function(){},renderHtml:function(){return'<div id="'+this._id+'" class="'+this.classes+'"></div>'},postRender:function(){var e,t,n,r,o,i=this,a=i.settings;for(r in i.$el=me(i.getEl()),i.state.set("rendered",!0),a)0===r.indexOf("on")&&i.on(r.substr(2),a[r]);if(i._eventsRoot){for(n=i.parent();!o&&n;n=n.parent())o=n._eventsRoot;if(o)for(r in o._nativeEvents)i._nativeEvents[r]=!0}Ze(i),a.style&&(e=i.getEl())&&(e.setAttribute("style",a.style),e.style.cssText=a.style),i.settings.border&&i.$el.css({"border-top-width":(t=i.borderBox).top,"border-right-width":t.right,"border-bottom-width":t.bottom,"border-left-width":t.left});var s=i.getRoot();for(var u in s.controlIdLookup||(s.controlIdLookup={}),s.controlIdLookup[i._id]=i,i._aria)i.aria(u,i._aria[u]);!1===i.state.get("visible")&&(i.getEl().style.display="none"),i.bindStates(),i.state.on("change:visible",function(e){var t,n=e.value;i.state.get("rendered")&&(i.getEl().style.display=!1===n?"none":"",i.getEl().getBoundingClientRect()),(t=i.parent())&&(t._lastRect=null),i.fire(n?"show":"hide"),Xe.add(i)}),i.fire("postrender",{},!1)},bindStates:function(){},scrollIntoView:function(e){var t,n,r,o,i,a,s=this.getEl(),u=s.parentNode,c=function(e,t){var n,r,o=e;for(n=r=0;o&&o!==t&&o.nodeType;)n+=o.offsetLeft||0,r+=o.offsetTop||0,o=o.offsetParent;return{x:n,y:r}}(s,u);return t=c.x,n=c.y,r=s.offsetWidth,o=s.offsetHeight,i=u.clientWidth,a=u.clientHeight,"end"===e?(t-=i-r,n-=a-o):"center"===e&&(t-=i/2-r/2,n-=a/2-o/2),u.scrollLeft=t,u.scrollTop=n,this},getRoot:function(){for(var e,t=this,n=[];t;){if(t.rootControl){e=t.rootControl;break}n.push(t),e=t,t=t.parent()}e||(e=this);for(var r=n.length;r--;)n[r].rootControl=e;return e},reflow:function(){Xe.remove(this);var e=this.parent();return e&&e._layout&&!e._layout.isNative()&&e.reflow(),this}};function Qe(e){return e._eventDispatcher||(e._eventDispatcher=new Ee({scope:e,toggleEvent:function(t,n){n&&Ee.isNative(t)&&(e._nativeEvents||(e._nativeEvents={}),e._nativeEvents[t]=!0,e.state.get("rendered")&&Ze(e))}})),e._eventDispatcher}function Ze(e){var t,n,r,o,i,a;function s(t){var n=e.getParentCtrl(t.target);n&&n.fire(t.type,t)}function u(){var e=o._lastHoverCtrl;e&&(e.fire("mouseleave",{target:e.getEl()}),e.parents().each(function(e){e.fire("mouseleave",{target:e.getEl()})}),o._lastHoverCtrl=null)}function c(t){var n,r,i,a=e.getParentCtrl(t.target),s=o._lastHoverCtrl,u=0;
vendor: 19,024 bytes, line 1
1if(a!==s){if(o._lastHoverCtrl=a,(r=a.parents().toArray().reverse()).push(a),s){for((i=s.parents().toArray().reverse()).push(s),u=0;u<i.length&&r[u]===i[u];u++);for(n=i.length-1;n>=u;n--)(s=i[n]).fire("mouseleave",{target:s.getEl()})}for(n=u;n<r.length;n++)(a=r[n]).fire("mouseenter",{target:a.getEl()})}}function l(t){t.preventDefault(),"mousewheel"===t.type?(t.deltaY=-.025*t.wheelDelta,t.wheelDeltaX&&(t.deltaX=-.025*t.wheelDeltaX)):(t.deltaX=0,t.deltaY=t.detail),t=e.fire("wheel",t)}if(i=e._nativeEvents){for((r=e.parents().toArray()).unshift(e),t=0,n=r.length;!o&&t<n;t++)o=r[t]._eventsRoot;for(o||(o=r[r.length-1]||e),e._eventsRoot=o,n=t,t=0;t<n;t++)r[t]._eventsRoot=o;var f=o._delegates;for(a in f||(f=o._delegates={}),i){if(!i)return!1;"wheel"!==a||Ke?("mouseenter"===a||"mouseleave"===a?o._hasMouseEnter||(me(o.getEl()).on("mouseleave",u).on("mouseover",c),o._hasMouseEnter=1):f[a]||(me(o.getEl()).on(a,s),f[a]=!0),i[a]=!1):Ye?me(e.getEl()).on("mousewheel",l):me(e.getEl()).on("DOMMouseScroll",l)}}}r.each("text title visible disabled active value".split(" "),function(e){Je[e]=function(t){return 0===arguments.length?this.state.get(e):("undefined"!=typeof t&&this.state.set(e,t),this)}});var et=qe=Te.extend(Je),tt=function(e){return!!e.getAttribute("data-mce-tabstop")};function nt(e){var t,n,r=e.root;function o(e){return e&&1===e.nodeType}try{t=document.activeElement}catch(e){t=document.body}function i(e){return o(e=e||t)?e.getAttribute("role"):null}function a(e){for(var n,r=e||t;r=r.parentNode;)if(n=i(r))return n}function s(e){var n=t;if(o(n))return n.getAttribute("aria-"+e)}function u(e){var t=e.tagName.toUpperCase();return"INPUT"===t||"TEXTAREA"===t||"SELECT"===t}function c(e){var t=[];return function e(n){if(1===n.nodeType&&"none"!==n.style.display&&!n.disabled){(function(e){return!(!u(e)||e.hidden)||!!tt(e)||!!/^(button|menuitem|checkbox|tab|menuitemcheckbox|option|gridcell|slider)$/.test(i(e))})(n)&&t.push(n);for(var r=0;r<n.childNodes.length;r++)e(n.childNodes[r])}}(e||r.getEl()),t}function l(e){var t,r;(r=(e=e||n).parents().toArray()).unshift(e);for(var o=0;o<r.length&&!(t=r[o]).settings.ariaRoot;o++);return t}function f(e,t){return e<0?e=t.length-1:e>=t.length&&(e=0),t[e]&&t[e].focus(),e}function d(e,n){var r=-1,o=l();n=n||c(o.getEl());for(var i=0;i<n.length;i++)n[i]===t&&(r=i);o.lastAriaIndex=f(r+=e,n)}function h(){"tablist"===a()?d(-1,c(t.parentNode)):n.parent().submenu?v():d(-1)}function p(){var e=i(),n=a();"tablist"===n?d(1,c(t.parentNode)):"menuitem"===e&&"menu"===n&&s("haspopup")?y():d(1)}function m(){d(-1)}function g(){var e=i(),t=a();"menuitem"===e&&"menubar"===t?y():"button"===e&&s("haspopup")?y({key:"down"}):d(1)}function v(){n.fire("cancel")}function y(e){n.fire("click",{target:t,aria:e=e||{}})}return n=r.getParentCtrl(t),r.on("keydown",function(e){function r(e,n){u(t)||tt(t)||"slider"!==i(t)&&!1!==n(e)&&e.preventDefault()}if(!e.isDefaultPrevented())switch(e.keyCode){case 37:r(e,h);break;case 39:r(e,p);break;case 38:r(e,m);break;case 40:r(e,g);break;case 27:v();break;case 14:case 13:case 32:r(e,y);break;case 9:!function(e){if("tablist"===a()){var t=c(n.getEl("body"))[0];t&&t.focus()}else d(e.shiftKey?-1:1)}(e),e.preventDefault()}}),r.on("focusin",function(e){t=e.target,n=e.control}),{focusFirst:function(e){var t=l(e),n=c(t.getEl());f(t.settings.ariaRemember&&"lastAriaIndex"in t?t.lastAriaIndex:0,n)}}}var rt={},ot=et.extend({init:function(e){var t=this;t._super(e),(e=t.settings).fixed&&t.state.set("fixed",!0),t._items=new Fe,t.isRtl()&&t.classes.add("rtl"),t.bodyClasses=new _e(function(){t.state.get("rendered")&&(t.getEl("body").className=this.toString())}),t.bodyClasses.prefix=t.classPrefix,t.classes.add("container"),t.bodyClasses.add("container-body"),e.containerCls&&t.classes.add(e.containerCls),t._layout=f.create((e.layout||"")+"layout"),t.add(t.settings.items?t.settings.items:t.render()),t._hasBody=!0},items:function(){return this._items},find:function(e){return(e=rt[e]=rt[e]||new Le(e)).find(this)},add:function(e){return this.items().add(this.create(e)).parent(this),this},focus:function(e){var t,n,r;if(!e||!(n=this.keyboardNav||this.parents().eq(-1)[0].keyboardNav))return r=this.find("*"),this.statusbar&&r.add(this.statusbar.items()),r.each(function(e){if(e.settings.autofocus)return t=null,!1;e.canFocus&&(t=t||e)}),t&&t.focus(),this;n.focusFirst(this)},replace:function(e,t){for(var n,r=this.items(),o=r.length;o--;)if(r[o]===e){r[o]=t;break}o>=0&&((n=t.getEl())&&n.parentNode.removeChild(n),(n=e.getEl())&&n.parentNode.removeChild(n)),t.parent(this)},create:function(e){var t,n=this,o=[];return r.isArray(e)||(e=[e]),r.each(e,function(e){e&&(e instanceof et||("string"==typeof e&&(e={type:e}),t=r.extend({},n.settings.defaults,e),e.type=t.type=t.type||e.type||n.settings.defaultType||(t.defaults?t.defaults.type:null),e=f.create(t)),o.push(e))}),o},renderNew:function(){var e=this;return e.items().each(function(t,n){var r;t.parent(e),t.state.get("rendered")||((r=e.getEl("body")).hasChildNodes()&&n<=r.childNodes.length-1?me(r.childNodes[n]).before(t.renderHtml()):me(r).append(t.renderHtml()),t.postRender(),Xe.add(t))}),e._layout.applyClasses(e.items().filter(":visible")),e._lastRect=null,e},append:function(e){return this.add(e).renderNew()},prepend:function(e){return this.items().set(this.create(e).concat(this.items().toArray())),this.renderNew()},insert:function(e,t,n){var r,o,i;return e=this.create(e),r=this.items(),!n&&t<r.length-1&&(t+=1),t>=0&&t<r.length&&(o=r.slice(0,t).toArray(),i=r.slice(t).toArray(),r.set(o.concat(e,i))),this.renderNew()},fromJSON:function(e){for(var t in e)this.find("#"+t).value(e[t]);return this},toJSON:function(){var e={};return this.find("*").each(function(t){var n=t.name(),r=t.value();n&&"undefined"!=typeof r&&(e[n]=r)}),e},renderHtml:function(){var e=this._layout,t=this.settings.role;return this.preRender(),e.preRender(this),'<div id="'+this._id+'" class="'+this.classes+'"'+(t?' role="'+this.settings.role+'"':"")+'><div id="'+this._id+'-body" class="'+this.bodyClasses+'">'+(this.settings.html||"")+e.renderHtml(this)+"</div></div>"},postRender:function(){var e;return this.items().exec("postRender"),this._super(),this._layout.postRender(this),this.state.set("rendered",!0),this.settings.style&&this.$el.css(this.settings.style),this.settings.border&&this.$el.css({"border-top-width":(e=this.borderBox).top,"border-right-width":e.right,"border-bottom-width":e.bottom,"border-left-width":e.left}),this.parent()||(this.keyboardNav=nt({root:this})),this},initLayoutRect:function(){var e=this._super();return this._layout.recalc(this),e},recalc:function(){var e=this._layoutRect,t=this._lastRect;if(!t||t.w!==e.w||t.h!==e.h)return this._layout.recalc(this),e=this.layoutRect(),this._lastRect={x:e.x,y:e.y,w:e.w,h:e.h},!0},reflow:function(){var e;if(Xe.remove(this),this.visible()){for(et.repaintControls=[],et.repaintControls.map={},this.recalc(),e=et.repaintControls.length;e--;)et.repaintControls[e].repaint();"flow"!==this.settings.layout&&"stack"!==this.settings.layout&&this.repaint(),et.repaintControls=[]}return this}});function it(e){var t,n;if(e.changedTouches)for(t="screenX screenY pageX pageY clientX clientY".split(" "),n=0;n<t.length;n++)e[t[n]]=e.changedTouches[0][t[n]]}function at(e,t){var n,r,o,i,a,s,u,c=t.document||document,l=c.getElementById((t=t||{}).handle||e);o=function(e){var o,f,d=function(e){var t,n,r,o,i,a,s,u,c=Math.max;return r=c((t=e.documentElement).scrollWidth,(n=e.body).scrollWidth),o=c(t.clientWidth,n.clientWidth),i=c(t.offsetWidth,n.offsetWidth),a=c(t.scrollHeight,n.scrollHeight),s=c(t.clientHeight,n.clientHeight),u=c(t.offsetHeight,n.offsetHeight),{width:r<i?o:r,height:a<u?s:a}}(c);it(e),e.preventDefault(),r=e.button,o=l,s=e.screenX,u=e.screenY,f=window.getComputedStyle?window.getComputedStyle(o,null).getPropertyValue("cursor"):o.runtimeStyle.cursor,n=me("<div></div>").css({position:"absolute",top:0,left:0,width:d.width,height:d.height,zIndex:2147483647,opacity:1e-4,cursor:f}).appendTo(c.body),me(c).on("mousemove touchmove",a).on("mouseup touchend",i),t.start(e)},a=function(e){if(it(e),e.button!==r)return i(e);e.deltaX=e.screenX-s,e.deltaY=e.screenY-u,e.preventDefault(),t.drag(e)},i=function(e){it(e),me(c).off("mousemove touchmove",a).off("mouseup touchend",i),n.remove(),t.stop&&t.stop(e)},this.destroy=function(){me(l).off()},me(l).on("mousedown touchstart",o)}var st,ut,ct,lt,ft={init:function(){this.on("repaint",this.renderScroll)},renderScroll:function(){var e=this,t=2;function n(){var n,r,o;function i(o,i,a,s,u,c){var l,f,d,h,p,m,g,v;if(f=e.getEl("scroll"+o)){if(g=i.toLowerCase(),v=a.toLowerCase(),me(e.getEl("absend")).css(g,e.layoutRect()[s]-1),!u)return void me(f).css("display","none");me(f).css("display","block"),l=e.getEl("body"),d=e.getEl("scroll"+o+"t"),h=l["client"+a]-2*t,p=(h-=n&&r?f["client"+c]:0)/l["scroll"+a],(m={})[g]=l["offset"+i]+t,m[v]=h,me(f).css(m),(m={})[g]=l["scroll"+i]*p,m[v]=h*p,me(d).css(m)}}o=e.getEl("body"),r=o.scrollHeight>o.clientHeight,i("h","Left","Width","contentW",n=o.scrollWidth>o.clientWidth,"Height"),i("v","Top","Height","contentH",r,"Width")}e.settings.autoScroll&&(e._hasScroll||(e._hasScroll=!0,function(){function n(n,r,o,i,a){var s,u=e._id+"-scroll"+n,c=e.classPrefix;me(e.getEl()).append('<div id="'+u+'" class="'+c+"scrollbar "+c+"scrollbar-"+n+'"><div id="'+u+'t" class="'+c+'scrollbar-thumb"></div></div>'),e.draghelper=new at(u+"t",{start:function(){s=e.getEl("body")["scroll"+r],me("#"+u).addClass(c+"active")},drag:function(u){var c,l,f,d,h=e.layoutRect();l=h.contentW>h.innerW,f=h.contentH>h.innerH,d=e.getEl("body")["client"+o]-2*t,c=(d-=l&&f?e.getEl("scroll"+n)["client"+a]:0)/e.getEl("body")["scroll"+o],e.getEl("body")["scroll"+r]=s+u["delta"+i]/c},stop:function(){me("#"+u).removeClass(c+"active")}})}e.classes.add("scroll"),n("v","Top","Height","Y","Width"),n("h","Left","Width","X","Height")}(),e.on("wheel",function(t){var r=e.getEl("body");r.scrollLeft+=10*(t.deltaX||0),r.scrollTop+=10*t.deltaY,n()}),me(e.getEl("body")).on("scroll",n)),n())}},dt=ot.extend({Defaults:{layout:"fit",containerCls:"panel"},Mixins:[ft],renderHtml:function(){var e=this._layout,t=this.settings.html;return this.preRender(),e.preRender(this),"undefined"==typeof t?t='<div id="'+this._id+'-body" class="'+this.bodyClasses+'">'+e.renderHtml(this)+"</div>":("function"==typeof t&&(t=t.call(this)),this._hasBody=!1),'<div id="'+this._id+'" class="'+this.classes+'" hidefocus="1" tabindex="-1" role="group">'+(this._preBodyHtml||"")+t+"</div>"}}),ht={resizeToContent:function(){this._layoutRect.autoResize=!0,this._lastRect=null,this.reflow()},resizeTo:function(e,t){if(e<=1||t<=1){var n=ve.getWindowSize();e=e<=1?e*n.w:e,t=t<=1?t*n.h:t}return this._layoutRect.autoResize=!1,this.layoutRect({minW:e,minH:t,w:e,h:t}).reflow()},resizeBy:function(e,t){var n=this.layoutRect();return this.resizeTo(n.w+e,n.h+t)}},pt=[],mt=[];function gt(e,t){for(;e;){if(e===t)return!0;e=e.parent()}}function vt(e){var t=ve.getViewPort().y;function n(t,n){for(var r,o=0;o<pt.length;o++)if(pt[o]!==e)for(r=pt[o].parent();r&&(r=r.parent());)r===e&&pt[o].fixed(t).moveBy(0,n).repaint()}e.settings.autofix&&(e.state.get("fixed")?e._autoFixY>t&&(e.fixed(!1).layoutRect({y:e._autoFixY}).repaint(),n(!1,e._autoFixY-t)):(e._autoFixY=e.layoutRect().y,e._autoFixY<t&&(e.fixed(!0).layoutRect({y:0}).repaint(),n(!0,t-e._autoFixY))))}function yt(e,t){var n,r,o=bt.zIndex||65535;if(e)mt.push(t);else for(n=mt.length;n--;)mt[n]===t&&mt.splice(n,1);if(mt.length)for(n=0;n<mt.length;n++)mt[n].modal&&(o++,r=mt[n]),mt[n].getEl().style.zIndex=o,mt[n].zIndex=o,o++;var i=me("#"+t.classPrefix+"modal-block",t.getContainerElm())[0];r?me(i).css("z-index",r.zIndex-1):i&&(i.parentNode.removeChild(i),lt=!1),bt.currentZIndex=o}var bt=dt.extend({Mixins:[Se,ht],init:function(e){var t=this;t._super(e),t._eventsRoot=t,t.classes.add("floatpanel"),e.autohide&&(st||(st=function(e){2!==e.button&&function(e){for(var t=pt.length;t--;){var n=pt[t],r=n.getParentCtrl(e.target);if(n.settings.autohide){if(r&&(gt(r,n)||n.parent()===r))continue;(e=n.fire("autohide",{target:e.target})).isDefaultPrevented()||n.hide()}}}(e)},me(document).on("click touchstart",st)),function(){if(!ct){var e=document.documentElement,t=e.clientWidth,n=e.clientHeight;ct=function(){document.all&&t===e.clientWidth&&n===e.clientHeight||(t=e.clientWidth,n=e.clientHeight,bt.hideAll())},me(window).on("resize",ct)}}(),pt.push(t)),e.autofix&&(ut||(ut=function(){var e;for(e=pt.length;e--;)vt(pt[e])},me(window).on("scroll",ut)),t.on("move",function(){vt(this)})),t.on("postrender show",function(e){if(e.control===t){var n,r=t.classPrefix;t.modal&&!lt&&((n=me("#"+r+"modal-block",t.getContainerElm()))[0]||(n=me('<div id="'+r+'modal-block" class="'+r+"reset "+r+'fade"></div>').appendTo(t.getContainerElm())),y.setTimeout(function(){n.addClass(r+"in"),me(t.getEl()).addClass(r+"in")}),lt=!0),yt(!0,t)}}),t.on("show",function(){t.parents().each(function(e){if(e.state.get("fixed"))return t.fixed(!0),!1})}),e.popover&&(t._preBodyHtml='<div class="'+t.classPrefix+'arrow"></div>',t.classes.add("popover").add("bottom").add(t.isRtl()?"end":"start")),t.aria("label",e.ariaLabel),t.aria("labelledby",t._id),t.aria("describedby",t.describedBy||t._id+"-none")},fixed:function(e){if(this.state.get("fixed")!==e){if(this.state.get("rendered")){var t=ve.getViewPort();e?this.layoutRect().y-=t.y:this.layoutRect().y+=t.y}this.classes.toggle("fixed",e),this.state.set("fixed",e)}return this},show:function(){var e,t=this._super();for(e=pt.length;e--&&pt[e]!==this;);return-1===e&&pt.push(this),t},hide:function(){return wt(this),yt(!1,this),this._super()},hideAll:function(){bt.hideAll()},close:function(){return this.fire("close").isDefaultPrevented()||(this.remove(),yt(!1,this)),this},remove:function(){wt(this),this._super()},postRender:function(){return this.settings.bodyRole&&this.getEl("body").setAttribute("role",this.settings.bodyRole),this._super()}});function wt(e){var t;for(t=pt.length;t--;)pt[t]===e&&pt.splice(t,1);for(t=mt.length;t--;)mt[t]===e&&mt.splice(t,1)}bt.hideAll=function(){for(var e=pt.length;e--;){var t=pt[e];t&&t.settings.autohide&&(t.hide(),pt.splice(e,1))}};var xt=function(e,t){return!(!e||t.settings.ui_container)};function Ct(e,t){var n,r,o=this,i=et.classPrefix;o.show=function(a,s){function u(){n&&(me(e).append('<div class="'+i+"throbber"+(t?" "+i+"throbber-inline":"")+'"></div>'),s&&s())}return o.hide(),n=!0,a?r=y.setTimeout(u,a):u(),o},o.hide=function(){var t=e.lastChild;return y.clearTimeout(r),t&&-1!==t.className.indexOf("throbber")&&t.parentNode.removeChild(t),n=!1,o}}var St=et.extend({Mixins:[Se],Defaults:{classes:"widget tooltip tooltip-n"},renderHtml:function(){var e=this.classPrefix;return'<div id="'+this._id+'" class="'+this.classes+'" role="presentation"><div class="'+e+'tooltip-arrow"></div><div class="'+e+'tooltip-inner">'+this.encode(this.state.get("text"))+"</div></div>"},bindStates:function(){var e=this;return e.state.on("change:text",function(t){e.getEl().lastChild.innerHTML=e.encode(t.value)}),e._super()},repaint:function(){var e,t;(e=this.getEl().style).left=(t=this._layoutRect).x+"px",e.top=t.y+"px",e.zIndex=131070}}),Tt=et.extend({init:function(e){var t=this;t._super(e),e=t.settings,t.canFocus=!0,e.tooltip&&!1!==Tt.tooltips&&(t.on("mouseenter",function(n){var r=t.tooltip().moveTo(-65535);if(n.control===t){var o=r.text(e.tooltip).show().testMoveRel(t.getEl(),["bc-tc","bc-tl","bc-tr"]);r.classes.toggle("tooltip-n","bc-tc"===o),r.classes.toggle("tooltip-nw","bc-tl"===o),r.classes.toggle("tooltip-ne","bc-tr"===o),r.moveRel(t.getEl(),o)}else r.hide()}),t.on("mouseleave mousedown click",function(){t.tooltip().remove(),t._tooltip=null})),t.aria("label",e.ariaLabel||e.tooltip)},tooltip:function(){return this._tooltip||(this._tooltip=new St({type:"tooltip"}),R.inheritUiContainer(this,this._tooltip),this._tooltip.renderTo()),this._tooltip},postRender:function(){var e=this.settings;this._super(),this.parent()||!e.width&&!e.height||(this.initLayoutRect(),this.repaint()),e.autofocus&&this.focus()},bindStates:function(){var e=this;function t(t){e.aria("disabled",t),e.classes.toggle("disabled",t)}function n(t){e.aria("pressed",t),e.classes.toggle("active",t)}return e.state.on("change:disabled",function(e){t(e.value)}),e.state.on("change:active",function(e){n(e.value)}),e.state.get("disabled")&&t(!0),e.state.get("active")&&n(!0),e._super()},remove:function(){this._super(),this._tooltip&&(this._tooltip.remove(),this._tooltip=null)}}),Et=Tt.extend({Defaults:{value:0},init:function(e){this._super(e),this.classes.add("progress"),this.settings.filter||(this.settings.filter=function(e){return Math.round(e)})},renderHtml:function(){var e=this.classPrefix;return'<div id="'+this._id+'" class="'+this.classes+'"><div class="'+e+'bar-container"><div class="'+e+'bar"></div></div><div class="'+e+'text">0%</div></div>'},postRender:function(){return this._super(),this.value(this.settings.value),this},bindStates:function(){var e=this;function t(t){t=e.settings.filter(t),e.getEl().lastChild.innerHTML=t+"%",e.getEl().firstChild.firstChild.style.width=t+"%"}return e.state.on("change:value",function(e){t(e.value)}),t(e.state.get("value")),e._super()}}),kt=function(e,t){e.getEl().lastChild.textContent=t+(e.progressBar?" "+e.progressBar.value()+"%":"")},Nt=et.extend({Mixins:[Se],Defaults:{classes:"widget notification"},init:function(e){var t=this;t._super(e),t.maxWidth=e.maxWidth,e.text&&t.text(e.text),e.icon&&(t.icon=e.icon),e.color&&(t.color=e.color),e.type&&t.classes.add("notification-"+e.type),e.timeout&&(e.timeout<0||e.timeout>0)&&!e.closeButton?t.closeButton=!1:(t.classes.add("has-close"),t.closeButton=!0),e.progressBar&&(t.progressBar=new Et),t.on("click",function(e){-1!==e.target.className.indexOf(t.classPrefix+"close")&&t.close()})},renderHtml:function(){var e,t=this.classPrefix,n="",r="",o="";return this.icon&&(n='<i class="'+t+"ico "+t+"i-"+this.icon+'"></i>'),e=' style="max-width: '+this.maxWidth+"px;"+(this.color?"background-color: "+this.color+';"':'"'),this.closeButton&&(r='<button type="button" class="'+t+'close" aria-hidden="true">\xd7</button>'),this.progressBar&&(o=this.progressBar.renderHtml()),'<div id="'+this._id+'" class="'+this.classes+'"'+e+' role="presentation">'+n+'<div class="'+t+'notification-inner">'+this.state.get("text")+"</div>"+o+r+'<div style="clip: rect(1px, 1px, 1px, 1px);height: 1px;overflow: hidden;position: absolute;width: 1px;" aria-live="assertive" aria-relevant="additions" aria-atomic="true"></div></div>'},postRender:function(){var e=this;return y.setTimeout(function(){e.$el.addClass(e.classPrefix+"in"),kt(e,e.state.get("text"))},100),e._super()},bindStates:function(){var e=this;return e.state.on("change:text",function(t){e.getEl().firstChild.innerHTML=t.value,kt(e,t.value)}),e.progressBar&&(e.progressBar.bindStates(),e.progressBar.state.on("change:value",function(t){kt(e,e.state.get("text"))})),e._super()},close:function(){return this.fire("close").isDefaultPrevented()||this.remove(),this},repaint:function(){var e,t;
1(e=this.getEl().style).left=(t=this._layoutRect).x+"px",e.top=t.y+"px",e.zIndex=65534}}),Rt=[],_t="";function At(e){var t,n=me("meta[name=viewport]")[0];!1!==ce.overrideViewPort&&(n||((n=document.createElement("meta")).setAttribute("name","viewport"),document.getElementsByTagName("head")[0].appendChild(n)),(t=n.getAttribute("content"))&&"undefined"!=typeof _t&&(_t=t),n.setAttribute("content",e?"width=device-width,initial-scale=1.0,user-scalable=0,minimum-scale=1.0,maximum-scale=1.0":_t))}var Dt=bt.extend({modal:!0,Defaults:{border:1,layout:"flex",containerCls:"panel",role:"dialog",callbacks:{submit:function(){this.fire("submit",{data:this.toJSON()})},close:function(){this.close()}}},init:function(e){var t=this;t._super(e),t.isRtl()&&t.classes.add("rtl"),t.classes.add("window"),t.bodyClasses.add("window-body"),t.state.set("fixed",!0),e.buttons&&(t.statusbar=new dt({layout:"flex",border:"1 0 0 0",spacing:3,padding:10,align:"center",pack:t.isRtl()?"start":"end",defaults:{type:"button"},items:e.buttons}),t.statusbar.classes.add("foot"),t.statusbar.parent(t)),t.on("click",function(e){var n=t.classPrefix+"close";(ve.hasClass(e.target,n)||ve.hasClass(e.target.parentNode,n))&&t.close()}),t.on("cancel",function(){t.close()}),t.aria("describedby",t.describedBy||t._id+"-none"),t.aria("label",e.title),t._fullscreen=!1},recalc:function(){var e,t,n,r,o=this.statusbar;
1this._fullscreen&&(this.layoutRect(ve.getWindowSize()),this.layoutRect().contentH=this.layoutRect().innerH),this._super(),e=this.layoutRect(),this.settings.title&&!this._fullscreen&&(t=e.headerW)>e.w&&(n=e.x-Math.max(0,t/2),this.layoutRect({w:t,x:n}),r=!0),o&&(o.layoutRect({w:this.layoutRect().innerW}).recalc(),(t=o.layoutRect().minW+e.deltaW)>e.w&&(n=e.x-Math.max(0,t-e.w),this.layoutRect({w:t,x:n}),r=!0)),r&&this.recalc()},initLayoutRect:function(){var e,t=this._super(),n=0;if(this.settings.title&&!this._fullscreen){e=this.getEl("head");var r=ve.getSize(e);t.headerW=r.width,t.headerH=r.height,n+=t.headerH}this.statusbar&&(n+=this.statusbar.layoutRect().h),t.deltaH+=n,t.minH+=n,t.h+=n;var o=ve.getWindowSize();return t.x=this.settings.x||Math.max(0,o.w/2-t.w/2),t.y=this.settings.y||Math.max(0,o.h/2-t.h/2),t},renderHtml:function(){var e=this._layout,t=this._id,n=this.classPrefix,r=this.settings,o="",i="",a=r.html;return this.preRender(),e.preRender(this),r.title&&(o='<div id="'+t+'-head" class="'+n+'window-head"><div id="'+t+'-title" class="'+n+'title">'+this.encode(r.title)+'</div><div id="'+t+'-dragh" class="'+n+'dragh"></div><button type="button" class="'+n+'close" aria-hidden="true"><i class="mce-ico mce-i-remove"></i></button></div>'),r.url&&(a='<iframe src="'+r.url+'" tabindex="-1"></iframe>'),"undefined"==typeof a&&(a=e.renderHtml(this)),this.statusbar&&(i=this.statusbar.renderHtml()),'<div id="'+t+'" class="'+this.classes+'" hidefocus="1"><div class="'+this.classPrefix+'reset" role="application">'+o+'<div id="'+t+'-body" class="'+this.bodyClasses+'">'+a+"</div>"+i+"</div></div>"},fullscreen:function(e){var t,n,r=this,o=document.documentElement,i=r.classPrefix;if(e!==r._fullscreen)if(me(window).on("resize",function(){var e;if(r._fullscreen)if(t)r._timer||(r._timer=y.setTimeout(function(){var e=ve.getWindowSize();r.moveTo(0,0).resizeTo(e.w,e.h),r._timer=0},50));else{e=(new Date).getTime();var n=ve.getWindowSize();r.moveTo(0,0).resizeTo(n.w,n.h),(new Date).getTime()-e>50&&(t=!0)}}),n=r.layoutRect(),r._fullscreen=e,e){r._initial={x:n.x,y:n.y,w:n.w,h:n.h},r.borderBox=ke("0"),r.getEl("head").style.display="none",n.deltaH-=n.headerH+2,me([o,document.body]).addClass(i+"fullscreen"),r.classes.add("fullscreen");var a=ve.getWindowSize();r.moveTo(0,0).resizeTo(a.w,a.h)}else r.borderBox=ke(r.settings.border),r.getEl("head").style.display="",n.deltaH+=n.headerH,me([o,document.body]).removeClass(i+"fullscreen"),r.classes.remove("fullscreen"),r.moveTo(r._initial.x,r._initial.y).resizeTo(r._initial.w,r._initial.h);return r.reflow()},postRender:function(){var e,t=this;setTimeout(function(){t.classes.add("in"),t.fire("open")},0),t._super(),t.statusbar&&t.statusbar.postRender(),t.focus(),this.dragHelper=new at(t._id+"-dragh",{start:function(){e={x:t.layoutRect().x,y:t.layoutRect().y}},drag:function(n){t.moveTo(e.x+n.deltaX,e.y+n.deltaY)}}),t.on("submit",function(e){e.isDefaultPrevented()||t.close()}),Rt.push(t),At(!0)},submit:function(){return this.fire("submit",{data:this.toJSON()})},remove:function(){var e,t;for(this.dragHelper.destroy(),this._super(),this.statusbar&&this.statusbar.remove(),t=this.classPrefix,!1,function(){for(var e=0;e<Rt.length;e++)if(Rt[e]._fullscreen)return!0;return!1}()&&me([document.documentElement,document.body]).removeClass(t+"fullscreen"),e=Rt.length;e--;)Rt[e]===this&&Rt.splice(e,1);At(Rt.length>0)},getContentWindow:function(){var e=this.getEl().getElementsByTagName("iframe")[0];return e?e.contentWindow:null}});!function(){if(!ce.desktop){var e={w:window.innerWidth,h:window.innerHeight};y.setInterval(function(){var t=window.innerWidth,n=window.innerHeight;e.w===t&&e.h===n||(e={w:t,h:n},me(window).trigger("resize"))},100)}me(window).on("resize",function(){var e,t,n=ve.getWindowSize();for(e=0;e<Rt.length;e++)t=Rt[e].layoutRect(),Rt[e].moveTo(Rt[e].settings.x||Math.max(0,n.w/2-t.w/2),Rt[e].settings.y||Math.max(0,n.h/2-t.h/2))})}();var Ot=Dt.extend({init:function(e){this._super({border:1,padding:20,layout:"flex",pack:"center",align:"center",containerCls:"panel",autoScroll:!0,buttons:{type:"button",text:"Ok",action:"ok"},items:{type:"label",multiline:!0,maxWidth:500,maxHeight:200}})},Statics:{OK:1,OK_CANCEL:2,YES_NO:3,YES_NO_CANCEL:4,msgBox:function(e){var t,n=e.callback||function(){};function r(e,t,r){return{type:"button",text:e,subtype:r?"primary":"",onClick:function(e){e.control.parents()[1].close(),n(t)}}}switch(e.buttons){case Ot.OK_CANCEL:t=[r("Ok",!0,!0),r("Cancel",!1)];break;case Ot.YES_NO:case Ot.YES_NO_CANCEL:t=[r("Yes",1,!0),r("No",0)],e.buttons===Ot.YES_NO_CANCEL&&t.push(r("Cancel",-1));break;default:t=[r("Ok",!0,!0)]}return new Dt({padding:20,x:e.x,y:e.y,minWidth:300,minHeight:100,layout:"flex",pack:"center",align:"center",buttons:t,title:e.title,role:"alertdialog",items:{type:"label",multiline:!0,maxWidth:500,maxHeight:200,text:e.text},onPostRender:function(){this.aria("describedby",this.items()[0]._id)},onClose:e.onClose,onCancel:function(){n(!1)}}).renderTo(document.body).reflow()},alert:function(e,t){return"string"==typeof e&&(e={text:e}),e.callback=t,Ot.msgBox(e)},confirm:function(e,t){return"string"==typeof e&&(e={text:e}),e.callback=t,e.buttons=Ot.OK_CANCEL,Ot.msgBox(e)}}}),Pt=function(e){return{renderUI:function(t){return function(e,t,r){var i=function(e){var t=e.settings,r=t.skin,o=t.skin_url;if(!1!==r){var i=r||"lightgray";o=o?e.documentBaseURI.toAbsolute(o):n.baseURL+"/skins/"+i}return o}(e);return i&&(r.skinUiCss=i+"/skin.min.css",e.contentCSS.push(i+"/content"+(e.inline?".inline":"")+".min.css")),function(e,t){var n;e.on("ProgressState",function(e){n=n||new Ct(t.panel.getEl("body")),e.state?n.show(e.time):n.hide()})}(e,t),function(e){return e.getParam("inline",!1,"boolean")}(e)?function(e,t,n){var r,i,s=l.DOM,c=function(e){return e.getParam("fixed_toolbar_container")}(e);c&&(i=s.select(c)[0]);var d=function(){if(r&&r.moveRel&&r.visible()&&!r._fixed){var t=e.selection.getScrollC
vendor: 11,736 bytes, line 1
1ontainer(),n=e.getBody(),o=0,i=0;if(t){var a=s.getPos(n),u=s.getPos(t);o=Math.max(0,u.x-a.x),i=Math.max(0,u.y-a.y)}r.fixed(!1).moveRel(n,e.rtl?["tr-br","br-tr"]:["tl-bl","bl-tl","tr-br"]).moveBy(o,i)}},h=function(){r&&(r.show(),d(),s.addClass(e.getBody(),"mce-edit-focus"))},m=function(){r&&(r.hide(),bt.hideAll(),s.removeClass(e.getBody(),"mce-edit-focus"))},v=function(){r?r.visible()||h():(r=t.panel=f.create({type:i?"panel":"floatpanel",role:"application",classes:"tinymce tinymce-inline",layout:"flex",direction:"column",align:"stretch",autohide:!1,autofix:xt(i,e),fixed:xt(i,e),border:1,items:[!1===o(e)?null:{type:"menubar",border:"0 0 1 0",items:oe(e)},D(e,a(e))]}),R.setUiContainer(e,r),p(e),i?r.renderTo(i).reflow():r.renderTo().reflow(),g(e,r),h(),L(e),e.on("nodeChange",d),e.on("ResizeWindow",d),e.on("activate",h),e.on("deactivate",m),e.nodeChanged())};return e.settings.content_editable=!0,e.on("focus",function(){!1===u(e)&&n.skinUiCss?s.styleSheetLoader.load(n.skinUiCss,v,v):v()}),e.on("blur hide",m),e.on("remove",function(){r&&(r.remove(),r=null)}),!1===u(e)&&n.skinUiCss?s.styleSheetLoader.load(n.skinUiCss,fe(e)):fe(e)(),{}}(e,t,r):pe(e,t,r)}(e,this,t)},resizeTo:function(t,n){return ue(e,t,n)},resizeBy:function(t,n){return function(e,t,n){var r=e.getContentAreaContainer();se(e,r.clientWidth+t,r.clientHeight+n)}(e,t,n)},getNotificationManagerImpl:function(){return function(e){var t=function(e){return e.inline?e.getElement():e.getContentAreaContainer()};return{open:function(n,o){var i,a=r.extend(n,{maxWidth:(i=t(e),ve.getSize(i).width)}),s=new Nt(a);return s.args=a,a.timeout>0&&(s.timer=setTimeout(function(){s.close(),o()},a.timeout)),s.on("close",function(){o()}),s.renderTo(),s},close:function(e){e.close()},reposition:function(n){!function(e){V(e,function(e){e.moveTo(0,0)})}(n),function(n){if(n.length>0){var r=n.slice(0,1)[0],o=t(e);r.moveRel(o,"tc-tc"),V(n,function(e,t){t>0&&e.moveRel(n[t-1].getEl(),"bc-tc")})}}(n)},getArgs:function(e){return e.args}}}(e)},getWindowManagerImpl:function(){return{open:function(e,t,n){var r;return e.title=e.title||" ",e.url=e.url||e.file,e.url&&(e.width=parseInt(e.width||320,10),e.height=parseInt(e.height||240,10)),e.body&&(e.items={defaults:e.defaults,type:e.bodyType||"form",items:e.body,data:e.data,callbacks:e.commands}),e.url||e.buttons||(e.buttons=[{text:"Ok",subtype:"primary",onclick:function(){r.find("form")[0].submit()}},{text:"Cancel",onclick:function(){r.close()}}]),(r=new Dt(e)).on("close",function(){n(r)}),e.data&&r.on("postRender",function(){this.find("*").each(function(t){var n=t.name();n in e.data&&t.value(e.data[n])})}),r.features=e||{},r.params=t||{},r=r.renderTo(document.body).reflow()},alert:function(e,t,n){var r;return(r=Ot.alert(e,function(){t()})).on("close",function(){n(r)}),r},confirm:function(e,t,n){var r;return(r=Ot.confirm(e,function(e){t(e)})).on("close",function(){n(r)}),r},close:function(e){e.close()},getParams:function(e){return e.params},setParams:function(e,t){e.params=t}}}}},Bt=Te.extend({Defaults:{firstControlClass:"first",lastControlClass:"last"},init:function(e){this.settings=r.extend({},this.Defaults,e)},preRender:function(e){e.bodyClasses.add(this.settings.containerClass)},applyClasses:function(e){var t,n,r,o,i=this.settings;t=i.firstControlClass,n=i.lastControlClass,e.each(function(e){e.classes.remove(t).remove(n).add(i.controlClass),e.visible()&&(r||(r=e),o=e)}),r&&r.classes.add(t),o&&o.classes.add(n)},renderHtml:function(e){var t="";return this.applyClasses(e.items()),e.items().each(function(e){t+=e.renderHtml()}),t},recalc:function(){},postRender:function(){},isNative:function(){return!1}}),It=Bt.extend({Defaults:{containerClass:"abs-layout",controlClass:"abs-layout-item"},recalc:function(e){e.items().filter(":visible").each(function(e){var t=e.settings;e.layoutRect({x:t.x,y:t.y,w:t.w,h:t.h}),e.recalc&&e.recalc()})},renderHtml:function(e){return'<div id="'+e._id+'-absend" class="'+e.classPrefix+'abs-end"></div>'+this._super(e)}}),Lt=Tt.extend({Defaults:{classes:"widget btn",role:"button"},init:function(e){var t,n=this;n._super(e),e=n.settings,t=n.settings.size,n.on("click mousedown",function(e){e.preventDefault()}),n.on("touchstart",function(e){n.fire("click",e),e.preventDefault()}),e.subtype&&n.classes.add(e.subtype),t&&n.classes.add("btn-"+t),e.icon&&n.icon(e.icon)},icon:function(e){return arguments.length?(this.state.set("icon",e),this):this.state.get("icon")},repaint:function(){var e,t=this.getEl().firstChild;t&&((e=t.style).width=e.height="100%"),this._super()},renderHtml:function(){var e,t=this._id,n=this.classPrefix,r=this.state.get("icon"),o=this.state.get("text"),i="",a=this.settings;return(e=a.image)?(r="none","string"!=typeof e&&(e=window.getSelection?e[0]:e[1]),e=" style=\"background-image: url('"+e+"')\""):e="",o&&(this.classes.add("btn-has-text"),i='<span class="'+n+'txt">'+this.encode(o)+"</span>"),r=r?n+"ico "+n+"i-"+r:"",'<div id="'+t+'" class="'+this.classes+'" tabindex="-1"'+("boolean"==typeof a.active?' aria-pressed="'+a.active+'"':"")+'><button id="'+t+'-button" role="presentation" type="button" tabindex="-1">'+(r?'<i class="'+r+'"'+e+"></i>":"")+i+"</button></div>"},bindStates:function(){var e=this,t=e.$,n=e.classPrefix+"txt";function r(r){var o=t("span."+n,e.getEl());r?(o[0]||(t("button:first",e.getEl()).append('<span class="'+n+'"></span>'),o=t("span."+n,e.getEl())),o.html(e.encode(r))):o.remove(),e.classes.toggle("btn-has-text",!!r)}return e.state.on("change:text",function(e){r(e.value)}),e.state.on("change:icon",function(t){var n=t.value,o=e.classPrefix;e.settings.icon=n,n=n?o+"ico "+o+"i-"+e.settings.icon:"";var i=e.getEl().firstChild,a=i.getElementsByTagName("i")[0];n?(a&&a===i.firstChild||(a=document.createElement("i"),i.insertBefore(a,i.firstChild)),a.className=n):a&&i.removeChild(a),r(e.state.get("text"))}),e._super()}}),Mt=Lt.extend({init:function(e){e=r.extend({text:"Browse...",multiple:!1,accept:null},e),this._super(e),this.classes.add("browsebutton"),e.multiple&&this.classes.add("multiple")},postRender:function(){var e=this,t=ve.create("input",{type:"file",id:e._id+"-browse",accept:e.settings.accept});e._super(),me(t).on("change",function(t){var n=t.target.files;e.value=function(){return n.length?e.settings.multiple?n:n[0]:null},t.preventDefault(),n.length&&e.fire("change",t)}),me(t).on("click",function(e){e.stopPropagation()}),me(e.getEl("button")).on("click",function(e){e.stopPropagation(),t.click()}),e.getEl().appendChild(t)},remove:function(){me(this.getEl("button")).off(),me(this.getEl("input")).off(),this._super()}}),Ht=ot.extend({Defaults:{defaultType:"button",role:"group"},renderHtml:function(){var e=this._layout;return this.classes.add("btn-group"),this.preRender(),e.preRender(this),'<div id="'+this._id+'" class="'+this.classes+'"><div id="'+this._id+'-body">'+(this.settings.html||"")+e.renderHtml(this)+"</div></div>"}}),Ft=Tt.extend({Defaults:{classes:"checkbox",role:"checkbox",checked:!1},init:function(e){var t=this;t._super(e),t.on("click mousedown",function(e){e.preventDefault()}),t.on("click",function(e){e.preventDefault(),t.disabled()||t.checked(!t.checked())}),t.checked(t.settings.checked)},checked:function(e){return arguments.length?(this.state.set("checked",e),this):this.state.get("checked")},value:function(e){return arguments.length?this.checked(e):this.checked()},renderHtml:function(){var e=this._id,t=this.classPrefix;return'<div id="'+e+'" class="'+this.classes+'" unselectable="on" aria-labelledby="'+e+'-al" tabindex="-1"><i class="'+t+"ico "+t+'i-checkbox"></i><span id="'+e+'-al" class="'+t+'label">'+this.encode(this.state.get("text"))+"</span></div>"},bindStates:function(){var e=this;function t(t){e.classes.toggle("checked",t),e.aria("checked",t)}return e.state.on("change:text",function(t){e.getEl("al").firstChild.data=e.translate(t.value)}),e.state.on("change:checked change:value",function(n){e.fire("change"),t(n.value)}),e.state.on("change:icon",function(t){var n=t.value,r=e.classPrefix;if("undefined"==typeof n)return e.settings.icon;e.settings.icon=n,n=n?r+"ico "+r+"i-"+e.settings.icon:"";var o=e.getEl().firstChild,i=o.getElementsByTagName("i")[0];n?(i&&i===o.firstChild||(i=document.createElement("i"),o.insertBefore(i,o.firstChild)),i.className=n):i&&o.removeChild(i)}),e.state.get("checked")&&t(!0),e._super()}}),Wt=tinymce.util.Tools.resolve("tinymce.util.VK"),jt=Tt.extend({init:function(e){var t=this;t._super(e),e=t.settings,t.classes.add("combobox"),t.subinput=!0,t.ariaTarget="inp",e.menu=e.menu||e.values,e.menu&&(e.icon="caret"),t.on("click",function(n){var r=n.target,o=t.getEl();if(me.contains(o,r)||r===o)for(;r&&r!==o;)r.id&&-1!==r.id.indexOf("-open")&&(t.fire("action"),e.menu&&(t.showMenu(),n.aria&&t.menu.items()[0].focus())),r=r.parentNode}),t.on("keydown",function(e){var n;13===e.keyCode&&"INPUT"===e.target.nodeName&&(e.preventDefault(),t.parents().reverse().each(function(e){if(e.toJSON)return n=e,!1}),t.fire("submit",{data:n.toJSON()}))}),t.on("keyup",function(e){if("INPUT"===e.target.nodeName){var n=t.state.get("value"),r=e.target.value;r!==n&&(t.state.set("value",r),t.fire("autocomplete",e))}}),t.on("mouseover",function(e){var n=t.tooltip().moveTo(-65535);if(t.statusLevel()&&-1!==e.target.className.indexOf(t.classPrefix+"status")){var r=t.statusMessage()||"Ok",o=n.text(r).show().testMoveRel(e.target,["bc-tc","bc-tl","bc-tr"]);n.classes.toggle("tooltip-n","bc-tc"===o),n.classes.toggle("tooltip-nw","bc-tl"===o),n.classes.toggle("tooltip-ne","bc-tr"===o),n.moveRel(e.target,o)}})},statusLevel:function(e){return arguments.length>0&&this.state.set("statusLevel",e),this.state.get("statusLevel")},statusMessage:function(e){return arguments.length>0&&this.state.set("statusMessage",e),this.state.get("statusMessage")},showMenu:function(){var e,t=this;t.menu||((e=t.settings.menu||[]).length?e={type:"menu",items:e}:e.type=e.type||"menu",t.menu=f.create(e).parent(t).renderTo(t.getContainerElm()),t.fire("createmenu"),t.menu.reflow(),t.menu.on("cancel",function(e){e.control===t.menu&&t.focus()}),t.menu.on("show hide",function(e){e.control.items().each(function(e){e.active(e.value()===t.value())})}).fire("show"),t.menu.on("select",function(e){t.value(e.control.value())}),t.on("focusin",function(e){"INPUT"===e.target.tagName.toUpperCase()&&t.menu.hide()}),t.aria("expanded",!0)),t.menu.show(),t.menu.layoutRect({w:t.layoutRect().w}),t.menu.moveRel(t.getEl(),t.isRtl()?["br-tr","tr-br"]:["bl-tl","tl-bl"])},focus:function(){this.getEl("inp").focus()},repaint:function(){var e,t,n=this.getEl(),r=this.getEl("open"),o=this.layoutRect(),i=0,a=n.firstChild;this.statusLevel()&&"none"!==this.statusLevel()&&(i=parseInt(ve.getRuntimeStyle(a,"padding-right"),10)-parseInt(ve.getRuntimeStyle(a,"padding-left"),10)),e=r?o.w-ve.getSize(r).width-10:o.w-10;var s=document;return s.all&&(!s.documentMode||s.documentMode<=8)&&(t=this.layoutRect().h-2+"px"),me(a).css({width:e-i,lineHeight:t}),this._super(),this},postRender:function(){var e=this;return me(this.getEl("inp")).on("change",function(t){e.state.set("value",t.target.value),e.fire("change",t)}),e._super()},renderHtml:function(){var e,t,n,r=this._id,o=this.settings,i=this.classPrefix,a=this.state.get("value")||"",s="",u="";return"spellcheck"in o&&(u+=' spellcheck="'+o.spellcheck+'"'),o.maxLength&&(u+=' maxlength="'+o.maxLength+'"'),o.size&&(u+=' size="'+o.size+'"'),o.subtype&&(u+=' type="'+o.subtype+'"'),n='<i id="'+r+'-status" class="mce-status mce-ico" style="display: none"></i>',this.disabled()&&(u+=' disabled="disabled"'),(e=o.icon)&&"caret"!==e&&(e=i+"ico "+i+"i-"+o.icon),t=this.state.get("text"),(e||t)&&(s='<div id="'+r+'-open" class="'+i+"btn "+i+'open" tabIndex="-1" role="button"><button id="'+r+'-action" type="button" hidefocus="1" tabindex="-1">
1'+("caret"!==e?'<i class="'+e+'"></i>':'<i class="'+i+'caret"></i>')+(t?(e?" ":"")+t:"")+"</button></div>",this.classes.add("has-open")),'<div id="'+r+'" class="'+this.classes+'"><input id="'+r+'-inp" class="'+i+'textbox" value="'+this.encode(a,!1)+'" hidefocus="1"'+u+' placeholder="'+this.encode(o.placeholder)+'" />'+n+s+"</div>"},value:function(e){return arguments.length?(this.state.set("value",e),this):(this.state.get("rendered")&&this.state.set("value",this.getEl("inp").value),this.state.get("value"))},showAutoComplete:function(e,t){var n=this;if(0!==e.length){n.menu?n.menu.items().remove():n.menu=f.create({type:"menu",classes:"combobox-menu",layout:"flow"}).parent(n).renderTo(),r.each(e,function(e){var r,o;n.menu.add({text:e.title,url:e.previewUrl,match:t,classes:"menu-item-ellipsis",onclick:(r=e.value,o=e.title,function(){n.fire("selectitem",{title:o,value:r})})})}),n.menu.renderNew(),n.hideMenu(),n.menu.on("cancel",function(e){e.control.parent()===n.menu&&(e.stopPropagation(),n.focus(),n.hideMenu())}),n.menu.on("select",function(){n.focus()});var o=n.layoutRect().w;n.menu.layoutRect({w:o,minW:0,maxW:o}),n.menu.repaint(),n.menu.reflow(),n.menu.show(),n.menu.moveRel(n.getEl(),n.isRtl()?["br-tr","tr-br"]:["bl-tl","tl-bl"])}else n.hideMenu()},hideMenu:function(){this.menu&&this.menu.hide()},bindStates:function(){var e=this;e.state.on("change:value",function(t){e.getEl("inp").value!==t.value&&(e.getEl("inp").value=t.value)}),e.state.on("change:disabled",function(t){e.getEl("inp").disabled=t.value}),e.state.on("change:statusLevel",function(t){var n=e.getEl("status"),r=e.classPrefix,o=t.value;ve.css(n,"display","none"===o?"none":""),ve.toggleClass(n,r+"i-checkmark","ok"===o),ve.toggleClass(n,r+"i-warning","warn"===o),ve.toggleClass(n,r+"i-error","error"===o),e.classes.toggle("has-status","none"!==o),e.repaint()}),ve.on(e.getEl("status"),"mouseleave",function(){e.tooltip().hide()}),e.on("cancel",function(t){e.menu&&e.menu.visible()&&(t.stopPropagation(),e.hideMenu())});var t=function(e,t){t&&t.items().length>0&&t.items().eq(e)[0].focus()};return e.on("keydown",function(n){var r=n.keyCode;"INPUT"===n.target.nodeName&&(r===Wt.DOWN?(n.preventDefault(),e.fire("autocomplete"),t(0,e.menu)):r===Wt.UP&&(n.preventDefault(),t(-1,e.menu)))}),e._super()},remove:function(){me(this.getEl("inp")).off(),this.menu&&this.menu.remove(),this._super()}}),$t=jt.extend({init:function(e){var t=this;e.spellcheck=!1,e.onaction&&(e.icon="none"),t._super(e),t.classes.add("colorbox"),t.on("change keyup postrender",function(){t.repaintColor(t.value())})},repaintColor:function(e){var t=this.getEl("open"),n=t?t.getElementsByTagName("i")[0]:null;if(n)try{n.style.background=e}catch(e){}},bindStates:function(){var e=this;return e.state.on("change:value",function(t){e.state.get("rendered")&&e.repaintColor(t.value)}),e._super()}}),zt=Lt.extend({showPanel:function(){var e=this,t=e.settings;if(e.classes.add("opened"),e.panel)e.panel.show();else{var n=t.panel;n.type&&(n={layout:"grid",items:n}),n.role=n.role||"dialog",n.popover=!0,n.autohide=!0,n.ariaRoot=!0,e.panel=new bt(n).on("hide",function(){e.classes.remove("opened")}).on("cancel",function(t){t.stopPropagation(),e.focus(),e.hidePanel()}).parent(e).renderTo(e.getContainerElm()),e.panel.fire("show"),e.panel.reflow()}var r=e.panel.testMoveRel(e.getEl(),t.popoverAlign||(e.isRtl()?["bc-tc","bc-tl","bc-tr"]:["bc-tc","bc-tr","bc-tl"]));e.panel.classes.toggle("start","bc-tl"===r),e.panel.classes.toggle("end","bc-tr"===r),e.panel.moveRel(e.getEl(),r)},hidePanel:function(){this.panel&&this.panel.hide()},postRender:function(){var e=this;return e.aria("haspopup",!0),e.on("click",function(t){t.control===e&&(e.panel&&e.panel.visible()?e.hidePanel():(e.showPanel(),e.panel.focus(!!t.aria)))}),e._super()},remove:function(){return this.panel&&(this.panel.remove(),this.panel=null),this._super()}}),qt=l.DOM,Ut=zt.extend({init:function(e){this._super(e),this.classes.add("splitbtn"),this.classes.add("colorbutton")},color:function(e){return e?(this._color=e,this.getEl("preview").style.backgroundColor=e,this):this._color},resetColor:function(){return this._color=null,this.getEl("preview").style.backgroundColor=null,this},renderHtml:function(){var e=this._id,t=this.classPrefix,n=this.state.get("text"),r=this.settings.icon?t+"ico "+t+"i-"+this.settings.icon:"",o=this.settings.image?" style=\"background-image: url('"+this.settings.image+"')\"":"",i="";return n&&(this.classes.add("btn-has-text"),i='<span class="'+t+'txt">'+this.encode(n)+"</span>"),'<div id="'+e+'" class="'+this.classes+'" role="button" tabindex="-1" aria-haspopup="true"><button role="presentation" hidefocus="1" type="button" tabindex="-1">'+(r?'<i class="'+r+'"'+o+"></i>":"")+'<span id="'+e+'-preview" class="'+t+'preview"></span>'+i+'</button><button type="button" class="'+t+'open" hidefocus="1" tabindex="-1"> <i class="'+t+'caret"></i></button></div>'},postRender:function(){var e=this,t=e.settings.onclick;return e.on("click",function(n){n.aria&&"down"===n.aria.key||n.control!==e||qt.getParent(n.target,"."+e.classPrefix+"open")||(n.stopImmediatePropagation(),t.call(e,n))}),delete e.settings.onclick,e._super()}}),Vt=tinymce.util.Tools.resolve("tinymce.util.Color"),Xt=Tt.extend({Defaults:{classes:"widget colorpicker"},init:function(e){this._super(e)},postRender:function(){var e,t,n,r,o,i=this,a=i.color();function s(e,t){var n,r,o=ve.getPos(e);return n=t.pageX-o.x,r=t.pageY-o.y,{x:n=Math.max(0,Math.min(n/e.clientWidth,1)),y:r=Math.max(0,Math.min(r/e.clientHeight,1))}}function u(e,t){ve.css(n,{top:(360-e.h)/360*100+"%"}),t||ve.css(o,{left:e.s+"%",top:100-e.v+"%"}),r.style.background=Vt({s:100,v:100,h:e.h}).toHex(),i.color().parse({s:e.s,v:e.v,h:e.h})}function c(t){var n;n=s(r,t),e.s=100*n.x,e.v=100*(1-n.y),u(e),i.fire("change")}function l(n){var r;r=s(t,n),(e=a.toHsv()).h=360*(1-r.y),u(e,!0),i.fire("change")}t=i.getEl("h"),n=i.getEl("hp"),r=i.getEl("sv"),o=i.getEl("svp"),i._repaint=function(){u(e=a.toHsv())},i._super(),i._svdraghelper=new at(i._id+"-sv",{start:c,drag:c}),i._hdraghelper=new at(i._id+"-h",{start:l,drag:l}),i._repaint()},rgb:function(){return this.color().toRgb()},value:function(e){if(!arguments.length)return this.color().toHex();this.color().parse(e),this._rendered&&this._repaint()},color:function(){return this._color||(this._color=Vt()),this._color},renderHtml:function(){var e,t=this._id,n=this.classPrefix,r="#ff0000,#ff0080,#ff00ff,#8000ff,#0000ff,#0080ff,#00ffff,#00ff80,#00ff00,#80ff00,#ffff00,#ff8000,#ff0000";return e='<div id="'+t+'-h" class="'+n+'colorpicker-h" style="background: -ms-linear-gradient(top,'+r+");background: linear-gradient(to bottom,"+r+');">'+function(){var e,t,o,i,a="";for(o="filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=",e=0,t=(i=r.split(",")).length-1;e<t;e++)a+='<div class="'+n+'colorpicker-h-chunk" style="height:'+100/t+"%;"+o+i[e]+",endColorstr="+i[e+1]+");-ms-"+o+i[e]+",endColorstr="+i[e+1]+')"></div>';return a}()+'<div id="'+t+'-hp" class="'+n+'colorpicker-h-marker"></div></div>','<div id="'+t+'" class="'+this.classes+'"><div id="'+t+'-sv" class="'+n+'colorpicker-sv"><div class="'+n+'colorpicker-overlay1"><div class="'+n+'colorpicker-overlay2"><div id="'+t+'-svp" class="'+n+'colorpicker-selector1"><div class="'+n+'colorpicker-selector2"></div></div></div></div></div>'+e+"</div>"}}),Yt=Tt.extend({init:function(e){e=r.extend({height:100,text:"Drop an image here",multiple:!1,accept:null},e),this._super(e),this.classes.add("dropzone"),e.multiple&&this.classes.add("multiple")},renderHtml:function(){var e,t=this.settings;return e=ve.create("div",{id:this._id,hidefocus:"1"},"<span>"+this.translate(t.text)+"</span>"),t.height&&ve.css(e,"height",t.height+"px"),t.width&&ve.css(e,"width",t.width+"px"),e.className=this.classes,e.outerHTML},postRender:function(){var e=this,t=function(t){t.preventDefault(),e.classes.toggle("dragenter"),e.getEl().className=e.classes};e._super(),e.$el.on("dragover",function(e){e.preventDefault()}),e.$el.on("dragenter",t),e.$el.on("dragleave",t),e.$el.on("drop",function(t){if(t.preventDefault(),!e.state.get("disabled")){var n=function(t){var n=e.settings.accept;if("string"!=typeof n)return t;var o=new RegExp("("+n.split(/\s*,\s*/).join("|")+")$","i");return r.grep(t,function(e){return o.test(e.name)}
1)}(t.dataTransfer.files);e.value=function(){return n.length?e.settings.multiple?n:n[0]:null},n.length&&e.fire("change",t)}})},remove:function(){this.$el.off(),this._super()}}),Kt=Tt.extend({init:function(e){var t=this;e.delimiter||(e.delimiter="\xbb"),t._super(e),t.classes.add("path"),t.canFocus=!0,t.on("click",function(e){var n;(n=e.target.getAttribute("data-index"))&&t.fire("select",{value:t.row()[n],index:n})}),t.row(t.settings.row)},focus:function(){return this.getEl().firstChild.focus(),this},row:function(e){return arguments.length?(this.state.set("row",e),this):this.state.get("row")},renderHtml:function(){return'<div id="'+this._id+'" class="'+this.classes+'">'+this._getDataPathHtml(this.state.get("row"))+"</div>"},bindStates:function(){var e=this;return e.state.on("change:row",function(t){e.innerHtml(e._getDataPathHtml(t.value))}),e._super()},_getDataPathHtml:function(e){var t,n,r=e||[],o="",i=this.classPrefix;for(t=0,n=r.length;t<n;t++)o+=(t>0?'<div class="'+i+'divider" aria-hidden="true"> '+this.settings.delimiter+" </div>":"")+'<div role="button" class="'+i+"path-item"+(t===n-1?" "+i+"last":"")+'" data-index="'+t+'" tabindex="-1" id="'+this._id+"-"+t+'" aria-level="'+(t+1)+'">'+r[t].name+"</div>";return o||(o='<div class="'+i+'path-item">\xa0</div>'),o}}),Gt=Kt.extend({postRender:function(){var e=this,t=e.settings.editor;function n(e){if(1===e.nodeType){if("BR"===e.nodeName||e.getAttribute("data-mce-bogus"))return!0;if("bookmark"===e.getAttribute("data-mce-type"))return!0}return!1}return!1!==t.settings.elementpath&&(e.on("select",function(e){t.focus(),t.selection.select(this.row()[e.index].element),t.nodeChanged()}),t.on("nodeChange",function(r){for(var o=[],i=r.parents,a=i.length;a--;)if(1===i[a].nodeType&&!n(i[a])){var s=t.fire("ResolveName",{name:i[a].nodeName.toLowerCase(),target:i[a]});if(s.isDefaultPrevented()||o.push({name:s.name,element:i[a]}),s.isPropagationStopped())break}e.row(o)})),e._super()}}),Jt=ot.extend({Defaults:{layout:"flex",align:"center",defaults:{flex:1}},renderHtml:function(){var e=this._layout,t=this.classPrefix;return this.classes.add("formitem"),e.preRender(this),'<div id="'+this._id+'" class="'+this.classes+'" hidefocus="1" tabindex="-1">'+(this.settings.title?'<div id="'+this._id+'-title" class="'+t+'title">'+this.settings.title+"</div>":"")+'<div id="'+this._id+'-body" class="'+this.bodyClasses+'">'+(this.settings.html||"")+e.renderHtml(this)+"</div></div>"}}),Qt=ot.extend({Defaults:{containerCls:"form",layout:"flex",direction:"column",align:"stretch",flex:1,padding:15,labelGap:30,spacing:10,callbacks:{submit:function(){this.submit()}}},preRender:function(){var e=this,t=e.items();e.settings.formItemDefaults||(e.settings.formItemDefaults={layout:"flex",autoResize:"overflow",defaults:{flex:1}}),t.each(function(t){var n,o=t.settings.label;o&&((n=new Jt(r.extend({items:{type:"label",id:t._id+"-l",text:o,flex:0,forId:t._id,disabled:t.disabled()}},e.settings.formItemDefaults))).type="formitem",t.aria("labelledby",t._id+"-l"),"undefined"==typeof t.settings.flex&&(t.settings.flex=1),e.replace(t,n),n.add(t))})},submit:function(){return this.fire("submit",{data:this.toJSON()})},postRender:function(){this._super(),this.fromJSON(this.settings.data)},bindStates:function(){var e=this;function t(){var t,n,r=0,o=[];if(!1!==e.settings.labelGapCalc)for(("children"===e.settings.labelGapCalc?e.find("formitem"):e.items()).filter("formitem").each(function(e){var t=e.items()[0],n=t.getEl().clientWidth;r=n>r?n:r,o.push(t)}),n=e.settings.labelGap||0,t=o.length;t--;)o[t].settings.minWidth=r+n}e._super(),e.on("show",t),t()}}),Zt=Qt.extend({Defaults:{containerCls:"fieldset",layout:"flex",direction:"column",align:"stretch",flex:1,padding:"25 15 5 15",labelGap:30,spacing:10,border:1},renderHtml:function(){var e=this._layout,t=this.classPrefix;return this.preRender(),e.preRender(this),'<fieldset id="'+this._id+'" class="'+this.classes+'" hidefocus="1" tabindex="-1">'+(this.settings.title?'<legend id="'+this._id+'-title" class="'+t+'fieldset-title">'+this.settings.title+"</legend>":"")+'<div id="'+this._id+'-body" class="'+this.bodyClasses+'">'+(this.settings.html||"")+e.renderHtml(this)+"</div></fieldset>"}}),en=0,tn=function(e){if(null===e||void 0===e)throw new Error("Node cannot be null or undefined");return{dom:w.constant(e)}},nn=function(e){var t,n=!1;return function(){return n||(n=!0,t=e.apply(null,arguments)),t}},rn=function(e){return e.dom().nodeName.toLowerCase()},on=function(e){return e.dom().nodeType},an=function(e){return function(t){return on(t)===e}},sn=an(1),un=an(3),cn=an(9),ln={name:rn,type:on,value:function(e){return e.dom().nodeValue},isElement:sn,isText:un,isDocument:cn,isComment:function(e){return 8===on(e)||"#comment"===rn(e)}},fn=(nn(function(){return fn(tn(document))}),function(e){var t=e.dom().body;if(null===t||void 0===t)throw"Body is not available yet";return tn(t)}),dn=function(e){return function(t){return function(e){if(null===e)return"null";var t=typeof e;return"object"===t&&Array.prototype.isPrototypeOf(e)?"array":"object"===t&&String.prototype.isPrototypeOf(e)?"string":t}(t)===e}},hn={isString:dn("string"),isObject:dn("object"),isArray:dn("array"),isNull:dn("null"),isBoolean:dn("boolean"),isUndefined:dn("undefined"),isFunction:dn("function"),isNumber:dn("number")},pn=(Object.keys,function(){var e=arguments;return function(){for(var t=new Array(arguments.length),n=0;n<t.length;n++)t[n]=arguments[n];if(e.length!==t.length)throw new Error('Wrong number of arguments to struct. Expected "['+e.length+']", got '+t.length+" arguments");var r={};return V(e,function(e,n){r[e]=w.constant(t[n])}),r}}),mn=("undefined"!=typeof window?window:Function("return this;")(),function(){return gn(0,0)}),gn=function(e,t){return{major:e,minor:t}},vn={nu:gn,detect:function(e,t){var n=String(t).toLowerCase();return 0===e.length?mn():function(t,n){var r=function(e,t){for(var n=0;n<e.length;n++){var r=e[n];if(r.test(t))return r}}(e,n);if(!r)return{major:0,minor:0};var o=function(e){return Number(n.replace(r,"$"+e))};return gn(o(1),o(2))}(0,n)},unknown:mn},yn=function(e,t){return function(){return t===e}},bn=function(e){var t=e.current;
1return{current:t,version:e.version,isEdge:yn("Edge",t),isChrome:yn("Chrome",t),isIE:yn("IE",t),isOpera:yn("Opera",t),isFirefox:yn("Firefox",t),isSafari:yn("Safari",t)}},wn=function(){return bn({current:void 0,version:vn.unknown()})},xn=bn,Cn=(w.constant("Edge"),w.constant("Chrome"),w.constant("IE"),w.constant("Opera"),w.constant("Firefox"),w.constant("Safari"),function(e,t){return function(){return t===e}}),Sn=function(e){var t=e.current;return{current:t,version:e.version,isWindows:Cn("Windows",t),isiOS:Cn("iOS",t),isAndroid:Cn("Android",t),isOSX:Cn("OSX",t),isLinux:Cn("Linux",t),isSolaris:Cn("Solaris",t),isFreeBSD:Cn("FreeBSD",t)}},Tn=function(){return Sn({current:void 0,version:vn.unknown()})},En=Sn,kn=(w.constant("Windows"),w.constant("iOS"),w.constant("Android"),w.constant("Linux"),w.constant("OSX"),w.constant("Solaris"),w.constant("FreeBSD"),function(e,t){var n=String(t).toLowerCase();return G(e,function(e){return e.search(n)})}),Nn=function(e,t){return-1!==e.indexOf(t)},Rn=/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,_n=function(e){return function(t){return Nn(t,e)}},An=[{name:"Edge",versionRegexes:[/.*?edge\/ ?([0-9]+)\.([0-9]+)$/],search:function(e){return Nn(e,"edge/")&&Nn(e,"chrome")&&Nn(e,"safari")&&Nn(e,"applewebkit")}},{name:"Chrome",versionRegexes:[/.*?chrome\/([0-9]+)\.([0-9]+).*/,Rn],search:function(e){return Nn(e,"chrome")&&!Nn(e,"chromeframe")}},{name:"IE",versionRegexes:[/.*?msie\ ?([0-9]+)\.([0-9]+).*/,/.*?rv:([0-9]+)\.([0-9]+).*/],search:function(e){return Nn(e,"msie")||Nn(e,"trident")}},{name:"Opera",versionRegexes:[Rn,/.*?opera\/([0-9]+)\.([0-9]+).*/],search:_n("opera")},{name:"Firefox",versionRegexes:[/.*?firefox\/\ ?([0-9]+)\.([0-9]+).*/],search:_n("firefox")},{name:"Safari",versionRegexes:[Rn,/.*?cpu os ([0-9]+)_([0-9]+).*/],search:function(e){return(Nn(e,"safari")||Nn(e,"mobile/"))&&Nn(e,"applewebkit")}}],Dn=[{name:"Windows",search:_n("win"),versionRegexes:[/.*?windows\ nt\ ?([0-9]+)\.([0-9]+).*/]},{name:"iOS",search:function(e){return Nn(e,"iphone")||Nn(e,"ipad")},versionRegexes:[/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,/.*cpu os ([0-9]+)_([0-9]+).*/,/.*cpu iphone os ([0-9]+)_([0-9]+).*/]},{name:"Android",search:_n("android"),versionRegexes:[/.*?android\ ?([0-9]+)\.([0-9]+).*/]},{name:"OSX",search:_n("os x"),versionRegexes:[/.*?os\ x\ ?([0-9]+)_([0-9]+).*/]},{name:"Linux",search:_n("linux"),versionRegexes:[]},{name:"Solaris",search:_n("sunos"),versionRegexes:[]},{name:"FreeBSD",search:_n("freebsd"),versionRegexes:[]}],On={browsers:w.constant(An),oses:w.constant(Dn)},Pn=function(e){return 1!==e.nodeType&&9!==e.nodeType||0===e.childElementCount},Bn=(nn(function(){return function(e){var t=On.browsers(),n=On.oses(),r=function(e,t){return kn(e,t).map(function(e){var n=vn.detect(e.versionRegexes,t);return{current:e.name,version:n}})}(t,e).fold(wn,xn),o=function(e,t){return kn(e,t).map(function(e){var n=vn.detect(e.versionRegexes,t);return{current:e.name,version:n}})}(n,e).fold(Tn,En);return{browser:r,os:o,deviceType:function(e,t,n){var r=e.isiOS()&&!0===/ipad/i.test(n),o=e.isiOS()&&!r,i=e.isAndroid()&&3===e.version.major,a=e.isAndroid()&&4===e.version.major,s=r||i||a&&!0===/mobile/i.test(n),u=e.isiOS()||e.isAndroid(),c=u&&!s,l=t.isSafari()&&e.isiOS()&&!1===/safari/i.test(n);return{isiPad:w.constant(r),isiPhone:w.constant(o),isTablet:w.constant(s),isPhone:w.constant(c),isTouch:w.constant(u),isAndroid:e.isAndroid,isiOS:e.isiOS,isWebView:w.constant(l)}}(o,r,e)}}(navigator.userAgent)})().browser.isIE(),pn("element","offset"),function(e,t){return function(e,t){var n=void 0===t?document:t.dom();return Pn(n)?[]:U(n.querySelectorAll(e),tn)}(t,e)}),In=r.trim,Ln=function(e){return function(t){if(t&&1===t.nodeType){if(t.contentEditable===e)return!0;if(t.getAttribute("data-mce-contenteditable")===e)return!0}return!1}},Mn=Ln("true"),Hn=Ln("false"),Fn=function(e,t,n,r,o){return{type:e,title:t,url:n,level:r,attach:o}},Wn=function(e){return e.innerText||e.textContent},jn=function(e){return function(e){return e&&"A"===e.nodeName&&(e.id||e.name)}(e)&&zn(e)},$n=function(e){return e&&/^(H[1-6])$/.test(e.nodeName)},zn=function(e){return function(e){for(;e=e.parentNode;){var t=e.contentEditable;if(t&&"inherit"!==t)return Mn(e)}return!1}(e)&&!Hn(e)},qn=function(e){return $n(e)&&zn(e)},Un=function(e){var t=function(e){return e.id?e.id:("h",t=(new Date).getTime(),"h_"+Math.floor(1e9*Math.random())+ ++en+String(t));var t}(e);return Fn("header",Wn(e),"#"+t,function(e){return $n(e)?parseInt(e.nodeName.substr(1),10):0}(e),function(){e.id=t})},Vn=function(e){var t=e.id||e.name,n=Wn(e);return Fn("anchor",n||"#"+t,"#"+t,0,w.noop)},Xn=function(e){return In(e.title).length>0},Yn={},Kn=function(e){return{title:e.title,value:{title:{raw:e.title},url:e.url,attach:e.attach}}},Gn=function(e,t){return{title:e,value:{title:e,url:t,attach:w.noop}}},Jn=function(e,t,n){var r=t in e?e[t]:n;return!1===r?null:r},Qn=function(e,t){var n=e.toLowerCase(),o=r.grep(t,function(e){return-1!==e.title.toLowerCase().indexOf(n)});return 1===o.length&&o[0].title===e?[]:o},Zn=function(e,t,n,o){var i=function(i){var a,s=function(e,t,n,o){var i,a,s,u,c={title:"-"},l=function(e){var o=e.hasOwnProperty(n)?e[n]:[],i=X(o,function(e){return function(e,t){return!Z(t,function(t){return t.url===e})}(e,t)});return r.map(i,function(e){return{title:e,value:{title:e,url:e,attach:w.noop}}})},f=function(e){return function(e){return r.map(e,Kn)}(X(t,function(t){return t.type===e}))};return!1===o.typeahead_urls?[]:"file"===n?(i=[Qn(e,l(Yn)),Qn(e,f("header")),Qn(e,(a=f("anch
1or"),s=Jn(o,"anchor_top","#top"),u=Jn(o,"anchor_bottom","#bottom"),null!==s&&a.unshift(Gn("<top>",s)),null!==u&&a.push(Gn("<bottom>",u)),a))],K(i,function(e,t){return 0===e.length||0===t.length?e.concat(t):e.concat(c,t)},[])):Qn(e,l(Yn))}(i,(a=function(e){var t;return t="h1,h2,h3,h4,h5,h6,a:not([href])",U(Bn(tn(e),t),function(e){return e.dom()})}(n),X(function(e){return U(X(e,qn),Un)}(a).concat(function(e){return U(X(e,jn),Vn)}(a)),Xn)),o,t);e.showAutoComplete(s,i)};e.on("autocomplete",function(){i(e.value())}),e.on("selectitem",function(t){var n=t.value;e.value(n.url);var r=function(e){var t=e.title;return t.raw?t.raw:t}(n);e.fire("change","image"===o?{meta:{alt:r,attach:n.attach}}:{meta:{text:r,attach:n.attach}}),e.focus()}),e.on("click",function(t){0===e.value().length&&"INPUT"===t.target.nodeName&&i("")}),e.on("PostRender",function(){e.getRoot().on("submit",function(t){t.isDefaultPrevented()||function(e,t){var n=Yn[t];/^https?/.test(e)&&(n?-1===Y(n,e)&&(Yn[t]=n.slice(0,5).concat(e)):Yn[t]=[e])}(e.value(),o)})})},er=jt.extend({Statics:{clearHistory:function(){Yn={}}},init:function(e){var t,o,i,a=this,s=window.tinymce?window.tinymce.activeEditor:n.activeEditor,u=s.settings,c=e.filetype;e.spellcheck=!1,(i=u.file_picker_types||u.file_browser_callback_types)&&(i=r.makeMap(i,/[, ]/)),i&&!i[c]||(!(o=u.file_picker_callback)||i&&!i[c]?!(o=u.file_browser_callback)||i&&!i[c]||(t=function(){o(a.getEl("inp").id,a.value(),c,window)}):t=function(){var e=a.fire("beforecall").meta;e=r.extend({filetype:c},e),o.call(s,function(e,t){a.value(e).fire("change",{meta:t})},a.value(),e)}),t&&(e.icon="browse",e.onaction=t),a._super(e),a.classes.add("filepicker"),Zn(a,u,s.getBody(),c
1),function(e,t,n){var r=t.filepicker_validator_handler;r&&e.state.on("change:value",function(t){var o;0!==(o=t.value).length?r({url:o,type:n},function(t){var n=function(e){var t=e.status,n=e.message;return"valid"===t?{status:"ok",message:n}:"unknown"===t?{status:"warn",message:n}:"invalid"===t?{status:"warn",message:n}:{status:"none",message:""}}(t);e.statusMessage(n.message),e.statusLevel(n.status)}):e.statusLevel("none")})}(a,u,c)}}),tr=It.extend({recalc:function(e){var t=e.layoutRect(),n=e.paddingBox;e.items().filter(":visible").each(function(e){e.layoutRect({x:n.left,y:n.top,w:t.innerW-n.right-n.left,h:t.innerH-n.top-n.bottom}),e.recalc&&e.recalc()})}}),nr=It.extend({recalc:function(e){var t,n,r,o,i,a,s,u,c,l,f,d,h,p,m,g,v,y,b,w,x,C,S,T,E,k,N,R,_,A,D,O,P,B,I,L,M,H=[],F=Math.max,W=Math.min;for(r=e.items().filter(":visible"),o=e.layoutRect(),i=e.paddingBox,a=e.settings,d=e.isRtl()?a.direction||"row-reversed":a.direction,s=a.align,u=e.isRtl()?a.pack||"end":a.pack,c=a.spacing||0,"row-reversed"!==d&&"column-reverse"!==d||(r=r.set(r.toArray().reverse()),d=d.split("-")[0]),"column"===d?(T="y",C="h",S="minH",E="maxH",N="innerH",k="top",R="deltaH",_="contentH",B="left",O="w",A="x",D="innerW",P="minW",I="right",L="deltaW",M="contentW"):(T="x",C="w",S="minW",E="maxW",N="innerW",k="left",R="deltaW",_="contentW",B="top",O="h",A="y",D="innerH",P="minH",I="bottom",L="deltaH",M="contentH"),f=o[N]-i[k]-i[k],x=l=0,t=0,n=r.length;t<n;t++)p=(h=r[t]).layoutRect(),m=h.settings.flex,f-=t<n-1?c:0,m>0&&(l+=m,p[E]&&H.push(h),p.flex=m),f-=p[S],(g=i[B]+p[P]+i[I])>x&&(x=g);if((b={})[S]=f<0?o[S]-f+o[R]:o[N]-f+o[R],b[P]=x+o[L],b[_]=o[N]-f,b[M]=x,b.minW=W(b.minW,o.maxW),b.minH=W(b.minH,o.maxH),b.minW=F(b.minW,o.startMinWidth),b.minH=F(b.minH,o.startMinHeight),!o.autoResize||b.minW===o.minW&&b.minH===o.minH){for(y=f/l,t=0,n=H.length;t<n;t++)(g=(p=(h=H[t]).layoutRect())[S]+p.flex*y)>(v=p[E])?(f-=p[E]-p[S],l-=p.flex,p.flex=0,p.maxFlexSize=v):p.maxFlexSize=0;for(y=f/l,w=i[k],b={},0===l&&("end"===u?w=f+i[k]:"center"===u?(w=Math.round(o[N]/2-(o[N]-f)/2)+i[k])<0&&(w=i[k]):"justify"===u&&(w=i[k],c=Math.floor(f/(r.length-1)))),b[A]=i[B],t=0,n=r.length;t<n;t++)g=(p=(h=r[t]).layoutRect()).maxFlexSize||p[S],"center"===s?b[A]=Math.round(o[D]/2-p[O]/2):"stretch"===s?(b[O]=F(p[P]||0,o[D]-i[B]-i[I]),b[A]=i[B]):"end"===s&&(b[A]=o[D]-p[O]-i.top),p.flex>0&&(g+=p.flex*y),b[C]=g,b[T]=w,h.layoutRect(b),h.recalc&&h.recalc(),w+=g+c}else if(b.w=b.minW,b.h=b.minH,e.layoutRect(b),this.recalc(e),null===e._lastRect){var j=e.parent();j&&(j._lastRect=null,j.recalc())}}}),rr=Bt.extend({Defaults:{containerClass:"flow-layout",controlClass:"flow-layout-item",endClass:"break"},recalc:function(e){e.items().filter(":visible").each(function(e){e.recalc&&e.recalc()})},isNative:function(){return!0}}),or=function(e,t){return function(){e.execCommand("mceToggleFormat",!1,t)}},ir=function(e,t){return function(){var n=this;e.formatter?e.formatter.formatChanged(t,function(e){n.active(e)}):e.on("init",function(){e.formatter.formatChanged(t,function(e){n.active(e)})})}},ar=function(e){return function(t,n){return k.from(n).map(tn).filter(ln.isElement).bind(function(n){return function(e,t,n){for(;n!==t;){if(n.style[e]){var r=n.style[e];return""!==r?k.some(r):k.none()}n=n.parentNode}return k.none()}(e,t,n.dom()).or(function(e,t){return k.from(l.DOM.getStyle(t,e,!0))}(e,n.dom()))}).getOr("")}},sr={getFontSize:ar("fontSize"),getFontFamily:w.compose(function(e){return e.replace(/[\'\"\\]/g,"").replace(/,\s+/g,",")},ar("fontFamily")),toPt:function(e,t){return/[0-9.]+px$/.test(e)?function(e,t){var n=Math.pow(10,t);return Math.round(e*n)/n}(72*parseInt(e,10)/96,t||0)+"pt":e}},ur=function(e){return e?e.split(",")[0]:""},cr=function(e,t,n){var o;return r.each(e,function(e){e.value===n?o=n:e.value===t&&(o=t)}),o},lr=function(e,t){var n=t.length;return r.each(t,function(t){t.menu&&(t.hidden=0===lr(e,t.menu));var r=t.format;r&&(t.hidden=!e.formatter.canApply(r)),t.hidden&&n--}),n},fr=function(e,t){var n=t.items().length;return t.items().each(function(t){t.menu&&t.visible(fr(e,t.menu)>0),!t.menu&&t.settings.menu&&t.visible(lr(e,t.settings.menu)>0);var r=t.settings.format;r&&t.visible(e.formatter.canApply(r)),t.visible()||n--}),n},dr=function(e,t){var n,o;if("string"==typeof t)o=t.split(" ");else if(r.isArray(t))return Q(r.map(t,function(t){return dr(e,t)}));return n=r.grep(o,function(t){return"|"===t||t in e.menuItems}),r.map(n,function(t){return"|"===t?{text:"-"}:e.menuItems[t]})},hr=function(e){return e&&"-"===e.text},pr=function(e,t){return function(){var n=this,r=function(){return!!e.undoM
1anager&&e.undoManager["redo"===t?"hasRedo":"hasUndo"]()};n.disabled(!r()),e.on("Undo Redo AddUndo TypingUndo ClearUndos SwitchMode",function(){n.disabled(e.readonly||!r())})}},mr={setup:function(e){!function(e){e.rtl&&(et.rtl=!0)}(e),function(e){e.on("mousedown",function(){bt.hideAll()})}(e),function(e){var t,n;e.settings.ui_container&&(ce.container=(t=tn(document.body),n=e.settings.ui_container,function(e,t){var n=void 0===t?document:t.dom();return Pn(n)?k.none():k.from(n.querySelector(e)).map(tn)}(n,t)).fold(w.constant(null),function(e){return e.dom()}))}(e),Tt.tooltips=!ce.iOS,et.translate=function(e){return n.translate(e)},function(e){var t=function(e){for(var t=(e=e.replace(/;$/,"").split(";")).length;t--;)e[t]=e[t].split("=");return e}(e.settings.block_formats||"Paragraph=p;Heading 1=h1;Heading 2=h2;Heading 3=h3;Heading 4=h4;Heading 5=h5;Heading 6=h6;Preformatted=pre");e.addMenuItem("blockformats",{text:"Blocks",menu:function(e,t){return r.map(t,function(t){return{text:t[0],onclick:or(e,t[1]),textStyle:function(){return e.formatter.getCssText(t[1])}}})}(e,t)}),e.addButton("formatselect",function(e,t){return function(){var n=[];return r.each(t,function(t){n.push({text:t[0],value:t[1],textStyle:function(){return e.formatter.getCssText(t[1])}})}),{type:"listbox",text:t[0][0],values:n,fixedWidth:!0,onselect:function(t){if(t.control){var n=t.control.value();or(e,n)()}},onPostRender:function(e,t,n){return function(){var n=this;e.on("nodeChange",function(o){var i=e.formatter,a=null;r.each(o.parents,function(e){if(r.each(t,function(t){if(i.matchNode(e,t.value)&&(a=t.value),a)return!1}),a)return!1}),n.value(a)})}}(e,n)}}}(e,t))}(e),function(e){e.addMenuItem("align",{text:"Align",menu:[{text:"Left",icon:"alignleft",onclick:or(e,"alignleft")},{text:"Center",icon:"aligncenter",onclick:or(e,"aligncenter")},{text:"Right",icon:"alignright",onclick:or(e,"alignright")},{text:"Justify",icon:"alignjustify",onclick:or(e,"alignjustify")}]}),r.each({alignleft:["Align left","JustifyLeft"],aligncenter:["Align center","JustifyCenter"],alignright:["Align right","JustifyRight"],alignjustify:["Justify","JustifyFull"],alignnone:["No alignment","JustifyNone"]},function(t,n){e.addButton(n,{active:!1,tooltip:t[0],cmd:t[1],onPostRender:ir(e,n)})})}(e),function(e){(function(e){!function(e){r.each({bold:"Bold",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",subscript:"Subscript",superscript:"Superscript"},function(t,n){e.addButton(n,{active:!1,tooltip:t,onPostRender:ir(e,n),onclick:or(e,n)})})}(e),function(e){r.each({outdent:["Decrease indent","Outdent"],indent:["Increase indent","Indent"],cut:["Cut","Cut"],copy:["Copy","Copy"],paste:["Paste","Paste"],help:["Help","mceHelp"],selectall:["Select all","SelectAll"],visualaid:["Visual aids","mceToggleVisualAid"],newdocument:["New document","mceNewDocument"],removeformat:["Clear formatting","RemoveFormat"],remove:["Remove","Delete"]},function(t,n){e.addButton(n,{tooltip:t[0],cmd:t[1]})})}(e),function(e){r.each({blockquote:["Blockquote","mceBlockQuote"],subscript:["Subscript","Subscript"],superscript:["Superscript","Superscript"]},function(t,n){e.addButton(n,{active:!1,tooltip:t[0],cmd:t[1],onPostRender:ir(e,n)})})}(e)})(e),function(e){r.each({bold:["Bold","Bold","Meta+B"],italic:["Italic","Italic","Meta+I"],underline:["Underline","Underline","Meta+U"],strikethrough:["Strikethrough","Strikethrough"],subscript:["Subscript","Subscript"],superscript:["Superscript","Superscript"],removeformat:["Clear formatting","RemoveFormat"],newdocument:["New document","mceNewDocument"],cut:["Cut","Cut","Meta+X"],copy:["Copy","Copy","Meta+C"],paste:["Paste","Paste","Meta+V"],selectall:["Select all","SelectAll","Meta+A"]},function(t,n){e.addMenuItem(n,{text:t[0],icon:n,shortcut:t[2],cmd:t[1]})}),e.addMenuItem("codeformat",{text:"Code",icon:"code",onclick:or(e,"code")})}(e)}(e),function(e){!function(e){e.addMenuItem("undo",{text:"Undo",icon:"undo",shortcut:"Meta+Z",onPostRender:pr(e,"undo"),cmd:"undo"}),e.addMenuItem("redo",{text:"Redo",icon:"redo",shortcut:"Meta+Y",onPostRender:pr(e,"redo"),cmd:"redo"})}
1(e),function(e){e.addButton("undo",{tooltip:"Undo",onPostRender:pr(e,"undo"),cmd:"undo"}),e.addButton("redo",{tooltip:"Redo",onPostRender:pr(e,"redo"),cmd:"redo"})}(e)}(e),function(e){!function(e){e.addButton("fontsizeselect",function(){var t=function(e){return r.map((e.settings.fontsize_formats||"8pt 10pt 12pt 14pt 18pt 24pt 36pt").split(" "),function(e){var t=e,n=e,r=e.split("=");return r.length>1&&(t=r[0],n=r[1]),{text:t,value:n}})}(e);return{type:"listbox",text:"Font Sizes",tooltip:"Font Sizes",values:t,fixedWidth:!0,onPostRender:function(e,t){return function(){var n=this;e.on("init nodeChange",function(r){var o,i,a,s;if(o=sr.getFontSize(e.getBody(),r.element))for(a=3;!s&&a>=0;a--)i=sr.toPt(o,a),s=cr(t,i,o);n.value(s||null),s||n.text(i)})}}(e,t),onclick:function(t){t.control.settings.value&&e.execCommand("FontSize",!1,t.control.settings.value)}}})}(e)}(e),function(e){!function(e){e.addButton("fontselect",function(){var t=function(e){var t=function(e){for(var t=(e=e.replace(/;$/,"").split(";")).length;t--;)e[t]=e[t].split("=");return e}(e.settings.font_formats||"Andale Mono=andale mono,monospace;Arial=arial,helvetica,sans-serif;Arial Black=arial black,sans-serif;Book Antiqua=book antiqua,palatino,serif;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier,monospace;Georgia=georgia,palatino,serif;Helvetica=helvetica,arial,sans-serif;Impact=impact,sans-serif;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco,monospace;Times New Roman=times new roman,times,serif;Trebuchet MS=trebuchet ms,geneva,sans-serif;Verdana=verdana,geneva,sans-serif;Webdings=webdings;Wingdings=wingdings,zapf dingbats");return r.map(t,function(e){return{text:{raw:e[0]},value:e[1],textStyle:-1===e[1].indexOf("dings")?"font-family:"+e[1]:""}})}(e);return{type:"listbox",text:"Font Family",tooltip:"Font Family",values:t,fixedWidth:!0,onPostRender:function(e,t){return function(){var n=this;e.on("init nodeChange",function(o){var i=sr.getFontFamily(e.getBody(),o.element),a=function(e,t){var n;return r.each(e,function(e){e.value.toLowerCase()===t.toLowerCase()&&(n=e.value)}),r.each(e,function(e){n||ur(e.value).toLowerCase()!==ur(t).toLowerCase()||(n=e.value)}),n}(t,i);n.value(a||null),!a&&i&&n.text(ur(i))})}}(e,t),onselect:function(t){t.control.settings.value&&e.execCommand("FontName",!1,t.control.settings.value)}}})}(e)}(e),function(e){var t=function(e){var t=0,n=[],o=[{title:"Headings",items:[{title:"Heading 1",format:"h1"},{title:"Heading 2",format:"h2"},{title:"Heading 3",format:"h3"},{title:"Heading 4",format:"h4"},{title:"Heading 5",format:"h5"},{title:"Heading 6",format:"h6"}]},{title:"Inline",items:[{title:"Bold",icon:"bold",format:"bold"},{title:"Italic",icon:"italic",format:"italic"},{title:"Underline",icon:"underline",format:"underline"},{title:"Strikethrough",icon:"strikethrough",format:"strikethrough"},{title:"Superscript",icon:"superscript",format:"superscript"},{title:"Subscript",icon:"subscript",format:"subscript"},{title:"Code",icon:"code",format:"code"}]},{title:"Blocks",items:[{title:"Paragraph",format:"p"},{title:"Blockquote",format:"blockquote"},{title:"Div",format:"div"},{title:"Pre",format:"pre"}]},{title:"Alignment",items:[{title:"Left",icon:"alignleft",format:"alignleft"},{title:"Center",icon:"aligncenter",format:"aligncenter"},{title:"Right",icon:"alignright",format:"alignright"},{title:"Justify",icon:"alignjustify",format:"alignjustify"}]}],i=function(e){var o=[];if(e)return r.each(e,function(e){var r={text:e.title,icon:e.icon};if(e.items)r.menu=i(e.items);else{var a=e.format||"custom"+t++;e.format||(e.name=a,n.push(e)),r.format=a,r.cmd=e.cmd}o.push(r)}),o};return e.on("init",function(){r.each(n,function(t){e.formatter.register(t.name,t)})}),{type:"menu",items:i(e.settings.style_formats_merge?e.settings.style_formats?o.concat(e.settings.style_formats):o:e.settings.style_formats||o),onPostRender:function(t){e.fire("renderFormatsMenu",{control:t.control})},itemDefaults:{preview:!0,textStyle:function(){if(this.settings.format)return e.formatter.getCssText(this.settings.format)},onPostRender:function(){var t=this;t.parent().on("show",function(){var n,r;(n=t.settings.format)&&(t.disabled(!e.formatter.canApply(n)),t.active(e.formatter.match(n))),(r=t.settings.cmd)&&t.active(e.queryCommandState(r))})},onclick:function(){this.settings.format&&or(e,this.settings.format)(),this.settings.cmd&&e.execCommand(this.settings.cmd)}}}}(e);!function(e,t){e.addMenuItem("formats",{text:"Formats",menu:t})}(e,t),function(e,t){e.addButton("styleselect",{type:"menubutton",text:"Formats",menu:t,onShowMenu:function(){e.settings.style_formats_autohide&&fr(e,this.menu)}})}(e,t)}(e),function(e){!function(e){e.addMenuItem("visualaid",{text:"Visual aids",selectable:!0,onPostRender:function(e){return function(){var t=this;e.on("VisualAid",function(e){t.active(e.hasVisual)}),t.active(e.hasVisual)}}(e),cmd:"mceToggleVisualAid"})}(e)}(e),function(e){!function(e){e.addButton("insert",{type:"menubutton",icon:"insert",menu:[],oncreatemenu:function(){this.menu.add(function(e){var t,n,o=e.settings.insert_button_items;return t=o?dr(e,o):function(e,t){var n=[{text:"-"}],o=r.grep(e.menuItems,function(e){return"insert"===e.context});return r.each(o,function(e){"before"===e.separator&&n.push({text:"|"}),e.prependToContext?n.unshift(e):n.push(e),"after"===e.separator&&n.push({text:"|"})}),n}(e),n=X(t,function(e,t,n){return!hr(e)||!hr(n[t-1])}),X(n,function(e,t,n){return!hr(e)||t>0&&t<n.length-1})}(e)),this.menu.renderNew()}})}(e)}(e)}},gr=It.extend({recalc:function(e){var t,n,r,o,i,a,s,u,c,l,f,d,h,p,m,g,v,y,b,w,x,C,S,T,E,k,N,R,_=[],A=[];t=e.settings,o=e.items().filter(":visible"),i=e.layoutRect(),r=t.columns||Math.ceil(Math.sqrt(o.length)),n=Math.ceil(o.length/r),y=t.spacingH||t.spacing||0,b=t.spacingV||t.spacing||0,w=t.alignH||t.align,x=t.alignV||t.align,g=e.paddingBox,R="reverseRows"in t?t.reverseRows:e.isRtl(),w&&"string"==typeof w&&(w=[w]),x&&"string"==typeof x&&(x=[x]);for(f=0;f<r;f++)_.push(0);for(d=0;d<n;d++)A.push(0);for(d=0;d<n;d++)for(f=0;f<r&&(l=o[d*r+f]);f++)E=(c=l.layoutRect()).minH,_[f]=(T=c.minW)>_[f]?T:_[f],A[d]=E>A[d]?E:A[d];for(k=i.innerW-g.left-g.right,C=0,f=0;f<r;f++)C+=_[f]+(f>0?y:0),k-=(f>0?y:0)+_[f];for(N=i.innerH-g.top-g.bottom,S=0,d=0;d<n;d++)S+=A[d]+(d>0?b:0),N-=(d>0?b:0)+A[d];if(S+=g.top+g.bottom,(u={}).minW=(C+=g.left+g.right)+(i.w-i.innerW),u.minH=S+(i.h-i.innerH),u.contentW=u.minW-i.deltaW,u.contentH=u.minH-i.deltaH,u.minW=Math.min(u.minW,i.maxW),u.minH=Math.min(u.minH,i.maxH),u.minW=Math.max(u.minW,i.startMinWidth),u.minH=Math.max(u.minH,i.startMinHeight),!i.autoResize||u.minW===i.minW&&u.minH===i.minH){var D;i.autoResize&&((u=e.layoutRect(u)).contentW=u.minW-i.deltaW,u.contentH=u.minH-i.deltaH),D="start"===t.packV?0:N>0?Math.floor(N/n):0;var O=0,P=t.flexWidths;if(P)for(f=0;f<P.length;f++)O+=P[f];else O=r;var B=k/O;
vendor: 13,586 bytes, line 1
1for(f=0;f<r;f++)_[f]+=P?P[f]*B:B;for(p=g.top,d=0;d<n;d++){for(h=g.left,s=A[d]+D,f=0;f<r&&(l=o[R?d*r+r-1-f:d*r+f]);f++)m=l.settings,c=l.layoutRect(),a=Math.max(_[f],c.startMinWidth),c.x=h,c.y=p,"center"===(v=m.alignH||(w?w[f]||w[0]:null))?c.x=h+a/2-c.w/2:"right"===v?c.x=h+a-c.w:"stretch"===v&&(c.w=a),"center"===(v=m.alignV||(x?x[f]||x[0]:null))?c.y=p+s/2-c.h/2:"bottom"===v?c.y=p+s-c.h:"stretch"===v&&(c.h=s),l.layoutRect(c),h+=a+y,l.recalc&&l.recalc();p+=s+b}}else if(u.w=u.minW,u.h=u.minH,e.layoutRect(u),this.recalc(e),null===e._lastRect){var I=e.parent();I&&(I._lastRect=null,I.recalc())}}}),vr=Tt.extend({renderHtml:function(){return this.classes.add("iframe"),this.canFocus=!1,'<iframe id="'+this._id+'" class="'+this.classes+'" tabindex="-1" src="'+(this.settings.url||"javascript:''")+'" frameborder="0"></iframe>'},src:function(e){this.getEl().src=e},html:function(e,t){var n=this,r=this.getEl().contentWindow.document.body;return r?(r.innerHTML=e,t&&t()):y.setTimeout(function(){n.html(e)}),this}}),yr=Tt.extend({init:function(e){this._super(e),this.classes.add("widget").add("infobox"),this.canFocus=!1},severity:function(e){this.classes.remove("error"),this.classes.remove("warning"),this.classes.remove("success"),this.classes.add(e)},help:function(e){this.state.set("help",e)},renderHtml:function(){var e=this.classPrefix;return'<div id="'+this._id+'" class="'+this.classes+'"><div id="'+this._id+'-body">'+this.encode(this.state.get("text"))+'<button role="button" tabindex="-1"><i class="'+e+"ico "+e+'i-help"></i></button></div></div>'},bindStates:function(){var e=this;return e.state.on("change:text",function(t){e.getEl("body").firstChild.data=e.encode(t.value),e.state.get("rendered")&&e.updateLayoutRect()}),e.state.on("change:help",function(t){e.classes.toggle("has-help",t.value),e.state.get("rendered")&&e.updateLayoutRect()}),e._super()}}),br=Tt.extend({init:function(e){this._super(e),this.classes.add("widget").add("label"),this.canFocus=!1,e.multiline&&this.classes.add("autoscroll"),e.strong&&this.classes.add("strong")},initLayoutRect:function(){var e=this._super();return this.settings.multiline&&(ve.getSize(this.getEl()).width>e.maxW&&(e.minW=e.maxW,this.classes.add("multiline")),this.getEl().style.width=e.minW+"px",e.startMinH=e.h=e.minH=Math.min(e.maxH,ve.getSize(this.getEl()).height)),e},repaint:function(){return this.settings.multiline||(this.getEl().style.lineHeight=this.layoutRect().h+"px"),this._super()},severity:function(e){this.classes.remove("error"),this.classes.remove("warning"),this.classes.remove("success"),this.classes.add(e)},renderHtml:function(){var e,t,n=this.settings.forId,r=this.settings.html?this.settings.html:this.encode(this.state.get("text"));return!n&&(t=this.settings.forName)&&(e=this.getRoot().find("#"+t)[0])&&(n=e._id),n?'<label id="'+this._id+'" class="'+this.classes+'"'+(n?' for="'+n+'"':"")+">"+r+"</label>":'<span id="'+this._id+'" class="'+this.classes+'">'+r+"</span>"},bindStates:function(){var e=this;return e.state.on("change:text",function(t){e.innerHtml(e.encode(t.value)),e.state.get("rendered")&&e.updateLayoutRect()}),e._super()}}),wr=ot.extend({Defaults:{role:"toolbar",layout:"flow"},init:function(e){this._super(e),this.classes.add("toolbar")},postRender:function(){return this.items().each(function(e){e.classes.add("toolbar-item")}),this._super()}}),xr=wr.extend({Defaults:{role:"menubar",containerCls:"menubar",ariaRoot:!0,defaults:{type:"menubutton"}}}),Cr=Lt.extend({init:function(e){this._renderOpen=!0,this._super(e),e=this.settings,this.classes.add("menubtn"),e.fixedWidth&&this.classes.add("fixed-width"),this.aria("haspopup",!0),this.state.set("menu",e.menu||this.render())},showMenu:function(e){var t,n=this;if(n.menu&&n.menu.visible()&&!1!==e)return n.hideMenu();n.menu||(t=n.state.get("menu")||[],n.classes.add("opened"),t.length?t={type:"menu",animate:!0,items:t}:(t.type=t.type||"menu",t.animate=!0),n.menu=t.renderTo?t.parent(n).show().renderTo():f.create(t).parent(n).renderTo(),n.fire("createmenu"),n.menu.reflow(),n.menu.on("cancel",function(e){e.control.parent()===n.menu&&(e.stopPropagation(),n.focus(),n.hideMenu())}),n.menu.on("select",function(){n.focus()}),n.menu.on("show hide",function(e){e.control===n.menu&&(n.activeMenu("show"===e.type),n.classes.toggle("opened","show"===e.type)),n.aria("expanded","show"===e.type)}).fire("show")),n.menu.show(),n.menu.layoutRect({w:n.layoutRect().w}),n.menu.repaint(),n.menu.moveRel(n.getEl(),n.isRtl()?["br-tr","tr-br"]:["bl-tl","tl-bl"]),n.fire("showmenu")},hideMenu:function(){this.menu&&(this.menu.items().each(function(e){e.hideMenu&&e.hideMenu()}),this.menu.hide())},activeMenu:function(e){this.classes.toggle("active",e)},renderHtml:function(){var e,t=this._id,n=this.classPrefix,r=this.settings.icon,o=this.state.get("text"),i="";return(e=this.settings.image)?(r="none","string"!=typeof e&&(e=window.getSelection?e[0]:e[1]),e=" style=\"background-image: url('"+e+"')\""):e="",o&&(this.classes.add("btn-has-text"),i='<span class="'+n+'txt">'+this.encode(o)+"</span>"),r=this.settings.icon?n+"ico "+n+"i-"+r:"",this.aria("role",this.parent()instanceof xr?"menuitem":"button"),'<div id="'+t+'" class="'+this.classes+'" tabindex="-1" aria-labelledby="'+t+'"><button id="'+t+'-open" role="presentation" type="button" tabindex="-1">'+(r?'<i class="'+r+'"'+e+"></i>":"")+i+' <i class="'+n+'caret"></i></button></div>'},postRender:function(){var e=this;return e.on("click",function(t){t.control===e&&function(e,t){for(;e;){if(t===e)return!0;e=e.parentNode}return!1}(t.target,e.getEl())&&(e.focus(),e.showMenu(!t.aria),t.aria&&e.menu.items().filter(":visible")[0].focus())}),e.on("mouseenter",function(t){var n,r=t.control,o=e.parent();r&&o&&r instanceof Cr&&r.parent()===o&&(o.items().filter("MenuButton").each(function(e){e.hideMenu&&e!==r&&(e.menu&&e.menu.visible()&&(n=!0),e.hideMenu())}),n&&(r.focus(),r.showMenu()))}),e._super()},bindStates:function(){var e=this;return e.state.on("change:menu",function(){e.menu&&e.menu.remove(),e.menu=null}),e._super()},remove:function(){this._super(),this.menu&&this.menu.remove()}}),Sr=bt.extend({Defaults:{defaultType:"menuitem",border:1,layout:"stack",role:"application",bodyRole:"menu",ariaRoot:!0},init:function(e){if(e.autohide=!0,e.constrainToViewport=!0,"function"==typeof e.items&&(e.itemsFactory=e.items,e.items=[]),e.itemDefaults)for(var t=e.items,n=t.length;n--;)t[n]=r.extend({},e.itemDefaults,t[n]);this._super(e),this.classes.add("menu"),e.animate&&11!==ce.ie&&this.classes.add("animate")},repaint:function(){return this.classes.toggle("menu-align",!0),this._super(),this.getEl().style.height="",this.getEl("body").style.height="",this},cancel:function(){this.hideAll(),this.fire("select")},load:function(){var e,t=this;function n(){t.throbber&&(t.throbber.hide(),t.throbber=null)}t.settings.itemsFactory&&(t.throbber||(t.throbber=new Ct(t.getEl("body"),!0),0===t.items().length?(t.throbber.show(),t.fire("loading")):t.throbber.show(100,function(){t.items().remove(),t.fire("loading")}),t.on("hide close",n)),t.requestTime=e=(new Date).getTime(),t.settings.itemsFactory(function(r){0!==r.length?t.requestTime===e&&(t.getEl().style.width="",t.getEl("body").style.width="",n(),t.items().remove(),t.getEl("body").innerHTML="",t.add(r),t.renderNew(),t.fire("loaded")):t.hide()}))},hideAll:function(){return this.find("menuitem").exec("hideMenu"),this._super()},preRender:function(){var e=this;return e.items().each(function(t){var n=t.settings;if(n.icon||n.image||n.selectable)return e._hasIcons=!0,!1}),e.settings.itemsFactory&&e.on("postrender",function(){e.settings.itemsFactory&&e.load()}),e.on("show hide",function(t){t.control===e&&("show"===t.type?y.setTimeout(function(){e.classes.add("in")},0):e.classes.remove("in"))}),e._super()}}),Tr=Cr.extend({init:function(e){var t,n,r,o,i=this;i._super(e),i._values=t=(e=i.settings).values,t&&("undefined"!=typeof e.value&&function t(o){for(var a=0;a<o.length;a++){if(n=o[a].selected||e.value===o[a].value)return r=r||o[a].text,i.state.set("value",o[a].value),!0;if(o[a].menu&&t(o[a].menu))return!0}}(t),!n&&t.length>0&&(r=t[0].text,i.state.set("value",t[0].value)),i.state.set("menu",t)),i.state.set("text",e.text||r),i.classes.add("listbox"),i.on("select",function(t){var n=t.control;o&&(t.lastControl=o),e.multiple?n.active(!n.active()):i.value(t.control.value()),o=n})},bindStates:function(){var e=this;return e.on("show",function(t){var n,r;n=t.control,r=e.value(),n instanceof Sr&&n.items().each(function(e){e.hasMenus()||e.active(e.value()===r)})}),e.state.on("change:value",function(t){var n=function e(t,n){var r;if(t)for(var o=0;o<t.length;o++){if(t[o].value===n)return t[o];if(t[o].menu&&(r=e(t[o].menu,n)))return r}}(e.state.get("menu"),t.value);e.text(n?n.text:e.settings.text)}),e._super()}}),Er=Tt.extend({Defaults:{border:0,role:"menuitem"},init:function(e){var t;this._super(e),e=this.settings,this.classes.add("menu-item"),e.menu&&this.classes.add("menu-item-expand"),e.preview&&this.classes.add("menu-item-preview"),"-"!==(t=this.state.get("text"))&&"|"!==t||(this.classes.add("menu-item-sep"),this.aria("role","separator"),this.state.set("text","-")),e.selectable&&(this.aria("role","menuitemcheckbox"),this.classes.add("menu-item-checkbox"),e.icon="selected"),e.preview||e.selectable||this.classes.add("menu-item-normal"),this.on("mousedown",function(e){e.preventDefault()}),e.menu&&!e.ariaHideMenu&&this.aria("haspopup",!0)},hasMenus:function(){return!!this.settings.menu},showMenu:function(){var e,t=this,n=t.settings,r=t.parent();if(r.items().each(function(e){e!==t&&e.hideMenu()}),n.menu){(e=t.menu)?e.show():((e=n.menu).length?e={type:"menu",items:e}:e.type=e.type||"menu",r.settings.itemDefaults&&(e.itemDefaults=r.settings.itemDefaults),(e=t.menu=f.create(e).parent(t).renderTo()).reflow(),e.on("cancel",function(n){n.stopPropagation(),t.focus(),e.hide()}),e.on("show hide",function(e){e.control.items&&e.control.items().each(function(e){e.active(e.settings.selected)})}).fire("show"),e.on("hide",function(n){n.control===e&&t.classes.remove("selected")}),e.submenu=!0),e._parentMenu=r,e.classes.add("menu-sub");var o=e.testMoveRel(t.getEl(),t.isRtl()?["tl-tr","bl-br","tr-tl","br-bl"]:["tr-tl","br-bl","tl-tr","bl-br"]);e.moveRel(t.getEl(),o),e.rel=o,o="menu-sub-"+o,e.classes.remove(e._lastRel).add(o),e._lastRel=o,t.classes.add("selected"),t.aria("expanded",!0)}},hideMenu:function(){return this.menu&&(this.menu.items().each(function(e){e.hideMenu&&e.hideMenu()}),this.menu.hide(),this.aria("expanded",!1)),this},renderHtml:function(){var e,t=this._id,n=this.settings,r=this.classPrefix,o=this.state.get("text"),i=this.settings.icon,a="",s=n.shortcut,u=this.encode(n.url);function c(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function l(e){var t=n.match||"";return t?e.replace(new RegExp(c(t),"gi"),function(e){return"!mce~match["+e+"]mce~match!"}):e}function f(e){return e.replace(new RegExp(c("!mce~match["),"g"),"<b>").replace(new RegExp(c("]mce~match!"),"g"),"</b>")}return i&&this.parent().classes.add("menu-has-icons"),n.image&&(a=" style=\"background-image: url('"+n.image+"')\""),s&&(s=function(e){var t,n,r;for(r=ce.mac?{alt:"⌥",ctrl:"⌘",shift:"⇧",meta:"⌘"}:{meta:"Ctrl"},e=e.split("+"),t=0;t<e.length;t++)(n=r[e[t].toLowerCase()])&&(e[t]=n);return e.join("+")}(s)),i=r+"ico "+r+"i-"+(this.settings.icon||"none"),e="-"!==o?'<i class="'+i+'"'+a+"></i>\xa0":"",o=f(this.encode(l(o))),u=f(this.encode(l(u))),'<div id="'+t+'" class="'+this.classes+'" tabindex="-1">'+e+("-"!==o?'<span id="'+t+'-text" class="'+r+'text">'+o+"</span>":"")+(s?'<div id="'+t+'-shortcut" class="'+r+'menu-shortcut">'+s+"</div>":"")+(n.menu?'<div class="'+r+'caret"></div>':"")+(u?'<div class="'+r+'menu-item-link">'+u+"</div>":"")+"</div>"},postRender:function(){var e=this,t=e.settings,n=t.textStyle;if("function"==typeof n&&(n=n.call(this)),n){var r=e.getEl("text");r&&(r.setAttribute("style",n),e._textStyle=n)}return e.on("mouseenter click",function(n){n.control===e&&(t.menu||"click"!==n.type?(e.showMenu(),n.aria&&e.menu.focus(!0)):(e.fire("select"),y.requestAnimationFrame(function(){e.parent().hideAll()})))}),e._super(),e},hover:function(){return this.parent().items().each(function(e){e.classes.remove("selected")}),this.classes.toggle("selected",!0),this},active:function(e){return function(e,t){var n=e._textStyle;if(n){var r=e.getEl("text");r.setAttribute("style",n),t&&(r.style.color="",r.style.backgroundColor="")}}(this,e),"undefined"!=typeof e&&this.aria("checked",e),this._super(e)},remove:function(){this._super(),this.menu&&this.menu.remove()}}),kr=Ft.extend({Defaults:{classes:"radio",role:"radio"}}),Nr=Tt.extend({renderHtml:function(){var e=this.classPrefix;return this.classes.add("resizehandle"),"both"===this.settings.direction&&this.classes.add("resizehandle-both"),this.canFocus=!1,'<div id="'+this._id+'" class="'+this.classes+'"><i class="'+e+"ico "+e+'i-resize"></i></div>'},postRender:function(){var e=this;e._super(),e.resizeDragHelper=new at(this._id,{start:function(){e.fire("ResizeStart")},drag:function(t){"both"!==e.settings.direction&&(t.deltaX=0),e.fire("Resize",t)},stop:function(){e.fire("ResizeEnd")}})},remove:function(){return this.resizeDragHelper&&this.resizeDragHelper.destroy(),this._super()}});function Rr(e){var t="";if(e)for(var n=0;n<e.length;n++)t+='<option value="'+e[n]+'">'+e[n]+"</option>";return t}var _r=Tt.extend({Defaults:{classes:"selectbox",role:"selectbox",options:[]},init:function(e){var t=this;t._super(e),t.settings.size&&(t.size=t.settings.size),t.settings.options&&(t._options=t.settings.options),t.on("key
1down",function(e){var n;13===e.keyCode&&(e.preventDefault(),t.parents().reverse().each(function(e){if(e.toJSON)return n=e,!1}),t.fire("submit",{data:n.toJSON()}))})},options:function(e){return arguments.length?(this.state.set("options",e),this):this.state.get("options")},renderHtml:function(){var e,t="";return e=Rr(this._options),this.size&&(t=' size = "'+this.size+'"'),'<select id="'+this._id+'" class="'+this.classes+'"'+t+">"+e+"</select>"},bindStates:function(){var e=this;return e.state.on("change:options",function(t){e.getEl().innerHTML=Rr(t.value)}),e._super()}});function Ar(e,t,n){return e<t&&(e=t),e>n&&(e=n),e}function Dr(e,t,n){e.setAttribute("aria-"+t,n)}function Or(e,t){var n,r,o,i,a;"v"===e.settings.orientation?(i="top",o="height",r="h"):(i="left",o="width",r="w"),a=e.getEl("handle"),n=(e.layoutRect()[r]||100)-ve.getSize(a)[o],a.style[i]=n*((t-e._minValue)/(e._maxValue-e._minValue))+"px",a.style.height=e.layoutRect().h+"px",Dr(a,"valuenow",t),Dr(a,"valuetext",""+e.settings.previewFilter(t)),Dr(a,"valuemin",e._minValue),Dr(a,"valuemax",e._maxValue)}var Pr,Br=Tt.extend({init:function(e){e.previewFilter||(e.previewFilter=function(e){return Math.round(100*e)/100}),this._super(e),this.classes.add("slider"),"v"===e.orientation&&this.classes.add("vertical"),this._minValue=hn.isNumber(e.minValue)?e.minValue:0,this._maxValue=hn.isNumber(e.maxValue)?e.maxValue:100,this._initValue=this.state.get("value")},renderHtml:function(){var e=this._id;return'<div id="'+e+'" class="'+this.classes+'"><div id="'+e+'-handle" class="'+this.classPrefix+'slider-handle" role="slider" tabindex="-1"></div></div>'},reset:function(){this.value(this._initValue).repaint()},postRender:function(){var e,t,n,r,o,i,a=this;e=a._minValue,t=a._maxValue,"v"===a.settings.orientation?(n="screenY",r="top",o="height",i="h"):(n="screenX",r="left",o="width",i="w"),a._super(),function(e,t){function n(n){var r,o;r=a.value(),r=Ar(r=function(e,n,r){return r*(t-e)-e}(e,0,(r+(o=e))/(t-o)+.05*n),e,t),a.value(r),a.fire("dragstart",{value:r}),a.fire("drag",{value:r}),a.fire("dragend",{value:r})}a.on("keydown",function(e){switch(e.keyCode){case 37:case 38:n(-1);break;case 39:case 40:n(1)}})}(e,t),function(e,t,s){var u,c,l,f,d;a._dragHelper=new at(a._id,{handle:a._id+"-handle",start:function(e){u=e[n],c=parseInt(a.getEl("handle").style[r],10),l=(a.layoutRect()[i]||100)-ve.getSize(s)[o],a.fire("dragstart",{value:d})},drag:function(o){f=Ar(c+(o[n]-u),0,l),s.style[r]=f+"px",a.value(d=e+f/l*(t-e)),a.tooltip().text(""+a.settings.previewFilter(d)).show().moveRel(s,"bc tc"),a.fire("drag",{value:d})},stop:function(){a.tooltip().hide(),a.fire("dragend",{value:d})}})}(e,t,a.getEl("handle"))},repaint:function(){this._super(),Or(this,this.value())},bindStates:function(){var e=this;return e.state.on("change:value",function(t){Or(e,t.value)}),e._super()}}),Ir=Tt.extend({renderHtml:function(){return this.classes.add("spacer"),this.canFocus=!1,'<div id="'+this._id+'" class="'+this.classes+'"></div>'}}),Lr=Cr.extend({Defaults:{classes:"widget btn splitbtn",role:"button"},repaint:function(){var e,t=this.getEl(),n=this.layoutRect();return this._super(),e=t.lastChild,me(t.firstChild).css({width:n.w-ve.getSize(e).width,height:n.h-2}),me(e).css({height:n.h-2}),this},activeMenu:function(e){me(this.getEl().lastChild).toggleClass(this.classPrefix+"active",e)},renderHtml:function(){var e,t=this._id,n=this.classPrefix,r=this.state.get("icon"),o=this.state.get("text"),i=this.settings,a="";return(e=i.image)?(r="none","string"!=typeof e&&(e=window.getSelection?e[0]:e[1]),e=" style=\"background-image: url('"+e+"')\""):e="",r=i.icon?n+"ico "+n+"i-"+r:"",o&&(this.classes.add("btn-has-text"),a='<span class="'+n+'txt">'+this.encode(o)+"</span>"),'<div id="'+t+'" class="'+this.classes+'" role="button"'+("boolean"==typeof i.active?' aria-pressed="'+i.active+'"':"")+' tabindex="-1"><button type="button" hidefocus="1" tabindex="-1">'+(r?'<i class="'+r+'"'+e+"></i>":"")+a+'</button><button type="button" class="'+n+'open" hidefocus="1" tabindex="-1">'+(this._menuBtnText?(r?"\xa0":"")+this._menuBtnText:"")+' <i class="'+n+'caret"></i></button></div>'},postRender:function(){var e=this.settings.onclick;return this.on("click",function(t){var n=t.target;if(t.control===this)for(;n;){if(t.aria&&"down"!==t.aria.key||"BUTTON"===n.nodeName&&-1===n.className.indexOf("open"))return t.stopImmediatePropagation(),void(e&&e.call(this,t));n=n.parentNode}}),delete this.settings.onclick,this._super()}}),Mr=rr.extend({Defaults:{containerClass:"stack-layout",controlClass:"stack-layout-item",endClass:"break"},isNative:function(){return!0}}),Hr=dt.extend({Defaults:{layout:"absolute",defaults:{type:"panel"}},activateTab:function(e){var t;this.activeTabId&&(t=this.getEl(this.activeTabId),me(t).removeClass(this.classPrefix+"active"),t.setAttribute("aria-selected","false")),this.activeTabId="t"+e,(t=this.getEl("t"+e)).setAttribute("aria-selected","true"),me(t).addClass(this.classPrefix+"active"),this.items()[e].show().fire("showtab"),this.reflow(),this.items().each(function(t,n){e!==n&&t.hide()})},renderHtml:function(){var e=this,t=e._layout,n="",r=e.classPrefix;return e.preRender(),t.preRender(e),e.items().each(function(t,o){var i=e._id+"-t"+o;t.aria("role","tabpanel"),t.aria("labelledby",i),n+='<div id="'+i+'" class="'+r+'tab" unselectable="on" role="tab" aria-controls="'+t._id+'" aria-selected="false" tabIndex="-1">'+e.encode(t.settings.title)+"</div>"}),'<div id="'+e._id+'" class="'+e.classes+'" hidefocus="1" tabindex="-1"><div id="'+e._id+'-head" class="'+r+'tabs" role="tablist">'+n+'</div><div id="'+e._id+'-body" class="'+e.bodyClasses+'">'+t.renderHtml(e)+"</div></div>"},postRender:function(){var e=this;e._super(),e.settings.activeTab=e.settings.activeTab||0,e.activateTab(e.settings.activeTab),this.on("click",function(t){var n=t.target.parentNode;if(n&&n.id===e._id+"-head")for(var r=n.childNodes.length;r--;)n.childNodes[r]===t.target&&e.activateTab(r)})},initLayoutRect:function(){var e,t,n;t=(t=ve.getSize(this.getEl("head")).width)<0?0:t,n=0,this.items().each(function(e){t=Math.max(t,e.layoutRect().minW),n=Math.max(n,e.layoutRect().minH)}),this.items().each(function(e){e.settings.x=0,e.settings.y=0,e.settings.w=t,e.settings.h=n,e.layoutRect({x:0,y:0,w:t,h:n})});var r=ve.getSize(this.getEl("head")).height;return this.settings.minWidth=t,this.settings.minHeight=n+r,(e=this._super()).deltaH+=r,e.innerH=e.h-e.deltaH,e}}
1),Fr=Tt.extend({init:function(e){var t=this;t._super(e),t.classes.add("textbox"),e.multiline?t.classes.add("multiline"):(t.on("keydown",function(e){var n;13===e.keyCode&&(e.preventDefault(),t.parents().reverse().each(function(e){if(e.toJSON)return n=e,!1}),t.fire("submit",{data:n.toJSON()}))}),t.on("keyup",function(e){t.state.set("value",e.target.value)}))},repaint:function(){var e,t,n,r,o,i=0;e=this.getEl().style,t=this._layoutRect,o=this._lastRepaintRect||{};var a=document;return!this.settings.multiline&&a.all&&(!a.documentMode||a.documentMode<=8)&&(e.lineHeight=t.h-i+"px"),r=(n=this.borderBox).left+n.right+8,i=n.top+n.bottom+(this.settings.multiline?8:0),t.x!==o.x&&(e.left=t.x+"px",o.x=t.x),t.y!==o.y&&(e.top=t.y+"px",o.y=t.y),t.w!==o.w&&(e.width=t.w-r+"px",o.w=t.w),t.h!==o.h&&(e.height=t.h-i+"px",o.h=t.h),this._lastRepaintRect=o,this.fire("repaint",{},!1),this},renderHtml:function(){var e,t,n=this.settings;return e={id:this._id,hidefocus:"1"},r.each(["rows","spellcheck","maxLength","size","readonly","min","max","step","list","pattern","placeholder","required","multiple"],function(t){e[t]=n[t]}),this.disabled()&&(e.disabled="disabled"),n.subtype&&(e.type=n.subtype),(t=ve.create(n.multiline?"textarea":"input",e)).value=this.state.get("value"),t.className=this.classes,t.outerHTML},value:function(e){return arguments.length?(this.state.set("value",e),this):(this.state.get("rendered")&&this.state.set("value",this.getEl().value),this.state.get("value"))},postRender:function(){var e=this;e.getEl().value=e.state.get("value"),e._super(),e.$el.on("change",function(t){e.state.set("value",t.target.value),e.fire("change",t)})},bindStates:function(){var e=this;return e.state.on("change:value",function(t){e.getEl().value!==t.value&&(e.getEl().value=t.value)}),e.state.on("change:disabled",function(t){e.getEl().disabled=t.value}),e._super()},remove:function(){this.$el.off(),this._super()}}),Wr=function(){return{Selector:Le,Collection:Fe,ReflowQueue:Xe,Control:et,Factory:f,KeyboardNavigation:nt,Container:ot,DragHelper:at,Scrollable:ft,Panel:dt,Movable:Se,Resizable:ht,FloatPanel:bt,Window:Dt,MessageBox:Ot,Tooltip:St,Widget:Tt,Progress:Et,Notification:Nt,Layout:Bt,AbsoluteLayout:It,Button:Lt,ButtonGroup:Ht,Checkbox:Ft,ComboBox:jt,ColorBox:$t,PanelButton:zt,ColorButton:Ut,ColorPicker:Xt,Path:Kt,ElementPath:Gt,FormItem:Jt,Form:Qt,FieldSet:Zt,FilePicker:er,FitLayout:tr,FlexLayout:nr,FlowLayout:rr,FormatControls:mr,GridLayout:gr,Iframe:vr,InfoBox:yr,Label:br,Toolbar:wr,MenuBar:xr,MenuButton:Cr,MenuItem:Er,Throbber:Ct,Menu:Sr,ListBox:Tr,Radio:kr,ResizeHandle:Nr,SelectBox:_r,Slider:Br,Spacer:Ir,SplitButton:Lr,StackLayout:Mr,TabPanel:Hr,TextBox:Fr,DropZone:Yt,BrowseButton:Mt}};r.each(Wr(),function(e,t){f.add(t,e)}),(Pr=window.tinymce?window.tinymce:{}).ui?r.each(Wr(),function(e,t){Pr.ui[t]=e}):Pr.ui=Wr(),t.add("modern",function(e){return mr.setup(e),Pt(e)})}(),function(){"use strict";var e=tinymce.util.Tools.resolve("tinymce.PluginManager"),t=tinymce.util.Tools.resolve("tinymce.util.VK"),n=function(e){return e.target_list},r=function(e){return e.rel_list},o=function(e){return e.link_class_list},i=n,a=r,s=function(e){return void 0!==r(e)},u=o,c=function(e){return"boolean"==typeof e.allow_unsafe_link_target&&e.allow_unsafe_link_target},l=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),f=tinymce.util.Tools.resolve("tinymce.Env"),d=tinymce.util.Tools.resolve("tinymce.util.Tools"),h=function(e,t){var n=["noopener"],r=e?e.split(/\s+/):[],o=function(e){return e.filter(function(e){return-1===d.inArray(n,e)})};return(r=t?function(e){return(e=o(e)).length?e.concat(n):n}(r):o(r)).length?d.trim(r.sort().join(" ")):null},p=function(e,t){return t=t||e.selection.getNode(),g(t)?e.dom.select("a[href]",t)[0]:e.dom.getParent(t,"a[href]")},m=function(e){return e&&"A"===e.nodeName&&e.href},g=function(e){return e&&"FIGURE"===e.nodeName&&/\bimage\b/i.test(e.className)},v=function(e){return function(){e.undoManager.transact(function(){var t=e.selection.getNode();g(t)?function(e,t){var n,r;(r=e.dom.select("img",t)[0])&&(n=e.dom.getParents(r,"a[href]",t)[0])&&(n.parentNode.insertBefore(r,n),e.dom.remove(n))}(e,t):e.execCommand("unlink")})}},y=m,b=function(e){return d.grep(e,m).length>0},w=p,x=h,C=tinymce.util.Tools.resolve("tinymce.util.Delay"),S=tinymce.util.Tools.resolve("tinymce.util.XHR"),T={},E=function(e,t,n){var r=function(e,n){return n=n||[],d.each(e,function(e){var o={text:e.text||e.title};e.menu?o.menu=r(e.menu):(o.value=e.value,t&&t(o)),n.push(o)}),n};return r(e,n||[])},k=function(e,t,n){var r=e.selection.getRng();C.setEditorTimeout(e,function(){e.windowManager.confirm(t,function(t){e.selection.setRng(r),n(t)})})},N=function(e,t){var r,l,f,m,y,b,C,S,N,R,_,A,D={},O=e.dom,P=function(e){var t=f.find("#text");
1(!t.value()||e.lastControl&&t.value()===e.lastControl.text())&&t.value(e.control.text()),f.find("#href").value(e.control.value())},B=function(){l||!m||D.text||this.parent().parent().find("#text")[0].value(this.value())};A=e.selection.getContent(),m=!(/</.test(A)&&(!/^<a [^>]+>[^<]+<\/a>$/.test(A)||-1===A.indexOf("href="))),r=w(e),D.text=l=function(t,n){return(n?n.innerText||n.textContent:e.selection.getContent({format:"text"})).replace(/\uFEFF/g,"")}(0,r),D.href=r?O.getAttrib(r,"href"):"",r?D.target=O.getAttrib(r,"target"):"string"==typeof e.settings.default_link_target&&(D.target=e.settings.default_link_target),(_=O.getAttrib(r,"rel"))&&(D.rel=_),(_=O.getAttrib(r,"class"))&&(D.class=_),(_=O.getAttrib(r,"title"))&&(D.title=_),m&&(y={name:"text",type:"textbox",size:40,label:"Text to display",onchange:function(){D.text=this.value()}}),t&&(b={type:"listbox",label:"Link list",values:E(t,function(t){t.value=e.convertURL(t.value||t.url,"href")},[{text:"None",value:""}]),onselect:P,value:e.convertURL(D.href,"href"),onPostRender:function(){b=this}}),!1!==n(e.settings)&&(void 0===i(e.settings)&&function(e,t){e.settings.target_list=[{text:"None",value:""},{text:"New window",value:"_blank"}]}(e),S={name:"target",type:"listbox",label:"Target",values:E(i(e.settings))}),s(e.settings)&&(C={name:"rel",type:"listbox",label:"Rel",values:E(a(e.settings),function(t){!1===c(e.settings)&&(t.value=x(t.value,"_blank"===D.target))})}),void 0!==o(e.settings)&&(N={name:"class",type:"listbox",label:"Class",values:E(u(e.settings),function(t){t.value&&(t.textStyle=function(){return e.formatter.getCssText({inline:"a",classes:[t.value]})})})}),!1!==e.settings.link_title&&(R={name:"title",type:"textbox",label:"Title",value:D.title}),f=e.windowManager.open({title:"Insert link",data:D,body:[{name:"href",type:"filepicker",filetype:"file",size:40,autofocus:!0,label:"Url",onchange:function(t){var n=t.meta||{};b&&b.value(e.convertURL(this.value(),"href")),d.each(t.meta,function(e,t){var n=f.find("#"+t);"text"===t?0===l.length&&(n.value(e),D.text=e):n.value(e)}),n.attach&&(T={href:this.value(),attach:n.attach}),n.text||B.call(this)},onkeyup:B,onpaste:B,onbeforecall:function(e){e.meta=f.toJSON()}},y,R,function(t){var n=[];if(d.each(e.dom.select("a:not([href])"),function(e){var r=e.name||e.id;r&&n.push({text:r,value:"#"+r,selected:-1!==t.indexOf("#"+r)})}),n.length)return n.unshift({text:"None",value:""}),{name:"anchor",type:"listbox",label:"Anchors",values:n,onselect:P}}(D.href),b,C,S,N],onSubmit:function(t){var n,r="boolean"==typeof(n=e.settings).link_assume_external_targets&&n.link_assume_external_targets,o=function(e,t){return function(n){e.undoManager.transact(function(){var r=e.selection.getNode(),o=p(e,r),i={href:n.href,target:n.target?n.target:null,rel:n.rel?n.rel:null,class:n.class?n.class:null,title:n.title?n.title:null};s(e.settings)||!1!==c(e.settings)||(i.rel=h(i.rel,"_blank"===i.target)),n.href===t.href&&(t.attach(),t={}),o?(e.focus(),n.hasOwnProperty("text")&&("innerText"in o?o.innerText=n.text:o.textContent=n.text),e.dom.setAttribs(o,i),e.selection.select(o),e.undoManager.add()):g(r)?function(e,t,n){var o,i;(i=e.dom.select("img",r)[0])&&(o=e.dom.create("a",n),i.parentNode.insertBefore(o,i),o.appendChild(i))}(e,0,i):n.hasOwnProperty("text")?e.insertContent(e.dom.createHTML("a",i,e.dom.encode(n.text))):e.execCommand("mceInsertLink",!1,i)})}}(e,T),i=v(e),a=d.extend({},D,t.data),u=a.href;u?(m&&a.text!==l||delete a.text,u.indexOf("@")>0&&-1===u.indexOf("//")&&-1===u.indexOf("mailto:")?k(e,"The URL you entered seems to be an email address. Do you want to add the required mailto: prefix?",function(e){e&&(a.href="mailto:"+u),o(a)}):!0===r&&!/^\w+:/i.test(u)||!1===r&&/^\s*www[\.|\d\.]/i.test(u)?k(e,"The URL you entered seems to be an external link. Do you want to add the required http:// prefix?",function(e){e&&(a.href="http://"+u),o(a)}):o(a)):i()}})},R=function(e,t){return e.dom.getParent(t,"a[href]")},_=function(e){return R(e,e.selection.getStart())},A=function(e,t){if(t){var n=(o=t).getAttribute("data-mce-href")||o.getAttribute("href");if(/^#/.test(n)){var r=e.$(n);r.length&&e.selection.scrollIntoView(r[0],!0)}else!function(e){if(!f.ie||f.ie>10){var t=document.createElement("a");t.target="_blank",t.href=e,t.rel="noreferrer noopener";var n=document.createEvent("MouseEvents");
1n.initMouseEvent("click",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),function(e,t){document.body.appendChild(e),e.dispatchEvent(t),document.body.removeChild(e)}(t,n)}else{var r=window.open("","_blank");if(r){r.opener=null;var o=r.document;o.open(),o.write('<meta http-equiv="refresh" content="0; url='+l.DOM.encode(e)+'">'),o.close()}}}(t.href)}var o},D=function(e){return function(){!function(e){!function(e,t){var n=e.settings.link_list;"string"==typeof n?S.send({url:n,success:function(n){t(e,JSON.parse(n))}}):"function"==typeof n?n(function(n){t(e,n)}):t(e,n)}(e,N)}(e)}},O=function(e){return function(){A(e,_(e))}},P=function(e){return function(){var t=this;e.on("nodechange",function(n){t.active(!e.readonly&&!!w(e,n.element))})}};e.add("link",function(e){(function(e){e.addButton("link",{active:!1,icon:"link",tooltip:"Insert/edit link",onclick:D(e),onpostrender:P(e)}),e.addButton("unlink",{active:!1,icon:"unlink",tooltip:"Remove link",onclick:v(e),onpostrender:P(e)}),e.addContextToolbar&&e.addButton("openlink",{icon:"newtab",tooltip:"Open link",onclick:O(e)})})(e),function(e){e.addMenuItem("openlink",{text:"Open link",icon:"newtab",onclick:O(e),onPostRender:function(e){return function(){var t=this,n=function(e){b(e.parents)?t.show():t.hide()};b(e.dom.getParents(e.selection.getStart()))||t.hide(),e.on("nodechange",n),t.on("remove",function(){e.off("nodechange",n)})}}(e),prependToContext:!0}),e.addMenuItem("link",{icon:"link",text:"Link",shortcut:"Meta+K",onclick:D(e),stateSelector:"a[href]",context:"insert",prependToContext:!0})}(e),function(e){e.addContextToolbar&&e.addContextToolbar(function(e){return function(t){var n,r,o,i;return!!("boolean"==typeof(i=e.settings).link_context_toolbar&&i.link_context_toolbar&&!function(e){var t=e.plugins.contextmenu;return!!t&&t.isContextMenuVisible()}(e)&&y(t)&&3===(o=(r=(n=e.selection).getRng()).startContainer).nodeType&&n.isCollapsed()&&r.startOffset>0&&r.startOffset<o.data.length)}}(e),"openlink | link unlink")}(e),function(e){e.on("click",function(n){var r=R(e,n.target);r&&t.metaKeyPressed(n)&&(n.preventDefault(),A(e,r))}),e.on("keydown",function(t){var n=_(e);n&&13===t.keyCode&&function(e){return!0===e.altKey&&!1===e.shiftKey&&!1===e.ctrlKey&&!1===e.metaKey}(t)&&(t.preventDefault(),A(e,n))})}(e),function(e){e.addCommand("mceLink",D(e))}(e),function(e){e.addShortcut("Meta+K","",D(e))}(e)})}(),function(){"use strict";var e=function(t){var n=t,r=function(){return n};return{get:r,set:function(e){n=e},clone:function(){return e(r())}}},t=tinymce.util.Tools.resolve("tinymce.PluginManager"),n=function(e,t){return e.fire("PastePlainTextToggle",{state:t})},r={shouldPlainTextInform:function(e){return e.getParam("paste_plaintext_inform",!0)},shouldBlockDrop:function(e){return e.getParam("paste_block_drop",!1)},shouldPasteDataImages:function(e){return e.getParam("paste_data_images",!1)},shouldFilterDrop:function(e){return e.getParam("paste_filter_drop",!0)},getPreProcess:function(e){return e.getParam("paste_preprocess")},getPostProcess:function(e){return e.getParam("paste_postprocess")},getWebkitStyles:function(e){return e.getParam("paste_webkit_styles")},shouldRemoveWebKitStyles:function(e){return e.getParam("paste_remove_styles_if_webkit",!0)},shouldMergeFormats:function(e){return e.getParam("paste_merge_formats",!0)},isSmartPasteEnabled:function(e){return e.getParam("smart_paste",!0)},isPasteAsTextEnabled:function(e){return e.getParam("paste_as_text",!1)},getRetainStyleProps:function(e){return e.getParam("paste_retain_style_properties")},getWordValidElements:function(e){return e.getParam("paste_word_valid_elements","-strong/b,-em/i,-u,-span,-p,-ol,-ul,-li,-h1,-h2,-h3,-h4,-h5,-h6,-p/div,-a[href|name],sub,sup,strike,br,del,table[width],tr,td[colspan|rowspan|width],th[colspan|rowspan|width],thead,tfoot,tbody")},shouldConvertWordFakeLists:function(e){return e.getParam("paste_convert_word_fake_lists",!0)},shouldUseDefaultFilters:function(e){return e.getParam("paste_enable_default_filters",!0)}},o=tinymce.util.Tools.resolve("tinymce.Env"),i=tinymce.util.Tools.resolve("tinymce.util.Delay"),a=tinymce.util.Tools.resolve("tinymce.util.Tools"),s=tinymce.util.Tools.resolve("tinymce.util.VK"),u="\x3c!-- x-tinymce/html --\x3e",c={mark:function(e){return u+e},unmark:function(e){return e.replace(u,"")},isMarked:function(e){return-1!==e.indexOf(u)},internalHtmlMime:function(){return"x-tinymce/html"}},l=tinymce.util.Tools.resolve("tinymce.html.Entities"),f=function(e){return e.replace(/\r?\n/g,"<br>")},d=function(e,t,n){var r=e.split(/\n\n/),o=function(e,t){var n,r=[],o="<"+e;if("object"==typeof t){for(n in t)t.hasOwnProperty(n)&&r.push(n+'="'+l.encodeAllRaw(t[n])+'"');r.length&&(o+=" "+r.join(" "))}return o+">"}(t,n),i="</"+t+">",s=a.map(r,function(e){return e.split(/\n/).join("<br />")});return 1===s.length?s[0]:a.map(s,function(e){return o+e+i}).join("")},h={isPlainText:function(e){return!/<(?:\/?(?!(?:div|p|br|span)>)\w+|(?:(?!(?:span style="white-space:\s?pre;?">)|br\s?\/>))\w+\s[^>]+)>/i.test(e)},convert:function(e,t,n){return t?d(e,t,n):f(e)},toBRs:f,toBlockElements:d},p=tinymce.util.Tools.resolve("tinymce.html.DomParser"),m=tinymce.util.Tools.resolve("tinymce.html.Node"),g=tinymce.util.Tools.resolve("tinymce.html.Schema"),v=tinymce.util.Tools.resolve("tinymce.html.Serializer");function y(e,t){return a.each(t,function(t){e=t.constructor===RegExp?e.replace(t,""):e.replace(t[0],t[1])}),e}var b={filter:y,innerText:function(e){var t=g(),n=p({},t),r="",o=t.getShortEndedElements(),i=a.makeMap("script noscript style textarea video audio iframe object"," "),s=t.getBlockElements();return e=y(e,[/<!\[[^\]]+\]>/g]),function e(t){var n=t.name,a=t;if("br"!==n)if(o[n]&&(r+=" "),i[n])r+=" ";else{if(3===t.type&&(r+=t.value),!t.shortEnded&&(t=t.firstChild))do{e(t)}while(t=t.next);s[n]&&a.next&&(r+="\n","p"===n&&(r+="\n"))}else r+="\n"}(n.parse(e)),r},trimHtml:function(e){return y(e,[/^[\s\S]*<body[^>]*>\s*|\s*<\/body[^>]*>[\s\S]*$/gi,/<!--StartFragment-->|<!--EndFragment-->
vendor: 4,085 bytes, line 1
1/g,[/( ?)<span class="Apple-converted-space">\u00a0<\/span>( ?)/g,function(e,t,n){return t||n?"\xa0":" "}],/<br class="Apple-interchange-newline">/g,/<br>$/i])},createIdGenerator:function(e){var t=0;return function(){return e+t++}},isMsEdge:function(){return-1!==navigator.userAgent.indexOf(" Edge/")}};function w(e){var t,n;return n=[/^[IVXLMCD]{1,2}\.[ \u00a0]/,/^[ivxlmcd]{1,2}\.[ \u00a0]/,/^[a-z]{1,2}[\.\)][ \u00a0]/,/^[A-Z]{1,2}[\.\)][ \u00a0]/,/^[0-9]+\.[ \u00a0]/,/^[\u3007\u4e00\u4e8c\u4e09\u56db\u4e94\u516d\u4e03\u516b\u4e5d]+\.[ \u00a0]/,/^[\u58f1\u5f10\u53c2\u56db\u4f0d\u516d\u4e03\u516b\u4e5d\u62fe]+\.[ \u00a0]/],e=e.replace(/^[\u00a0 ]+/,""),a.each(n,function(n){if(n.test(e))return t=!0,!1}),t}function x(e,t,n,o){var i,s={},u=e.dom.parseStyle(o);return a.each(u,function(a,u){switch(u){case"mso-list":(i=/\w+ \w+([0-9]+)/i.exec(o))&&(n._listLevel=parseInt(i[1],10)),/Ignore/i.test(a)&&n.firstChild&&(n._listIgnore=!0,n.firstChild._listIgnore=!0);break;case"horiz-align":u="text-align";break;case"vert-align":u="vertical-align";break;case"font-color":case"mso-foreground":u="color";break;case"mso-background":case"mso-highlight":u="background";break;case"font-weight":case"font-style":return void("normal"!==a&&(s[u]=a));case"mso-element":if(/^(comment|comment-list)$/i.test(a))return void n.remove()}0!==u.indexOf("mso-comment")?0!==u.indexOf("mso-")&&("all"===r.getRetainStyleProps(e)||t&&t[u])&&(s[u]=a):n.remove()}),/(bold)/i.test(s["font-weight"])&&(delete s["font-weight"],n.wrap(new m("b",1))),/(italic)/i.test(s["font-style"])&&(delete s["font-style"],n.wrap(new m("i",1))),(s=e.dom.serializeStyle(s,n.name))||null}var C={preProcess:function(e,t){return r.shouldUseDefaultFilters(e)?function(e,t){var n,o;(n=r.getRetainStyleProps(e))&&(o=a.makeMap(n.split(/[, ]/))),t=b.filter(t,[/<br class="?Apple-interchange-newline"?>/gi,/<b[^>]+id="?docs-internal-[^>]*>/gi,/<!--[\s\S]+?-->/gi,/<(!|script[^>]*>.*?<\/script(?=[>\s])|\/?(\?xml(:\w+)?|img|meta|link|style|\w:\w+)(?=[\s\/>]))[^>]*>/gi,[/<(\/?)s>/gi,"<$1strike>"],[/ /gi,"\xa0"],[/<span\s+style\s*=\s*"\s*mso-spacerun\s*:\s*yes\s*;?\s*"\s*>([\s\u00a0]*)<\/span>/gi,function(e,t){return t.length>0?t.replace(/./," ").slice(Math.floor(t.length/2)).split("").join("\xa0"):""}]]);var i=r.getWordValidElements(e),s=g({valid_elements:i,valid_children:"-li[p]"});a.each(s.elements,function(e){e.attributes.class||(e.attributes.class={},e.attributesOrder.push("class")),e.attributes.style||(e.attributes.style={},e.attributesOrder.push("style"))});var u=p({},s);u.addAttributeFilter("style",function(t){for(var n,r=t.length;r--;)(n=t[r]).attr("style",x(e,o,n,n.attr("style"))),"span"===n.name&&n.parent&&!n.attributes.length&&n.unwrap()}),u.addAttributeFilter("class",function(e){for(var t,n,r=e.length;r--;)n=(t=e[r]).attr("class"),/^(MsoCommentReference|MsoCommentText|msoDel)$/i.test(n)&&t.remove(),t.attr("class",null)}),u.addNodeFilter("del",function(e){for(var t=e.length;t--;)e[t].remove()}),u.addNodeFilter("a",function(e){for(var t,n,r,o=e.length;o--;)if(n=(t=e[o]).attr("href"),r=t.attr("name"),n&&-1!==n.indexOf("#_msocom_"))t.remove();else if(n&&0===n.indexOf("file://")&&(n=n.split("#")[1])&&(n="#"+n),n||r){if(r&&!/^_?(?:toc|edn|ftn)/i.test(r)){t.unwrap();continue}t.attr({href:n,name:r})}else t.unwrap()});var c=u.parse(t);return r.shouldConvertWordFakeLists(e)&&function(e){var t,n,r=1;function o(e){var t="";if(3===e.type)return e.value;if(e=e.firstChild)do{t+=o(e)}while(e=e.next);return t}function i(e,t){if(3===e.type&&t.test(e.value))return e.value=e.value.replace(t,""),!1;if(e=e.firstChild)do{if(!i(e,t))return!1}while(e=e.next);return!0}function a(e,o,a){var s=e._listLevel||r;s!==r&&(s<r?t&&(t=t.parent.parent):(n=t,t=null)),t&&t.name===o?t.append(e):(n=n||t,t=new m(o,1),a>1&&t.attr("start",""+a),e.wrap(t)),e.name="li",s>r&&n&&n.lastChild.append(t),r=s,function e(t){if(t._listIgnore)t.remove();else if(t=t.firstChild)do{e(t)}while(t=t.next)}(e),i(e,/^\u00a0+/),i(e,/^\s*([\u2022\u00b7\u00a7\u25CF]|\w+\.)/),i(e,/^\u00a0+/)}for(var s=[],u=e.firstChild;"undefined"!=typeof u&&null!==u;
1)if(s.push(u),null!==(u=u.walk()))for(;"undefined"!=typeof u&&u.parent!==e;)u=u.walk();for(var c=0;c<s.length;c++)if("p"===(e=s[c]).name&&e.firstChild){var l=o(e);if(/^[\s\u00a0]*[\u2022\u00b7\u00a7\u25CF]\s*/.test(l)){a(e,"ul");continue}if(w(l)){var f=/([0-9]+)\./.exec(l),d=1;f&&(d=parseInt(f[1],10)),a(e,"ol",d);continue}if(e._listLevel){a(e,"ul",1);continue}t=null}else n=t,t=null}(c),v({validate:e.settings.validate},s).serialize(c)}(e,t):t},isWordContent:function(e){return/<font face="Times New Roman"|class="?Mso|style="[^"]*\bmso-|style='[^'']*\bmso-|w:WordDocument/i.test(e)||/class="OutlineElement/.test(e)||/id="?docs\-internal\-guid\-/.test(e)}},S=function(e,t){return{content:e,cancelled:t}},T=function(e,t){return e.insertContent(t,{merge:r.shouldMergeFormats(e),paste:!0}),!0},E=function(e){return/^https?:\/\/[\w\?\-\/+=.&%@~#]+$/i.test(e)},k=function(e,t,n){return!(!1!==e.selection.isCollapsed()||!E(t))&&function(e,t,n){return e.undoManager.extra(function(){n(e,t)},function(){e.execCommand("mceInsertLink",!1,t)}),!0}(e,t,n)},N=function(e,t,n){return!(!E(r=t)||!/.(gif|jpe?g|png)$/.test(r))&&function(e,t,n){return e.undoManager.extra(function(){n(e,t)},function(){e.insertContent('<img src="'+t+'">')}),!0}(e,t,n);var r},R=function(e,t,n){var o=n||c.isMarked(t),i=function(e,t,n){var r=C.isWordContent(t);return function(e,t,n,r){var o=function(e,n,r,o){return e.fire("PastePreProcess",{content:t,internal:r,wordContent:o})}(e,0,n,r);return e.hasEventListeners("PastePostProcess")&&!o.isDefaultPrevented()?function(e,t,n,r){var i=function(e,t,n,r){return e.fire("PastePostProcess",{node:t,internal:n,wordContent:r})}(e,e.dom.create("div",{style:"display:none"},o.content),n,r);return S(i.node.innerHTML,i.isDefaultPrevented())}(e,0,n,r):S(o.content,o.isDefaultPrevented())}(e,r?C.preProcess(e,t):t,n,r)}(e,c.unmark(t),o);!1===i.cancelled&&function(e,t){!1===r.isSmartPasteEnabled(e)?T(e,t):function(e,t){a.each([k,N,T],function(n){return!0!==n(e,t,T)})}(e,t)}(e,i.content)},_=function(e,t){t=e.dom.encode(t).replace(/\r\n/g,"\n"),t=h.convert(t,e.settings.forced_root_block,e.settings.forced_root_block_attrs),R(e,t,!1)},A=function(e){var t={};if(e){if(e.getData){var n=e.getData("Text");n&&n.length>0&&-1===n.indexOf("data:text/mce-internal,")&&(t["text/plain"]=n)}if(e.types)for(var r=0;r<e.types.length;r++){var o=e.types[r];try{t[o]=e.getData(o)}catch(e){t[o]=""}}}return t},D=function(e,t){return t in e&&e[t].length>0},O=function(e){return D(e,"text/html")||D(e,"text/plain")},P=function(e,t,n,r){var o=b.createIdGenerator("mceclip");t&&(e.selection.setRng(t),t=null);var i,a,s,u=n.result,c=-1!==(a=(i=u).indexOf(","))?i.substr(a+1):null,l=o(),f=e.settings.images_reuse_filename&&r.name?function(e,t){var n=r.name.match(/([\s\S]+?)\.(?:jpeg|jpg|png|gif)$/i);return n?e.dom.encode(n[1]):null}(e):l,d=new Image;if(d.src=u,!(s=e.settings).images_dataimg_filter||s.images_dataimg_filter(d)){var h,p=e.editorUpload.blobCache,m=void 0;(h=p.findFirst(function(e){return e.base64()===c}))?m=h:(m=p.create(l,r,c,f),p.add(m)),R(e,'<img src="'+m.blobUri()+'">',!1)}else R(e,'<img src="'+u+'">',!1)},B=function(e,t,n){var r="paste"===t.type?t.clipboardData:t.dataTransfer;function o(r){var o,i,a,s=!1;if(r)for(o=0;o<r.length;o++)if(/^image\/(jpeg|png|gif|bmp)$/.test((i=r[o]).type)){var u=i.getAsFile?i.getAsFile():i;(a=new window.FileReader).onload=P.bind(null,e,n,a,u),a.readAsDataURL(u),t.preventDefault(),s=!0}return s}if(e.settings.paste_data_images&&r)return o(r.items)||o(r.files)},I=function(e){return s.metaKeyPressed(e)&&86===e.keyCode||e.shiftKey&&45===e.keyCode},L=function(e){return e.dom.get("mcepastebin")},M=function(e,t){return t===e},H=function(){},F=function(e,t,n,r){!function(e,t,n){if(!function(e){return!1===o.iOS&&void 0!==e&&"function"==typeof e.setData&&!0!==b.isMsEdge()}(e))return!1;try{return e.clearData(),e.setData("text/html",t),e.setData("text/plain",n),e.setData(c.internalHtmlMime(),t),!0}catch(e){return!1}}(e.clipboardData,t.html,t.text)?n(t.html,r):(e.preventDefault(),r())},W=function(e){return function(t,n){var r=c.mark(t),o=e.dom.create("div",{contenteditable:"false","data-mce-bogus":"all"}),i=e.dom.create("div",{contenteditable:"true"},r);e.dom.setStyles(o,{position:"fixed",top:"0",left:"-3000px",width:"1000px",overflow:"hidden"}),o.appendChild(i),e.dom.add(e.getBody(),o);var a=e.selection.getRng();i.focus();var s=e.dom.createRng();s.selectNodeContents(i),e.selection.setRng(s),setTimeout(function(){e.selection.setRng(a),o.parentNode.removeChild(o),n()},0)}},j=function(e){return{html:e.selection.getContent({contextual:!0}),text:e.selection.getContent({format:"text"})}},$=tinymce.util.Tools.resolve("tinymce.dom.RangeUtils"),z=function(e,t){return $.getCaretRangeFromPoint(t.clientX,t.clientY,e.getDoc())},q=function(e,t){e.focus(),e.selection.setRng(t)};function U(e,t){e.on("PastePreProcess",function(n){n.content=t(e,n.content,n.internal,n.wordContent)})}function V(e,t){if(!C.isWordContent(t))return t;var n=[];a.each(e.schema.getBlockElements(),function(e,t){n.push(t)});var r=new RegExp("(?:<br> [\\s\\r\\n]+|<br>)*(<\\/?("+n.join("|")+")[^>]*>)(?:<br> [\\s\\r\\n]+|<br>)*","g");return t=b.filter(t,[[r,"$1"]]),b.filter(t,[[/<br><br>/g,"<BR><BR>"],[/<br>/g," "],[/<BR><BR>/g,"<br>"]])}function X(e,t,n,o){if(o||n)return t;var i,a=r.getWebkitStyles(e);if(!1===r.shouldRemoveWebKitStyles(e)||"all"===a)return t;if(a&&(i=a.split(/[, ]/)),i){var s=e.dom,u=e.selection.getNode();t=t.replace(/(<[^>]+) style="([^"]*)"([^>]*>)/gi,function(e,t,n,r){var o=s.parseStyle(s.decode(n),"span"),a={};if("none"===i)return t+r;for(var c=0;c<i.length;c++){var l=o[i[c]],f=s.getStyle(u,i[c],!0);/color/.test(i[c])&&(l=s.toHex(l),f=s.toHex(f)),f!==l&&(a[i[c]]=l)}return(a=s.serializeStyle(a,"span"))?t+' style="'+a+'"'+r:t+r})}else t=t.replace(/(<[^>]+) style="([^"]*)"([^>]*>)/gi,"$1$3");return t.replace(/(<[^>]+) data-mce-style="([^"]+)"([^>]*>)/gi,function(e,t,n,r){return t+' style="'+n+'"'+r})}function Y(e,t){e.$("a",t).find("font,u").each(function(t,n){e.dom.remove(n,!0)})}var K=function(e){return function(){return e}},G=(K(!1),K(!0),function(e,t){var n=function(e){for(var t=new Array(arguments.length-1),n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];var o=t.concat(n);return e.apply(null,o)}}((K(!1),K(!0),function(e,t,n){var r=n.control;r.active("text"===t.pasteFormat),e.on("PastePlainTextToggle",function(e){r.active(e.state)})}),e,t);e.addButton("pastetext",{active:!1,icon:"pastetext",tooltip:"Paste as text",cmd:"mceTogglePlainTextPaste",onPostRender:n}),e.addMenuItem("pastetext",{text:"Paste as text",selectable:!0,active:t.pasteFormat,cmd:"mceTogglePlainTextPaste",onPostRender:n})}),J=e(!1);t.add("paste",function(s){if(!1===function(e){return!(!/(^|[ ,])powerpaste([, ]|$)/.test(e.settings.plugins)||!t.get("powerpaste")||("undefined"!=typeof window.console&&window.console.log&&window.console.log("PowerPaste is incompatible with Paste plugin! Remove 'paste' from the 'plugins' option."),0))}(s)){var u=function(t){var n=function(t){var n=e(null);return{create:function(){return function(e,t,n){var r,i,a=e.dom,s=e.getBody(),u=e.dom.getViewPort(e.getWin()).y,c=20;t.set(e.selection.getRng());var l=t.get();
1if(e.inline&&(i=e.selection.getScrollContainer())&&i.scrollTop>0&&(u=i.scrollTop),l.getClientRects){var f=function(e){var t,n,r,o=e.startContainer;if((t=e.getClientRects()).length)return t[0];if(e.collapsed&&1===o.nodeType){for(r=o.childNodes[l.startOffset];r&&3===r.nodeType&&!r.data.length;)r=r.nextSibling;if(r)return"BR"===r.tagName&&(n=a.doc.createTextNode("\ufeff"),r.parentNode.insertBefore(n,r),(e=a.createRng()).setStartBefore(n),e.setEndAfter(n),t=e.getClientRects(),a.remove(n)),t.length?t[0]:void 0}}(l);if(f)c=u+(f.top-a.getPos(s).y);else{c=u;var d=l.startContainer;d&&(3===d.nodeType&&d.parentNode!==s&&(d=d.parentNode),1===d.nodeType&&(c=a.getPos(d,i||s).y))}}r=e.dom.add(e.getBody(),"div",{id:"mcepastebin",contentEditable:!0,"data-mce-bogus":"all",style:"position: absolute; top: "+c+"px; width: 10px; height: 10px; overflow: hidden; opacity: 0"},"%MCEPASTEBIN%"),(o.ie||o.gecko)&&a.setStyle(r,"left","rtl"===a.getStyle(s,"direction",!0)?65535:-65535),a.bind(r,"beforedeactivate focusin focusout",function(e){e.stopPropagation()}),r.focus(),e.selection.select(r,!0)}(t,n)},remove:function(){return function(e,t){if(L(e)){for(var n=void 0,r=t.get();n=e.dom.get("mcepastebin");)e.dom.remove(n),e.dom.unbind(n);r&&e.selection.setRng(r)}t.set(null)}(t,n)},getEl:function(){return L(t)},getHtml:function(){return function(e){var t,n,r,o,i,s=function(t,n){t.appendChild(n),e.dom.remove(n,!0)};for(n=a.grep(e.getBody().childNodes,function(e){return"mcepastebin"===e.id}),t=n.shift(),a.each(n,function(e){s(t,e)}),r=(o=e.dom.select("div[id=mcepastebin]",t)).length-1;r>=0;r--)i=e.dom.create("div"),t.insertBefore(i,o[r]),s(i,o[r]);return t?t.innerHTML:""}(t)},getLastRng:function(){return function(e){return e.get()}(n)},isDefault:function(){return function(e,t){var n,r=L(e);return(n=r)&&"mcepastebin"===n.id&&M("%MCEPASTEBIN%",r.innerHTML)}(t)},isDefaultContent:function(e){return M("%MCEPASTEBIN%",e)}}}(t),s=r.isPasteAsTextEnabled(t)?"text":"html";return t.on("preInit",function(){return function(e,t,n){var r;(function(e,t,n){var r,s=0;function u(n,r,o,i){var a,s;D(n,"text/html")?a=n["text/html"]:(a=t.getHtml(),i=i||c.isMarked(a),t.isDefaultContent(a)&&(o=!0)),a=b.trimHtml(a),t.remove(),s=!1===i&&h.isPlainText(a),a.length&&!s||(o=!0),o&&(a=D(n,"text/plain")&&s?n["text/plain"]:b.innerText(a)),t.isDefaultContent(a)?r||e.windowManager.alert("Please use Ctrl+V/Cmd+V keyboard shortcuts to paste contents."):o?_(e,a):R(e,a,i)}e.on("keydown",function(n){function i(e){I(e)&&!e.isDefaultPrevented()&&t.remove()}if(I(n)&&!n.isDefaultPrevented()){if((r=n.shiftKey&&86===n.keyCode)&&o.webkit&&-1!==navigator.userAgent.indexOf("Version/"))return;if(n.stopImmediatePropagation(),s=(new Date).getTime(),o.ie&&r)return n.preventDefault(),void function(e,t){e.fire("paste",{ieFake:!0})}(e);t.remove(),t.create(),e.once("keyup",i),e.once("paste",function(){e.off("keyup",i)})}}),e.on("paste",function(l){var f=(new Date).getTime(),d=function(e,t){var n=A(l.clipboardData||e.getDoc().dataTransfer);return b.isMsEdge()?a.extend(n,{"text/html":""}):n}(e),h=(new Date).getTime()-f,p=(new Date).getTime()-s-h<1e3,m="text"===n||r,g=D(d,c.internalHtmlMime());r=!1,l.isDefaultPrevented()||function(e){var t=e.clipboardData;return-1!==navigator.userAgent.indexOf("Android")&&t&&t.items&&0===t.items.length}(l)?t.remove():O(d)||!B(e,l,t.getLastRng()||e.selection.getRng())?(p||l.preventDefault(),!o.ie||p&&!l.ieFake||D(d,"text/html")||(t.create(),e.dom.bind(t.getEl(),"paste",function(e){e.stopPropagation()}),e.getDoc().execCommand("Paste",!1,null),d["text/html"]=t.getHtml()),D(d,"text/html")?(l.preventDefault(),g||(g=c.isMarked(d["text/html"])),u(d,p,m,g)):i.setEditorTimeout(e,function(){u(d,p,m,g)},0)):t.remove()})})(e,t,n),e.parser.addNodeFilter("img",function(t,n,i){var a=function(e){e.attr("data-mce-object")||r===o.transparentSrc||e.remove()},s=function(e){return 0===e.indexOf("webkit-fake-url")},u=function(e){return 0===e.indexOf("data:")};if(!e.settings.paste_data_images&&function(e){return e.data&&!0===e.data.paste}(i))for(var c=t.length;c--;)(r=t[c].attributes.map.src)&&(s(r)?a(t[c]):!e.settings.allow_html_data_urls&&u(r)&&a(t[c]))})}(t,n,s)}),{pasteFormat:s,pasteHtml:function(e,n){return R(t,e,n)},pasteText:function(e){return _(t,e)},pasteImageData:function(e,n){return B(t,e,n)},getDataTransferItems:A,hasHtmlOrText:O,hasContentType:D}}(s),l=function(e){o.webkit&&U(e,X),o.ie&&(U(e,V),function(e,t){e.on("PastePostProcess",function(n){t(e,n.node)})}(e,Y))}(s),f=e(!1);return G(s,u),function(e,t,o){e.addCommand("mceTogglePlainTextPaste",function(){!function(e,t,o){"text"===t.pasteFormat?(t.pasteFormat="html",n(e,!1)):(t.pasteFormat="text",n(e,!0),function(e,t){return!1===t.get()&&r.shouldPlainTextInform(e)}(e,o)&&(function(e,t){e.notificationManager.open({text:e.translate("Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off."),type:"info"})}(e),o.set(!0))),e.focus()}(e,t,o)}
1),e.addCommand("mceInsertClipboardContent",function(e,n){n.content&&t.pasteHtml(n.content,n.internal),n.text&&t.pasteText(n.text)})}(s,u,J),function(e){var t=e.plugins.paste,n=r.getPreProcess(e);n&&e.on("PastePreProcess",function(e){n.call(t,t,e)});var o=r.getPostProcess(e);o&&e.on("PastePostProcess",function(e){o.call(t,t,e)})}(s),function(e){e.on("cut",function(e){return function(t){!1===e.selection.isCollapsed()&&F(t,j(e),W(e),function(){setTimeout(function(){e.execCommand("Delete")},0)})}}(e)),e.on("copy",function(e){return function(t){!1===e.selection.isCollapsed()&&F(t,j(e),W(e),H)}}(e))}(s),function(e,t,n){r.shouldBlockDrop(e)&&e.on("dragend dragover draggesture dragdrop drop drag",function(e){e.preventDefault(),e.stopPropagation()}),r.shouldPasteDataImages(e)||e.on("drop",function(e){var t=e.dataTransfer;t&&t.files&&t.files.length>0&&e.preventDefault()}),e.on("drop",function(o){var a,s;if(s=z(e,o),!o.isDefaultPrevented()&&!n.get()){a=t.getDataTransferItems(o.dataTransfer);var u,l=t.hasContentType(a,c.internalHtmlMime());if((t.hasHtmlOrText(a)&&(!(u=a["text/plain"])||0!==u.indexOf("file://"))||!t.pasteImageData(o,s))&&s&&r.shouldFilterDrop(e)){var f=a["mce-internal"]||a["text/html"]||a["text/plain"];f&&(o.preventDefault(),i.setEditorTimeout(e,function(){e.undoManager.transact(function(){a["mce-internal"]&&e.execCommand("Delete"),q(e,s),f=b.trimHtml(f),a["text/html"]?t.pasteHtml(f,l):t.pasteText(f)})}))}}}),e.on("dragstart",function(e){n.set(!0)}),e.on("dragover dragend",function(t){r.shouldPasteDataImages(e)&&!1===n.get()&&(t.preventDefault(),q(e,z(e,t))),"dragend"===t.type&&n.set(!1)})}(s,u,f),function(e,t){return{clipboard:e,quirks:t}}(u,l)}})}(),function(){"use strict";var e,t,n=tinymce.util.Tools.resolve("tinymce.PluginManager"),r=function(e){return function(){return e}},o={noop:function(){},noarg:function(e){return function(){return e()}},compose:function(e,t){return function(){return e(t.apply(null,arguments))}},constant:r,identity:function(e){return e},tripleEquals:function(e,t){return e===t},curry:function(e){for(var t=new Array(arguments.length-1),n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];var o=t.concat(n);return e.apply(null,o)}},not:function(e){return function(){return!e.apply(null,arguments)}},die:function(e){return function(){throw new Error(e)}},apply:function(e){return e()},call:function(e){e()},never:r(!1),always:r(!0)},i=o.never,a=o.always,s=function(){return u},u=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:i,isSome:i,isNone:a,getOr:n,getOrThunk:t,getOrDie:function(e){throw new Error(e||"error: getOrDie called on none.")},or:n,orThunk:t,map:s,ap:s,each:function(){},bind:s,flatten:s,exists:i,forall:a,filter:s,equals:e,equals_:e,toArray:function(){return[]},toString:o.constant("none()")};return Object.freeze&&Object.freeze(r),r}(),c=function(e){var t=function(){return 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:a,isNone:i,getOr:t,getOrThunk:t,getOrDie:t,or:n,orThunk:n,map:function(t){return c(t(e))},ap:function(t){return t.fold(s,function(t){return c(t(e))})},each:function(t){t(e)},bind:r,flatten:t,exists:r,forall:r,filter:function(t){return t(e)?o:u},equals:function(t){return t.is(e)},equals_:function(t,n){return t.fold(i,function(t){return n(e,t)})},toArray:function(){return[e]},toString:function(){return"some("+e+")"}};return o},l={some:c,none:s,from:function(e){return null===e||void 0===e?u:c(e)}},f=void 0===(e=Array.prototype.indexOf)?function(e,t){return y(e,t)}:function(t,n){return e.call(t,n)},d=function(e,t){return f(e,t)>-1},h=function(e,t){for(var n=e.length,r=new Array(n),o=0;o<n;o++)r[o]=t(e[o],o,e);return r},p=function(e,t){for(var n=0,r=e.length;n<r;n++)t(e[n],n,e)},m=function(e,t){for(var n=e.length-1;n>=0;n--)t(e[n],n,e)},g=function(e,t){for(var n=[],r=0,o=e.length;r<o;r++){var i=e[r];t(i,r,e)&&n.push(i)}return n},v=function(e,t){for(var n=0,r=e.length;n<r;n++)if(t(e[n],n,e))return l.some(n);return l.none()},y=function(e,t){for(var n=0,r=e.length;n<r;++n)if(e[n]===t)return n;return-1},b=Array.prototype.push,w=function(e){for(var t=[],n=0,r=e.length;n<r;++n){if(!Array.prototype.isPrototypeOf(e[n]))throw new Error("Arr.flatten item "+n+" was not an array, input
1: "+e);b.apply(t,e[n])}return t},x=function(e,t){for(var n=0,r=e.length;n<r;++n)if(!0!==t(e[n],n,e))return!1;return!0},C=Array.prototype.slice,S={map:h,each:p,eachr:m,partition:function(e,t){for(var n=[],r=[],o=0,i=e.length;o<i;o++){var a=e[o];(t(a,o,e)?n:r).push(a)}return{pass:n,fail:r}},filter:g,groupBy:function(e,t){if(0===e.length)return[];for(var n=t(e[0]),r=[],o=[],i=0,a=e.length;i<a;i++){var s=e[i],u=t(s);u!==n&&(r.push(o),o=[]),n=u,o.push(s)}return 0!==o.length&&r.push(o),r},indexOf:function(e,t){var n=f(e,t);return-1===n?l.none():l.some(n)},foldr:function(e,t,n){return m(e,function(e){n=t(n,e)}),n},foldl:function(e,t,n){return p(e,function(e){n=t(n,e)}),n},find:function(e,t){for(var n=0,r=e.length;n<r;n++){var o=e[n];if(t(o,n,e))return l.some(o)}return l.none()},findIndex:v,flatten:w,bind:function(e,t){var n=h(e,t);return w(n)},forall:x,exists:function(e,t){return v(e,t).isSome()},contains:d,equal:function(e,t){return e.length===t.length&&x(e,function(e,n){return e===t[n]})},reverse:function(e){var t=C.call(e,0);return t.reverse(),t},chunk:function(e,t){for(var n=[],r=0;r<e.length;r+=t){var o=e.slice(r,r+t);n.push(o)}return n},difference:function(e,t){return g(e,function(e){return!d(t,e)})},mapToObject: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},pure:function(e){return[e]},sort:function(e,t){var n=C.call(e,0);return n.sort(t),n},range:function(e,t){for(var n=[],r=0;r<e;r++)n.push(t(r));return n},head:function(e){return 0===e.length?l.none():l.some(e[0])},last:function(e){return 0===e.length?l.none():l.some(e[e.length-1])}},T=void 0===(t=Object.keys)?function(e){var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}:t,E=function(e,t){for(var n=T(e),r=0,o=n.length;r<o;r++){var i=n[r];t(e[i],i,e)}},k=function(e,t){var n={};return E(e,function(r,o){var i=t(r,o,e);n[i.k]=i.v}),n},N=function(e,t){var n=[];return E(e,function(e,r){n.push(t(e,r))}),n},R=function(e){return N(e,function(e){return e})},_={bifilter:function(e,t){var n={},r={};return E(e,function(e,o){(t(e,o)?n:r)[o]=e}),{t:n,f:r}},each:E,map:function(e,t){return k(e,function(e,n,r){return{k:n,v:t(e,n,r)}})},mapToArray:N,tupleMap:k,find:function(e,t){for(var n=T(e),r=0,o=n.length;r<o;r++){var i=n[r],a=e[i];if(t(a,i,e))return l.some(a)}return l.none()},keys:T,values:R,size:function(e){return R(e).length}},A=function(e){return function(t){return function(e){if(null===e)return"null";var t=typeof e;return"object"===t&&Array.prototype.isPrototypeOf(e)?"array":"object"===t&&String.prototype.isPrototypeOf(e)?"string":t}(t)===e}},D={isString:A("string"),isObject:A("object"),isArray:A("array"),isNull:A("null"),isBoolean:A("boolean"),isUndefined:A("undefined"),isFunction:A("function"),isNumber:A("number")},O=function(e){return e.slice(0).sort()},P=function(e,t){throw new Error("All required keys ("+O(e).join(", ")+") were not specified. Specified keys were: "+O(t).join(", ")+".")},B=function(e){throw new Error("Unsupported keys for object: "+O(e).join(", "))},I=function(e,t){if(!D.isArray(t))throw new Error("The "+e+" fields must be an array. Was: "+t+".");S.each(t,function(t){if(!D.isString(t))throw new Error("The value "+t+" in the "+e+" fields was not a string.")})},L=function(e){var t=O(e);S.find(t,function(e,n){return n<t.length-1&&e===t[n+1]}).each(function(e){throw new Error("The field: "+e+" occurs more than once in the combined fields: ["+t.join(", ")+"].")})},M={immutable:function(){var e=arguments;return function(){for(var t=new Array(arguments.length),n=0;n<t.length;n++)t[n]=arguments[n];if(e.length!==t.length)throw new Error('Wrong number of arguments to struct. Expected "['+e.length+']", got '+t.length+" arguments");var r={};return S.each(e,function(e,n){r[e]=o.constant(t[n])}),r}},immutableBag:function(e,t){var n=e.concat(t);if(0===n.length)throw new Error("You must specify at least one required or optional field.");return I("required",e),I("optional",t),L(n),function(r){var i=_.keys(r);S.forall(e,function(e){return S.contains(i,e)})||P(e,i);var a=S.filter(i,function(e){return!S.contains(n,e)});a.length>0&&B(a);var s={};return S.each(e,function(e){s[e]=o.constant(r[e])}),S.each(t,function(e){s[e]=o.constant(Object.prototype.hasOwnProperty.call(r,e)?l.some(r[e]):l.none())}),s}}},H=M.immutable("width","height"),F=M.immutable("rows","columns"),W=M.immutable("row","column"),j=M.immutable("x","y"),$=M.immutable("element","rowspan","colspan"),z=M.immutable("element","rowspan","colspan","isNew"),q={dimensions:H,grid:F,address:W,coords:j,extended:M.immutable("element","rowspan","colspan","row","column"),detail:$,detailnew:z,rowdata:M.immutable("element","cells","section"),elementnew:M.immutable("element","isNew"),rowdatanew:M.immutable("element","cells","section","isNew"),rowcells:M.immutable("cells","section"),rowdetail
1s:M.immutable("details","section"),bounds:M.immutable("startRow","startCol","finishRow","finishCol")},U=function(e){if(null===e||void 0===e)throw new Error("Node cannot be null or undefined");return{dom:o.constant(e)}},V={fromHtml:function(e,t){var n=(t||document).createElement("div");if(n.innerHTML=e,!n.hasChildNodes()||n.childNodes.length>1)throw console.error("HTML does not have a single root node",e),"HTML must have a single root node";return U(n.childNodes[0])},fromTag:function(e,t){var n=(t||document).createElement(e);return U(n)},fromText:function(e,t){var n=(t||document).createTextNode(e);return U(n)},fromDom:U,fromPoint:function(e,t,n){return l.from(e.dom().elementFromPoint(t,n)).map(U)}},X=function(e){return 1!==e.nodeType&&9!==e.nodeType||0===e.childElementCount},Y={all:function(e,t){var n=void 0===t?document:t.dom();return X(n)?[]:S.map(n.querySelectorAll(e),V.fromDom)},is:function(e,t){var n=e.dom();if(1!==n.nodeType)return!1;if(void 0!==n.matches)return n.matches(t);if(void 0!==n.msMatchesSelector)return n.msMatchesSelector(t);if(void 0!==n.webkitMatchesSelector)return n.webkitMatchesSelector(t);if(void 0!==n.mozMatchesSelector)return n.mozMatchesSelector(t);throw new Error("Browser lacks native selectors")},one:function(e,t){var n=void 0===t?document:t.dom();return X(n)?l.none():l.from(n.querySelector(e)).map(V.fromDom)}},K=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},G="undefined"!=typeof window?window:Function("return this;")(),J=function(){return function(e,t){var n=function(e,t){return function(e,t){for(var n=void 0!==t&&null!==t?t:G,r=0;r<e.length&&void 0!==n&&null!==n;++r)n=n[e[r]];return n}(e.split("."),t)}("Node",void 0);if(void 0===n||null===n)throw"Node not available on this browser";return n}()},Q=function(e){var t,n=!1;return function(){return n||(n=!0,t=e.apply(null,arguments)),t}},Z=function(){return ee(0,0)},ee=function(e,t){return{major:e,minor:t}},te=function(e,t){var n=String(t).toLowerCase();return 0===e.length?Z():function(t,n){var r=function(e,t){for(var n=0;n<e.length;n++){var r=e[n];if(r.test(t))return r}}(e,n);if(!r)return{major:0,minor:0};var o=function(e){return Number(n.replace(r,"$"+e))};return ee(o(1),o(2))}(0,n)},ne=Z,re=function(e,t){return function(){return t===e}},oe=function(e){var t=e.current;return{current:t,version:e.version,isEdge:re("Edge",t),isChrome:re("Chrome",t),isIE:re("IE",t),isOpera:re("Opera",t),isFirefox:re("Firefox",t),isSafari:re("Safari",t)}},ie=function(){return oe({current:void 0,version:ne()})},ae=oe,se=(o.constant("Edge"),o.constant("Chrome"),o.constant("IE"),o.constant("Opera"),o.constant("Firefox"),o.constant("Safari"),function(e,t){return function(){return t===e}}),ue=function(e){var t=e.current;return{current:t,version:e.version,isWindows:se("Windows",t),isiOS:se("iOS",t),isAndroid:se("Android",t),isOSX:se("OSX",t),isLinux:se("Linux",t),isSolaris:se("Solaris",t),isFreeBSD:se("FreeBSD",t)}},ce=function(){return ue({current:void 0,version:ne()})},le=ue,fe=(o.constant("Windows"),o.constant("iOS"),o.constant("Android"),o.constant("Linux"),o.constant("OSX"),o.constant("Solaris"),o.constant("FreeBSD"),function(e,t){var n=String(t).toLowerCase();return S.find(e,function(e){return e.search(n)})}),de=function(e,t){return function(e,t,n){return""===t||!(e.length<t.length)&&e.substr(n,n+t.length)===t}(e,t,e.length-t.length)},he=function(e,t){return-1!==e.indexOf(t)},pe=/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,me=function(e){return function(t){return he(t,e)}},ge=[{name:"Edge",versionRegexes:[/.*?edge\/ ?([0-9]+)\.([0-9]+)$/],search:function(e){return he(e,"edge/")&&he(e,"chrome")&&he(e,"safari")&&he(e,"applewebkit")}},{name:"Chrome",versionRegexes:[/.*?chrome\/([0-9]+)\.([0-9]+).*/,pe],search:function(e){return he(e,"chrome")&&!he(e,"chromeframe")}},{name:"IE",versionRegexes:[/.*?msie\ ?([0-9]+)\.([0-9]+).*/,/.*?rv:([0-9]+)\.([0-9]+).*/],search:function(e){return he(e,"msie")||he(e,"trident")}},{name:"Opera",versionRegexes:[pe,/.*?opera\/([0-9]+)\.([0-9]+).*/],search:me("opera")},{name:"Firefox",versionRegexes:[/.*?firefox\/\ ?([0-9]+)\.([0-9]+).*/],search:me("firefox")},{name:"Safari",versionRegexes:[pe,/.*?cpu os ([0-9]+)_([0-9]+).*/],search:function(e){return(
1he(e,"safari")||he(e,"mobile/"))&&he(e,"applewebkit")}}],ve=[{name:"Windows",search:me("win"),versionRegexes:[/.*?windows\ nt\ ?([0-9]+)\.([0-9]+).*/]},{name:"iOS",search:function(e){return he(e,"iphone")||he(e,"ipad")},versionRegexes:[/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,/.*cpu os ([0-9]+)_([0-9]+).*/,/.*cpu iphone os ([0-9]+)_([0-9]+).*/]},{name:"Android",search:me("android"),versionRegexes:[/.*?android\ ?([0-9]+)\.([0-9]+).*/]},{name:"OSX",search:me("os x"),versionRegexes:[/.*?os\ x\ ?([0-9]+)_([0-9]+).*/]},{name:"Linux",search:me("linux"),versionRegexes:[]},{name:"Solaris",search:me("sunos"),versionRegexes:[]},{name:"FreeBSD",search:me("freebsd"),versionRegexes:[]}],ye={browsers:o.constant(ge),oses:o.constant(ve)},be={detect:Q(function(){return function(e){var t=ye.browsers(),n=ye.oses(),r=function(e,t){return fe(e,t).map(function(e){var n=te(e.versionRegexes,t);return{current:e.name,version:n}})}(t,e).fold(ie,ae),i=function(e,t){return fe(e,t).map(function(e){var n=te(e.versionRegexes,t);return{current:e.name,version:n}})}(n,e).fold(ce,le);return{browser:r,os:i,deviceType:function(e,t,n){var r=e.isiOS()&&!0===/ipad/i.test(n),i=e.isiOS()&&!r,a=e.isAndroid()&&3===e.version.major,s=e.isAndroid()&&4===e.version.major,u=r||a||s&&!0===/mobile/i.test(n),c=e.isiOS()||e.isAndroid(),l=c&&!u,f=t.isSafari()&&e.isiOS()&&!1===/safari/i.test(n);return{isiPad:o.constant(r),isiPhone:o.constant(i),isTablet:o.constant(u),isPhone:o.constant(l),isTouch:o.constant(c),isAndroid:e.isAndroid,isiOS:e.isiOS,isWebView:o.constant(f)}}(i,r,e)}}(navigator.userAgent)})},we=function(e,t){return e.dom()===t.dom()},xe=be.detect().browser.isIE()?function(e,t){return function(e,t,n){return 0!=(e.compareDocumentPosition(t)&n)}(e.dom(),t.dom(),J().DOCUMENT_POSITION_CONTAINED_BY)}:function(e,t){var n=e.dom(),r=t.dom();return n!==r&&n.contains(r)},Ce={eq:we,isEqualNode:function(e,t){return e.dom().isEqualNode(t.dom())},member:function(e,t){return S.exists(t,o.curry(we,e))},contains:xe,is:Y.is},Se=function(e){return V.fromDom(e.dom().ownerDocument)},Te=function(e){var t=e.dom();return l.from(t.parentNode).map(V.fromDom)},Ee=function(e){var t=e.dom();return l.from(t.previousSibling).map(V.fromDom)},ke=function(e){var t=e.dom();return l.from(t.nextSibling).map(V.fromDom)},Ne=function(e){var t=e.dom();return S.map(t.childNodes,V.fromDom)},Re=function(e,t){var n=e.dom().childNodes;return l.from(n[t]).map(V.fromDom)},_e=M.immutable("element","offset"),Ae={owner:Se,defaultView:function(e){var t=e.dom();return V.fromDom(t.ownerDocument.defaultView)},documentElement:function(e){var t=Se(e);return V.fromDom(t.dom().documentElement)},parent:Te,findIndex:function(e){return Te(e).bind(function(t){var n=Ne(t);return S.findIndex(n,function(t){return Ce.eq(e,t)})})},parents:function(e,t){for(var n=D.isFunction(t)?t:o.constant(!1),r=e.dom(),i=[];null!==r.parentNode&&void 0!==r.parentNode;){var a=r.parentNode,s=V.fromDom(a);if(i.push(s),!0===n(s))break;r=a}return i},siblings:function(e){return Te(e).map(Ne).map(function(t){return S.filter(t,function(t){return!Ce.eq(e,t)})}).getOr([])},prevSibling:Ee,offsetParent:function(e){var t=e.dom();return l.from(t.offsetParent).map(V.fromDom)},prevSiblings:function(e){return S.reverse(K(e,Ee))},nextSibling:ke,nextSiblings:function(e){return K(e,ke)},children:Ne,child:Re,firstChild:function(e){return Re(e,0)},lastChild:function(e){return Re(e,e.dom().childNodes.length-1)},childNodesCount:function(e){return e.dom().childNodes.length},hasChildNodes:function(e){return e.dom().hasChildNodes()},leaf:function(e,t){var n=Ne(e);return n.length>0&&t<n.length?_e(n[t],0):_e(e,t)}},De=function(e,t,n){return S.bind(Ae.children(e),function(e){return Y.is(e,t)?n(e)?[e]:[]:De(e,t,n)})},Oe={firstLayer:function(e,t){return De(e,t,o.constant(!0))},filterFirstLayer:De},Pe=function(e){return e.dom().nodeName.toLowerCase()},Be=function(e){return e.dom().nodeType},Ie=function(e){return function(t){return Be(t)===e}},Le=Ie(1),Me=Ie(3),He=Ie(9),Fe={name:Pe,type:Be,value:function(e){return e.dom().nodeValue},isElement:Le,isText:Me,isDocument:He,isComment:function(e){return 8===Be(e)||"#comment"===Pe(e)}},We=function(e,t,n){if(!(D.isString(n)||D.isBoolean(n)||D.isNumber(n)))throw console.error("Invalid call to Attr.set. Key ",t,":: Value ",n,"::
1Element ",e),new Error("Attribute value was not simple");e.setAttribute(t,n+"")},je=function(e,t,n){We(e.dom(),t,n)},$e=function(e,t){var n=e.dom().getAttribute(t);return null===n?void 0:n},ze=function(e,t){var n=e.dom();return!(!n||!n.hasAttribute)&&n.hasAttribute(t)},qe={clone:function(e){return S.foldl(e.dom().attributes,function(e,t){return e[t.name]=t.value,e},{})},set:je,setAll:function(e,t){var n=e.dom();_.each(t,function(e,t){We(n,t,e)})},get:$e,has:ze,remove:function(e,t){e.dom().removeAttribute(t)},hasNone:function(e){var t=e.dom().attributes;return void 0===t||null===t||0===t.length},transfer:function(e,t,n){Fe.isElement(e)&&Fe.isElement(t)&&S.each(n,function(n){!function(e,t,n){ze(e,n)&&!ze(t,n)&&je(t,n,$e(e,n))}(e,t,n)})}},Ue=Q(function(){return Ve(V.fromDom(document))}),Ve=function(e){var t=e.dom().body;if(null===t||void 0===t)throw"Body is not available yet";return V.fromDom(t)},Xe={body:Ue,getBody:Ve,inBody:function(e){var t=Fe.isText(e)?e.dom().parentNode:e.dom();return void 0!==t&&null!==t&&t.ownerDocument.body.contains(t)}},Ye=function(e,t){var n=[];return S.each(Ae.children(e),function(e){t(e)&&(n=n.concat([e])),n=n.concat(Ye(e,t))}),n},Ke={all:function(e){return Ye(Xe.body(),e)},ancestors:function(e,t,n){return S.filter(Ae.parents(e,n),t)},siblings:function(e,t){return S.filter(Ae.siblings(e),t)},children:function(e,t){return S.filter(Ae.children(e),t)},descendants:Ye},Ge={all:function(e){return Y.all(e)},ancestors:function(e,t,n){return Ke.ancestors(e,function(e){return Y.is(e,t)},n)},siblings:function(e,t){return Ke.siblings(e,function(e){return Y.is(e,t)})},children:function(e,t){return Ke.children(e,function(e){return Y.is(e,t)})},descendants:function(e,t){return Y.all(t,e)}};function Je(e,t,n,r,o){return e(n,r)?l.some(n):D.isFunction(o)&&o(n)?l.none():t(n,r,o)}var Qe=function(e,t,n){for(var r=e.dom(),i=D.isFunction(n)?n:o.constant(!1);r.parentNode;){var a=V.fromDom(r=r.parentNode);if(t(a))return l.some(a);if(i(a))break}return l.none()},Ze=function(e,t){return S.find(e.dom().childNodes,o.compose(t,V.fromDom)).map(V.fromDom)},et=function(e,t){var n=function(e){for(var r=0;r<e.childNodes.length;r++){if(t(V.fromDom(e.childNodes[r])))return l.some(V.fromDom(e.childNodes[r]));var o=n(e.childNodes[r]);if(o.isSome())return o}return l.none()};return n(e.dom())},tt={first:function(e){return et(Xe.body(),e)},ancestor:Qe,closest:function(e,t,n){return Je(function(e){return t(e)},Qe,e,t,n)},sibling:function(e,t){var n=e.dom();return n.parentNode?Ze(V.fromDom(n.parentNode),function(n){return!Ce.eq(e,n)&&t(n)}):l.none()},child:Ze,descendant:et},nt=function(e,t,n){return tt.ancestor(e,function(e){return Y.is(e,t)},n)},rt={first:function(e){return Y.one(e)},ancestor:nt,sibling:function(e,t){return tt.sibling(e,function(e){return Y.is(e,t)})},child:function(e,t){return tt.child(e,function(e){return Y.is(e,t)})},descendant:function(e,t){return Y.one(t,e)},closest:function(e,t,n){return Je(Y.is,nt,e,t,n)}},ot=function(e,t,n){var r=void 0!==n?n:o.constant(!1);return r(t)?l.none():S.contains(e,Fe.name(t))?l.some(t):rt.ancestor(t,e.join(","),function(e){return Y.is(e,"table")||r(e)})},it=function(e,t){return Ae.parent(t).map(function(t){return Ge.children(t,e)})},at=function(e,t){return ot(["td","th"],e,t)},st=function(e){return Oe.firstLayer(e,"th,td")},ut=(o.curry(it,"th,td"),function(e,t){return rt.closest(e,"table",t)}),ct=function(e){return Oe.firstLayer(e,"tr")},lt=(o.curry(it,"tr"),function(e){var t=ct(e);return S.map(t,function(e){var t=e,n=Ae.parent(t).bind(function(e){var t=Fe.name(e);return"tfoot"===t||"thead"===t||"tbody"===t?t:"tbody"}),r=S.map(st(e),function(e){var t=qe.has(e,"rowspan")?parseInt(qe.get(e,"rowspan"),10):1,n=qe.has(e,"colspan")?parseInt(qe.get(e,"colspan"),10):1;return q.detail(e,t,n)});return q.rowdata(t,r,n)})}),ft=function(e,t){return e+","+t},dt=function(e,t){var n=S.bind(e.all(),function(e){return e.cells()});return S.filter(n,t)},ht=function(e){var t={},n=[],r=e.length,i=0;S.each(e,function(e,r){var o=[];S.each(e.cells(),function(e,n){for(var a=0;void 0!==t[ft(r,a)];)a++;for(var s=q.extended(e.element(),e.rowspan(),e.colspan(),r,a),u=0;u<e.colspan();u++)for(var c=0;c<e.rowspan();
1c++){var l=a+u,f=ft(r+c,l);t[f]=s,i=Math.max(i,l+1)}o.push(s)}),n.push(q.rowdata(e.element(),o,e.section()))});var a=q.grid(r,i);return{grid:o.constant(a),access:o.constant(t),all:o.constant(n)}},pt=function(e,t,n){var r=e.access()[ft(t,n)];return void 0!==r?l.some(r):l.none()},mt=function(e,t,n){var r=dt(e,function(e){return n(t,e.element())});return r.length>0?l.some(r[0]):l.none()},gt=dt,vt=function(e){var t=S.map(e.all(),function(e){return e.cells()});return S.flatten(t)},yt={isSupported:function(e){return void 0!==e.style}},bt=function(e,t,n){if(!D.isString(n))throw console.error("Invalid call to CSS.set. Property ",t,":: Value ",n,":: Element ",e),new Error("CSS value must be a string: "+n);yt.isSupported(e)&&e.style.setProperty(t,n)},wt=function(e,t){yt.isSupported(e)&&e.style.removeProperty(t)},xt=function(e,t,n){var r=e.dom();bt(r,t,n)},Ct=function(e,t){return yt.isSupported(e)?e.style.getPropertyValue(t):""},St=function(e,t){var n=e.dom(),r=Ct(n,t);return l.from(r).filter(function(e){return e.length>0})},Tt={copy:function(e,t){var n=e.dom(),r=t.dom();yt.isSupported(n)&&yt.isSupported(r)&&(r.style.cssText=n.style.cssText)},set:xt,preserve:function(e,t){var n=qe.get(e,"style"),r=t(e);return(void 0===n?qe.remove:qe.set)(e,"style",n),r},setAll:function(e,t){var n=e.dom();_.each(t,function(e,t){bt(n,t,e)})},setOptions:function(e,t){var n=e.dom();_.each(t,function(e,t){e.fold(function(){wt(n,t)},function(e){bt(n,t,e)})})},remove:function(e,t){var n=e.dom();wt(n,t),qe.has(e,"style")&&""===qe.get(e,"style").replace(/^\s+|\s+$/g,"")&&qe.remove(e,"style")},get:function(e,t){var n=e.dom(),r=window.getComputedStyle(n).getPropertyValue(t),o=""!==r||Xe.inBody(e)?r:Ct(n,t);return null===o?void 0:o},getRaw:St,getAllRaw:function(e){var t={},n=e.dom();if(yt.isSupported(n))for(var r=0;r<n.style.length;r++){var o=n.style.item(r);t[o]=n.style[o]}return t},isValidValue:function(e,t,n){var r=V.fromTag(e);return xt(r,t,n),St(r,t).isSome()},reflow:function(e){return e.dom().offsetWidth},transfer:function(e,t,n){Fe.isElement(e)&&Fe.isElement(t)&&S.each(n,function(n){!function(e,t,n){St(e,n).each(function(e){St(t,n).isNone()&&xt(t,n,e)})}(e,t,n)})}},Et=function(e,t){Ae.parent(e).each(function(n){n.dom().insertBefore(t.dom(),e.dom())})},kt=function(e,t){e.dom().appendChild(t.dom())},Nt={before:Et,after:function(e,t){Ae.nextSibling(e).fold(function(){Ae.parent(e).each(function(e){kt(e,t)})},function(e){Et(e,t)})},prepend:function(e,t){Ae.firstChild(e).fold(function(){kt(e,t)},function(n){e.dom().insertBefore(t.dom(),n.dom())})},append:kt,appendAt:function(e,t,n){Ae.child(e,n).fold(function(){kt(e,t)},function(e){Et(e,t)})},wrap:function(e,t){Et(e,t),kt(t,e)}},Rt={before:function(e,t){S.each(t,function(t){Nt.before(e,t)})},after:function(e,t){S.each(t,function(n,r){Nt.after(0===r?e:t[r-1],n)})},prepend:function(e,t){S.each(t.slice().reverse(),function(t){Nt.prepe
1nd(e,t)})},append:function(e,t){S.each(t,function(t){Nt.append(e,t)})}},_t=function(e){var t=e.dom();null!==t.parentNode&&t.parentNode.removeChild(t)},At={empty:function(e){e.dom().textContent="",S.each(Ae.children(e),function(e){_t(e)})},remove:_t,unwrap:function(e){var t=Ae.children(e);t.length>0&&Rt.before(e,t),_t(e)}},Dt=M.immutable("minRow","minCol","maxRow","maxCol"),Ot=function(e,t){var n=e.grid().columns(),r=e.grid().rows(),o=n,i=0,a=0;return _.each(e.access(),function(e){if(t(e)){var n=e.row(),s=n+e.rowspan()-1,u=e.column(),c=u+e.colspan()-1;n<r?r=n:s>i&&(i=s),u<o?o=u:c>a&&(a=c)}}),Dt(r,o,i,a)},Pt=function(e,t,n){var r=e[n].element(),o=V.fromTag("td");Nt.append(o,V.fromTag("br")),(t?Nt.append:Nt.prepend)(r,o)},Bt=function(e,t){return V.fromDom(e.dom().cloneNode(t))},It=function(e){return Bt(e,!0)},Lt=function(e){return Bt(e,!1)},Mt=It,Ht=function(e,t){var n=function(t){return e(t)?l.from(t.dom().nodeValue):l.none()},r=be.detect().browser,o=r.isIE()&&10===r.version.major?function(e){try{return n(e)}catch(e){return l.none()}}:n;return{get:function(t){if(!e(t))throw new Error("Can only get text value of a text node");return o(t).getOr("")},getOption:o,set:function(t,n){if(!e(t))throw new Error("Can only set raw text value of a text node");t.dom().nodeValue=n}}}(Fe.isText),Ft={get:function(e){return Ht.get(e)},getOption:function(e){return Ht.getOption(e)},set:function(e,t){Ht.set(e,t)}},Wt=["img","br"],jt=function(e){return"img"===Fe.name(e)?1:Ft.getOption(e).fold(function(){return Ae.children(e).length},function(e){return e.length})},$t=function(e){return Ft.getOption(e).filter(function(e){return 0!==e.trim().length||e.indexOf("\xa0")>-1}).isSome()||S.contains(Wt,Fe.name(e))},zt=function(e){return tt.descendant(e,$t)},qt=function(e){return t=$t,(n=function(e){for(var r=Ae.children(e),o=r.length-1;o>=0;o--){var i=r[o];if(t(i))return l.some(i);var a=n(i);if(a.isSome())return a}return l.none()})(e);var t,n},Ut=function(){var e=V.fromTag("td");return Nt.append(e,V.fromTag("br")),e},Vt=function(e,t,n){var r=function(e,t){var n=function(e,t){var n=V.fromTag(t),r=qe.clone(e);return qe.setAll(n,r),n}(e,t),r=Ae.children(It(e));return Rt.append(n,r),n}(e,t);return _.each(n,function(e,t){null===e?qe.remove(r,t):qe.set(r,t,e)}),r},Xt=function(e){return e},Yt=function(e){return function(){return V.fromTag("tr",e.dom())}},Kt=function(e,t,n){return{row:Yt(t),cell:function(t){var r=Ae.owner(t.element()),o=V.fromTag(Fe.name(t.element()),r.dom()),i=n.getOr(["strong","em","b","i","span","font","h1","h2","h3","h4","h5","h6","p","div"]),a=i.length>0?function(e,t,n){return zt(e).map(function(r){var o=n.join(","),i=Ge.ancestors(r,o,function(t){return Ce.eq(t,e)});return S.foldr(i,function(e,t){var n=Lt(t);return Nt.append(e,n),n},t)}).getOr(t)}(t.element(),o,i):o;return Nt.append(a,V.fromTag("br")),Tt.copy(t.element(),o),Tt.remove(o,"height"),1!==t.colspan()&&Tt.remove(t.element(),"width"),e(t.element(),o),o},replace:Vt,gap:Ut}},Gt=function(e){return{row:Yt(e),cell:Ut,replace:Xt,gap:Ut}},Jt=["body","p","div","article","aside","figcaption","figure","footer","header","nav","section","ol","ul","li","table","thead","tbody","tfoot","caption","tr","td","th","h1","h2","h3","h4","h5","h6","blockquote","pre","address"];function Qt(){return{up:o.constant({selector:rt.ancestor,closest:rt.closest,predicate:tt.ancestor,all:Ae.parents}),down:o.constant({selector:Ge.descendants,predicate:Ke.descendants}),styles:o.constant({get:Tt.get,getRaw:Tt.getRaw,set:Tt.set,remove:Tt.remove}),attrs:o.constant({get:qe.get,set:qe.set,remove:qe.remove,copyTo:function(e,t){var n=qe.clone(e);qe.setAll(t,n)}}),insert:o.constant({before:Nt.before,after:Nt.after,afterAll:Rt.after,append:Nt.append,appendAll:Rt.append,prepend:Nt.prepend,wrap:Nt.wrap}),remove:o.constant({unwrap:At.unwrap,remove:At.remove}),create:o.constant({nu:V.fromTag,clone:function(e){return V.fromDom(e.dom().cloneNode(!1))},text:V.fromText}),query:o.constant({comparePosition:function(e,t){return e.dom().compareDocumentPosition(t.dom())},prevSibling:Ae.prevSibling,nextSibling:Ae.nextSibling}),property:o.constant({children:Ae.children,name:Fe.name,parent:Ae.parent,isText:Fe.isText,isComment:Fe.isComment,isElement:Fe.isElement,getText:Ft.get,setText:Ft.set,isBoundary:function(e){return!!Fe.isElement(e)&&("body"===Fe.name(e)||S.contains(Jt,Fe.name(e)))},isEmptyTag:function(e){return!!Fe.isElement(e)&&S.contains(["br","img","hr","
1input"],Fe.name(e))}}),eq:Ce.eq,is:Ce.is}}M.immutable("left","right");var Zt=function(e,t,n){return t.bind(function(t){return n.filter(o.curry(e.eq,t))})},en=function(e,t,n){return function(e,t,n){return n.length>0?function(e,t,n,r){return function(e,t,n,r){var o=t(e,n);return S.foldr(r,function(n,r){var o=t(e,r);return Zt(e,n,o)},o)}(e,t,n[0],n.slice(1))}(e,t,n):l.none()}(e,t,n)},tn=Qt(),nn=function(e,t){return en(tn,function(t,n){return e(n)},t)},rn=function(e,t,n){return function(e,t,n,r){return function(e,t,n,r){var i=void 0!==r?r:o.constant(!1),a=[t].concat(e.up().all(t)),s=[n].concat(e.up().all(n)),u=function(e){return S.findIndex(e,i).fold(function(){return e},function(t){return e.slice(0,t+1)})},c=u(a),l=u(s),f=S.find(c,function(t){return S.exists(l,function(e,n){return o.curry(e.eq,t)}(e))});return{firstpath:o.constant(c),secondpath:o.constant(l),shared:o.constant(f)}}(e,t,n,r)}(tn,e,t,n)},on=function(e,t){return t.column()>=e.startCol()&&t.column()+t.colspan()-1<=e.finishCol()&&t.row()>=e.startRow()&&t.row()+t.rowspan()-1<=e.finishRow()},an=function(e,t){var n=t.column(),r=t.column()+t.colspan()-1,o=t.row(),i=t.row()+t.rowspan()-1;return n<=e.finishCol()&&r>=e.startCol()&&o<=e.finishRow()&&i>=e.startRow()},sn=function(e,t,n){var r=mt(e,t,Ce.eq),o=mt(e,n,Ce.eq);return r.bind(function(e){return o.map(function(t){return n=e,r=t,q.bounds(Math.min(n.row(),r.row()),Math.min(n.column(),r.column()),Math.max(n.row()+n.rowspan()-1,r.row()+r.rowspan()-1),Math.max(n.column()+n.colspan()-1,r.column()+r.colspan()-1));var n,r})})}
1,un=sn,cn=function(e,t,n){return un(e,t,n).map(function(t){var n=gt(e,o.curry(an,t));return S.map(n,function(e){return e.element()})})},ln=function(e,t){return mt(e,t,function(e,t){return Ce.contains(t,e)}).bind(function(e){return e.element()})},fn=function(e){var t=lt(e);return ht(t)},dn=function(e,t,n,r,o){var i=fn(e),a=Ce.eq(e,n)?t:ln(i,t),s=Ce.eq(e,o)?r:ln(i,r);return cn(i,a,s)},hn=function(e,t){return rt.ancestor(e,"table")},pn=M.immutableBag(["boxes","start","finish"],[]),mn=function(e,t,n){var r=function(e){return function(t){return n(t)||Ce.eq(t,e)}};return Ce.eq(e,t)?l.some(pn({boxes:l.some([e]),start:e,finish:t})):hn(e).bind(function(o){return hn(t).bind(function(i){if(Ce.eq(o,i))return l.some(pn({boxes:(a=o,s=e,u=t,c=fn(a),cn(c,s,u)),start:e,finish:t}));var a,s,u,c;if(Ce.contains(o,i)){var f=(d=Ge.ancestors(t,"td,th",r(o))).length>0?d[d.length-1]:t;return l.some(pn({boxes:dn(o,e,o,t,i),start:e,finish:f}))}if(Ce.contains(i,o)){var d,h=(d=Ge.ancestors(e,"td,th",r(i))).length>0?d[d.length-1]:e;return l.some(pn({boxes:dn(i,e,o,t,i),start:e,finish:h}))}return rn(e,t).shared().bind(function(a){return rt.closest(a,"table",n).bind(function(n){var a=Ge.ancestors(t,"td,th",r(n)),s=a.length>0?a[a.length-1]:t,u=Ge.ancestors(e,"td,th",r(n)),c=u.length>0?u[u.length-1]:e;return l.some(pn({boxes:dn(n,e,o,t,i),start:c,finish:s}))})})})})},gn=mn,vn=function(e,t){var n=Ge.descendants(e,t);return n.length>0?l.some(n):l.none()},yn=function(e,t,n,r,i){return function(e,t){return S.find(e,function(e){return Y.is(e,t)})}(e,i).bind(function(e){return function(e,t,n){return ut(e).bind(function(r){return function(e,t,n,r){return mt(e,t,Ce.eq).bind(function(t){var o=n>0?t.row()+t.rowspan()-1:t.row(),i=r>0?t.column()+t.colspan()-1:t.column();return pt(e,o+n,i+r).map(function(e){return e.element()})})}(fn(r),e,t,n)})}(e,t,n).bind(function(e){return function(e,t){return rt.ancestor(e,"table").bind(function(n){return rt.descendant(n,t).bind(function(t){return mn(t,e).bind(function(e){return e.boxes().map(function(t){return{boxes:o.constant(t),start:o.constant(e.start()),finish:o.constant(e.finish())}})})})})}(e,r)})})},bn=function(e,t,n){return rt.descendant(e,t).bind(function(t){return rt.descendant(e,n).bind(function(e){return nn(hn,[t,e]).map(function(n){return{first:o.constant(t),last:o.constant(e),table:o.constant(n)}})})})},wn=function(e,t,n){return bn(e,t,n).bind(function(t){var n=function(t){return Ce.eq(e,t)},r=rt.ancestor(t.first(),"thead,tfoot,tbody,table",n),i=rt.ancestor(t.last(),"thead,tfoot,tbody,table",n);return r.bind(function(e){return i.bind(function(n){return Ce.eq(e,n)?(r=t.table(),i=t.first(),a=t.last(),function(e,t,n){return sn(e,t,n).bind(function(t){return function(e,t){for(var n=!0,r=o.curry(on,t),i=t.startRow();i<=t.finishRow();i++)for(var a=t.startCol();a<=t.finishCol();a++)n=n&&pt(e,i,a).exists(r);return n?l.some(t):l.none()}(e,t)})}(fn(r),i,a)):l.none();var r,i,a})})})},xn={selected:o.constant("data-mce-selected"),selectedSelector:o.constant("td[data-mce-selected],th[data-mce-selected]"),attributeSelector:o.constant("[data-mce-selected]"),firstSelected:o.constant("data-mce-first-selected"),firstSelectedSelector:o.constant("td[data-mce-first-selected],th[data-mce-first-selected]"),lastSelected:o.constant("data-mce-last-selected"),lastSelectedSelector:o.constant("td[data-mce-last-selected],th[data-mce-last-selected]")},Cn=function(e){if(!D.isArray(e))throw new Error("cases must be an array");if(0===e.length)throw new Error("there must be at least one case");var t=[],n={};return S.each(e,function(r,o){var i=_.keys(r);if(1!==i.length)throw new Error("one and only one name per case");var a=i[0],s=r[a];if(void 0!==n[a])throw new Error("duplicate key detected:"+a);if("cata"===a)throw new Error("cannot have a case named cata (sorry)");if(!D.isArray(s))throw new Error("case arguments must be an array");t.push(a),n[a]=function(){var n=arguments.length;if(n!==s.length)throw new Error("Wrong number of arguments to case "+a+". Expected "+s.length+" ("+s+"), got "+n);for(var r=new Array(n),i=0;i<r.length;i++)r[i]=arguments[i];return{fold:function(){if(arguments.length!==e.length)throw new Error("Wrong number of arguments to fold. Expected "+e.length+", got "+arguments.length);return arguments[o].apply(null,r)},match:function(e){var n=_.keys(e);if(t.length!==n.length)throw new Error("Wrong number of arguments to match. Expected: "+t.join(",")+"\nActual: "+n.join(","));if(!S.forall(t,function(e){return S.contains(n,e)}))throw new Error("Not all branches were specified when using match. Specified: "+n.join(", ")+"\nRequired: "+t.join(", "));return e[a].apply(null,r)},log:function(e){console.log(e,{constructors:t,constructor:a,params:r})}}}}),n},Sn=Cn([{none:[]},{multiple:["elements"]},{single:["selection"]}]),Tn={cata:function(e,t,n,r){return e.fold(t,n,r)},none:Sn.none,multiple:Sn.multiple,single:Sn.single},En=function(e,t){return Tn.cata(t.get(),o.constant([]),o.identity,o.constant([e]))},kn=En,Nn=function(e){return{element:o.constant(e),mergable:l.none,unmergable:l.none,selection:o.constant([e])}},Rn=M.immutable("element","clipboard","generators"),_n={noMenu:Nn,forMenu:function(e,t,n){return{element:o.constant(n),mergable:o.constant(function(e,t){return Tn.cata(t.get(),l.none,function(t,n){return 0===t.length?l.none():wn(e,xn.firstSelectedSelector(),xn.lastSelectedSelector()).bind(function(e){return t.length>1?l.some({bounds:o.constant(e),cells:o.constant(t)}):l.none()})},l.none)}(t,e)),unmergable:o.constant(function(e,t){var n=En(e,t);return n.length>0&&S.forall(n,function(e){return qe.has(e,"rowspan")&&parseInt(qe.get(e,"rowspan"),10)>1||qe.has(e,"colspan")&&parseInt(qe.get(e,"colspan"),10)>1})?l.some(n):l.none()}(n,e)),selection:o.constant(kn(n,e))}},notCell:function(e){return Nn(e)},paste:Rn,pasteRows:function(e,t,n,r,i){return{element:o.constant(n),mergable:l.none,unmergable:l.none,selection:o.constant(kn(n,e)),clipboard:o.constant(r),generators:o.constant(i)}}};function An(e,t){var n=function(n){var r=t(n);if(r<=0||null===r){var o=Tt.get(n,e);return parseFloat(o)||0}return r},r=function(e,t){return S.foldl(t,function(t,n){var r=Tt.get(e,n),o=void 0===r?0:parseInt(r,10);return isNaN(o)?t:t+o},0)};return{set:function(t,n){if(!D.isNumber(n)&&!n.match(/^[0-9]+$/))throw e+".set accepts only positive integer values. Value was "+n;var r=t.dom();yt.isSupported(r)&&(r.style[e]=n+"px")},get:n,getOuter:n,aggregate:r,max:function(e,t,n){var o=r(e,n);return t>o?t-o:0}}}var Dn=An("height",function(e){return Xe.inBody(e)?e.dom().getBoundingClientRect().height:e.dom().offsetHeight}),On=function(e){return Dn.get(e)},Pn=function(e){return Dn.getOuter(e)},Bn=An("width",function(e){return e.dom().offsetWidth}),In=function(e){return Bn.get(e)},Ln=function(e){return Bn.getOuter(e)},Mn=be.detect(),Hn=function(e,t,n){return function(e,t){var n=parseFloat(e);return isNaN(n)?t:n}(Tt.get(e,t),n)},Fn=/(\d+(\.\d+)?)(\w|%)*/,Wn=/(\d+(\.\d+)?)%/,jn=/(\d+(\.\d+)?)px|em/,$n=function(e,t){Tt.set(e,"height",t+"px")},zn=function(e){return Tt.getRaw(e,"width").fold(function(){return l.from(qe.get(e,"width"))},function(e){return l.some(e)})},qn=function(e,t){return e/t.pixelWidth()*100},Un={percentageBasedSizeRegex:o.constant(Wn),pixelBasedSizeRegex:o.constant(jn),setPixelWidth:function(e,t){Tt.set(e,"width",t+"px")},setPercentageWidth:function(e,t){Tt.set(e,"width",t+"%")},setHeight:$n,getPixelWidth:function(e,t){return zn(e).fold(function(){var t=In(e);return parseInt(t,10)},function(n){return function(e,t,n){if(jn.test(t)){var r=jn.exec(t);return parseInt(r[1],10)}if(Wn.test(t)){var o=Wn.exec(t);return function(e,t){return e/100*t.pixelWidth()}(parseFloat(o[1]),n)}var i=In(e);return parseInt(i,10)}(e,n,t)})},getPercentageWidth:function(e,t){return zn(e).fold(function(){var n=In(e),r=parseInt(n,10);return qn(r,t)},function(n){return function(e,t,n){if(Wn.test(t)){var r=Wn.exec(t);return parseFloat(r[1])}var o=In(e),i=parseInt(o,10);return qn(i,n)}(e,n,t)})},getGenericWidth:function(e){return zn(e).bind(function(e){if(Fn.test(e)){var t=Fn.exec(e);return l.some({width:o.constant(t[1]),unit:o.constant(t[3])})}return l.none()})},setGenericWidth:function(e,t,n){Tt.set(e,"width",t+n)},getHeight:function(e){return function(e,t,n){return function(e){var t=function(e){return Tt.getRaw(e,"height").getOrThunk(function(){return function(e){return Mn.browser.isIE()||Mn.browser.isEdge()?function(e){var t=Hn(e,"padding-top",0),n=Hn(e,"padding-bottom",0),r=Hn(e,"border-top-width",0),o=Hn(e,"border-bottom-width",0),i=e.dom().getBoundingClientRect().height;return"border-box"===Tt.get(e,"box-sizing")?i:i-t-n-(r+o)}(e):Hn(e,"height",On(e))}(e)+"px"})}(e);return t?function(e,t,n,r){var o=parseInt(e,10);return de(e,"%")&&"table"!==Fe.name(t)?function(e,t,n,r){var o=ut(e).map(function(e){var r=n(e);return Math.floor(t/100*r)}).getOr(t);return r(e,o),o}(t,o,n,r):o}(t,e,On,$n):On(e)}(e)/function(e,t){return qe.has(e,"rowspan")?parseInt(qe.get(e,"rowspan"),10):1}(e)}(e)},getRawWidth:zn},Vn=function(e,t){Un.getGenericWidth(e).each(function(n){var r=n.width()/2;Un.setGenericWidth(e,r,n.unit()),Un.setGenericWidth(t,r,n.unit())})}
1,Xn=function(e,t){return{left:o.constant(e),top:o.constant(t),translate:function(n,r){return Xn(e+n,t+r)}}},Yn=function(e,t){return void 0!==e?e:void 0!==t?t:0},Kn=function(e){var t=e.dom().ownerDocument,n=t.body,r=function(e){var t=e.dom();return t===t.window?e:Fe.isDocument(e)?t.defaultView||t.parentWindow:null}(V.fromDom(t)),i=t.documentElement,a=Yn(r.pageYOffset,i.scrollTop),s=Yn(r.pageXOffset,i.scrollLeft),u=Yn(i.clientTop,n.clientTop),c=Yn(i.clientLeft,n.clientLeft);return function(e){var t=e.dom(),n=t.ownerDocument,r=n.body,i=V.fromDom(n.documentElement);return r===t?Xn(r.offsetLeft,r.offsetTop):function(e,t){var n=i||V.fromDom(document.documentElement);return tt.ancestor(e,o.curry(Ce.eq,n)).isSome()}(e)?function(e){var t=e.getBoundingClientRect();return Xn(t.left,t.top)}(t):Xn(0,0)}(e).translate(s-c,a-u)},Gn=M.immutable("row","y"),Jn=M.immutable("col","x"),Qn=function(e){return Kn(e).left()+Ln(e)},Zn=function(e){return Kn(e).left()},er=function(e,t){return Jn(e,Zn(t))},tr=function(e,t){return Jn(e,Qn(t))},nr=function(e){return Kn(e).top()},rr=function(e,t,n){if(0===n.length)return[];var r=S.map(n.slice(1),function(t,n){return t.map(function(t){return e(n,t)})}),o=n[n.length-1].map(function(e){return t(n.length-1,e)});return r.concat([o])},or={delta:o.identity,positions:o.curry(rr,function(e,t){return Gn(e,nr(t))},function(e,t){return Gn(e,nr(t)+Pn(t))}),edge:nr},ir={delta:o.identity,edge:Zn,positions:o.curry(rr,er,tr)},ar={height:or,rtl:{delta:function(e,t){return-e},edge:Qn,positions:o.curry(rr,tr,er)},ltr:ir},sr={ltr:ar.ltr,rtl:ar.rtl};function ur(e){var t=function(t){return e(t).isRtl()?sr.rtl:sr.ltr};return{delta:function(e,n){return t(n).delta(e,n)},edge:function(e){return t(e).edge(e)},positions:function(e,n){return t(n).positions(e,n)}}}var cr=function(e){var t=lt(e);return ht(t).grid()},lr=function(e){var t=e,n=function(){return t};return{get:n,set:function(e){t=e},clone:function(){return lr(n())}}},fr=function(e,t){return dr(e,t,{validate:D.isFunction,label:"function"})},dr=function(e,t,n){if(0===t.length)throw new Error("You must specify at least one required field.");return I("required",t),L(t),function(r){var o=_.keys(r);S.forall(t,function(e){return S.contains(o,e)})||P(t,o),e(t,o);var i=S.filter(t,function(e){return!n.validate(r[e],e)});return i.length>0&&function(e,t){throw new Error("All values need to be of type: "+t+". Keys ("+O(e).join(", ")+") were not.")}(i,n.label),r}},hr=o.noop,pr={exactly:o.curry(fr,function(e,t){var n=S.filter(t,function(t){return!S.contains(e,t)});n.length>0&&B(n)}),ensure:o.curry(fr,hr),ensureWith:o.curry(dr,hr)},mr=function(e){var t=qe.has(e,"colspan")?parseInt(qe.get(e,"colspan"),10):1,n=qe.has(e,"rowspan")?parseInt(qe.get(e,"rowspan"),10):1;return{element:o.constant(e),colspan:o.constant(t),rowspan:o.constant(n)}},gr=pr.exactly(["cell","row","replace","gap"]),vr=function(e,t){gr(e);var n=lr(l.none()),r=void 0!==t?t:mr,o=function(t){var o=function(t){return n=r(t),e.cell(n);var n}(t);return n.get().isNone()&&n.set(l.some(o)),i=l.some({item:t,replacement:o}),o},i=l.none();return{getOrInit:function(e,t){return i.fold(function(){return o(e)},function(n){return t(e,n.item)?n.replacement:o(e)})},cursor:n.get}},yr=function(e,t){return function(n){var r=lr(l.none());gr(n);var o=[],i=function(i){var a=n.replace(i,t,{scope:e});return o.push({item:i,sub:a}),r.get().isNone()&&r.set(l.some(a)),a};return{replaceOrInit:function(e,t){return function(e,t){return S.find(o,function(n){return t(n.item,e)})}(e,t).fold(function(){return i(e)},function(n){return t(e,n.item)?n.sub:i(e)})},cursor:r.get}}},br=function(e){gr(e);var t=lr(l.none());return{combine:function(n){return t.get().isNone()&&t.set(l.some(n)),function(){var t=e.cell({element:o.constant(n),colspan:o.constant(1),rowspan:o.constant(1)});return Tt.remove(t,"width"),Tt.remove(n,"width"),t}},cursor:t.get}},wr=["body","p","div","article","aside","figcaption","figure","footer","header","nav","section","ol","ul","table","thead","tfoot","tbody","caption","tr","td","th","h1","h2","h3","h4","h5","h6","blockquote","pre","address"],xr=Qt(),Cr=function(e){return t=e,n=xr.property().name(t),S.contains(wr,n);var t,n},Sr=function(e){return t=e,n=xr.property().name(t),S.contains(["ol","ul"],n);var t,n},Tr=function(e){var t,n=function(e){return"br"===Fe.name(e)},r=function(e){return qt(e).bind(function(t){var r=Ae.nextSibling(t).map(function(e){return!!Cr(e)||(t=e,S.contains(["br","img","hr","
1input"],xr.property().name(t))?"img"!==Fe.name(e):void 0);var t}).getOr(!1);return Ae.parent(t).map(function(o){return!0===r||"li"===Fe.name(i=o)||tt.ancestor(i,Sr).isSome()||n(t)||Cr(o)&&!Ce.eq(e,o)?[]:[V.fromTag("br")];var i})}).getOr([])},o=0===(t=S.bind(e,function(e){var t=Ae.children(e);return function(e){return S.forall(e,function(e){return n(e)||Fe.isText(e)&&0===Ft.get(e).trim().length})}(t)?[]:t.concat(r(e))})).length?[V.fromTag("br")]:t;At.empty(e[0]),Rt.append(e[0],o)},Er=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)i.hasOwnProperty(a)&&(r[a]=e(r[a],i[a]))}return r}},kr=Er(function(e,t){return D.isObject(e)&&D.isObject(t)?kr(e,t):t}),Nr=Er(function(e,t){return t}),Rr={deepMerge:kr,merge:Nr},_r=function(e){for(var t=[],n=function(e){t.push(e)},r=0;r<e.length;r++)e[r].each(n);return t},Ar=function(e,t){for(var n=0;n<e.length;n++){var r=t(e[n],n);if(r.isSome())return r}return l.none()},Dr=function(e,t){return q.rowcells(t,e.section())},Or=function(e,t){return e.cells()[t]},Pr=function(e,t,n){var r=e.cells(),o=r.slice(0,t),i=r.slice(t),a=o.concat([n]).concat(i);return Dr(e,a)},Br=Dr,Ir=function(e,t,n){e.cells()[t]=n},Lr=Or,Mr=function(e,t){return Or(e,t).element()},Hr=function(e,t){var n=e.cells(),r=S.map(n,t);return q.rowcells(r,e.section())},Fr=function(e){return e.cells().length},Wr=function(e,t){if(0===e.length)return 0;var n=e[0];return S.findIndex(e,function(e){return!t(n.element(),e.element())}).fold(function(){return e.length},function(e){return e})},jr=function(e,t,n){for(var r=[],o=0;o<e.grid().rows();o++){for(var i=[],a=0;a<e.grid().columns();a++){var s=pt(e,o,a).map(function(e){return q.elementnew(e.element(),n)}).getOrThunk(function(){return q.elementnew(t.gap(),!0)});i.push(s)}var u=q.rowcells(i,e.all()[o].section());r.push(u)}return r},$r=function(e,t,n,r){n===r?qe.remove(e,t):qe.set(e,t,n)},zr=function(e,t){for(var n=[],r=e;r<t;r++)n.push(r);return n},qr=function(e,t){if(t<0||t>=e.length-1)return l.none();var n=e[t].fold(function(){var n=S.reverse(e.slice(0,t));return Ar(n,function(e,t){return e.map(function(e){return{value:e,delta:t+1}})})},function(e){return l.some({value:e,delta:0})}),r=e[t+1].fold(function(){var n=e.slice(t+1);return Ar(n,function(e,t){return e.map(function(e){return{value:e,delta:t+1}})})},function(e){return l.some({value:e,delta:1})});return n.bind(function(e){return r.map(function(t){var n=t.delta+e.delta;return Math.abs(t.value-e.value)/n})})},Ur=function(e,t,n){var r=e();return S.find(r,t).orThunk(function(){return l.from(r[0]).orThunk(n)}).map(function(e){return e.element()})},Vr=function(e){var t=e.grid(),n=zr(0,t.columns()),r=zr(0,t.rows());return S.map(n,function(t){return Ur(function(){return S.bind(r,function(n){return pt(e,n,t).filter(function(e){return e.column()===t}).fold(o.constant([]),function(e){return[e]})})},function(e){return 1===e.colspan()},function(){return pt(e,0,t)})})},Xr=function(e){var t=e.grid(),n=zr(0,t.rows()),r=zr(0,t.columns());return S.map(n,function(t){return Ur(function(){return S.bind(r,function(n){return pt(e,t,n).filter(function(e){return e.row()===t}).fold(o.constant([]),function(e){return[e]})})},function(e){return 1===e.rowspan()},function(){return pt(e,t,0)})})},Yr=function(e){var t=e.replace(/\./g,"-");return{resolve:function(e){return t+"-"+e}}},Kr={resolve:Yr("ephox-snooker").resolve},Gr=function(e,t){var n=qe.get(e,t);return void 0===n||""===n?[]:n.split(" ")},Jr=Gr,Qr=function(e){return Jr(e,"class")},Zr=function(e,t){return function(e,t,n){var r=Gr(e,"class").concat([n]);qe.set(e,"class",r.join(" "))}(e,0,t)},eo=function(e,t){return function(e,t,n){var r=S.filter(Gr(e,"class"),function(e){return e!==n});r.length>0?qe.set(e,"class",r.join(" ")):qe.remove(e,"class")}(e,0,t)},to=Qr,no=Zr,ro=eo,oo=function(e){return void 0!==e.dom().classList},io=function(e,t){return oo(e)&&e.dom().classList.contains(t)},ao={add:function(e,t){oo(e)?e.dom().classList.add(t):no(e,t)},remove:function(e,t){oo(e)?e.dom().classList.remove(t):ro(e,t),function(e){0===(oo(e)?e.dom().classList:to(e)).length&&qe.remove(e,"class")}(e)},toggle:function(e,t){return oo(e)?e.dom().classList.toggle(t):function(e,t){S.contains(Qr(e),t)?eo(e,t):Zr(e,t)}(e,t)},toggler:function(e,t){var n=oo(e),r=e.dom().classList;return function(o,i,a){var s=io(e,t)||!1,u=function(){n?r.add(t):no(e,t),s=!0},c=function(){n?r.remove(t):ro(e,t),s=!1};return{on:u,off:c,toggle:function(){(s?c:u)()},isOn:function(){return s}}}()},has:io},so=Kr.resolve("resizer-bar"),uo=Kr.resolve("resizer-rows"),co=Kr.resolve("resizer-cols"),lo=function(e){var t=Ge.descendants(e.parent(),"."+so);S.each(t,At.remove)},fo=function(e,t,n){var r=e.origin();S.each(t,function(t,o){t.each(function(t){var o=n(r,t);ao.add(o,so),Nt.append(e.parent(),o)})})},ho=function(e,t){var n=Ge.descendants(e.parent(),"."+so);S.each(n,t)},po={refresh:function(e,t,n,r){lo(e);var o=lt(t),i=ht(o);!function(e,t,n,r,o,i){var a=Kn(t);!function(e,t,n,r){fo(e,t,function(e,t){var o,i,a,s,u,c=(o=t.row(),i=n.left()-e.left(),a=t.y()-e.top(),s=r,u=V.fromTag("div"),Tt.setAll(u,{position:"absolute",left:i+"px",top:a-3.5+"px",height:"7px",width:s+"px"}),qe.setAll(u,{"data-row":o,role:"presentation"}),u);return ao.add(c,uo),c})}(e,n.length>0?o.positions(n,t):[],a,Ln(t)),function(e,t,n,r){fo(e,t,function(e,t){var o,i,a,s,u,c=(o=t.col(),i=t.x()-e.left(),a=n.top()-e.top(),s=r,u=V.fromTag("div"),Tt.setAll(u,{position:"absolute",left:i-3.5+"px",top:a+"px",height:s+"px",width:"7px"}),qe.setAll(u,{"data-column":o,role:"presentation"}),u);return ao.add(c,co),c})}(e,r.length>0?i.positions(r,t):[],a,Pn(t))}(e,t,Xr(i),Vr(i),n,r)},hide:function(e){ho(e,function(e){Tt.set(e,"display","none")})},show:function(e){ho(e,function(e){Tt.set(e,"display","block")})},destroy:lo,isRowBar:function(e){return ao.has(e,uo)},isColBar:function(e){return ao.has(e,co)}},mo=function(e,t){return function(e,t){return S.map(e,function(e){var n=function(e){return Ar(e,function(e){return Ae.parent(e.element()).map(function(e){var t=Ae.parent(e).isNone();return q.elementnew(e,t)})}).getOrThunk(function(){return q.elementnew(t.row(),!0)})}(e.details());
1return q.rowdatanew(n.element(),e.details(),e.section(),n.isNew())})}(function(e,t){var n=S.map(e,function(e,t){return S.map(e.cells(),function(e,t){return!1})});return S.map(e,function(r,i){var a=S.bind(r.cells(),function(r,a){if(!1===n[i][a]){var s=function(e,t,n,r){var i=function(e,n){return e[t]}(e).cells().slice(n),a=Wr(i,r),s=function(e,t){return S.map(e,function(e){return Lr(e,t)})}(e,n).slice(t),u=Wr(s,r);return{colspan:o.constant(a),rowspan:o.constant(u)}}(e,i,a,t);return function(e,t,r,o){for(var i=e;i<e+r;i++)for(var a=t;a<t+o;a++)n[i][a]=!0}(i,a,s.rowspan(),s.colspan()),[q.detailnew(r.element(),s.rowspan(),s.colspan(),r.isNew())]}return[]});return q.rowdetails(a,r.section())})}(e,Ce.eq),t)},go=function(e,t){var n=S.flatten(S.map(e.all(),function(e){return e.cells()}));return S.find(n,function(e){return Ce.eq(t,e.element())})},vo=function(e,t,n,r,i){return function(a,s,u,c,f){var d=lt(s),h=ht(d);return t(h,u).map(function(t){var n=function(e,t){return jr(e,t,!1)}(h,c),r=e(n,t,Ce.eq,i(c)),a=mo(r.grid(),c);return{grid:o.constant(a),cursor:r.cursor}}).fold(function(){return l.none()},function(e){var t=function(e,t){var n=[],r=[],i=function(t,o){t.length>0?function(t,o){var i=rt.child(e,o).getOrThunk(function(){var t=V.fromTag(o,Ae.owner(e).dom());return Nt.append(e,t),t});At.empty(i);var a=S.map(t,function(e){e.isNew()&&n.push(e.element());var t=e.element();return At.empty(t),S.each(e.cells(),function(e){e.isNew()&&r.push(e.element()),$r(e.element(),"colspan",e.colspan(),1),$r(e.element(),"rowspan",e.rowspan(),1),Nt.append(t,e.element())}),t});Rt.append(i,a)}(t,o):function(t){rt.child(e,t).bind(At.remove)}(o)},a=[],s=[],u=[];return S.each(t,function(e){switch(e.section()){case"thead":a.push(e);break;case"tbody":s.push(e);break;case"tfoot":u.push(e)}}),i(a,"thead"),i(s,"tbody"),i(u,"tfoot"),{newRows:o.constant(n),newCells:o.constant(r)}}(s,e.grid());return n(s,e.grid(),f),r(s),po.refresh(a,s,ar.height,f),l.some({cursor:e.cursor,newRows:t.newRows,newCells:t.newCells})})}},yo=mo,bo=function(e,t){return at(t.element()).bind(function(t){return go(e,t)})},wo=function(e,t){var n=S.map(t.selection(),function(t){return at(t).bind(function(t){return go(e,t)})}),r=_r(n);return r.length>0?l.some(r):l.none()},xo=function(e,t){var n=S.map(t.selection(),function(t){return at(t).bind(function(t){return go(e,t)})}),r=_r(n);return r.length>0?l.some(Rr.merge({cells:r},{generators:t.generators,clipboard:t.clipboard})):l.none()},Co=function(e){return{is:function(t){return e===t},isValue:o.always,isError:o.never,getOr:o.constant(e),getOrThunk:o.constant(e),getOrDie:o.constant(e),or:function(t){return Co(e)},orThunk:function(t){return Co(e)},fold:function(t,n){return n(e)},map:function(t){return Co(t(e))},each:function(t){t(e)},bind:function(t){return t(e)},exists:function(t){return t(e)},forall:function(t){return t(e)},toOption:function(){return l.some(e)}}},So=function(e){return{is:o.never,isValue:o.never,isError:o.always,getOr:o.identity,getOrThunk:function(e){return e()},getOrDie:function(){return o.die(e)()},or:function(e){return e},orThunk:function(e){return e()},fold:function(t,n){return t(e)},map:function(t){return So(e)},each:o.noop,bind:function(t){return So(e)},exists:o.never,forall:o.always,toOption:l.none}},To={value:Co,error:So},Eo=function(e,t){return S.map(e,function(){return q.elementnew(t.cell(),!0)})},ko=function(e,t,n){return S.map(e,function(e){return Br(e,e.cells().concat(Eo(zr(0,t),n)))})},No=function(e,t){var n=Fr(e[0]),r=Fr(t[0]);return{rowDelta:o.constant(0),colDelta:o.constant(n-r)}},Ro=function(e,t,n){var r=t.colDelta()<0?ko:o.identity;return(t.rowDelta()<0?function(e,t,n){return e.concat(function(t,r){for(var o=[],i=0;i<t;i++)o.push(Br(e[e.length-1],Eo(e[e.length-1].cells(),n)));return o}(t))}:o.identity)(r(e,Math.abs(t.colDelta()),n),Math.abs(t.rowDelta()),n)},_o=function(e,t,n,r){for(var o=!0,i=0;i<e.length;i++)for(var a=0;a<Fr(e[0]);a++){var s=n(Mr(e[i],a),t);!0===s&&!1===o?Ir(e[i],a,q.elementnew(r(),!0)):!0===s&&(o=!1)}return e},Ao=function(e,t,n,r){var i=Lr(e[t],n),a=o.curry(r,i.element()),s=e[t];return e.length>1&&Fr(s)>1&&(n>0&&a(Mr(s,n-1))||n<s.length-1&&a(Mr(s,n+1))||t>0&&a(Mr(e[t-1],n))||t<e.length-1&&a(Mr(e[t+1],n)))},Do=function(e,t,n,r,o){!function(e,t,n,r){if(t>0&&t<e.length){var o=function(e,t){return S.foldl(e,function(e,n){return S.exists(e,function(e){return t(e.element(),n.element
1())})?e:e.concat([n])},[])}(e[t-1].cells(),n);S.each(o,function(o){for(var i=l.none(),a=t;a<e.length;a++)for(var s=0;s<Fr(e[0]);s++){var u=e[a].cells()[s];n(u.element(),o.element())&&(i.isNone()&&(i=l.some(r())),i.each(function(t){Ir(e[a],s,q.elementnew(t,!0))}))}})}}(t,e,o,r.cell);var i=No(n,t),a=Ro(n,i,r),s=No(t,a),u=Ro(t,s,r);return u.slice(0,e).concat(a).concat(u.slice(e,u.length))},Oo=function(e,t,n,r,o){var i=e.slice(0,t),a=e.slice(t),s=Hr(e[n],function(n,i){return t>0&&t<e.length&&r(Mr(e[t-1],i),Mr(e[t],i))?Lr(e[t],i):q.elementnew(o(n.element(),r),!0)});return i.concat([s]).concat(a)},Po=function(e,t,n,r,o){return S.map(e,function(e){var i=t>0&&t<Fr(e)&&r(Mr(e,t-1),Mr(e,t))?Lr(e,t):q.elementnew(o(Mr(e,n),r),!0);return Pr(e,t,i)})},Bo=function(e,t,n,r){return S.map(e,function(e){return Hr(e,function(e){return function(e){return S.exists(t,function(t){return n(e.element(),t.element())})}(e)?q.elementnew(r(e.element(),n),!0):e})})},Io=function(e,t,n,r){return void 0!==Mr(e[t],n)&&t>0&&r(Mr(e[t-1],n),Mr(e[t],n))},Lo=function(e,t,n){return t>0&&n(Mr(e,t-1),Mr(e,t))},Mo=function(e,t,n,r){var o=S.bind(e,function(r,o){return Io(e,o,t,n)||Lo(r,t,n)?[]:[Lr(r,t)]});return Bo(e,o,n,r)},Ho=function(e,t,n,r){var o=e[t],i=S.bind(o.cells(),function(r,i){return Io(e,t,i,n)||Lo(o,i,n)?[]:[r]});return Bo(e,i,n,r)},Fo=function(e){return{fold:e}},Wo=function(){return Fo(function(e,t,n,r,o){return e()})},jo=function(e,t){return qe.has(e,t)&&parseInt(qe.get(e,t),10)>1},$o={hasColspan:function(e){return jo(e,"colspan")},hasRowspan:function(e){return jo(e,"rowspan")},minWidth:o.constant(10),minHeight:o.constant(10),getInt:function(e,t){return parseInt(Tt.get(e,t),10)}},zo=function(e,t,n){return Tt.getRaw(e,t).fold(function(){return n(e)+"px"},function(e){return e})},qo=function(e){return zo(e,"width",Un.getPixelWidth)},Uo=function(e){return zo(e,"height",Un.getHeight)},Vo=function(e,t,n,r,i){var a=Vr(e),s=S.map(a,function(e){return e.map(t.edge)});return S.map(a,function(e,t){return e.filter(o.not($o.hasColspan)).fold(function(){var e=qr(s,t);return r(e)},function(e){return n(e,i)})})},Xo=function(e){return e.map(function(e){return e+"px"}).getOr("")},Yo=function(e,t,n,r){var i=Xr(e),a=S.map(i,function(e){return e.map(t.edge)});return S.map(i,function(e,t){return e.filter(o.not($o.hasRowspan)).fold(function(){var e=qr(a,t);return r(e)},function(e){return n(e)})})},Ko={getRawWidths:function(e,t){return Vo(e,t,qo,Xo)},getPixelWidths:function(e,t,n){return Vo(e,t,Un.getPixelWidth,function(e){return e.getOrThunk(n.minCellWidth)},n)},getPercentageWidths:function(e,t,n){return Vo(e,t,Un.getPercentageWidth,function(e){return e.fold(function(){return n.minCellWidth()},function(e){return e/n.pixelWidth()*100})},n)},getPixelHeights:function(e,t){return Yo(e,t,Un.getHeight,function(e){return e.getOrThunk($o.minHeight)})},getRawHeights:function(e,t){return Yo(e,t,Uo,Xo)}},Go=function(e,t,n){for(var r=0,o=e;o<t;o++)r+=void 0!==n[o]?n[o]:0;return r},Jo=function(e,t){var n=vt(e);return S.map(n,function(e){var n=Go(e.column(),e.column()+e.colspan(),t);return{element:e.element,width:o.constant(n),colspan:e.colspan}})},Qo=function(e,t){var n=vt(e);return S.map(n,function(e){var n=Go(e.row(),e.row()+e.rowspan(),t);return{element:e.element,height:o.constant(n),rowspan:e.rowspan}})},Zo=function(e){var t=parseInt(e,10),n=o.identity;return{width:o.constant(t),pixelWidth:o.constant(t),getWidths:Ko.getPixelWidths,getCellDelta:n,singleColumnWidth:function(e,t){return[Math.max($o.minWidth(),e+t)-e]},minCellWidth:$o.minWidth,setElementWidth:Un.setPixelWidth,setTableWidth:function(e,t,n){var r=S.foldr(t,function(e,t){return e+t},0);Un.setPixelWidth(e,r)}}},ei=function(e){return Un.getRawWidth(e).fold(function(){var t=In(e);return Zo(t)},function(t){return function(e,t){if(Un.percentageBasedSizeRegex().test(t))return function(e,t){var n=parseFloat(e),r=In(t);return{width:o.constant(n),pixelWidth:o.constant(r),getWidths:Ko.getPercentageWidths,getCellDelta:function(e){return e/r*100},singleColumnWidth:function(e,t){return[100-e]},minCellWidth:function(){return $o.minWidth()/r*100},setElementWidth:Un.setPercentageWidth,setTableWidth:function(e,t,r){Un.setPercentageWidth(e,n+r)}}}(Un.percentageBasedSizeRegex().exec(t)[1],e);if(Un.pixelBasedSizeRegex().test(t)){var n=Un.pixelBasedSizeRegex().exec(t);return Zo(n[1])}var r=In(e);return Zo(r)}(e,t)})},ti=function(e){return ht(e)},ni=function(e){var t=lt(e);return ti(t)},ri={adjustWidth:function(e,t,n,r){var i=ei(e),a=i.getCellDelta(t),s=ni(e),u=i.getWidths(s,r,i),c=function(e,t,n,r){var i=e.slice(0),a=function(e,t){return 0===e.length?Wo():1===e.length?Fo(function(e,t,n,r,o){return t(0)}):0===t?Fo(function(e,t,n,r,o){return n(0,1)}):t===e.length-1?function(e,t){return Fo(function(n,r,o,i,a){return a(e,t)})}(t-1,t):t>0&&t<e.length-1?function(e,t,n){return Fo(function(r,o,i,a,s){return a(e,t,n)})}(t-1,t,t+1):Wo()}(e,t),s=function(e){return S.map(e,o.constant(0))},u=o.constant(s(i)),c=function(e,t){if(n>=0){var o=Math.max(r.minCellWidth(),i[t]-n);return s(i.slice(0,e)).concat([n,o-i[t]]).concat(s(i.slice(t+1)))}var a=Math.max(r.minCellWidth(),i[e]+n),u=i[e]-a;return s(i.slice(0,e)).concat([a-i[e],u]).concat(s(i.slice(t+1)))};return a.fold(u,function(e){return r.singleColumnWidth(i[e],n)},c,function(e,t,n){return c(t,n)},function(e,t){if(n>=0)return s(i.slice(0,t)).concat([n]);var o=Math.max(r.minCellWidth(),i[t]+n);return s(i.slice(0,t)).concat([o-i[t]])})}(u,n,a,i),l=S.map(c,function(e,t){return e+u[t]}),f=Jo(s,l);S.each(f,function(e){i.setElementWidth(e.element(),e.width())}),n===s.grid().columns()-1&&i.setTableWidth(e,l,a)},adjustHeight:function(e,t,n,r){var i=ni(e),a=Ko.getPixelHeights(i,r),s=S.map(a,function(e,r){return n===r?Math.max(t+e,$o.minHeight()):e}),u=Qo(i,s),c=function(e,t){return S.map(e.all(),function(e,n){return{element:e.element,height:o.constant(t[n])}})}(i,s);S.each(c,function(e){Un.setHeight(e.element(),e.height())}),S.each(u,function(e){Un.setHeight(e.element(),e.height())});var l=S.foldr(s,function(e,t){return e+t},0);Un.setHeight(e,l)}
1,adjustWidthTo:function(e,t,n){var r=ei(e),o=ti(t),i=r.getWidths(o,n,r),a=Jo(o,i);S.each(a,function(e){r.setElementWidth(e.element(),e.width())});var s=S.foldr(i,function(e,t){return t+e},0);a.length>0&&r.setElementWidth(e,s)}},oi=function(e){0===st(e).length&&At.remove(e)},ii=M.immutable("grid","cursor"),ai=function(e,t,n){return si(e,t,n).orThunk(function(){return si(e,0,0)})},si=function(e,t,n){return l.from(e[t]).bind(function(e){return l.from(e.cells()[n]).bind(function(e){return l.from(e.element())})})},ui=function(e,t,n){return ii(e,si(e,t,n))},ci=function(e){return S.foldl(e,function(e,t){return S.exists(e,function(e){return e.row()===t.row()})?e:e.concat([t])},[]).sort(function(e,t){return e.row()-t.row()})},li=function(e){return S.foldl(e,function(e,t){return S.exists(e,function(e){return e.column()===t.column()})?e:e.concat([t])},[]).sort(function(e,t){return e.column()-t.column()})},fi=function(e,t,n){var r=function(e,t){return S.map(e,function(e){var n=S.map(st(e),function(e){var t=qe.has(e,"rowspan")?parseInt(qe.get(e,"rowspan"),10):1,n=qe.has(e,"colspan")?parseInt(qe.get(e,"colspan"),10):1;return q.detail(e,t,n)});return q.rowdata(e,n,t.section())})}(e,n),o=ht(r);return jr(o,t,!0)}
1,di=ri.adjustWidthTo,hi={insertRowBefore:vo(function(e,t,n,r){var o=t.row(),i=t.row(),a=Oo(e,i,o,n,r.getOrInit);return ui(a,i,t.column())},bo,o.noop,o.noop,vr),insertRowsBefore:vo(function(e,t,n,r){var o=t[0].row(),i=t[0].row(),a=ci(t),s=S.foldl(a,function(e,t){return Oo(e,i,o,n,r.getOrInit)},e);return ui(s,i,t[0].column())},wo,o.noop,o.noop,vr),insertRowAfter:vo(function(e,t,n,r){var o=t.row(),i=t.row()+t.rowspan(),a=Oo(e,i,o,n,r.getOrInit);return ui(a,i,t.column())},bo,o.noop,o.noop,vr),insertRowsAfter:vo(function(e,t,n,r){var o=ci(t),i=o[o.length-1].row(),a=o[o.length-1].row()+o[o.length-1].rowspan(),s=S.foldl(o,function(e,t){return Oo(e,a,i,n,r.getOrInit)},e);return ui(s,a,t[0].column())},wo,o.noop,o.noop,vr),insertColumnBefore:vo(function(e,t,n,r){var o=t.column(),i=t.column(),a=Po(e,i,o,n,r.getOrInit);return ui(a,t.row(),i)},bo,di,o.noop,vr),insertColumnsBefore:vo(function(e,t,n,r){var o=li(t),i=o[0].column(),a=o[0].column(),s=S.foldl(o,function(e,t){return Po(e,a,i,n,r.getOrInit)},e);return ui(s,t[0].row(),a)},wo,di,o.noop,vr),insertColumnAfter:vo(function(e,t,n,r){var o=t.column(),i=t.column()+t.colspan(),a=Po(e,i,o,n,r.getOrInit);return ui(a,t.row(),i)},bo,di,o.noop,vr),insertColumnsAfter:vo(function(e,t,n,r){var o=t[t.length-1].column(),i=t[t.length-1].column()+t[t.length-1].colspan(),a=li(t),s=S.foldl(a,function(e,t){return Po(e,i,o,n,r.getOrInit)},e);return ui(s,t[0].row(),i)},wo,di,o.noop,vr),splitCellIntoColumns:vo(function(e,t,n,r){var o=function(e,t,n,r,o){var i=n+1;return S.map(e,function(e,a){var s=a===t?q.elementnew(o(Mr(e,n),r),!0):Lr(e,n);return Pr(e,i,s)})}(e,t.row(),t.column(),n,r.getOrInit);return ui(o,t.row(),t.column())},bo,di,o.noop,vr),splitCellIntoRows:vo(function(e,t,n,r){var o=function(e,t,n,r,o){var i=t+1,a=e.slice(0,i),s=e.slice(i),u=Hr(e[t],function(e,t){return t===n?q.elementnew(o(e.element(),r),!0):e});return a.concat([u]).concat(s)}(e,t.row(),t.column(),n,r.getOrInit);return ui(o,t.row(),t.column())},bo,o.noop,o.noop,vr),eraseColumns:vo(function(e,t,n,r){var o=li(t),i=function(e,t,n){var r=S.map(e,function(e){var r=e.cells().slice(0,t).concat(e.cells().slice(n+1));return q.rowcells(r,e.section())});return S.filter(r,function(e){return e.cells().length>0})}(e,o[0].column(),o[o.length-1].column()),a=ai(i,t[0].row(),t[0].column());return ii(i,a)},wo,di,oi,vr),eraseRows:vo(function(e,t,n,r){var o=ci(t),i=function(e,t,n){return e.slice(0,t).concat(e.slice(n+1))}(e,o[0].row(),o[o.length-1].row()),a=ai(i,t[0].row(),t[0].column());return ii(i,a)},wo,o.noop,oi,vr),makeColumnHeader:vo(function(e,t,n,r){var o=Mo(e,t.column(),n,r.replaceOrInit);return ui(o,t.row(),t.column())},bo,o.noop,o.noop,yr("row","th")),unmakeColumnHeader:vo(function(e,t,n,r){var o=Mo(e,t.column(),n,r.replaceOrInit);return ui(o,t.row(),t.column())},bo,o.noop,o.noop,yr(null,"td")),makeRowHeader:vo(function(e,t,n,r){var o=Ho(e,t.row(),n,r.replaceOrInit);return ui(o,t.row(),t.column())},bo,o.noop,o.noop,yr("col","th")),unmakeRowHeader:vo(function(e,t,n,r){var o=Ho(e,t.row(),n,r.replaceOrInit);return ui(o,t.row(),t.column())},bo,o.noop,o.noop,yr(null,"td")),mergeCells:vo(function(e,t,n,r){var i=t.cells();Tr(i);var a=function(e,t,n,r){if(0===e.length)return e;for(var o=t.startRow();o<=t.finishRow();o++)for(var i=t.startCol();i<=t.finishCol();i++)Ir(e[o],i,q.elementnew(r(),!1));return e}(e,t.bounds(),0,o.constant(i[0]));return ii(a,l.from(i[0]))},function(e,t){return t.mergable()},o.noop,o.noop,br),unmergeCells:vo(function(e,t,n,r){var o=S.foldr(t,function(e,t){return _o(e,t,n,r.combine(t))},e);return ii(o,l.from(t[0]))},function(e,t){return t.unmergable()},di,o.noop,br),pasteCells:vo(function(e,t,n,r){var i,a,s,u,c=(i=t.clipboard(),a=t.generators(),s=lt(i),u=ht(s),jr(u,a,!0));return function(e,t,n,r,i){return function(e,t,n){if(e.row()>=t.length||e.column()>Fr(t[0]))return To.error("invalid start address out of table bounds, row: "+e.row()+", column: "+e.column());var r=t.slice(e.row()),i=r[0].cells().slice(e.column()),a=Fr(n[0]);return To.value({rowDelta:o.constant(r.length-n.length),colDelta:o.constant(i.length-a)})}(e,t,n).map(function(o){var a=Ro(t,o,r);return function(e,t,n,r,o){for(var i=e.row(),a=e.column(),s=i+n.length,u=a+Fr(n[0]),c=i;c<s;c++)for(var l=a;l<u;l++){Ao(t,c,l,o)&&_o(t,Mr(t[c],l),o,r.cell);var f=Mr(n[c-i],l-a),d=r.replace(f);Ir(t[c],l,q.elementnew(d,!0))}return t}(e,a,n,r,i)})}(q.address(t.row(),t.column()),e,c,t.generators(),n).fold(function(){return ii(e,l.some(t.element()))},function(e){var n=ai(e,t.row(),t.column());return ii(e,n)})},function(e,t){return at(t.element()).bind(function(n){return go(e,n).map(function(e){return Rr.merge(e,{generators:t.generators,clipboard:t.clipboard})})})},di,o.noop,vr),pasteRowsBefore:vo(function(e,t,n,r){var o=e[t.cells[0].row()],i=t.cells[0].row(),a=fi(t.clipboard(),t.generators(),o),s=Do(i,e,a,t.generators(),n),u=ai(s,t.cells[0].row(),t.cells[0].column());return ii(s,u)},xo,o.noop,o.noop,vr),pasteRowsAfter:vo(function(e,t,n,r){var o=e[t.cells[0].row()],i=t.cells[t.cells.length-1].row()+t.cells[t.cells.length-1].rowspan(),a=fi(t.clipboard(),t.generators(),o),s=Do(i,e,a,t.generators(),n),u=ai(s,t.cells[0].row(),t.cells[0].column());return ii(s,u)},xo,o.noop,o.noop,vr)},pi=function(e){return V.fromDom(e.getBody())},mi={getBody:pi,getIsRoot:function(e){return function(t){return Ce.eq(t,pi(e))}},addSizeSuffix:function(e){return/^[0-9]+$/.test(e)&&(e+="px"),e},removePxSuffix:function(e){return e?e.replace(/px$/,""):""}},gi=function(e){return"rtl"===Tt.get(e,"direction")?"rtl":"ltr"},vi={isRtl:o.constant(!1)},yi={isRtl:o.constant(!0)},bi=function(e){return"rtl"===gi(e)?yi:vi},wi=["tableprops","tabledelete","|","tableinsertrowbefore","tableinsertrowafter","tabledeleterow","|","tableinsertcolbefore","tableinsertcolafter","tabledelete
1col"],xi={"border-collapse":"collapse",width:"100%"},Ci={border:"1"},Si=function(e){return e.getParam("table_default_styles",xi,"object")},Ti=function(e){return e.getParam("forced_root_block","p","string")},Ei=function(e){return e.getParam("table_cell_advtab",!0,"boolean")},ki=function(e){return e.getParam("table_row_advtab",!0,"boolean")},Ni=function(e){return e.getParam("table_advtab",!0,"boolean")},Ri=function(e){return e.getParam("table_style_by_css",!1,"boolean")},_i=function(e){return e.getParam("table_cell_class_list",[],"array")},Ai=function(e){return e.getParam("table_row_class_list",[],"array")},Di=function(e){return e.getParam("table_class_list",[],"array")},Oi=function(e){return!1===e.getParam("table_responsive_width")},Pi=function(e,t){return e.fire("newrow",{node:t})},Bi=function(e,t){return e.fire("newcell",{node:t})},Ii=tinymce.util.Tools.resolve("tinymce.util.Tools"),Li={applyAlign:function(e,t,n){n&&e.formatter.apply("align"+n,{},t)},applyVAlign:function(e,t,n){n&&e.formatter.apply("valign"+n,{},t)},unApplyAlign:function(e,t){Ii.each("left center right".split(" "),function(n){e.formatter.remove("align"+n,{},t)})},unApplyVAlign:function(e,t){Ii.each("top middle bottom".split(" "),function(n){e.formatter.remove("valign"+n,{},t)})},getTDTHOverallStyle:function(e,t,n){return function(t,r){for(var o=0;o<r.length;o++){var i=e.getStyle(r[o],n);if("undefined"==typeof t&&(t=i),t!==i)return""}return t}(void 0,e.select("td,th",t))}},Mi=function(e,t){var n=e.dom,r=t.control.rootControl,o=r.toJSON(),i=n.parseStyle(o.style);"style"===t.control.name()?(r.find("#borderStyle").value(i["border-style"]||"")[0].fire("select"),r.find("#borderColor").value(i["border-color"]||"")[0].fire("change"),r.find("#backgroundColor").value(i["background-color"]||"")[0].fire("change"),r.find("#width").value(i.width||"").fire("change"),r.find("#height").value(i.height||"").fire("change")):(i["border-style"]=o.borderStyle,i["border-color"]=o.borderColor,i["background-color"]=o.backgroundColor,i.width=o.width?mi.addSizeSuffix(o.width):"",i.height=o.height?mi.addSizeSuffix(o.height):""),r.find("#style").value(n.serializeStyle(n.parseStyle(n.serializeStyle(i))))},Hi={createStyleForm:function(e){var t=function(){var t=function(e){return e.getParam("color_picker_callback")}(e);if(t)return function(n){return t.call(e,function(e){n.control.value(e).fire("change")},n.control.value())}};return{title:"Advanced",type:"form",defaults:{onchange:o.curry(Mi,e)},items:[{label:"Style",name:"style",type:"textbox"},{type:"form",padding:0,formItemDefaults:{layout:"grid",alignH:["start","right"]},defaults:{size:7},items:[{label:"Border style",type:"listbox",name:"borderStyle",width:90,onselect:o.curry(Mi,e),values:[{text:"Select...",value:""},{text:"Solid",value:"solid"},{text:"Dotted",value:"dotted"},{text:"Dashed",value:"dashed"},{text:"Double",value:"double"},{text:"Groove",value:"groove"},{text:"Ridge",value:"ridge"},{text:"Inset",value:"inset"},{text:"Outset",value:"outset"},{text:"None",value:"none"},{text:"Hidden",value:"hidden"}]},{label:"Border color",type:"colorbox",name:"borderColor",onaction:t()},{label:"Background color",type:"colorbox",name:"backgroundColor",onaction:t()}]}]}},buildListItems:function(e,t,n){var r=function(e,n){return n=n||[],Ii.each(e,function(e){var o={text:e.text||e.title};e.menu?o.menu=r(e.menu):(o.value=e.value,t&&t(o)),n.push(o)}),n};return r(e,n||[])},updateStyleField:Mi,extractAdvancedStyles:function(e,t){var n=e.parseStyle(e.getAttrib(t,"style")),r={};return n["border-style"]&&(r.borderStyle=n["border-style"]),n["border-color"]&&(r.borderColor=n["border-color"]),n["background-color"]&&(r.backgroundColor=n["background-color"]),r.style=e.serializeStyle(n),r}},Fi=function(e,t,n){var r,o=e.dom;function i(e,t,n){n&&o.setAttrib(e,t,n)}function a(e,t,n){n&&o.setStyle(e,t,n)}Hi.updateStyleField(e,n),r=n.control.rootControl.toJSON(),e.undoManager.transact(function(){Ii.each(t,function(n){i(n,"scope",r.scope),1===t.length?i(n,"style",r.style):n.style.cssText+=";"+r.style,i(n,"class",r.class),a(n,"width",mi.addSizeSuffix(r.width)),a(n,"height",mi.addSizeSuffix(r.height)),r.type&&n.nodeName.toLowerCase()!==r.type&&(n=o.rename(n,r.type)),1===t.length&&(Li.unApplyAlign(e,n),Li.unApplyVAlign(e,n)),r.align&&Li.applyAlign(e,n,r.align),r.valign&&Li.applyVAlign(e,n,r.valign)}),e.focus()})},Wi=function(e){var t,n,r,i=[];if(i=e.dom.select("td[data-mce-selected],th[data-mce-selected]"),t=e.dom.getParent(e.selection.getStart(),"td,th"),!i.length&&t&&i.push(t),t=t||i[0]){n=i.length>1?{width:"",height:"",scope:"",class:"",align:"",style:"",type:t.nodeName.toLowerCase()}:function(e,t){var n=e.dom,r={width:n.getStyle(t,"width")||n.getAttrib(t,"width"),height:n.getStyle(t,"height")||n.getAttrib(t,"height"),scope:n.getAttrib(t,"scope"),class:n.getAttrib(t,"class")};return r.type=t.nodeName.toLowerCase(),Ii.each("left center right".split(" "),function(n){e.formatter.matchNode(t,"align"+n)&&(r.align=n)}),Ii.each("top middle bottom".split(" "),function(n){e.formatter.matchNode(t,"valign"+n)&&(r.valign=n)}),Ei(e)&&Ii.extend(r,Hi.extractAdvancedStyles(n,t)),r}(e,t),_i(e).length>0&&(r={name:"class",type:"listbox",label:"Class",values:Hi.buildListItems(_i(e),function(t){t.value&&(t.textStyle=function(){return e.formatter.getCssText({block:"td",classes:[t.value]})})})});var a={type:"form",layout:"flex",direction:"column",labelGapCalc:"children",padding:0,items:[{type:"form",layout:"grid",columns:2,labelGapCalc:!1,padding:0,defaults:{type:"textbox",maxWidth:50},items:[{label:"Width",name:"width",onchange:o.curry(Hi.updateStyleField,e)},{label:"Height",name:"height",onchange:o.curry(Hi.updateStyleField,e)},{label:"Cell type",name:"type",type:"listbox",text:"None",minWidth:90,maxWidth:null,values:[{text:"Cell",value:"td"},{text:"Header cell",value:"th"}]},{label:"Scope",name:"scope",type:"listbox",text:"None",minWidth:90,maxWidth:null,values:[{text:"None",value:""},{text:"Row",value:"row"},{text:"Column",value:"col"},{text:"Row group",value:"rowgroup"},{text:"Column group",value:"colgroup"}]},{label:"H Align",name:"align",type:"listbox",text:"None",minWidth:90,maxWidth:null,values:[{text:"None",value:""},{text:"Left",value:"left"},{text:"Center",value:"center"},{text:"Right",value:"right"}]},{label:"V Align",name:"valign",type:"listbox",text:"None",minWidth:90,maxWidth:null,values:[{text:"None",value:""},{text:"Top",value:"top"},{text:"Middle",value:"middle"},{text:"Bottom",value:"bottom"}]}]},r]};Ei(e)?e.windowManager.open({title:"Cell properties",bodyType:"tabpanel",data:n,body:[{title:"General",type:"form",items:a},Hi.createStyleForm(e)],onsubmit:o.curry(Fi,e,i)}):e.windowManager.open({title:"Cell properties",data:n,body:a,onsubmit:o.curry(Fi,e,i)})}},ji=function(e,t,n){var r=e.getParent(t,"table"),o=t.parentNode,i=e.select(n,r)[0];i||(i=e.create(n),r.firstChild?"CAPTION"===r.firstChild.nodeName?e.insertAfter(i,r.firstChild):r.insertBefore(i,r.f
1irstChild):r.appendChild(i)),i.appendChild(t),o.hasChildNodes()||e.remove(o)};function $i(e,t,n){var r,o=e.dom;function i(e,t,n){n&&o.setAttrib(e,t,n)}Hi.updateStyleField(e,n),r=n.control.rootControl.toJSON(),e.undoManager.transact(function(){Ii.each(t,function(n){var a,s;i(n,"scope",r.scope),i(n,"style",r.style),i(n,"class",r.class),a=n,(s=mi.addSizeSuffix(r.height))&&o.setStyle(a,"height",s),r.type!==n.parentNode.nodeName.toLowerCase()&&ji(e.dom,n,r.type),1===t.length&&Li.unApplyAlign(e,n),r.align&&Li.applyAlign(e,n,r.align)}),e.focus()})}var zi=function(e){var t,n,r,i,a,s,u=e.dom,c=[];t=u.getParent(e.selection.getStart(),"table"),n=u.getParent(e.selection.getStart(),"td,th"),Ii.each(t.rows,function(e){Ii.each(e.cells,function(t){if(u.getAttrib(t,"data-mce-selected")||t===n)return c.push(e),!1})}),(r=c[0])&&(a=c.length>1?{height:"",scope:"",class:"",align:"",type:r.parentNode.nodeName.toLowerCase()}:function(e,t){var n=e.dom,r={height:n.getStyle(t,"height")||n.getAttrib(t,"height"),scope:n.getAttrib(t,"scope"),class:n.getAttrib(t,"class")};return r.type=t.parentNode.nodeName.toLowerCase(),Ii.each("left center right".split(" "),function(n){e.formatter.matchNode(t,"align"+n)&&(r.align=n)}),ki(e)&&Ii.extend(r,Hi.extractAdvancedStyles(n,t)),r}(e,r),Ai(e).length>0&&(i={name:"class",type:"listbox",label:"Class",values:Hi.buildListItems(Ai(e),function(t){t.value&&(t.textStyle=function(){return e.formatter.getCssText({block:"tr",classes:[t.value]})})})}),s={type:"form",columns:2,padding:0,defaults:{type:"textbox"},items:[{type:"listbox",name:"type",label:"Row type",text:"Header",maxWidth:null,values:[{text:"Header",value:"thead"},{text:"Body",value:"tbody"},{text:"Footer",value:"tfoot"}]},{type:"listbox",name:"align",label:"Alignment",text:"None",maxWidth:null,values:[{text:"None",value:""},{text:"Left",value:"left"},{text:"Center",value:"center"},{text:"Right",value:"right"}]},{label:"Height",name:"height"},i]},ki(e)?e.windowManager.open({title:"Row properties",data:a,bodyType:"tabpanel",body:[{title:"General",type:"form",items:s},Hi.createStyleForm(e)],onsubmit:o.curry($i,e,c)}):e.windowManager.open({title:"Row properties",data:a,body:s,onsubmit:o.curry($i,e,c)}))},qi=tinymce.util.Tools.resolve("tinymce.Env"),Ui={styles:{"border-collapse":"collapse",width:"100%"},attributes:{border:"1"},percentages:!0},Vi=function(e,t){e.selection.select(t.dom(),!0),e.selection.collapse(!0)},Xi=function(e,t,n){var r,i=Si(e),a=function(e,t,n,r,o){void 0===o&&(o=Ui);var i=V.fromTag("table");Tt.setAll(i,o.styles),qe.setAll(i,o.attributes);var a=V.fromTag("tbody");Nt.append(i,a);for(var s=[],u=0;u<e;u++){for(var c=V.fromTag("tr"),l=0;l<t;l++){var f=V.fromTag(u<0||l<0?"th":"td");l<0&&qe.set(f,"scope","row"),u<0&&qe.set(f,"scope","col"),Nt.append(f,V.fromTag("br")),o.percentages&&Tt.set(f,"width",100/t+"%"),Nt.append(c,f)}s.push(c)}return Rt.append(a,s),i}(n,t,0,0,{styles:i,attributes:function(e){return e.getParam("table_default_attributes",Ci,"object")}(e),percentages:(r=i.width,D.isString(r)&&-1!==r.indexOf("%")&&!Oi(e))});qe.set(a,"data-mce-id","__mce");var s,u,c,l=(s=a,u=V.fromTag("div"),c=V.fromDom(s.dom().cloneNode(!0)),Nt.append(u,c),u.dom().innerHTML);return e.insertContent(l),rt.descendant(mi.getBody(e),'table[data-mce-id="__mce"]').map(function(t){return Oi(e)&&Tt.set(t,"width",Tt.get(t,"width")),qe.remove(t,"data-mce-id"),function(e,t){S.each(Ge.descendants(t,"tr"),function(t){Pi(e,t.dom()),S.each(Ge.descendants(t,"th,td"),function(t){Bi(e,t.dom())})})}(e,t),function(e,n){rt.descendant(t,"td,th").each(o.curry(Vi,e))}(e),t.dom()}).getOr(null)};function Yi(e,t,n,r){if("TD"===t.tagName||"TH"===t.tagName)e.setStyle(t,n,r);else if(t.children)for(var o=0;o<t.children.length;o++)Yi(e,t.children[o],n,r)}var Ki=function(e,t,n){var r,o,i=e.dom;Hi.updateStyleField(e,n),!1===(o=n.control.rootControl.toJSON()).class&&delete o.class,e.undoManager.transact(function(){t||(t=Xi(e,o.cols||1,o.rows||1)),function(e,t,n){var r=e.dom,o={},i={};if(o.class=n.class,i.height=mi.addSizeSuffix(n.height),r.getAttrib(t,"width")&&!Ri(e)?o.width=mi.removePxSuffix(n.width):i.width=mi.addSizeSuffix(n.width),Ri(e)?(i["border-width"]=mi.addSizeSuffix(n.border),i["border-spacing"]=mi.addSizeSuffix(n.cellspacing),Ii.extend(o,{"data-mce-border-color":n.borderColor,"data-mce-cell-padding":n.cellpadding,"data-mce-border":n.border})):Ii.extend(o,{border:n.border,cellpadding:n.cellpadding,cellspacing:n.cellspacing}),Ri(e)&&t.children)for(var a=0;a<t.children.length;a++)Yi(r,t.children[a],{"border-width":mi.addSizeSuffix(n.border),"border-color":n.borderColor,padding:mi.addSizeSuffix(n.cellpadding)});n.style?Ii.extend(i,r.parseStyle(n.style)):i=Ii.extend({},r.parseStyle(r.getAttrib(t,"style")),i),o.style=r.serializeStyle(i),r.setAttribs(t,o)}(e,t,o),(r=i.select("caption",t)[0])&&!o.caption&&i.remove(r),!r&&o.caption&&((r=i.create("caption")).innerHTML=qi.ie?"\xa0":'<br data-mce-bogus="1"/>',t.insertBefore(r,t.firstChild)),Li.unApplyAlign(e,t),o.align&&Li.applyAlign(e,t,o.align),e.focus(),e.addVisual()})},Gi=function(e,t){var n,r,i,a,s,u={};!0===t?(n=e.dom.getParent(e.selection.getStart(),"table"))&&(u=function(e,t){var n=e.dom,r={width:n.getStyle(t,"width")||n.getAttrib(t,"width"),height:n.getStyle(t,"height")||n.getAttrib(t,"height"),cellspacing:n.getStyle(t,"border-spacing")||n.getAttrib(t,"cellspacing"),cellpadding:n.getAttrib(t,"data-mce-cell-padding")||n.getAttrib(t,"cellpadding")||Li.getTDTHOverallStyle(e.dom,t,"padding"),border:n.getAttrib(t,"data-mce-border")||n.getAttrib(t,"border")||Li.getTDTHOverallStyle(e.dom,t,"border"),borderColor:n.getAttrib(t,"data-mce-border-color"),caption:!!n.select("caption",t)[0],class:n.getAttrib(t,"class")};return Ii.each("left center right".split(" "),function(n){e.formatter.matchNode(t,"align"+n)&&(r.align=n)}),Ni(e)&&Ii.extend(r,Hi.extractAdvancedStyles(n,t)),r}(e,n)):(r={label:"Cols",name:"cols"},i={label:"Rows",name:"rows"}),Di(e).length>0&&(u.class&&(u.class=u.class.replace(/\s*mce\-item\-table\s*/g,"")),a={name:"class",type:"listbox",label:"Class",values:Hi.buildListItems(Di(e),function(t){t.value&&(t.textStyle=function(){return e.formatter.getCssText({block:"table",classes:[t.value]})})})}),s={type:"form",layout:"flex",direction:"column",labelGapCalc:"children",padding:0,items:[{type:"form",labelGapCalc:!1,padding:0,layout:"grid",columns:2,defaults:{type:"textbox",maxWidth:50},items:function(e){return e.getParam("table_appearance_options",!0,"boolean")}(e)?[r,i,{label:"Width",name:"width",onchange:o.curry(Hi.updateStyleField,e)},{label:"Height",name:"height",onchange:o.curry(Hi.updateStyleField,e)},{label:"Cell spacing",name:"cellspacing"},{label:"Cell padding",name:"cellpadding"},{label:"Border",name:"border"},{label:"Caption",name:"caption",type:"checkbox"}]:[r,i,{label:"Width",name:"width",onchange:o.curry(Hi.updateStyleField,e)},{label:"Height",name:"height",onchange:o.curry(Hi.updateStyleField,e)}]},{label:"Alignment",name:"align",type:"listbox",text:"None",values:[{text:"None",value:""},{text:"Left",value:"left"},{text:"Center",value:"center"},{text:"Right",value:"right"}]},a]},Ni(e)?e.windowManager.open({title:"Table properties",data:u,bodyType:"tabpanel",body:[{title:"General",type:"form",items:s},Hi.createStyleForm(e)],onsubmit:o.curry(Ki,e,n)}):e.windowManager.open({title:"Table properties",data:u,body:s,onsubmit:o.curry(Ki,e,n)})},Ji=Ii.each,Qi=function(e,t,n,r,i){var a=mi.getIsRoot(e),s=function(){return V.fromDom(e.dom.getParent(e.selection.getStart(),"th,td"))},u=function(e){return ut(e,a)},c=function(t){var o=s();u(o).each(function(i){var a=_n.forMenu(r,i,o);t(i,a).each(function(t){e.selection.setRng(t),e.focus(),n.clear(i)})})},f=function(t){var n=s();return u(n).bind(function(t){var i=V.fromDom(e.getDoc());return function(e,t,n){var r=lt(e),o=ht(r);return wo(o,t).map(function(e){var t=jr(o,n,!1).slice(e[0].row(),e[e.length-1].row()+e[e.length-1].rowspan()),r=yo(t,n);return S.map(r,function(e){var t=Lt(e.element());return S.each(e.cells(),function(e){var n=Mt(e.element());
1$r(n,"colspan",e.colspan(),1),$r(n,"rowspan",e.rowspan(),1),Nt.append(t,n)}),t})})}(t,_n.forMenu(r,t,n),Kt(o.noop,i,l.none()))})},d=function(t){i.get().each(function(o){var i=S.map(o,function(e){return Mt(e)}),a=s();u(a).bind(function(o){var s=V.fromDom(e.getDoc()),u=Gt(s),c=_n.pasteRows(r,o,a,i,u);t(o,c).each(function(t){e.selection.setRng(t),e.focus(),n.clear(o)})})})};Ji({mceTableSplitCells:function(){c(t.unmergeCells)},mceTableMergeCells:function(){c(t.mergeCells)},mceTableInsertRowBefore:function(){c(t.insertRowsBefore)},mceTableInsertRowAfter:function(){c(t.insertRowsAfter)},mceTableInsertColBefore:function(){c(t.insertColumnsBefore)},mceTableInsertColAfter:function(){c(t.insertColumnsAfter)},mceTableDeleteCol:function(){c(t.deleteColumn)},mceTableDeleteRow:function(){c(t.deleteRow)},mceTableCutRow:function(e){i.set(f()),c(t.deleteRow)},mceTableCopyRow:function(e){i.set(f())},mceTablePasteRowBefore:function(e){d(t.pasteRowsBefore)},mceTablePasteRowAfter:function(e){d(t.pasteRowsAfter)},mceTableDelete:function(){var t=V.fromDom(e.dom.getParent(e.selection.getStart(),"th,td"));ut(t,a).filter(o.not(a)).each(function(t){var n=V.fromText("");Nt.after(t,n),At.remove(t);var r=e.dom.createRng();r.setStart(n.dom(),0),r.setEnd(n.dom(),0),e.selection.setRng(r)})}},function(t,n){e.addCommand(n,t)}),Ji({mceInsertTable:o.curry(Gi,e),mceTableProps:o.curry(Gi,e,!0),mceTableRowProps:o.curry(zi,e),mceTableCellProps:o.curry(Wi,e)},function(t,n){e.addCommand(n,function(e,n){t(n)})})},Zi=function(e){var t=l.from(e.dom().documentElement).map(V.fromDom).getOr(e);return{parent:o.constant(t),view:o.constant(e),origin:o.constant(Xn(0,0))}},ea=function(e,t){return{parent:o.constant(t),view:o.constant(e),origin:o.constant(Xn(0,0))}};function ta(e){var t=M.immutable.apply(null,e),n=[];return{bind:function(e){if(void 0===e)throw"Event bind error: undefined handler";n.push(e)},unbind:function(e){n=S.filter(n,function(t){return t!==e})},trigger:function(){var e=t.apply(null,arguments);S.each(n,function(t){t(e)})}}}var na={create:function(e){return{registry:_.map(e,function(e){return{bind:e.b
1ind,unbind:e.unbind}}),trigger:_.map(e,function(e){return e.trigger})}}},ra={mode:pr.exactly(["compare","extract","mutate","sink"]),sink:pr.exactly(["element","start","stop","destroy"]),api:pr.exactly(["forceDrop","drop","move","delayDrop"])},oa={resolve:Yr("ephox-dragster").resolve},ia=function(e,t,n,r,i){var a=function(e,t){return function(n){if(e(n)){var r=V.fromDom(n.target),i=function(){n.stopPropagation()},a=function(){n.preventDefault()},s=o.compose(a,i),u=function(e,t,n,r,i,a,s){return{target:o.constant(e),x:o.constant(t),y:o.constant(n),stop:r,prevent:i,kill:a,raw:o.constant(s)}}(r,n.clientX,n.clientY,i,a,s,n);t(u)}}}(n,r);return e.dom().addEventListener(t,a,i),{unbind:o.curry(aa,e,t,a,i)}},aa=function(e,t,n,r){e.dom().removeEventListener(t,n,r)},sa=o.constant(!0),ua={bind:function(e,t,n){return function(e,t,n,r){return ia(e,t,sa,r,!1)}(e,t,0,n)},capture:function(e,t,n){return function(e,t,n,r){return ia(e,t,sa,r,!0)}(e,t,0,n)}},ca=ra.mode({compare:function(e,t){return Xn(t.left()-e.left(),t.top()-e.top())},extract:function(e){return l.some(Xn(e.x(),e.y()))},sink:function(e,t){var n=function(e){var t=Rr.merge({layerClass:oa.resolve("blocker")},e),n=V.fromTag("div");return qe.set(n,"role","presentation"),Tt.setAll(n,{position:"fixed",left:"0px",top:"0px",width:"100%",height:"100%"}),ao.add(n,oa.resolve("blocker")),ao.add(n,t.layerClass),{element:function(){return n},destroy:function(){At.remove(n)}}}(t),r=ua.bind(n.element(),"mousedown",e.forceDrop),o=ua.bind(n.element(),"mouseup",e.drop),i=ua.bind(n.element(),"mousemove",e.move),a=ua.bind(n.element(),"mouseout",e.delayDrop);return ra.sink({element:n.element,start:function(e){Nt.append(e,n.element
1())},stop:function(){At.remove(n.element())},destroy:function(){n.destroy(),o.unbind(),i.unbind(),a.unbind(),r.unbind()}})},mutate:function(e,t){e.mutate(t.left(),t.top())}});var la=function(e,t,n){var r,i,a=!1,s=na.create({start:ta([]),stop:ta([])}),u=function(){var e,t,n={onEvent:function(e,t){},reset:o.noop},r=(e=l.none(),{onEvent:function(n,r){r.extract(n).each(function(n){(function(t,n){var r=e.map(function(e){return t.compare(e,n)});return e=l.some(n),r})(r,n).each(function(e){t.trigger.move(e)})})},reset:function(){e=l.none()},events:(t=na.create({move:ta(["info"])})).registry}),i=n;return{on:function(){i.reset(),i=r},off:function(){i.reset(),i=n},isOn:function(){return i===r},onEvent:function(e,t){i.onEvent(e,t)},events:r.events}}(),c=function(){h.stop(),u.isOn()&&(u.off(),s.trigger.stop())},f=(r=c,200,i=null,{cancel:function(){null!==i&&(clearTimeout(i),i=null)},throttle:function(){var e=arguments;null!==i&&clearTimeout(i),i=setTimeout(function(){r.apply(null,e),i=null,e=null},200)}});u.events.move.bind(function(n){t.mutate(e,n.info())});var d=function(e){return function(){var t=Array.prototype.slice.call(arguments,0);if(a)return e.apply(null,t)}},h=t.sink(ra.api({forceDrop:c,drop:d(c),move:d(function(e,n){f.cancel(),u.onEvent(e,t)}),delayDrop:d(f.throttle)}),n);return{element:h.element,go:function(e){h.start(e),u.on(),s.trigger.start()},on:function(){a=!0},off:function(){a=!1},destroy:function(){h.destroy()},events:s.registry}},fa={transform:function(e,t){var n=void 0!==t?t:{};return la(e,void 0!==n.mode?n.mode:ca,t)}},da={any:function(e){return rt.first(e).isSome()},ancestor:function(e,t,n){return rt.ancestor(e,t,n).isSome()},sibling:function(e,t){return rt.sibling(e,t).isSome()},child:function(e,t){return rt.child(e,t).isSome()},descendant:function(e,t){return rt.descendant(e,t).isSome()},closest:function(e,t,n){return rt.closest(e,t,n).isSome()}},ha=Kr.resolve("resizer-bar-dragging");var pa=function(e,t){return e.inline?ea(mi.getBody(e),function(){var e=V.fromTag("div");return Tt.setAll(e,{position:"static",height:"0",width:"0",padding:"0",margin:"0",border:"0"}),Nt.append(Xe.body(),e),e}()):Zi(V.fromDom(e.getDoc()))},ma=function(e,t){e.inline&&At.remove(t.parent())},ga=function(e){return{fold:e}},va=function(e){return ga(function(t,n,r,o){return t(e)})},ya=function(e,t){return ga(function(n,r,o,i){return o(e,t)})},ba=function(e,t){return ut(e,t).bind(function(t){var n=st(t);return S.findIndex(n,function(t){return Ce.eq(e,t)}).map(function(e){return{index:o.constant(e),all:o.constant(n)}})})},wa=Cn([{before:["element"]},{on:["element","offset"]},{after:["element"]}]),xa={before:wa.before,on:wa.on,after:wa.after,cata:function(e,t,n,r){return e.fold(t,n,r)},getStart:function(e){return e.fold(o.identity,o.identity,o.identity)}},Ca=Cn([{domRange:["rng"]},{relative:["startSitu","finishSitu"]},{exact:["start","soffset","finish","foffset"]}]),Sa=M.immutable("start","soffset","finish","foffset"),Ta={domRange:Ca.domRange,relative:Ca.relative,exact:Ca.exact,exactFromRange:function(e){return Ca.exact(e.start(),e.soffset(),e.finish(),e.foffset())},range:Sa,getWin:function(e){var t=function(e){return e.match({domRange:function(e){return V.fromDom(e.startContainer)},relative:function(e,t){return xa.getStart(e)},exact:function(e,t,n,r){return e}})}(e);return Ae.defaultView(t)}},Ea=function(e,t){e.selectNodeContents(t.dom())},ka=function(e){e.deleteContents()},Na=function(e){return{left:o.constant(e.left),top:o.constant(e.top),right:o.constant(e.right),bottom:o.constant(e.bottom),width:o.constant(e.width),height:o.constant(e.height)}},Ra=function(e,t){var n=e.document.createRange();return Ea(n,t),n},_a=Ea,Aa=function(e,t,n){var r,o=e.document.createRange();return r=o,t.fold(function(e){r.setStartBefore(e.dom())},function(e,t){r.setStart(e.dom(),t)},function(e){r.setStartAfter(e.dom())}),function(e,t){n.fold(function(t){e.setEndBefore(t.dom())},function(t,n){e.setEnd(t.dom(),n)},function(t){e.setEndAfter(t.dom())})}(o),o},Da=function(e,t,n,r,o){var i=e.document.createRange();return i.setStart(t.dom(),n),i.setEnd(r.dom(),o),i},Oa=ka,Pa=Cn([{ltr:["start","soffset","finish","foffset"]},{rtl:["start","soffset","finish","foffset"]}]),Ba=function(e,t,n){return t(V.fromDom(n.startContainer),n.startOffset,V.fromDom(n.endContainer),n.endOffset)},Ia=function(e,t){return function(e,t){var n=t.ltr();return n.collapsed?t.rtl().filter(function(e){return!1===e.collapsed}).map(function(e){return Pa.rtl(V.fromDom(e.endContainer),e.endOffset,V.fromDom(e.startContainer),e.startOffset)}).getOrThunk(function(){return Ba(0,Pa.ltr,n)}):Ba(0,Pa.ltr,n)}(0,function(e,t){return t.match({domRange:function(e){return{ltr:o.constant(e),rtl:l.none}},relative:function(t,n){return{ltr:Q(function(){return Aa(e,t,n)}),rtl:Q(function(){return l.some(Aa(e,n,t))})}},exact:function(t,n,r,o){return{ltr:Q(function(){return Da(e,t,n,r,o)}),rtl:Q(function(){return l.some(Da(e,r,o,t,n))})}}})}(e,t))},La=Ia,Ma=function(e,t){return Ia(e,t).match({ltr:function(t,n,r,o){var i=e.document.createRange();return i.setStart(t.dom(),n),i.setEnd(r.dom(),o),i},rtl:function(t,n,r,o){var i=e.document.createRange();return i.setStart(r.dom(),o),i.setEnd(t.dom(),n),i}})},Ha=function(e,t,n){return t>=e.left&&t<=e.right&&n>=e.top&&n<=e.bottom},Fa=function(e,t,n,r){return(Fe.isText(t)?function(e,t,n,r){var o=e.dom().createRange();o.selectNode(t.dom());var i=o.getClientRects();return Ar(i,function(e){return Ha(e,n,r)?l.some(e):l.none()}).map(function(o){return function(e,t,n,r,o){var i=function(n){var r=e.dom().createRange();return r.setStart(t.dom(),n),r.collapse(!0),r},a=Ft.get(t).length,s=function(e,t,n,r,o){if(0===o)return 0;if(t===r)return o-1;for(var a=r,s=1;s<o;s++){var u=i(s).getBoundingClientRect(),c=Math.abs(t-u.left);if(n>u.bottom);else{if(n<u.top||c>a)return s-1;a=c}}return 0}(0,n,r,o.right,a);return i(s)}(e,t,n,r,o)})}:function(e,t,n,r){var o=e.dom().createRange(),i=Ae.children(t);return Ar(i,function(t){return o.selectNode(t.dom()),Ha(o.getBoundingClientRect(),n,r)?Fa(e,t,n,r):l.none()})})(e,t,n,r)},Wa=function(e,t){return t-e.left<e.right-t},ja=function(e,t,n){var r=e.dom().createRange();return r.selectNode(t.dom()),r.collapse(n),r},$a=document.caretPositionFromPoint?function(e,t,n){return l.from(e.dom().caretPositionFromPoint(t,n)).bind(function(t){if(null===t.offsetNode)return l.none();var n=e.dom().createRange();return n.setStart(t.offsetNode,t.offset),n.collapse(),l.some(n)})}:document.caretRangeFromPoint?function(e,t,n){return l.from(e.dom().caretRangeFromPoint(t,n))}:function(e,t,n){return V.fromPoint(e,t,n).bind(function(r){var o=function(){return function(e,t,n){return(0===Ae.children(t).length?function(e,t,n){var r=t.dom().getBoundingClientRect(),o=Wa(r,n);return l.some(ja(e,t,o))}:function(e,t,n){var r=e.dom().createRange();r.selectNode(t.dom());var o=r.getBoundingClientRect(),i=Wa(o,n);return(!0===i?zt:qt)(t).map(function(t){return ja(e,t,i)})})(e,t,n)}(e,r,t)};return 0===Ae.children(r).length?o():function(e,t,n,r){var o=e.dom().createRange();o.selectNode(t.dom());var i=o.getBoundingClientRect();return function(e,t,n,r){var o=e.dom().createRange();o.selectNode(t.dom());var i=o.getBoundingClientRect(),a=Math.max(i.left,Math.min(i.right,n)),s=Math.max(i.top,Math.min(i.bottom,r));return Fa(e,t,a,s)}(e,t,Math.max(i.left,Math.min(i.right,n)),Math.max(i.top,Math.min(i.bottom,r)))}(e,r,t,n).orThunk(o)})},za=function(e,t){var n=Fe.name(e);return"input"===n?xa.after(e):S.contains(["br","img"],n)?0===t?xa.before(e):xa.after(e):xa.on(e,t)},qa=function(e,t){var n=e.fold(xa.before,za,xa.after),r=t.fold(xa.before,za,xa.after);return Ta.relative(n,r)},Ua=function(e,t,n,r){var o=za(e,t),i=za(n,r);return Ta.relative(o,i)},Va=qa,Xa=Ua,Ya=function(e,t){l.from(e.getSelection()).each(function(e){e.removeAllRanges(),e.addRange(t)}
1)},Ka=function(e,t,n,r,o){var i=Da(e,t,n,r,o);Ya(e,i)},Ga=function(e,t){return La(e,t).match({ltr:function(t,n,r,o){Ka(e,t,n,r,o)},rtl:function(t,n,r,o){var i=e.getSelection();i.extend?(i.collapse(t.dom(),n),i.extend(r.dom(),o)):Ka(e,r,o,t,n)}})},Ja=function(e){var t=e.getSelection();return t.rangeCount>0?function(e){var t,n,r,o,i,a,s=V.fromDom(e.anchorNode),u=V.fromDom(e.focusNode);return i=function(e,t,n,r){var o=Ae.owner(e).dom().createRange();return o.setStart(e.dom(),t),o.setEnd(n.dom(),r),o}(t=s,n=e.anchorOffset,r=u,o=e.focusOffset),a=Ce.eq(t,r)&&n===o,i.collapsed&&!a?l.some(Ta.range(V.fromDom(e.anchorNode),e.anchorOffset,V.fromDom(e.focusNode),e.focusOffset)):function(e){if(e.rangeCount>0){var t=e.getRangeAt(0),n=e.getRangeAt(e.rangeCount-1);return l.some(Ta.range(V.fromDom(t.startContainer),t.startOffset,V.fromDom(n.endContainer),n.endOffset))}return l.none()}(e)}(t):l.none()},Qa={setExact:function(e,t,n,r,o){var i=Xa(t,n,r,o);Ga(e,i)},getExact:Ja,get:function(e){return Ja(e).map(function(e){return Ta.exact(e.start(),e.soffset(),e.finish(),e.foffset())})},setRelative:function(e,t,n){var r=Va(t,n);Ga(e,r)},toNative:function(e){var t=Ta.getWin(e).dom(),n=function(e,n,r,o){return Da(t,e,n,r,o)},r=function(e){return e.match({domRange:function(e){var t=V.fromDom(e.startContainer),n=V.fromDom(e.endContainer);return Ua(t,e.startOffset,n,e.endOffset)},relative:qa,exact:Ua})}(e);return La(t,r).match({ltr:n,rtl:n})},setToElement:function(e,t){var n=Ra(e,t);Ya(e,n)},clear:function(e){e.getSelection().removeAllRanges()},clone:function(e,t){return function(e){var t=e.cloneContents();return V.fromDom(t)}(Ma(e,t))},replace:function(e,t,n){!function(e,t){ka(e),e.insertNode(t.dom())}(Ma(e,t),function(t,n){var r=(e.document||document).createDocumentFragment();return S.each(t,function(e){r.appendChild(e.dom())}),V.fromDom(r)}(n))},deleteAt:function(e,t){var n=Ma(e,t);Oa(n)},forElement:function(e,t){var n=Ra(e,t);return Ta.range(V.fromDom(n.startContainer),n.startOffset,V.fromDom(n.endContainer),n.endOffset)},getFirstRect:function(e,t){return function(e){var t=e.getClientRects(),n=t.length>0?t[0]:e.getBoundingClientRect();return n.width>0||n.height>0?l.some(n).map(Na):l.none()}(Ma(e,t))},getBounds:function(e,t){return function(e){var t=e.getBoundingClientRect();return t.width>0||t.height>0?l.some(t).map(Na):l.none()}(Ma(e,t))},getAtPoint:function(e,t,n){return function(e,t,n){var r=V.fromDom(e.document);return $a(r,t,n).map(function(e){return Ta.range(V.fromDom(e.startContainer),e.startOffset,V.fromDom(e.endContainer),e.endOffset)})}(e,t,n)},findWithin:function(e,t,n){return function(e,t,n){var r=Ma(e,t),o=V.fromDom(r.commonAncestorContainer);return Fe.isElement(o)?function(e,t,n,r){var o=function(e){return e.document.createRange()}(e),i=(Y.is(t,r)?[t]:[]).concat(Ge.descendants(t,r));return S.filter(i,function(e){return _a(o,e),function(e,t){return t.compareBoundaryPoints(e.END_TO_START,e)<1&&t.compareBoundaryPoints(e.START_TO_END,e)>-1}(n,o)})}(e,o,r,n):[]}(e,t,n)},getAsString:function(e,t){return function(e){return e.toString()}(Ma(e,t))},isCollapsed:function(e,t,n,r){return Ce.eq(e,n)&&t===r}},Za=tinymce.util.Tools.resolve("tinymce.util.VK"),es=function(e,t){var n=Ta.exact(t,0,t,0);return Qa.toNative(n)},ts=function(e,t,n,r,o){return n.fold(l.none,l.none,function(e,t){return zt(t).map(function(e){return es(0,e)})},function(n){return ut(n,t).bind(function(t){var o=_n.noMenu(n);return e.undoManager.transact(function(){r.insertRowsAfter(t,o)}),function(e,t){var n=Ge.descendants(t,"tr");return S.last(n).bind(function(e){return rt.descendant(e,"td,th").map(function(e){return es(0,e)})})}(0,t)})})},ns=["table","li","dl"],rs=function(e,t,n,r){if(e.keyCode===Za.TAB){var o=mi.getBody(t),i=function(e){var t=Fe.name(e);return Ce.eq(e,o)||S.contains(ns,t)},a=t.selection.getRng();if(a.collapsed){var s=V.fromDom(a.startContainer);at(s,i).each(function(o){e.preventDefault(),(e.shiftKey?function(e,t,n,r){return ts(e,t,function(e,t){return ba(e,t).fold(function(){return va()},function(t){return t.index()-1>=0?ya(e,t.all()[t.index()-1]):function(e){return ga(function(t,n,r,o){return n(e)})}(e)})}(n),r)}:function(e,t,n,r){return ts(e,t,function(e,t){return ba(e,t).fold(function(){return va(e)},function(t){return t.index()+1<t.all().length?ya(e,t.all()[t.index()+1]):function(e){return ga(function(t,n,r,o){return o(e)})}(e)})}(n),r)})(t,i,o,n,r).each(function(e){t.selection.setRng(e)})})}}},os={response:M.immutable("selection","kill")},is=function(e){return function(t){return t===e}},as=is(38),ss=is(40),us={ltr:{isBackward:is(37),isForward:is(39)},rtl:{isBackward:is(39),isForward:is(37)},isUp:as,isDown:ss,isNavigation:function(e){return e>=37&&e<=40}},cs={convertToRange:function(e,t){var n=Ma(e,t);return{start:o.constant(V.fromDom(n.startContainer)),soffset:o.constant(n.startOffset),finish:o.constant(V.fromDom(n.endContainer)),foffset:o.constant(n.endOffset)}},makeSitus:function(e,t,n,r){return{start:o.constant(xa.on(e,t)),finish:o.constant(xa.on(n,r))}}},ls=be.detect().browser.isSafari(),fs=function(e){var t=void 0!==e?e.dom():document;return Xn(t.body.scrollLeft||t.documentElement.scrollLeft,t.body.scrollTop||t.documentElement.scrollTop)},ds=function(e,t,n){(void 0!==n?n.dom():document).defaultView.scrollTo(e,t)},hs=function(e,t){ls&&D.isFunction(e.dom().scrollIntoViewIfNeeded)?e.dom().scrollIntoViewIfNeeded(!1):e.dom().scrollIntoView(t)},ps={get:fs,to:ds,by:function(e,t,n){(void 0!==n?n.dom():document).defaultView.scrollBy(e,t)},preserve:function(e,t){var n=fs(e);t();var r=fs(e);n.top()===r.top()&&n.left()===r.left()||ds(n.left(),n.top(),e)},capture:function(e){var t=l.none(),n=function(){t=l.some(fs(e))};return n(),{save:n,restore:function(){t.each(function(t){ds(t.left(),t.top(),e)})}}},intoView:hs,intoViewIfNeeded:function(e,t){var n=t.dom().getBoundingClientRect(),r=e.dom().getBoundingClientRect();r.top<n.top?hs(e,!0):r.bottom>n.bottom&&hs(e,!1)},setToElement:function(e,t){var n=Kn(t),r=V.fromDom(e.document);ds(n.left(),n.top(),r)},scrollBarWidth:function(){var e=V.fromHtml('<div style="width: 100px; height: 100px; overflow: scroll; position: absolute; top: -9999px;"></div>');Nt.after(Xe.body(),e);var t=e.dom().offsetWidth-e.dom().clientWidth;return At.remove(e),t}};function ms(e){return{elementFromPoint:function(t,n){return l.from(e.document.elementFromPoint(t,n)).map(V.fromDom)},getRect:function(e){return e.dom().getBoundingClientRect()},getRangedRect:function(t,n,r,i){var a=Ta.exact(t,n,r,i);return Qa.getFirstRect(e,a).map(function(e){return _.map(e,o.apply)})},getSelection:function(){return Qa.get(e).map(function(t){return cs.convertToRange(e,t)})},fromSitus:function(t){var n=Ta.relative(t.start(),t.finish());return cs.convertToRange(e,n)},situsFromPoint:function(t,n){return Qa.getAtPoint(e,t,n).map(function(e){return{start:o.constant(xa.on(e.start(),e.soffset()
1)),finish:o.constant(xa.on(e.finish(),e.foffset()))}})},clearSelection:function(){Qa.clear(e)},setSelection:function(t){Qa.setExact(e,t.start(),t.soffset(),t.finish(),t.foffset())},setRelativeSelection:function(t,n){Qa.setRelative(e,t,n)},selectContents:function(t){Qa.setToElement(e,t)},getInnerHeight:function(){return e.innerHeight},getScrollY:function(){return ps.get(V.fromDom(e.document)).top()},scrollBy:function(t,n){ps.by(t,n,V.fromDom(e.document))}}}var gs=function(e,t,n,r,o){if(!Ce.eq(n,r))return gn(n,r,t).bind(function(t){var r=t.boxes().getOr([]);return r.length>0?(o(e,r,t.start(),t.finish()),l.some(os.response(l.some(cs.makeSitus(n,0,n,jt(n))),!0))):l.none()})},vs=gs,ys=M.immutableBag(["left","top","right","bottom"],[]),bs={nu:ys,moveUp:function(e,t){return ys({left:e.left(),top:e.top()-t,right:e.right(),bottom:e.bottom()-t})},moveDown:function(e,t){return ys({left:e.left(),top:e.top()+t,right:e.right(),bottom:e.bottom()+t})},moveBottomTo:function(e,t){var n=e.bottom()-e.top();return ys({left:e.left(),top:t-n,right:e.right(),bottom:t})},moveTopTo:function(e,t){var n=e.bottom()-e.top();return ys({left:e.left(),top:t,right:e.right(),bottom:t+n})},getTop:function(e){return e.top()},getBottom:function(e){return e.bottom()},translate:function(e,t,n){return ys({left:e.left()+t,top:e.top()+n,right:e.right()+t,bottom:e.bottom()+n})},toString:function(e){return"("+e.left()+", "+e.top()+") -> ("+e.right()+", "+e.bottom()+")"}},ws=function(e){return bs.nu({left:e.left,top:e.top,right:e.right,bottom:e.bottom})},xs=function(e,t){return l.some(e.getRect(t))},Cs=function(e,t,n){return Fe.isElement(t)?xs(e,t).map(ws):Fe.isText(t)?function(e,t,n){return n>=0&&n<jt(t)?e.getRangedRect(t,n,t,n+1):n>0?e.getRangedRect(t,n-1,t,n):l.none()}(e,t,n).map(ws):l.none()},Ss=function(e,t){return Fe.isElement(t)?xs(e,t).map(ws):Fe.isText(t)?e.getRangedRect(t,0,t,jt(t)).map(ws):l.none()},Ts=M.immutable("item","mode"),Es=function(e,t,n,r){var o=void 0!==r?r:ks;return e.property().parent(t).map(function(e){return Ts(e,o)})},ks=function(e,t,n,r){var o=void 0!==r?r:Ns;return n.sibling(e,t).map(function(e){return Ts(e,o)})},Ns=function(e,t,n,r){var o=void 0!==r?r:Ns,i=e.property().children(t);return n.first(i).map(function(e){return Ts(e,o)})},Rs=[{current:Es,next:ks,fallback:l.none()},{current:ks,next:Ns,fallback:l.some(Es)},{current:Ns,next:Ns,fallback:l.some(ks)}],_s=function(e,t,n,r,o){return S.find(o=void 0!==o?o:Rs,function(e){return e.current===n}).bind(function(n){return n.current(e,t,r,n.next).orThunk(function(){return n.fallback.bind(function(n){return _s(e,t,n,r)})})})},As={backtrack:Es,sidestep:ks,advance:Ns,go:_s},Ds={left:function(){return{sibling:function(e,t){return e.query().prevSibling(t)},first:function(e){return e.length>0?l.some(e[e.length-1]):l.none()}}},right:function(){return{sibling:function(e,t){return e.query().nextSibling(t)},first:function(e){return e.length>0?l.some(e[0]):l.none()}}}},Os=function(e,t,n,r,o,i){return As.go(e,t,r,o).bind(function(t){return i(t.item())?l.none():n(t.item())?l.some(t.item()):Os(e,t.item(),n,t.mode(),o,i)})},Ps=function(e,t){return 0===e.property().children(t).length},Bs=function(e,t,n,r){return function(e,t,n,r){return Os(e,t,n,As.sidestep,Ds.left(),r)}(e,t,n,r)},Is=function(e,t,n,r){return function(e,t,n,r){return Os(e,t,n,As.sidestep,Ds.right(),r)}(e,t,n,r)},Ls={before:function(e,t,n){return Bs(e,t,o.curry(Ps,e),n)},after:function(e,t,n){return Is(e,t,o.curry(Ps,e),n)},seekLeft:Bs,seekRight:Is,walkers:function(){return{left:Ds.left,right:Ds.right}},walk:function(e,t,n,r,o){return As.go(e,t,n,r,o)},backtrack:As.backtrack,sidestep:As.sidestep,advance:As.advance},Ms=Qt(),Hs={gather:function(e,t,n){return Ls.gather(Ms,e,t,n)},before:function(e,t){return Ls.before(Ms,e,t)},after:function(e,t){return Ls.after(Ms,e,t)},seekLeft:function(e,t,n){return Ls.seekLeft(Ms,e,t,n)},seekRight:function(e,t,n){return Ls.seekRight(Ms,e,t,n)},walkers:function(){return Ls.walkers()},walk:function(e,t,n,r){return Ls.walk(Ms,e,t,n,r)}},Fs=Cn([{none:[]},{retry:["caret"]}]),Ws=function(e,t,n){return tt.closest(t,Cr).fold(o.constant(!1),function(t){return Ss(e,t).exists(function(e){return function(e,t){return e.left()<t.left()||Math.abs(t.right()-e.left())<1||e.left()>t.right()}(n,e)})})},js={point:bs.getBottom,adjuster:function(e,t,n,r,o){var i=bs.moveDown(o,5);return Math.abs(n.bottom()-r.bottom())<1?Fs.retry(i):n.top()>o.bottom()?Fs.retry(i):n.top()===o.bottom()?Fs.retry(bs.moveDown(o,1)):Ws(e,t,o)?Fs.retry(bs.translate(i,5,0)):Fs.none()},move:bs.moveDown,gather:Hs.after},$s=function(e,t,n,r,o){return 0===o?l.some(r):function(e,t,n){return e.elementFromPoint(t,n).filter(function(e){return"table"===Fe.name(e)}).isSome()}(e,r.left(),t.point(r))?function(e,t,n,r,o){return $s(e,t,n,t.move(r,5),o)}(e,t,n,r,o-1):e.situsFromPoint(r.left(),t.point(r)).bind(function(i){return i.start().fold(l.none,function(i,a){return Ss(e,i).bind(function(a){return t.adjuster(e,i,a,n,r).fold(l.none,function(r){return $s(e,t,n,r,o-1)})}).orThunk(function(){return l.some(r)})},l.none)})},zs=function(e,t,n){var r=e.move(n,5),o=$s(t,e,n,r,100).getOr(r);return function(e,t,n){return e.point(t)>n.getInnerHeight()?l.some(e.point(t)-n.getInnerHeight()):e.point(t)<0?l.some(-e.point(t)):l.none()}(e,o,t).fold(function(){return t.situsFromPoint(o.left(),e.point(o))},function(n){return t.scrollBy(0,n),t.situsFromPoint(o.left(),e.point(o)-n)})}
1,qs={tryUp:o.curry(zs,{point:bs.getTop,adjuster:function(e,t,n,r,o){var i=bs.moveUp(o,5);return Math.abs(n.top()-r.top())<1?Fs.retry(i):n.bottom()<o.top()?Fs.retry(i):n.bottom()===o.top()?Fs.retry(bs.moveUp(o,1)):Ws(e,t,o)?Fs.retry(bs.translate(i,5,0)):Fs.none()},move:bs.moveUp,gather:Hs.before}),tryDown:o.curry(zs,js),ieTryUp:function(e,t){return e.situsFromPoint(t.left(),t.top()-5)},ieTryDown:function(e,t){return e.situsFromPoint(t.left(),t.bottom()+5)},getJumpSize:o.constant(5)},Us=Cn([{none:["message"]},{success:[]},{failedUp:["cell"]},{failedDown:["cell"]}]),Vs=function(e){return rt.closest(e,"tr")},Xs={verify:function(e,t,n,r,o,i,a){return rt.closest(r,"td,th",a).bind(function(n){return rt.closest(t,"td,th",a).map(function(t){return Ce.eq(n,t)?Ce.eq(r,n)&&jt(n)===o?i(t):Us.none("in same cell"):nn(Vs,[n,t]).fold(function(){return function(e,n,r){var o=e.getRect(t),i=e.getRect(r);return i.right>o.left&&i.left<o.right}(e,0,n)?Us.success():i(t)},function(e){return i(t)})})}).getOr(Us.none("default"))},cata:function(e,t,n,r,o){return e.fold(t,n,r,o)},adt:Us},Ys={point:M.immutable("element","offset"),delta:M.immutable("element","deltaOffset"),range:M.immutable("element","start","finish"),points:M.immutable("begin","end"),text:M.immutable("element","text")},Ks=(M.immutable("ancestor","descendants","element","index"),M.immutable("parent","children","element","index")),Gs=function(e){return"br"===Fe.name(e)},Js=function(e,t,n){return t(e,n).bind(function(e){return Fe.isText(e)&&0===Ft.get(e).trim().length?Js(e,t,n):l.some(e)})},Qs=function(e,t,n,r){return(Gs(t)?function(e,t,n){return n.traverse(t).orThunk(function(){return Js(t,n.gather,e)}).map(n.relative)}(e,t,r):function(e,t,n,r){return function(e,t){return Ae.child(e,t).filter(Gs).orThunk(function(){return Ae.child(e,t-1).filter(Gs)})}(t,n).bind(function(t){return r.traverse(t).fold(function(){return Js(t,r.gather,e).map(r.relative)},function(e){return(t=e,Ae.parent(t).bind(function(e){var n=Ae.children(e);return function(e,t){return S.findIndex(n,o.curry(Ce.eq,t))}(0,t).map(function(r){return Ks(e,n,t,r)})})).map(function(e){return xa.on(e.parent(),e.index())});var t})})}(e,t,n,r)).map(function(e){return{start:o.constant(e),finish:o.constant(e)}})},Zs=be.detect(),eu=function(e,t,n,r,o,i){return 0===i?l.none():ru(e,t,n,r,o).bind(function(a){var s=e.fromSitus(a),u=Xs.verify(e,n,r,s.finish(),s.foffset(),o.failure,t);return Xs.cata(u,function(){return l.none()},function(){return l.some(a)},function(a){return Ce.eq(n,a)&&0===r?tu(e,n,r,bs.moveUp,o):eu(e,t,a,0,o,i-1)},function(a){return Ce.eq(n,a)&&r===jt(a)?tu(e,n,r,bs.moveDown,o):eu(e,t,a,jt(a),o,i-1)})})},tu=function(e,t,n,r,o){return Cs(e,t,n).bind(function(t){return nu(e,o,r(t,qs.getJumpSize()))})},nu=function(e,t,n){return Zs.browser.isChrome()||Zs.browser.isSafari()||Zs.browser.isFirefox()||Zs.browser.isEdge()?t.otherRetry(e,n):Zs.browser.isIE()?t.ieRetry(e,n):l.none()},ru=function(e,t,n,r,o){return Cs(e,n,r).bind(function(t){return nu(e,o,t)})},ou=be.detect(),iu=function(e,t,n,r,i){return rt.closest(r,"td,th",t).bind(function(r){return rt.closest(r,"table",t).bind(function(a){return function(e,t){return tt.ancestor(i,function(e){return Ae.parent(e).exists(function(e){return Ce.eq(e,t)})},void 0).isSome()}(0,a)?function(e,t,n){return function(e,t,n){return e.getSelection().bind(function(r){return Qs(t,r.finish(),r.foffset(),n).fold(function(){return l.some(Ys.point(r.finish(),r.foffset()))},function(o){var i,a=e.fromSitus(o);return i=Xs.verify(e,r.finish(),r.foffset(),a.finish(),a.foffset(),n.failure,t),Xs.cata(i,function(e){return l.none()},function(){return l.none()},function(e){return l.some(Ys.point(e,0))},function(e){return l.some(Ys.point(e,jt(e)))})})})}(e,t,n).bind(function(r){return eu(e,t,r.element(),r.offset(),n,20).map(e.fromSitus)})}(e,t,n).bind(function(e){return rt.closest(e.finish(),"td,th",t).map(function(t){return{start:o.constant(r),finish:o.constant(t),range:o.constant(e)}})}):l.none()})})},au=function(e,t,n,r,o,i){return ou.browser.isIE()?l.none():i(r,t).orThunk(function(){return iu(e,t,n,r,o).map(function(e){var t=e.range();return os.response(l.some(cs.makeSitus(t.start(),t.soffset(),t.finish(),t.foffset())),!0)})})},su=function(e,t,n,r,o,i,a){return iu(e,n,r,o,i).bind(function(e){return vs(t,n,e.start(),e.finish(),a)})},uu=function(e,t){return rt.closest(e,"tr",t).bind(function(e){return rt.closest(e,"table",t).bind(function(n){var r=Ge.descendants(n,"tr");return Ce.eq(e,r[0])?Hs.seekLeft(n,function(e){return qt(e).isSome()},t).map(function(e){var t=jt(e);return os.response(l.some(cs.makeSitus(e,t,e,t)),!0)}):l.none()})})},cu=function(e,t){return rt.closest(e,"tr",t).bind(function(e){return rt.closest(e,"table",t).bind(function(n){var r=Ge.descendants(n,"tr");return Ce.eq(e,r[r.length-1])?Hs.seekRight(n,function(e){return zt(e).isSome()},t).map(function(e){return os.response(l.some(cs.makeSitus(e,0,e,0)),!0)}):l.none()})})},lu=function(e,t){return rt.closest(e,"td,th",t)},fu={down:{traverse:Ae.nextSibling,gather:Hs.after,relative:xa.before,otherRetry:qs.tryDown,ieRetry:qs.ieTryDown,failure:Xs.adt.failedDown},up:{traverse:Ae.prevSibling,gather:Hs.before,relative:xa.before,otherRetry:qs.tryUp,ieRetry:qs.ieTryUp,failure:Xs.adt.failedUp}},du=M.immutable("rows","cols"),hu=function(e,t,n,r){var o=function(e,t,n,r){var o=l.none(),i=function(){o=l.none()};return{mousedown:function(e){r.clear(t),o=lu(e.target(),n)},mouseover:function(i){o.each(function(o){r.clear(t),lu(i.target(),n).each(function(i){gn(o,i,n).each(function(n){var a=n.boxes().getOr([]);(a.length>1||1===a.length&&!Ce.eq(o,i))&&(r.selectRange(t,a,n.start(),n.finish()),e.selectContents(i))})})})},mouseup:function(){o.each(i)}}}(ms(e),t,n,r);return{mousedown:o.mousedown,mouseover:o.mouseover,mouseup:o.mouseup}},pu=function(e,t,n,r){var i=ms(e),a=function(){return r.clear(t),l.none()};return{keydown:function(e,s,u,c,f,d){var h=e.raw().which,p=!0===e.raw().shiftKey;return vn(t,r.selectedSelector()).fold(function(){return us.isDown(h)&&p?o.curry(su,i,t,n,fu.down,c,s,r.selectRange):us.isUp(h)&&p?o.curry(su,i,t,n,fu.up,c,s,r.selectRange):us.isDown(h)?o.curry(au,i,n,fu.down,c,s,cu):us.isUp(h)?o.curry(au,i,n,fu.up,c,s,uu):l.none},function(e){var n=function(n){return function(){return Ar(n,function(n){return function(e,t,n,r,o){return yn(r,e,t,o.firstSelectedSelector(),o.lastSelectedSelector()).map(function(e){return o.clear(n),o.selectRange(n,e.boxes(),e.start(),e.finish()),e.boxes()})}(n.rows(),n.cols(),t,e,r)}).fold(function(){return bn(t,r.firstSelectedSelector(),r.lastSelectedSelector()).map(function(e){var n=us.isDown(h)||d.isForward(h)?xa.after:x
1a.before;return i.setRelativeSelection(xa.on(e.first(),0),n(e.table())),r.clear(t),os.response(l.none(),!0)})},function(e){return l.some(os.response(l.none(),!0))})}};return us.isDown(h)&&p?n([du(1,0)]):us.isUp(h)&&p?n([du(-1,0)]):d.isBackward(h)&&p?n([du(0,-1),du(-1,0)]):d.isForward(h)&&p?n([du(0,1),du(1,0)]):us.isNavigation(h)&&!1===p?a:l.none})()},keyup:function(e,o,i,a,s){return vn(t,r.selectedSelector()).fold(function(){var u=e.raw().which;return 0==(!0===e.raw().shiftKey)?l.none():us.isNavigation(u)?function(e,t,n,r,o,i,a){return Ce.eq(n,o)&&r===i?l.none():rt.closest(n,"td,th",t).bind(function(n){return rt.closest(o,"td,th",t).bind(function(r){return gs(e,t,n,r,a)})})}(t,n,o,i,a,s,r.selectRange):l.none()},l.none)}}},mu=function(e){var t=function(t){qe.remove(t,e.selected()),qe.remove(t,e.firstSelected()),qe.remove(t,e.lastSelected())},n=function(t){qe.set(t,e.selected(),"1")},r=function(n){var r=Ge.descendants(n,e.selectedSelector());S.each(r,t)};return{clear:r,selectRange:function(t,o,i,a){r(t),S.each(o,n),qe.set(i,e.firstSelected(),"1"),qe.set(a,e.lastSelected(),"1")},selectedSelector:e.selectedSelector,firstSelectedSelector:e.firstSelectedSelector,lastSelectedSelector:e.lastSelectedSelector}},gu=Ii.each;n.add("table",function(e){var t=function(e){var t,n,r=l.none(),i=l.none(),a=l.none(),s=/(\d+(\.\d+)?)%/,u=function(e){return"TABLE"===e.nodeName};return e.on("init",function(){var t=ur(bi),n=pa(e);if(a=l.some(n),function(e){var t=e.getParam("object_resizing",!0);return"table"===t||t}(e)&&function(e){return e.getParam("table_resize_bars",!0,"boolean")}(e)){var s=function(e,t){var n=ar.height,r=function(e,t,n){var r=function(){var e=na.create({drag:ta(["xDelta","yDelta","target"])}),t=l.none(),n=function(){var e=na.create({drag:ta(["xDelta","yDelta"])});return{mutate:function(t,n){e.trigger.drag(t,n)},events:e.registry}}();return n.events.drag.bind(function(n){t.each(function(t){e.trigger.drag(n.xDelta(),n.yDelta(),t)})}),{assign:function(e){t=l.some(e)},get:function(){return t},mutate:n.mutate,events:e.registry}}(),i=fa.transform(r,{}),a=l.none(),s=function(e,t){return l.from(qe.get(e,t))};r.events.drag.bind(function(e){s(e.target(),"data-row").each(function(t){var n=$o.getInt(e.target(),"top");Tt.set(e.target(),"top",n+e.yDelta()+"px")}),s(e.target(),"data-column").each(function(t){var n=$o.getInt(e.target(),"left");Tt.set(e.target(),"left",n+e.xDelta()+"px")})});var u=function(e,t){return $o.getInt(e,t)-parseInt(qe.get(e,"data-initial-"+t),10)};i.events.stop.bind(function(){r.get().each(function(r){a.each(function(o){s(r,"data-row").each(function(e){var t=u(r,"top");qe.remove(r,"data-initial-top"),p.trigger.adjustHeight(o,t,parseInt(e,10))}),s(r,"data-column").each(function(e){var t=u(r,"left");qe.remove(r,"data-initial-left"),p.trigger.adjustWidth(o,t,parseInt(e,10))}),po.refresh(e,o,n,t)})})});var c=function(t,n){p.trigger.startAdjust(),r.assign(t),qe.set(t,"data-initial-"+n,parseInt(Tt.get(t,n),10)),ao.add(t,ha),Tt.set(t,"opacity","0.2"),i.go(e.parent())},f=ua.bind(e.parent(),"mousedown",function(e){po.isRowBar(e.target())&&c(e.target(),"top"),po.isColBar(e.target())&&c(e.target(),"left")}),d=function(t){return Ce.eq(t,e.view())},h=ua.bind(e.view(),"mouseover",function(r){"table"===Fe.name(r.target())||da.ancestor(r.target(),"table",d)?(a="table"===Fe.name(r.target())?l.some(r.target()):rt.ancestor(r.target(),"table",d)).each(function(r){po.refresh(e,r,n,t)}):Xe.inBody(r.target())&&po.destroy(e)}),p=na.create({adjustHeight:ta(["table","delta","row"]),adjustWidth:ta(["table","delta","column"]),startAdjust:ta([])});return{destroy:function(){f.unbind(),h.unbind(),i.destroy(),po.destroy(e)},refresh:function(r){po.refresh(e,r,n,t)},on:i.on,off:i.off,hideBars:o.curry(po.hide,e),showBars:o.curry(po.show,e),events:p.registry}}(e,t,n),i=na.create({beforeResize:ta(["table"]),afterResize:ta(["table"]),startDrag:ta([])});return r.events.adjustHeight.bind(function(e){i.trigger.beforeResize(e.table());var t=n.delta(e.delta(),e.table());ri.adjustHeight(e.table(),t,e.row(),n),i.trigger.afterResize(e.table())}),r.events.startAdjust.bind(function(e){i.trigger.startDrag()}
1),r.events.adjustWidth.bind(function(e){i.trigger.beforeResize(e.table());var n=t.delta(e.delta(),e.table());ri.adjustWidth(e.table(),n,e.column(),t),i.trigger.afterResize(e.table())}),{on:r.on,off:r.off,hideBars:r.hideBars,showBars:r.showBars,destroy:r.destroy,events:i.registry}}(n,t);s.on(),s.events.startDrag.bind(function(t){r=l.some(e.selection.getRng())}),s.events.afterResize.bind(function(t){var n=t.table(),o=Ge.descendants(n,"td[data-mce-style],th[data-mce-style]");S.each(o,function(e){qe.remove(e,"data-mce-style")}),r.each(function(t){e.selection.setRng(t),e.focus()}),e.undoManager.add()}),i=l.some(s)}}),e.on("ObjectResizeStart",function(r){var o;u(r.target)&&(t=r.width,n=e.dom.getStyle(o=r.target,"width")||e.dom.getAttrib(o,"width"))}),e.on("ObjectResized",function(r){if(u(r.target)){var o=r.target;if(s.test(n)){var i=parseFloat(s.exec(n)[1]);e.dom.setStyle(o,"width",r.width*i/t+"%")}else{var a=[];Ii.each(o.rows,function(t){Ii.each(t.cells,function(t){var n=e.dom.getStyle(t,"width",!0);a.push({cell:t,width:n})})}),Ii.each(a,function(t){e.dom.setStyle(t.cell,"width",t.width),e.dom.setAttrib(t.cell,"width",null)})}}}),{lazyResize:function(){return i},lazyWire:function(){return a.getOr(Zi(V.fromDom(e.getBody())))},destroy:function(){i.each(function(e){e.destroy()}),a.each(function(t){ma(e,t)})}}}(e),n=function(e,t){var n=M.immutableBag(["mousedown","mouseover","mouseup","keyup","keydown"],[]),r=l.none(),i=mu(xn);return e.on("init",function(a){var s=e.getWin(),u=mi.getBody(e),c=mi.getIsRoot(e),f=hu(s,u,c,i),d=pu(s,u,c,i),h=function(t,n){(function(e){return!0===e.raw().shiftKey})(t)&&(n.kill()&&t.kill(),n.selection().each(function(t){var n=Ta.relative(t.start(),t.finish()),r=Ma(s,n);e.selection.setRng(r)}))},p=function(t){var n=v(t);if(n.raw().shiftKey&&us.isNavigation(n.raw().which)){var r=e.selection.getRng(),o=V.fromDom(r.startContainer),i=V.fromDom(r.endContainer);d.keyup(n,o,r.startOffset,i,r.endOffset).each(function(e){h(n,e)})}},m=function(e){return!(qe.has(e,"data-mce-bogus")||"br"===Fe.name(e)||Fe.isText(e)&&0===Ft.get(e).length)},g=function(n){var r,o,i=v(n);t().each(function(e){e.hideBars()}),40===n.which&&(r=V.fromDom(e.getBody()),o=function(e){return Ae.prevSibling(e).bind(function(e){return m(e)?l.some(e):o(e)})},Ae.lastChild(r).bind(function(e){return m(e)?l.some(e):o(e)})).each(function(t){"table"===Fe.name(t)&&(Ti(e)?e.dom.add(e.getBody(),Ti(e),function(e){return e.getParam("forced_block_attrs",{},"object")}(e),"<br/>"):e.dom.add(e.getBody(),"br"))});var a=e.selection.getRng(),s=V.fromDom(e.selection.getStart()),u=V.fromDom(a.startContainer),c=V.fromDom(a.endContainer),f=bi(s).isRtl()?us.rtl:us.ltr;d.keydown(i,u,a.startOffset,c,a.endOffset,f).each(function(e){h(i,e)}),t().each(function(e){e.showBars()})},v=function(e){var t=V.fromDom(e.target),n=function(){e.stopPropagation()},r=function(){e.preventDefault()},i=o.compose(r,n);return{target:o.constant(t),x:o.constant(e.x),y:o.constant(e.y),stop:n,prevent:r,kill:i,raw:o.constant(e)}},y=function(e){return 0===e.button},b=function(e){y(e)&&f.mousedown(v(e))},w=function(e){var t;(void 0===(t=e).buttons||0!=(1&t.buttons))&&f.mouseover(v(e))},x=function(e){y&&f.mouseup(v(e))};e.on("mousedown",b),e.on("mouseover",w),e.on("mouseup",x),e.on("keyup",p),e.on("keydown",g),e.on("nodechange",function(){var t=e.selection,n=V.fromDom(t.getStart()),r=V.fromDom(t.getEnd()),a=ut(n),s=ut(r);a.bind(function(e){return s.bind(function(t){return Ce.eq(e,t)?l.some(!0):l.none()})}).fold(function(){i.clear(u)},o.noop)}),r=l.some(n({mousedown:b,mouseover:w,mouseup:x,keyup:p,keydown:g}))}),{clear:i.clear,destroy:function(){r.each(function(e){})}}}(e,t.lazyResize),r=function(e,t){var n=function(e){return"table"===Fe.name(mi.getBody(e))},r=function(e){var t=e.getParam("table_clone_elements");return D.isString(t)?l.some(t.split(/[ ,]/)):Array.isArray(t)?l.some(t):l.none()}(e),i=function(t,n,o,i){return function(a,s){var u=Ge.descendants(a,"td[data-mce-style],th[data-mce-style]");S.each(u,function(e){qe.remove(e,"data-mce-style")});var c=i(),f=V.fromDom(e.getDoc()),d=ur(bi),h=Kt(o,f,r);return n(a)?t(c,a,s,h,d).bind(function(t){return S.each(t.newRows(),function(t){Pi(e,t.dom())}),S.each(t.newCells(),function(t){Bi(e,t.dom())}),t.cursor().map(function(t){var n=e.dom.createRng();return n.setStart(t.dom(),0),n.setEnd(t.dom(),0),n})}):l.none()}};return{deleteRow:i(hi.eraseRows,function(t){var r=cr(t);return!1===n(e)||r.rows()>1},o.noop,t),deleteColumn:i(hi.eraseColumns,function(t){var r=cr(t);return!1===n(e)||r.columns()>1},o.noop,t),insertRowsBefore:i(hi.insertRowsBefore,o.always,o.noop,t),insertRowsAfter:i(hi.insertRowsAfter,o.always,o.noop,t),insertColumnsBefore:i(hi.insertColumnsBefore,o.always,Vn,t),insertColumnsAfter:i(hi.insertColumnsAfter,o.always,Vn,t),mergeCells:i(hi.mergeCells,o.always,o.noop,t),unmergeCells:i(hi.unmergeCells,o.always,o.noop,t),pasteRowsBefore:i(hi.pasteRowsBefore,o.always,o.noop,t),pasteRowsAfter:i(hi.pasteRowsAfter,o.always,o.noop,t),pasteCells:i(hi.pasteCells,o.always,o.noop,t)}}(e,t.lazyWire),i=function(e){return{get:function(){var t,n,r=mi.getBody(e);return(t=r,n=xn.selectedSelector(),vn(t,n)).fold(function(){return void 0===e.selection.getStart()?Tn.none():Tn.single(e.selection)},function(e){return Tn.multiple(e)})}}}(e),a=lr(l.none());return Qi(e,r,n,i,a),function(e,t,n,r){e.on("BeforeGetContent",function(n){!0===n.selection&&Tn.cata(t.get(),o.noop,function(t){n.preventDefault(),function(e){return ut(e[0]).map(Mt).map(function(e){return[(t=e,n=xn.attributeSelector(),r=function(e){return Y.is(e.element(),n)},o=lt(t),i=ht(o),a=Ot(i,r),s="th:not("+n+"),td:not("+n+")",u=Oe.filterFirstLayer(t,"th,td",function(e){return Y.is(e,s)}),S.each(u,At.remove),function(e,t,n,r){for(var o=t.grid().columns(),i=t.grid().rows(),a=0;a<i;a++)for(var s=!1,u=0;u<o;u++)a<n.minRow()||a>n.maxRow()||u<n.minCol()||u>
1n.maxCol()||(pt(t,a,u).filter(r).isNone()?Pt(e,s,a):s=!0)}(o,i,a,r),function(e,t){var n=S.filter(Oe.firstLayer(e,"tr"),function(e){return 0===e.dom().childElementCount});S.each(n,At.remove),t.minCol()!==t.maxCol()&&t.minRow()!==t.maxRow()||S.each(Oe.firstLayer(e,"th,td"),function(e){qe.remove(e,"rowspan"),qe.remove(e,"colspan")}),qe.remove(e,"width"),qe.remove(e,"height"),Tt.remove(e,"width"),Tt.remove(e,"height")}(t,a),t)];var t,n,r,o,i,a,s,u})}(t).each(function(t){n.content=S.map(t,function(t){return function(e,t){return e.selection.serializer.serialize(t.dom(),{})}(e,t)}).join("")})},o.noop)}),e.on("BeforeSetContent",function(t){!0===t.selection&&!0===t.paste&&l.from(e.dom.getParent(e.selection.getStart(),"th,td")).each(function(o){var i=V.fromDom(o);ut(i).bind(function(o){var a,s,u=S.filter((a=t.content,(s=document.createElement("div")).innerHTML=a,Ae.children(V.fromDom(s))),function(e){return"meta"!==Fe.name(e)});if(1===u.length&&"table"===Fe.name(u[0])){t.preventDefault();var c=V.fromDom(e.getDoc()),l=Gt(c),f=_n.paste(i,u[0],l);n.pasteCells(o,f).each(function(t){e.selection.setRng(t),e.focus(),r.clear(o)})}})})})}(e,i,r,n),function(e,t){var n=l.none(),r=[],i=[],a=[],s=[],u=function(e){e.disabled(!0)},c=function(e){e.disabled(!1)},f=function(){var e=this;r.push(e),n.fold(function(){u(e)},function(t){c(e)})},d=function(){var e=this;i.push(e),n.fold(function(){u(e)},function(t){c(e)})};e.on("init",function(){e.on("nodechange",function(o){var f=l.from(e.dom.getParent(e.selection.getStart(),"th,td"));(n=f.bind(function(e){var n=V.fromDom(e);return ut(n).map(function(e){return _n.forMenu(t,e,n)})})).fold(function(){S.each(r,u),S.each(i,u),S.each(a,u),S.each(s,u)},function(e){S.each(r,c),S.each(i,c),S.each(a,function(t){t.disabled(e.mergable().isNone())}),S.each(s,function(t){t.disabled(e.unmergable().isNone())})})})});var h=function(e,t,n,r){var o,i,a,s,u,c=r.getEl().getElementsByTagName("table")[0],l=r.isRtl()||"tl-tr"===r.parent().rel;for(c.nextSibling.innerHTML=t+1+" x "+(n+1),l&&(t=9-t),i=0;i<10;i++)for(o=0;o<10;o++)e.dom.toggleClass(s=c.rows[i].childNodes[o].firstChild,"mce-active",u=(l?o>=t:o<=t)&&i<=n),u&&(a=s);return a.parentNode},p=!1===function(e){return e.getParam("table_grid",!0,"boolean")}
vendor: 3,465 bytes, line 1
1(e)?{text:"Table",icon:"table",context:"table",onclick:o.curry(Gi,e)}:{text:"Table",icon:"table",context:"table",ariaHideMenu:!0,onclick:function(t){t.aria&&(this.parent().hideAll(),t.stopImmediatePropagation(),Gi(e))},onshow:function(){h(e,0,0,this.menu.items()[0])},onhide:function(){var t=this.menu.items()[0].getEl().getElementsByTagName("a");e.dom.removeClass(t,"mce-active"),e.dom.addClass(t[0],"mce-active")},menu:[{type:"container",html:function(){var e="";e='<table role="grid" class="mce-grid mce-grid-border" aria-readonly="true">';for(var t=0;t<10;t++){e+="<tr>";for(var n=0;n<10;n++)e+='<td role="gridcell" tabindex="-1"><a id="mcegrid'+(10*t+n)+'" href="#" data-mce-x="'+n+'" data-mce-y="'+t+'"></a></td>';e+="</tr>"}return(e+="</table>")+'<div class="mce-text-center" role="presentation">1 x 1</div>'}(),onPostRender:function(){this.lastX=this.lastY=0},onmousemove:function(t){var n,r,o=t.target;"A"===o.tagName.toUpperCase()&&(n=parseInt(o.getAttribute("data-mce-x"),10),r=parseInt(o.getAttribute("data-mce-y"),10),(this.isRtl()||"tl-tr"===this.parent().rel)&&(n=9-n),n===this.lastX&&r===this.lastY||(h(e,n,r,t.control),this.lastX=n,this.lastY=r))},onclick:function(t){var n=this;"A"===t.target.tagName.toUpperCase()&&(t.preventDefault(),t.stopPropagation(),n.parent().cancel(),e.undoManager.transact(function(){Xi(e,n.lastX+1,n.lastY+1)}),e.addVisual())}}]};function m(t){return function(){e.execCommand(t)}}var g={text:"Table properties",context:"table",onPostRender:f,onclick:o.curry(Gi,e,!0)},v={text:"Delete table",context:"table",onPostRender:f,cmd:"mceTableDelete"},y={text:"Row",context:"table",menu:[{text:"Insert row before",onclick:m("mceTableInsertRowBefore"),onPostRender:d},{text:"Insert row after",onclick:m("mceTableInsertRowAfter"),onPostRender:d},{text:"Delete row",onclick:m("mceTableDeleteRow"),onPostRender:d},{text:"Row properties",onclick:m("mceTableRowProps"),onPostRender:d},{text:"-"},{text:"Cut row",onclick:m("mceTableCutRow"),onPostRender:d},{text:"Copy row",onclick:m("mceTableCopyRow"),onPostRender:d},{text:"Paste row before",onclick:m("mceTablePasteRowBefore"),onPostRender:d},{text:"Paste row after",onclick:m("mceTablePasteRowAfter"),onPostRender:d}]},b={text:"Column",context:"table",menu:[{text:"Insert column before",onclick:m("mceTableInsertColBefore"),onPostRender:d},{text:"Insert column after",onclick:m("mceTableInsertColAfter"),onPostRender:d},{text:"Delete column",onclick:m("mceTableDeleteCol"),onPostRender:d}]},w={separator:"before",text:"Cell",context:"table",menu:[{text:"Cell properties",onclick:m("mceTableCellProps"),onPostRender:d},{text:"Merge cells",onclick:m("mceTableMergeCells"),onPostRender:function(){var e=this;a.push(e),n.fold(function(){u(e)},function(t){e.disabled(t.mergable().isNone())})}},{text:"Split cell",onclick:m("mceTableSplitCells"),onPostRender:function(){var e=this;s.push(e),n.fold(function(){u(e)},function(t){e.disabled(t.unmergable().isNone())})}}]};e.addMenuItem("inserttable",p),e.addMenuItem("tableprops",g),e.addMenuItem("deletetable",v),e.addMenuItem("row",y),e.addMenuItem("column",b),e.addMenuItem("cell",w)}(e,i),function(e){var t=[];function n(t){return function(){e.execCommand(t)}}gu("inserttable tableprops deletetable | cell row column".split(" "),function(n){t.push("|"===n?{text:"-"}:e.menuItems[n])}),e.addButton("table",{type:"menubutton",title:"Table",menu:t}),e.addButton("tableprops",{title:"Table properties",onclick:o.curry(Gi,e,!0),icon:"table"}
1),e.addButton("tabledelete",{title:"Delete table",onclick:n("mceTableDelete")}),e.addButton("tablecellprops",{title:"Cell properties",onclick:n("mceTableCellProps")}),e.addButton("tablemergecells",{title:"Merge cells",onclick:n("mceTableMergeCells")}),e.addButton("tablesplitcells",{title:"Split cell",onclick:n("mceTableSplitCells")}),e.addButton("tableinsertrowbefore",{title:"Insert row before",onclick:n("mceTableInsertRowBefore")}),e.addButton("tableinsertrowafter",{title:"Insert row after",onclick:n("mceTableInsertRowAfter")}),e.addButton("tabledeleterow",{title:"Delete row",onclick:n("mceTableDeleteRow")}),e.addButton("tablerowprops",{title:"Row properties",onclick:n("mceTableRowProps")}),e.addButton("tablecutrow",{title:"Cut row",onclick:n("mceTableCutRow")}),e.addButton("tablecopyrow",{title:"Copy row",onclick:n("mceTableCopyRow")}),e.addButton("tablepasterowbefore",{title:"Paste row before",onclick:n("mceTablePasteRowBefore")}),e.addButton("tablepasterowafter",{title:"Paste row after",onclick:n("mceTablePasteRowAfter")}),e.addButton("tableinsertcolbefore",{title:"Insert column before",onclick:n("mceTableInsertColBefore")}),e.addButton("tableinsertcolafter",{title:"Insert column after",onclick:n("mceTableInsertColAfter")}),e.addButton("tabledeletecol",{title:"Delete column",onclick:n("mceTableDeleteCol")})}(e),function(e){var t=function(e){var t=e.getParam("table_toolbar",wi);return""===t||!1===t?[]:D.isString(t)?t.split(/[ ,]/):D.isArray(t)?t:[]}(e);t.length>0&&e.addContextToolbar(function(t){return e.dom.is(t,"table")&&e.getBody().contains(t)},t.join(" "))}(e),e.on("PreInit",function(){e.serializer.addTempAttr(xn.firstSelected()),e.serializer.addTempAttr(xn.lastSelected())}),function(e){return e.getParam("table_tab_navigation",!0,"boolean")}(e)&&e.on("keydown",function(n){rs(n,e,r,t.lazyWire)}),e.on("remove",function(){t.destroy(),n.destroy()}),function(e,t){return{insertTable:function(t,n){return Xi(e,t,n)},setClipboardRows:function(e){return function(e,t){var n=S.map(e,V.fromDom);t.set(l.from(n))}(e,t)},getClipboardRows:function(){return function(e){return e.get().fold(function(){},function(e){return S.map(e,function(e){return e.dom()})})}(t)}}}(e,a)})}();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.