Commit 64d4f18d authored by bing zhang's avatar bing zhang
Browse files

1

parent 539344b2
/*! jQuery v1.11.0 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k="".trim,l={},m="1.11.0",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(e=arguments[h]))for(d in e)a=g[d],c=e[d],g!==c&&(j&&c&&(n.isPlainObject(c)||(b=n.isArray(c)))?(b?(b=!1,f=a&&n.isArray(a)?a:[]):f=a&&n.isPlainObject(a)?a:{},g[d]=n.extend(j,f,c)):void 0!==c&&(g[d]=c));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray||function(a){return"array"===n.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){return a-parseFloat(a)>=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;try{if(a.constructor&&!j.call(a,"constructor")&&!j.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(l.ownLast)for(b in a)return j.call(a,b);for(b in a);return void 0===b||j.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(b){b&&n.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:k&&!k.call("\ufeff\xa0")?function(a){return null==a?"":k.call(a)}:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){var d;if(b){if(g)return g.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,b){var c=+b.length,d=0,e=a.length;while(c>d)a[e++]=b[d++];if(c!==c)while(void 0!==b[d])a[e++]=b[d++];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(f=a[b],b=a,a=f),n.isFunction(a)?(c=d.call(arguments,2),e=function(){return a.apply(b||this,c.concat(d.call(arguments)))},e.guid=a.guid=a.guid||n.guid++,e):void 0},now:function(){return+new Date},support:l}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s="sizzle"+-new Date,t=a.document,u=0,v=0,w=eb(),x=eb(),y=eb(),z=function(a,b){return a===b&&(j=!0),0},A="undefined",B=1<<31,C={}.hasOwnProperty,D=[],E=D.pop,F=D.push,G=D.push,H=D.slice,I=D.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},J="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",K="[\\x20\\t\\r\\n\\f]",L="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",M=L.replace("w","w#"),N="\\["+K+"*("+L+")"+K+"*(?:([*^$|!~]?=)"+K+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+M+")|)|)"+K+"*\\]",O=":("+L+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+N.replace(3,8)+")*)|.*)\\)|)",P=new RegExp("^"+K+"+|((?:^|[^\\\\])(?:\\\\.)*)"+K+"+$","g"),Q=new RegExp("^"+K+"*,"+K+"*"),R=new RegExp("^"+K+"*([>+~]|"+K+")"+K+"*"),S=new RegExp("="+K+"*([^\\]'\"]*?)"+K+"*\\]","g"),T=new RegExp(O),U=new RegExp("^"+M+"$"),V={ID:new RegExp("^#("+L+")"),CLASS:new RegExp("^\\.("+L+")"),TAG:new RegExp("^("+L.replace("w","w*")+")"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+K+"*(even|odd|(([+-]|)(\\d*)n|)"+K+"*(?:([+-]|)"+K+"*(\\d+)|))"+K+"*\\)|)","i"),bool:new RegExp("^(?:"+J+")$","i"),needsContext:new RegExp("^"+K+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+K+"*((?:-\\d)?\\d*)"+K+"*\\)|)(?=[^-]|$)","i")},W=/^(?:input|select|textarea|button)$/i,X=/^h\d$/i,Y=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,$=/[+~]/,_=/'|\\/g,ab=new RegExp("\\\\([\\da-f]{1,6}"+K+"?|("+K+")|.)","ig"),bb=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{G.apply(D=H.call(t.childNodes),t.childNodes),D[t.childNodes.length].nodeType}catch(cb){G={apply:D.length?function(a,b){F.apply(a,H.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function db(a,b,d,e){var f,g,h,i,j,m,p,q,u,v;if((b?b.ownerDocument||b:t)!==l&&k(b),b=b||l,d=d||[],!a||"string"!=typeof a)return d;if(1!==(i=b.nodeType)&&9!==i)return[];if(n&&!e){if(f=Z.exec(a))if(h=f[1]){if(9===i){if(g=b.getElementById(h),!g||!g.parentNode)return d;if(g.id===h)return d.push(g),d}else if(b.ownerDocument&&(g=b.ownerDocument.getElementById(h))&&r(b,g)&&g.id===h)return d.push(g),d}else{if(f[2])return G.apply(d,b.getElementsByTagName(a)),d;if((h=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return G.apply(d,b.getElementsByClassName(h)),d}if(c.qsa&&(!o||!o.test(a))){if(q=p=s,u=b,v=9===i&&a,1===i&&"object"!==b.nodeName.toLowerCase()){m=ob(a),(p=b.getAttribute("id"))?q=p.replace(_,"\\$&"):b.setAttribute("id",q),q="[id='"+q+"'] ",j=m.length;while(j--)m[j]=q+pb(m[j]);u=$.test(a)&&mb(b.parentNode)||b,v=m.join(",")}if(v)try{return G.apply(d,u.querySelectorAll(v)),d}catch(w){}finally{p||b.removeAttribute("id")}}}return xb(a.replace(P,"$1"),b,d,e)}function eb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function fb(a){return a[s]=!0,a}function gb(a){var b=l.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function hb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function ib(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||B)-(~a.sourceIndex||B);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function jb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function kb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function lb(a){return fb(function(b){return b=+b,fb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function mb(a){return a&&typeof a.getElementsByTagName!==A&&a}c=db.support={},f=db.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},k=db.setDocument=function(a){var b,e=a?a.ownerDocument||a:t,g=e.defaultView;return e!==l&&9===e.nodeType&&e.documentElement?(l=e,m=e.documentElement,n=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){k()},!1):g.attachEvent&&g.attachEvent("onunload",function(){k()})),c.attributes=gb(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=gb(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Y.test(e.getElementsByClassName)&&gb(function(a){return a.innerHTML="<div class='a'></div><div class='a i'></div>",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=gb(function(a){return m.appendChild(a).id=s,!e.getElementsByName||!e.getElementsByName(s).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==A&&n){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ab,bb);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ab,bb);return function(a){var c=typeof a.getAttributeNode!==A&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==A?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==A&&n?b.getElementsByClassName(a):void 0},p=[],o=[],(c.qsa=Y.test(e.querySelectorAll))&&(gb(function(a){a.innerHTML="<select t=''><option selected=''></option></select>",a.querySelectorAll("[t^='']").length&&o.push("[*^$]="+K+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||o.push("\\["+K+"*(?:value|"+J+")"),a.querySelectorAll(":checked").length||o.push(":checked")}),gb(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&o.push("name"+K+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||o.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),o.push(",.*:")})),(c.matchesSelector=Y.test(q=m.webkitMatchesSelector||m.mozMatchesSelector||m.oMatchesSelector||m.msMatchesSelector))&&gb(function(a){c.disconnectedMatch=q.call(a,"div"),q.call(a,"[s!='']:x"),p.push("!=",O)}),o=o.length&&new RegExp(o.join("|")),p=p.length&&new RegExp(p.join("|")),b=Y.test(m.compareDocumentPosition),r=b||Y.test(m.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},z=b?function(a,b){if(a===b)return j=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===t&&r(t,a)?-1:b===e||b.ownerDocument===t&&r(t,b)?1:i?I.call(i,a)-I.call(i,b):0:4&d?-1:1)}:function(a,b){if(a===b)return j=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],k=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:i?I.call(i,a)-I.call(i,b):0;if(f===g)return ib(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)k.unshift(c);while(h[d]===k[d])d++;return d?ib(h[d],k[d]):h[d]===t?-1:k[d]===t?1:0},e):l},db.matches=function(a,b){return db(a,null,null,b)},db.matchesSelector=function(a,b){if((a.ownerDocument||a)!==l&&k(a),b=b.replace(S,"='$1']"),!(!c.matchesSelector||!n||p&&p.test(b)||o&&o.test(b)))try{var d=q.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return db(b,l,null,[a]).length>0},db.contains=function(a,b){return(a.ownerDocument||a)!==l&&k(a),r(a,b)},db.attr=function(a,b){(a.ownerDocument||a)!==l&&k(a);var e=d.attrHandle[b.toLowerCase()],f=e&&C.call(d.attrHandle,b.toLowerCase())?e(a,b,!n):void 0;return void 0!==f?f:c.attributes||!n?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},db.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},db.uniqueSort=function(a){var b,d=[],e=0,f=0;if(j=!c.detectDuplicates,i=!c.sortStable&&a.slice(0),a.sort(z),j){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return i=null,a},e=db.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=db.selectors={cacheLength:50,createPseudo:fb,match:V,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ab,bb),a[3]=(a[4]||a[5]||"").replace(ab,bb),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||db.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&db.error(a[0]),a},PSEUDO:function(a){var b,c=!a[5]&&a[2];return V.CHILD.test(a[0])?null:(a[3]&&void 0!==a[4]?a[2]=a[4]:c&&T.test(c)&&(b=ob(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ab,bb).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=w[a+" "];return b||(b=new RegExp("(^|"+K+")"+a+"("+K+"|$)"))&&w(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==A&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=db.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),t=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&t){k=q[s]||(q[s]={}),j=k[a]||[],n=j[0]===u&&j[1],m=j[0]===u&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[u,n,m];break}}else if(t&&(j=(b[s]||(b[s]={}))[a])&&j[0]===u)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(t&&((l[s]||(l[s]={}))[a]=[u,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||db.error("unsupported pseudo: "+a);return e[s]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?fb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=I.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:fb(function(a){var b=[],c=[],d=g(a.replace(P,"$1"));return d[s]?fb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:fb(function(a){return function(b){return db(a,b).length>0}}),contains:fb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:fb(function(a){return U.test(a||"")||db.error("unsupported lang: "+a),a=a.replace(ab,bb).toLowerCase(),function(b){var c;do if(c=n?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===m},focus:function(a){return a===l.activeElement&&(!l.hasFocus||l.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return X.test(a.nodeName)},input:function(a){return W.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:lb(function(){return[0]}),last:lb(function(a,b){return[b-1]}),eq:lb(function(a,b,c){return[0>c?c+b:c]}),even:lb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:lb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:lb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:lb(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=jb(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=kb(b);function nb(){}nb.prototype=d.filters=d.pseudos,d.setFilters=new nb;function ob(a,b){var c,e,f,g,h,i,j,k=x[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=Q.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=R.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(P," ")}),h=h.slice(c.length));for(g in d.filter)!(e=V[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?db.error(a):x(a,i).slice(0)}function pb(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function qb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=v++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[u,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[s]||(b[s]={}),(h=i[d])&&h[0]===u&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function rb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function sb(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function tb(a,b,c,d,e,f){return d&&!d[s]&&(d=tb(d)),e&&!e[s]&&(e=tb(e,f)),fb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||wb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:sb(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=sb(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?I.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=sb(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):G.apply(g,r)})}function ub(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],i=g||d.relative[" "],j=g?1:0,k=qb(function(a){return a===b},i,!0),l=qb(function(a){return I.call(b,a)>-1},i,!0),m=[function(a,c,d){return!g&&(d||c!==h)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>j;j++)if(c=d.relative[a[j].type])m=[qb(rb(m),c)];else{if(c=d.filter[a[j].type].apply(null,a[j].matches),c[s]){for(e=++j;f>e;e++)if(d.relative[a[e].type])break;return tb(j>1&&rb(m),j>1&&pb(a.slice(0,j-1).concat({value:" "===a[j-2].type?"*":""})).replace(P,"$1"),c,e>j&&ub(a.slice(j,e)),f>e&&ub(a=a.slice(e)),f>e&&pb(a))}m.push(c)}return rb(m)}function vb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,i,j,k){var m,n,o,p=0,q="0",r=f&&[],s=[],t=h,v=f||e&&d.find.TAG("*",k),w=u+=null==t?1:Math.random()||.1,x=v.length;for(k&&(h=g!==l&&g);q!==x&&null!=(m=v[q]);q++){if(e&&m){n=0;while(o=a[n++])if(o(m,g,i)){j.push(m);break}k&&(u=w)}c&&((m=!o&&m)&&p--,f&&r.push(m))}if(p+=q,c&&q!==p){n=0;while(o=b[n++])o(r,s,g,i);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=E.call(j));s=sb(s)}G.apply(j,s),k&&!f&&s.length>0&&p+b.length>1&&db.uniqueSort(j)}return k&&(u=w,h=t),r};return c?fb(f):f}g=db.compile=function(a,b){var c,d=[],e=[],f=y[a+" "];if(!f){b||(b=ob(a)),c=b.length;while(c--)f=ub(b[c]),f[s]?d.push(f):e.push(f);f=y(a,vb(e,d))}return f};function wb(a,b,c){for(var d=0,e=b.length;e>d;d++)db(a,b[d],c);return c}function xb(a,b,e,f){var h,i,j,k,l,m=ob(a);if(!f&&1===m.length){if(i=m[0]=m[0].slice(0),i.length>2&&"ID"===(j=i[0]).type&&c.getById&&9===b.nodeType&&n&&d.relative[i[1].type]){if(b=(d.find.ID(j.matches[0].replace(ab,bb),b)||[])[0],!b)return e;a=a.slice(i.shift().value.length)}h=V.needsContext.test(a)?0:i.length;while(h--){if(j=i[h],d.relative[k=j.type])break;if((l=d.find[k])&&(f=l(j.matches[0].replace(ab,bb),$.test(i[0].type)&&mb(b.parentNode)||b))){if(i.splice(h,1),a=f.length&&pb(i),!a)return G.apply(e,f),e;break}}}return g(a,m)(f,b,!n,e,$.test(a)&&mb(b.parentNode)||b),e}return c.sortStable=s.split("").sort(z).join("")===s,c.detectDuplicates=!!j,k(),c.sortDetached=gb(function(a){return 1&a.compareDocumentPosition(l.createElement("div"))}),gb(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||hb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&gb(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||hb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),gb(function(a){return null==a.getAttribute("disabled")})||hb(J,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),db}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return n.inArray(a,b)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;e>b;b++)if(n.contains(d[b],this))return!0}));for(b=0;e>b;b++)n.find(a,d[b],c);return c=this.pushStack(e>1?n.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=a.document,A=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,B=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:A.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:z,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}if(d=z.getElementById(c[2]),d&&d.parentNode){if(d.id!==c[2])return y.find(a);this.length=1,this[0]=d}return this.context=z,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};B.prototype=n.fn,y=n(z);var C=/^(?:parents|prev(?:Until|All))/,D={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=a[b];while(e&&9!==e.nodeType&&(void 0===c||1!==e.nodeType||!n(e).is(c)))1===e.nodeType&&d.push(e),e=e[b];return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b,c=n(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if(n.contains(this,c[b]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?n.inArray(this[0],n(a)):n.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function E(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return E(a,"nextSibling")},prev:function(a){return E(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return n.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(D[a]||(e=n.unique(e)),C.test(a)&&(e=e.reverse())),this.pushStack(e)}});var F=/\S+/g,G={};function H(a){var b=G[a]={};return n.each(a.match(F)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?G[a]||H(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(c=a.memory&&l,d=!0,f=g||0,g=0,e=h.length,b=!0;h&&e>f;f++)if(h[f].apply(l[0],l[1])===!1&&a.stopOnFalse){c=!1;break}b=!1,h&&(i?i.length&&j(i.shift()):c?h=[]:k.disable())},k={add:function(){if(h){var d=h.length;!function f(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&f(c)})}(arguments),b?e=h.length:c&&(g=d,j(c))}return this},remove:function(){return h&&n.each(arguments,function(a,c){var d;while((d=n.inArray(c,h,d))>-1)h.splice(d,1),b&&(e>=d&&e--,f>=d&&f--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],e=0,this},disable:function(){return h=i=c=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,c||k.disable(),this},locked:function(){return!i},fireWith:function(a,c){return!h||d&&!i||(c=c||[],c=[a,c.slice?c.slice():c],b?i.push(c):j(c)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!d}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){if(a===!0?!--n.readyWait:!n.isReady){if(!z.body)return setTimeout(n.ready);n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(z,[n]),n.fn.trigger&&n(z).trigger("ready").off("ready"))}}});function J(){z.addEventListener?(z.removeEventListener("DOMContentLoaded",K,!1),a.removeEventListener("load",K,!1)):(z.detachEvent("onreadystatechange",K),a.detachEvent("onload",K))}function K(){(z.addEventListener||"load"===event.type||"complete"===z.readyState)&&(J(),n.ready())}n.ready.promise=function(b){if(!I)if(I=n.Deferred(),"complete"===z.readyState)setTimeout(n.ready);else if(z.addEventListener)z.addEventListener("DOMContentLoaded",K,!1),a.addEventListener("load",K,!1);else{z.attachEvent("onreadystatechange",K),a.attachEvent("onload",K);var c=!1;try{c=null==a.frameElement&&z.documentElement}catch(d){}c&&c.doScroll&&!function e(){if(!n.isReady){try{c.doScroll("left")}catch(a){return setTimeout(e,50)}J(),n.ready()}}()}return I.promise(b)};var L="undefined",M;for(M in n(l))break;l.ownLast="0"!==M,l.inlineBlockNeedsLayout=!1,n(function(){var a,b,c=z.getElementsByTagName("body")[0];c&&(a=z.createElement("div"),a.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",b=z.createElement("div"),c.appendChild(a).appendChild(b),typeof b.style.zoom!==L&&(b.style.cssText="border:0;margin:0;width:1px;padding:1px;display:inline;zoom:1",(l.inlineBlockNeedsLayout=3===b.offsetWidth)&&(c.style.zoom=1)),c.removeChild(a),a=b=null)}),function(){var a=z.createElement("div");if(null==l.deleteExpando){l.deleteExpando=!0;try{delete a.test}catch(b){l.deleteExpando=!1}}a=null}(),n.acceptData=function(a){var b=n.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return 1!==c&&9!==c?!1:!b||b!==!0&&a.getAttribute("classid")===b};var N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(O,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}n.data(a,b,c)}else c=void 0}return c}function Q(a){var b;for(b in a)if(("data"!==b||!n.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function R(a,b,d,e){if(n.acceptData(a)){var f,g,h=n.expando,i=a.nodeType,j=i?n.cache:a,k=i?a[h]:a[h]&&h;if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||n.guid++:h),j[k]||(j[k]=i?{}:{toJSON:n.noop}),("object"==typeof b||"function"==typeof b)&&(e?j[k]=n.extend(j[k],b):j[k].data=n.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[n.camelCase(b)]=d),"string"==typeof b?(f=g[b],null==f&&(f=g[n.camelCase(b)])):f=g,f
}}function S(a,b,c){if(n.acceptData(a)){var d,e,f=a.nodeType,g=f?n.cache:a,h=f?a[n.expando]:n.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){n.isArray(b)?b=b.concat(n.map(b,n.camelCase)):b in d?b=[b]:(b=n.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!Q(d):!n.isEmptyObject(d))return}(c||(delete g[h].data,Q(g[h])))&&(f?n.cleanData([a],!0):l.deleteExpando||g!=g.window?delete g[h]:g[h]=null)}}}n.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return a=a.nodeType?n.cache[a[n.expando]]:a[n.expando],!!a&&!Q(a)},data:function(a,b,c){return R(a,b,c)},removeData:function(a,b){return S(a,b)},_data:function(a,b,c){return R(a,b,c,!0)},_removeData:function(a,b){return S(a,b,!0)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=n.data(f),1===f.nodeType&&!n._data(f,"parsedAttrs"))){c=g.length;while(c--)d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d]));n._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){n.data(this,a)}):arguments.length>1?this.each(function(){n.data(this,a,b)}):f?P(f,a,n.data(f,a)):void 0},removeData:function(a){return this.each(function(){n.removeData(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=n._data(a,b),c&&(!d||n.isArray(c)?d=n._data(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return n._data(a,c)||n._data(a,c,{empty:n.Callbacks("once memory").add(function(){n._removeData(a,b+"queue"),n._removeData(a,c)})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=n._data(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var T=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,U=["Top","Right","Bottom","Left"],V=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)},W=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},X=/^(?:checkbox|radio)$/i;!function(){var a=z.createDocumentFragment(),b=z.createElement("div"),c=z.createElement("input");if(b.setAttribute("className","t"),b.innerHTML=" <link/><table></table><a href='/a'>a</a>",l.leadingWhitespace=3===b.firstChild.nodeType,l.tbody=!b.getElementsByTagName("tbody").length,l.htmlSerialize=!!b.getElementsByTagName("link").length,l.html5Clone="<:nav></:nav>"!==z.createElement("nav").cloneNode(!0).outerHTML,c.type="checkbox",c.checked=!0,a.appendChild(c),l.appendChecked=c.checked,b.innerHTML="<textarea>x</textarea>",l.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue,a.appendChild(b),b.innerHTML="<input type='radio' checked='checked' name='t'/>",l.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,l.noCloneEvent=!0,b.attachEvent&&(b.attachEvent("onclick",function(){l.noCloneEvent=!1}),b.cloneNode(!0).click()),null==l.deleteExpando){l.deleteExpando=!0;try{delete b.test}catch(d){l.deleteExpando=!1}}a=b=c=null}(),function(){var b,c,d=z.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(l[b+"Bubbles"]=c in a)||(d.setAttribute(c,"t"),l[b+"Bubbles"]=d.attributes[c].expando===!1);d=null}();var Y=/^(?:input|select|textarea)$/i,Z=/^key/,$=/^(?:mouse|contextmenu)|click/,_=/^(?:focusinfocus|focusoutblur)$/,ab=/^([^.]*)(?:\.(.+)|)$/;function bb(){return!0}function cb(){return!1}function db(){try{return z.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=n.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return typeof n===L||a&&n.event.triggered===a.type?void 0:n.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(F)||[""],h=b.length;while(h--)f=ab.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=n.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=n.event.special[o]||{},l=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},i),(m=g[o])||(m=g[o]=[],m.delegateCount=0,j.setup&&j.setup.call(a,d,p,k)!==!1||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,l):m.push(l),n.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n.hasData(a)&&n._data(a);if(r&&(k=r.events)){b=(b||"").match(F)||[""],j=b.length;while(j--)if(h=ab.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=m.length;while(f--)g=m[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(m.splice(f,1),g.selector&&m.delegateCount--,l.remove&&l.remove.call(a,g));i&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(k)&&(delete r.handle,n._removeData(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,l,m,o=[d||z],p=j.call(b,"type")?b.type:b,q=j.call(b,"namespace")?b.namespace.split("."):[];if(h=l=d=d||z,3!==d.nodeType&&8!==d.nodeType&&!_.test(p+n.event.triggered)&&(p.indexOf(".")>=0&&(q=p.split("."),p=q.shift(),q.sort()),g=p.indexOf(":")<0&&"on"+p,b=b[n.expando]?b:new n.Event(p,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=q.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+q.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),k=n.event.special[p]||{},e||!k.trigger||k.trigger.apply(d,c)!==!1)){if(!e&&!k.noBubble&&!n.isWindow(d)){for(i=k.delegateType||p,_.test(i+p)||(h=h.parentNode);h;h=h.parentNode)o.push(h),l=h;l===(d.ownerDocument||z)&&o.push(l.defaultView||l.parentWindow||a)}m=0;while((h=o[m++])&&!b.isPropagationStopped())b.type=m>1?i:k.bindType||p,f=(n._data(h,"events")||{})[b.type]&&n._data(h,"handle"),f&&f.apply(h,c),f=g&&h[g],f&&f.apply&&n.acceptData(h)&&(b.result=f.apply(h,c),b.result===!1&&b.preventDefault());if(b.type=p,!e&&!b.isDefaultPrevented()&&(!k._default||k._default.apply(o.pop(),c)===!1)&&n.acceptData(d)&&g&&d[p]&&!n.isWindow(d)){l=d[g],l&&(d[g]=null),n.event.triggered=p;try{d[p]()}catch(r){}n.event.triggered=void 0,l&&(d[g]=l)}return b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(n._data(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,g=0;while((e=f.handlers[g++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(e.namespace))&&(a.handleObj=e,a.data=e.data,c=((n.event.special[e.origType]||{}).handle||e.handler).apply(f.elem,i),void 0!==c&&(a.result=c)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(e=[],f=0;h>f;f++)d=b[f],c=d.selector+" ",void 0===e[c]&&(e[c]=d.needsContext?n(c,this).index(i)>=0:n.find(c,this,null,[i]).length),e[c]&&e.push(d);e.length&&g.push({elem:i,handlers:e})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},fix:function(a){if(a[n.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=$.test(e)?this.mouseHooks:Z.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new n.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=f.srcElement||z),3===a.target.nodeType&&(a.target=a.target.parentNode),a.metaKey=!!a.metaKey,g.filter?g.filter(a,f):a},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button,g=b.fromElement;return null==a.pageX&&null!=b.clientX&&(d=a.target.ownerDocument||z,e=d.documentElement,c=d.body,a.pageX=b.clientX+(e&&e.scrollLeft||c&&c.scrollLeft||0)-(e&&e.clientLeft||c&&c.clientLeft||0),a.pageY=b.clientY+(e&&e.scrollTop||c&&c.scrollTop||0)-(e&&e.clientTop||c&&c.clientTop||0)),!a.relatedTarget&&g&&(a.relatedTarget=g===a.target?b.toElement:g),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==db()&&this.focus)try{return this.focus(),!1}catch(a){}},delegateType:"focusin"},blur:{trigger:function(){return this===db()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return n.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=n.extend(new n.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?n.event.trigger(e,null,b):n.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=z.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){var d="on"+b;a.detachEvent&&(typeof a[d]===L&&(a[d]=null),a.detachEvent(d,c))},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&(a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault())?bb:cb):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={isDefaultPrevented:cb,isPropagationStopped:cb,isImmediatePropagationStopped:cb,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=bb,a&&(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=bb,a&&(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=bb,this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),l.submitBubbles||(n.event.special.submit={setup:function(){return n.nodeName(this,"form")?!1:void n.event.add(this,"click._submit keypress._submit",function(a){var b=a.target,c=n.nodeName(b,"input")||n.nodeName(b,"button")?b.form:void 0;c&&!n._data(c,"submitBubbles")&&(n.event.add(c,"submit._submit",function(a){a._submit_bubble=!0}),n._data(c,"submitBubbles",!0))})},postDispatch:function(a){a._submit_bubble&&(delete a._submit_bubble,this.parentNode&&!a.isTrigger&&n.event.simulate("submit",this.parentNode,a,!0))},teardown:function(){return n.nodeName(this,"form")?!1:void n.event.remove(this,"._submit")}}),l.changeBubbles||(n.event.special.change={setup:function(){return Y.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(n.event.add(this,"propertychange._change",function(a){"checked"===a.originalEvent.propertyName&&(this._just_changed=!0)}),n.event.add(this,"click._change",function(a){this._just_changed&&!a.isTrigger&&(this._just_changed=!1),n.event.simulate("change",this,a,!0)})),!1):void n.event.add(this,"beforeactivate._change",function(a){var b=a.target;Y.test(b.nodeName)&&!n._data(b,"changeBubbles")&&(n.event.add(b,"change._change",function(a){!this.parentNode||a.isSimulated||a.isTrigger||n.event.simulate("change",this.parentNode,a,!0)}),n._data(b,"changeBubbles",!0))})},handle:function(a){var b=a.target;return this!==b||a.isSimulated||a.isTrigger||"radio"!==b.type&&"checkbox"!==b.type?a.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return n.event.remove(this,"._change"),!Y.test(this.nodeName)}}),l.focusinBubbles||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a),!0)};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=n._data(d,b);e||d.addEventListener(a,c,!0),n._data(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=n._data(d,b)-1;e?n._data(d,b,e):(d.removeEventListener(a,c,!0),n._removeData(d,b))}}}),n.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(f in a)this.on(f,b,c,a[f],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=cb;else if(!d)return this;return 1===e&&(g=d,d=function(a){return n().off(a),g.apply(this,arguments)},d.guid=g.guid||(g.guid=n.guid++)),this.each(function(){n.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=cb),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});function eb(a){var b=fb.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}var fb="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",gb=/ jQuery\d+="(?:null|\d+)"/g,hb=new RegExp("<(?:"+fb+")[\\s/>]","i"),ib=/^\s+/,jb=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,kb=/<([\w:]+)/,lb=/<tbody/i,mb=/<|&#?\w+;/,nb=/<(?:script|style|link)/i,ob=/checked\s*(?:[^=]|=\s*.checked.)/i,pb=/^$|\/(?:java|ecma)script/i,qb=/^true\/(.*)/,rb=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,sb={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:l.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},tb=eb(z),ub=tb.appendChild(z.createElement("div"));sb.optgroup=sb.option,sb.tbody=sb.tfoot=sb.colgroup=sb.caption=sb.thead,sb.th=sb.td;function vb(a,b){var c,d,e=0,f=typeof a.getElementsByTagName!==L?a.getElementsByTagName(b||"*"):typeof a.querySelectorAll!==L?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||n.nodeName(d,b)?f.push(d):n.merge(f,vb(d,b));return void 0===b||b&&n.nodeName(a,b)?n.merge([a],f):f}function wb(a){X.test(a.type)&&(a.defaultChecked=a.checked)}function xb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function yb(a){return a.type=(null!==n.find.attr(a,"type"))+"/"+a.type,a}function zb(a){var b=qb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Ab(a,b){for(var c,d=0;null!=(c=a[d]);d++)n._data(c,"globalEval",!b||n._data(b[d],"globalEval"))}function Bb(a,b){if(1===b.nodeType&&n.hasData(a)){var c,d,e,f=n._data(a),g=n._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)n.event.add(b,c,h[c][d])}g.data&&(g.data=n.extend({},g.data))}}function Cb(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!l.noCloneEvent&&b[n.expando]){e=n._data(b);for(d in e.events)n.removeEvent(b,d,e.handle);b.removeAttribute(n.expando)}"script"===c&&b.text!==a.text?(yb(b).text=a.text,zb(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),l.html5Clone&&a.innerHTML&&!n.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&X.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}}n.extend({clone:function(a,b,c){var d,e,f,g,h,i=n.contains(a.ownerDocument,a);if(l.html5Clone||n.isXMLDoc(a)||!hb.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(ub.innerHTML=a.outerHTML,ub.removeChild(f=ub.firstChild)),!(l.noCloneEvent&&l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(d=vb(f),h=vb(a),g=0;null!=(e=h[g]);++g)d[g]&&Cb(e,d[g]);if(b)if(c)for(h=h||vb(a),d=d||vb(f),g=0;null!=(e=h[g]);g++)Bb(e,d[g]);else Bb(a,f);return d=vb(f,"script"),d.length>0&&Ab(d,!i&&vb(a,"script")),d=h=e=null,f},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k,m=a.length,o=eb(b),p=[],q=0;m>q;q++)if(f=a[q],f||0===f)if("object"===n.type(f))n.merge(p,f.nodeType?[f]:f);else if(mb.test(f)){h=h||o.appendChild(b.createElement("div")),i=(kb.exec(f)||["",""])[1].toLowerCase(),k=sb[i]||sb._default,h.innerHTML=k[1]+f.replace(jb,"<$1></$2>")+k[2],e=k[0];while(e--)h=h.lastChild;if(!l.leadingWhitespace&&ib.test(f)&&p.push(b.createTextNode(ib.exec(f)[0])),!l.tbody){f="table"!==i||lb.test(f)?"<table>"!==k[1]||lb.test(f)?0:h:h.firstChild,e=f&&f.childNodes.length;while(e--)n.nodeName(j=f.childNodes[e],"tbody")&&!j.childNodes.length&&f.removeChild(j)}n.merge(p,h.childNodes),h.textContent="";while(h.firstChild)h.removeChild(h.firstChild);h=o.lastChild}else p.push(b.createTextNode(f));h&&o.removeChild(h),l.appendChecked||n.grep(vb(p,"input"),wb),q=0;while(f=p[q++])if((!d||-1===n.inArray(f,d))&&(g=n.contains(f.ownerDocument,f),h=vb(o.appendChild(f),"script"),g&&Ab(h),c)){e=0;while(f=h[e++])pb.test(f.type||"")&&c.push(f)}return h=null,o},cleanData:function(a,b){for(var d,e,f,g,h=0,i=n.expando,j=n.cache,k=l.deleteExpando,m=n.event.special;null!=(d=a[h]);h++)if((b||n.acceptData(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)m[e]?n.event.remove(d,e):n.removeEvent(d,e,g.handle);j[f]&&(delete j[f],k?delete d[i]:typeof d.removeAttribute!==L?d.removeAttribute(i):d[i]=null,c.push(f))}}}),n.fn.extend({text:function(a){return W(this,function(a){return void 0===a?n.text(this):this.empty().append((this[0]&&this[0].ownerDocument||z).createTextNode(a))},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=xb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=xb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(vb(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&Ab(vb(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&n.cleanData(vb(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&n.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return W(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(gb,""):void 0;if(!("string"!=typeof a||nb.test(a)||!l.htmlSerialize&&hb.test(a)||!l.leadingWhitespace&&ib.test(a)||sb[(kb.exec(a)||["",""])[1].toLowerCase()])){a=a.replace(jb,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(vb(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(vb(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,k=this.length,m=this,o=k-1,p=a[0],q=n.isFunction(p);if(q||k>1&&"string"==typeof p&&!l.checkClone&&ob.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(k&&(i=n.buildFragment(a,this[0].ownerDocument,!1,this),c=i.firstChild,1===i.childNodes.length&&(i=c),c)){for(g=n.map(vb(i,"script"),yb),f=g.length;k>j;j++)d=i,j!==o&&(d=n.clone(d,!0,!0),f&&n.merge(g,vb(d,"script"))),b.call(this[j],d,j);if(f)for(h=g[g.length-1].ownerDocument,n.map(g,zb),j=0;f>j;j++)d=g[j],pb.test(d.type||"")&&!n._data(d,"globalEval")&&n.contains(h,d)&&(d.src?n._evalUrl&&n._evalUrl(d.src):n.globalEval((d.text||d.textContent||d.innerHTML||"").replace(rb,"")));i=c=null}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=0,e=[],g=n(a),h=g.length-1;h>=d;d++)c=d===h?this:this.clone(!0),n(g[d])[b](c),f.apply(e,c.get());return this.pushStack(e)}});var Db,Eb={};function Fb(b,c){var d=n(c.createElement(b)).appendTo(c.body),e=a.getDefaultComputedStyle?a.getDefaultComputedStyle(d[0]).display:n.css(d[0],"display");return d.detach(),e}function Gb(a){var b=z,c=Eb[a];return c||(c=Fb(a,b),"none"!==c&&c||(Db=(Db||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=(Db[0].contentWindow||Db[0].contentDocument).document,b.write(),b.close(),c=Fb(a,b),Db.detach()),Eb[a]=c),c}!function(){var a,b,c=z.createElement("div"),d="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;padding:0;margin:0;border:0";c.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",a=c.getElementsByTagName("a")[0],a.style.cssText="float:left;opacity:.5",l.opacity=/^0.5/.test(a.style.opacity),l.cssFloat=!!a.style.cssFloat,c.style.backgroundClip="content-box",c.cloneNode(!0).style.backgroundClip="",l.clearCloneStyle="content-box"===c.style.backgroundClip,a=c=null,l.shrinkWrapBlocks=function(){var a,c,e,f;if(null==b){if(a=z.getElementsByTagName("body")[0],!a)return;f="border:0;width:0;height:0;position:absolute;top:0;left:-9999px",c=z.createElement("div"),e=z.createElement("div"),a.appendChild(c).appendChild(e),b=!1,typeof e.style.zoom!==L&&(e.style.cssText=d+";width:1px;padding:1px;zoom:1",e.innerHTML="<div></div>",e.firstChild.style.width="5px",b=3!==e.offsetWidth),a.removeChild(c),a=c=e=null}return b}}();var Hb=/^margin/,Ib=new RegExp("^("+T+")(?!px)[a-z%]+$","i"),Jb,Kb,Lb=/^(top|right|bottom|left)$/;a.getComputedStyle?(Jb=function(a){return a.ownerDocument.defaultView.getComputedStyle(a,null)},Kb=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Jb(a),g=c?c.getPropertyValue(b)||c[b]:void 0,c&&(""!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),Ib.test(g)&&Hb.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0===g?g:g+""}):z.documentElement.currentStyle&&(Jb=function(a){return a.currentStyle},Kb=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Jb(a),g=c?c[b]:void 0,null==g&&h&&h[b]&&(g=h[b]),Ib.test(g)&&!Lb.test(b)&&(d=h.left,e=a.runtimeStyle,f=e&&e.left,f&&(e.left=a.currentStyle.left),h.left="fontSize"===b?"1em":g,g=h.pixelLeft+"px",h.left=d,f&&(e.left=f)),void 0===g?g:g+""||"auto"});function Mb(a,b){return{get:function(){var c=a();if(null!=c)return c?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d,e,f,g,h=z.createElement("div"),i="border:0;width:0;height:0;position:absolute;top:0;left:-9999px",j="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;padding:0;margin:0;border:0";h.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",b=h.getElementsByTagName("a")[0],b.style.cssText="float:left;opacity:.5",l.opacity=/^0.5/.test(b.style.opacity),l.cssFloat=!!b.style.cssFloat,h.style.backgroundClip="content-box",h.cloneNode(!0).style.backgroundClip="",l.clearCloneStyle="content-box"===h.style.backgroundClip,b=h=null,n.extend(l,{reliableHiddenOffsets:function(){if(null!=c)return c;var a,b,d,e=z.createElement("div"),f=z.getElementsByTagName("body")[0];if(f)return e.setAttribute("className","t"),e.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",a=z.createElement("div"),a.style.cssText=i,f.appendChild(a).appendChild(e),e.innerHTML="<table><tr><td></td><td>t</td></tr></table>",b=e.getElementsByTagName("td"),b[0].style.cssText="padding:0;margin:0;border:0;display:none",d=0===b[0].offsetHeight,b[0].style.display="",b[1].style.display="none",c=d&&0===b[0].offsetHeight,f.removeChild(a),e=f=null,c},boxSizing:function(){return null==d&&k(),d},boxSizingReliable:function(){return null==e&&k(),e},pixelPosition:function(){return null==f&&k(),f},reliableMarginRight:function(){var b,c,d,e;if(null==g&&a.getComputedStyle){if(b=z.getElementsByTagName("body")[0],!b)return;c=z.createElement("div"),d=z.createElement("div"),c.style.cssText=i,b.appendChild(c).appendChild(d),e=d.appendChild(z.createElement("div")),e.style.cssText=d.style.cssText=j,e.style.marginRight=e.style.width="0",d.style.width="1px",g=!parseFloat((a.getComputedStyle(e,null)||{}).marginRight),b.removeChild(c)}return g}});function k(){var b,c,h=z.getElementsByTagName("body")[0];h&&(b=z.createElement("div"),c=z.createElement("div"),b.style.cssText=i,h.appendChild(b).appendChild(c),c.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;position:absolute;display:block;padding:1px;border:1px;width:4px;margin-top:1%;top:1%",n.swap(h,null!=h.style.zoom?{zoom:1}:{},function(){d=4===c.offsetWidth}),e=!0,f=!1,g=!0,a.getComputedStyle&&(f="1%"!==(a.getComputedStyle(c,null)||{}).top,e="4px"===(a.getComputedStyle(c,null)||{width:"4px"}).width),h.removeChild(b),c=h=null)}}(),n.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var Nb=/alpha\([^)]*\)/i,Ob=/opacity\s*=\s*([^)]*)/,Pb=/^(none|table(?!-c[ea]).+)/,Qb=new RegExp("^("+T+")(.*)$","i"),Rb=new RegExp("^([+-])=("+T+")","i"),Sb={position:"absolute",visibility:"hidden",display:"block"},Tb={letterSpacing:0,fontWeight:400},Ub=["Webkit","O","Moz","ms"];function Vb(a,b){if(b in a)return b;var c=b.charAt(0).toUpperCase()+b.slice(1),d=b,e=Ub.length;while(e--)if(b=Ub[e]+c,b in a)return b;return d}function Wb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=n._data(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&V(d)&&(f[g]=n._data(d,"olddisplay",Gb(d.nodeName)))):f[g]||(e=V(d),(c&&"none"!==c||!e)&&n._data(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}function Xb(a,b,c){var d=Qb.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Yb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+U[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+U[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+U[f]+"Width",!0,e))):(g+=n.css(a,"padding"+U[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+U[f]+"Width",!0,e)));return g}function Zb(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=Jb(a),g=l.boxSizing()&&"border-box"===n.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=Kb(a,b,f),(0>e||null==e)&&(e=a.style[b]),Ib.test(e))return e;d=g&&(l.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Yb(a,b,c||(g?"border":"content"),d,f)+"px"}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Kb(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":l.cssFloat?"cssFloat":"styleFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;if(b=n.cssProps[h]||(n.cssProps[h]=Vb(i,h)),g=n.cssHooks[b]||n.cssHooks[h],void 0===c)return g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b];if(f=typeof c,"string"===f&&(e=Rb.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(n.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||n.cssNumber[h]||(c+="px"),l.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),!(g&&"set"in g&&void 0===(c=g.set(a,c,d)))))try{i[b]="",i[b]=c}catch(j){}}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Vb(a.style,h)),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(f=g.get(a,!0,c)),void 0===f&&(f=Kb(a,b,d)),"normal"===f&&b in Tb&&(f=Tb[b]),""===c||c?(e=parseFloat(f),c===!0||n.isNumeric(e)?e||0:f):f}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?0===a.offsetWidth&&Pb.test(n.css(a,"display"))?n.swap(a,Sb,function(){return Zb(a,b,d)}):Zb(a,b,d):void 0},set:function(a,c,d){var e=d&&Jb(a);return Xb(a,c,d?Yb(a,b,d,l.boxSizing()&&"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),l.opacity||(n.cssHooks.opacity={get:function(a,b){return Ob.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=n.isNumeric(b)?"alpha(opacity="+100*b+")":"",f=d&&d.filter||c.filter||"";c.zoom=1,(b>=1||""===b)&&""===n.trim(f.replace(Nb,""))&&c.removeAttribute&&(c.removeAttribute("filter"),""===b||d&&!d.filter)||(c.filter=Nb.test(f)?f.replace(Nb,e):f+" "+e)}}),n.cssHooks.marginRight=Mb(l.reliableMarginRight,function(a,b){return b?n.swap(a,{display:"inline-block"},Kb,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+U[d]+b]=f[d]||f[d-2]||f[0];return e}},Hb.test(a)||(n.cssHooks[a+b].set=Xb)}),n.fn.extend({css:function(a,b){return W(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=Jb(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)
},a,b,arguments.length>1)},show:function(){return Wb(this,!0)},hide:function(){return Wb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){V(this)?n(this).show():n(this).hide()})}});function $b(a,b,c,d,e){return new $b.prototype.init(a,b,c,d,e)}n.Tween=$b,$b.prototype={constructor:$b,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=$b.propHooks[this.prop];return a&&a.get?a.get(this):$b.propHooks._default.get(this)},run:function(a){var b,c=$b.propHooks[this.prop];return this.pos=b=this.options.duration?n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):$b.propHooks._default.set(this),this}},$b.prototype.init.prototype=$b.prototype,$b.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[n.cssProps[a.prop]]||n.cssHooks[a.prop])?n.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},$b.propHooks.scrollTop=$b.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},n.fx=$b.prototype.init,n.fx.step={};var _b,ac,bc=/^(?:toggle|show|hide)$/,cc=new RegExp("^(?:([+-])=|)("+T+")([a-z%]*)$","i"),dc=/queueHooks$/,ec=[jc],fc={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=cc.exec(b),f=e&&e[3]||(n.cssNumber[a]?"":"px"),g=(n.cssNumber[a]||"px"!==f&&+d)&&cc.exec(n.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,n.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function gc(){return setTimeout(function(){_b=void 0}),_b=n.now()}function hc(a,b){var c,d={height:a},e=0;for(b=b?1:0;4>e;e+=2-b)c=U[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function ic(a,b,c){for(var d,e=(fc[b]||[]).concat(fc["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function jc(a,b,c){var d,e,f,g,h,i,j,k,m=this,o={},p=a.style,q=a.nodeType&&V(a),r=n._data(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,m.always(function(){m.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[p.overflow,p.overflowX,p.overflowY],j=n.css(a,"display"),k=Gb(a.nodeName),"none"===j&&(j=k),"inline"===j&&"none"===n.css(a,"float")&&(l.inlineBlockNeedsLayout&&"inline"!==k?p.zoom=1:p.display="inline-block")),c.overflow&&(p.overflow="hidden",l.shrinkWrapBlocks()||m.always(function(){p.overflow=c.overflow[0],p.overflowX=c.overflow[1],p.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],bc.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(q?"hide":"show")){if("show"!==e||!r||void 0===r[d])continue;q=!0}o[d]=r&&r[d]||n.style(a,d)}if(!n.isEmptyObject(o)){r?"hidden"in r&&(q=r.hidden):r=n._data(a,"fxshow",{}),f&&(r.hidden=!q),q?n(a).show():m.done(function(){n(a).hide()}),m.done(function(){var b;n._removeData(a,"fxshow");for(b in o)n.style(a,b,o[b])});for(d in o)g=ic(q?r[d]:0,d,m),d in r||(r[d]=g.start,q&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function kc(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function lc(a,b,c){var d,e,f=0,g=ec.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=_b||gc(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:_b||gc(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(kc(k,j.opts.specialEasing);g>f;f++)if(d=ec[f].call(j,a,k,j.opts))return d;return n.map(k,ic,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(lc,{tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],fc[c]=fc[c]||[],fc[c].unshift(b)},prefilter:function(a,b){b?ec.unshift(a):ec.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(V).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=lc(this,n.extend({},a),f);(e||n._data(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=n._data(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&dc.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=n._data(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(hc(b,!0),a,d,e)}}),n.each({slideDown:hc("show"),slideUp:hc("hide"),slideToggle:hc("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=n.timers,c=0;for(_b=n.now();c<b.length;c++)a=b[c],a()||b[c]!==a||b.splice(c--,1);b.length||n.fx.stop(),_b=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){ac||(ac=setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){clearInterval(ac),ac=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(a,b){return a=n.fx?n.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a,b,c,d,e=z.createElement("div");e.setAttribute("className","t"),e.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",a=e.getElementsByTagName("a")[0],c=z.createElement("select"),d=c.appendChild(z.createElement("option")),b=e.getElementsByTagName("input")[0],a.style.cssText="top:1px",l.getSetAttribute="t"!==e.className,l.style=/top/.test(a.getAttribute("style")),l.hrefNormalized="/a"===a.getAttribute("href"),l.checkOn=!!b.value,l.optSelected=d.selected,l.enctype=!!z.createElement("form").enctype,c.disabled=!0,l.optDisabled=!d.disabled,b=z.createElement("input"),b.setAttribute("value",""),l.input=""===b.getAttribute("value"),b.value="t",b.setAttribute("type","radio"),l.radioValue="t"===b.value,a=b=c=d=e=null}();var mc=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(mc,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.text(a)}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(l.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)if(d=e[g],n.inArray(n.valHooks.option.get(d),f)>=0)try{d.selected=c=!0}catch(h){d.scrollHeight}else d.selected=!1;return c||(a.selectedIndex=-1),e}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>=0:void 0}},l.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var nc,oc,pc=n.expr.attrHandle,qc=/^(?:checked|selected)$/i,rc=l.getSetAttribute,sc=l.input;n.fn.extend({attr:function(a,b){return W(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===L?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),d=n.attrHooks[b]||(n.expr.match.bool.test(b)?oc:nc)),void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=n.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void n.removeAttr(a,b))},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(F);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)?sc&&rc||!qc.test(c)?a[d]=!1:a[n.camelCase("default-"+c)]=a[d]=!1:n.attr(a,c,""),a.removeAttribute(rc?c:d)},attrHooks:{type:{set:function(a,b){if(!l.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),oc={set:function(a,b,c){return b===!1?n.removeAttr(a,c):sc&&rc||!qc.test(c)?a.setAttribute(!rc&&n.propFix[c]||c,c):a[n.camelCase("default-"+c)]=a[c]=!0,c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=pc[b]||n.find.attr;pc[b]=sc&&rc||!qc.test(b)?function(a,b,d){var e,f;return d||(f=pc[b],pc[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,pc[b]=f),e}:function(a,b,c){return c?void 0:a[n.camelCase("default-"+b)]?b.toLowerCase():null}}),sc&&rc||(n.attrHooks.value={set:function(a,b,c){return n.nodeName(a,"input")?void(a.defaultValue=b):nc&&nc.set(a,b,c)}}),rc||(nc={set:function(a,b,c){var d=a.getAttributeNode(c);return d||a.setAttributeNode(d=a.ownerDocument.createAttribute(c)),d.value=b+="","value"===c||b===a.getAttribute(c)?b:void 0}},pc.id=pc.name=pc.coords=function(a,b,c){var d;return c?void 0:(d=a.getAttributeNode(b))&&""!==d.value?d.value:null},n.valHooks.button={get:function(a,b){var c=a.getAttributeNode(b);return c&&c.specified?c.value:void 0},set:nc.set},n.attrHooks.contenteditable={set:function(a,b,c){nc.set(a,""===b?!1:b,c)}},n.each(["width","height"],function(a,b){n.attrHooks[b]={set:function(a,c){return""===c?(a.setAttribute(b,"auto"),c):void 0}}})),l.style||(n.attrHooks.style={get:function(a){return a.style.cssText||void 0},set:function(a,b){return a.style.cssText=b+""}});var tc=/^(?:input|select|textarea|button|object)$/i,uc=/^(?:a|area)$/i;n.fn.extend({prop:function(a,b){return W(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return a=n.propFix[a]||a,this.each(function(){try{this[a]=void 0,delete this[a]}catch(b){}})}}),n.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!n.isXMLDoc(a),f&&(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=n.find.attr(a,"tabindex");return b?parseInt(b,10):tc.test(a.nodeName)||uc.test(a.nodeName)&&a.href?0:-1}}}}),l.hrefNormalized||n.each(["href","src"],function(a,b){n.propHooks[b]={get:function(a){return a.getAttribute(b,4)}}}),l.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this}),l.enctype||(n.propFix.enctype="encoding");var vc=/[\t\r\n\f]/g;n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h=0,i=this.length,j="string"==typeof a&&a;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,this.className))});if(j)for(b=(a||"").match(F)||[];i>h;h++)if(c=this[h],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(vc," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=n.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0,i=this.length,j=0===arguments.length||"string"==typeof a&&a;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,this.className))});if(j)for(b=(a||"").match(F)||[];i>h;h++)if(c=this[h],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(vc," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?n.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(n.isFunction(a)?function(c){n(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=n(this),f=a.match(F)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===L||"boolean"===c)&&(this.className&&n._data(this,"__className__",this.className),this.className=this.className||a===!1?"":n._data(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(vc," ").indexOf(b)>=0)return!0;return!1}}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var wc=n.now(),xc=/\?/,yc=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;n.parseJSON=function(b){if(a.JSON&&a.JSON.parse)return a.JSON.parse(b+"");var c,d=null,e=n.trim(b+"");return e&&!n.trim(e.replace(yc,function(a,b,e,f){return c&&b&&(d=0),0===d?a:(c=e||b,d+=!f-!e,"")}))?Function("return "+e)():n.error("Invalid JSON: "+b)},n.parseXML=function(b){var c,d;if(!b||"string"!=typeof b)return null;try{a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b))}catch(e){c=void 0}return c&&c.documentElement&&!c.getElementsByTagName("parsererror").length||n.error("Invalid XML: "+b),c};var zc,Ac,Bc=/#.*$/,Cc=/([?&])_=[^&]*/,Dc=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Ec=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Fc=/^(?:GET|HEAD)$/,Gc=/^\/\//,Hc=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Ic={},Jc={},Kc="*/".concat("*");try{Ac=location.href}catch(Lc){Ac=z.createElement("a"),Ac.href="",Ac=Ac.href}zc=Hc.exec(Ac.toLowerCase())||[];function Mc(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(F)||[];if(n.isFunction(c))while(d=f[e++])"+"===d.charAt(0)?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Nc(a,b,c,d){var e={},f=a===Jc;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Oc(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(d in b)void 0!==b[d]&&((e[d]?a:c||(c={}))[d]=b[d]);return c&&n.extend(!0,a,c),a}function Pc(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===e&&(e=a.mimeType||b.getResponseHeader("Content-Type"));if(e)for(g in h)if(h[g]&&h[g].test(e)){i.unshift(g);break}if(i[0]in c)f=i[0];else{for(g in c){if(!i[0]||a.converters[g+" "+i[0]]){f=g;break}d||(d=g)}f=f||d}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function Qc(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ac,type:"GET",isLocal:Ec.test(zc[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Kc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Oc(Oc(a,n.ajaxSettings),b):Oc(n.ajaxSettings,a)},ajaxPrefilter:Mc(Ic),ajaxTransport:Mc(Jc),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=n.ajaxSetup({},b),l=k.context||k,m=k.context&&(l.nodeType||l.jquery)?n(l):n.event,o=n.Deferred(),p=n.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!j){j={};while(b=Dc.exec(f))j[b[1].toLowerCase()]=b[2]}b=j[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?f:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return i&&i.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||Ac)+"").replace(Bc,"").replace(Gc,zc[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=n.trim(k.dataType||"*").toLowerCase().match(F)||[""],null==k.crossDomain&&(c=Hc.exec(k.url.toLowerCase()),k.crossDomain=!(!c||c[1]===zc[1]&&c[2]===zc[2]&&(c[3]||("http:"===c[1]?"80":"443"))===(zc[3]||("http:"===zc[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=n.param(k.data,k.traditional)),Nc(Ic,k,b,v),2===t)return v;h=k.global,h&&0===n.active++&&n.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!Fc.test(k.type),e=k.url,k.hasContent||(k.data&&(e=k.url+=(xc.test(e)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=Cc.test(e)?e.replace(Cc,"$1_="+wc++):e+(xc.test(e)?"&":"?")+"_="+wc++)),k.ifModified&&(n.lastModified[e]&&v.setRequestHeader("If-Modified-Since",n.lastModified[e]),n.etag[e]&&v.setRequestHeader("If-None-Match",n.etag[e])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+Kc+"; q=0.01":""):k.accepts["*"]);for(d in k.headers)v.setRequestHeader(d,k.headers[d]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(d in{success:1,error:1,complete:1})v[d](k[d]);if(i=Nc(Jc,k,b,v)){v.readyState=1,h&&m.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,i.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,c,d){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),i=void 0,f=d||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,c&&(u=Pc(k,v,c)),u=Qc(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(n.lastModified[e]=w),w=v.getResponseHeader("etag"),w&&(n.etag[e]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,h&&m.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),h&&(m.trigger("ajaxComplete",[v,k]),--n.active||n.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){if(n.isFunction(a))return this.each(function(b){n(this).wrapAll(a.call(this,b))});if(this[0]){var b=n(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&1===a.firstChild.nodeType)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return this.each(n.isFunction(a)?function(b){n(this).wrapInner(a.call(this,b))}:function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0||!l.reliableHiddenOffsets()&&"none"===(a.style&&a.style.display||n.css(a,"display"))},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var Rc=/%20/g,Sc=/\[\]$/,Tc=/\r?\n/g,Uc=/^(?:submit|button|image|reset|file)$/i,Vc=/^(?:input|select|textarea|keygen)/i;function Wc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||Sc.test(a)?d(a,e):Wc(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Wc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Wc(c,a[c],b,e);return d.join("&").replace(Rc,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&Vc.test(this.nodeName)&&!Uc.test(a)&&(this.checked||!X.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(Tc,"\r\n")}}):{name:b.name,value:c.replace(Tc,"\r\n")}}).get()}}),n.ajaxSettings.xhr=void 0!==a.ActiveXObject?function(){return!this.isLocal&&/^(get|post|head|put|delete|options)$/i.test(this.type)&&$c()||_c()}:$c;var Xc=0,Yc={},Zc=n.ajaxSettings.xhr();a.ActiveXObject&&n(a).on("unload",function(){for(var a in Yc)Yc[a](void 0,!0)}),l.cors=!!Zc&&"withCredentials"in Zc,Zc=l.ajax=!!Zc,Zc&&n.ajaxTransport(function(a){if(!a.crossDomain||l.cors){var b;return{send:function(c,d){var e,f=a.xhr(),g=++Xc;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)void 0!==c[e]&&f.setRequestHeader(e,c[e]+"");f.send(a.hasContent&&a.data||null),b=function(c,e){var h,i,j;if(b&&(e||4===f.readyState))if(delete Yc[g],b=void 0,f.onreadystatechange=n.noop,e)4!==f.readyState&&f.abort();else{j={},h=f.status,"string"==typeof f.responseText&&(j.text=f.responseText);try{i=f.statusText}catch(k){i=""}h||!a.isLocal||a.crossDomain?1223===h&&(h=204):h=j.text?200:404}j&&d(h,i,j,f.getAllResponseHeaders())},a.async?4===f.readyState?setTimeout(b):f.onreadystatechange=Yc[g]=b:b()},abort:function(){b&&b(void 0,!0)}}}});function $c(){try{return new a.XMLHttpRequest}catch(b){}}function _c(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c=z.head||n("head")[0]||z.documentElement;return{send:function(d,e){b=z.createElement("script"),b.async=!0,a.scriptCharset&&(b.charset=a.scriptCharset),b.src=a.url,b.onload=b.onreadystatechange=function(a,c){(c||!b.readyState||/loaded|complete/.test(b.readyState))&&(b.onload=b.onreadystatechange=null,b.parentNode&&b.parentNode.removeChild(b),b=null,c||e(200,"success"))},c.insertBefore(b,c.firstChild)},abort:function(){b&&b.onload(void 0,!0)}}}});var ad=[],bd=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=ad.pop()||n.expando+"_"+wc++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(bd.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&bd.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(bd,"$1"+e):b.jsonp!==!1&&(b.url+=(xc.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,ad.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||z;var d=v.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=n.buildFragment([a],b,e),e&&e.length&&n(e).remove(),n.merge([],d.childNodes))};var cd=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&cd)return cd.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=a.slice(h,a.length),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(f="POST"),g.length>0&&n.ajax({url:a,type:f,dataType:"html",data:b}).done(function(a){e=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,e||[a.responseText,b,a])}),this},n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};var dd=a.document.documentElement;function ed(a){return n.isWindow(a)?a:9===a.nodeType?a.defaultView||a.parentWindow:!1}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&n.inArray("auto",[f,i])>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d={top:0,left:0},e=this[0],f=e&&e.ownerDocument;if(f)return b=f.documentElement,n.contains(b,e)?(typeof e.getBoundingClientRect!==L&&(d=e.getBoundingClientRect()),c=ed(f),{top:d.top+(c.pageYOffset||b.scrollTop)-(b.clientTop||0),left:d.left+(c.pageXOffset||b.scrollLeft)-(b.clientLeft||0)}):d},position:function(){if(this[0]){var a,b,c={top:0,left:0},d=this[0];return"fixed"===n.css(d,"position")?b=d.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(c=a.offset()),c.top+=n.css(a[0],"borderTopWidth",!0),c.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-c.top-n.css(d,"marginTop",!0),left:b.left-c.left-n.css(d,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||dd;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||dd})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c=/Y/.test(b);n.fn[a]=function(d){return W(this,function(a,d,e){var f=ed(a);return void 0===e?f?b in f?f[b]:f.document.documentElement[d]:a[d]:void(f?f.scrollTo(c?n(f).scrollLeft():e,c?e:n(f).scrollTop()):a[d]=e)},a,d,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=Mb(l.pixelPosition,function(a,c){return c?(c=Kb(a,b),Ib.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return W(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var fd=a.jQuery,gd=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=gd),b&&a.jQuery===n&&(a.jQuery=fd),n},typeof b===L&&(a.jQuery=a.$=n),n});
/*!
* ====================================================
* Kity Formula Parser - v1.0.0 - 2014-07-31
* https://github.com/HanCong03/kityformula-editor
* GitHub: https://github.com/kitygraph/kityformula-editor.git
* Copyright (c) 2014 Baidu Kity Group; Licensed MIT
* ====================================================
*/
!function(){function a(a){b.r([c[a]])}var b={r:function(a){if(b[a].inited)return b[a].value;if("function"!=typeof b[a].value)return b[a].inited=!0,b[a].value;var c={exports:{}},d=b[a].value(null,c.exports,c);if(b[a].inited=!0,b[a].value=d,void 0!==d)return d;for(var e in c.exports)if(c.exports.hasOwnProperty(e))return b[a].inited=!0,b[a].value=c.exports,c.exports}};b[0]={value:function(){function a(a){this.formula=a}function b(a,e,f,g,i){var j,k=null,l=null,m=[],n=e.operand||[],o=null;if(f.operand=[],-1===e.name.indexOf("text")){for(var p=0,q=n.length;q>p;p++)k=n[p],k!==h?k?"string"==typeof k?(n[p]="brackets"===e.name&&2>p?k:"function"===e.name&&0===p?k:c("text",k),f.operand.push(n[p])):(f.operand.push({}),n[p]=b(a.operand[p],k,f.operand[f.operand.length-1],g,i)):(n[p]=c("empty"),f.operand.push(n[p])):(m.push(p),i.hasOwnProperty("startOffset")||(i.startOffset=p),i.endOffset=p,e.attr&&e.attr.id&&(i.groupId=e.attr.id));for(2===m.length&&(i.endOffset-=1);p=m.length;)p=m[p-1],n.splice(p,1),m.length--,a.operand.splice(p,1)}if(o=d(e.name),!o)throw new Error("operator type error: not found "+e.operator);j=function(){},j.prototype=o.prototype,l=new j,o.apply(l,n),f.func=l;for(var r in e.callFn)e.callFn.hasOwnProperty(r)&&l[r]&&l[r].apply(l,e.callFn[r]);return e.attr&&(e.attr.id&&(g[e.attr.id]={objGroup:l,strGroup:a}),e.attr["data-root"]&&(g.root={objGroup:l,strGroup:a}),l.setAttr(e.attr)),l}function c(a,b){switch(a){case"empty":return new kf.EmptyExpression;case"text":return new kf.TextExpression(b)}}function d(a){return g[a]||kf[a.replace(/^[a-z]/i,function(a){return a.toUpperCase()}).replace(/-([a-z])/gi,function(a,b){return b.toUpperCase()})+"Expression"]}function e(a){var b={};if("[object Array]"==={}.toString.call(a)){b=[];for(var c=0,d=a.length;d>c;c++)b[c]=f(a[c])}else for(var e in a)a.hasOwnProperty(e)&&(b[e]=f(a[e]));return b}function f(a){return a?"object"!=typeof a?a:e(a):a}var g={},h="\uf155";return a.prototype.generateBy=function(a){var c=a.tree,d={},f={},g={};if("string"==typeof c)throw new Error("Unhandled error");return this.formula.appendExpression(b(c,e(c),d,g,f)),{select:f,parsedTree:c,tree:d,mapping:g}},a.prototype.regenerateBy=function(a){return this.formula.clearExpressions(),this.generateBy(a)},a}},b[1]={value:function(){return{toRPNExpression:b.r(2),generateTree:b.r(3)}}},b[2]={value:function(){function a(b){var e=[],f=null;for(b=c(b);f=b.shift();)"combination"===f.name&&1===f.operand.length&&"brackets"===f.operand[0].name&&(f=f.operand[0]),e.push(d.isArray(f)?a(f):f);return e}function c(a){for(var b=[],c=null;void 0!==(c=a.pop());)if(!c||"object"!=typeof c||c.sign!==!1&&"function"!==c.name)b.push(c);else{var d=c.handler(c,[],b.reverse());b.unshift(d),b.reverse()}return b.reverse()}var d=b.r(4);return a}},b[3]={value:function(){function a(b){for(var e=null,f=[],g=0,h=b.length;h>g;g++)d.isArray(b[g])&&(b[g]=a(b[g]));for(;e=b.shift();)f.push("object"==typeof e&&e.handler?e.handler(e,f,b):e);return c(f)}var c=b.r(13),d=b.r(4);return a}},b[4]={value:function(){var a=b.r(7),c=b.r(6),d=b.r(15),e={getLatexType:function(b){return b=b.replace(/^\\/,""),a[b]?"operator":c[b]?"function":"text"},isArray:function(a){return a&&"[object Array]"===Object.prototype.toString.call(a)},getDefine:function(b){return e.extend({},a[b.replace("\\","")])},getFuncDefine:function(a){return{name:"function",params:a.replace(/^\\/,""),handler:d}},getBracketsDefine:function(b,c){return e.extend({params:[b,c]},a.brackets)},extend:function(a,b){for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);return a}};return e}},b[5]={value:function(){var a=!0;return{".":a,"{":a,"}":a,"[":a,"]":a,"(":a,")":a,"|":a}}},b[6]={value:function(){return{sin:1,cos:1,arccos:1,cosh:1,det:1,inf:1,limsup:1,Pr:1,tan:1,arcsin:1,cot:1,dim:1,ker:1,ln:1,sec:1,tanh:1,arctan:1,coth:1,exp:1,lg:1,log:1,arg:1,csc:1,gcd:1,lim:1,max:1,sinh:1,deg:1,hom:1,liminf:1,min:1,sup:1}}},b[7]={value:function(){var a=b.r(22),c=b.r(11);return{"^":{name:"superscript",type:c.OP,handler:a},_:{name:"subscript",type:c.OP,handler:a},frac:{name:"fraction",type:c.FN,sign:!1,handler:b.r(14)},sqrt:{name:"radical",type:c.FN,sign:!1,handler:b.r(23)},sum:{name:"summation",type:c.FN,traversal:"rtl",handler:b.r(24)},"int":{name:"integration",type:c.FN,traversal:"rtl",handler:b.r(16)},brackets:{name:"brackets",type:c.FN,handler:b.r(12)},mathcal:{name:"mathcal",type:c.FN,sign:!1,handler:b.r(19)},mathfrak:{name:"mathfrak",type:c.FN,sign:!1,handler:b.r(20)},mathbb:{name:"mathbb",type:c.FN,sign:!1,handler:b.r(18)},mathrm:{name:"mathrm",type:c.FN,sign:!1,handler:b.r(21)}}}},b[8]={value:function(){return{"int":b.r(26),quot:b.r(27)}}},b[9]={value:function(){return{combination:b.r(29),fraction:b.r(30),"function":b.r(31),integration:b.r(32),subscript:b.r(39),superscript:b.r(41),script:b.r(37),radical:b.r(38),summation:b.r(40),brackets:b.r(28),mathcal:b.r(34),mathfrak:b.r(35),mathbb:b.r(33),mathrm:b.r(36)}}},b[10]={value:function(){return{"#":1,$:1,"%":1,_:1,"&":1,"{":1,"}":1,"^":1,"~":1}}},b[11]={value:function(){return{OP:1,FN:2}}},b[12]={value:function(){var a=b.r(5);return function(b,c,d){for(var e=0,f=b.params.length;f>e;e++)if(!(b.params[e]in a))throw new Error("Brackets: invalid params");return b.operand=b.params,b.params[2]=d.shift(),delete b.handler,delete b.params,b}}},b[13]={value:function(){return function(){return{name:"combination",operand:arguments[0]||[]}}}},b[14]={value:function(){return function(a,b,c){var d=c.shift(),e=c.shift();if(void 0===d||void 0===e)throw new Error("Frac: Syntax Error");return d.handler&&"integration"===d.name?(d=d.handler(d,b,[e]),e=c.shift()):e.handler&&"integration"===e.name&&(e=e.handler(e,b,[c.shift()])),a.operand=[d,e],delete a.handler,a}}},b[15]={value:function(){var a=b.r(17);return function(b,c,d){var e=a.exec(d);return e.expr&&e.expr.handler&&"integration"===e.expr.name&&(e.expr=e.expr.handler(e.expr,c,[d.shift()])),b.operand=[b.params,e.expr,e.superscript,e.subscript],delete b.params,delete b.handler,b}}},b[16]={value:function(){var a=b.r(17),c=b.r(11).FN;return function(b,d,e){var f=e.shift(),g=a.exec(e);return g.expr&&g.expr.type===c&&g.expr.handler&&"integration"===g.expr.name&&(g.expr=g.expr.handler(g.expr,d,[e.shift()])),b.operand=[g.expr,g.superscript,g.subscript],b.callFn={setType:[0|f]},delete b.handler,b}}},b[17]={value:function(){function a(a){var c=b(a),d=null,e={superscript:null,subscript:null};if(!c)return e;if(d=b(a),e[c.type]=c.value||null,d){if(d.type===c.type)throw new Error("Script: syntax error!");e[d.type]=d.value||null}return e}function b(a){var b=a.shift();return b?"subscript"===b.name||"superscript"===b.name?{type:b.name,value:a.shift()}:(a.unshift(b),null):null}return{exec:function(b){var c=a(b),d=b.shift();if(d&&d.name&&-1!==d.name.indexOf("script"))throw new Error("Script: syntax error!");return c.expr=d||null,c}}}},b[18]={value:function(){return function(a,b,c){var d=c.shift();return"object"==typeof d&&"combination"===d.name&&(d=d.operand.join("")),a.name="text",a.attr={_reverse:"mathbb"},a.callFn={setFamily:["KF AMS BB"]},a.operand=[d],delete a.handler,a}}},b[19]={value:function(){return function(a,b,c){var d=c.shift();return"object"==typeof d&&"combination"===d.name&&(d=d.operand.join("")),a.name="text",a.attr={_reverse:"mathcal"},a.callFn={setFamily:["KF AMS CAL"]},a.operand=[d],delete a.handler,a}}},b[20]={value:function(){return function(a,b,c){var d=c.shift();return"object"==typeof d&&"combination"===d.name&&(d=d.operand.join("")),a.name="text",a.attr={_reverse:"mathfrak"},a.callFn={setFamily:["KF AMS FRAK"]},a.operand=[d],delete a.handler,a}}},b[21]={value:function(){return function(a,b,c){var d=c.shift();return"object"==typeof d&&"combination"===d.name&&(d=d.operand.join("")),a.name="text",a.attr={_reverse:"mathrm"},a.callFn={setFamily:["KF AMS ROMAN"]},a.operand=[d],delete a.handler,a}}},b[22]={value:function(){return function(a,b,c){var d=b.pop(),e=c.shift()||null;if(!e)throw new Error("Missing script");if(d=d||"",d.name===a.name||"script"===d.name)throw new Error("script error");return"subscript"===d.name?(d.name="script",d.operand[2]=d.operand[1],d.operand[1]=e,d):"superscript"===d.name?(d.name="script",d.operand[2]=e,d):(a.operand=[d,e],delete a.handler,a)}}},b[23]={value:function(){var a=b.r(13);return function(b,c,d){var e=d.shift(),f=null,g=null;if("["===e){for(e=[];(f=d.shift())&&"]"!==f;)e.push(f);e=0===e.length?null:a(e),g=d.shift()}else g=e,e=null;return b.operand=[g,e],delete b.handler,b}}},b[24]={value:function(){var a=b.r(17),c=b.r(11).FN;return function(b,d,e){var f=a.exec(e);return f.expr&&f.expr.type===c&&f.expr.handler&&"integration"===f.expr.name&&(f.expr=f.expr.handler(f.expr,d,[e.shift()])),b.operand=[f.expr,f.superscript,f.subscript],delete b.handler,b}}},b[25]={value:function(){function a(a){if(d(a))return a.substring(1);switch(m.getLatexType(a)){case"operator":return m.getDefine(a);case"function":return m.getFuncDefine(a);default:return c(a)}}function c(a){return 0===a.indexOf("\\")?a+"\\":a}function d(a){return 0===a.indexOf("\\")?!!l[a.substring(1)]:!1}function e(a){return a.replace(/\\\s+/,"").replace(/\s*([^a-z0-9\s])\s*/gi,function(a,b){return b})}var f=b.r(43).Parser,g=b.r(1),h=b.r(8),i=b.r(42),j=b.r(7),k=b.r(9),l=b.r(10),m=b.r(4),n="\ufff8",o="\ufffc",p=new RegExp(n+"|"+o,"g"),q=new RegExp(n,"g"),r=new RegExp(o,"g");f.register("latex",f.implement({parse:function(a){var b=this.split(this.format(a));return b=this.parseToGroup(b),b=this.parseToStruct(b),this.generateTree(b)},serialization:function(a,b){return i(a,b)},expand:function(a){var b=a.parse,c=null,d=a.pre,e=a.reverse;for(var f in b)b.hasOwnProperty(f)&&(c=f.replace(/\\/g,""),j[c]=b[f]);for(var f in e)e.hasOwnProperty(f)&&(k[f.replace(/\\/g,"")]=e[f]);if(d)for(var f in d)d.hasOwnProperty(f)&&(h[f.replace(/\\/g,"")]=d[f])},format:function(a){a=e(a),a=a.replace(p,"").replace(/\\{/gi,n).replace(/\\}/gi,o);for(var b in h)h.hasOwnProperty(b)&&(a=h[b](a));return a},split:function(a){var b=[],c=/(?:\\[^a-z]\s*)|(?:\\[a-z]+\s*)|(?:[{}]\s*)|(?:[^\\{}]\s*)/gi,d=/^\s+|\s+$/g,e=null;for(a=a.replace(d,"");e=c.exec(a);)e=e[0].replace(d,""),e&&b.push(e);return b},generateTree:function(a){for(var b=[],c=null;c=a.shift();)b.push(m.isArray(c)?this.generateTree(c):c);return b=g.toRPNExpression(b),g.generateTree(b)},parseToGroup:function(a){for(var b=[],c=[b],d=0,e=0,f=0,g=a.length;g>f;f++)switch(a[f]){case"{":d++,c.push(b),b.push([]),b=b[b.length-1];break;case"}":d--,b=c.pop();break;case"\\left":e++,c.push(b),b.push([[]]),b=b[b.length-1][0],b.type="brackets",f++,b.leftBrackets=a[f].replace(q,"{").replace(r,"}");break;case"\\right":e--,f++,b.rightBrackets=a[f].replace(q,"{").replace(r,"}"),b=c.pop();break;default:b.push(a[f].replace(q,"\\{").replace(r,"\\}"))}if(0!==d)throw new Error("Group Error!");if(0!==e)throw new Error("Brackets Error!");return c[0]},parseToStruct:function(b){for(var c=[],d=0,e=b.length;e>d;d++)m.isArray(b[d])?"brackets"===b[d].type?(c.push(m.getBracketsDefine(b[d].leftBrackets,b[d].rightBrackets)),c.push(this.parseToStruct(b[d]))):c.push(this.parseToStruct(b[d])):c.push(a(b[d]));return c}}))}},b[26]={value:function(){return function(a){return a.replace(/\\(i+)nt(\b|[^a-zA-Z])/g,function(a,b,c){return"\\int "+b.length+c})}}},b[27]={value:function(){return function(a){return a.replace(/``/g,"\u201c")}}},b[28]={value:function(){return function(a){return("{"===a[0]||"}"===a[0])&&(a[0]="\\"+a[0]),("{"===a[1]||"}"===a[1])&&(a[1]="\\"+a[1]),["\\left",a[0],a[2],"\\right",a[1]].join(" ")}}},b[29]={value:function(){return function(a){return this.attr["data-root"]||this.attr["data-placeholder"]?a.join(""):"{"+a.join("")+"}"}}},b[30]={value:function(){return function(a){return"\\frac "+a[0]+" "+a[1]}}},b[31]={value:function(){return function(a){var b=["\\"+a[0]];return a[2]&&b.push("^"+a[2]),a[3]&&b.push("_"+a[3]),a[1]&&b.push(" "+a[1]),b.join("")}}},b[32]={value:function(){return function(a){var b=["\\int "];if(this.callFn&&this.callFn.setType){b=["\\"];for(var c=0,d=this.callFn.setType;d>c;c++)b.push("i");b.push("nt ")}return a[1]&&b.push("^"+a[1]),a[2]&&b.push("_"+a[2]),a[0]&&b.push(" "+a[0]),b.join("")}}},b[33]={value:function(){return function(a){return"\\mathbb{"+a[0]+"}"}}},b[34]={value:function(){return function(a){return"\\mathcal{"+a[0]+"}"}}},b[35]={value:function(){return function(a){return"\\mathfrak{"+a[0]+"}"}}},b[36]={value:function(){return function(a){return"\\mathrm{"+a[0]+"}"}}},b[37]={value:function(){return function(a){return a[0]+"^"+a[1]+"_"+a[2]}}},b[38]={value:function(){return function(a){var b=["\\sqrt"];return a[1]&&b.push("["+a[1]+"]"),b.push(" "+a[0]),b.join("")}}},b[39]={value:function(){return function(a){return a[0]+"_"+a[1]}}},b[40]={value:function(){return function(a){var b=["\\sum "];return a[1]&&b.push("^"+a[1]),a[2]&&b.push("_"+a[2]),a[0]&&b.push(" "+a[0]),b.join("")}}},b[41]={value:function(){return function(a){return a[0]+"^"+a[1]}}},b[42]={value:function(){function a(b,e){var g=[],h=null,i=null;if("object"!=typeof b)return c(b)?"\\"+b+" ":b.replace(f,function(a,b){return b+" "});"combination"===b.name&&1===b.operand.length&&"combination"===b.operand[0].name&&(b=b.operand[0]),i=b.operand;for(var j=0,k=i.length;k>j;j++)g.push(i[j]?a(i[j]):i[j]);return h=b.attr&&b.attr._reverse?b.attr._reverse:b.name,d[h].call(b,g,e)}function c(a){return!!e[a]}var d=b.r(9),e=b.r(10),f=/(\\(?:[\w]+)|(?:[^a-z]))\\/gi;return function(b,c){return a(b,c)}}},b[43]={value:function(a,b,c){function d(a){this.impl=new a,this.conf={}}function e(){this.conf={}}var f={},g={},h={extend:function(a,b){var c=null;b=[].slice.call(arguments,1);for(var d=0,e=b.length;e>d;d++){c=b[d];for(var f in c)c.hasOwnProperty(f)&&(a[f]=c[f])}},setData:function(a,b,c){if("string"==typeof b)a[b]=c;else{if("object"!=typeof b)throw new Error("invalid option");for(c in b)b.hasOwnProperty(c)&&(a[c]=b[c])}}},i={use:function(a){if(!g[a])throw new Error("unknown parser type");return this.proxy(g[a])},config:function(a,b){return h.setData(f,a,b),this},register:function(a,b){return g[a.toLowerCase()]=b,this},implement:function(a){var b=function(){},c=a.constructor||function(){},d=function(){e.call(this),c.call(this)};b.prototype=e.prototype,d.prototype=new b,delete a.constructor;for(var f in a)"constructor"!==f&&a.hasOwnProperty(f)&&(d.prototype[f]=a[f]);return d},proxy:function(a){return new d(a)}};h.extend(d.prototype,{config:function(a,b){h.setData(this.conf,a,b)},set:function(a,b){this.impl.set(a,b)},parse:function(a){var b={config:{},tree:this.impl.parse(a)};return h.extend(b.config,f,this.conf),b},serialization:function(a,b){return this.impl.serialization(a,b)},expand:function(a){this.impl.expand(a)}}),h.extend(e.prototype,{set:function(a,b){h.extend(this.conf,a,b)},parse:function(){throw new Error("Abstract function")}}),c.exports={Parser:i,ParserInterface:e}}},b[44]={value:function(){var a=b.r(43).Parser;b.r(25),window.kf.Parser=a,window.kf.Assembly=b.r(0)}};var c={"kf.start":44};!function(){try{a("kf.start")}catch(b){}}(this)}();
\ No newline at end of file
!function(){var f={r:function(t){if(f[t].inited)return f[t].value;if("function"!=typeof f[t].value)return f[t].inited=!0,f[t].value;var e={exports:{}},i=f[t].value(null,e.exports,e);if(f[t].inited=!0,void 0!==(f[t].value=i))return i;for(var n in e.exports)if(e.exports.hasOwnProperty(n))return f[t].inited=!0,f[t].value=e.exports,e.exports}};f[0]={value:function(t){function p(t){this.ok=!1,"#"==t.charAt(0)&&(t=t.substr(1,6)),t=(t=t.replace(/ /g,"")).toLowerCase();var u={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};for(var e in u)t==e&&(t=u[e]);for(var c=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,example:["rgb(123, 234, 45)","rgb(255,234,245)"],process:function(t){return[parseInt(t[1]),parseInt(t[2]),parseInt(t[3])]}},{re:/^(\w{2})(\w{2})(\w{2})$/,example:["#00ff00","336699"],process:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,example:["#fb0","f0f"],process:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}}],i=0;i<c.length;i++){var n=c[i].re,r=c[i].process,s=n.exec(t);s&&(channels=r(s),this.r=channels[0],this.g=channels[1],this.b=channels[2],this.ok=!0)}this.r=this.r<0||isNaN(this.r)?0:255<this.r?255:this.r,this.g=this.g<0||isNaN(this.g)?0:255<this.g?255:this.g,this.b=this.b<0||isNaN(this.b)?0:255<this.b?255:this.b,this.toRGB=function(){return"rgb("+this.r+", "+this.g+", "+this.b+")"},this.toHex=function(){var t=this.r.toString(16),e=this.g.toString(16),i=this.b.toString(16);return 1==t.length&&(t="0"+t),1==e.length&&(e="0"+e),1==i.length&&(i="0"+i),"#"+t+e+i},this.getHelpXML=function(){for(var t=new Array,e=0;e<c.length;e++)for(var i=c[e].example,n=0;n<i.length;n++)t[t.length]=i[n];for(var r in u)t[t.length]=r;var s=document.createElement("ul");s.setAttribute("id","rgbcolor-examples");for(e=0;e<t.length;e++)try{var a=document.createElement("li"),o=new p(t[e]),h=document.createElement("div");h.style.cssText="margin: 3px; border: 1px solid black; background:"+o.toHex()+"; color:"+o.toHex(),h.appendChild(document.createTextNode("test"));var l=document.createTextNode(" "+t[e]+" -> "+o.toRGB()+" -> "+o.toHex());a.appendChild(h),a.appendChild(l),s.appendChild(a)}catch(t){}return s}}var W=[512,512,456,512,328,456,335,512,405,328,271,456,388,335,292,512,454,405,364,328,298,271,496,456,420,388,360,335,312,292,273,512,482,454,428,405,383,364,345,328,312,298,284,271,259,496,475,456,437,420,404,388,374,360,347,335,323,312,302,292,282,273,265,512,497,482,468,454,441,428,417,405,394,383,373,364,354,345,337,328,320,312,305,298,291,284,278,271,265,259,507,496,485,475,465,456,446,437,428,420,412,404,396,388,381,374,367,360,354,347,341,335,329,323,318,312,307,302,297,292,287,282,278,273,269,265,261,512,505,497,489,482,475,468,461,454,447,441,435,428,422,417,411,405,399,394,389,383,378,373,368,364,359,354,350,345,341,337,332,328,324,320,316,312,309,305,301,298,294,291,287,284,281,278,274,271,268,265,262,259,257,507,501,496,491,485,480,475,470,465,460,456,451,446,442,437,433,428,424,420,416,412,408,404,400,396,392,388,385,381,377,374,370,367,363,360,357,354,350,347,344,341,338,335,332,329,326,323,320,318,315,312,310,307,304,302,299,297,294,292,289,287,285,282,280,278,275,273,271,269,267,265,263,261,259],$=[9,11,12,13,13,14,14,15,15,15,15,16,16,16,16,17,17,17,17,17,17,17,18,18,18,18,18,18,18,18,18,19,19,19,19,19,19,19,19,19,19,19,19,19,19,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24];function c(t,e,i,n,r,s){if(!(isNaN(s)||s<1)){s|=0;var a,o=document.getElementById(t).getContext("2d");try{try{a=o.getImageData(e,i,n,r)}catch(t){try{netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead"),a=o.getImageData(e,i,n,r)}catch(t){throw alert("Cannot access local image"),new Error("unable to access local image data: "+t)}}}catch(t){throw alert("Cannot access image"),new Error("unable to access image data: "+t)}var h,l,u,c,p,f,d,x,g,m,y,b,v,w,E,P,B,S,C,M,k,T,O,V,R=a.data,A=s+s+1,F=n-1,q=r-1,N=s+1,D=N*(N+1)/2,z=new j,I=z;for(u=1;u<A;u++)if(I=I.next=new j,u==N)var L=I;I.next=z;var H=null,U=null;d=f=0;var X=W[s],G=$[s];for(l=0;l<r;l++){for(P=B=S=C=x=g=m=y=0,b=N*(M=R[f]),v=N*(k=R[f+1]),w=N*(T=R[f+2]),E=N*(O=R[f+3]),x+=D*M,g+=D*k,m+=D*T,y+=D*O,I=z,u=0;u<N;u++)I.r=M,I.g=k,I.b=T,I.a=O,I=I.next;for(u=1;u<N;u++)c=f+((F<u?F:u)<<2),x+=(I.r=M=R[c])*(V=N-u),g+=(I.g=k=R[c+1])*V,m+=(I.b=T=R[c+2])*V,y+=(I.a=O=R[c+3])*V,P+=M,B+=k,S+=T,C+=O,I=I.next;for(H=z,U=L,h=0;h<n;h++)R[f+3]=O=y*X>>G,0!=O?(O=255/O,R[f]=(x*X>>G)*O,R[f+1]=(g*X>>G)*O,R[f+2]=(m*X>>G)*O):R[f]=R[f+1]=R[f+2]=0,x-=b,g-=v,m-=w,y-=E,b-=H.r,v-=H.g,w-=H.b,E-=H.a,c=d+((c=h+s+1)<F?c:F)<<2,x+=P+=H.r=R[c],g+=B+=H.g=R[c+1],m+=S+=H.b=R[c+2],y+=C+=H.a=R[c+3],H=H.next,b+=M=U.r,v+=k=U.g,w+=T=U.b,E+=O=U.a,P-=M,B-=k,S-=T,C-=O,U=U.next,f+=4;d+=n}for(h=0;h<n;h++){for(B=S=C=P=g=m=y=x=0,b=N*(M=R[f=h<<2]),v=N*(k=R[f+1]),w=N*(T=R[f+2]),E=N*(O=R[f+3]),x+=D*M,g+=D*k,m+=D*T,y+=D*O,I=z,u=0;u<N;u++)I.r=M,I.g=k,I.b=T,I.a=O,I=I.next;for(p=n,u=1;u<=s;u++)f=p+h<<2,x+=(I.r=M=R[f])*(V=N-u),g+=(I.g=k=R[f+1])*V,m+=(I.b=T=R[f+2])*V,y+=(I.a=O=R[f+3])*V,P+=M,B+=k,S+=T,C+=O,I=I.next,u<q&&(p+=n);for(f=h,H=z,U=L,l=0;l<r;l++)R[(c=f<<2)+3]=O=y*X>>G,0<O?(O=255/O,R[c]=(x*X>>G)*O,R[c+1]=(g*X>>G)*O,R[c+2]=(m*X>>G)*O):R[c]=R[c+1]=R[c+2]=0,x-=b,g-=v,m-=w,y-=E,b-=H.r,v-=H.g,w-=H.b,E-=H.a,c=h+((c=l+N)<q?c:q)*n<<2,x+=P+=H.r=R[c],g+=B+=H.g=R[c+1],m+=S+=H.b=R[c+2],y+=C+=H.a=R[c+3],H=H.next,b+=M=U.r,v+=k=U.g,w+=T=U.b,E+=O=U.a,P-=M,B-=k,S-=T,C-=O,U=U.next,f+=n}o.putImageData(a,e,i)}}function j(){this.r=0,this.g=0,this.b=0,this.a=0,this.next=null}return function(){this.canvg=function(t,e,n){if(null!=t||null!=e||null!=n){n=n||{},"string"==typeof t&&(t=document.getElementById(t)),null!=t.svg&&t.svg.stop();var R,r=((R={FRAMERATE:30,MAX_VIRTUAL_PIXELS:3e4}).init=function(t){var e=0;R.UniqueId=function(){return"canvg"+ ++e},R.Definitions={},R.Styles={},R.Animations=[],R.Images=[],R.ctx=t,R.ViewPort=new function(){this.viewPorts=[],this.Clear=function(){this.viewPorts=[]},this.SetCurrent=function(t,e){this.viewPorts.push({width:t,height:e})},this.RemoveCurrent=function(){this.viewPorts.pop()},this.Current=function(){return this.viewPorts[this.viewPorts.length-1]},this.width=function(){return this.Current().width},this.height=function(){return this.Current().height},this.ComputeSize=function(t){return null!=t&&"number"==typeof t?t:"x"==t?this.width():"y"==t?this.height():Math.sqrt(Math.pow(this.width(),2)+Math.pow(this.height(),2))/Math.sqrt(2)}}},R.init(),R.ImagesLoaded=function(){for(var t=0;t<R.Images.length;t++)if(!R.Images[t].loaded)return!1;return!0},R.trim=function(t){return t.replace(/^\s+|\s+$/g,"")},R.compressSpaces=function(t){return t.replace(/[\s\r\t\n]+/gm," ")},R.ajax=function(t){var e;return(e=window.XMLHttpRequest?new XMLHttpRequest:new ActiveXObject("Microsoft.XMLHTTP"))?(e.open("GET",t,!1),e.send(null),e.responseText):null},R.parseXml=function(t){if(window.DOMParser)return(new DOMParser).parseFromString(t,"text/xml");t=t.replace(/<!DOCTYPE svg[^>]*>/,"");var e=new ActiveXObject("Microsoft.XMLDOM");return e.async="false",e.loadXML(t),e},R.Property=function(t,e){this.name=t,this.value=e},R.Property.prototype.getValue=function(){return this.value},R.Property.prototype.hasValue=function(){return null!=this.value&&""!==this.value},R.Property.prototype.numValue=function(){if(!this.hasValue())return 0;var t=parseFloat(this.value);return(this.value+"").match(/%$/)&&(t/=100),t},R.Property.prototype.valueOrDefault=function(t){return this.hasValue()?this.value:t},R.Property.prototype.numValueOrDefault=function(t){return this.hasValue()?this.numValue():t},R.Property.prototype.addOpacity=function(t){var e=this.value;if(null!=t&&""!=t&&"string"==typeof this.value){var i=new p(this.value);i.ok&&(e="rgba("+i.r+", "+i.g+", "+i.b+", "+t+")")}return new R.Property(this.name,e)},R.Property.prototype.getDefinition=function(){var t=this.value.match(/#([^\)'"]+)/);return t=(t=t&&t[1])||this.value,R.Definitions[t]},R.Property.prototype.isUrlDefinition=function(){return 0==this.value.indexOf("url(")},R.Property.prototype.getFillStyleDefinition=function(t,e){var i=this.getDefinition();if(null!=i&&i.createGradient)return i.createGradient(R.ctx,t,e);if(null!=i&&i.createPattern){if(i.getHrefAttribute().hasValue()){var n=i.attribute("patternTransform");i=i.getHrefAttribute().getDefinition(),n.hasValue()&&(i.attribute("patternTransform",!0).value=n.value)}return i.createPattern(R.ctx,t)}return null},R.Property.prototype.getDPI=function(t){return 96},R.Property.prototype.getEM=function(t){var e=12,i=new R.Property("fontSize",R.Font.Parse(R.ctx.font).fontSize);return i.hasValue()&&(e=i.toPixels(t)),e},R.Property.prototype.getUnits=function(){return(this.value+"").replace(/[0-9\.\-]/g,"")},R.Property.prototype.toPixels=function(t,e){if(!this.hasValue())return 0;var i=this.value+"";if(i.match(/em$/))return this.numValue()*this.getEM(t);if(i.match(/ex$/))return this.numValue()*this.getEM(t)/2;if(i.match(/px$/))return this.numValue();if(i.match(/pt$/))return this.numValue()*this.getDPI(t)*(1/72);if(i.match(/pc$/))return 15*this.numValue();if(i.match(/cm$/))return this.numValue()*this.getDPI(t)/2.54;if(i.match(/mm$/))return this.numValue()*this.getDPI(t)/25.4;if(i.match(/in$/))return this.numValue()*this.getDPI(t);if(i.match(/%$/))return this.numValue()*R.ViewPort.ComputeSize(t);var n=this.numValue();return e&&n<1?n*R.ViewPort.ComputeSize(t):n},R.Property.prototype.toMilliseconds=function(){if(!this.hasValue())return 0;var t=this.value+"";return t.match(/s$/)?1e3*this.numValue():(t.match(/ms$/),this.numValue())},R.Property.prototype.toRadians=function(){if(!this.hasValue())return 0;var t=this.value+"";return t.match(/deg$/)?this.numValue()*(Math.PI/180):t.match(/grad$/)?this.numValue()*(Math.PI/200):t.match(/rad$/)?this.numValue():this.numValue()*(Math.PI/180)},R.Font=new function(){this.Styles="normal|italic|oblique|inherit",this.Variants="normal|small-caps|inherit",this.Weights="normal|bold|bolder|lighter|100|200|300|400|500|600|700|800|900|inherit",this.CreateFont=function(t,e,i,n,r,s){var a=null!=s?this.Parse(s):this.CreateFont("","","","","",R.ctx.font);return{fontFamily:r||a.fontFamily,fontSize:n||a.fontSize,fontStyle:t||a.fontStyle,fontWeight:i||a.fontWeight,fontVariant:e||a.fontVariant,toString:function(){return[this.fontStyle,this.fontVariant,this.fontWeight,this.fontSize,this.fontFamily].join(" ")}}};var a=this;this.Parse=function(t){for(var e={},i=R.trim(R.compressSpaces(t||"")).split(" "),n={fontSize:!1,fontStyle:!1,fontWeight:!1,fontVariant:!1},r="",s=0;s<i.length;s++)n.fontStyle||-1==a.Styles.indexOf(i[s])?n.fontVariant||-1==a.Variants.indexOf(i[s])?n.fontWeight||-1==a.Weights.indexOf(i[s])?n.fontSize?"inherit"!=i[s]&&(r+=i[s]):("inherit"!=i[s]&&(e.fontSize=i[s].split("/")[0]),n.fontStyle=n.fontVariant=n.fontWeight=n.fontSize=!0):("inherit"!=i[s]&&(e.fontWeight=i[s]),n.fontStyle=n.fontVariant=n.fontWeight=!0):("inherit"!=i[s]&&(e.fontVariant=i[s]),n.fontStyle=n.fontVariant=!0):("inherit"!=i[s]&&(e.fontStyle=i[s]),n.fontStyle=!0);return""!=r&&(e.fontFamily=r),e}},R.ToNumberArray=function(t){for(var e=R.trim(R.compressSpaces((t||"").replace(/,/g," "))).split(" "),i=0;i<e.length;i++)e[i]=parseFloat(e[i]);return e},R.Point=function(t,e){this.x=t,this.y=e},R.Point.prototype.angleTo=function(t){return Math.atan2(t.y-this.y,t.x-this.x)},R.Point.prototype.applyTransform=function(t){var e=this.x*t[0]+this.y*t[2]+t[4],i=this.x*t[1]+this.y*t[3]+t[5];this.x=e,this.y=i},R.CreatePoint=function(t){var e=R.ToNumberArray(t);return new R.Point(e[0],e[1])},R.CreatePath=function(t){for(var e=R.ToNumberArray(t),i=[],n=0;n<e.length;n+=2)i.push(new R.Point(e[n],e[n+1]));return i},R.BoundingBox=function(t,e,n,r){this.x1=Number.NaN,this.y1=Number.NaN,this.x2=Number.NaN,this.y2=Number.NaN,this.x=function(){return this.x1},this.y=function(){return this.y1},this.width=function(){return this.x2-this.x1},this.height=function(){return this.y2-this.y1},this.addPoint=function(t,e){null!=t&&((isNaN(this.x1)||isNaN(this.x2))&&(this.x1=t,this.x2=t),t<this.x1&&(this.x1=t),t>this.x2&&(this.x2=t)),null!=e&&((isNaN(this.y1)||isNaN(this.y2))&&(this.y1=e,this.y2=e),e<this.y1&&(this.y1=e),e>this.y2&&(this.y2=e))},this.addX=function(t){this.addPoint(t,null)},this.addY=function(t){this.addPoint(null,t)},this.addBoundingBox=function(t){this.addPoint(t.x1,t.y1),this.addPoint(t.x2,t.y2)},this.addQuadraticCurve=function(t,e,i,n,r,s){var a=t+2/3*(i-t),o=e+2/3*(n-e),h=a+1/3*(r-t),l=o+1/3*(s-e);this.addBezierCurve(t,e,a,h,o,l,r,s)},this.addBezierCurve=function(t,e,n,r,s,a,o,h){var l=[t,e],u=[n,r],c=[s,a],p=[o,h];for(this.addPoint(l[0],l[1]),this.addPoint(p[0],p[1]),i=0;i<=1;i++){function f(t){return Math.pow(1-t,3)*l[i]+3*Math.pow(1-t,2)*t*u[i]+3*(1-t)*Math.pow(t,2)*c[i]+Math.pow(t,3)*p[i]}var d=6*l[i]-12*u[i]+6*c[i],x=-3*l[i]+9*u[i]-9*c[i]+3*p[i],g=3*u[i]-3*l[i];if(0!=x){var m=Math.pow(d,2)-4*g*x;if(!(m<0)){var y=(-d+Math.sqrt(m))/(2*x);0<y&&y<1&&(0==i&&this.addX(f(y)),1==i&&this.addY(f(y)));var b=(-d-Math.sqrt(m))/(2*x);0<b&&b<1&&(0==i&&this.addX(f(b)),1==i&&this.addY(f(b)))}}else{if(0==d)continue;var v=-g/d;0<v&&v<1&&(0==i&&this.addX(f(v)),1==i&&this.addY(f(v)))}}},this.isPointInBox=function(t,e){return this.x1<=t&&t<=this.x2&&this.y1<=e&&e<=this.y2},this.addPoint(t,e),this.addPoint(n,r)},R.Transform=function(t){var e=this;this.Type={},this.Type.translate=function(t){this.p=R.CreatePoint(t),this.apply=function(t){t.translate(this.p.x||0,this.p.y||0)},this.unapply=function(t){t.translate(-1*this.p.x||0,-1*this.p.y||0)},this.applyToPoint=function(t){t.applyTransform([1,0,0,1,this.p.x||0,this.p.y||0])}},this.Type.rotate=function(t){var e=R.ToNumberArray(t);this.angle=new R.Property("angle",e[0]),this.cx=e[1]||0,this.cy=e[2]||0,this.apply=function(t){t.translate(this.cx,this.cy),t.rotate(this.angle.toRadians()),t.translate(-this.cx,-this.cy)},this.unapply=function(t){t.translate(this.cx,this.cy),t.rotate(-1*this.angle.toRadians()),t.translate(-this.cx,-this.cy)},this.applyToPoint=function(t){var e=this.angle.toRadians();t.applyTransform([1,0,0,1,this.p.x||0,this.p.y||0]),t.applyTransform([Math.cos(e),Math.sin(e),-Math.sin(e),Math.cos(e),0,0]),t.applyTransform([1,0,0,1,-this.p.x||0,-this.p.y||0])}},this.Type.scale=function(t){this.p=R.CreatePoint(t),this.apply=function(t){t.scale(this.p.x||1,this.p.y||this.p.x||1)},this.unapply=function(t){t.scale(1/this.p.x||1,1/this.p.y||this.p.x||1)},this.applyToPoint=function(t){t.applyTransform([this.p.x||0,0,0,this.p.y||0,0,0])}},this.Type.matrix=function(t){this.m=R.ToNumberArray(t),this.apply=function(t){t.transform(this.m[0],this.m[1],this.m[2],this.m[3],this.m[4],this.m[5])},this.applyToPoint=function(t){t.applyTransform(this.m)}},this.Type.SkewBase=function(t){this.base=e.Type.matrix,this.base(t),this.angle=new R.Property("angle",t)},this.Type.SkewBase.prototype=new this.Type.matrix,this.Type.skewX=function(t){this.base=e.Type.SkewBase,this.base(t),this.m=[1,0,Math.tan(this.angle.toRadians()),1,0,0]},this.Type.skewX.prototype=new this.Type.SkewBase,this.Type.skewY=function(t){this.base=e.Type.SkewBase,this.base(t),this.m=[1,Math.tan(this.angle.toRadians()),0,1,0,0]},this.Type.skewY.prototype=new this.Type.SkewBase,this.transforms=[],this.apply=function(t){for(var e=0;e<this.transforms.length;e++)this.transforms[e].apply(t)},this.unapply=function(t){for(var e=this.transforms.length-1;0<=e;e--)this.transforms[e].unapply(t)},this.applyToPoint=function(t){for(var e=0;e<this.transforms.length;e++)this.transforms[e].applyToPoint(t)};for(var i=R.trim(R.compressSpaces(t)).replace(/\)(\s?,\s?)/g,") ").split(/\s(?=[a-z])/),n=0;n<i.length;n++){var r=R.trim(i[n].split("(")[0]),s=i[n].split("(")[1].replace(")",""),a=new this.Type[r](s);a.type=r,this.transforms.push(a)}},R.AspectRatio=function(t,e,i,n,r,s,a,o,h,l){var u=(e=(e=R.compressSpaces(e)).replace(/^defer\s/,"")).split(" ")[0]||"xMidYMid",c=e.split(" ")[1]||"meet",p=i/n,f=r/s,d=Math.min(p,f),x=Math.max(p,f);"meet"==c&&(n*=d,s*=d),"slice"==c&&(n*=x,s*=x),h=new R.Property("refX",h),l=new R.Property("refY",l),h.hasValue()&&l.hasValue()?t.translate(-d*h.toPixels("x"),-d*l.toPixels("y")):(u.match(/^xMid/)&&("meet"==c&&d==f||"slice"==c&&x==f)&&t.translate(i/2-n/2,0),u.match(/YMid$/)&&("meet"==c&&d==p||"slice"==c&&x==p)&&t.translate(0,r/2-s/2),u.match(/^xMax/)&&("meet"==c&&d==f||"slice"==c&&x==f)&&t.translate(i-n,0),u.match(/YMax$/)&&("meet"==c&&d==p||"slice"==c&&x==p)&&t.translate(0,r-s)),"none"==u?t.scale(p,f):"meet"==c?t.scale(d,d):"slice"==c&&t.scale(x,x),t.translate(null==a?0:-a,null==o?0:-o)},R.Element={},R.EmptyProperty=new R.Property("EMPTY",""),R.Element.ElementBase=function(t){if(this.attributes={},this.styles={},this.children=[],this.attribute=function(t,e){var i=this.attributes[t];return null!=i?i:(1==e&&(i=new R.Property(t,""),this.attributes[t]=i),i||R.EmptyProperty)},this.getHrefAttribute=function(){for(var t in this.attributes)if(t.match(/:href$/))return this.attributes[t];return R.EmptyProperty},this.style=function(t,e){var i=this.styles[t];if(null!=i)return i;var n=this.attribute(t);if(null!=n&&n.hasValue())return this.styles[t]=n;var r=this.parent;if(null!=r){var s=r.style(t);if(null!=s&&s.hasValue())return s}return 1==e&&(i=new R.Property(t,""),this.styles[t]=i),i||R.EmptyProperty},this.render=function(t){if("none"!=this.style("display").value&&"hidden"!=this.attribute("visibility").value){if(t.save(),this.attribute("mask").hasValue()){var e=this.attribute("mask").getDefinition();null!=e&&e.apply(t,this)}else if(this.style("filter").hasValue()){var i=this.style("filter").getDefinition();null!=i&&i.apply(t,this)}else this.setContext(t),this.renderChildren(t),this.clearContext(t);t.restore()}},this.setContext=function(t){},this.clearContext=function(t){},this.renderChildren=function(t){for(var e=0;e<this.children.length;e++)this.children[e].render(t)},this.addChild=function(t,e){var i=t;e&&(i=R.CreateElement(t)),(i.parent=this).children.push(i)},null!=t&&1==t.nodeType){for(var e=0;e<t.childNodes.length;e++){var i=t.childNodes[e];if(1==i.nodeType&&this.addChild(i,!0),this.captureTextNodes&&3==i.nodeType){var n=i.nodeValue||i.text||"";""!=R.trim(R.compressSpaces(n))&&this.addChild(new R.Element.tspan(i),!1)}}for(e=0;e<t.attributes.length;e++){var r=t.attributes[e];this.attributes[r.nodeName]=new R.Property(r.nodeName,r.nodeValue)}if(null!=(h=R.Styles[t.nodeName]))for(var s in h)this.styles[s]=h[s];if(this.attribute("class").hasValue())for(var a=R.compressSpaces(this.attribute("class").value).split(" "),o=0;o<a.length;o++){if(null!=(h=R.Styles["."+a[o]]))for(var s in h)this.styles[s]=h[s];if(null!=(h=R.Styles[t.nodeName+"."+a[o]]))for(var s in h)this.styles[s]=h[s]}if(this.attribute("id").hasValue()&&null!=(h=R.Styles["#"+this.attribute("id").value]))for(var s in h)this.styles[s]=h[s];if(this.attribute("style").hasValue()){var h=this.attribute("style").value.split(";");for(e=0;e<h.length;e++)if(""!=R.trim(h[e])){var l=h[e].split(":"),u=(s=R.trim(l[0]),R.trim(l[1]));this.styles[s]=new R.Property(s,u)}}this.attribute("id").hasValue()&&null==R.Definitions[this.attribute("id").value]&&(R.Definitions[this.attribute("id").value]=this)}},R.Element.RenderedElementBase=function(t){this.base=R.Element.ElementBase,this.base(t),this.setContext=function(t){var e;if(this.style("fill").isUrlDefinition())null!=(e=this.style("fill").getFillStyleDefinition(this,this.style("fill-opacity")))&&(t.fillStyle=e);else if(this.style("fill").hasValue()){var i;"currentColor"==(i=this.style("fill")).value&&(i.value=this.style("color").value),t.fillStyle="none"==i.value?"rgba(0,0,0,0)":i.value}if(this.style("fill-opacity").hasValue()&&(i=(i=new R.Property("fill",t.fillStyle)).addOpacity(this.style("fill-opacity").value),t.fillStyle=i.value),this.style("stroke").isUrlDefinition())null!=(e=this.style("stroke").getFillStyleDefinition(this,this.style("stroke-opacity")))&&(t.strokeStyle=e);else if(this.style("stroke").hasValue()){var n;"currentColor"==(n=this.style("stroke")).value&&(n.value=this.style("color").value),t.strokeStyle="none"==n.value?"rgba(0,0,0,0)":n.value}if(this.style("stroke-opacity").hasValue()&&(n=(n=new R.Property("stroke",t.strokeStyle)).addOpacity(this.style("stroke-opacity").value),t.strokeStyle=n.value),this.style("stroke-width").hasValue()){var r=this.style("stroke-width").toPixels();t.lineWidth=0==r?.001:r}if(this.style("stroke-linecap").hasValue()&&(t.lineCap=this.style("stroke-linecap").value),this.style("stroke-linejoin").hasValue()&&(t.lineJoin=this.style("stroke-linejoin").value),this.style("stroke-miterlimit").hasValue()&&(t.miterLimit=this.style("stroke-miterlimit").value),this.style("stroke-dasharray").hasValue()){var s=R.ToNumberArray(this.style("stroke-dasharray").value);void 0!==t.setLineDash?t.setLineDash(s):void 0!==t.webkitLineDash?t.webkitLineDash=s:void 0!==t.mozDash&&(t.mozDash=s);var a=this.style("stroke-dashoffset").numValueOrDefault(1);void 0!==t.lineDashOffset?t.lineDashOffset=a:void 0!==t.webkitLineDashOffset?t.webkitLineDashOffset=a:void 0!==t.mozDashOffset&&(t.mozDashOffset=a)}if(void 0!==t.font&&(t.font=R.Font.CreateFont(this.style("font-style").value,this.style("font-variant").value,this.style("font-weight").value,this.style("font-size").hasValue()?this.style("font-size").toPixels()+"px":"",this.style("font-family").value).toString()),this.attribute("transform").hasValue()&&new R.Transform(this.attribute("transform").value).apply(t),this.style("clip-path").hasValue()){var o=this.style("clip-path").getDefinition();null!=o&&o.apply(t)}this.style("opacity").hasValue()&&(t.globalAlpha=this.style("opacity").numValue())}},R.Element.RenderedElementBase.prototype=new R.Element.ElementBase,R.Element.PathElementBase=function(t){this.base=R.Element.RenderedElementBase,this.base(t),this.path=function(t){return null!=t&&t.beginPath(),new R.BoundingBox},this.renderChildren=function(t){this.path(t),R.Mouse.checkPath(this,t),""!=t.fillStyle&&(this.attribute("fill-rule").hasValue()?t.fill(this.attribute("fill-rule").value):t.fill()),""!=t.strokeStyle&&t.stroke();var e=this.getMarkers();if(null!=e){if(this.style("marker-start").isUrlDefinition()&&(i=this.style("marker-start").getDefinition()).render(t,e[0][0],e[0][1]),this.style("marker-mid").isUrlDefinition())for(var i=this.style("marker-mid").getDefinition(),n=1;n<e.length-1;n++)i.render(t,e[n][0],e[n][1]);this.style("marker-end").isUrlDefinition()&&(i=this.style("marker-end").getDefinition()).render(t,e[e.length-1][0],e[e.length-1][1])}},this.getBoundingBox=function(){return this.path()},this.getMarkers=function(){return null}},R.Element.PathElementBase.prototype=new R.Element.RenderedElementBase,R.Element.svg=function(t){this.base=R.Element.RenderedElementBase,this.base(t),this.baseClearContext=this.clearContext,this.clearContext=function(t){this.baseClearContext(t),R.ViewPort.RemoveCurrent()},this.baseSetContext=this.setContext,this.setContext=function(t){t.strokeStyle="rgba(0,0,0,0)",t.lineCap="butt",t.lineJoin="miter",t.miterLimit=4,this.baseSetContext(t),this.attribute("x").hasValue()||(this.attribute("x",!0).value=0),this.attribute("y").hasValue()||(this.attribute("y",!0).value=0),t.translate(this.attribute("x").toPixels("x"),this.attribute("y").toPixels("y"));var e=R.ViewPort.width(),i=R.ViewPort.height();if(this.attribute("width").hasValue()||(this.attribute("width",!0).value="100%"),this.attribute("height").hasValue()||(this.attribute("height",!0).value="100%"),void 0===this.root){e=this.attribute("width").toPixels("x"),i=this.attribute("height").toPixels("y");var n=0,r=0;this.attribute("refX").hasValue()&&this.attribute("refY").hasValue()&&(n=-this.attribute("refX").toPixels("x"),r=-this.attribute("refY").toPixels("y")),t.beginPath(),t.moveTo(n,r),t.lineTo(e,r),t.lineTo(e,i),t.lineTo(n,i),t.closePath(),t.clip()}if(R.ViewPort.SetCurrent(e,i),this.attribute("viewBox").hasValue()){var s=R.ToNumberArray(this.attribute("viewBox").value),a=s[0],o=s[1];e=s[2],i=s[3],R.AspectRatio(t,this.attribute("preserveAspectRatio").value,R.ViewPort.width(),e,R.ViewPort.height(),i,a,o,this.attribute("refX").value,this.attribute("refY").value),R.ViewPort.RemoveCurrent(),R.ViewPort.SetCurrent(s[2],s[3])}}},R.Element.svg.prototype=new R.Element.RenderedElementBase,R.Element.rect=function(t){this.base=R.Element.PathElementBase,this.base(t),this.path=function(t){var e=this.attribute("x").toPixels("x"),i=this.attribute("y").toPixels("y"),n=this.attribute("width").toPixels("x"),r=this.attribute("height").toPixels("y"),s=this.attribute("rx").toPixels("x"),a=this.attribute("ry").toPixels("y");return this.attribute("rx").hasValue()&&!this.attribute("ry").hasValue()&&(a=s),this.attribute("ry").hasValue()&&!this.attribute("rx").hasValue()&&(s=a),s=Math.min(s,n/2),a=Math.min(a,r/2),null!=t&&(t.beginPath(),t.moveTo(e+s,i),t.lineTo(e+n-s,i),t.quadraticCurveTo(e+n,i,e+n,i+a),t.lineTo(e+n,i+r-a),t.quadraticCurveTo(e+n,i+r,e+n-s,i+r),t.lineTo(e+s,i+r),t.quadraticCurveTo(e,i+r,e,i+r-a),t.lineTo(e,i+a),t.quadraticCurveTo(e,i,e+s,i),t.closePath()),new R.BoundingBox(e,i,e+n,i+r)}},R.Element.rect.prototype=new R.Element.PathElementBase,R.Element.circle=function(t){this.base=R.Element.PathElementBase,this.base(t),this.path=function(t){var e=this.attribute("cx").toPixels("x"),i=this.attribute("cy").toPixels("y"),n=this.attribute("r").toPixels();return null!=t&&(t.beginPath(),t.arc(e,i,n,0,2*Math.PI,!0),t.closePath()),new R.BoundingBox(e-n,i-n,e+n,i+n)}},R.Element.circle.prototype=new R.Element.PathElementBase,R.Element.ellipse=function(t){this.base=R.Element.PathElementBase,this.base(t),this.path=function(t){var e=(Math.sqrt(2)-1)/3*4,i=this.attribute("rx").toPixels("x"),n=this.attribute("ry").toPixels("y"),r=this.attribute("cx").toPixels("x"),s=this.attribute("cy").toPixels("y");return null!=t&&(t.beginPath(),t.moveTo(r,s-n),t.bezierCurveTo(r+e*i,s-n,r+i,s-e*n,r+i,s),t.bezierCurveTo(r+i,s+e*n,r+e*i,s+n,r,s+n),t.bezierCurveTo(r-e*i,s+n,r-i,s+e*n,r-i,s),t.bezierCurveTo(r-i,s-e*n,r-e*i,s-n,r,s-n),t.closePath()),new R.BoundingBox(r-i,s-n,r+i,s+n)}},R.Element.ellipse.prototype=new R.Element.PathElementBase,R.Element.line=function(t){this.base=R.Element.PathElementBase,this.base(t),this.getPoints=function(){return[new R.Point(this.attribute("x1").toPixels("x"),this.attribute("y1").toPixels("y")),new R.Point(this.attribute("x2").toPixels("x"),this.attribute("y2").toPixels("y"))]},this.path=function(t){var e=this.getPoints();return null!=t&&(t.beginPath(),t.moveTo(e[0].x,e[0].y),t.lineTo(e[1].x,e[1].y)),new R.BoundingBox(e[0].x,e[0].y,e[1].x,e[1].y)},this.getMarkers=function(){var t=this.getPoints(),e=t[0].angleTo(t[1]);return[[t[0],e],[t[1],e]]}},R.Element.line.prototype=new R.Element.PathElementBase,R.Element.polyline=function(t){this.base=R.Element.PathElementBase,this.base(t),this.points=R.CreatePath(this.attribute("points").value),this.path=function(t){var e=new R.BoundingBox(this.points[0].x,this.points[0].y);null!=t&&(t.beginPath(),t.moveTo(this.points[0].x,this.points[0].y));for(var i=1;i<this.points.length;i++)e.addPoint(this.points[i].x,this.points[i].y),null!=t&&t.lineTo(this.points[i].x,this.points[i].y);return e},this.getMarkers=function(){for(var t=[],e=0;e<this.points.length-1;e++)t.push([this.points[e],this.points[e].angleTo(this.points[e+1])]);return t.push([this.points[this.points.length-1],t[t.length-1][1]]),t}},R.Element.polyline.prototype=new R.Element.PathElementBase,R.Element.polygon=function(t){this.base=R.Element.polyline,this.base(t),this.basePath=this.path,this.path=function(t){var e=this.basePath(t);return null!=t&&(t.lineTo(this.points[0].x,this.points[0].y),t.closePath()),e}},R.Element.polygon.prototype=new R.Element.polyline,R.Element.path=function(t){this.base=R.Element.PathElementBase,this.base(t);var e=this.attribute("d").value;e=(e=(e=(e=(e=(e=(e=(e=e.replace(/,/gm," ")).replace(/([MmZzLlHhVvCcSsQqTtAa])([MmZzLlHhVvCcSsQqTtAa])/gm,"$1 $2")).replace(/([MmZzLlHhVvCcSsQqTtAa])([MmZzLlHhVvCcSsQqTtAa])/gm,"$1 $2")).replace(/([MmZzLlHhVvCcSsQqTtAa])([^\s])/gm,"$1 $2")).replace(/([^\s])([MmZzLlHhVvCcSsQqTtAa])/gm,"$1 $2")).replace(/([0-9])([+\-])/gm,"$1 $2")).replace(/(\.[0-9]*)(\.)/gm,"$1 $2")).replace(/([Aa](\s+[0-9]+){3})\s+([01])\s*([01])/gm,"$1 $3 $4 "),e=R.compressSpaces(e),e=R.trim(e),this.PathParser=new function(t){this.tokens=t.split(" "),this.reset=function(){this.i=-1,this.command="",this.previousCommand="",this.start=new R.Point(0,0),this.control=new R.Point(0,0),this.current=new R.Point(0,0),this.points=[],this.angles=[]},this.isEnd=function(){return this.i>=this.tokens.length-1},this.isCommandOrEnd=function(){return!!this.isEnd()||null!=this.tokens[this.i+1].match(/^[A-Za-z]$/)},this.isRelativeCommand=function(){switch(this.command){case"m":case"l":case"h":case"v":case"c":case"s":case"q":case"t":case"a":case"z":return!0}return!1},this.getToken=function(){return this.i++,this.tokens[this.i]},this.getScalar=function(){return parseFloat(this.getToken())},this.nextCommand=function(){this.previousCommand=this.command,this.command=this.getToken()},this.getPoint=function(){var t=new R.Point(this.getScalar(),this.getScalar());return this.makeAbsolute(t)},this.getAsControlPoint=function(){var t=this.getPoint();return this.control=t},this.getAsCurrentPoint=function(){var t=this.getPoint();return this.current=t},this.getReflectedControlPoint=function(){return"c"!=this.previousCommand.toLowerCase()&&"s"!=this.previousCommand.toLowerCase()&&"q"!=this.previousCommand.toLowerCase()&&"t"!=this.previousCommand.toLowerCase()?this.current:new R.Point(2*this.current.x-this.control.x,2*this.current.y-this.control.y)},this.makeAbsolute=function(t){return this.isRelativeCommand()&&(t.x+=this.current.x,t.y+=this.current.y),t},this.addMarker=function(t,e,i){null!=i&&0<this.angles.length&&null==this.angles[this.angles.length-1]&&(this.angles[this.angles.length-1]=this.points[this.points.length-1].angleTo(i)),this.addMarkerAngle(t,null==e?null:e.angleTo(t))},this.addMarkerAngle=function(t,e){this.points.push(t),this.angles.push(e)},this.getMarkerPoints=function(){return this.points},this.getMarkerAngles=function(){for(var t=0;t<this.angles.length;t++)if(null==this.angles[t])for(var e=t+1;e<this.angles.length;e++)if(null!=this.angles[e]){this.angles[t]=this.angles[e];break}return this.angles}}(e),this.path=function(t){var e=this.PathParser;e.reset();var i=new R.BoundingBox;for(null!=t&&t.beginPath();!e.isEnd();)switch(e.nextCommand(),e.command){case"M":case"m":var n=e.getAsCurrentPoint();for(e.addMarker(n),i.addPoint(n.x,n.y),null!=t&&t.moveTo(n.x,n.y),e.start=e.current;!e.isCommandOrEnd();)n=e.getAsCurrentPoint(),e.addMarker(n,e.start),i.addPoint(n.x,n.y),null!=t&&t.lineTo(n.x,n.y);break;case"L":case"l":for(;!e.isCommandOrEnd();){var r=e.current;n=e.getAsCurrentPoint(),e.addMarker(n,r),i.addPoint(n.x,n.y),null!=t&&t.lineTo(n.x,n.y)}break;case"H":case"h":for(;!e.isCommandOrEnd();){var s=new R.Point((e.isRelativeCommand()?e.current.x:0)+e.getScalar(),e.current.y);e.addMarker(s,e.current),e.current=s,i.addPoint(e.current.x,e.current.y),null!=t&&t.lineTo(e.current.x,e.current.y)}break;case"V":case"v":for(;!e.isCommandOrEnd();)s=new R.Point(e.current.x,(e.isRelativeCommand()?e.current.y:0)+e.getScalar()),e.addMarker(s,e.current),e.current=s,i.addPoint(e.current.x,e.current.y),null!=t&&t.lineTo(e.current.x,e.current.y);break;case"C":case"c":for(;!e.isCommandOrEnd();){var a=e.current,o=e.getPoint(),h=e.getAsControlPoint(),l=e.getAsCurrentPoint();e.addMarker(l,h,o),i.addBezierCurve(a.x,a.y,o.x,o.y,h.x,h.y,l.x,l.y),null!=t&&t.bezierCurveTo(o.x,o.y,h.x,h.y,l.x,l.y)}break;case"S":case"s":for(;!e.isCommandOrEnd();)a=e.current,o=e.getReflectedControlPoint(),h=e.getAsControlPoint(),l=e.getAsCurrentPoint(),e.addMarker(l,h,o),i.addBezierCurve(a.x,a.y,o.x,o.y,h.x,h.y,l.x,l.y),null!=t&&t.bezierCurveTo(o.x,o.y,h.x,h.y,l.x,l.y);break;case"Q":case"q":for(;!e.isCommandOrEnd();)a=e.current,h=e.getAsControlPoint(),l=e.getAsCurrentPoint(),e.addMarker(l,h,h),i.addQuadraticCurve(a.x,a.y,h.x,h.y,l.x,l.y),null!=t&&t.quadraticCurveTo(h.x,h.y,l.x,l.y);break;case"T":case"t":for(;!e.isCommandOrEnd();)a=e.current,h=e.getReflectedControlPoint(),e.control=h,l=e.getAsCurrentPoint(),e.addMarker(l,h,h),i.addQuadraticCurve(a.x,a.y,h.x,h.y,l.x,l.y),null!=t&&t.quadraticCurveTo(h.x,h.y,l.x,l.y);break;case"A":case"a":for(;!e.isCommandOrEnd();){a=e.current;var u=e.getScalar(),c=e.getScalar(),p=e.getScalar()*(Math.PI/180),f=e.getScalar(),d=e.getScalar(),x=(l=e.getAsCurrentPoint(),new R.Point(Math.cos(p)*(a.x-l.x)/2+Math.sin(p)*(a.y-l.y)/2,-Math.sin(p)*(a.x-l.x)/2+Math.cos(p)*(a.y-l.y)/2)),g=Math.pow(x.x,2)/Math.pow(u,2)+Math.pow(x.y,2)/Math.pow(c,2);1<g&&(u*=Math.sqrt(g),c*=Math.sqrt(g));var m=(f==d?-1:1)*Math.sqrt((Math.pow(u,2)*Math.pow(c,2)-Math.pow(u,2)*Math.pow(x.y,2)-Math.pow(c,2)*Math.pow(x.x,2))/(Math.pow(u,2)*Math.pow(x.y,2)+Math.pow(c,2)*Math.pow(x.x,2)));function y(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))}function b(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(E(t,e))}isNaN(m)&&(m=0);var v=new R.Point(m*u*x.y/c,m*-c*x.x/u),w=new R.Point((a.x+l.x)/2+Math.cos(p)*v.x-Math.sin(p)*v.y,(a.y+l.y)/2+Math.sin(p)*v.x+Math.cos(p)*v.y),E=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(y(t)*y(e))},P=b([1,0],[(x.x-v.x)/u,(x.y-v.y)/c]),B=[(x.x-v.x)/u,(x.y-v.y)/c],S=[(-x.x-v.x)/u,(-x.y-v.y)/c],C=b(B,S);E(B,S)<=-1&&(C=Math.PI),1<=E(B,S)&&(C=0);var M=1-d?1:-1,k=P+C/2*M,T=new R.Point(w.x+u*Math.cos(k),w.y+c*Math.sin(k));if(e.addMarkerAngle(T,k-M*Math.PI/2),e.addMarkerAngle(l,k-M*Math.PI),i.addPoint(l.x,l.y),null!=t){E=c<u?u:c;var O=c<u?1:u/c,V=c<u?c/u:1;t.translate(w.x,w.y),t.rotate(p),t.scale(O,V),t.arc(0,0,E,P,P+C,1-d),t.scale(1/O,1/V),t.rotate(-p),t.translate(-w.x,-w.y)}}break;case"Z":case"z":null!=t&&t.closePath(),e.current=e.start}return i},this.getMarkers=function(){for(var t=this.PathParser.getMarkerPoints(),e=this.PathParser.getMarkerAngles(),i=[],n=0;n<t.length;n++)i.push([t[n],e[n]]);return i}},R.Element.path.prototype=new R.Element.PathElementBase,R.Element.pattern=function(t){this.base=R.Element.ElementBase,this.base(t),this.createPattern=function(t,e){var i=this.attribute("width").toPixels("x",!0),n=this.attribute("height").toPixels("y",!0),r=new R.Element.svg;r.attributes.viewBox=new R.Property("viewBox",this.attribute("viewBox").value),r.attributes.width=new R.Property("width",i+"px"),r.attributes.height=new R.Property("height",n+"px"),r.attributes.transform=new R.Property("transform",this.attribute("patternTransform").value),r.children=this.children;var s=document.createElement("canvas");s.width=i,s.height=n;var a=s.getContext("2d");this.attribute("x").hasValue()&&this.attribute("y").hasValue()&&a.translate(this.attribute("x").toPixels("x",!0),this.attribute("y").toPixels("y",!0));for(var o=-1;o<=1;o++)for(var h=-1;h<=1;h++)a.save(),a.translate(o*s.width,h*s.height),r.render(a),a.restore();return t.createPattern(s,"repeat")}},R.Element.pattern.prototype=new R.Element.ElementBase,R.Element.marker=function(t){this.base=R.Element.ElementBase,this.base(t),this.baseRender=this.render,this.render=function(t,e,i){t.translate(e.x,e.y),"auto"==this.attribute("orient").valueOrDefault("auto")&&t.rotate(i),"strokeWidth"==this.attribute("markerUnits").valueOrDefault("strokeWidth")&&t.scale(t.lineWidth,t.lineWidth),t.save();var n=new R.Element.svg;n.attributes.viewBox=new R.Property("viewBox",this.attribute("viewBox").value),n.attributes.refX=new R.Property("refX",this.attribute("refX").value),n.attributes.refY=new R.Property("refY",this.attribute("refY").value),n.attributes.width=new R.Property("width",this.attribute("markerWidth").value),n.attributes.height=new R.Property("height",this.attribute("markerHeight").value),n.attributes.fill=new R.Property("fill",this.attribute("fill").valueOrDefault("black")),n.attributes.stroke=new R.Property("stroke",this.attribute("stroke").valueOrDefault("none")),n.children=this.children,n.render(t),t.restore(),"strokeWidth"==this.attribute("markerUnits").valueOrDefault("strokeWidth")&&t.scale(1/t.lineWidth,1/t.lineWidth),"auto"==this.attribute("orient").valueOrDefault("auto")&&t.rotate(-i),t.translate(-e.x,-e.y)}},R.Element.marker.prototype=new R.Element.ElementBase,R.Element.defs=function(t){this.base=R.Element.ElementBase,this.base(t),this.render=function(t){}},R.Element.defs.prototype=new R.Element.ElementBase,R.Element.GradientBase=function(t){this.base=R.Element.ElementBase,this.base(t),this.gradientUnits=this.attribute("gradientUnits").valueOrDefault("objectBoundingBox"),this.stops=[];for(var e=0;e<this.children.length;e++){var i=this.children[e];"stop"==i.type&&this.stops.push(i)}this.getGradient=function(){},this.createGradient=function(t,e,i){var n=this;function r(t){return i.hasValue()?new R.Property("color",t).addOpacity(i.value).value:t}this.getHrefAttribute().hasValue()&&(n=this.getHrefAttribute().getDefinition());var s=this.getGradient(t,e);if(null==s)return r(n.stops[n.stops.length-1].color);for(var a=0;a<n.stops.length;a++)s.addColorStop(n.stops[a].offset,r(n.stops[a].color));if(this.attribute("gradientTransform").hasValue()){var o=R.ViewPort.viewPorts[0],h=new R.Element.rect;h.attributes.x=new R.Property("x",-R.MAX_VIRTUAL_PIXELS/3),h.attributes.y=new R.Property("y",-R.MAX_VIRTUAL_PIXELS/3),h.attributes.width=new R.Property("width",R.MAX_VIRTUAL_PIXELS),h.attributes.height=new R.Property("height",R.MAX_VIRTUAL_PIXELS);var l=new R.Element.g;l.attributes.transform=new R.Property("transform",this.attribute("gradientTransform").value),l.children=[h];var u=new R.Element.svg;u.attributes.x=new R.Property("x",0),u.attributes.y=new R.Property("y",0),u.attributes.width=new R.Property("width",o.width),u.attributes.height=new R.Property("height",o.height),u.children=[l];var c=document.createElement("canvas");c.width=o.width,c.height=o.height;var p=c.getContext("2d");return p.fillStyle=s,u.render(p),p.createPattern(c,"no-repeat")}return s}},R.Element.GradientBase.prototype=new R.Element.ElementBase,R.Element.linearGradient=function(t){this.base=R.Element.GradientBase,this.base(t),this.getGradient=function(t,e){var i=e.getBoundingBox();this.attribute("x1").hasValue()||this.attribute("y1").hasValue()||this.attribute("x2").hasValue()||this.attribute("y2").hasValue()||(this.attribute("x1",!0).value=0,this.attribute("y1",!0).value=0,this.attribute("x2",!0).value=1,this.attribute("y2",!0).value=0);var n="objectBoundingBox"==this.gradientUnits?i.x()+i.width()*this.attribute("x1").numValue():this.attribute("x1").toPixels("x"),r="objectBoundingBox"==this.gradientUnits?i.y()+i.height()*this.attribute("y1").numValue():this.attribute("y1").toPixels("y"),s="objectBoundingBox"==this.gradientUnits?i.x()+i.width()*this.attribute("x2").numValue():this.attribute("x2").toPixels("x"),a="objectBoundingBox"==this.gradientUnits?i.y()+i.height()*this.attribute("y2").numValue():this.attribute("y2").toPixels("y");return n==s&&r==a?null:t.createLinearGradient(n,r,s,a)}},R.Element.linearGradient.prototype=new R.Element.GradientBase,R.Element.radialGradient=function(t){this.base=R.Element.GradientBase,this.base(t),this.getGradient=function(t,e){var i=e.getBoundingBox();this.attribute("cx").hasValue()||(this.attribute("cx",!0).value="50%"),this.attribute("cy").hasValue()||(this.attribute("cy",!0).value="50%"),this.attribute("r").hasValue()||(this.attribute("r",!0).value="50%");var n="objectBoundingBox"==this.gradientUnits?i.x()+i.width()*this.attribute("cx").numValue():this.attribute("cx").toPixels("x"),r="objectBoundingBox"==this.gradientUnits?i.y()+i.height()*this.attribute("cy").numValue():this.attribute("cy").toPixels("y"),s=n,a=r;this.attribute("fx").hasValue()&&(s="objectBoundingBox"==this.gradientUnits?i.x()+i.width()*this.attribute("fx").numValue():this.attribute("fx").toPixels("x")),this.attribute("fy").hasValue()&&(a="objectBoundingBox"==this.gradientUnits?i.y()+i.height()*this.attribute("fy").numValue():this.attribute("fy").toPixels("y"));var o="objectBoundingBox"==this.gradientUnits?(i.width()+i.height())/2*this.attribute("r").numValue():this.attribute("r").toPixels();return t.createRadialGradient(s,a,0,n,r,o)}},R.Element.radialGradient.prototype=new R.Element.GradientBase,R.Element.stop=function(t){this.base=R.Element.ElementBase,this.base(t),this.offset=this.attribute("offset").numValue(),this.offset<0&&(this.offset=0),1<this.offset&&(this.offset=1);var e=this.style("stop-color");this.style("stop-opacity").hasValue()&&(e=e.addOpacity(this.style("stop-opacity").value)),this.color=e.value},R.Element.stop.prototype=new R.Element.ElementBase,R.Element.AnimateBase=function(t){this.base=R.Element.ElementBase,this.base(t),R.Animations.push(this),this.duration=0,this.begin=this.attribute("begin").toMilliseconds(),this.maxDuration=this.begin+this.attribute("dur").toMilliseconds(),this.getProperty=function(){var t=this.attribute("attributeType").value,e=this.attribute("attributeName").value;return"CSS"==t?this.parent.style(e,!0):this.parent.attribute(e,!0)},this.initialValue=null,this.initialUnits="",this.removed=!1,this.calcValue=function(){return""},this.update=function(t){if(null==this.initialValue&&(this.initialValue=this.getProperty().value,this.initialUnits=this.getProperty().getUnits()),this.duration>this.maxDuration){if("indefinite"!=this.attribute("repeatCount").value&&"indefinite"!=this.attribute("repeatDur").value)return"remove"==this.attribute("fill").valueOrDefault("remove")&&!this.removed&&(this.removed=!0,this.getProperty().value=this.initialValue,!0);this.duration=0}this.duration=this.duration+t;var e=!1;if(this.begin<this.duration){var i=this.calcValue();this.attribute("type").hasValue()&&(i=this.attribute("type").value+"("+i+")"),this.getProperty().value=i,e=!0}return e},this.from=this.attribute("from"),this.to=this.attribute("to"),this.values=this.attribute("values"),this.values.hasValue()&&(this.values.value=this.values.value.split(";")),this.progress=function(){var t={progress:(this.duration-this.begin)/(this.maxDuration-this.begin)};if(this.values.hasValue()){var e=t.progress*(this.values.value.length-1),i=Math.floor(e),n=Math.ceil(e);t.from=new R.Property("from",parseFloat(this.values.value[i])),t.to=new R.Property("to",parseFloat(this.values.value[n])),t.progress=(e-i)/(n-i)}else t.from=this.from,t.to=this.to;return t}},R.Element.AnimateBase.prototype=new R.Element.ElementBase,R.Element.animate=function(t){this.base=R.Element.AnimateBase,this.base(t),this.calcValue=function(){var t=this.progress();return t.from.numValue()+(t.to.numValue()-t.from.numValue())*t.progress+this.initialUnits}},R.Element.animate.prototype=new R.Element.AnimateBase,R.Element.animateColor=function(t){this.base=R.Element.AnimateBase,this.base(t),this.calcValue=function(){var t=this.progress(),e=new p(t.from.value),i=new p(t.to.value);if(e.ok&&i.ok){var n=e.r+(i.r-e.r)*t.progress,r=e.g+(i.g-e.g)*t.progress,s=e.b+(i.b-e.b)*t.progress;return"rgb("+parseInt(n,10)+","+parseInt(r,10)+","+parseInt(s,10)+")"}return this.attribute("from").value}},R.Element.animateColor.prototype=new R.Element.AnimateBase,R.Element.animateTransform=function(t){this.base=R.Element.AnimateBase,this.base(t),this.calcValue=function(){for(var t=this.progress(),e=R.ToNumberArray(t.from.value),i=R.ToNumberArray(t.to.value),n="",r=0;r<e.length;r++)n+=e[r]+(i[r]-e[r])*t.progress+" ";return n}},R.Element.animateTransform.prototype=new R.Element.animate,R.Element.font=function(t){this.base=R.Element.ElementBase,this.base(t),this.horizAdvX=this.attribute("horiz-adv-x").numValue(),this.isRTL=!1,this.isArabic=!1,this.fontFace=null,this.missingGlyph=null,this.glyphs=[];for(var e=0;e<this.children.length;e++){var i=this.children[e];"font-face"==i.type?(this.fontFace=i).style("font-family").hasValue()&&(R.Definitions[i.style("font-family").value]=this):"missing-glyph"==i.type?this.missingGlyph=i:"glyph"==i.type&&(""!=i.arabicForm?(this.isRTL=!0,this.isArabic=!0,void 0===this.glyphs[i.unicode]&&(this.glyphs[i.unicode]=[]),this.glyphs[i.unicode][i.arabicForm]=i):this.glyphs[i.unicode]=i)}},R.Element.font.prototype=new R.Element.ElementBase,R.Element.fontface=function(t){this.base=R.Element.ElementBase,this.base(t),this.ascent=this.attribute("ascent").value,this.descent=this.attribute("descent").value,this.unitsPerEm=this.attribute("units-per-em").numValue()},R.Element.fontface.prototype=new R.Element.ElementBase,R.Element.missingglyph=function(t){this.base=R.Element.path,this.base(t),this.horizAdvX=0},R.Element.missingglyph.prototype=new R.Element.path,R.Element.glyph=function(t){this.base=R.Element.path,this.base(t),this.horizAdvX=this.attribute("horiz-adv-x").numValue(),this.unicode=this.attribute("unicode").value,this.arabicForm=this.attribute("arabic-form").value},R.Element.glyph.prototype=new R.Element.path,R.Element.text=function(t){this.captureTextNodes=!0,this.base=R.Element.RenderedElementBase,this.base(t),this.baseSetContext=this.setContext,this.setContext=function(t){this.baseSetContext(t),this.style("dominant-baseline").hasValue()&&(t.textBaseline=this.style("dominant-baseline").value),this.style("alignment-baseline").hasValue()&&(t.textBaseline=this.style("alignment-baseline").value)},this.getBoundingBox=function(){return new R.BoundingBox(this.attribute("x").toPixels("x"),this.attribute("y").toPixels("y"),0,0)},this.renderChildren=function(t){this.x=this.attribute("x").toPixels("x"),this.y=this.attribute("y").toPixels("y"),this.x+=this.getAnchorDelta(t,this,0);for(var e=0;e<this.children.length;e++)this.renderChild(t,this,e)},this.getAnchorDelta=function(t,e,i){var n=this.style("text-anchor").valueOrDefault("start");if("start"==n)return 0;for(var r=0,s=i;s<e.children.length;s++){var a=e.children[s];if(i<s&&a.attribute("x").hasValue())break;r+=a.measureTextRecursive(t)}return-1*("end"==n?r:r/2)},this.renderChild=function(t,e,i){var n=e.children[i];for(n.attribute("x").hasValue()?n.x=n.attribute("x").toPixels("x")+this.getAnchorDelta(t,e,i):(this.attribute("dx").hasValue()&&(this.x+=this.attribute("dx").toPixels("x")),n.attribute("dx").hasValue()&&(this.x+=n.attribute("dx").toPixels("x")),n.x=this.x),this.x=n.x+n.measureText(t),n.attribute("y").hasValue()?n.y=n.attribute("y").toPixels("y"):(this.attribute("dy").hasValue()&&(this.y+=this.attribute("dy").toPixels("y")),n.attribute("dy").hasValue()&&(this.y+=n.attribute("dy").toPixels("y")),n.y=this.y),this.y=n.y,n.render(t),i=0;i<n.children.length;i++)this.renderChild(t,n,i)}},R.Element.text.prototype=new R.Element.RenderedElementBase,R.Element.TextElementBase=function(t){this.base=R.Element.RenderedElementBase,this.base(t),this.getGlyph=function(t,e,i){var n=e[i],r=null;if(t.isArabic){var s="isolated";(0==i||" "==e[i-1])&&i<e.length-2&&" "!=e[i+1]&&(s="terminal"),0<i&&" "!=e[i-1]&&i<e.length-2&&" "!=e[i+1]&&(s="medial"),0<i&&" "!=e[i-1]&&(i==e.length-1||" "==e[i+1])&&(s="initial"),void 0!==t.glyphs[n]&&null==(r=t.glyphs[n][s])&&"glyph"==t.glyphs[n].type&&(r=t.glyphs[n])}else r=t.glyphs[n];return null==r&&(r=t.missingGlyph),r},this.renderChildren=function(t){var e=this.parent.style("font-family").getDefinition();if(null==e)""!=t.fillStyle&&t.fillText(R.compressSpaces(this.getText()),this.x,this.y),""!=t.strokeStyle&&t.strokeText(R.compressSpaces(this.getText()),this.x,this.y);else{var i=this.parent.style("font-size").numValueOrDefault(R.Font.Parse(R.ctx.font).fontSize),n=this.parent.style("font-style").valueOrDefault(R.Font.Parse(R.ctx.font).fontStyle),r=this.getText();e.isRTL&&(r=r.split("").reverse().join(""));for(var s=R.ToNumberArray(this.parent.attribute("dx").value),a=0;a<r.length;a++){var o=this.getGlyph(e,r,a),h=i/e.fontFace.unitsPerEm;t.translate(this.x,this.y),t.scale(h,-h);var l=t.lineWidth;t.lineWidth=t.lineWidth*e.fontFace.unitsPerEm/i,"italic"==n&&t.transform(1,0,.4,1,0,0),o.render(t),"italic"==n&&t.transform(1,0,-.4,1,0,0),t.lineWidth=l,t.scale(1/h,-1/h),t.translate(-this.x,-this.y),this.x+=i*(o.horizAdvX||e.horizAdvX)/e.fontFace.unitsPerEm,void 0===s[a]||isNaN(s[a])||(this.x+=s[a])}}},this.getText=function(){},this.measureTextRecursive=function(t){for(var e=this.measureText(t),i=0;i<this.children.length;i++)e+=this.children[i].measureTextRecursive(t);return e},this.measureText=function(t){var e=this.parent.style("font-family").getDefinition();if(null!=e){var i=this.parent.style("font-size").numValueOrDefault(R.Font.Parse(R.ctx.font).fontSize),n=0,r=this.getText();e.isRTL&&(r=r.split("").reverse().join(""));for(var s=R.ToNumberArray(this.parent.attribute("dx").value),a=0;a<r.length;a++)n+=(this.getGlyph(e,r,a).horizAdvX||e.horizAdvX)*i/e.fontFace.unitsPerEm,void 0===s[a]||isNaN(s[a])||(n+=s[a]);return n}var o=R.compressSpaces(this.getText());if(!t.measureText)return 10*o.length;t.save(),this.setContext(t);var h=t.measureText(o).width;return t.restore(),h}},R.Element.TextElementBase.prototype=new R.Element.RenderedElementBase,R.Element.tspan=function(t){this.captureTextNodes=!0,this.base=R.Element.TextElementBase,this.base(t),this.text=t.nodeValue||t.text||"",this.getText=function(){return this.text}},R.Element.tspan.prototype=new R.Element.TextElementBase,R.Element.tref=function(t){this.base=R.Element.TextElementBase,this.base(t),this.getText=function(){var t=this.getHrefAttribute().getDefinition();if(null!=t)return t.children[0].getText()}},R.Element.tref.prototype=new R.Element.TextElementBase,R.Element.a=function(t){this.base=R.Element.TextElementBase,this.base(t),this.hasText=!0;for(var e=0;e<t.childNodes.length;e++)3!=t.childNodes[e].nodeType&&(this.hasText=!1);this.text=this.hasText?t.childNodes[0].nodeValue:"",this.getText=function(){return this.text},this.baseRenderChildren=this.renderChildren,this.renderChildren=function(t){if(this.hasText){this.baseRenderChildren(t);var e=new R.Property("fontSize",R.Font.Parse(R.ctx.font).fontSize);R.Mouse.checkBoundingBox(this,new R.BoundingBox(this.x,this.y-e.toPixels("y"),this.x+this.measureText(t),this.y))}else{var i=new R.Element.g;i.children=this.children,i.parent=this,i.render(t)}},this.onclick=function(){window.open(this.getHrefAttribute().value)},this.onmousemove=function(){R.ctx.canvas.style.cursor="pointer"}},R.Element.a.prototype=new R.Element.TextElementBase,R.Element.image=function(t){this.base=R.Element.RenderedElementBase,this.base(t);var e=this.getHrefAttribute().value,s=e.match(/\.svg$/);if(R.Images.push(this),this.loaded=!1,s)this.img=R.ajax(e),this.loaded=!0;else{this.img=document.createElement("img");var i=this;this.img.onload=function(){i.loaded=!0},this.img.onerror=function(){"undefined"!=typeof console&&(console.log('ERROR: image "'+e+'" not found'),i.loaded=!0)},this.img.src=e}this.renderChildren=function(t){var e=this.attribute("x").toPixels("x"),i=this.attribute("y").toPixels("y"),n=this.attribute("width").toPixels("x"),r=this.attribute("height").toPixels("y");0!=n&&0!=r&&(t.save(),s?t.drawSvg(this.img,e,i,n,r):(t.translate(e,i),R.AspectRatio(t,this.attribute("preserveAspectRatio").value,n,this.img.width,r,this.img.height,0,0),t.drawImage(this.img,0,0)),t.restore())},this.getBoundingBox=function(){var t=this.attribute("x").toPixels("x"),e=this.attribute("y").toPixels("y"),i=this.attribute("width").toPixels("x"),n=this.attribute("height").toPixels("y");return new R.BoundingBox(t,e,t+i,e+n)}},R.Element.image.prototype=new R.Element.RenderedElementBase,R.Element.g=function(t){this.base=R.Element.RenderedElementBase,this.base(t),this.getBoundingBox=function(){for(var t=new R.BoundingBox,e=0;e<this.children.length;e++)t.addBoundingBox(this.children[e].getBoundingBox());return t}},R.Element.g.prototype=new R.Element.RenderedElementBase,R.Element.symbol=function(t){this.base=R.Element.RenderedElementBase,this.base(t),this.baseSetContext=this.setContext,this.setContext=function(t){if(this.baseSetContext(t),this.attribute("viewBox").hasValue()){var e=R.ToNumberArray(this.attribute("viewBox").value),i=e[0],n=e[1];width=e[2],height=e[3],R.AspectRatio(t,this.attribute("preserveAspectRatio").value,this.attribute("width").toPixels("x"),width,this.attribute("height").toPixels("y"),height,i,n),R.ViewPort.SetCurrent(e[2],e[3])}}},R.Element.symbol.prototype=new R.Element.RenderedElementBase,R.Element.style=function(t){this.base=R.Element.ElementBase,this.base(t);for(var e="",i=0;i<t.childNodes.length;i++)e+=t.childNodes[i].nodeValue;e=e.replace(/(\/\*([^*]|[\r\n]|(\*+([^*\/]|[\r\n])))*\*+\/)|(^[\s]*\/\/.*)/gm,"");var n=(e=R.compressSpaces(e)).split("}");for(i=0;i<n.length;i++)if(""!=R.trim(n[i]))for(var r=n[i].split("{"),s=r[0].split(","),a=r[1].split(";"),o=0;o<s.length;o++){var h=R.trim(s[o]);if(""!=h){for(var l={},u=0;u<a.length;u++){var c=a[u].indexOf(":"),p=a[u].substr(0,c),f=a[u].substr(c+1,a[u].length-c);null!=p&&null!=f&&(l[R.trim(p)]=new R.Property(R.trim(p),R.trim(f)))}if(R.Styles[h]=l,"@font-face"==h)for(var d=l["font-family"].value.replace(/"/g,""),x=l.src.value.split(","),g=0;g<x.length;g++)if(0<x[g].indexOf('format("svg")'))for(var m=x[g].indexOf("url"),y=x[g].indexOf(")",m),b=x[g].substr(m+5,y-m-6),v=R.parseXml(R.ajax(b)).getElementsByTagName("font"),w=0;w<v.length;w++){var E=R.CreateElement(v[w]);R.Definitions[d]=E}}}},R.Element.style.prototype=new R.Element.ElementBase,R.Element.use=function(t){this.base=R.Element.RenderedElementBase,this.base(t),this.baseSetContext=this.setContext,this.setContext=function(t){this.baseSetContext(t),this.attribute("x").hasValue()&&t.translate(this.attribute("x").toPixels("x"),0),this.attribute("y").hasValue()&&t.translate(0,this.attribute("y").toPixels("y"))},this.getDefinition=function(){var t=this.getHrefAttribute().getDefinition();return this.attribute("width").hasValue()&&(t.attribute("width",!0).value=this.attribute("width").value),this.attribute("height").hasValue()&&(t.attribute("height",!0).value=this.attribute("height").value),t},this.path=function(t){var e=this.getDefinition();null!=e&&e.path(t)},this.getBoundingBox=function(){var t=this.getDefinition();if(null!=t)return t.getBoundingBox()},this.renderChildren=function(t){var e=this.getDefinition();if(null!=e){var i=e.parent;e.parent=null,e.render(t),e.parent=i}}},R.Element.use.prototype=new R.Element.RenderedElementBase,R.Element.mask=function(t){this.base=R.Element.ElementBase,this.base(t),this.apply=function(t,e){var i=this.attribute("x").toPixels("x"),n=this.attribute("y").toPixels("y"),r=this.attribute("width").toPixels("x"),s=this.attribute("height").toPixels("y");if(0==r&&0==s){for(var a=new R.BoundingBox,o=0;o<this.children.length;o++)a.addBoundingBox(this.children[o].getBoundingBox());i=Math.floor(a.x1),n=Math.floor(a.y1),r=Math.floor(a.width()),s=Math.floor(a.height())}var h=e.attribute("mask").value;e.attribute("mask").value="";var l=document.createElement("canvas");l.width=i+r,l.height=n+s;var u=l.getContext("2d");this.renderChildren(u);var c=document.createElement("canvas");c.width=i+r,c.height=n+s;var p=c.getContext("2d");e.render(p),p.globalCompositeOperation="destination-in",p.fillStyle=u.createPattern(l,"no-repeat"),p.fillRect(0,0,i+r,n+s),t.fillStyle=p.createPattern(c,"no-repeat"),t.fillRect(0,0,i+r,n+s),e.attribute("mask").value=h},this.render=function(t){}},R.Element.mask.prototype=new R.Element.ElementBase,R.Element.clipPath=function(t){this.base=R.Element.ElementBase,this.base(t),this.apply=function(t){for(var e=0;e<this.children.length;e++){var i=this.children[e];if(void 0!==i.path){var n=null;i.attribute("transform").hasValue()&&(n=new R.Transform(i.attribute("transform").value)).apply(t),i.path(t),t.clip(),n&&n.unapply(t)}}},this.render=function(t){}},R.Element.clipPath.prototype=new R.Element.ElementBase,R.Element.filter=function(t){this.base=R.Element.ElementBase,this.base(t),this.apply=function(t,e){var i=e.getBoundingBox(),n=Math.floor(i.x1),r=Math.floor(i.y1),s=Math.floor(i.width()),a=Math.floor(i.height()),o=e.style("filter").value;e.style("filter").value="";for(var h=0,l=0,u=0;u<this.children.length;u++){var c=this.children[u].extraFilterDistance||0;h=Math.max(h,c),l=Math.max(l,c)}var p=document.createElement("canvas");p.width=s+2*h,p.height=a+2*l;var f=p.getContext("2d");for(f.translate(-n+h,-r+l),e.render(f),u=0;u<this.children.length;u++)this.children[u].apply(f,0,0,s+2*h,a+2*l);t.drawImage(p,0,0,s+2*h,a+2*l,n-h,r-l,s+2*h,a+2*l),e.style("filter",!0).value=o},this.render=function(t){}},R.Element.filter.prototype=new R.Element.ElementBase,R.Element.feMorphology=function(t){this.base=R.Element.ElementBase,this.base(t),this.apply=function(t,e,i,n,r){}},R.Element.feMorphology.prototype=new R.Element.ElementBase,R.Element.feColorMatrix=function(t){function o(t,e,i,n,r,s){return t[i*n*4+4*e+s]}function h(t,e,i,n,r,s,a){t[i*n*4+4*e+s]=a}this.base=R.Element.ElementBase,this.base(t),this.apply=function(t,e,i,n,r){var s=t.getImageData(0,0,n,r);for(i=0;i<r;i++)for(e=0;e<n;e++){var a=(o(s.data,e,i,n,0,0)+o(s.data,e,i,n,0,1)+o(s.data,e,i,n,0,2))/3;h(s.data,e,i,n,0,0,a),h(s.data,e,i,n,0,1,a),h(s.data,e,i,n,0,2,a)}t.clearRect(0,0,n,r),t.putImageData(s,0,0)}},R.Element.feColorMatrix.prototype=new R.Element.ElementBase,R.Element.feGaussianBlur=function(t){this.base=R.Element.ElementBase,this.base(t),this.blurRadius=Math.floor(this.attribute("stdDeviation").numValue()),this.extraFilterDistance=this.blurRadius,this.apply=function(t,e,i,n,r){t.canvas.id=R.UniqueId(),t.canvas.style.display="none",document.body.appendChild(t.canvas),c(t.canvas.id,e,i,n,r,this.blurRadius),document.body.removeChild(t.canvas)}},R.Element.feGaussianBlur.prototype=new R.Element.ElementBase,R.Element.title=function(t){},R.Element.title.prototype=new R.Element.ElementBase,R.Element.desc=function(t){},R.Element.desc.prototype=new R.Element.ElementBase,R.Element.MISSING=function(t){"undefined"!=typeof console&&console.log("ERROR: Element '"+t.nodeName+"' not yet implemented.")},R.Element.MISSING.prototype=new R.Element.ElementBase,R.CreateElement=function(t){var e=t.nodeName.replace(/^[^:]+:/,"");e=e.replace(/\-/g,"");var i=null;return(i=void 0!==R.Element[e]?new R.Element[e](t):new R.Element.MISSING(t)).type=t.nodeName,i},R.load=function(t,e){R.loadXml(t,R.ajax(e))},R.loadXml=function(t,e){R.loadXmlDoc(t,R.parseXml(e))},R.loadXmlDoc=function(s,a){function i(t){for(var e=s.canvas;e;)t.x-=e.offsetLeft,t.y-=e.offsetTop,e=e.offsetParent;return window.scrollX&&(t.x+=window.scrollX),window.scrollY&&(t.y+=window.scrollY),t}function n(){R.ViewPort.Clear(),s.canvas.parentNode&&R.ViewPort.SetCurrent(s.canvas.parentNode.clientWidth,s.canvas.parentNode.clientHeight),1!=R.opts.ignoreDimensions&&(o.style("width").hasValue()&&(s.canvas.width=o.style("width").toPixels("x"),s.canvas.style.width=s.canvas.width+"px"),o.style("height").hasValue()&&(s.canvas.height=o.style("height").toPixels("y"),s.canvas.style.height=s.canvas.height+"px"));var t=s.canvas.clientWidth||s.canvas.width,e=s.canvas.clientHeight||s.canvas.height;if(1==R.opts.ignoreDimensions&&o.style("width").hasValue()&&o.style("height").hasValue()&&(t=o.style("width").toPixels("x"),e=o.style("height").toPixels("y")),R.ViewPort.SetCurrent(t,e),null!=R.opts.offsetX&&(o.attribute("x",!0).value=R.opts.offsetX),null!=R.opts.offsetY&&(o.attribute("y",!0).value=R.opts.offsetY),null!=R.opts.scaleWidth&&null!=R.opts.scaleHeight){var i=1,n=1,r=R.ToNumberArray(o.attribute("viewBox").value);o.attribute("width").hasValue()?i=o.attribute("width").toPixels("x")/R.opts.scaleWidth:isNaN(r[2])||(i=r[2]/R.opts.scaleWidth),o.attribute("height").hasValue()?n=o.attribute("height").toPixels("y")/R.opts.scaleHeight:isNaN(r[3])||(n=r[3]/R.opts.scaleHeight),o.attribute("width",!0).value=R.opts.scaleWidth,o.attribute("height",!0).value=R.opts.scaleHeight,o.attribute("viewBox",!0).value="0 0 "+t*i+" "+e*n,o.attribute("preserveAspectRatio",!0).value="none"}1!=R.opts.ignoreClear&&s.clearRect(0,0,t,e),o.render(s),h&&(h=!1,"function"==typeof R.opts.renderCallback&&R.opts.renderCallback(a))}R.init(s),1!=R.opts.ignoreMouse&&(s.canvas.onclick=function(t){var e=i(new R.Point(null!=t?t.clientX:event.clientX,null!=t?t.clientY:event.clientY));R.Mouse.onclick(e.x,e.y)},s.canvas.onmousemove=function(t){var e=i(new R.Point(null!=t?t.clientX:event.clientX,null!=t?t.clientY:event.clientY));R.Mouse.onmousemove(e.x,e.y)});var o=R.CreateElement(a.documentElement),h=o.root=!0,r=!0;R.ImagesLoaded()&&(r=!1,n()),R.intervalID=setInterval(function(){var t=!1;if(r&&R.ImagesLoaded()&&(t=!(r=!1)),1!=R.opts.ignoreMouse&&(t|=R.Mouse.hasEvents()),1!=R.opts.ignoreAnimation)for(var e=0;e<R.Animations.length;e++)t|=R.Animations[e].update(1e3/R.FRAMERATE);"function"==typeof R.opts.forceRedraw&&1==R.opts.forceRedraw()&&(t=!0),t&&(n(),R.Mouse.runEvents())},1e3/R.FRAMERATE)},R.stop=function(){R.intervalID&&clearInterval(R.intervalID)},R.Mouse=new function(){this.events=[],this.hasEvents=function(){return 0!=this.events.length},this.onclick=function(t,e){this.events.push({type:"onclick",x:t,y:e,run:function(t){t.onclick&&t.onclick()}})},this.onmousemove=function(t,e){this.events.push({type:"onmousemove",x:t,y:e,run:function(t){t.onmousemove&&t.onmousemove()}})},this.eventElements=[],this.checkPath=function(t,e){for(var i=0;i<this.events.length;i++){var n=this.events[i];e.isPointInPath&&e.isPointInPath(n.x,n.y)&&(this.eventElements[i]=t)}},this.checkBoundingBox=function(t,e){for(var i=0;i<this.events.length;i++){var n=this.events[i];e.isPointInBox(n.x,n.y)&&(this.eventElements[i]=t)}},this.runEvents=function(){R.ctx.canvas.style.cursor="";for(var t=0;t<this.events.length;t++)for(var e=this.events[t],i=this.eventElements[t];i;)e.run(i),i=i.parent;this.events=[],this.eventElements=[]}},R);1==t.childNodes.length&&"OBJECT"==t.childNodes[0].nodeName||(t.svg=r),r.opts=n;var s=t.getContext("2d");void 0!==e.documentElement?r.loadXmlDoc(s,e):"<"==e.substr(0,1)?r.loadXml(s,e):r.load(s,e)}else for(var a=document.getElementsByTagName("svg"),o=0;o<a.length;o++){var h=a[o],l=document.createElement("canvas");l.width=h.clientWidth,l.height=h.clientHeight,h.parentNode.insertBefore(l,h),h.parentNode.removeChild(h);var u=document.createElement("div");u.appendChild(h),canvg(l,u.innerHTML)}}}(),"undefined"!=typeof CanvasRenderingContext2D&&(CanvasRenderingContext2D.prototype.drawSvg=function(t,e,i,n,r){canvg(this.canvas,t,{ignoreMouse:!0,ignoreAnimation:!0,ignoreDimensions:!0,ignoreClear:!0,offsetX:e,offsetY:i,scaleWidth:n,scaleHeight:r})}),canvg}},f[1]={value:function(t){var e=f.r(34),s=f.r(0);return e.createClass("Output",{constructor:function(t){this.formula=t},toJPG:function(t){i(this.formula,"image/jpeg",t)},toPNG:function(t){i(this.formula,"image/png",t)}});function i(t,e,i){var n,r,s,a=t.container.getRenderBox();return function(t,e,i,n){var r=arguments;{o.apply(null,r)}}(t.node.ownerDocument,{width:a.width,height:a.height,content:(n=t.node,r=n.ownerDocument.createElement("div"),s=['<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="',n.getAttribute("width"),'" height="',n.getAttribute("height"),'">'],r.appendChild(n.cloneNode(!0)),r.innerHTML.replace(/<svg[^>]+?>/i,s.join("")).replace(/&nbsp;/g,""))},e,i)}function a(t,e,i,n){var r=t.createElement("canvas"),s=r.getContext("2d");return r.width=e,r.height=i,"image/png"!==n&&(s.fillStyle="white",s.fillRect(0,0,r.width,r.height)),r}function o(t,e,i,n){var r=a(t,e.width,e.height,i);r.style.cssText="position: absolute; top: 0; left: 100000px; z-index: -1;",window.setTimeout(function(){t.body.appendChild(r),s(r,e.content),t.body.removeChild(r),n(r.toDataURL(i))},0)}}},f[2]={value:function(){return["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","&#x237;","&#x131;","&#x3b1;","&#x3b2;","&#x3b3;","&#x3b4;","&#x3b5;","&#x3b6;","&#x3b7;","&#x3b8;","&#x3b9;","&#x3ba;","&#x3bb;","&#x3bc;","&#x3bd;","&#x3be;","&#x3bf;","&#x3c0;","&#x3c1;","&#x3c2;","&#x3c3;","&#x3c4;","&#x3c5;","&#x3c6;","&#x3c7;","&#x3c8;","&#x3c9;","&#x3d1;","&#x3d5;","&#x3d6;","&#x3de;","&#x3dc;","&#x3f5;","&#x3f1;","&#x3f9;","&#x211c;","&#x2135;","&#x2111;","&#x2127;","&#x2136;","&#x2137;","&#x2138;","&#xf0;","&#x210f;","&#x2141;","&#x210e;","&#x2202;","&#x2118;","&#x214c;","&#x2132;","&#x2201;","&#x2113;","&#x24c8;","(",")","&#x393;","&#x394;","&#x395;","&#x396;","&#x397;","&#x398;","&#x399;","&#x39a;","&#x39b;","&#x39c;","&#x39d;","&#x39e;","&#x39f;","&#x3a0;","&#x3a1;","&#x3a3;","&#x3a4;","&#x3a5;","&#x3a6;","&#x3a7;","&#x3a8;","&#x3a9;","&#x391;","&#x392;","#","!","$","%","&#x26;","&#x2220;","&#x2032;","&#x2035;","&#x2605;","&#x25c6;","&#x25a0;","&#x25b2;","&#x25bc;","&#x22a4;","&#x22a5;","&#x2663;","&#x2660;","&#x2662;","&#x2661;","&#x2203;","&#x2204;","&#x266d;","&#x266e;","&#x266f;","&#x2200;","&#x221e;","&#x2221;","&#x2207;","&#xac;","&#x2222;","&#x221a;","&#x25b3;","&#x25bd;","&#x2205;","&#xf8;","&#x25c7;","&#x25c0;","&#x25b8;","[","]","{","}","&#x3008;","&#x3009;","&#x3f0;",",",".","/",":",";","?","\\","&#x22ee;","&#x22ef;","&#x22f0;","&#x2026;","@","&#x22;","'","|","^","`","&#x201c;","_","*","+","-","&#x2210;","&#x22bc;","&#x22bb;","&#x25ef;","&#x22a1;","&#x229f;","&#x229e;","&#x22a0;","&#x2022;","&#x2229;","&#x222a;","&#x22d2;","&#x22d3;","&#x22d0;","&#x22d1;","&#xb7;","&#x25aa;","&#x25e6;","&#x229b;","&#x229a;","&#x2296;","&#x2299;","&#x229d;","&#x2295;","&#x2297;","&#x2298;","&#xb1;","&#x2213;","&#x22cf;","&#x22ce;","&#x2020;","&#x2021;","&#x22c4;","&#xf7;","&#x22c7;","&#x2214;","&#x232d;","&#x22d7;","&#x22d6;","&#x22c9;","&#x22ca;","&#x22cb;","&#x22cc;","&#x2293;","&#x2294;","&#x2291;","&#x2292;","&#x228f;","&#x2290;","&#x22c6;","&#xd7;","&#x22b3;","&#x22b2;","&#x22b5;","&#x22b4;","&#x228e;","&#x2228;","&#x2227;","&#x2240;","&#x3c;","=","&#x3e;","&#x2248;","&#x2247;","&#x224d;","&#x2252;","&#x2253;","&#x224a;","&#x223d;","&#x2241;","&#x2242;","&#x2243;","&#x22cd;","&#x224f;","&#x224e;","&#x2257;","&#x2245;","&#x22de;","&#x22df;","&#x2250;","&#x2251;","&#x2256;","&#x2a96;","&#x2a95;","&#x2261;","&#x2265;","&#x2264;","&#x2266;","&#x2267;","&#x2a7e;","&#x2a7d;","&#x226b;","&#x226a;","&#x2268;","&#x2269;","&#x22d8;","&#x22d9;","&#x2a87;","&#x2a88;","&#x2a89;","&#x2a8a;","&#x22e7;","&#x22e6;","&#x2a86;","&#x2a85;","&#x22db;","&#x22da;","&#x2a8b;","&#x2a8c;","&#x2277;","&#x2276;","&#x2273;","&#x2272;","&#x232e;","&#x232f;","&#x226f;","&#x2271;","&#x2270;","&#x226e;","&#x2331;","&#x2330;","&#x2332;","&#x2333;","&#x226c;","&#x2280;","&#x2281;","&#x22e0;","&#x22e1;","&#x227a;","&#x227b;","&#x227c;","&#x227d;","&#x227e;","&#x227f;","&#x2282;","&#x2283;","&#x2288;","&#x2289;","&#x2286;","&#x2287;","&#x228a;","&#x228b;","&#x2ab7;","&#x2ab8;","&#x2aaf;","&#x2ab0;","&#x2ab9;","&#x2aba;","&#x2ab5;","&#x2ab6;","&#x22e8;","&#x22e9;","&#x223c;","&#x225c;","&#x21b6;","&#x21b7;","&#x21ba;","&#x21bb;","&#x21be;","&#x21bf;","&#x21c2;","&#x21c3;","&#x21c4;","&#x21c6;","&#x21c8;","&#x21ca;","&#x21cb;","&#x21cc;","&#x21cd;","&#x21ce;","&#x21cf;","&#x21d0;","&#x21d1;","&#x21d2;","&#x21d3;","&#x21d4;","&#x21d5;","&#x21da;","&#x21db;","&#x21dd;","&#x21ab;","&#x21ac;","&#x21ad;","&#x21ae;","&#x2190;","&#x2191;","&#x2192;","&#x2193;","&#x2194;","&#x2195;","&#x2196;","&#x2197;","&#x2198;","&#x2199;","&#x219e;","&#x21a0;","&#x21a2;","&#x21a3;","&#x21b0;","&#x21b1;","&#x22a2;","&#x22a3;","&#x22a8;","&#x22a9;","&#x22aa;","&#x22ad;","&#x22af;","&#x22b8;","&#x22ba;","&#x22d4;","&#x22ea;","&#x22eb;","&#x22ec;","&#x22ed;","&#x2308;","&#x2309;","&#x230a;","&#x230b;","&#x2acb;","&#x2acc;","&#x2ac5;","&#x2ac6;","&#x2208;","&#x220b;","&#x221d;","&#x2224;","&#x2226;","&#x2234;","&#x2235;","&#x220d;","&#x22c8;","&#x2322;","&#x2323;","&#x2223;","&#x2225;","&#x23d0;","&#x23d1;","&#x23d2;","&#x23d3;","&#x2ac7;","&#x2ac8;","&#x22ae;","&#x22ac;","&#x2ac9;","&#x23d4;","&#x23d5;","&#x23d6;","&#x23d7;","&#x21c7;","&#x21c9;","&#x21bc;","&#x21bd;","&#x21c0;","&#x21c1;","&#x219a;","&#x219b;","&#x27f5;","&#x27f6;","&#x27f7;","&#x27f9;","&#x27f8;","&#x27fa;","&#x2262;","&#x2260;","&#x2209;"]}},f[3]={value:function(){return{defaultFont:"KF AMS MAIN"}}},f[4]={value:function(t){var n=f.r(34),r=document.createElement("div");function e(t){var e,i=new n.Text;return"innerHTML"in i.node?i.node.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"):-1!=t.indexOf(" ")&&(e=t,r.innerHTML='<svg><text gg="asfdas">'+e.replace(/\s/gi,"&nbsp;")+"</text></svg>",t=r.firstChild.firstChild.textContent),i.setContent(t),i}return{create:function(t){return e(t)}}}},f[5]={value:function(t){var i=f.r(34),e=f.r(47).font,r=f.r(25),n=f.r(4);return i.createClass("Text",{base:f.r(46),constructor:function(t,e){this.callBase(),this.fontFamily=e,this.fontSize=50,this.content=t||"",this.box.remove(),this.translationContent=this.translation(this.content),this.contentShape=new i.Group,this.contentNode=this.createContent(),this.contentShape.addShape(this.contentNode),this.addShape(this.contentShape)},createContent:function(){var t=n.create(this.translationContent);return t.setAttr({"font-family":this.fontFamily,"font-size":50,x:0,y:e.offset}),t},setFamily:function(t){this.fontFamily=t,this.contentNode.setAttr("font-family",t)},setFontSize:function(t){this.fontSize=t,this.contentNode.setAttr("font-size",t+"px"),this.contentNode.setAttr("y",t/50*e.offset)},getBaseHeight:function(){for(var t=this.contentShape.getItems(),e=null,i=0,n=0;e=t[i];)n=Math.max(n,e.getHeight()),i++;return n},translation:function(t){var n=this.fontFamily;return t.replace(/``/g,"“").replace(/\\([a-zA-Z,]+)\\/g,function(t,e){if(","===e)return" ";var i=r.getCharacterValue(e,n);return i||""})}})}},f[6]={value:function(){return{UNKNOWN:-1,EXP:0,COMPOUND_EXP:1,OP:2}}},f[7]={value:function(){return{SIDE:"side",FOLLOW:"follow"}}},f[8]={value:function(t){return f.r(34).createClass("SubscriptExpression",{base:f.r(17),constructor:function(t,e){this.callBase(t,null,e),this.setFlag("Subscript")}})}},f[9]={value:function(t){return f.r(34).createClass("SuperscriptExpression",{base:f.r(17),constructor:function(t,e){this.callBase(t,e,null),this.setFlag("Superscript")}})}},f[10]={value:function(t){return f.r(34).createClass("BinaryExpression",{base:f.r(19),constructor:function(t,e){this.callBase(),this.setFirstOperand(t),this.setLastOperand(e)},setFirstOperand:function(t){return this.setOperand(t,0)},getFirstOperand:function(){return this.getOperand(0)},setLastOperand:function(t){return this.setOperand(t,1)},getLastOperand:function(){return this.getOperand(1)}})}},f[11]={value:function(t){var e=f.r(34),n=f.r(35);return e.createClass("BracketsExpression",{base:f.r(19),constructor:function(t,e,i){this.callBase(),this.setFlag("Brackets"),2===arguments.length&&(i=e,e=t),this.leftSymbol=t,this.rightSymbol=e,this.setOperator(new n),this.setOperand(i,0)},getLeftSymbol:function(){return this.leftSymbol},getRightSymbol:function(){return this.rightSymbol}})}},f[12]={value:function(t){var n=f.r(34),i=f.r(47).font,e=f.r(36);return n.createClass("CombinationExpression",{base:f.r(19),constructor:function(){this.callBase(),this.setFlag("Combination"),this.setOperator(new e),n.Utils.each(arguments,function(t,e){this.setOperand(t,e)},this)},getRenderBox:function(t){var e=this.callBase(t);return 0===this.getOperands().length&&(e.height=i.spaceHeight),e},getBaseline:function(e){var i=0,t=this.getOperands();return 0===t.length?this.callBase(e):(n.Utils.each(t,function(t){i=Math.max(t.getBaseline(e),i)}),i)},getMeanline:function(e){var i=1e7,t=this.getOperands();return 0===t.length?this.callBase(e):(n.Utils.each(t,function(t){i=Math.min(t.getMeanline(e),i)}),i)}})}},f[13]={value:function(t){var e=f.r(34),i=f.r(38);return e.createClass("FractionExpression",{base:f.r(10),constructor:function(t,e){this.callBase(t,e),this.setFlag("Fraction"),this.setOperator(new i)},getBaseline:function(t){var e=this.getOperand(1),i=e.getRenderBox(t);return i.y+e.getBaselineProportion()*i.height},getMeanline:function(t){var e=this.getOperand(0),i=e.getRenderBox(t);return e.getMeanlineProportion()*i.height}})}},f[14]={value:function(t){var e=f.r(34),i=f.r(47).func,r=f.r(39);return e.createClass("FunctionExpression",{base:f.r(19),constructor:function(t,e,i,n){this.callBase(),this.setFlag("Func"),this.funcName=t,this.setOperator(new r(t)),this.setExpr(e),this.setSuperscript(i),this.setSubscript(n)},isSideScript:function(){return!i["ud-script"][this.funcName]},setExpr:function(t){return this.setOperand(t,0)},setSuperscript:function(t){return this.setOperand(t,1)},setSubscript:function(t){return this.setOperand(t,2)}})}},f[15]={value:function(t){var e=f.r(34),n=f.r(40);return e.createClass("IntegrationExpression",{base:f.r(19),constructor:function(t,e,i){this.callBase(),this.setFlag("Integration"),this.setOperator(new n),this.setIntegrand(t),this.setSuperscript(e),this.setSubscript(i)},setType:function(t){return this.getOperator().setType(t),this},resetType:function(){return this.getOperator().resetType(),this},setIntegrand:function(t){this.setOperand(t,0)},setSuperscript:function(t){this.setOperand(t,1)},setSubscript:function(t){this.setOperand(t,2)}})}},f[16]={value:function(t){var e=f.r(34),i=f.r(42);return e.createClass("RadicalExpression",{base:f.r(10),constructor:function(t,e){this.callBase(t,e),this.setFlag("Radicand"),this.setOperator(new i)},setRadicand:function(t){return this.setFirstOperand(t)},getRadicand:function(){return this.getFirstOperand()},setExponent:function(t){return this.setLastOperand(t)},getExponent:function(){return this.getLastOperand()}})}},f[17]={value:function(t){var e=f.r(34),n=f.r(43);return e.createClass("ScriptExpression",{base:f.r(19),constructor:function(t,e,i){this.callBase(),this.setFlag("Script"),this.setOperator(new n),this.setOpd(t),this.setSuperscript(e),this.setSubscript(i)},setOpd:function(t){this.setOperand(t,0)},setSuperscript:function(t){this.setOperand(t,1)},setSubscript:function(t){this.setOperand(t,2)}})}},f[18]={value:function(t){var e=f.r(34),n=f.r(44);return e.createClass("SummationExpression",{base:f.r(19),constructor:function(t,e,i){this.callBase(),this.setFlag("Summation"),this.setOperator(new n),this.setExpr(t),this.setSuperscript(e),this.setSubscript(i)},setExpr:function(t){this.setOperand(t,0)},setSuperscript:function(t){this.setOperand(t,1)},setSubscript:function(t){this.setOperand(t,2)}})}},f[19]={value:function(t){var e=f.r(34),i=f.r(6),n=f.r(21);return e.createClass("CompoundExpression",{base:f.r(21),constructor:function(){this.callBase(),this.type=i.COMPOUND_EXP,this.operands=[],this.operator=null,this.operatorBox=new e.Group,this.operatorBox.setAttr("data-type","kf-editor-exp-op-box"),this.operandBox=new e.Group,this.operandBox.setAttr("data-type","kf-editor-exp-operand-box"),this.setChildren(0,this.operatorBox),this.setChildren(1,this.operandBox)},setOperator:function(t){return void 0===t?this:(this.operator&&this.operator.remove(),this.operatorBox.addShape(t),this.operator=t,this.operator.setParentExpression(this),t.expression=this)},getOperator:function(){return this.operator},setOperand:function(t,e,i){return!1===i?this.operands[e]=t:(t=n.wrap(t),this.operands[e]&&this.operands[e].remove(),this.operands[e]=t,this.operandBox.addShape(t)),this},getOperand:function(t){return this.operands[t]},getOperands:function(){return this.operands},addedCall:function(){return this.operator.applyOperand.apply(this.operator,this.operands),this}})}},f[20]={value:function(t){var e=f.r(34),i=f.r(47).font,n=f.r(21),r=e.createClass("EmptyExpression",{base:n,constructor:function(){this.callBase(),this.setFlag("Empty")},getRenderBox:function(){return{width:0,height:i.spaceHeight,x:0,y:0}}});return r.isEmpty=function(t){return t instanceof r},n.registerWrap("empty",function(t){if(null==t)return new r}),r}},f[21]={value:function(t){var n=f.r(34),e=f.r(6),i=f.r(47).font,r=[],s={},a=n.createClass("Expression",{base:f.r(46),constructor:function(){this.callBase(),this.type=e.EXP,this._offset={top:0,bottom:0},this.children=[],this.box.fill("transparent").setAttr("data-type","kf-editor-exp-box"),this.box.setAttr("data-type","kf-editor-exp-bg-box"),this.expContent=new n.Group,this.expContent.setAttr("data-type","kf-editor-exp-content-box"),this.addShape(this.expContent)},getChildren:function(){return this.children},getChild:function(t){return this.children[t]||null},getTopOffset:function(){return this._offset.top},getBottomOffset:function(){return this._offset.bottom},getOffset:function(){return this._offset},setTopOffset:function(t){this._offset.top=t},setBottomOffset:function(t){this._offset.bottom=t},setOffset:function(t,e){this._offset.top=t,this._offset.bottom=e},setFlag:function(t){this.setAttr("data-flag",t||"Expression")},setChildren:function(t,e){this.children[t]&&this.children[t].remove(),this.children[t]=e,this.expContent.addShape(e)},getBaselineProportion:function(){return i.baselinePosition},getMeanlineProportion:function(){return i.meanlinePosition},getBaseline:function(t){return this.getRenderBox(t).height*i.baselinePosition-3},getMeanline:function(t){return this.getRenderBox(t).height*i.meanlinePosition-1},getAscenderline:function(){return this.getFixRenderBox().height*i.ascenderPosition},getDescenderline:function(){return this.getFixRenderBox().height*i.descenderPosition},translateElement:function(t,e){this.expContent.translate(t,e)},expand:function(t,e){var i=this.getFixRenderBox();this.setBoxSize(i.width+t,i.height+e)},getBaseWidth:function(){return this.getWidth()},getBaseHeight:function(){return this.getHeight()},updateBoxSize:function(){var t=this.expContent.getFixRenderBox();this.setBoxSize(t.width,t.height)},getBox:function(){return this.box}});return n.Utils.extend(a,{registerWrap:function(t,e){s[t]=r.length,r.push(e)},revokeWrap:function(t){var e=null;return t in s&&(e=r[s[t]],r[s[t]]=null,delete s[t]),e},wrap:function(e){var i;return n.Utils.each(r,function(t){if(t)return!(i=t(e))&&void 0}),i}}),a}},f[22]={value:function(t){var i=f.r(5),n=f.r(34),r=f.r(3),e=f.r(21),s=n.createClass("TextExpression",{base:f.r(21),constructor:function(t,e){this.callBase(),this.fontFamily=e||r.defaultFont,this.setFlag("Text"),this.content=t+"",this.textContent=new i(this.content,this.fontFamily),this.setChildren(0,this.textContent),this.setChildren(1,new n.Rect(0,0,0,0).fill("transparent"))},setFamily:function(t){this.textContent.setFamily(t)},setFontSize:function(t){this.textContent.setFontSize(t)},addedCall:function(){var t=this.textContent.getFixRenderBox();return this.getChild(1).setSize(t.width,t.height),this.updateBoxSize(),this}});return e.registerWrap("text",function(t){var e=typeof t;return"number"!=e&&"string"!=e||(t=new s(t)),t}),s}},f[23]={value:function(){return['<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">','<text id="abcd" font-family="KF AMS MAIN" font-size="50" x="0" y="0">x</text>',"</svg>"]}},f[24]={value:function(t){var s=f.r(34),e=f.r(25),l=f.r(33),u=f.r(47).font,c=f.r(2),p=[];return s.createClass("FontInstaller",{constructor:function(t,e){this.callBase(),this.resource=e||"../src/resource/",this.doc=t},mount:function(i){var t=e.getFontList(),n=0,r=this;s.Utils.each(t,function(t){var a,o,h;n++,t.meta.src=r.resource+t.meta.src,r.createFontStyle(t),a=r.doc,o=t,h=function(){var t,e;0===--n&&(t=r.doc,e=i,window.setTimeout(function(){!function(t){var e=t.createElement("div");e.style.cssText="position: absolute; top: 0; left: -100000px;",e.innerHTML=f.r(23).join(""),t.body.appendChild(e);var i=e.getElementsByTagName("text")[0].getBBox();u.spaceHeight=i.height,u.topSpace=-i.y-u.baseline,u.bottomSpace=u.spaceHeight-u.topSpace-u.baseHeight,u.offset=u.baseline+u.topSpace,u.baselinePosition=(u.topSpace+u.baseline)/u.spaceHeight,u.meanlinePosition=(u.topSpace+u.meanline)/u.spaceHeight,u.ascenderPosition=u.topSpace/u.spaceHeight,u.descenderPosition=(u.topSpace+u.baseHeight)/u.spaceHeight,t.body.removeChild(e)}(t),s.Utils.each(p,function(t){t.parentNode.removeChild(t)}),p=[],e()},100))},l.get(o.meta.src,function(t,e){var i,n,r,s;"success"===e&&(i=a,n=o,r=document.createElement("div"),s=n.meta.fontFamily,r.style.cssText="position: absolute; top: -10000px; left: -100000px;",r.style.fontFamily=s,r.innerHTML=c.join(""),i.body.appendChild(r),p.push(r)),h()})})},createFontStyle:function(t){var e=this.doc.createElement("style");e.setAttribute("type","text/css"),e.innerHTML='@font-face{\nfont-family: "${fontFamily}";\nsrc: url("${src}");\n}'.replace("${fontFamily}",t.meta.fontFamily).replace("${src}",t.meta.src),this.doc.head.appendChild(e)}})}},f[25]={value:function(t){var i={},e=f.r(34),n=f.r(47).font.list;return e.Utils.each(n,function(t){i[t.meta.fontFamily]=t}),{getFontList:function(){return i},getCharacterValue:function(t,e){return i[e]&&i[e].map[t]||null}}}},f[26]={value:function(){return{meta:{fontFamily:"KF AMS BB",src:"KF_AMS_BB.woff"}}}},f[27]={value:function(){return{meta:{fontFamily:"KF AMS CAL",src:"KF_AMS_CAL.woff"}}}},f[28]={value:function(){return{meta:{fontFamily:"KF AMS FRAK",src:"KF_AMS_FRAK.woff"}}}},f[29]={value:function(){return{meta:{fontFamily:"KF AMS MAIN",src:"KF_AMS_MAIN.woff"},map:{Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",varkappa:"ϰ",chi:"χ",psi:"ψ",omega:"ω",digamma:"Ϝ",varepsilon:"ϵ",varrho:"ϱ",varphi:"ϕ",vartheta:"ϑ",varpi:"ϖ",varsigma:"Ϲ",aleph:"ℵ",beth:"ℶ",daleth:"ℸ",gimel:"ℷ",eth:"ð",hbar:"ℎ",hslash:"ℏ",mho:"℧",partial:"∂",wp:"℘",Game:"⅁",Bbbk:"⅌",Finv:"Ⅎ",Im:"ℑ",Re:"ℜ",complement:"∁",ell:"ℓ",circledS:"Ⓢ",imath:"ı",jmath:"ȷ",doublecap:"⋒",Cap:"⋒",doublecup:"⋓",Cup:"⋓",ast:"*",divideontimes:"⋇",rightthreetimes:"⋌",leftthreetimes:"⋋",cdot:"·",odot:"⊙",dotplus:"∔",rtimes:"⋊",ltimes:"⋉",centerdot:"▪",doublebarwedge:"⌭",setminus:"⒁",amalg:"∐",circ:"◦",bigcirc:"◯",gtrdot:"⋗",lessdot:"⋖",smallsetminus:"⒅",circledast:"⊛",circledcirc:"⊚",sqcap:"⊓",sqcup:"⊔",barwedge:"⊼",circleddash:"⊝",star:"⋆",bigtriangledown:"▽",bigtriangleup:"△",cup:"∪",cap:"∩",times:"×",mp:"∓",pm:"±",triangleleft:"⊲",triangleright:"⊳",boxdot:"⊡",curlyvee:"⋏",curlywedge:"⋎",boxminus:"⊟",boxtimes:"⊠",ominus:"⊖",oplus:"⊕",oslash:"⊘",otimes:"⊗",uplus:"⊎",boxplus:"⊞",dagger:"†",ddagger:"‡",vee:"∨",lor:"∨",veebar:"⊻",bullet:"•",diamond:"⋄",wedge:"∧",land:"∧",div:"÷",wr:"≀",geqq:"≧",lll:"⋘",llless:"⋘",ggg:"⋙",gggtr:"⋙",preccurlyeq:"≼",geqslant:"⩾",lnapprox:"⪉",preceq:"⪯",gg:"≫",lneq:"⪇",precnapprox:"⪹",approx:"≈",lneqq:"≨",precneqq:"⪵",approxeq:"≊",gnapprox:"⪊",lnsim:"⋦",precnsim:"⋨",asymp:"≍",gneq:"⪈",lvertneqq:"⌮",precsim:"≾",backsim:"∽",gneqq:"≩",ncong:"≇",risingdotseq:"≓",backsimeq:"⋍",gnsim:"⋧",sim:"∼",simeq:"≃",bumpeq:"≏",gtrapprox:"⪆",ngeq:"≱",Bumpeq:"≎",gtreqless:"⋛",ngeqq:"⌱",succ:"≻",circeq:"≗",gtreqqless:"⪌",ngeqslant:"⌳",succapprox:"⪸",cong:"≅",gtrless:"≷",ngtr:"≯",succcurlyeq:"≽",curlyeqprec:"⋞",gtrsim:"≳",nleq:"≰",succeq:"⪰",curlyeqsucc:"⋟",gvertneqq:"⌯",neq:"≠",ne:"≠",nequiv:"≢",nleqq:"⌰",succnapprox:"⪺",doteq:"≐",leq:"≤",le:"≤",nleqslant:"⌲",succneqq:"⪶",doteqdot:"≑",Doteq:"≑",leqq:"≦",nless:"≮",succnsim:"⋩",leqslant:"⩽",nprec:"⊀",succsim:"≿",eqsim:"≂",lessapprox:"⪅",npreceq:"⋠",eqslantgtr:"⪖",lesseqgtr:"⋚",nsim:"≁",eqslantless:"⪕",lesseqqgtr:"⪋",nsucc:"⊁",triangleq:"≜",eqcirc:"≖",equiv:"≡",lessgtr:"≶",nsucceq:"⋡",fallingdotseq:"≒",lesssim:"≲",prec:"≺",geq:"≥",ge:"≥",ll:"≪",precapprox:"⪷",uparrow:"↑",downarrow:"↓",updownarrow:"↕",Uparrow:"⇑",Downarrow:"⇓",Updownarrow:"⇕",circlearrowleft:"↺",circlearrowright:"↻",curvearrowleft:"↶",curvearrowright:"↷",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",leftarrow:"←",gets:"←",Leftarrow:"⇐",leftarrowtail:"↢",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",leftrightarrow:"↔",Leftrightarrow:"⇔",leftrightarrows:"⇄",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",Lleftarrow:"⇚",looparrowleft:"↫",looparrowright:"↬",multimap:"⊸",nLeftarrow:"⇍",nRightarrow:"⇏",nLeftrightarrow:"⇎",nearrow:"↗",nleftarrow:"↚",nleftrightarrow:"↮",nrightarrow:"↛",nwarrow:"↖",rightarrow:"→",to:"→",Rightarrow:"⇒",rightarrowtail:"↣",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇆",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"⇝",Rrightarrow:"⇛",searrow:"↘",swarrow:"↙",twoheadleftarrow:"↞",twoheadrightarrow:"↠",upharpoonleft:"↿",upharpoonright:"↾",restriction:"↾",upuparrows:"⇈",Lsh:"↰",Rsh:"↱",longleftarrow:"⟵",longrightarrow:"⟶",Longleftarrow:"⟸",Longrightarrow:"⟹",implies:"⟹",longleftrightarrow:"⟷",Longleftrightarrow:"⟺",backepsilon:"∍",because:"∵",therefore:"∴",between:"≬",blacktriangleleft:"◀",blacktriangleright:"▸",dashv:"⊣",bowtie:"⋈",frown:"⌢",in:"∈",notin:"∉",mid:"∣",parallel:"∥",models:"⊨",ni:"∋",owns:"∋",nmid:"∤",nparallel:"∦",nshortmid:"⏒",nshortparallel:"⏓",nsubseteq:"⊈",nsubseteqq:"⫇",nsupseteq:"⊉",nsupseteqq:"⫈",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",nvdash:"⊬",nVdash:"⊮",nvDash:"⊭",nVDash:"⊯",perp:"⊥",pitchfork:"⋔",propto:"∝",shortmid:"⏐",shortparallel:"⏑",smile:"⌣",sqsubset:"⊏",sqsubseteq:"⊑",sqsupset:"⊐",sqsupseteq:"⊒",subset:"⊂",Subset:"⋐",subseteq:"⊆",subseteqq:"⫅",subsetneq:"⊊",subsetneqq:"⫋",supset:"⊃",Supset:"⋑",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",trianglelefteq:"⊴",trianglerighteq:"⊵",varpropto:"⫉",varsubsetneq:"⏔",varsubsetneqq:"⏖",varsupsetneq:"⏕",varsupsetneqq:"⏗",vdash:"⊢",Vdash:"⊩",vDash:"⊨",Vvdash:"⊪",vert:"|",Vert:"ǁ","|":"ǁ","{":"{","}":"}",backslash:"\\",langle:"〈",rangle:"〉",lceil:"⌈",rceil:"⌉",lbrace:"{",rbrace:"}",lfloor:"⌊",rfloor:"⌋",cdots:"⋯",ddots:"⋰",vdots:"⋮",dots:"…",ldots:"…","#":"#",bot:"⊥",angle:"∠",backprime:"‵",bigstar:"★",blacklozenge:"◆",blacksquare:"■",blacktriangle:"▲",blacktriangledown:"▼",clubsuit:"♣",diagdown:"⒁",diagup:"⒂",diamondsuit:"♢",emptyset:"ø",exists:"∃",flat:"♭",forall:"∀",heartsuit:"♡",infty:"∞",lozenge:"◇",measuredangle:"∡",nabla:"∇",natural:"♮",neg:"¬",lnot:"¬",nexists:"∄",prime:"′",sharp:"♯",spadesuit:"♠",sphericalangle:"∢",surd:"√",top:"⊤",varnothing:"∅",triangle:"△",triangledown:"▽"}}}},f[30]={value:function(){return{meta:{fontFamily:"KF AMS ROMAN",src:"KF_AMS_ROMAN.woff"}}}},f[31]={value:function(t){var r=f.r(34),s=f.r(6),e=f.r(25),i=f.r(24),n={fontsize:50,autoresize:!0,padding:[0]},a=f.r(1),o=r.createClass("ExpressionWrap",{constructor:function(t,e){this.wrap=new r.Group,this.bg=new r.Rect(0,0,0,0).fill("transparent"),this.exp=t,this.config=e,this.wrap.setAttr("data-type","kf-exp-wrap"),this.bg.setAttr("data-type","kf-exp-wrap-bg"),this.wrap.addShape(this.bg),this.wrap.addShape(this.exp)},getWrapShape:function(){return this.wrap},getExpression:function(){return this.exp},getBackground:function(){return this.bg},resize:function(){var t=this.config.padding,e=this.exp.getFixRenderBox();1===t.length&&(t[1]=t[0]),this.bg.setSize(2*t[1]+e.width,2*t[0]+e.height),this.exp.translate(t[1],t[0])}}),h=r.createClass("Formula",{base:f.r(32),constructor:function(t,e){this.callBase(t),this.expressions=[],this.fontInstaller=new i(this),this.config=r.Utils.extend({},n,e),this.initEnvironment(),this.initInnerFont()},getContentContainer:function(){return this.container},initEnvironment:function(){this.zoom=this.config.fontsize/50,"width"in this.config&&this.setWidth(this.config.width),"height"in this.config&&this.setHeight(this.config.height),this.node.setAttribute("font-size",n.fontsize)},initInnerFont:function(){var t=e.getFontList(),n=this;r.Utils.each(t,function(t){var e,i;e=t,(i=n.doc.createElement("style")).setAttribute("type","text/css"),i.innerHTML='@font-face{font-family: "${fontFamily}";font-style: normal;src: url("${src}") format("woff");}'.replace("${fontFamily}",e.meta.fontFamily).replace("${src}",e.meta.src),n.resourceNode.appendChild(i)})},insertExpression:function(t,e){var i=this.wrap(t);this.container.clearTransform(),this.expressions.splice(e,0,i.getWrapShape()),this.addShape(i.getWrapShape()),function t(e){var i=0;if(!e)return;if(e.getType()===s.EXP)for(var n=0,i=e.getChildren().length;n<i;n++)t(e.getChild(n));else if(e.getType()===s.COMPOUND_EXP){for(var n=0,i=e.getOperands().length;n<i;n++)t(e.getOperand(n));t(e.getOperator())}e.addedCall&&e.addedCall()}.call(this,i.getExpression()),i.resize(),function(){var i=0;return r.Utils.each(this.expressions,function(t){var e;t&&(t.setMatrix(new r.Matrix(1,0,0,1,0,0)),e=t.getFixRenderBox(),t.translate(0-e.x,i),i+=e.height+10)}),this}.call(this),this.resetZoom(),this.config.autoresize&&this.resize()},appendExpression:function(t){this.insertExpression(t,this.expressions.length)},resize:function(){var t=this.container.getRenderBox("paper");this.node.setAttribute("width",t.width),this.node.setAttribute("height",t.height)},resetZoom:function(){var t=this.zoom/this.getBaseZoom();0!=t&&this.container.scale(t)},wrap:function(t){return new o(t,this.config)},clear:function(){this.callBase(),this.expressions=[]},clearExpressions:function(){r.Utils.each(this.expressions,function(t){t.remove()}),this.expressions=[]},toJPG:function(t){new a(this).toJPG(t)},toPNG:function(t){new a(this).toPNG(t)}});return r.Utils.extend(h,{registerFont:function(t){e.registerFont(t)}}),h}},f[32]={value:function(t){var e=f.r(34);return e.createClass("FPaper",{base:e.Paper,constructor:function(t){this.callBase(t),this.doc=t.ownerDocument,this.container=new e.Group,this.container.setAttr("data-type","kf-container"),this.background=new e.Group,this.background.setAttr("data-type","kf-bg"),this.baseZoom=1,this.zoom=1,this.base("addShape",this.background),this.base("addShape",this.container)},getZoom:function(){return this.zoom},getBaseZoom:function(){return this.baseZoom},addShape:function(t,e){return this.container.addShape(t,e)},getBackground:function(){return this.background},removeShape:function(t){return this.container.removeShape(t)},clear:function(){return this.container.clear()}})}},f[33]={value:function(){if(!window.jQuery)throw new Error("Missing jQuery");return window.jQuery}},f[34]={value:function(){if(!window.kity)throw new Error("Missing Kity Graphic Lib");return window.kity}},f[35]={value:function(t){var h=f.r(34),l=f.r(5);return h.createClass("BracketsOperator",{base:f.r(41),constructor:function(){this.callBase("Brackets")},applyOperand:function(t){(function(t){var e=this.getParentExpression().getLeftSymbol(),i=this.getParentExpression().getRightSymbol(),n=t.getFixRenderBox().height,r=new h.Group,s=0,a=new l(e,"KF AMS MAIN").fill("black"),o=new l(i,"KF AMS MAIN").fill("black");a.setFontSize(n),o.setFontSize(n),this.addOperatorShape(r.addShape(a).addShape(o)),s+=a.getFixRenderBox().width,t.translate(s,0),s+=t.getFixRenderBox().width,o.translate(s,0)}).call(this,t)}})}},f[36]={value:function(t){var e=f.r(34);return e.createClass("CombinationOperator",{base:f.r(41),constructor:function(){this.callBase("Combination")},applyOperand:function(){var n=0,t=arguments,r=0,s=0,a=0,o=[],h=[];e.Utils.each(t,function(t){var e=t.getFixRenderBox(),i=t.getOffset();e.height-=i.top+i.bottom,o.push(e),h.push(i),s=Math.max(i.top,s),a=Math.max(i.bottom,a),r=Math.max(e.height,r)}),e.Utils.each(t,function(t,e){var i=o[e];t.translate(n-i.x,(r-(i.y+i.height))/2+a-h[e].bottom),n+=i.width}),this.parentExpression.setOffset(s,a),this.parentExpression.updateBoxSize()}})}},f[37]={value:function(t){var s=f.r(34),a=f.r(20),o={subOffset:0,supOffset:0,zoom:.66};return s.createClass("ScriptController",{constructor:function(t,e,i,n,r){this.observer=t.getParentExpression(),this.target=e,this.sup=i,this.sub=n,this.options=s.Utils.extend({},o,r)},applyUpDown:function(){var t=this.target,e=this.sup,i=this.sub,n=this.options;e.scale(n.zoom),i.scale(n.zoom);var r=t.getFixRenderBox();return a.isEmpty(e)&&a.isEmpty(i)?{width:r.width,height:r.height,top:0,bottom:0}:!a.isEmpty(e)&&a.isEmpty(i)?this.applyUp(t,e):a.isEmpty(e)&&!a.isEmpty(i)?this.applyDown(t,i):this.applyUpDownScript(t,e,i)},applySide:function(){var t=this.target,e=this.sup,i=this.sub;if(a.isEmpty(e)&&a.isEmpty(i)){var n=t.getRenderBox(this.observer);return{width:n.width,height:n.height,top:0,bottom:0}}return a.isEmpty(e)&&!a.isEmpty(i)?this.applySideSub(t,i):!a.isEmpty(e)&&a.isEmpty(i)?this.applySideSuper(t,e):this.applySideScript(t,e,i)},applySideSuper:function(t,e){e.scale(this.options.zoom);var i=t.getRenderBox(this.observer),n=e.getRenderBox(this.observer),r=t.getMeanline(this.observer),s=e.getBaseline(this.observer)-r,a={top:0,bottom:0,width:i.width+n.width,height:i.height};return e.translate(i.width,0),this.options.supOffset&&e.translate(this.options.supOffset,0),0<s?(t.translate(0,s),a.bottom=s,a.height+=s):e.translate(0,-s),a},applySideSub:function(t,e){e.scale(this.options.zoom);var i=t.getRenderBox(this.observer),n=e.getRenderBox(this.observer),r=e.getOffset(),s=t.getBaseline(this.observer),a=(n.height+r.top+r.bottom)/2,o=i.height-s-a,h={top:0,bottom:0,width:i.width+n.width,height:i.height};return e.translate(i.width,r.top+s-a),this.options.subOffset&&e.translate(this.options.subOffset,0),o<0&&(h.top=-o,h.height-=o),h},applySideScript:function(t,e,i){e.scale(this.options.zoom),i.scale(this.options.zoom);var n=t.getRenderBox(this.observer),r=i.getRenderBox(this.observer),s=e.getRenderBox(this.observer),a=t.getMeanline(this.observer),o=t.getBaseline(this.observer),h=e.getBaseline(this.observer),l=i.getAscenderline(this.observer),u=a+2*(o-a)/3,c=a-h,p=n.height-u-(r.height-l),f={top:0,bottom:0,width:n.width+Math.max(r.width,s.width),height:n.height};return e.translate(n.width,c),i.translate(n.width,u-l),this.options.supOffset&&e.translate(this.options.supOffset,0),this.options.subOffset&&i.translate(this.options.subOffset,0),0<c?p<0&&(n.height-=p,f.top=-p):(t.translate(0,-c),e.translate(0,-c),i.translate(0,-c),f.height-=c,0<p?f.bottom=-c:(f.height-=p,(p=-p)<(c=-c)?f.bottom=c-p:f.top=p-c)),f},applyUp:function(t,e){var i=e.getFixRenderBox(),n=t.getFixRenderBox(),r={width:Math.max(n.width,i.width),height:i.height+n.height,top:0,bottom:i.height};return e.translate((r.width-i.width)/2,0),t.translate((r.width-n.width)/2,i.height),r},applyDown:function(t,e){var i=e.getFixRenderBox(),n=t.getFixRenderBox(),r={width:Math.max(n.width,i.width),height:i.height+n.height,top:i.height,bottom:0};return e.translate((r.width-i.width)/2,n.height),t.translate((r.width-n.width)/2,0),r},applyUpDownScript:function(t,e,i){var n=e.getFixRenderBox(),r=i.getFixRenderBox(),s=t.getFixRenderBox(),a={width:Math.max(s.width,n.width,r.width),height:n.height+r.height+s.height,top:0,bottom:0};return e.translate((a.width-n.width)/2,0),t.translate((a.width-s.width)/2,n.height),i.translate((a.width-r.width)/2,n.height+s.height),a}})}},f[38]={value:function(t){var c=f.r(34),p=f.r(47).zoom;return c.createClass("FractionOperator",{base:f.r(41),constructor:function(){this.callBase("Fraction")},applyOperand:function(t,e){t.scale(p),e.scale(p);var i,n,r=Math.ceil(t.getWidth()),s=Math.ceil(e.getWidth()),a=Math.ceil(t.getHeight()),o=Math.ceil(e.getHeight()),h=Math.max(r,s),l=Math.max(a,o),u=(i=h,n=3,new c.Rect(i+2*n,1).fill("black"));this.addOperatorShape(u),t.translate((h-r)/2+3,0),u.translate(0,a+1),e.translate((h-s)/2+3,a+u.getHeight()+2),this.parentExpression.setOffset(l-a,l-o),this.parentExpression.expand(2,2),this.parentExpression.translateElement(1,1)}})}},f[39]={value:function(t){var e=f.r(34),h=f.r(5),l=f.r(37);return e.createClass("FunctionOperator",{base:f.r(41),constructor:function(t){this.callBase("Function: "+t),this.funcName=t},applyOperand:function(t,e,i){var n=function(){var t=new h(this.funcName,"KF AMS ROMAN");return this.addOperatorShape(t),t.getBaseline=function(){return t.getFixRenderBox().height},t.getMeanline=function(){return 0},t}.call(this),r=t.getFixRenderBox(),s=this.parentExpression.isSideScript()?"applySide":"applyUpDown",a=new l(this,n,e,i,{zoom:.5})[s](),o=(a.height+a.top+a.bottom-r.height)/2;n.translate(0,a.top),e.translate(0,a.top),i.translate(0,a.top),0<=o?t.translate(a.width+5,o):(o=-o,n.translate(0,o),e.translate(0,o),i.translate(0,o),t.translate(a.width+5,0)),this.parentExpression.expand(5,10),this.parentExpression.translateElement(5,5)}})}},f[40]={value:function(t){var a=f.r(34),o=f.r(37);return a.createClass("IntegrationOperator",{base:f.r(41),constructor:function(t){this.callBase("Integration"),this.opType=t||1},setType:function(t){this.opType=0|t},resetType:function(){this.opType=1},applyOperand:function(t,e,i){var n=this.getOperatorShape(),r=t.getFixRenderBox(),s=new o(this,n,e,i,{supOffset:3,subOffset:-15}).applySide(),a=(s.height+s.top-r.height)/2;n.translate(0,s.top),e.translate(0,s.top),i.translate(0,s.top),0<=a?t.translate(s.width+3,a):(a=-a,n.translate(0,a),e.translate(0,a),i.translate(0,a),t.translate(s.width+3,0)),this.parentExpression.expand(3,6),this.parentExpression.translateElement(3,3)},getOperatorShape:function(){var t=new a.Group,e=new a.Group,i=new a.Path("M1.318,48.226c0,0,0.044,0.066,0.134,0.134c0.292,0.313,0.626,0.447,1.006,0.447c0.246,0.022,0.358-0.044,0.604-0.268 c0.782-0.782,1.497-2.838,2.324-6.727c0.514-2.369,0.938-4.693,1.586-8.448C8.559,24.068,9.9,17.878,11.978,9.52 c0.917-3.553,1.922-7.576,3.866-8.983C16.247,0.246,16.739,0,17.274,0c1.564,0,2.503,1.162,2.592,2.57 c0,0.827-0.424,1.386-1.273,1.386c-0.671,0-1.229-0.514-1.229-1.251c0-0.805,0.514-1.095,1.185-1.274 c0.022,0-0.291-0.29-0.425-0.379c-0.201-0.134-0.514-0.224-0.737-0.224c-0.067,0-0.112,0-0.157,0.022 c-0.469,0.134-0.983,0.939-1.453,2.234c-0.537,1.475-0.961,3.174-1.631,6.548c-0.424,2.101-0.693,3.464-1.229,6.727 c-1.608,9.185-2.949,15.487-5.006,23.756c-0.514,2.034-0.849,3.24-1.207,4.335c-0.559,1.698-1.162,2.95-1.811,3.799 c-0.514,0.715-1.385,1.408-2.436,1.408c-1.363,0-2.391-1.185-2.458-2.592c0-0.804,0.447-1.363,1.273-1.363 c0.671,0,1.229,0.514,1.229,1.251C2.503,47.757,1.989,48.047,1.318,48.226z").fill("black"),n=new a.Rect(0,0,0,0).fill("transparent"),r=null;e.addShape(i),t.addShape(n),t.addShape(e),this.addOperatorShape(t);for(var s=1;s<this.opType;s++)r=new a.Use(i).translate(i.getWidth()/2*s,0),e.addShape(r);return e.scale(1.6),r=null,t.getBaseline=function(){return e.getFixRenderBox().height},t.getMeanline=function(){return 10},t}})}},f[41]={value:function(t){var e=f.r(34),i=f.r(6);return e.createClass("Operator",{base:f.r(46),constructor:function(t){this.callBase(),this.type=i.OP,this.parentExpression=null,this.operatorName=t,this.operatorShape=new e.Group,this.addShape(this.operatorShape)},applyOperand:function(){throw new Error("applyOperand is abstract")},setParentExpression:function(t){this.parentExpression=t},getParentExpression:function(){return this.parentExpression},clearParentExpression:function(){this.parentExpression=null},addOperatorShape:function(t){return this.operatorShape.addShape(t)},getOperatorShape:function(){return this.operatorShape}})}},f[42]={value:function(t){var s=f.r(34),o=1,e=2*Math.PI/360,a=Math.sin(15*e),h=Math.cos(15*e),l=Math.tan(15*e);return s.createClass("RadicalOperator",{base:f.r(41),constructor:function(){this.callBase("Radical")},applyOperand:function(t,e){(function(t,e){var i=function(t){var e=new s.Path,i=o,n=t.getHeight()/3,r=e.getDrawer();return r.moveTo(0,h*i*6),r.lineBy(a*i,h*i),r.lineBy(h*i*3,-a*i*3),r.lineBy(l*n,n),r.lineBy(a*i*3,-h*i*3),r.lineBy(-a*n,-n),r.close(),e.fill("black")}(t),n=function(t){var e=new s.Path,i=.9*t.getHeight(),n=e.getDrawer();return n.moveTo(l*i,0),n.lineTo(0,i),n.lineBy(a*o*3,h*o*3),n.lineBy(l*i+a*o*3,-(i+3*o*h)),n.close(),e.fill("black")}(t),r=function(t){var e=t.getWidth()+2*o;return new s.Rect(e,2*o).fill("black")}(t);this.addOperatorShape(i),this.addOperatorShape(n),this.addOperatorShape(r),function(t,e,i,n){var r,s={x:0,y:0},a=e.getFixRenderBox();n.scale(.66),0<(r=n.getFixRenderBox()).width&&0<r.height&&(s.y=r.height-a.height/2,s.y<0&&(n.translate(0,-s.y),s.y=0),s.x=r.width+a.height/2*l-t.x);e.translate(s.x,s.y),i.translate(s.x+t.x+o,s.y+2*o)}.call(this,function(t,e,i){var n=t.getFixRenderBox(),r=e.getFixRenderBox();return e.translate(n.width-a*o*3,0),t.translate(0,r.height-n.height),r=e.getFixRenderBox(),i.translate(r.x+r.width-o/h,0),{x:r.x+r.width-o/h,y:0}}(i,n,r),this.operatorShape,t,e),this.parentExpression.expand(0,10),this.parentExpression.translateElement(0,5)}).call(this,t,e)}})}},f[43]={value:function(t){var e=f.r(34),s=f.r(37);return e.createClass("ScriptOperator",{base:f.r(41),constructor:function(t){this.callBase(t||"Script")},applyOperand:function(t,e,i){var n=this.parentExpression,r=new s(this,t,e,i).applySide();this.getOperatorShape(),r&&n.setOffset(r.top,r.bottom),n.expand(4,2),n.translateElement(2,1)}})}},f[44]={value:function(t){var r=f.r(34),o=f.r(37);return r.createClass("SummationOperator",{base:f.r(41),constructor:function(){this.callBase("Summation"),this.displayType="equation"},applyOperand:function(t,e,i){var n=this.getOperatorShape(),r=t.getFixRenderBox(),s=new o(this,n,e,i).applyUpDown(),a=(s.height-s.top-s.bottom-r.height)/2;0<=a?t.translate(s.width+0,a+s.bottom):(a=-a,n.translate(0,a),e.translate(0,a),i.translate(0,a),t.translate(s.width+0,s.bottom)),this.parentExpression.setOffset(s.top,s.bottom),this.parentExpression.expand(0,0),this.parentExpression.translateElement(0,0)},getOperatorShape:function(){var t,e=new r.Path("M0.672,33.603c-0.432,0-0.648,0-0.648-0.264c0-0.024,0-0.144,0.24-0.432l12.433-14.569L0,0.96c0-0.264,0-0.72,0.024-0.792 C0.096,0.024,0.12,0,0.672,0h28.371l2.904,6.745h-0.6C30.531,4.8,28.898,3.72,28.298,3.336c-1.896-1.2-3.984-1.608-5.28-1.8 c-0.216-0.048-2.4-0.384-5.617-0.384H4.248l11.185,15.289c0.168,0.24,0.168,0.312,0.168,0.36c0,0.12-0.048,0.192-0.216,0.384 L3.168,31.515h14.474c4.608,0,6.96-0.624,7.464-0.744c2.76-0.72,5.305-2.352,6.241-4.848h0.6l-2.904,7.681H0.672z").fill("black"),i=new r.Rect(0,0,0,0).fill("transparent"),n=new r.Group;return n.addShape(i),n.addShape(e),e.scale(1.6),this.addOperatorShape(n),t=e.getFixRenderBox(),"inline"===this.displayType?(e.translate(5,15),i.setSize(t.width+10,t.height+25)):(e.translate(2,5),i.setSize(t.width+4,t.height+8)),n}})}},f[45]={value:function(t){var i=f.r(34),n=[],r=f.r(47).resource,s=f.r(24),e=f.r(31),a=!1;return{ready:function(t,e){a||(a=!0,function(t){t=i.Utils.extend({},r,t),/^(https?:)?\/\//.test(t.path)||(t.path=function(t){var e=location.pathname.split("/");return--e.length,e=e.join("/")+"/",[location.protocol,"//",location.host,e,t.replace(/^\//,"")].join("")}(t.path));new s(document,t.path).mount(o)}(e)),n.push(t)}};function o(){i.Utils.each(n,function(t){t(e)})}}},f[46]={value:function(t){var e=f.r(34),i=f.r(6);return e.createClass("SignGroup",{base:e.Group,constructor:function(){this.callBase(),this.box=new e.Rect(0,0,0,0),this.type=i.UNKNOWN,this.addShape(this.box),this.zoom=1},setZoom:function(t){this.zoom=t},getZoom:function(){return this.zoom},setBoxSize:function(t,e){return this.box.setSize(t,e)},setBoxWidth:function(t){return this.box.setWidth(t)},setBoxHeight:function(t){return this.box.setHeight(t)},getType:function(){return this.type},getBaseHeight:function(){return this.getHeight()},getBaseWidth:function(){return this.getWidth()},addedCall:function(){}})}},f[47]={value:function(t){return{zoom:.66,font:{meanline:Math.round(19),baseline:Math.round(40),baseHeight:50,list:[f.r(29),f.r(27),f.r(28),f.r(26),f.r(30)]},resource:{path:"src/resource/"},func:{"ud-script":{lim:!0}}}}},f[48]={value:function(t){window.kf={ResourceManager:f.r(45),Operator:f.r(41),Expression:f.r(21),CompoundExpression:f.r(19),TextExpression:f.r(22),EmptyExpression:f.r(20),CombinationExpression:f.r(12),FunctionExpression:f.r(14),FractionExpression:f.r(13),IntegrationExpression:f.r(15),RadicalExpression:f.r(16),ScriptExpression:f.r(17),SuperscriptExpression:f.r(9),SubscriptExpression:f.r(8),SummationExpression:f.r(18),BracketsExpression:f.r(11)}}};var e={"kf.start":48};!function(){var t;kity.Shape.getRenderBox;kity.extendClass(kity.Shape,{getFixRenderBox:function(){return this.getRenderBox(this.container.container)},getTranslate:function(){return this.transform.translate}});try{t="kf.start",f.r([e[t]])}catch(t){}}()}();
\ No newline at end of file
/*!
* ====================================================
* Kity Formula Editor - v1.0.0 - 2014-09-03
* https://github.com/kitygraph/formula
* GitHub: https://github.com/kitygraph/formula.git
* Copyright (c) 2014 Baidu Kity Group; Licensed MIT
* ====================================================
*/
!function(){function a(a){b.r([c[a]])}var b={r:function(a){if(b[a].inited)return b[a].value;if("function"!=typeof b[a].value)return b[a].inited=!0,b[a].value;var c={exports:{}},d=b[a].value(null,c.exports,c);if(b[a].inited=!0,b[a].value=d,void 0!==d)return d;for(var e in c.exports)if(c.exports.hasOwnProperty(e))return b[a].inited=!0,b[a].value=c.exports,c.exports}};b[0]={value:function(){function a(d,e,f,g){return g=0|g,g>b?f:(g++,c.each(f,function(b,f){d?!b||"object"!=typeof b&&"function"!=typeof b?e[f]=b:(e[f]=e[f]||(c.isArray(b)?[]:{}),e[f]=a(d,e[f],b,g)):e[f]=b}),e)}var b=10,c={extend:function(b,d){var e=!1;if("boolean"==typeof b?(e=b,b=d,d=[].splice.call(arguments,2)):d=[].splice.call(arguments,1),!b)throw new Error("Utils: extend, target can not be empty");return c.each(d,function(c){(c&&"object"==typeof c||"function"==typeof c)&&a(e,b,c)}),b},contains:function(a,b){return a.contains?a.contains(b):a.compareDocumentPosition?!!(16&a.compareDocumentPosition(b)):void 0},getRect:function(a){return a.getBoundingClientRect()},isArray:function(a){return a&&"[object Array]"==={}.toString.call(a)},isString:function(a){return"string"==typeof a},proxy:function(a,b){return function(){return a.apply(b,arguments)}},each:function(a,b){if(a)if("length"in a&&"number"==typeof a.length)for(var c=0,d=a.length;d>c&&b.call(null,a[c],c,a)!==!1;c++);else for(var e in a)if(a.hasOwnProperty(e)&&b.call(null,a[e],e,a)===!1)break}};return c}},b[1]={value:function(){var a=b.r(20);return a.createClass("Component",{constructor:function(){}})}},b[2]={value:function(){function a(){return++d}var c={},d=0,e=!0,f=b.r(3),g=b.r(0),h=function(a){var b=a.type,d=a.target,f=this.__kfe_eid,h=/^(?:before|after)/.test(b),j=c[f][b];return h||(i.trigger(d,"before"+b),e!==!1)?(g.each(j,function(b){return b&&b.call(d,a)===!1?e=!1:void 0}),void(h||i.trigger(d,"after"+b))):(e=!0,!1)},i={addEvent:function(b,d,e){var f=!0,g=null;b.__kfe_eid||(f=!1,b.__kfe_eid=a(),c[b.__kfe_eid]={}),g=c[b.__kfe_eid],g[d]||(f=!1,g[d]=[]),g[d].push(e),f||b.addEventListener(d,h,!1)},trigger:function(a,b,c){c=c||f.createEvent(b,c),a.dispatchEvent(c)}};return i}},b[3]={value:function(){return{createEvent:function(a){var b=document.createEvent("Event");return b.initEvent(a,!0,!0),b}}}},b[4]={value:function(){var a={},c=b.r(0);return c.extend(a,c,b.r(2)),a}},b[5]={value:function(){var a=b.r(20),c=b.r(8),d=a.createClass("ControllerComponent",{constructor:function(a){this.kfEditor=a,this.components={},this.initComponents()},initComponents:function(){this.components.listener=new c(this,this.kfEditor)}});return d}},b[6]={value:function(){var a={32:"\\,","s+219":"\\{","s+221":"\\}",220:"\\backslash","s+51":"\\#","s+52":"\\$","s+53":"\\%","s+54":"\\^","s+55":"\\&","s+189":"\\_","s+192":"\\~"};return{getReplaceString:function(b){return a[b]||null}}}},b[7]={value:function(){var a=b.r(20),c=b.r(4),d=b.r(6),e={LEFT:37,RIGHT:39,DELETE:8,INPUT:229};return a.createClass("InputComponent",{constructor:function(a,b){this.parentComponent=a,this.kfEditor=b,this.inputBox=this.createInputBox(),this.initServices(),this.initCommands(),this.initEvent()},initServices:function(){this.kfEditor.registerService("control.update.input",this,{updateInput:this.updateInput}),this.kfEditor.registerService("control.insert.string",this,{insertStr:this.insertStr})},initCommands:function(){this.kfEditor.registerCommand("focus",this,this.focus)},createInputBox:function(){var a=this.kfEditor.getContainer(),b=this.kfEditor.getDocument().createElement("input");return b.className="kf-editor-input-box",b.type="text",b.isTrusted=!1,a.appendChild(b),b},focus:function(){var a=null;this.inputBox.focus(),this.kfEditor.requestService("syntax.has.cursor.info")||(a=this.kfEditor.requestService("syntax.get.root.group.info"),this.kfEditor.requestService("syntax.update.record.cursor",{groupId:a.id,startOffset:0,endOffset:a.content.length}),this.kfEditor.requestService("control.update.input")),this.kfEditor.requestService("control.reselect")},setUntrusted:function(){this.inputBox.isTrusted=!1},setTrusted:function(){this.inputBox.isTrusted=!0},updateInput:function(){var a=this.kfEditor.requestService("syntax.serialization");this.setUntrusted(),this.inputBox.value=a.str,this.inputBox.selectionStart=a.startOffset,this.inputBox.selectionEnd=a.endOffset,this.inputBox.focus(),this.setTrusted()},insertStr:function(a){var b=this.kfEditor.requestService("syntax.serialization"),c=b.str;c=c.substring(0,b.startOffset)+" "+a+" "+c.substring(b.endOffset),this.restruct(c),this.updateInput(),this.kfEditor.requestService("ui.update.canvas.view")},initEvent:function(){var a=this;c.addEvent(this.inputBox,"keydown",function(b){var c=!1;if(b.ctrlKey)return void a.processUserCtrl(b);switch(b.keyCode){case e.INPUT:return;case e.LEFT:b.preventDefault(),a.leftMove(),c=!0;break;case e.RIGHT:b.preventDefault(),a.rightMove(),c=!0;break;case e.DELETE:b.preventDefault(),a.delete(),c=!0}c&&a.kfEditor.requestService("ui.update.canvas.view"),a.pretreatmentInput(b)||b.preventDefault()}),c.addEvent(this.inputBox,"input",function(){a.processingInput()}),c.addEvent(this.inputBox,"blur",function(){a.kfEditor.requestService("ui.toolbar.disable"),a.kfEditor.requestService("ui.toolbar.close"),a.kfEditor.requestService("control.cursor.hide"),a.kfEditor.requestService("render.clear.select")}),c.addEvent(this.inputBox,"focus",function(){a.kfEditor.requestService("ui.toolbar.enable"),this.isTrusted&&a.kfEditor.requestService("control.reselect")}),c.addEvent(this.inputBox,"paste",function(a){a.preventDefault()})},hasRootplaceholder:function(){return this.kfEditor.requestService("syntax.has.root.placeholder")},leftMove:function(){this.hasRootplaceholder()||(this.kfEditor.requestService("syntax.cursor.move.left"),this.update())},rightMove:function(){this.hasRootplaceholder()||(this.kfEditor.requestService("syntax.cursor.move.right"),this.update())},"delete":function(){var a=null;this.hasRootplaceholder()||(a=this.kfEditor.requestService("syntax.delete.group"),a?(this.updateInput(),this.processingInput()):(this.updateInput(),this.kfEditor.requestService("control.reselect")))},processUserCtrl:function(a){switch(a.preventDefault(),a.keyCode){case 65:this.kfEditor.requestService("control.select.all");break;case 83:this.kfEditor.requestService("print.image")}},pretreatmentInput:function(a){var b=this.getKeyCode(a),c=d.getReplaceString(b);return null===c?!0:(this.insertStr(c),!1)},getKeyCode:function(a){return(a.shiftKey?"s+":"")+a.keyCode},processingInput:function(){this.restruct(this.inputBox.value),this.kfEditor.requestService("ui.update.canvas.view")},restruct:function(a){this.kfEditor.requestService("render.draw",a),this.kfEditor.requestService("control.reselect")},update:function(){this.updateInput(),this.kfEditor.requestService("control.reselect")}})}},b[8]={value:function(){var a=b.r(20),c=b.r(9),d=b.r(7),e=b.r(10);return a.createClass("MoveComponent",{constructor:function(a,b){this.parentComponent=a,this.kfEditor=b,this.components={},this.initComponents()},initComponents:function(){this.components.location=new c(this,this.kfEditor),this.components.selection=new e(this,this.kfEditor),this.components.input=new d(this,this.kfEditor)}})}},b[9]={value:function(){function a(a){return a.getBoundingClientRect()}var c=b.r(20);return c.createClass("LocationComponent",{constructor:function(a,b){this.parentComponent=a,this.kfEditor=b,this.paper=this.getPaper(),this.cursorShape=this.createCursor(),this.initServices(),this.initEvent()},getPaper:function(){return this.kfEditor.requestService("render.get.paper")},initServices:function(){this.kfEditor.registerService("control.cursor.relocation",this,{relocationCursor:this.updateCursor}),this.kfEditor.registerService("control.cursor.hide",this,{hideCursor:this.hideCursor}),this.kfEditor.registerService("control.reselect",this,{reselect:this.reselect}),this.kfEditor.registerService("control.get.cursor.location",this,{getCursorLocation:this.getCursorLocation})},createCursor:function(){var a=new c.Rect(1,0,0,0).fill("black");return a.setAttr("style","display: none"),this.paper.addShape(a),a},initEvent:function(){var a=this.kfEditor.request("ui.canvas.container.event"),b=this;a.on("mousedown",function(a){a.preventDefault(),b.updateCursorInfo(a),b.kfEditor.requestService("control.update.input"),b.reselect()})},updateCursorInfo:function(a){var b=null,c=null,d=-1;return this.kfEditor.requestService("syntax.has.root.placeholder")?(this.kfEditor.requestService("syntax.update.record.cursor",{groupId:this.kfEditor.requestService("syntax.get.root.group.info").id,startOffset:0,endOffset:1}),!1):(b=this.kfEditor.requestService("position.get.wrap",a.target),b&&this.kfEditor.requestService("syntax.is.placeholder.node",b.id)?(c=this.kfEditor.requestService("position.get.group.info",b),void this.kfEditor.requestService("syntax.update.record.cursor",c.group.id,c.index,c.index+1)):(c=this.kfEditor.requestService("position.get.group",a.target),null===c&&(c=this.kfEditor.requestService("syntax.get.root.group.info")),d=this.getIndex(a.clientX,c),void this.kfEditor.requestService("syntax.update.record.cursor",c.id,d)))},hideCursor:function(){this.cursorShape.setAttr("style","display: none")},reselect:function(){var a=this.kfEditor.requestService("syntax.get.record.cursor"),b=null;return this.hideCursor(),this.kfEditor.requestService("syntax.is.select.placeholder")?(b=this.kfEditor.requestService("syntax.get.group.content",a.groupId),void this.kfEditor.requestService("render.select.group",b.content[a.startOffset].id)):void(a.startOffset===a.endOffset?(this.updateCursor(),this.kfEditor.requestService("render.tint.current.cursor")):this.kfEditor.requestService("render.select.current.cursor"))},updateCursor:function(){var b=this.kfEditor.requestService("syntax.get.record.cursor");if(b.startOffset!==b.endOffset)return void this.hideCursor();var c=this.kfEditor.requestService("syntax.get.group.content",b.groupId),d=0===b.endOffset,e=d?0:b.endOffset-1,f=c.content[e],g=a(this.paper.container.node),h=0,i=a(f),j=this.cursorShape.getTransform(this.cursorShape),k=this.kfEditor.requestService("render.get.canvas.zoom"),l=this.paper.getZoom();this.cursorShape.setHeight(i.height/k/l),h=d?i.left-2:i.left+i.width-2,h-=g.left,j.m.e=Math.floor(h/k/l)+.5,j.m.f=(i.top-g.top)/k/l,this.cursorShape.setMatrix(j),this.cursorShape.setAttr("style","display: block")},getCursorLocation:function(){var a=this.cursorShape.getRenderBox("paper");return{x:a.x,y:a.y}},getIndex:function(b,c){for(var d=-1,e=c.content,f=null,g=e.length-1,h=null;g>=0;g--)if(d=g,h=e[g],f=a(h),f.left<b){f.left+f.width/2<b&&(d+=1);break}return d}})}},b[10]={value:function(){var a=b.r(20),c=b.r(4),d=10;return a.createClass("SelectionComponent",{constructor:function(a,b){this.parentComponent=a,this.kfEditor=b,this.isDrag=!1,this.isMousedown=!1,this.startPoint={x:-1,y:-1},this.startGroupIsPlaceholder=!1,this.startGroup={},this.initServices(),this.initEvent()},initServices:function(){this.kfEditor.registerService("control.select.all",this,{selectAll:this.selectAll})},initEvent:function(){var a=this.kfEditor.request("ui.canvas.container.event"),b=this;a.on("mousedown",function(a){return a.preventDefault(),b.kfEditor.requestService("syntax.has.root.placeholder")?!1:(b.isMousedown=!0,b.updateStartPoint(a.clientX,a.clientY),void b.updateStartGroup())}),a.on("mouseup",function(a){a.preventDefault(),b.stopUpdateSelection()}),a.on("mousemove",function(a){if(a.preventDefault(),b.isDrag){if(1!==a.which)return void b.stopUpdateSelection();b.updateSelection(a.target,a.clientX,a.clientY)}else b.isMousedown&&d<b.getDistance(a.clientX,a.clientY)&&(b.kfEditor.requestService("control.cursor.hide"),b.startUpdateSelection())}),a.on("dblclick",function(a){b.updateSelectionByTarget(a.target)})},getDistance:function(a,b){var c=Math.abs(a-this.startPoint.x),d=Math.abs(b-this.startPoint.y);return Math.max(c,d)},updateStartPoint:function(a,b){this.startPoint.x=a,this.startPoint.y=b},updateStartGroup:function(){var a=this.kfEditor.requestService("syntax.get.record.cursor");this.startGroupIsPlaceholder=this.kfEditor.requestService("syntax.is.select.placeholder"),this.startGroup={groupInfo:this.kfEditor.requestService("syntax.get.group.content",a.groupId),offset:a.startOffset}},startUpdateSelection:function(){this.isDrag=!0,this.isMousedown=!1,this.clearSelection()},stopUpdateSelection:function(){this.isDrag=!1,this.isMousedown=!1,this.kfEditor.requestService("control.update.input")},clearSelection:function(){this.kfEditor.requestService("render.clear.select")},updateSelection:function(a,b){var d=b>this.startPoint.x,e={},f=null,g=!1,h=this.startGroup,i=null,j=this.getGroupInof(b,a);j.groupInfo.id===h.groupInfo.id?(e={groupId:j.groupInfo.id,startOffset:h.offset,endOffset:j.offset},this.startGroupIsPlaceholder&&(d?e.startOffset===e.endOffset&&(e.endOffset+=1):e.startOffset+=1)):c.contains(h.groupInfo.groupObj,j.groupInfo.groupObj)?e={groupId:h.groupInfo.id,startOffset:h.offset,endOffset:this.getIndex(h.groupInfo.groupObj,a,b)}:c.contains(j.groupInfo.groupObj,h.groupInfo.groupObj)?(e={groupId:j.groupInfo.id,startOffset:this.kfEditor.requestService("position.get.index",j.groupInfo.groupObj,h.groupInfo.groupObj),endOffset:j.offset},d||(e.startOffset+=1)):(f=this.getCommunityGroup(h.groupInfo,j.groupInfo),f.startOffset===f.endOffset?f.endOffset+=1:(i=f.group.content[f.endOffset],g=this.kfEditor.requestService("position.get.area",i,b),g&&(f.endOffset+=1),d||(f.startOffset+=1)),e={groupId:f.group.id,startOffset:f.startOffset,endOffset:f.endOffset}),this.kfEditor.requestService("syntax.update.record.cursor",e.groupId,e.startOffset,e.endOffset),this.kfEditor.requestService("control.reselect")},updateSelectionByTarget:function(a){var b=this.kfEditor.requestService("position.get.parent.group",a),c=null,d={};if(null!==b){if(this.kfEditor.requestService("syntax.is.root.node",b.id))return void this.selectAll();this.kfEditor.requestService("syntax.is.virtual.node",b.id)?(c=this.kfEditor.requestService("position.get.group.info",b.groupObj),d={groupId:c.group.id,startOffset:c.index,endOffset:c.index+1}):d={groupId:b.id,startOffset:0,endOffset:b.content.length},this.kfEditor.requestService("syntax.update.record.cursor",d),this.kfEditor.requestService("control.reselect"),this.kfEditor.requestService("control.update.input")}},selectAll:function(){var a=this.kfEditor.requestService("syntax.get.root.group.info"),b={groupId:a.id,startOffset:0,endOffset:a.content.length};this.kfEditor.requestService("syntax.update.record.cursor",b),this.kfEditor.requestService("control.reselect"),this.kfEditor.requestService("control.update.input")},getGroupInof:function(a,b){var c=this.kfEditor.requestService("position.get.group",b);null===c&&(c=this.kfEditor.requestService("syntax.get.root.group.info"));var d=this.kfEditor.requestService("position.get.location.info",a,c);return{groupInfo:c,offset:d}},getIndex:function(a,b,d){var e=this.kfEditor.requestService("position.get.index",a,b),f=this.kfEditor.requestService("syntax.get.group.content",a.id),g=f.content[e],h=c.getRect(g);return h.left+h.width/2<d&&(e+=1),e},getCommunityGroup:function(a,b){for(var d=null,e=a.groupObj,f=null;(d=this.kfEditor.requestService("position.get.group.info",e))&&(e=d.group.groupObj,!c.contains(d.group.groupObj,b.groupObj)););return f=d.group.groupObj,{group:d.group,startOffset:d.index,endOffset:this.kfEditor.requestService("position.get.index",f,b.groupObj)}}})}},b[11]={value:function(){return{GROUP:"kf-editor-group",VIRTUAL:"kf-editor-virtual-group"}}},b[12]={value:function(){function a(a){var b=this.services[a];if(!b)throw new Error("KFEditor: not found service, "+a);return b}var c=b.r(20),d=b.r(4),e={formula:{fontsize:50,autoresize:!1},ui:{zoom:!0,maxzoom:2,minzoom:1}},f={},g=b.r(19).ResourceManager,h=c.createClass("KFEditor",{constructor:function(a,b){this.options=d.extend(!0,{},e,b),this.FormulaClass=null,this._readyState=!1,this._callbacks=[],this.container=a,this.services={},this.commands={},this.initResource()},isReady:function(){return!!this._readyState},triggerReady:function(){for(var a=null,b=this;a=this._callbacks.shift();)a.call(b,b)},ready:function(a){this._readyState?a.call(this,this):this._callbacks.push(a)},getContainer:function(){return this.container},getDocument:function(){return this.container.ownerDocument},getFormulaClass:function(){return this.FormulaClass},getOptions:function(){return this.options},initResource:function(){var a=this;g.ready(function(b){a.FormulaClass=b,a.initComponents(),a._readyState=!0,a.triggerReady()},this.options.resource)},initComponents:function(){var a=this;d.each(f,function(b,c){new b(a,a.options[c])})},requestService:function(b){var c=a.call(this,b);return c.service[c.key].apply(c.provider,[].slice.call(arguments,1))},request:function(b){var c=a.call(this,b);return c.service},registerService:function(a,b,c){var e=null;for(e in c)c[e]&&c.hasOwnProperty(e)&&(c[e]=d.proxy(c[e],b));this.services[a]={provider:b,key:e,service:c}},registerCommand:function(a,b,c){this.commands[a]={executor:b,execFn:c}},execCommand:function(a){var b=this.commands[a];if(!b)throw new Error("KFEditor: not found command, "+a);return b.execFn.apply(b.executor,[].slice.call(arguments,1))}});return d.extend(h,{registerComponents:function(a,b){f[a]=b}}),h}},b[13]={value:function(){function a(a,b){var c=this;this._callbacks=[],this.editor=new d(a,b),this.editor.ready(function(){c._trigger()})}var c=b.r(20),d=b.r(12);return a.prototype._trigger=function(){var a=this.editor;c.Utils.each(this._callbacks,function(b){b.call(a,a)})},a.prototype.ready=function(a){this.editor.isReady()?a.call(this.editor,this.editor):this._callbacks.push(a)},{create:function(b,c){return new a(b,c)}}}},b[14]={value:function(){return window.jQuery}},b[15]={value:function(){return{selectColor:"rgba(42, 106, 189, 0.2)",allSelectColor:"rgba(42, 106, 189, 0.6)"}}},b[16]={value:function(){var a=b.r(20),c=b.r(19),d=b.r(18);return a.createClass("PlaceholderExpression",{base:c.CompoundExpression,constructor:function(){this.callBase(),this.setFlag("Placeholder"),this.label=null,this.box.setAttr("data-type",null),this.setOperator(new d)},setLabel:function(a){this.label=a},getLabel:function(){return this.label},setAttr:function(a,b){"label"===a?this.setLabel(b):(a.label&&(this.setLabel(a.label),delete a.label),this.callBase(a,b))},select:function(){this.getOperator().select()},selectAll:function(){this.getOperator().selectAll()},unselect:function(){this.getOperator().unselect()}})}},b[17]={value:function(){function a(a){c.PlaceholderExpression=b.r(16),c.Expression.prototype.select=function(){this.box.fill(d)},c.Expression.prototype.selectAll=function(){this.box.fill(e)},c.Expression.prototype.unselect=function(){this.box.fill("transparent")},a.getKFParser().expand({parse:{placeholder:{name:"placeholder",handler:function(a){return delete a.handler,a.operand=[],a},sign:!1}},reverse:{placeholder:function(){return"\\placeholder "}}})}var c=b.r(19),d=b.r(15).selectColor,e=b.r(15).allSelectColor;return{ext:a}}},b[18]={value:function(){function a(a,b){return null!==b?d(a,b):c(a)}function c(a){var b=35,c=50,d=null;return d=new e.Rect(b,c,0,0).stroke("black").fill("transparent"),d.setAttr("stroke-dasharray","5, 5"),a.addOperatorShape(d),d}function d(a,b){var c=new e.Text(b).fill(f),d=new e.Group,g=2,h=7,i=new e.Rect(0,0,0,0,h).stroke(f).fill("transparent"),j=null;return c.setFontSize(40),d.addShape(i),d.addShape(c),a.addOperatorShape(d),j=c.getFixRenderBox(),i.stroke(f).fill("transparent"),i.setSize(j.width+2*g,j.height+2*g),i.setRadius(h),i.setAttr("stroke-dasharray","5, 5"),c.setAttr({dx:0-j.x,dy:0-j.y}),c.translate(g,g),i}var e=b.r(20),f=b.r(29).rootPlaceholder.color,g=b.r(15).selectColor,h=b.r(15).allSelectColor;return e.createClass("PlaceholderOperator",{base:b.r(19).Operator,constructor:function(){this.opShape=null,this.callBase("Placeholder")},applyOperand:function(){this.opShape=a(this,this.parentExpression.getLabel()),this.parentExpression.expand(20,20),this.parentExpression.translateElement(10,10)},select:function(){this.opShape.fill(g)},selectAll:function(){this.opShape.fill(h)},unselect:function(){this.opShape.fill("transparent")}})}},b[19]={value:function(){return window.kf}},b[20]={value:function(){return window.kity}},b[21]={value:function(){function a(a,b,c){var i=null,j=!c;b.attr=b.attr||{},b.attr.id=a.getGroupId(),j?d(a,b):c.attr["data-root"]&&"placeholder"===b.name&&g(c.operand)&&(b.attr.label=o);for(var k=0,l=b.operand.length;l>k;k++)i=b.operand[k],h(b)?e(a,k,b,i):f(a,k,b,i);return b}function c(){return q+ ++s}function d(a,b){a.isResetId?b.attr["data-root"]="true":b.attr["data-type"]=r.VIRTUAL}function e(b,c,d,e){"brackets"===d.name&&2>c||("function"!==d.name||0!==c)&&(d.attr["data-type"]=r.VIRTUAL,e?"string"==typeof e?(d.operand[c]=j(b),d.operand[c].operand[0]=e):i(e)?(d.operand[c]=j(b),d.operand[c].operand[0]=a(b,e,d.operand[c])):d.operand[c]=a(b,e,d):d.operand[c]=e)}function f(b,c,d,e){d.attr["data-type"]=r.GROUP,d.operand[c]=e&&"string"!=typeof e?"text"===e.name?e:a(b,e,d):e}function g(a){var b=1;if(a.length>3)return!1;for(var c=0,d=a.length;d>c;c++)a[c]!==m&&a[c]&&"placeholder"===a[c].name&&b--;return!b}function h(a){return!!n[a.name]}function i(a){return"placeholder"===a.name}function j(a){return{name:p,attr:{"data-type":r.GROUP,id:a.getGroupId()},operand:[]}}var k=b.r(19).Parser,l=b.r(20),m=b.r(29).cursorCharacter,n=b.r(22),o=b.r(29).rootPlaceholder.content,p="combination",q="_kf_editor_",r=b.r(11),s=0,t=l.createClass("Parser",{constructor:function(a){this.kfEditor=a,this.callBase(),this.kfParser=k.use("latex"),this.initKFormulExtension(),this.pid=c(),this.groupRecord=0,this.tree=null,this.isResetId=!0,this.initServices()},parse:function(b,c){var d=null;return this.isResetId=!!c,this.isResetId&&this.resetGroupId(),d=this.kfParser.parse(b),a(this,d.tree),d},serialization:function(a){return this.kfParser.serialization(a)},initServices:function(){this.kfEditor.registerService("parser.parse",this,{parse:this.parse}),this.kfEditor.registerService("parser.latex.serialization",this,{serialization:this.serialization})},getKFParser:function(){return this.kfParser},initKFormulExtension:function(){b.r(17).ext(this)},resetGroupId:function(){this.groupRecord=0},getGroupId:function(){return this.pid+"_"+ ++this.groupRecord}});return t}},b[22]={value:function(){return{radical:!0,fraction:!0,summation:!0,integration:!0,placeholder:!0,script:!0,superscript:!0,subscript:!0,brackets:!0,"function":!0}}},b[23]={value:function(){function a(b,c,d){var e=null;return b.ownerSVGElement?(b=b.parentNode,e=b.tagName.toLowerCase(),b&&"body"!==e&&"svg"!==e?"kf-editor-group"===b.getAttribute("data-type")?b:c&&"kf-editor-virtual-group"===b.getAttribute("data-type")?b:d&&null!==b.getAttribute("data-flag")?b:a(b,c,d):null):null}var c=b.r(20),d=b.r(4),e=c.createClass("PositionComponenet",{constructor:function(a){this.kfEditor=a,this.initServices()},initServices:function(){this.kfEditor.registerService("position.get.group",this,{getGroupByTarget:this.getGroupByTarget}),this.kfEditor.registerService("position.get.index",this,{getIndexByTargetInGroup:this.getIndexByTargetInGroup}),this.kfEditor.registerService("position.get.location.info",this,{getLocationInfo:this.getLocationInfo}),this.kfEditor.registerService("position.get.parent.group",this,{getParentGroupByTarget:this.getParentGroupByTarget}),this.kfEditor.registerService("position.get.wrap",this,{getWrap:this.getWrap}),this.kfEditor.registerService("position.get.area",this,{getAreaByCursorInGroup:this.getAreaByCursorInGroup}),this.kfEditor.registerService("position.get.group.info",this,{getGroupInfoByNode:this.getGroupInfoByNode}),this.kfEditor.registerService("position.get.parent.info",this,{getParentInfoByNode:this.getParentInfoByNode})},getGroupByTarget:function(b){var c=a(b,!1,!1);return c?this.kfEditor.requestService("syntax.get.group.content",c.id):null},getIndexByTargetInGroup:function(a,b){var e=this.kfEditor.requestService("syntax.get.group.content",a.id),f=-1;return c.Utils.each(e.content,function(a,c){return f=c,d.contains(a,b)?!1:void 0}),f},getAreaByCursorInGroup:function(a,b){var c=d.getRect(a);return c.left+c.width/2<b},getLocationInfo:function(a,b){for(var c=-1,e=b.content,f=null,g=e.length-1,h=null;g>=0;g--)if(c=g,h=e[g],f=d.getRect(h),f.left<a){f.left+f.width/2<a&&(c+=1);break}return c},getParentGroupByTarget:function(b){var c=a(b,!0,!1);return c?this.kfEditor.requestService("syntax.get.group.content",c.id):null},getWrap:function(b){return a(b,!0,!0)},getGroupInfoByNode:function(b){var c={},e=a(b,!1,!1),f=null;if(!e)return null;f=this.kfEditor.requestService("syntax.get.group.content",e.id);for(var g=0,h=f.content.length;h>g&&(c.index=g,!d.contains(f.content[g],b));g++);return c.group=f,c},getParentInfoByNode:function(b){var c=a(b,!0,!1);return c=this.kfEditor.requestService("syntax.get.group.content",c.id),{group:c,index:c.content.indexOf(b)}}});return e}},b[24]={value:function(){var a=b.r(20);return a.createClass("Printer",{constructor:function(a){this.kfEditor=a,this.initServices(),this.initCommands()},initServices:function(){this.kfEditor.registerService("print.image",this,{printImage:this.printImage})},initCommands:function(){this.kfEditor.registerCommand("get.image.data",this,this.getImageData)},printImage:function(){var a=this.kfEditor.requestService("render.get.paper");this._formatCanvas(),a.toPNG(function(a){document.body.innerHTML='<img style="background: red;" src="'+a+'">'}),this._restoreCanvas()},getImageData:function(a){var b=this.kfEditor.requestService("render.get.canvas"),c=this.kfEditor.requestService("render.get.paper");this._formatCanvas(),c.toPNG(function(c){a({width:b.width,height:b.height,img:c})}),this._restoreCanvas()},_formatCanvas:function(){var a=this.kfEditor.requestService("render.get.canvas"),b=a.container.getRenderBox();a.node.setAttribute("width",b.width),a.node.setAttribute("height",b.height),this.kfEditor.requestService("render.clear.canvas.transform"),this.kfEditor.requestService("control.cursor.hide"),this.kfEditor.requestService("render.clear.select")},_restoreCanvas:function(){var a=this.kfEditor.requestService("render.get.canvas");a.node.setAttribute("width","100%"),a.node.setAttribute("height","100%"),this.kfEditor.requestService("render.revert.canvas.transform"),this.kfEditor.requestService("control.cursor.relocation"),this.kfEditor.requestService("render.reselect")}})}},b[25]={value:function(){var a=b.r(20),c=b.r(19).Assembly,d={autoresize:!1,fontsize:50,padding:[2,5]},e=a.createClass("RenderComponent",{base:b.r(1),constructor:function(b,c){this.callBase(),this.options=a.Utils.extend({},d,c),this.kfEditor=b,this.assembly=null,this.formula=null,this.relDisabled=!1,this.canvasZoom=1,this.record={select:{},cursor:{},canvas:{}},this.initCanvas(),this.initServices(),this.initCommands()},initCanvas:function(){var a=this.kfEditor.requestService("ui.get.canvas.container"),b=this.kfEditor.getFormulaClass();this.assembly=new c(new b(a,this.options)),this.formula=this.assembly.formula,this.setCanvasToCenter()},setCanvasOffset:function(a,b){var c=this.formula.getViewBox();b=void 0!==b?b:-c.height/2,this.formula.setViewBox(a,b,c.width,c.height)},setCanvasToCenter:function(){var a=this.formula.getViewBox();this.formula.setViewBox(-a.width/2,-a.height/2,a.width,a.height)},initServices:function(){this.kfEditor.registerService("render.get.canvas",this,{getCanvas:this.getCanvas}),this.kfEditor.registerService("render.get.content.size",this,{getContentSize:this.getContentSize}),this.kfEditor.registerService("render.clear.canvas.transform",this,{clearCanvasOffset:this.clearCanvasTransform}),this.kfEditor.registerService("render.set.canvas.offset",this,{setCanvasOffset:this.setCanvasOffset}),this.kfEditor.registerService("render.set.canvas.to.center",this,{setCanvasToCenter:this.setCanvasToCenter}),this.kfEditor.registerService("render.revert.canvas.transform",this,{revertCanvasTransform:this.revertCanvasTransform}),this.kfEditor.registerService("render.relocation",this,{relocation:this.relocation}),this.kfEditor.registerService("render.disable.relocation",this,{disableRelocation:this.disableRelocation}),this.kfEditor.registerService("render.enable.relocation",this,{enableRelocation:this.enableRelocation}),this.kfEditor.registerService("render.select.group.content",this,{selectGroupContent:this.selectGroupContent}),this.kfEditor.registerService("render.select.group",this,{selectGroup:this.selectGroup}),this.kfEditor.registerService("render.select.group.all",this,{selectAllGroup:this.selectAllGroup}),this.kfEditor.registerService("render.tint.current.cursor",this,{tintCurrentGroup:this.tintCurrentGroup}),this.kfEditor.registerService("render.select.current.cursor",this,{selectCurrentCursor:this.selectCurrentCursor}),this.kfEditor.registerService("render.reselect",this,{reselect:this.reselect}),this.kfEditor.registerService("render.clear.select",this,{clearSelect:this.clearSelect}),this.kfEditor.registerService("render.set.canvas.zoom",this,{setCanvasZoom:this.setCanvasZoom}),this.kfEditor.registerService("render.get.canvas.zoom",this,{getCanvasZoom:this.getCanvasZoom}),this.kfEditor.registerService("render.get.paper.offset",this,{getPaperOffset:this.getPaperOffset}),this.kfEditor.registerService("render.draw",this,{render:this.render}),this.kfEditor.registerService("render.insert.string",this,{insertString:this.insertString}),this.kfEditor.registerService("render.insert.group",this,{insertGroup:this.insertGroup}),this.kfEditor.registerService("render.get.paper",this,{getPaper:this.getPaper})},initCommands:function(){this.kfEditor.registerCommand("render",this,function(a){this.render(a),this.kfEditor.requestService("ui.update.canvas.view")}),this.kfEditor.registerCommand("getPaper",this,this.getPaper)},relocation:function(){this.relDisabled?this.relocationToLeft():this.relocationToCenter()},relocationToCenter:function(){var a=this.formula.container.getRenderBox();this.formula.container.setTranslate(-a.width/2,-a.height/2),this.setCanvasToCenter()},relocationToLeft:function(){var a=this.formula.container.getRenderBox();this.formula.container.setTranslate(0,-a.height/2),this.setCanvasOffset(0)},selectGroup:function(a){var b=this.kfEditor.requestService("syntax.get.group.object",a);this.clearSelect(),b.node.getAttribute("data-root")||(this.record.select.lastSelect=b,b.select())},selectGroupContent:function(a){null!==a.groupObj.getAttribute("data-placeholder")&&(a={id:a.content[0].id});var b=this.kfEditor.requestService("syntax.get.group.object",a.id);this.clearSelect(),this.record.select.lastSelect=b,b.node.getAttribute("data-root")||b.select()},selectAllGroup:function(a){null!==a.groupObj.getAttribute("data-placeholder")&&(a={id:a.content[0].id});var b=this.kfEditor.requestService("syntax.get.group.object",a.id);this.clearSelect(),this.record.select.lastSelect=b,b.selectAll()},selectCurrentCursor:function(){var a=this.kfEditor.requestService("syntax.get.record.cursor"),b=this.kfEditor.requestService("syntax.get.group.object",a.groupId),c=null,d=-1,e=0,f=Math.min(a.startOffset,a.endOffset),g=Math.max(a.startOffset,a.endOffset);this.clearSelect(),this.record.select.lastSelect=b;for(var h=f,i=g;i>h;h++)c=b.getOperand(h).getRenderBox(b),-1==d&&(d=c.x),e+=c.width;b.setBoxWidth(e),b.selectAll(),b.getBox().setTranslate(d,0)},tintCurrentGroup:function(){var a=this.kfEditor.requestService("syntax.get.record.cursor").groupId,b=this.kfEditor.requestService("syntax.get.group.object",a),c=this.kfEditor.requestService("syntax.is.placeholder.node",a);this.clearSelect(),b.node.getAttribute("data-root")||(c&&(b=this.kfEditor.requestService("syntax.get.group.object",b.operands[0].node.id)),this.record.select.lastSelect=b,b.select())},reselect:function(){var a=this.kfEditor.requestService("syntax.get.record.cursor"),b=null;b=this.kfEditor.requestService("syntax.get.group.object",a.groupId),this.clearSelect(),this.record.select.lastSelect=b,b.node.getAttribute("data-root")||b.select()
},clearSelect:function(){var a=null,b=this.record.select.lastSelect;b&&b.node.ownerSVGElement&&(b.unselect(),a=b.getRenderBox(b),b.setBoxWidth(a.width),b.getBox().setTranslate(0,0))},getPaper:function(){return this.formula},render:function(a){var b=this.kfEditor.requestService("parser.parse",a,!0),c=this.assembly.regenerateBy(b);this.kfEditor.requestService("syntax.update.objtree",c)},enableRelocation:function(){this.relDisabled=!1},disableRelocation:function(){this.relDisabled=!0},setCanvasZoom:function(a){var b=this.formula.getViewPort();this.canvasZoom=a,b.zoom=a,this.formula.setViewPort(b)},getCanvas:function(){return this.formula},getContentSize:function(){return this.formula.container.getRenderBox()},clearCanvasTransform:function(){var a=this.record.canvas;a.viewBox=this.formula.getViewBox(),a.contentOffset=this.formula.container.getTranslate(),this.setCanvasToCenter(),this.formula.node.removeAttribute("viewBox"),this.formula.container.setTranslate(0,0)},revertCanvasTransform:function(){var a=this.record.canvas,b=a.viewBox;return b?(this.formula.setViewBox(b.x,b.y,b.width,b.height),this.formula.container.setTranslate(a.contentOffset),a.viewBox=null,void(a.contentOffset=null)):!1},getCanvasZoom:function(){return this.canvasZoom}});return e}},b[26]={value:function(){var a=b.r(20);return a.createClass("DeleteComponent",{constructor:function(a,b){this.parentComponent=a,this.kfEditor=b},deleteGroup:function(){var a=this.parentComponent.getCursorRecord(),b=this.parentComponent.getObjectTree(),c=b.mapping[a.groupId].strGroup;return a.startOffset!==a.endOffset?this.parentComponent.isSelectPlaceholder()?this.parentComponent.isRootTree(c)?!1:(a=this.selectParentContainer(a.groupId),this.parentComponent.updateCursor(a),!1):this.deleteSelection(c,a):0===a.startOffset?this.parentComponent.isRootTree(c)?!1:(a=this.selectParentContainer(a.groupId),this.parentComponent.updateCursor(a),!1):c.operand.length>1?(a=this.deletePrevGroup(c,a),this.parentComponent.updateCursor(a),a.startOffset===a.endOffset?!0:!1):(a.startOffset=0,a.endOffset=1,c.operand[0].attr&&this.parentComponent.isGroupNode(c.operand[0].attr.id)?(this.parentComponent.updateCursor(a),!1):(c.operand[0]={name:"placeholder",operand:[]},this.parentComponent.updateCursor(a),!0))},deletePrevGroup:function(a,b){var c=b.startOffset-1,d=a.operand[c];return this.parentComponent.isLeafTree(d)?(a.operand.splice(c,1),b.startOffset-=1,b.endOffset-=1):b.startOffset-=1,b},deleteSelection:function(a,b){return 0===b.startOffset&&b.endOffset===a.operand.length?(a.operand.length=1,a.operand[0]={name:"placeholder",operand:[]},b.endOffset=1):(a.operand.splice(b.startOffset,b.endOffset-b.startOffset),b.endOffset=b.startOffset),this.parentComponent.updateCursor(b),!0},selectParentContainer:function(a){var b=this.parentComponent.getGroupObject(a).node,c=this.kfEditor.requestService("position.get.group",b),d=this.kfEditor.requestService("position.get.index",c.groupObj,b);return{groupId:c.id,startOffset:d,endOffset:d+1}}})}},b[27]={value:function(){function a(a){var b=null,c=this.parentComponent,f=null;return f=c.getGroupContent(a.groupId),c.isSelectPlaceholder()?e(this,f.content[a.startOffset],p.LEFT):(a.startOffset===a.endOffset?a.startOffset>0?(b=f.content[a.startOffset-1],l(b)?a=d(this,b,p.LEFT):(a.startOffset-=1,m(b)||(a.endOffset=a.startOffset))):a=e(this,f.groupObj,p.LEFT):(a.startOffset=Math.min(a.startOffset,a.endOffset),a.endOffset=a.startOffset),a)}function c(a){var b=null,c=this.parentComponent,f=null;return f=c.getGroupContent(a.groupId),c.isSelectPlaceholder()?e(this,f.content[a.startOffset],p.RIGHT):(a.startOffset===a.endOffset?a.startOffset<f.content.length?(b=f.content[a.startOffset],l(b)?a=d(this,b,p.RIGHT):(a.startOffset+=1,m(b)||(a.endOffset=a.startOffset))):a=e(this,f.groupObj,p.RIGHT):(a.endOffset=Math.max(a.startOffset,a.endOffset),a.startOffset=a.endOffset),a)}function d(a,b,c){switch(c){case p.LEFT:return f(a,b);case p.RIGHT:return h(a,b)}throw new Error("undefined move direction!")}function e(a,b,c){switch(c){case p.LEFT:return g(a,b);case p.RIGHT:return i(a,b)}throw new Error("undefined move direction!")}function f(a,b){var c=a.parentComponent,d=null,e=null;if(m(b)||n(b))return g(a,b);if(l(b)){if(d=c.getGroupContent(b.id),e=d.content[d.content.length-1],n(e))return g(a,e);if(k(b))return m(e)?{groupId:b.id,startOffset:d.content.length-1,endOffset:d.content.length}:k(e)&&1===d.content.length?f(a,e):{groupId:b.id,startOffset:d.content.length,endOffset:d.content.length};for(;!k(e)&&!n(e)&&!m(e);)d=c.getGroupContent(e.id),e=d.content[d.content.length-1];return n(e)?g(a,e):m(e)?{groupId:e.id,startOffset:d.content.length,endOffset:d.content.length}:f(a,e)}return null}function g(a,b){var c=a.kfEditor,d=null;if(j(b))return null;for(d=c.requestService("position.get.parent.info",b);0===d.index;){if(j(d.group.groupObj))return{groupId:d.group.id,startOffset:0,endOffset:0};if(k(d.group.groupObj)&&d.group.content.length>1)return{groupId:d.group.id,startOffset:0,endOffset:0};d=c.requestService("position.get.parent.info",d.group.groupObj)}return k(d.group.groupObj)?{groupId:d.group.id,startOffset:d.index,endOffset:d.index}:(b=d.group.content[d.index-1],l(b)?k(b)?f(a,b):f(a,b):n(b)?g(a,b):{groupId:d.group.id,startOffset:d.index,endOffset:d.index})}function h(a,b){var c=a.parentComponent,d=null,e=null;if(l(b)){if(d=c.getGroupContent(b.id),e=d.content[0],k(b))return k(e)?h(a,e):m(e)?{groupId:b.id,startOffset:0,endOffset:1}:{groupId:b.id,startOffset:0,endOffset:0};for(;!k(e)&&!m(e)&&!n(e);)d=c.getGroupContent(e.id),e=d.content[0];return m(e)?{groupId:e.id,startOffset:0,endOffset:0}:n(e)?i(a,e):h(a,e)}return null}function i(a,b){var c=a.kfEditor,d=a.parentComponent,e=null,f=null;if(j(b))return null;for(e=c.requestService("position.get.parent.info",b);e.index===e.group.content.length-1;){if(j(e.group.groupObj))return{groupId:e.group.id,startOffset:e.group.content.length,endOffset:e.group.content.length};if(k(e.group.groupObj)&&e.group.content.length>1)return{groupId:e.group.id,startOffset:e.group.content.length,endOffset:e.group.content.length};e=c.requestService("position.get.parent.info",e.group.groupObj)}return b=e.group.content[e.index+1],n(b)?i(a,b):k(b)?(f=d.getGroupContent(b.id),d.isPlaceholder(f.content[0].id)?{groupId:b.id,startOffset:0,endOffset:1}:{groupId:b.id,startOffset:0,endOffset:0}):{groupId:e.group.id,startOffset:e.index+1,endOffset:e.index+1}}function j(a){return!!a.getAttribute("data-root")}function k(a){return"kf-editor-group"===a.getAttribute("data-type")}function l(a){var b=a.getAttribute("data-type");return"kf-editor-group"===b||"kf-editor-virtual-group"===b}function m(a){return"Placeholder"===a.getAttribute("data-flag")}function n(a){return"Empty"===a.getAttribute("data-flag")}var o=b.r(20),p={LEFT:"left",RIGHT:"right"};return o.createClass("MoveComponent",{constructor:function(a,b){this.parentComponent=a,this.kfEditor=b},leftMove:function(){var b=this.parentComponent.getCursorRecord();b=a.call(this,b),b&&this.parentComponent.updateCursor(b)},rightMove:function(){var a=this.parentComponent.getCursorRecord();a=c.call(this,a),a&&this.parentComponent.updateCursor(a)}})}},b[28]={value:function(){var a=b.r(20),c=b.r(27),d=b.r(26),e=b.r(29).cursorCharacter,f=b.r(11),g=a.createClass("SyntaxComponenet",{constructor:function(a){this.kfEditor=a,this.record={cursor:{group:null,startOffset:-1,endOffset:-1}},this.components={},this.objTree=null,this.initComponents(),this.initServices(),this.initCommands()},initComponents:function(){this.components.move=new c(this,this.kfEditor),this.components.delete=new d(this,this.kfEditor)},initServices:function(){this.kfEditor.registerService("syntax.update.objtree",this,{updateObjTree:this.updateObjTree}),this.kfEditor.registerService("syntax.get.objtree",this,{getObjectTree:this.getObjectTree}),this.kfEditor.registerService("syntax.get.group.object",this,{getGroupObject:this.getGroupObject}),this.kfEditor.registerService("syntax.is.root.node",this,{isRootNode:this.isRootNode}),this.kfEditor.registerService("syntax.is.group.node",this,{isGroupNode:this.isGroupNode}),this.kfEditor.registerService("syntax.is.virtual.node",this,{isVirtualNode:this.isVirtualNode}),this.kfEditor.registerService("syntax.is.placeholder.node",this,{isPlaceholder:this.isPlaceholder}),this.kfEditor.registerService("syntax.is.select.placeholder",this,{isSelectPlaceholder:this.isSelectPlaceholder}),this.kfEditor.registerService("syntax.has.root.placeholder",this,{hasRootplaceholder:this.hasRootplaceholder}),this.kfEditor.registerService("syntax.valid.brackets",this,{isBrackets:this.isBrackets}),this.kfEditor.registerService("syntax.get.group.content",this,{getGroupContent:this.getGroupContent}),this.kfEditor.registerService("syntax.get.root.group.info",this,{getRootGroupInfo:this.getRootGroupInfo}),this.kfEditor.registerService("syntax.get.root",this,{getRootObject:this.getRootObject}),this.kfEditor.registerService("syntax.update.record.cursor",this,{updateCursor:this.updateCursor}),this.kfEditor.registerService("syntax.update.selection",this,{updateSelection:this.updateSelection}),this.kfEditor.registerService("syntax.get.record.cursor",this,{getCursorRecord:this.getCursorRecord}),this.kfEditor.registerService("syntax.has.cursor.info",this,{hasCursorInfo:this.hasCursorInfo}),this.kfEditor.registerService("syntax.serialization",this,{serialization:this.serialization}),this.kfEditor.registerService("syntax.cursor.move.left",this,{leftMove:this.leftMove}),this.kfEditor.registerService("syntax.cursor.move.right",this,{rightMove:this.rightMove}),this.kfEditor.registerService("syntax.delete.group",this,{deleteGroup:this.deleteGroup})},initCommands:function(){this.kfEditor.registerCommand("get.source",this,this.getSource),this.kfEditor.registerCommand("content.is.empty",this,this.isEmpty)},updateObjTree:function(a){var b=a.select;b&&b.groupId&&this.updateCursor(b.groupId,b.startOffset,b.endOffset),this.objTree=a},hasCursorInfo:function(){return null!==this.record.cursor.group},isRootNode:function(a){return this.objTree.mapping.root.strGroup.attr.id===a},isGroupNode:function(a){var b=this.objTree.mapping[a].strGroup.attr["data-type"];return b===f.GROUP||b===f.VIRTUAL},isVirtualNode:function(a){return this.objTree.mapping[a].strGroup.attr["data-type"]===f.VIRTUAL},isPlaceholder:function(a){var b=this.objTree.mapping[a];return b?(b=b.objGroup.node,"Placeholder"===b.getAttribute("data-flag")):!1},isBrackets:function(a){return!!this.objTree.mapping[a].objGroup.node.getAttribute("data-brackets")},hasRootplaceholder:function(){return"placeholder"===this.objTree.mapping.root.strGroup.operand[0].name},isSelectPlaceholder:function(){var a=this.record.cursor,b=null;return a.endOffset-a.startOffset!==1?!1:(b=this.getGroupContent(a.groupId),this.isPlaceholder(b.content[a.startOffset].id)?!0:!1)},isLeafTree:function(a){return"string"==typeof a},isRootTree:function(a){return a.attr&&a.attr["data-root"]},getObjectTree:function(){return this.objTree},getGroupObject:function(a){return this.objTree.mapping[a].objGroup||null},getCursorRecord:function(){return a.Utils.extend({},this.record.cursor)||null},getGroupContent:function(b){var c=this.objTree.mapping[b],d=[],e=c.objGroup.operands,f=e.length-1,g="rtl"!==c.strGroup.traversal;return a.Utils.each(e,function(a,b){g?d.push(a.node):d[f-b]=a.node}),{id:b,traversal:c.strGroup.traversal||"ltr",groupObj:c.objGroup.node,content:d}},getRootObject:function(){return this.objTree.mapping.root.objGroup},getRootGroupInfo:function(){var a=this.objTree.mapping.root.strGroup.attr.id;return this.getGroupContent(a)},updateSelection:function(a){var b=this.objTree.mapping[a.id],c=b.strGroup,d=null,f=null,g=null,h=-1,i=-1;if(d=a,f=b,"combination"===c.name)this.record.cursor={groupId:d.id,startOffset:0,endOffset:c.operand.length},c.operand.unshift(e),c.operand.push(e);else{for(;"combination"!==f.strGroup.name||1===d.content;)a=d,b=f,d=this.kfEditor.requestService("position.get.parent.group",b.objGroup.node),f=this.objTree.mapping[d.id];var j=[].indexOf.call(d.content,a.groupObj);this.record.cursor={groupId:d.id,startOffset:j,endOffset:j+1},f.strGroup.operand.splice(j+1,0,e),f.strGroup.operand.splice(j,0,e)}return g=this.kfEditor.requestService("parser.latex.serialization",this.objTree.parsedTree),h=g.indexOf(e),g=g.replace(e,""),i=g.indexOf(e),f.strGroup.operand.splice(this.record.cursor.startOffset,1),f.strGroup.operand.splice(this.record.cursor.endOffset,1),{str:g,startOffset:h,endOffset:i}},getSource:function(){return this.serialization().str.replace(e,"").replace(e,"")},isEmpty:function(){return this.hasRootplaceholder()},serialization:function(){var a=this.record.cursor,b=this.objTree.mapping[a.groupId],c=b.strGroup,d=null,f=-1,g=-1;return f=Math.min(a.endOffset,a.startOffset),g=Math.max(a.endOffset,a.startOffset),c.operand.splice(g,0,e),c.operand.splice(f,0,e),g+=1,d=this.kfEditor.requestService("parser.latex.serialization",this.objTree.parsedTree),c.operand.splice(g,1),c.operand.splice(f,1),f=d.indexOf(e),a.startOffset===a.endOffset&&(d=d.replace(e,"")),g=d.lastIndexOf(e),{str:d,startOffset:f,endOffset:g}},updateCursor:function(a,b,c){var d=null;1===arguments.length&&(c=a.endOffset,b=a.startOffset,a=a.groupId),void 0===c&&(c=b),b>c&&(d=c,c=b,b=d),this.record.cursor={groupId:a,startOffset:b,endOffset:c}},leftMove:function(){this.components.move.leftMove()},rightMove:function(){this.components.move.rightMove()},deleteGroup:function(){return this.components.delete.deleteGroup()},insertSubtree:function(a){var b=this.record.cursor,c=0,d=0,e=null,f=0;this.isPlaceholder(b.groupId)?this.replaceTree(a):(c=Math.min(b.startOffset,b.endOffset),d=Math.max(b.startOffset,b.endOffset),f=d-c,e=this.objTree.mapping[b.groupId].strGroup,e.operand.splice(c,f,a),b.startOffset+=1,b.endOffset=b.startOffset)},replaceTree:function(a){var b=this.record.cursor,c=this.objTree.mapping[b.groupId].objGroup.node,d=this.kfEditor.requestService("position.get.parent.info",c),e=this.objTree.mapping[d.group.id].strGroup;e.operand[d.index]=a,b.groupId=d.group.id,b.startOffset=d.index+1,b.endOffset=d.index+1}});return g}},b[29]={value:function(){return{cursorCharacter:"\uf155",rootPlaceholder:{color:"#666",content:"\u5728\u6b64\u5904\u952e\u5165\u516c\u5f0f",fontsize:16},scrollbar:{padding:5,step:150}}}},b[30]={value:function(){return{"\\pm":{x:5,y:0},"\\infty":{x:42,y:0},"=":{x:79,y:0},"\\sim":{x:116,y:0},"\\times":{x:153,y:0},"\\div":{x:190,y:0},"!":{x:227,y:0},"<":{x:264,y:0},"\\ll":{x:301,y:0},">":{x:338,y:0},"\\gg":{x:375,y:0},"\\leq":{x:412,y:0},"\\geq":{x:449,y:0},"\\mp":{x:486,y:0},"\\cong":{x:523,y:0},"\\equiv":{x:560,y:0},"\\propto":{x:597,y:0},"\\approx":{x:634,y:0},"\\forall":{x:671,y:0},"\\partial":{x:708,y:0},"\\surd":{x:745,y:0},"\\cup":{x:782,y:0},"\\cap":{x:819,y:0},"\\varnothing":{x:856,y:0},"%":{x:893,y:0},"\\circ":{x:930,y:0},"\\exists":{x:967,y:0},"\\nexists":{x:1004,y:0},"\\in":{x:1041,y:0},"\\ni":{x:1078,y:0},"\\gets":{x:5,y:37},"\\uparrow":{x:42,y:37},"\\to":{x:79,y:37},"\\downarrow":{x:116,y:37},"\\leftrightarrow":{x:153,y:37},"\\therefore":{x:190,y:37},"\\because":{x:227,y:37},"+":{x:264,y:37},"-":{x:301,y:37},"\\neg":{x:338,y:37},"\\ast":{x:375,y:37},"\\cdot":{x:412,y:37},"\\vdots":{x:449,y:37},"\\ddots":{x:486,y:37},"\\aleph":{x:523,y:37},"\\beth":{x:560,y:37},"\\blacksquare":{x:597,y:37},"\\alpha":{x:634,y:37},"\\beta":{x:671,y:37},"\\gamma":{x:708,y:37},"\\delta":{x:745,y:37},"\\epsilon":{x:782,y:37},"\\zeta":{x:819,y:37},"\\eta":{x:856,y:37},"\\theta":{x:893,y:37},"\\iota":{x:930,y:37},"\\kappa":{x:967,y:37},"\\lambda":{x:1004,y:37},"\\mu":{x:1041,y:37},"\\nu":{x:1078,y:37},"\\xi":{x:5,y:74},"\\omicron":{x:42,y:74},"\\pi":{x:79,y:74},"\\rho":{x:116,y:74},"\\sigma":{x:153,y:74},"\\tau":{x:190,y:74},"\\upsilon":{x:227,y:74},"\\phi":{x:264,y:74},"\\chi":{x:301,y:74},"\\psi":{x:338,y:74},"\\omega":{x:375,y:74},"\\Alpha":{x:412,y:74},"\\Beta":{x:449,y:74},"\\Gamma":{x:486,y:74},"\\Delta":{x:523,y:74},"\\Epsilon":{x:560,y:74},"\\Zeta":{x:597,y:74},"\\Eta":{x:634,y:74},"\\Theta":{x:671,y:74},"\\Iota":{x:708,y:74},"\\Kappa":{x:745,y:74},"\\Lambda":{x:782,y:74},"\\Mu":{x:819,y:74},"\\Nu":{x:856,y:74},"\\Xi":{x:893,y:74},"\\Omicron":{x:930,y:74},"\\Pi":{x:967,y:74},"\\Rho":{x:1004,y:74},"\\Sigma":{x:1041,y:74},"\\Tau":{x:1078,y:74},"\\Upsilon":{x:5,y:111},"\\Phi":{x:42,y:111},"\\Chi":{x:79,y:111},"\\Psi":{x:116,y:111},"\\Omega":{x:153,y:111},"\\digamma":{x:190,y:111},"\\varepsilon":{x:227,y:111},"\\varkappa":{x:264,y:111},"\\varphi":{x:301,y:111},"\\varpi":{x:338,y:111},"\\varrho":{x:375,y:111},"\\varsigma":{x:412,y:111},"\\vartheta":{x:449,y:111},"\\neq":{x:486,y:111},"\\nless":{x:523,y:111},"\\ngtr":{x:560,y:111},"\\nleq":{x:597,y:111},"\\ngeq":{x:634,y:111},"\\nsim":{x:671,y:111},"\\lneqq":{x:708,y:111},"\\gneqq":{x:745,y:111},"\\nprec":{x:782,y:111},"\\nsucc":{x:819,y:111},"\\notin":{x:856,y:111},"\\nsubseteq":{x:893,y:111},"\\nsupseteq":{x:930,y:111},"\\subsetneq":{x:967,y:111},"\\supsetneq":{x:1004,y:111},"\\lnsim":{x:1041,y:111},"\\gnsim":{x:1078,y:111},"\\precnsim":{x:5,y:148},"\\succnsim":{x:42,y:148},"\\ntriangleleft":{x:79,y:148},"\\ntriangleright":{x:116,y:148},"\\ntrianglelefteq":{x:153,y:148},"\\ntrianglerighteq":{x:190,y:148},"\\nmid":{x:227,y:148},"\\nparallel":{x:264,y:148},"\\nvdash":{x:301,y:148},"\\nVdash":{x:338,y:148},"\\nvDash":{x:375,y:148},"\\nVDash":{x:412,y:148},"\\daleth":{x:449,y:148},"\\gimel":{x:486,y:148},"\\complement":{x:523,y:148},"\\ell":{x:560,y:148},"\\eth":{x:597,y:148},"\\hbar":{x:634,y:148},"\\hslash":{x:671,y:148},"\\mho":{x:708,y:148},"\\wp":{x:745,y:148},"\\circledS":{x:782,y:148},"\\Bbbk":{x:819,y:148},"\\Finv":{x:856,y:148},"\\Game":{x:893,y:148},"\\Im":{x:930,y:148},"\\Re":{x:967,y:148},"\\updownarrow":{x:1004,y:148},"\\Leftarrow":{x:1041,y:148},"\\Rightarrow":{x:1078,y:148},"\\Uparrow":{x:5,y:185},"\\Downarrow":{x:42,y:185},"\\Leftrightarrow":{x:79,y:185},"\\Updownarrow":{x:116,y:185},"\\longleftarrow":{x:153,y:185},"\\longrightarrow":{x:190,y:185},"\\longleftrightarrow":{x:227,y:185},"\\Longleftarrow":{x:264,y:185},"\\Longrightarrow":{x:301,y:185},"\\Longleftrightarrow":{x:338,y:185},"\\nearrow":{x:375,y:185},"\\nwarrow":{x:412,y:185},"\\searrow":{x:449,y:185},"\\swarrow":{x:486,y:185},"\\nleftarrow":{x:523,y:185},"\\nrightarrow":{x:560,y:185},"\\nLeftarrow":{x:597,y:185},"\\nRightarrow":{x:634,y:185},"\\nLeftrightarrow":{x:671,y:185},"\\leftharpoonup":{x:708,y:185},"\\leftharpoondown":{x:745,y:185},"\\rightharpoonup":{x:782,y:185},"\\rightharpoondown":{x:819,y:185},"\\upharpoonleft":{x:856,y:185},"\\upharpoonright":{x:893,y:185},"\\downharpoonleft":{x:930,y:185},"\\downharpoonright":{x:967,y:185},"\\leftrightharpoons":{x:1004,y:185},"\\rightleftharpoons":{x:1041,y:185},"\\leftleftarrows":{x:1078,y:185},"\\rightrightarrows":{x:5,y:222},"\\upuparrows":{x:42,y:222},"\\downdownarrows":{x:79,y:222},"\\leftrightarrows":{x:116,y:222},"\\rightleftarrows":{x:153,y:222},"\\looparrowleft":{x:190,y:222},"\\looparrowright":{x:227,y:222},"\\leftarrowtail":{x:264,y:222},"\\rightarrowtail":{x:301,y:222},"\\Lsh":{x:338,y:222},"\\Rsh":{x:375,y:222},"\\Lleftarrow":{x:412,y:222},"\\Rrightarrow":{x:449,y:222},"\\curvearrowleft":{x:486,y:222},"\\curvearrowright":{x:523,y:222},"\\circlearrowleft":{x:560,y:222},"\\circlearrowright":{x:597,y:222},"\\multimap":{x:634,y:222},"\\leftrightsquigarrow":{x:671,y:222},"\\twoheadleftarrow":{x:708,y:222},"\\twoheadrightarrow":{x:745,y:222},"\\rightsquigarrow":{x:782,y:222},"\\mathcal{A}":{x:819,y:222},"\\mathcal{B}":{x:856,y:222},"\\mathcal{C}":{x:893,y:222},"\\mathcal{D}":{x:930,y:222},"\\mathcal{E}":{x:967,y:222},"\\mathcal{F}":{x:1004,y:222},"\\mathcal{G}":{x:1041,y:222},"\\mathcal{H}":{x:1078,y:222},"\\mathcal{I}":{x:5,y:259},"\\mathcal{J}":{x:42,y:259},"\\mathcal{K}":{x:79,y:259},"\\mathcal{L}":{x:116,y:259},"\\mathcal{M}":{x:153,y:259},"\\mathcal{N}":{x:190,y:259},"\\mathcal{O}":{x:227,y:259},"\\mathcal{P}":{x:264,y:259},"\\mathcal{Q}":{x:301,y:259},"\\mathcal{R}":{x:338,y:259},"\\mathcal{S}":{x:375,y:259},"\\mathcal{T}":{x:412,y:259},"\\mathcal{U}":{x:449,y:259},"\\mathcal{V}":{x:486,y:259},"\\mathcal{W}":{x:523,y:259},"\\mathcal{X}":{x:560,y:259},"\\mathcal{Y}":{x:597,y:259},"\\mathcal{Z}":{x:634,y:259},"\\mathfrak{A}":{x:671,y:259},"\\mathfrak{B}":{x:708,y:259},"\\mathfrak{C}":{x:745,y:259},"\\mathfrak{D}":{x:782,y:259},"\\mathfrak{E}":{x:819,y:259},"\\mathfrak{F}":{x:856,y:259},"\\mathfrak{G}":{x:893,y:259},"\\mathfrak{H}":{x:930,y:259},"\\mathfrak{I}":{x:967,y:259},"\\mathfrak{J}":{x:1004,y:259},"\\mathfrak{K}":{x:1041,y:259},"\\mathfrak{L}":{x:1078,y:259},"\\mathfrak{M}":{x:5,y:296},"\\mathfrak{N}":{x:42,y:296},"\\mathfrak{O}":{x:79,y:296},"\\mathfrak{P}":{x:116,y:296},"\\mathfrak{Q}":{x:153,y:296},"\\mathfrak{R}":{x:190,y:296},"\\mathfrak{S}":{x:227,y:296},"\\mathfrak{T}":{x:264,y:296},"\\mathfrak{U}":{x:301,y:296},"\\mathfrak{V}":{x:338,y:296},"\\mathfrak{W}":{x:375,y:296},"\\mathfrak{X}":{x:412,y:296},"\\mathfrak{Y}":{x:449,y:296},"\\mathfrak{Z}":{x:486,y:296},"\\mathfrak{a}":{x:523,y:296},"\\mathfrak{b}":{x:560,y:296},"\\mathfrak{c}":{x:597,y:296},"\\mathfrak{d}":{x:634,y:296},"\\mathfrak{e}":{x:671,y:296},"\\mathfrak{f}":{x:708,y:296},"\\mathfrak{g}":{x:745,y:296},"\\mathfrak{h}":{x:782,y:296},"\\mathfrak{i}":{x:819,y:296},"\\mathfrak{j}":{x:856,y:296},"\\mathfrak{k}":{x:893,y:296},"\\mathfrak{l}":{x:930,y:296},"\\mathfrak{m}":{x:967,y:296},"\\mathfrak{n}":{x:1004,y:296},"\\mathfrak{o}":{x:1041,y:296},"\\mathfrak{p}":{x:1078,y:296},"\\mathfrak{q}":{x:5,y:333},"\\mathfrak{r}":{x:42,y:333},"\\mathfrak{s}":{x:79,y:333},"\\mathfrak{t}":{x:116,y:333},"\\mathfrak{u}":{x:153,y:333},"\\mathfrak{v}":{x:190,y:333},"\\mathfrak{w}":{x:227,y:333},"\\mathfrak{x}":{x:264,y:333},"\\mathfrak{y}":{x:301,y:333},"\\mathfrak{z}":{x:338,y:333},"\\mathbb{A}":{x:375,y:333},"\\mathbb{B}":{x:412,y:333},"\\mathbb{C}":{x:449,y:333},"\\mathbb{D}":{x:486,y:333},"\\mathbb{E}":{x:523,y:333},"\\mathbb{F}":{x:560,y:333},"\\mathbb{G}":{x:597,y:333},"\\mathbb{H}":{x:634,y:333},"\\mathbb{I}":{x:671,y:333},"\\mathbb{J}":{x:708,y:333},"\\mathbb{K}":{x:745,y:333},"\\mathbb{L}":{x:782,y:333},"\\mathbb{M}":{x:819,y:333},"\\mathbb{N}":{x:856,y:333},"\\mathbb{O}":{x:893,y:333},"\\mathbb{P}":{x:930,y:333},"\\mathbb{Q}":{x:967,y:333},"\\mathbb{R}":{x:1004,y:333},"\\mathbb{S}":{x:1041,y:333},"\\mathbb{T}":{x:1078,y:333},"\\mathbb{U}":{x:5,y:370},"\\mathbb{V}":{x:42,y:370},"\\mathbb{W}":{x:79,y:370},"\\mathbb{X}":{x:116,y:370},"\\mathbb{Y}":{x:153,y:370},"\\mathbb{Z}":{x:190,y:370},"\\mathrm{A}":{x:227,y:370},"\\mathrm{B}":{x:264,y:370},"\\mathrm{C}":{x:301,y:370},"\\mathrm{D}":{x:338,y:370},"\\mathrm{E}":{x:375,y:370},"\\mathrm{F}":{x:412,y:370},"\\mathrm{G}":{x:449,y:370},"\\mathrm{H}":{x:486,y:370},"\\mathrm{I}":{x:523,y:370},"\\mathrm{J}":{x:560,y:370},"\\mathrm{K}":{x:597,y:370},"\\mathrm{L}":{x:634,y:370},"\\mathrm{M}":{x:671,y:370},"\\mathrm{N}":{x:708,y:370},"\\mathrm{O}":{x:745,y:370},"\\mathrm{P}":{x:782,y:370},"\\mathrm{Q}":{x:819,y:370},"\\mathrm{R}":{x:856,y:370},"\\mathrm{S}":{x:893,y:370},"\\mathrm{T}":{x:930,y:370},"\\mathrm{U}":{x:967,y:370},"\\mathrm{V}":{x:1004,y:370},"\\mathrm{W}":{x:1041,y:370},"\\mathrm{X}":{x:1078,y:370},"\\mathrm{Y}":{x:5,y:407},"\\mathrm{Z}":{x:42,y:407},"\\mathrm{a}":{x:79,y:407},"\\mathrm{b}":{x:116,y:407},"\\mathrm{c}":{x:153,y:407},"\\mathrm{d}":{x:190,y:407},"\\mathrm{e}":{x:227,y:407},"\\mathrm{f}":{x:264,y:407},"\\mathrm{g}":{x:301,y:407},"\\mathrm{h}":{x:338,y:407},"\\mathrm{i}":{x:375,y:407},"\\mathrm{j}":{x:412,y:407},"\\mathrm{k}":{x:449,y:407},"\\mathrm{l}":{x:486,y:407},"\\mathrm{m}":{x:523,y:407},"\\mathrm{n}":{x:560,y:407},"\\mathrm{o}":{x:597,y:407},"\\mathrm{p}":{x:634,y:407},"\\mathrm{q}":{x:671,y:407},"\\mathrm{r}":{x:708,y:407},"\\mathrm{s}":{x:745,y:407},"\\mathrm{t}":{x:782,y:407},"\\mathrm{u}":{x:819,y:407},"\\mathrm{v}":{x:856,y:407},"\\mathrm{w}":{x:893,y:407},"\\mathrm{x}":{x:930,y:407},"\\mathrm{y}":{x:967,y:407},"\\mathrm{z}":{x:1004,y:407}}}},b[31]={value:function(){var a=b.r(4),c=b.r(20),d={min:1,max:2},e=c.createClass("ScrollZoomController",{constructor:function(b,c,e,f){this.kfEditor=c,this.target=e,this.zoom=1,this.step=.05,this.options=a.extend({},d,f),this.initEvent()},initEvent:function(){var b=this.kfEditor,c=this,d=this.options.min,e=this.options.max,f=this.step;a.addEvent(this.target,"mousewheel",function(a){a.preventDefault(),a.wheelDelta<0?c.zoom-=c.zoom*f:c.zoom+=c.zoom*f,c.zoom=Math.max(c.zoom,d),c.zoom=Math.min(c.zoom,e),b.requestService("render.set.canvas.zoom",c.zoom)})}});return e}},b[32]={value:function(){return{VIEW_STATE:{NO_OVERFLOW:0,OVERFLOW:1},scrollbar:{step:50,thumbMinSize:50}}}},b[33]={value:function(){return{"x=\\frac {-b\\pm\\sqrt {b^2-4ac}}{2a}":{pos:{x:0,y:0},size:{width:310,height:73}},"{\\placeholder/\\placeholder}":{pos:{x:315,y:0},size:{width:56,height:75}},"\\frac \\placeholder\\placeholder":{pos:{x:376,y:0},size:{width:56,height:75}},"a^2+b^2=c^2":{pos:{x:437,y:0},size:{width:310,height:73}},"{\\left(x+a\\right)}^2=\\sum^n_{k=0}{\\left(^n_k\\right)x^ka^{n-k}}":{pos:{x:752,y:0},size:{width:310,height:73}},"\\frac {dy}{dx}":{pos:{x:1067,y:0},size:{width:56,height:75}},"\\frac {\\Delta y}{\\Delta x}":{pos:{x:1128,y:0},size:{width:56,height:75}},"\\frac {\\delta y}{\\delta x}":{pos:{x:1189,y:0},size:{width:56,height:75}},"\\frac \\pi 2":{pos:{x:1250,y:0},size:{width:56,height:75}},"\\placeholder^\\placeholder":{pos:{x:1311,y:0},size:{width:56,height:75}},"\\placeholder^\\placeholder_\\placeholder":{pos:{x:1372,y:0},size:{width:56,height:75}},"\\placeholder_\\placeholder":{pos:{x:1433,y:0},size:{width:56,height:75}},"{^\\placeholder_\\placeholder\\placeholder}":{pos:{x:1494,y:0},size:{width:56,height:75}},"e^{-i\\omega t}":{pos:{x:1555,y:0},size:{width:56,height:75}},"x^2":{pos:{x:1616,y:0},size:{width:56,height:75}},"{}^n_1Y":{pos:{x:1677,y:0},size:{width:56,height:75}},"\\sqrt \\placeholder":{pos:{x:1738,y:0},size:{width:56,height:75}},"\\sqrt [\\placeholder] \\placeholder":{pos:{x:1799,y:0},size:{width:56,height:75}},"\\sqrt [2] \\placeholder":{pos:{x:1860,y:0},size:{width:56,height:75}},"\\sqrt [3] \\placeholder":{pos:{x:1921,y:0},size:{width:56,height:75}},"\\frac {-b\\pm\\sqrt{b^2-4ac}}{2a}":{pos:{x:1982,y:0},size:{width:137,height:75}},"\\sqrt {a^2+b^2}":{pos:{x:2124,y:0},size:{width:137,height:75}},"\\int \\placeholder":{pos:{x:2266,y:0},size:{width:56,height:75}},"\\int^\\placeholder_\\placeholder\\placeholder":{pos:{x:2327,y:0},size:{width:56,height:75}},"\\iint\\placeholder":{pos:{x:2388,y:0},size:{width:56,height:75}},"\\iint^\\placeholder_\\placeholder\\placeholder":{pos:{x:2449,y:0},size:{width:56,height:75}},"\\iiint\\placeholder":{pos:{x:2510,y:0},size:{width:56,height:75}},"\\iiint^\\placeholder_\\placeholder\\placeholder":{pos:{x:2571,y:0},size:{width:56,height:75}},"\\sum\\placeholder":{pos:{x:2632,y:0},size:{width:56,height:75}},"\\sum^\\placeholder_\\placeholder\\placeholder":{pos:{x:2693,y:0},size:{width:56,height:75}},"\\sum_\\placeholder\\placeholder":{pos:{x:2754,y:0},size:{width:56,height:75}},"\\left(\\placeholder\\right)":{pos:{x:2815,y:0},size:{width:56,height:75}},"\\left[\\placeholder\\right]":{pos:{x:2876,y:0},size:{width:56,height:75}},"\\left\\{\\placeholder\\right\\}":{pos:{x:2937,y:0},size:{width:56,height:75}},"\\left|\\placeholder\\right|":{pos:{x:2998,y:0},size:{width:56,height:75}},"\\sin\\placeholder":{pos:{x:3059,y:0},size:{width:56,height:75}},"\\cos\\placeholder":{pos:{x:3120,y:0},size:{width:56,height:75}},"\\tan\\placeholder":{pos:{x:3181,y:0},size:{width:56,height:75}},"\\csc\\placeholder":{pos:{x:3242,y:0},size:{width:56,height:75}},"\\sec\\placeholder":{pos:{x:3303,y:0},size:{width:56,height:75}},"\\cot\\placeholder":{pos:{x:3364,y:0},size:{width:56,height:75}},"\\sin\\theta":{pos:{x:3425,y:0},size:{width:56,height:75}},"\\cos{2x}":{pos:{x:3486,y:0},size:{width:56,height:75}},"\\tan\\theta=\\frac {\\sin\\theta}{\\cos\\theta}":{pos:{x:3547,y:0},size:{width:137,height:75}}}}},b[34]={value:function(){function a(a){var b=[],c=a.path,d=a.values;return e.Utils.each(d,function(a){var d=a,e=a;"string"!=typeof a?(d=a.img,e=a.key):e="\\"+a,b.push({item:{show:""+c+d.toLowerCase()+".png",val:e}})}),b}var c=b.r(41),d=b.r(40),e=b.r(20),f=[{type:c.DRAPDOWN_BOX,options:{button:{label:"\u9884\u8bbe<br/>",className:"yushe-btn",icon:"assets/images/toolbar/button/fx.png",iconSize:{w:40}},box:{width:367,group:[{title:"\u9884\u8bbe\u516c\u5f0f",items:[{title:"\u9884\u8bbe\u516c\u5f0f",content:[{label:"\u4e8c\u6b21\u516c\u5f0f",item:{show:"assets/images/toolbar/ys/1.png",val:"x=\\frac {-b\\pm\\sqrt {b^2-4ac}}{2a}"}},{label:"\u4e8c\u9879\u5f0f\u5b9a\u7406",item:{show:"assets/images/toolbar/ys/2.png",val:"{\\left(x+a\\right)}^2=\\sum^n_{k=0}{\\left(^n_k\\right)x^ka^{n-k}}"}},{label:"\u52fe\u80a1\u5b9a\u7406",item:{show:"assets/images/toolbar/ys/3.png",val:"a^2+b^2=c^2"}}]}]}]}}},{type:c.DELIMITER},{type:c.AREA,options:{box:{fixOffset:!0,width:527,type:d.OVERLAP,group:[{title:"\u57fa\u7840\u6570\u5b66",items:[]},{title:"\u5e0c\u814a\u5b57\u6bcd",items:[]},{title:"\u6c42\u53cd\u5173\u7cfb\u8fd0\u7b97\u7b26",items:[]},{title:"\u5b57\u6bcd\u7c7b\u7b26\u53f7",items:[]},{title:"\u7bad\u5934",items:[]},{title:"\u624b\u5199\u4f53",items:[]}]}}},{type:c.DELIMITER},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u5206\u6570<br/>",icon:"assets/images/toolbar/button/frac.png"},box:{width:332,group:[{title:"\u5206\u6570",items:[{title:"\u5206\u6570",content:[{item:{show:"assets/images/toolbar/frac/1.png",val:"\\frac \\placeholder\\placeholder"}},{item:{show:"assets/images/toolbar/frac/2.png",val:"{\\placeholder/\\placeholder}"}}]},{title:"\u5e38\u7528\u5206\u6570",content:[{item:{show:"assets/images/toolbar/frac/c1.png",val:"\\frac {dy}{dx}"}},{item:{show:"assets/images/toolbar/frac/c2.png",val:"\\frac {\\Delta y}{\\Delta x}"}},{item:{show:"assets/images/toolbar/frac/c4.png",val:"\\frac {\\delta y}{\\delta x}"}},{item:{show:"assets/images/toolbar/frac/c5.png",val:"\\frac \\pi 2"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u4e0a\u4e0b\u6807<br/>",icon:"assets/images/toolbar/button/script.png"},box:{width:332,group:[{title:"\u4e0a\u6807\u548c\u4e0b\u6807",items:[{title:"\u4e0a\u6807\u548c\u4e0b\u6807",content:[{item:{show:"assets/images/toolbar/script/1.png",val:"\\placeholder^\\placeholder"}},{item:{show:"assets/images/toolbar/script/2.png",val:"\\placeholder_\\placeholder"}},{item:{show:"assets/images/toolbar/script/3.png",val:"\\placeholder^\\placeholder_\\placeholder"}},{item:{show:"assets/images/toolbar/script/4.png",val:"{^\\placeholder_\\placeholder\\placeholder}"}}]},{title:"\u5e38\u7528\u7684\u4e0a\u6807\u548c\u4e0b\u6807",content:[{item:{show:"assets/images/toolbar/script/c1.png",val:"e^{-i\\omega t}"}},{item:{show:"assets/images/toolbar/script/c2.png",val:"x^2"}},{item:{show:"assets/images/toolbar/script/c3.png",val:"{}^n_1Y"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u6839\u5f0f<br/>",icon:"assets/images/toolbar/button/sqrt.png"},box:{width:342,group:[{title:"\u6839\u5f0f",items:[{title:"\u6839\u5f0f",content:[{item:{show:"assets/images/toolbar/sqrt/1.png",val:"\\sqrt \\placeholder"}},{item:{show:"assets/images/toolbar/sqrt/2.png",val:"\\sqrt [\\placeholder] \\placeholder"}},{item:{show:"assets/images/toolbar/sqrt/3.png",val:"\\sqrt [2] \\placeholder"}},{item:{show:"assets/images/toolbar/sqrt/4.png",val:"\\sqrt [3] \\placeholder"}}]},{title:"\u5e38\u7528\u6839\u5f0f",content:[{item:{show:"assets/images/toolbar/sqrt/c1.png",val:"\\frac {-b\\pm\\sqrt{b^2-4ac}}{2a}"}},{item:{show:"assets/images/toolbar/sqrt/c2.png",val:"\\sqrt {a^2+b^2}"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u79ef\u5206<br/>",icon:"assets/images/toolbar/button/int.png"},box:{width:332,group:[{title:"\u79ef\u5206",items:[{title:"\u79ef\u5206",content:[{item:{show:"assets/images/toolbar/int/1.png",val:"\\int \\placeholder"}},{item:{show:"assets/images/toolbar/int/2.png",val:"\\int^\\placeholder_\\placeholder\\placeholder"}},{item:{show:"assets/images/toolbar/int/3.png",val:"\\iint\\placeholder"}},{item:{show:"assets/images/toolbar/int/4.png",val:"\\iint^\\placeholder_\\placeholder\\placeholder"}},{item:{show:"assets/images/toolbar/int/5.png",val:"\\iiint\\placeholder"}},{item:{show:"assets/images/toolbar/int/6.png",val:"\\iiint^\\placeholder_\\placeholder\\placeholder"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u5927\u578b<br/>\u8fd0\u7b97\u7b26",icon:"assets/images/toolbar/button/sum.png"},box:{width:332,group:[{title:"\u6c42\u548c",items:[{title:"\u6c42\u548c",content:[{item:{show:"assets/images/toolbar/large/1.png",val:"\\sum\\placeholder"}},{item:{show:"assets/images/toolbar/large/2.png",val:"\\sum^\\placeholder_\\placeholder\\placeholder"}},{item:{show:"assets/images/toolbar/large/3.png",val:"\\sum_\\placeholder\\placeholder"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u62ec\u53f7<br/>",icon:"assets/images/toolbar/button/brackets.png"},box:{width:332,group:[{title:"\u65b9\u62ec\u53f7",items:[{title:"\u65b9\u62ec\u53f7",content:[{item:{show:"assets/images/toolbar/brackets/1.png",val:"\\left(\\placeholder\\right)"}},{item:{show:"assets/images/toolbar/brackets/2.png",val:"\\left[\\placeholder\\right]"}},{item:{show:"assets/images/toolbar/brackets/3.png",val:"\\left\\{\\placeholder\\right\\}"}},{item:{show:"assets/images/toolbar/brackets/4.png",val:"\\left|\\placeholder\\right|"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u51fd\u6570<br/>",icon:"assets/images/toolbar/button/sin.png"},box:{width:340,group:[{title:"\u51fd\u6570",items:[{title:"\u4e09\u89d2\u51fd\u6570",content:[{item:{show:"assets/images/toolbar/func/1.png",val:"\\sin\\placeholder"}},{item:{show:"assets/images/toolbar/func/2.png",val:"\\cos\\placeholder"}},{item:{show:"assets/images/toolbar/func/3.png",val:"\\tan\\placeholder"}},{item:{show:"assets/images/toolbar/func/4.png",val:"\\csc\\placeholder"}},{item:{show:"assets/images/toolbar/func/5.png",val:"\\sec\\placeholder"}},{item:{show:"assets/images/toolbar/func/6.png",val:"\\cot\\placeholder"}}]},{title:"\u5e38\u7528\u51fd\u6570",content:[{item:{show:"assets/images/toolbar/func/c1.png",val:"\\sin\\theta"}},{item:{show:"assets/images/toolbar/func/c2.png",val:"\\sin{2x}"}},{item:{show:"assets/images/toolbar/func/c3.png",val:"\\tan\\theta=\\frac {\\sin\\theta}{\\cos\\theta}"}}]}]}]}}}];
return function(){var b=["pm","infty",{key:"=",img:"eq"},"sim","times","div",{key:"!",img:"tanhao"},{key:"<",img:"lt"},"ll",{key:">",img:"gt"},"gg","leq","geq","mp","cong","equiv","propto","approx","forall","partial","surd","cup","cap","varnothing",{key:"%",img:"baifenhao"},"circ","exists","nexists","in","ni","gets","uparrow","to","downarrow","leftrightarrow","therefore","because",{key:"+",img:"plus"},{key:"-",img:"minus"},"neg","ast","cdot","vdots","ddots","aleph","beth","blacksquare"],c=f[2].options.box.group[0].items;c.push({title:"\u57fa\u7840\u6570\u5b66",content:a({path:"assets/images/toolbar/char/math/",values:b})})}(),function(){var b=[{title:"\u5c0f\u5199",values:["alpha","beta","gamma","delta","epsilon","zeta","eta","theta","iota","kappa","lambda","mu","nu","xi","omicron","pi","rho","sigma","tau","upsilon","phi","chi","psi","omega"]},{title:"\u5927\u5199",values:["Alpha","Beta","Gamma","Delta","Epsilon","Zeta","Eta","Theta","Iota","Kappa","Lambda","Mu","Nu","Xi","Omicron","Pi","Rho","Sigma","Tau","Upsilon","Phi","Chi","Psi","Omega"]},{title:"\u53d8\u4f53",values:["digamma","varepsilon","varkappa","varphi","varpi","varrho","varsigma","vartheta"]}],c=f[2].options.box.group[1].items;c.push({title:b[0].title,content:a({path:"assets/images/toolbar/char/greek/lower/",values:b[0].values})}),c.push({title:b[1].title,content:a({path:"assets/images/toolbar/char/greek/upper/",values:b[1].values})}),c.push({title:b[2].title,content:a({path:"assets/images/toolbar/char/greek/misc/",values:b[2].values})})}(),function(){var b=[{title:"\u6c42\u53cd\u5173\u7cfb\u8fd0\u7b97\u7b26",values:["neq","nless","ngtr","nleq","ngeq","nsim","lneqq","gneqq","nprec","nsucc","notin","nsubseteq","nsupseteq","subsetneq","supsetneq","lnsim","gnsim","precnsim","succnsim","ntriangleleft","ntriangleright","ntrianglelefteq","ntrianglerighteq","nmid","nparallel","nvdash",{key:"\\nVdash",img:"nvdash-1"},{key:"\\nvDash",img:"nvdash-2"},{key:"\\nVDash",img:"nvdash-3"},"nexists"]}],c=f[2].options.box.group[2].items;c.push({title:b[0].title,content:a({path:"assets/images/toolbar/char/not/",values:b[0].values})})}(),function(){var b=["aleph","beth","daleth","gimel","complement","ell","eth","hbar","hslash","mho","partial","wp","circledS","Bbbk","Finv","Game","Im","Re"],c=f[2].options.box.group[3].items;c.push({title:"\u5b57\u6bcd\u7c7b\u7b26\u53f7",content:a({path:"assets/images/toolbar/alphabetic/",values:b})})}(),function(){var b=["gets","to","uparrow","downarrow","leftrightarrow","updownarrow",{key:"\\Leftarrow",img:"u-leftarrow"},{key:"\\Rightarrow",img:"u-rightarrow"},{key:"\\Uparrow",img:"u-uparrow"},{key:"\\Downarrow",img:"u-downarrow"},{key:"\\Leftrightarrow",img:"u-leftrightarrow"},{key:"\\Updownarrow",img:"u-updownarrow"},"longleftarrow","longrightarrow","longleftrightarrow",{key:"\\Longleftarrow",img:"u-longleftarrow"},{key:"\\Longrightarrow",img:"u-longrightarrow"},{key:"\\Longleftrightarrow",img:"u-longleftrightarrow"},"nearrow","nwarrow","searrow","swarrow","nleftarrow","nrightarrow",{key:"\\nLeftarrow",img:"u-nleftarrow"},{key:"\\nRightarrow",img:"u-nrightarrow"},{key:"\\nLeftrightarrow",img:"u-nleftrightarrow"},"leftharpoonup","leftharpoondown","rightharpoonup","rightharpoondown","upharpoonleft","upharpoonright","downharpoonleft","downharpoonright","leftrightharpoons","rightleftharpoons","leftleftarrows","rightrightarrows","upuparrows","downdownarrows","leftrightarrows","rightleftarrows","looparrowleft","looparrowright","leftarrowtail","rightarrowtail",{key:"\\Lsh",img:"u-lsh"},{key:"\\Rsh",img:"u-rsh"},{key:"\\Lleftarrow",img:"u-lleftarrow"},{key:"\\Rrightarrow",img:"u-rrightarrow"},"curvearrowleft","curvearrowright","circlearrowleft","circlearrowright","multimap","leftrightsquigarrow","twoheadleftarrow","twoheadrightarrow","rightsquigarrow"],c=f[2].options.box.group[4].items;c.push({title:"\u7bad\u5934",content:a({path:"assets/images/toolbar/arrow/",values:b})})}(),function(){var b=[{title:"\u624b\u5199\u4f53",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]},{title:"\u82b1\u4f53",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]},{title:"\u53cc\u7ebf",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]},{title:"\u7f57\u9a6c",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]}],c=f[2].options.box.group[5].items;e.Utils.each(b[0].values,function(a,c){b[0].values[c]={key:"\\mathcal{"+a+"}",img:a.toLowerCase()}}),e.Utils.each(b[1].values,function(a,c){b[1].values[c]={key:"\\mathfrak{"+a+"}",img:a.replace(/[A-Z]/,function(a){return"u"+a.toLowerCase()})}}),e.Utils.each(b[2].values,function(a,c){b[2].values[c]={key:"\\mathbb{"+a+"}",img:a.toLowerCase()}}),e.Utils.each(b[3].values,function(a,c){b[3].values[c]={key:"\\mathrm{"+a+"}",img:a.replace(/[A-Z]/,function(a){return"u"+a.toLowerCase()})}}),c.push({title:b[0].title,content:a({path:"assets/images/toolbar/char/cal/",values:b[0].values})}),c.push({title:b[1].title,content:a({path:"assets/images/toolbar/char/frak/",values:b[1].values})}),c.push({title:b[2].title,content:a({path:"assets/images/toolbar/char/bb/",values:b[2].values})}),c.push({title:b[3].title,content:a({path:"assets/images/toolbar/char/rm/",values:b[3].values})})}(),window.iconConfig=f,f}},b[35]={value:function(){function a(a,b){var c=[];return g.Utils.each(a,function(a){a.length>1&&(a="\\"+a),c.push({key:a,img:b,pos:e[a]})}),c}var c=b.r(41),d=b.r(40),e=b.r(30),f=b.r(33),g=b.r(20),h=[{type:c.DRAPDOWN_BOX,options:{button:{label:"\u9884\u8bbe<br/>",className:"yushe-btn",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:0,y:0},iconSize:{w:40}},box:{width:367,group:[{title:"\u9884\u8bbe\u516c\u5f0f",items:[{title:"\u9884\u8bbe\u516c\u5f0f",content:[{label:"\u4e8c\u6b21\u516c\u5f0f",item:{val:"x=\\frac {-b\\pm\\sqrt {b^2-4ac}}{2a}"}},{label:"\u4e8c\u9879\u5f0f\u5b9a\u7406",item:{val:"{\\left(x+a\\right)}^2=\\sum^n_{k=0}{\\left(^n_k\\right)x^ka^{n-k}}"}},{label:"\u52fe\u80a1\u5b9a\u7406",item:{val:"a^2+b^2=c^2"}}]}]}]}}},{type:c.DELIMITER},{type:c.AREA,options:{box:{fixOffset:!0,width:527,type:d.OVERLAP,group:[{title:"\u57fa\u7840\u6570\u5b66",items:[]},{title:"\u5e0c\u814a\u5b57\u6bcd",items:[]},{title:"\u6c42\u53cd\u5173\u7cfb\u8fd0\u7b97\u7b26",items:[]},{title:"\u5b57\u6bcd\u7c7b\u7b26\u53f7",items:[]},{title:"\u7bad\u5934",items:[]},{title:"\u624b\u5199\u4f53",items:[]}]}}},{type:c.DELIMITER},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u5206\u6570<br/>",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:45,y:0}},box:{width:332,group:[{title:"\u5206\u6570",items:[{title:"\u5206\u6570",content:[{item:{val:"\\frac \\placeholder\\placeholder"}},{item:{val:"{\\placeholder/\\placeholder}"}}]},{title:"\u5e38\u7528\u5206\u6570",content:[{item:{val:"\\frac {dy}{dx}"}},{item:{val:"\\frac {\\Delta y}{\\Delta x}"}},{item:{val:"\\frac {\\delta y}{\\delta x}"}},{item:{val:"\\frac \\pi 2"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u4e0a\u4e0b\u6807<br/>",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:82,y:0}},box:{width:332,group:[{title:"\u4e0a\u6807\u548c\u4e0b\u6807",items:[{title:"\u4e0a\u6807\u548c\u4e0b\u6807",content:[{item:{val:"\\placeholder^\\placeholder"}},{item:{val:"\\placeholder_\\placeholder"}},{item:{val:"\\placeholder^\\placeholder_\\placeholder"}},{item:{val:"{^\\placeholder_\\placeholder\\placeholder}"}}]},{title:"\u5e38\u7528\u7684\u4e0a\u6807\u548c\u4e0b\u6807",content:[{item:{val:"e^{-i\\omega t}"}},{item:{val:"x^2"}},{item:{val:"{}^n_1Y"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u6839\u5f0f<br/>",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:119,y:0}},box:{width:342,group:[{title:"\u6839\u5f0f",items:[{title:"\u6839\u5f0f",content:[{item:{val:"\\sqrt \\placeholder"}},{item:{val:"\\sqrt [\\placeholder] \\placeholder"}},{item:{val:"\\sqrt [2] \\placeholder"}},{item:{val:"\\sqrt [3] \\placeholder"}}]},{title:"\u5e38\u7528\u6839\u5f0f",content:[{item:{val:"\\frac {-b\\pm\\sqrt{b^2-4ac}}{2a}"}},{item:{val:"\\sqrt {a^2+b^2}"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u79ef\u5206<br/>",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:156,y:0}},box:{width:332,group:[{title:"\u79ef\u5206",items:[{title:"\u79ef\u5206",content:[{item:{val:"\\int \\placeholder"}},{item:{val:"\\int^\\placeholder_\\placeholder\\placeholder"}},{item:{val:"\\iint\\placeholder"}},{item:{val:"\\iint^\\placeholder_\\placeholder\\placeholder"}},{item:{val:"\\iiint\\placeholder"}},{item:{val:"\\iiint^\\placeholder_\\placeholder\\placeholder"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u5927\u578b<br/>\u8fd0\u7b97\u7b26",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:193,y:0}},box:{width:332,group:[{title:"\u6c42\u548c",items:[{title:"\u6c42\u548c",content:[{item:{val:"\\sum\\placeholder"}},{item:{val:"\\sum^\\placeholder_\\placeholder\\placeholder"}},{item:{val:"\\sum_\\placeholder\\placeholder"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u62ec\u53f7<br/>",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:230,y:0}},box:{width:332,group:[{title:"\u65b9\u62ec\u53f7",items:[{title:"\u65b9\u62ec\u53f7",content:[{item:{val:"\\left(\\placeholder\\right)"}},{item:{val:"\\left[\\placeholder\\right]"}},{item:{val:"\\left\\{\\placeholder\\right\\}"}},{item:{val:"\\left|\\placeholder\\right|"}}]}]}]}}},{type:c.DRAPDOWN_BOX,options:{button:{label:"\u51fd\u6570<br/>",icon:{src:"kityformula/assets/images/toolbar/btn.png",x:267,y:0}},box:{width:340,group:[{title:"\u51fd\u6570",items:[{title:"\u4e09\u89d2\u51fd\u6570",content:[{item:{val:"\\sin\\placeholder"}},{item:{val:"\\cos\\placeholder"}},{item:{val:"\\tan\\placeholder"}},{item:{val:"\\csc\\placeholder"}},{item:{val:"\\sec\\placeholder"}},{item:{val:"\\cot\\placeholder"}}]},{title:"\u5e38\u7528\u51fd\u6570",content:[{item:{val:"\\sin\\theta"}},{item:{val:"\\cos{2x}"}},{item:{val:"\\tan\\theta=\\frac {\\sin\\theta}{\\cos\\theta}"}}]}]}]}}}];return function(){var a=[],b="kityformula/assets/images/toolbar/other.png",d=[];g.Utils.each(h,function(b){b.type!==c.DELIMITER&&(b=b.options.box.group,a=a.concat(b))}),g.Utils.each(a,function(a){a=a.items;for(var b=0,c=a.length;c>b;b++)d=d.concat(a[b].content)}),g.Utils.each(d,function(a){var c=f[a.item.val];c&&(a.item.img=b,a.item.pos=c.pos,a.item.size=c.size)})}(),function(){var b=["pm","infty","=","sim","times","div","!","<","ll",">","gg","leq","geq","mp","cong","equiv","propto","approx","forall","partial","surd","cup","cap","varnothing","%","circ","exists","nexists","in","ni","gets","uparrow","to","downarrow","leftrightarrow","therefore","because","+","-","neg","ast","cdot","vdots","aleph","beth","blacksquare"],c=h[2].options.box.group[0].items;c.push({title:"\u57fa\u7840\u6570\u5b66",content:a(b,"kityformula/assets/images/toolbar/char.png")})}(),function(){var b=[{title:"\u5c0f\u5199",values:["alpha","beta","gamma","delta","epsilon","zeta","eta","theta","iota","kappa","lambda","mu","nu","xi","omicron","pi","rho","sigma","tau","upsilon","phi","chi","psi","omega"]},{title:"\u5927\u5199",values:["Alpha","Beta","Gamma","Delta","Epsilon","Zeta","Eta","Theta","Iota","Kappa","Lambda","Mu","Nu","Xi","Omicron","Pi","Rho","Sigma","Tau","Upsilon","Phi","Chi","Psi","Omega"]},{title:"\u53d8\u4f53",values:["digamma","varepsilon","varkappa","varphi","varpi","varrho","varsigma","vartheta"]}],c=h[2].options.box.group[1].items;c.push({title:b[0].title,content:a(b[0].values,"kityformula/assets/images/toolbar/char.png")}),c.push({title:b[1].title,content:a(b[1].values,"kityformula/assets/images/toolbar/char.png")}),c.push({title:b[2].title,content:a(b[2].values,"kityformula/assets/images/toolbar/char.png")})}(),function(){var b=[{title:"\u6c42\u53cd\u5173\u7cfb\u8fd0\u7b97\u7b26",values:["neq","nless","ngtr","nleq","ngeq","nsim","lneqq","gneqq","nprec","nsucc","notin","nsubseteq","nsupseteq","subsetneq","supsetneq","lnsim","gnsim","precnsim","succnsim","ntriangleleft","ntriangleright","ntrianglelefteq","ntrianglerighteq","nmid","nparallel","nvdash","nVdash","nvDash","nVDash","nexists"]}],c=h[2].options.box.group[2].items;c.push({title:b[0].title,content:a(b[0].values,"kityformula/assets/images/toolbar/char.png")})}(),function(){var b=["aleph","beth","daleth","gimel","complement","ell","eth","hbar","hslash","mho","partial","wp","circledS","Bbbk","Finv","Game","Im","Re"],c=h[2].options.box.group[3].items;c.push({title:"\u5b57\u6bcd\u7c7b\u7b26\u53f7",content:a(b,"kityformula/assets/images/toolbar/char.png")})}(),function(){var b=["gets","to","uparrow","downarrow","leftrightarrow","updownarrow","Leftarrow","Rightarrow","Uparrow","Downarrow","Leftrightarrow","Updownarrow","longleftarrow","longrightarrow","longleftrightarrow","Longleftarrow","Longrightarrow","Longleftrightarrow","nearrow","nwarrow","searrow","swarrow","nleftarrow","nrightarrow","nLeftarrow","nRightarrow","nLeftrightarrow","leftharpoonup","leftharpoondown","rightharpoonup","rightharpoondown","upharpoonleft","upharpoonright","downharpoonleft","downharpoonright","leftrightharpoons","rightleftharpoons","leftleftarrows","rightrightarrows","upuparrows","downdownarrows","leftrightarrows","rightleftarrows","looparrowleft","looparrowright","leftarrowtail","rightarrowtail","Lsh","Rsh","Lleftarrow","Rrightarrow","curvearrowleft","curvearrowright","circlearrowleft","circlearrowright","multimap","leftrightsquigarrow","twoheadleftarrow","twoheadrightarrow","rightsquigarrow"],c=h[2].options.box.group[4].items;c.push({title:"\u7bad\u5934",content:a(b,"kityformula/assets/images/toolbar/char.png")})}(),function(){var b=[{title:"\u624b\u5199\u4f53",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]},{title:"\u82b1\u4f53",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]},{title:"\u53cc\u7ebf",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]},{title:"\u7f57\u9a6c",values:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]}],c=h[2].options.box.group[5].items;g.Utils.each(b[0].values,function(a,c){b[0].values[c]="mathcal{"+a+"}"}),g.Utils.each(b[1].values,function(a,c){b[1].values[c]="mathfrak{"+a+"}"}),g.Utils.each(b[2].values,function(a,c){b[2].values[c]="mathbb{"+a+"}"}),g.Utils.each(b[3].values,function(a,c){b[3].values[c]="mathrm{"+a+"}"}),c.push({title:b[0].title,content:a(b[0].values,"kityformula/assets/images/toolbar/char.png")}),c.push({title:b[1].title,content:a(b[1].values,"kityformula/assets/images/toolbar/char.png")}),c.push({title:b[2].title,content:a(b[2].values,"kityformula/assets/images/toolbar/char.png")}),c.push({title:b[3].title,content:a(b[3].values,"kityformula/assets/images/toolbar/char.png")})}(),h}},b[36]={value:function(){function a(a,b,f){switch(a){case i.DRAPDOWN_BOX:return c(b,f);case i.DELIMITER:return d(b);case i.AREA:return e(b,f)}}function c(a,b){return new g.DrapdownBox(a,b)}function d(a){return new g.Delimiter(a)}function e(a,b){return new g.Area(a,b)}var f=b.r(20),g=b.r(48),h=b.r(47),i=b.r(41),j=f.createClass("Tollbar",{constructor:function(a,b,c){this.kfEditor=b,this.uiComponent=a,this.elementList=c,this.elements=[],this.initToolbarElements(),this.initServices(),this.initEvent()},initServices:function(){this.kfEditor.registerService("ui.toolbar.disable",this,{disableToolbar:this.disableToolbar}),this.kfEditor.registerService("ui.toolbar.enable",this,{enableToolbar:this.enableToolbar}),this.kfEditor.registerService("ui.toolbar.close",this,{closeToolbar:this.closeToolbar})},initEvent:function(){var a=this;h.on(this.uiComponent.toolbarContainer,"mousedown",function(a){a.preventDefault()}),h.on(this.uiComponent.toolbarContainer,"mousewheel",function(a){a.preventDefault()}),h.on(this.kfEditor.getContainer(),"mousedown",function(){a.notify("closeAll")}),h.subscribe("data.select",function(b){a.insertSource(b)})},insertSource:function(a){this.kfEditor.requestService("control.insert.string",a)},disableToolbar:function(){f.Utils.each(this.elements,function(a){a.disable&&a.disable()})},enableToolbar:function(){f.Utils.each(this.elements,function(a){a.enable&&a.enable()})},getContainer:function(){return this.kfEditor.requestService("ui.get.canvas.container")},closeToolbar:function(){this.closeElement()},notify:function(a){switch(a){case"closeAll":case"closeOther":return void this.closeElement(arguments[1])}},closeElement:function(a){f.Utils.each(this.elements,function(b){b!=a&&b.hide&&b.hide()})},initToolbarElements:function(){var b=this.elements,c=this.uiComponent.toolbarContainer.ownerDocument,d=this;f.Utils.each(this.elementList,function(e){var f=a(e.type,c,e.options);b.push(f),d.appendElement(f)})},appendElement:function(a){a.setToolbar(this),a.attachTo(this.uiComponent.toolbarContainer)}});return j}},b[37]={value:function(){var a=b.r(20),c="kf-editor-ui-",d=66,e=b.r(47),f=b.r(38),g=a.createClass("Area",{constructor:function(a,b){this.options=b,this.doc=a,this.toolbar=null,this.disabled=!0,this.panelIndex=0,this.maxPanelIndex=0,this.currentItemCount=0,this.lineMaxCount=9,this.element=this.createArea(),this.container=this.createContainer(),this.panel=this.createPanel(),this.buttonContainer=this.createButtonContainer(),this.button=this.createButton(),this.mountPoint=this.createMountPoint(),this.moveDownButton=this.createMoveDownButton(),this.moveUpButton=this.createMoveUpButton(),this.boxObject=this.createBox(),this.mergeElement(),this.mount(),this.setListener(),this.initEvent()},initEvent:function(){var a=this;e.on(this.button,"mousedown",function(b){b.preventDefault(),b.stopPropagation(),1!==b.which||a.disabled||(a.showMount(),a.toolbar.notify("closeOther",a))}),e.on(this.moveDownButton,"mousedown",function(b){b.preventDefault(),b.stopPropagation(),1!==b.which||a.disabled||(a.nextPanel(),a.toolbar.notify("closeOther",a))}),e.on(this.moveUpButton,"mousedown",function(b){b.preventDefault(),b.stopPropagation(),1!==b.which||a.disabled||(a.prevPanel(),a.toolbar.notify("closeOther",a))}),e.delegate(this.container,".kf-editor-ui-area-item","mousedown",function(b){b.preventDefault(),1!==b.which||a.disabled||e.publish("data.select",this.getAttribute("data-value"))}),this.boxObject.initEvent()},disable:function(){this.disabled=!0,this.boxObject.disable(),e.getClassList(this.element).remove(c+"enabled")},enable:function(){this.disabled=!1,this.boxObject.enable(),e.getClassList(this.element).add(c+"enabled")},setListener:function(){var a=this;this.boxObject.setSelectHandler(function(b){e.publish("data.select",b),a.hide()}),this.boxObject.setChangeHandler(function(){a.updateContent()})},createArea:function(){var a=e.ele(this.doc,"div",{className:c+"area"});return"width"in this.options&&(a.style.width=this.options.width+"px"),a},checkMaxPanelIndex:function(){this.maxPanelIndex=Math.ceil(this.currentItemCount/this.lineMaxCount/2)},updateContent:function(){var b=this.boxObject.getOverlapContent(),d=0,e=null,f=0,g=0,h=this.lineMaxCount,i=[];this.panel.innerHTML="",a.Utils.each(b,function(b){var j=b.content;a.Utils.each(j,function(a){f=Math.floor(d/h),g=d%h,d++,e="top: "+(33*f+5)+"px; left: "+(32*g+5)+"px;",i.push('<div class="'+c+'area-item" data-value="'+a.key+'" style="'+e+'"><div class="'+c+'area-item-inner"><div class="'+c+'area-item-img" style="background: url('+a.img+") no-repeat "+-a.pos.x+"px "+-a.pos.y+'px;"></div></div></div>')})}),this.currentItemCount=d,this.panelIndex=0,this.panel.style.top=0,this.panel.innerHTML=i.join(""),this.checkMaxPanelIndex(),this.updatePanelButtonState()},mount:function(){this.boxObject.mountTo(this.mountPoint)},showMount:function(){this.mountPoint.style.display="block",this.boxObject.updateSize()},hideMount:function(){this.mountPoint.style.display="none"},hide:function(){this.hideMount(),this.boxObject.hide()},createButton:function(){return e.ele(this.doc,"div",{className:c+"area-button"})},createMoveDownButton:function(){return e.ele(this.doc,"div",{className:c+"movedown-button",content:""})},createMoveUpButton:function(){return e.ele(this.doc,"div",{className:c+"moveup-button",content:""})},createMountPoint:function(){return e.ele(this.doc,"div",{className:c+"area-mount"})},createBox:function(){return new f(this.doc,this.options.box)},createContainer:function(){return e.ele(this.doc,"div",{className:c+"area-container"})},createPanel:function(){return e.ele(this.doc,"div",{className:c+"area-panel"})},createButtonContainer:function(){return e.ele(this.doc,"div",{className:c+"area-button-container"})},mergeElement:function(){this.buttonContainer.appendChild(this.moveUpButton),this.buttonContainer.appendChild(this.moveDownButton),this.buttonContainer.appendChild(this.button),this.container.appendChild(this.panel),this.element.appendChild(this.container),this.element.appendChild(this.buttonContainer),this.element.appendChild(this.mountPoint)},disablePanelUp:function(){this.disabledUp=!0,e.getClassList(this.moveUpButton).add("kf-editor-ui-disabled")},enablePanelUp:function(){this.disabledUp=!1,e.getClassList(this.moveUpButton).remove("kf-editor-ui-disabled")},disablePanelDown:function(){this.disabledDown=!0,e.getClassList(this.moveDownButton).add("kf-editor-ui-disabled")},enablePanelDown:function(){this.disabledDown=!1,e.getClassList(this.moveDownButton).remove("kf-editor-ui-disabled")},updatePanelButtonState:function(){0===this.panelIndex?this.disablePanelUp():this.enablePanelUp(),this.panelIndex+1>=this.maxPanelIndex?this.disablePanelDown():this.enablePanelDown()},nextPanel:function(){this.disabledDown||this.panelIndex+1>=this.maxPanelIndex||(this.panelIndex++,this.panel.style.top=-this.panelIndex*d+"px",this.updatePanelButtonState())},prevPanel:function(){this.disabledUp||0!==this.panelIndex&&(this.panelIndex--,this.panel.style.top=-this.panelIndex*d+"px",this.updatePanelButtonState())},setToolbar:function(a){this.toolbar=a,this.boxObject.setToolbar(a)},attachTo:function(a){a.appendChild(this.element),this.updateContent(),this.updatePanelButtonState()}});return g}},b[38]={value:function(){function a(a,b,c){var d=[];return h.Utils.each(b,function(b){d.push(new q(c,a,b))}),d}function c(a){return j.ele(a,"div",{className:i+"overlap-container"})}function d(a,b){return new m(a,{className:"overlap-button",label:"",fixOffset:b.fixOffset})}function e(a,b){return new n(a,b)}function f(a){return a.getBoundingClientRect()}function g(a){var b="background: url( "+a.img+" ) no-repeat ";return b+=-a.pos.x+"px ",b+=-a.pos.y+"px;",b+=" width: "+a.size.width+"px;",b+=" height: "+a.size.height+"px;"}var h=b.r(20),i="kf-editor-ui-",j=b.r(47),k=b.r(40),l=b.r(42),m=b.r(39),n=b.r(45),o=20,p=h.createClass("Box",{constructor:function(a,b){this.options=b,this.toolbar=null,this.options.type=this.options.type||k.DETACHED,this.doc=a,this.itemPanels=null,this.overlapButtonObject=null,this.overlapIndex=-1,this.element=this.createBox(),this.groupContainer=this.createGroupContainer(),this.itemGroups=this.createItemGroup(),this.mergeElement()},createBox:function(){var a=j.ele(this.doc,"div",{className:i+"box"});return"width"in this.options&&(a.style.width=this.options.width+"px"),a},setToolbar:function(a){this.toolbar=a,this.overlapButtonObject&&this.overlapButtonObject.setToolbar(a)},updateSize:function(){var a=j.getRectBox(this.toolbar.getContainer()),b=30,c=j.getRectBox(this.element);if(this.options.type===k.DETACHED){if(c.bottom<=a.bottom)return void(this.element.scrollTop=0);this.element.style.height=c.height-(c.bottom-a.bottom+b)+"px"}else{var d=this.getCurrentItemPanel(),e=null;if(d.scrollTop=0,c.bottom<=a.bottom)return;e=f(d),d.style.height=a.bottom-e.top-b+"px"}},initEvent:function(){var a="."+i+"box-item",b=this;j.delegate(this.groupContainer,a,"mousedown",function(a){a.preventDefault(),1===a.which&&b.onselectHandler&&b.onselectHandler(this.getAttribute("data-value"))}),j.on(this.element,"mousedown",function(a){a.stopPropagation(),a.preventDefault()}),j.on(this.element,"mousewheel",function(a){a.preventDefault(),a.stopPropagation(),b.scroll(a.originalEvent.wheelDelta)})},getNode:function(){return this.element},setSelectHandler:function(a){this.onselectHandler=a},scroll:function(a){0>a?this.scrollDown():(this.scrollUp(),this.element.scrollTop-=20)},scrollDown:function(){this.options.type===k.DETACHED?this.element.scrollTop+=o:this.getCurrentItemPanel().scrollTop+=o},scrollUp:function(){this.options.type===k.DETACHED?this.element.scrollTop-=o:this.getCurrentItemPanel().scrollTop-=o},setChangeHandler:function(a){this.onchangeHandler=a},onchangeHandler:function(){},createGroupContainer:function(){return j.ele(this.doc,"div",{className:i+"box-container"})},getPositionInfo:function(){return j.getRectBox(this.element)},createItemGroup:function(){var a=this.createGroup();switch(this.options.type){case k.DETACHED:return a.items[0];case k.OVERLAP:return this.createOverlapGroup(a)}return null},enable:function(){this.overlapButtonObject&&this.overlapButtonObject.enable()},disable:function(){this.overlapButtonObject&&this.overlapButtonObject.disable()},hide:function(){this.overlapButtonObject&&this.overlapButtonObject.hideMount()},getOverlapContent:function(){return this.options.type!==k.OVERLAP?null:this.options.group[this.overlapIndex].items},createOverlapGroup:function(a){var b=a.title,f=this,g=c(this.doc),k=d(this.doc,{fixOffset:this.options.fixOffset}),l=e(this.doc,{width:150,items:b}),m=j.ele(this.doc,"div",{className:i+"wrap-group"});return this.overlapButtonObject=k,k.mount(l),k.initEvent(),l.initEvent(),h.Utils.each(a.items,function(b,c){var d=m.cloneNode(!1);h.Utils.each(b,function(a){d.appendChild(a)}),a.items[c]=d}),this.itemPanels=a.items,l.setSelectHandler(function(c,d){f.overlapIndex=c,k.setLabel(b[c]),k.hideMount(),a.items[d].style.display="none",a.items[c].style.display="block",c!==d&&f.updateSize(),f.onchangeHandler(c)}),g.appendChild(k.getNode()),h.Utils.each(a.items,function(a,b){b>0&&(a.style.display="none"),g.appendChild(a)}),l.select(0),[g]},getCurrentItemPanel:function(){return this.itemPanels[this.overlapIndex]},getGroupList:function(){var a=[];return h.Utils.each(this.options.group,function(b){a.push(b.title)}),{width:150,items:a}},createGroup:function(){var b=this.doc,c=[],d={title:[],items:[]},e=null,f=null,g=k.DETACHED===this.options.type?l.BIG:l.SMALL,m=null;return e=j.ele(this.doc,"div",{className:i+"box-group"}),m=e.cloneNode(!1),m.className=i+"box-group-item-container",h.Utils.each(this.options.group,function(k){d.title.push(k.title||""),c=[],h.Utils.each(k.items,function(d){e=e.cloneNode(!1),m=m.cloneNode(!1),f=j.ele(b,"div",{className:i+"box-group-title",content:d.title}),e.appendChild(f),e.appendChild(m),h.Utils.each(a(b,d.content,g),function(a){a.appendTo(m)}),c.push(e)}),d.items.push(c)}),d},mergeElement:function(){var a=this.groupContainer;this.element.appendChild(a),h.Utils.each(this.itemGroups,function(b){a.appendChild(b)})},mountTo:function(a){a.appendChild(this.element)},appendTo:function(a){a.appendChild(this.element)}}),q=h.createClass("BoxItem",{constructor:function(a,b,c){this.type=a,this.doc=b,this.options=c,this.element=this.createItem(),this.labelNode=this.createLabel(),this.contentNode=this.createContent(),this.mergeElement()},getNode:function(){return this.element},createItem:function(){var a=j.ele(this.doc,"div",{className:i+"box-item"});return a},createLabel:function(){var a=null;if("label"in this.options)return a=j.ele(this.doc,"div",{className:i+"box-item-label",content:this.options.label})},getContent:function(){},createContent:function(){switch(this.type){case l.BIG:return this.createBigContent();case l.SMALL:return this.createSmallContent()}},createBigContent:function(){var a=this.doc,b=j.ele(a,"div",{className:i+"box-item-content"}),c=i+"box-item-val",d=this.options.item,e=null,f=g(d);return e=j.ele(a,"div",{className:c}),e.innerHTML='<div class="'+i+'item-image" style="'+f+'"></div>',this.element.setAttribute("data-value",d.val),b.appendChild(e),b},createSmallContent:function(){var a=this.doc,b=j.ele(a,"div",{className:i+"box-item-content"}),c=i+"box-item-val",d=this.options,e=null;return e=j.ele(a,"div",{className:c}),e.style.background="url( "+d.img+" )",e.style.backgroundPosition=-d.pos.x+"px "+-d.pos.y+"px",this.element.setAttribute("data-value",d.key),b.appendChild(e),b},mergeElement:function(){this.labelNode&&this.element.appendChild(this.labelNode),this.element.appendChild(this.contentNode)},appendTo:function(a){a.appendChild(this.element)}});return p}},b[39]={value:function(){function a(a){var b="url( "+a.src+" ) no-repeat ";return b+=-a.x+"px ",b+=-a.y+"px"}var c=b.r(20),d="kf-editor-ui-",e=7,f={iconSize:{w:32,h:32}},g=b.r(47),h=c.createClass("Button",{constructor:function(a,b){this.options=c.Utils.extend({},f,b),this.eventState=!1,this.toolbar=null,this.displayState=!1,this.fixOffset=b.fixOffset||!1,this.doc=a,this.element=this.createButton(),this.disabled=!0,this.mountElement=null,this.icon=this.createIcon(),this.label=this.createLabel(),this.sign=this.createSign(),this.mountPoint=this.createMountPoint(),this.mergeElement()},initEvent:function(){var a=this;this.eventState||(this.eventState=!0,g.on(this.element,"mousedown",function(b){b.preventDefault(),b.stopPropagation(),1===b.which&&(a.disabled||(a.toggleSelect(),a.toggleMountElement()))}))},setToolbar:function(a){this.toolbar=a},toggleMountElement:function(){this.displayState?this.hideMount():this.showMount()},setLabel:function(a){var b="";this.sign&&(b='<div class="'+d+'button-sign"></div>'),this.label.innerHTML=a+b},toggleSelect:function(){g.getClassList(this.element).toggle(d+"button-in")},unselect:function(){g.getClassList(this.element).remove(d+"button-in")},select:function(){g.getClassList(this.element).add(d+"button-in")},show:function(){this.select(),this.showMount()},hide:function(){this.unselect(),this.hideMount()},showMount:function(){if(this.displayState=!0,this.mountPoint.style.display="block",this.fixOffset){var a=this.element.getBoundingClientRect();this.mountElement.setOffset(a.left+e,a.bottom)}var b=this.toolbar.getContainer(),c=null,d=g.getRectBox(b),f=this.mountElement.getPositionInfo();f.right>d.right&&(c=g.getRectBox(this.element),this.mountPoint.style.left=c.right-f.right-1+"px"),this.mountElement.updateSize&&this.mountElement.updateSize()},hideMount:function(){this.displayState=!1,this.mountPoint.style.display="none"},getNode:function(){return this.element},mount:function(a){this.mountElement=a,a.mountTo(this.mountPoint)},createButton:function(){var a=g.ele(this.doc,"div",{className:d+"button"});return this.options.className&&(a.className+=" "+d+this.options.className),a},createIcon:function(){if(!this.options.icon)return null;var b=g.ele(this.doc,"div",{className:d+"button-icon"});return"string"==typeof this.options.icon?b.style.backgroundImage="url("+this.options.icon+") no-repeat":b.style.background=a(this.options.icon),this.options.iconSize.w&&(b.style.width=this.options.iconSize.w+"px"),this.options.iconSize.h&&(b.style.height=this.options.iconSize.h+"px"),b},createLabel:function(){var a=g.ele(this.doc,"div",{className:d+"button-label",content:this.options.label});return a},createSign:function(){return this.options.sign===!1?null:g.ele(this.doc,"div",{className:d+"button-sign"})},createMountPoint:function(){return g.ele(this.doc,"div",{className:d+"button-mount-point"})},disable:function(){this.disabled=!0,g.getClassList(this.element).remove(d+"enabled")
},enable:function(){this.disabled=!1,g.getClassList(this.element).add(d+"enabled")},mergeElement:function(){this.icon&&this.element.appendChild(this.icon),this.element.appendChild(this.label),this.sign&&this.label.appendChild(this.sign),this.element.appendChild(this.mountPoint)}});return h}},b[40]={value:function(){return{DETACHED:1,OVERLAP:2}}},b[41]={value:function(){return{DRAPDOWN_BOX:1,AREA:2,DELIMITER:3}}},b[42]={value:function(){return{BIG:1,SMALL:2}}},b[43]={value:function(){var a=b.r(20),c="kf-editor-ui-",d=b.r(47),e=a.createClass("Delimiter",{constructor:function(a){this.doc=a,this.element=this.createDilimiter()},setToolbar:function(){},createDilimiter:function(){var a=d.ele(this.doc,"div",{className:c+"delimiter"});return a.appendChild(d.ele(this.doc,"div",{className:c+"delimiter-line"})),a},attachTo:function(a){a.appendChild(this.element)}});return e}},b[44]={value:function(){var a=b.r(20),c=b.r(47),d=b.r(39),e=b.r(38),f=a.createClass("DrapdownBox",{constructor:function(a,b){this.options=b,this.toolbar=null,this.doc=a,this.buttonElement=this.createButton(),this.element=this.buttonElement.getNode(),this.boxElement=this.createBox(),this.buttonElement.mount(this.boxElement),this.initEvent()},initEvent:function(){var a=this;c.on(this.element,"mousedown",function(b){b.preventDefault(),b.stopPropagation(),a.toolbar.notify("closeOther",a)}),this.buttonElement.initEvent(),this.boxElement.initEvent(),this.boxElement.setSelectHandler(function(b){c.publish("data.select",b),a.buttonElement.hide()})},disable:function(){this.buttonElement.disable()},enable:function(){this.buttonElement.enable()},setToolbar:function(a){this.toolbar=a,this.buttonElement.setToolbar(a),this.boxElement.setToolbar(a)},createButton:function(){return new d(this.doc,this.options.button)},show:function(){this.buttonElement.show()},hide:function(){this.buttonElement.hide()},createBox:function(){return new e(this.doc,this.options.box)},attachTo:function(a){a.appendChild(this.element)}});return f}},b[45]={value:function(){var a=b.r(20),c="kf-editor-ui-",d=b.r(47),e=a.createClass("List",{constructor:function(a,b){this.options=b,this.doc=a,this.onselectHandler=null,this.currentSelect=-1,this.element=this.createBox(),this.itemGroups=this.createItems(),this.mergeElement()},onselectHandler:function(){},setSelectHandler:function(a){this.onselectHandler=a},createBox:function(){var a=d.ele(this.doc,"div",{className:c+"list"}),b=d.ele(this.doc,"div",{className:c+"list-bg"});return"width"in this.options&&(a.style.width=this.options.width+"px"),a.appendChild(b),a},select:function(a){var b=this.currentSelect;-1===b&&(b=a),this.unselect(b),this.currentSelect=a,d.getClassList(this.itemGroups.items[a]).add(c+"list-item-select"),this.onselectHandler(a,b)},unselect:function(a){d.getClassList(this.itemGroups.items[a]).remove(c+"list-item-select")},setOffset:function(a,b){this.element.style.left=a+"px",this.element.style.top=b+"px"},initEvent:function(){var a="."+c+"list-item",b=this;d.delegate(this.itemGroups.container,a,"mousedown",function(a){a.preventDefault(),1===a.which&&b.select(this.getAttribute("data-index"))}),d.on(this.element,"mousedown",function(a){a.stopPropagation(),a.preventDefault()})},getPositionInfo:function(){return d.getRectBox(this.element)},createItems:function(){var b=this.doc,e=null,f=null,g=null,h=[],i=null;return e=d.ele(this.doc,"div",{className:c+"list-item"}),i=e.cloneNode(!1),i.className=c+"list-item-container",a.Utils.each(this.options.items,function(a,j){f=e.cloneNode(!1),g=e.cloneNode(!1),g.className=c+"list-item-icon",f.appendChild(g),f.appendChild(d.ele(b,"text",a)),f.setAttribute("data-index",j),h.push(f),i.appendChild(f)}),{container:i,items:h}},mergeElement:function(){this.element.appendChild(this.itemGroups.container)},mountTo:function(a){a.appendChild(this.element)}});return e}},b[46]={value:function(){function a(a,b,c){var d=a.createElement(b),e='<div class="$1"></div><div class="$2"></div>';return d.className=r+c,"thumb"===c&&(c=r+c,d.innerHTML=e.replace("$1",c+"-left").replace("$2",c+"-right")),d}function c(a){return a.getBoundingClientRect()}function d(a){q.addEvent(a,"mousedown",function(a){a.preventDefault()})}function d(a){q.addEvent(a.container,"mousedown",function(a){a.preventDefault()})}function e(a){q.addEvent(a.widgets.track,"mousedown",function(b){h(this,a,b)})}function f(a){q.addEvent(a.widgets.leftButton,"mousedown",function(){j(a,-p.step)}),q.addEvent(a.widgets.rightButton,"mousedown",function(){j(a,p.step)})}function g(a){var b=!1,c=0,d=0,e=a.values.trackWidth;q.addEvent(a.widgets.thumb,"mousedown",function(e){e.preventDefault(),e.stopPropagation(),b=!0,c=e.clientX,d=a.thumbLocationX}),q.addEvent(a.container.ownerDocument,"mouseup",function(){b=!1,c=0,d=0}),q.addEvent(a.container.ownerDocument,"mousemove",function(f){if(b){var g=f.clientX-c,h=d+g,j=a.values.thumbWidth;0>h?h=0:h+j>e&&(h=e-j),i(a,h)}})}function h(a,b,d){var e=c(a),f=b.values,g=f.viewWidth/(f.contentWidth-f.viewWidth)*f.trackWidth,h=d.clientX-e.left;h>f.offset?f.offset+g>f.trackWidth?k(b,f.trackWidth):k(b,f.offset+g):f.offset-g<0?k(b,0):k(b,f.offset-g)}function i(a,b){var c=a.values,d=c.trackWidth-c.thumbWidth,e=Math.floor(b/d*c.trackWidth);a.updateOffset(e),a.thumbLocationX=b,a.widgets.thumb.style.left=b+"px"}function j(a,b){var c=a.leftOverflow+b;0>c?c=0:c>a.values.scrollWidth&&(c=a.values.scrollWidth),m(a,c)}function k(a,b){var c=a.values,d=b/c.trackWidth,e=c.trackWidth-c.thumbWidth,f=0;f=Math.floor(d*e),0>b&&(b=0,f=0),a.updateOffset(b),a.widgets.thumb.style.left=f+"px",a.thumbLocationX=f}function l(a,b){var c=a.values,d=0,e=0;d=b/(c.contentWidth-c.viewWidth),e=Math.floor(d*c.trackWidth),k(a,e)}function m(a,b){var c=a.values,d=b/(c.contentWidth-c.viewWidth);k(a,d*c.trackWidth)}var n=b.r(20),o=b.r(32).scrollbar,p=b.r(29).scrollbar,q=b.r(4),r="kf-editor-ui-";return n.createClass("Scrollbar",{constructor:function(a,b){this.uiComponent=a,this.kfEditor=b,this.widgets=null,this.container=this.uiComponent.scrollbarContainer,this.state=!1,this.values={offset:0,left:0,viewWidth:0,contentWidth:0,trackWidth:0,thumbWidth:0,scrollWidth:0},this.thumbLocationX=0,this.leftOverflow=0,this.rightOverflow=0,this.isExpand=!0,this.initWidget(),this.mountWidget(),this.initSize(),this.hide(),this.initServices(),this.initEvent(),this.updateHandler=function(){}},initWidget:function(){var b=this.container.ownerDocument;this.widgets={leftButton:a(b,"div","left-button"),rightButton:a(b,"div","right-button"),track:a(b,"div","track"),thumb:a(b,"div","thumb"),thumbBody:a(b,"div","thumb-body")}},initSize:function(){var a=c(this.widgets.leftButton).width,b=c(this.widgets.rightButton).width;this.values.viewWidth=c(this.container).width,this.values.trackWidth=this.values.viewWidth-a-b,this.widgets.track.style.width=this.values.trackWidth+"px"},initServices:function(){this.kfEditor.registerService("ui.show.scrollbar",this,{showScrollbar:this.show}),this.kfEditor.registerService("ui.hide.scrollbar",this,{hideScrollbar:this.hide}),this.kfEditor.registerService("ui.update.scrollbar",this,{updateScrollbar:this.update}),this.kfEditor.registerService("ui.set.scrollbar.update.handler",this,{setUpdateHandler:this.setUpdateHandler}),this.kfEditor.registerService("ui.relocation.scrollbar",this,{relocation:this.relocation})},initEvent:function(){d(this),e(this),g(this),f(this)},mountWidget:function(){var a=this.widgets,b=this.container;for(var c in a)a.hasOwnProperty(c)&&b.appendChild(a[c]);a.thumb.appendChild(a.thumbBody),a.track.appendChild(a.thumb)},show:function(){this.state=!0,this.container.style.display="block"},hide:function(){this.state=!1,this.container.style.display="none"},update:function(a){var b=this.values.trackWidth,c=0;return this.isExpand=a>this.values.contentWidth,this.values.contentWidth=a,this.values.scrollWidth=a-this.values.viewWidth,b>=a?void this.hide():(c=Math.max(Math.ceil(b*b/a),o.thumbMinSize),this.values.thumbWidth=c,this.widgets.thumb.style.width=c+"px",void(this.widgets.thumbBody.style.width=c-10+"px"))},setUpdateHandler:function(a){this.updateHandler=a},updateOffset:function(a){var b=this.values;b.offset=a,b.left=a/b.trackWidth,this.leftOverflow=b.left*(b.contentWidth-b.viewWidth),this.rightOverflow=b.contentWidth-b.viewWidth-this.leftOverflow,this.updateHandler(b.left,b.offset,b)},relocation:function(){var a=this.kfEditor.requestService("control.get.cursor.location"),b=p.padding,c=this.values.contentWidth,d=this.values.viewWidth,e=this.values.left*(c-d),f=0;a.x<e?(a.x<0&&(a.x=0),l(this,a.x)):a.x+b>e+d?(a.x+=b,a.x>c&&(a.x=c),f=a.x-d,l(this,f)):this.isExpand?m(this,this.leftOverflow):m(this,c-d-this.rightOverflow)}})}},b[47]={value:function(){function a(a){this.node=a,this.classes=a.className.replace(/^\s+|\s+$/g,"").split(/\s+/)}var c=b.r(14),d=b.r(20),e={},f={ele:function(a,b,c){var d=null;return"text"===b?a.createTextNode(c):(d=a.createElement(b),c.className&&(d.className=c.className),c.content&&(d.innerHTML=c.content),d)},getRectBox:function(a){return a.getBoundingClientRect()},on:function(a,b,d){return c(a).on(b,d),this},delegate:function(a,b,d,e){return c(a).delegate(b,d,e),this},publish:function(a,b){var c=e[a];c&&(b=[].slice.call(arguments,1),d.Utils.each(c,function(a){a.apply(null,b)}))},subscribe:function(a,b){e[a]||(e[a]=[]),e[a].push(b)},getClassList:function(b){return b.classList||new a(b)}};return a.prototype={constructor:a,contains:function(a){return-1!==this.classes.indexOf(a)},add:function(a){return-1==this.classes.indexOf(a)&&this.classes.push(a),this._update(),this},remove:function(a){var b=this.classes.indexOf(a);return-1!==b&&(this.classes.splice(b,1),this._update()),this},toggle:function(a){var b=this.contains(a)?"remove":"add";return this[b](a)},_update:function(){this.node.className=this.classes.join(" ")}},f}},b[48]={value:function(){return{DrapdownBox:b.r(44),Delimiter:b.r(43),Area:b.r(37)}}},b[49]={value:function(){function a(a){return h.ele(a,"div",{className:"kf-editor-toolbar"})}function c(a){return h.ele(a,"div",{className:"kf-editor-inner-toolbar"})}function d(a){var b=a.createElement("div");return b.className="kf-editor-edit-area",b.style.width="80%",b.style.height="800px",b}function e(a){var b=a.createElement("div");return b.className="kf-editor-canvas-container",b}function f(a){var b=a.createElement("div");return b.className="kf-editor-edit-scrollbar",b}var g=b.r(20),h=b.r(47),i=b.r(4),j=b.r(32).VIEW_STATE,k=b.r(46),l=b.r(36),m=(b.r(31),b.r(35)),n=g.createClass("UIComponent",{constructor:function(b,g){var h=null;this.options=g,this.container=b.getContainer(),h=this.container.ownerDocument,this.components={},this.canvasRect=null,this.viewState=j.NO_OVERFLOW,this.kfEditor=b,this.toolbarWrap=a(h),this.toolbarContainer=c(h),this.editArea=d(h),this.canvasContainer=e(h),this.scrollbarContainer=f(h),this.toolbarWrap.appendChild(this.toolbarContainer),this.container.appendChild(this.toolbarWrap),this.editArea.appendChild(this.canvasContainer),this.container.appendChild(this.editArea),this.container.appendChild(this.scrollbarContainer),this.initComponents(),this.initServices(),this.initEvent(),this.updateContainerSize(this.container,this.toolbarWrap,this.editArea,this.canvasContainer),this.initScrollEvent()},initComponents:function(){this.components.toolbar=new l(this,this.kfEditor,m),this.components.scrollbar=new k(this,this.kfEditor)},updateContainerSize:function(a,b,c){var d=a.getBoundingClientRect(),e=b.getBoundingClientRect();c.style.width=d.width+"px",c.style.height=d.bottom-e.bottom+"px"},initServices:function(){this.kfEditor.registerService("ui.get.canvas.container",this,{getCanvasContainer:this.getCanvasContainer}),this.kfEditor.registerService("ui.update.canvas.view",this,{updateCanvasView:this.updateCanvasView}),this.kfEditor.registerService("ui.canvas.container.event",this,{on:this.addEvent,off:this.removeEvent,trigger:this.trigger,fire:this.trigger})},initEvent:function(){},initScrollEvent:function(){var a=this;this.kfEditor.requestService("ui.set.scrollbar.update.handler",function(b,c,d){c=Math.floor(b*(d.contentWidth-d.viewWidth)),a.kfEditor.requestService("render.set.canvas.offset",c)})},getCanvasContainer:function(){return this.canvasContainer},addEvent:function(a,b){i.addEvent(this.canvasContainer,a,b)},removeEvent:function(){},trigger:function(a){i.trigger(this.canvasContainer,a)},updateCanvasView:function(){var a=this.kfEditor.requestService("render.get.canvas"),b=a.getContentContainer(),c=null;null===this.canvasRect&&(this.canvasRect=this.canvasContainer.getBoundingClientRect()),c=b.getRenderBox("paper"),c.width>this.canvasRect.width?(this.viewState===j.NO_OVERFLOW&&(this.toggleViewState(),this.kfEditor.requestService("ui.show.scrollbar"),this.kfEditor.requestService("render.disable.relocation")),this.kfEditor.requestService("render.relocation"),this.kfEditor.requestService("ui.update.scrollbar",c.width),this.kfEditor.requestService("ui.relocation.scrollbar")):(this.viewState===j.OVERFLOW&&(this.toggleViewState(),this.kfEditor.requestService("ui.hide.scrollbar"),this.kfEditor.requestService("render.enable.relocation")),this.kfEditor.requestService("render.relocation"))},toggleViewState:function(){this.viewState=this.viewState===j.NO_OVERFLOW?j.OVERFLOW:j.NO_OVERFLOW}});return n}},b[50]={value:function(){var a=b.r(12),c=b.r(13);a.registerComponents("ui",b.r(49)),a.registerComponents("parser",b.r(21)),a.registerComponents("render",b.r(25)),a.registerComponents("position",b.r(23)),a.registerComponents("syntax",b.r(28)),a.registerComponents("control",b.r(5)),a.registerComponents("print",b.r(24)),kf.EditorFactory=c}};var c={"kf.start":50};!function(){try{a("kf.start")}catch(b){}}(this)}();
\ No newline at end of file
!function(){var _p={r:function(t){if(_p[t].inited)return _p[t].value;if("function"!=typeof _p[t].value)return _p[t].inited=!0,_p[t].value;var e={exports:{}},n=_p[t].value(null,e.exports,e);if(_p[t].inited=!0,void 0!==(_p[t].value=n))return n;for(var r in e.exports)if(e.exports.hasOwnProperty(r))return _p[t].inited=!0,_p[t].value=e.exports,e.exports}};_p[0]={value:function(t){function a(t){var e=parseFloat(t,10);return/ms/.test(t)?e:/s/.test(t)?1e3*e:/min/.test(t)?60*e*1e3:e}var s=_p.r(8),o=_p.r(1),u=_p.r(11).createClass("Animator",{constructor:function(t,e,n){if(1==arguments.length){var r=t;this.beginValue=r.beginValue,this.finishValue=r.finishValue,this.setter=r.setter}else this.beginValue=t,this.finishValue=e,this.setter=n},start:function(t,e,n,r,i){2===arguments.length&&"object"==typeof e&&(n=e.easing,r=e.delay,i=e.callback,e=e.duration),4===arguments.length&&"function"==typeof r&&(i=r,r=0);var s=this.create(t,e,n,i);return 0<(r=a(r))?setTimeout(function(){s.play()},r):s.play(),s},create:function(t,e,n,r){var i;return e=e&&a(e)||u.DEFAULT_DURATION,"string"==typeof(n=n||u.DEFAULT_EASING)&&(n=o[n]),i=new s(this,t,e,n),"function"==typeof r&&i.on("finish",r),i},reverse:function(){return new u(this.finishValue,this.beginValue,this.setter)}});u.DEFAULT_DURATION=300,u.DEFAULT_EASING="linear";var e=_p.r(60);return _p.r(11).extendClass(e,{animate:function(t,e,n,r,i){var s=this._KityAnimateQueue=this._KityAnimateQueue||[],a=t.create(this,e,n,i);return a.on("finish",function(){s.shift(),s.length&&setTimeout(s[0].t.play.bind(s[0].t),s[0].d)}),s.push({t:a,d:r}),1==s.length&&setTimeout(a.play.bind(a),r),this},timeline:function(){return this._KityAnimateQueue[0].t},stop:function(){var t=this._KityAnimateQueue;if(t)for(;t.length;)t.shift().t.stop();return this}}),u}},_p[1]={value:function(t,e,n){var i={linear:function(t,e,n,r){return n*(t/r)+e},swing:function(t,e,n,r){return i.easeOutQuad(t,e,n,r)},ease:function(t,e,n,r){return i.easeInOutCubic(t,e,n,r)},easeInQuad:function(t,e,n,r){return n*(t/=r)*t+e},easeOutQuad:function(t,e,n,r){return-n*(t/=r)*(t-2)+e},easeInOutQuad:function(t,e,n,r){return(t/=r/2)<1?n/2*t*t+e:-n/2*(--t*(t-2)-1)+e},easeInCubic:function(t,e,n,r){return n*(t/=r)*t*t+e},easeOutCubic:function(t,e,n,r){return n*((t=t/r-1)*t*t+1)+e},easeInOutCubic:function(t,e,n,r){return(t/=r/2)<1?n/2*t*t*t+e:n/2*((t-=2)*t*t+2)+e},easeInQuart:function(t,e,n,r){return n*(t/=r)*t*t*t+e},easeOutQuart:function(t,e,n,r){return-n*((t=t/r-1)*t*t*t-1)+e},easeInOutQuart:function(t,e,n,r){return(t/=r/2)<1?n/2*t*t*t*t+e:-n/2*((t-=2)*t*t*t-2)+e},easeInQuint:function(t,e,n,r){return n*(t/=r)*t*t*t*t+e},easeOutQuint:function(t,e,n,r){return n*((t=t/r-1)*t*t*t*t+1)+e},easeInOutQuint:function(t,e,n,r){return(t/=r/2)<1?n/2*t*t*t*t*t+e:n/2*((t-=2)*t*t*t*t+2)+e},easeInSine:function(t,e,n,r){return-n*Math.cos(t/r*(Math.PI/2))+n+e},easeOutSine:function(t,e,n,r){return n*Math.sin(t/r*(Math.PI/2))+e},easeInOutSine:function(t,e,n,r){return-n/2*(Math.cos(Math.PI*t/r)-1)+e},easeInExpo:function(t,e,n,r){return 0===t?e:n*Math.pow(2,10*(t/r-1))+e},easeOutExpo:function(t,e,n,r){return t==r?e+n:n*(1-Math.pow(2,-10*t/r))+e},easeInOutExpo:function(t,e,n,r){return 0===t?e:t==r?e+n:(t/=r/2)<1?n/2*Math.pow(2,10*(t-1))+e:n/2*(2-Math.pow(2,-10*--t))+e},easeInCirc:function(t,e,n,r){return-n*(Math.sqrt(1-(t/=r)*t)-1)+e},easeOutCirc:function(t,e,n,r){return n*Math.sqrt(1-(t=t/r-1)*t)+e},easeInOutCirc:function(t,e,n,r){return(t/=r/2)<1?-n/2*(Math.sqrt(1-t*t)-1)+e:n/2*(Math.sqrt(1-(t-=2)*t)+1)+e},easeInElastic:function(t,e,n,r){var i=1.70158,s=0,a=n;return 0===t?e:1==(t/=r)?e+n:(s=s||.3*r,i=a<Math.abs(n)?(a=n,s/4):s/(2*Math.PI)*Math.asin(n/a),-(a*Math.pow(2,10*--t)*Math.sin((t*r-i)*(2*Math.PI)/s))+e)},easeOutElastic:function(t,e,n,r){var i=1.70158,s=0,a=n;return 0===t?e:1==(t/=r)?e+n:(s=s||.3*r,i=a<Math.abs(n)?(a=n,s/4):s/(2*Math.PI)*Math.asin(n/a),a*Math.pow(2,-10*t)*Math.sin((t*r-i)*(2*Math.PI)/s)+n+e)},easeInOutElastic:function(t,e,n,r){var i=1.70158,s=0,a=n;if(0===t)return e;if(2==(t/=r/2))return e+n;if(s=s||r*(.3*1.5),a<Math.abs(n)){a=n;i=s/4}else i=s/(2*Math.PI)*Math.asin(n/a);return t<1?a*Math.pow(2,10*--t)*Math.sin((t*r-i)*(2*Math.PI)/s)*-.5+e:a*Math.pow(2,-10*--t)*Math.sin((t*r-i)*(2*Math.PI)/s)*.5+n+e},easeInBack:function(t,e,n,r,i){return null==i&&(i=1.70158),n*(t/=r)*t*((i+1)*t-i)+e},easeOutBack:function(t,e,n,r,i){return null==i&&(i=1.70158),n*((t=t/r-1)*t*((i+1)*t+i)+1)+e},easeInOutBack:function(t,e,n,r,i){return null==i&&(i=1.70158),(t/=r/2)<1?n/2*(t*t*((1+(i*=1.525))*t-i))+e:n/2*((t-=2)*t*((1+(i*=1.525))*t+i)+2)+e},easeInBounce:function(t,e,n,r){return n-i.easeOutBounce(r-t,0,n,r)+e},easeOutBounce:function(t,e,n,r){return(t/=r)<1/2.75?n*(7.5625*t*t)+e:t<2/2.75?n*(7.5625*(t-=1.5/2.75)*t+.75)+e:t<2.5/2.75?n*(7.5625*(t-=2.25/2.75)*t+.9375)+e:n*(7.5625*(t-=2.625/2.75)*t+.984375)+e},easeInOutBounce:function(t,e,n,r){return t<r/2?.5*i.easeInBounce(2*t,0,n,r)+e:.5*i.easeOutBounce(2*t-r,0,n,r)+.5*n+e}};return i}},_p[2]={value:function(t,e){var n,r=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return setTimeout(t,1e3/60)},i=window.cancelAnimationFrame||window.mozCancelAnimationFrame||window.webkitCancelAnimationFrame||window.msCancelAnimationFrame||window.clearTimeout,s=[];function a(t){1===s.push(t)&&(n=r(o))}function o(){var t=s;for(s=[];t.length;)u(t.pop());n=0}function u(t){var e=+new Date,n=e-t.time;200<n&&(n=1e3/60),t.dur=n,t.elapsed+=n,t.time=e,t.action.call(null,t),t.index++}e.requestFrame=function(t){var e,n,r=(e=t,n={index:0,time:+new Date,elapsed:0,action:e,next:function(){a(n)}});return a(r),r},e.releaseFrame=function(t){var e=s.indexOf(t);~e&&s.splice(e,1),0===s.length&&i(n)}}},_p[3]={value:function(t){var e=_p.r(0),s=_p.r(34),a=_p.r(46),n=_p.r(60),o=_p.r(11).createClass("MotionAnimator",{base:e,constructor:function(t,e){var i=this;this.callBase({beginValue:0,finishValue:1,setter:function(t,e){var n=i.motionPath instanceof a?i.motionPath.getPathData():i.motionPath,r=s.pointAtPath(n,e);t.setTranslate(r.x,r.y),this.doRotate&&t.setRotate(r.tan.getAngle())}}),this.doRotate=e,this.motionPath=t}});return _p.r(11).extendClass(n,{motion:function(t,e,n,r,i){return this.animate(new o(t),e,n,r,i)}}),o}},_p[4]={value:function(t){var e=_p.r(0),s=_p.r(11).createClass("OpacityAnimator",{base:e,constructor:function(t){this.callBase({beginValue:function(t){return t.getOpacity()},finishValue:t,setter:function(t,e){t.setOpacity(e)}})}}),n=_p.r(60);return _p.r(11).extendClass(n,{fxOpacity:function(t,e,n,r,i){return this.animate(new s(t),e,n,r,i)},fadeTo:function(){return this.fxOpacity.apply(this,arguments)},fadeIn:function(){return this.fxOpacity.apply(this,[1].concat([].slice.call(arguments)))},fadeOut:function(){return this.fxOpacity.apply(this,[0].concat([].slice.call(arguments)))}}),s}},_p[5]={value:function(t){var e=_p.r(0),r=_p.r(34),s=_p.r(11).createClass("OpacityAnimator",{base:e,constructor:function(n){this.callBase({beginValue:function(t){return this.beginPath=t.getPathData(),0},finishValue:1,setter:function(t,e){t.setPathData(r.pathTween(this.beginPath,n,e))}})}}),n=_p.r(46);return _p.r(11).extendClass(n,{fxPath:function(t,e,n,r,i){return this.animate(new s(t),e,n,r,i)}}),s}},_p[6]={value:function(t){var e=_p.r(0),s=_p.r(11).createClass("RotateAnimator",{base:e,constructor:function(t){this.callBase({beginValue:0,finishValue:t,setter:function(t,e,n){var r=n.getDelta();t.rotate(r,ax,ay)}})}}),n=_p.r(60);return _p.r(11).extendClass(n,{fxRotate:function(t,e,n,r,i){return this.animate(new s(t),e,n,r,i)}}),s}},_p[7]={value:function(t){var e=_p.r(0),a=_p.r(11).createClass("ScaleAnimator",{base:e,constructor:function(a,o){this.callBase({beginValue:0,finishValue:1,setter:function(t,e,n){var r=n.getDelta(),i=Math.pow(a,r),s=Math.pow(o,r);t.scale(s,i)}})}}),n=_p.r(60);return _p.r(11).extendClass(n,{fxScale:function(t,e,n,r,i,s){return this.animate(new a(t,e),n,r,i,s)}}),a}},_p[8]={value:function(t){var e=_p.r(33),a=_p.r(12),n=_p.r(2);function r(t,e,n){for(var r in this.timeline=t,this.target=t.target,this.type=e,n)n.hasOwnProperty(r)&&(this[r]=n[r])}var i=_p.r(11).createClass("Timeline",{mixins:[e],constructor:function(t,e,n,r){this.callMixin(),this.target=e,this.time=0,this.duration=n,this.easing=r,this.animator=t,this.beginValue=t.beginValue,this.finishValue=t.finishValue,this.setter=t.setter,this.status="ready"},nextFrame:function(t){"playing"==this.status&&(this.time+=t.dur,this.setValue(this.getValue()),this.time>=this.duration&&this.timeUp(),t.next())},getPlayTime:function(){return this.rollbacking?this.duration-this.time:this.time},getTimeProportion:function(){return this.getPlayTime()/this.duration},getValueProportion:function(){return this.easing(this.getPlayTime(),0,1,this.duration)},getValue:function(){var t,e,n,r=this.beginValue,i=this.finishValue,s=this.getValueProportion();return t=r,e=i,n=s,a.paralle(t,e,function(t,e){return t+(e-t)*n})},setValue:function(t){this.lastValue=this.currentValue,this.currentValue=t,this.setter.call(this.target,this.target,t,this)},getDelta:function(){return this.lastValue=void 0===this.lastValue?this.beginValue:this.lastValue,t=this.lastValue,e=this.currentValue,a.paralle(t,e,function(t,e){return e-t});var t,e},play:function(){var t=this.status;switch(this.status="playing",t){case"ready":a.isFunction(this.beginValue)&&(this.beginValue=this.beginValue.call(this.target,this.target)),a.isFunction(this.finishValue)&&(this.finishValue=this.finishValue.call(this.target,this.target)),this.time=0,this.setValue(this.beginValue),this.frame=n.requestFrame(this.nextFrame.bind(this));break;case"finished":case"stoped":this.time=0,this.frame=n.requestFrame(this.nextFrame.bind(this));break;case"paused":this.frame.next()}return this.fire("play",new r(this,"play",{lastStatus:t})),this},pause:function(){return this.status="paused",this.fire("pause",new r(this,"pause")),n.releaseFrame(this.frame),this},stop:function(){return this.status="stoped",this.setValue(this.finishValue),this.rollbacking=!1,this.fire("stop",new r(this,"stop")),n.releaseFrame(this.frame),this},timeUp:function(){this.repeatOption?(this.time=0,this.rollback?this.rollbacking?(this.decreaseRepeat(),this.rollbacking=!1):(this.rollbacking=!0,this.fire("rollback",new r(this,"rollback"))):this.decreaseRepeat(),this.repeatOption?this.fire("repeat",new r(this,"repeat")):this.finish()):this.finish()},finish:function(){this.setValue(this.finishValue),this.status="finished",this.fire("finish",new r(this,"finish")),n.releaseFrame(this.frame)},decreaseRepeat:function(){!0!==this.repeatOption&&this.repeatOption--},repeat:function(t,e){return this.repeatOption=t,this.rollback=e,this}});return i.requestFrame=n.requestFrame,i.releaseFrame=n.releaseFrame,i}},_p[9]={value:function(t){var e=_p.r(0),a=_p.r(11).createClass("TranslateAnimator",{base:e,constructor:function(t,e){this.callBase({x:0,y:0},{x:t,y:e},function(t,e,n){var r=n.getDelta();t.translate(r.x,r.y)})}}),n=_p.r(60);return _p.r(11).extendClass(n,{fxTranslate:function(t,e,n,r,i,s){return this.animate(new a(t,e),n,r,i,s)}}),a}},_p[10]={value:function(){return function(){var t,e,n=navigator.userAgent.toLowerCase(),r=window.opera;(t={platform:{win32:"Win",macintel:"Mac"}[navigator.platform.toLowerCase()]||"Lux",lb:!!~(e=n).indexOf("lbbrowser")&&(~e.indexOf("msie")?"ie":"chrome"),sg:/se[\s\S]+metasr/.test(n),bd:!!~n.indexOf("bidubrowser"),edge:!!~n.indexOf("edge"),chrome:!1,opera:!!r&&r.version,webkit:-1<n.indexOf(" applewebkit/"),mac:-1<n.indexOf("macintosh")}).ie=!t.lb&&/(msie\s|trident.*rv:)([\w.]+)/.test(n),t.gecko="Gecko"==navigator.product&&!t.webkit&&!t.opera&&!t.ie;var i=0;if(t.ie&&(i=+(n.match(/(msie\s|trident.*rv:)([\w.]+)/)[2]||0),t.ie11Compat=11==document.documentMode,t.ie9Compat=9==document.documentMode),t.gecko){var s=n.match(/rv:([\d\.]+)/);s&&(i=1e4*(s=s[1].split("."))[0]+100*(s[1]||0)+ +(s[2]||0))}return!/chrome\/(\d+\.\d)/i.test(n)||t.bd||t.opera||t.lb||t.sg||t.edge||(t.chrome=+RegExp.$1),/(\d+\.\d)?(?:\.\d)?\s+safari\/?(\d+\.\d+)?/i.test(n)&&!/chrome/i.test(n)&&(t.safari=+(RegExp.$1||RegExp.$2)),t.opera&&(i=parseFloat(r.version())),t.webkit&&(i=parseFloat(n.match(/ applewebkit\/(\d+)/)[1])),t.bd&&(i=parseFloat(n.match(/bidubrowser\/(\d+)/)[1])),t.opera&&(i=parseFloat(n.match(/opr\/(\d+)/)[1])),t.edge&&(i=parseFloat(n.match(/edge\/(\d+)/)[1])),t.version=i,t.isCompatible=!t.mobile&&(t.ie&&6<=i||t.gecko&&10801<=i||t.opera&&9.5<=i||t.air&&1<=i||t.webkit&&522<=i||!1),t}()}},_p[11]={value:function(require,exports){function Class(){}function checkBaseConstructorCall(t,e){var n=t.toString();if(!/this\.callBase/.test(n))throw new Error(e+" : 类构造函数没有调用父类的构造函数!为了安全,请调用父类的构造函数")}exports.Class=Class,Class.__KityClassName="Class",Class.prototype.base=function(t){return arguments.callee.caller.__KityMethodClass.__KityBaseClass.prototype[t].apply(this,Array.prototype.slice.call(arguments,1))},Class.prototype.callBase=function(){var t=arguments.callee.caller;return t.__KityMethodClass.__KityBaseClass.prototype[t.__KityMethodName].apply(this,arguments)},Class.prototype.mixin=function(t){var e=arguments.callee.caller.__KityMethodClass.__KityMixins;return e?e[t].apply(this,Array.prototype.slice.call(arguments,1)):this},Class.prototype.callMixin=function(){var t=arguments.callee.caller,e=t.__KityMethodName,n=t.__KityMethodClass.__KityMixins;if(!n)return this;var r=n[e];if("constructor"!=e)return r.apply(this,arguments);for(var i=0,s=r.length;i<s;i++)r[i].call(this);return this},Class.prototype.pipe=function(t){return"function"==typeof t&&t.call(this,this),this},Class.prototype.getType=function(){return this.__KityClassName},Class.prototype.getClass=function(){return this.constructor};var KITY_INHERIT_FLAG="__KITY_INHERIT_FLAG_"+ +new Date;function inherit(constructor,BaseClass,classname){var KityClass=eval("(function "+classname+"( __inherit__flag ) {if( __inherit__flag != KITY_INHERIT_FLAG ) {KityClass.__KityConstructor.apply(this, arguments);}this.__KityClassName = KityClass.__KityClassName;})");for(var methodName in KityClass.__KityConstructor=constructor,KityClass.prototype=new BaseClass(KITY_INHERIT_FLAG),BaseClass.prototype)BaseClass.prototype.hasOwnProperty(methodName)&&0!==methodName.indexOf("__Kity")&&(KityClass.prototype[methodName]=BaseClass.prototype[methodName]);return KityClass.prototype.constructor=KityClass,KityClass}function mixin(t,e){if(!1==e instanceof Array)return t;var n,r,i,s=e.length;for(t.__KityMixins={constructor:[]},n=0;n<s;n++)for(i in r=e[n].prototype)!1!==r.hasOwnProperty(i)&&0!==i.indexOf("__Kity")&&("constructor"===i?t.__KityMixins.constructor.push(r[i]):t.prototype[i]=t.__KityMixins[i]=r[i]);return t}function extend(t,e){for(var n in e.__KityClassName&&(e=e.prototype),e)if(e.hasOwnProperty(n)&&n.indexOf("__Kity")&&"constructor"!=n){var r=t.prototype[n]=e[n];r.__KityMethodClass=t,r.__KityMethodName=n}return t}exports.createClass=function(t,e){var n,r,i;return 1===arguments.length&&(e=t,t="AnonymousClass"),i=e.base||Class,e.hasOwnProperty("constructor")?(n=e.constructor,i!=Class&&checkBaseConstructorCall(n,t)):n=function(){this.callBase.apply(this,arguments),this.callMixin.apply(this,arguments)},(r=mixin(r=inherit(n,i,t),e.mixins)).__KityClassName=n.__KityClassName=t,r.__KityBaseClass=n.__KityBaseClass=i,r.__KityMethodName=n.__KityMethodName="constructor",r.__KityMethodClass=n.__KityMethodClass=r,delete e.mixins,delete e.constructor,delete e.base,r=extend(r,e)},exports.extendClass=extend}},_p[12]={value:function(){var o={each:function(t,e,n){if(null!==t)if(t.length===+t.length){for(var r=0,i=t.length;r<i;r++)if(!1===e.call(n,t[r],r,t))return!1}else for(var s in t)if(t.hasOwnProperty(s)&&!1===e.call(n,t[s],s,t))return!1},extend:function(t){for(var e=arguments,n=!!this.isBoolean(e[e.length-1])&&e[e.length-1],r=this.isBoolean(e[e.length-1])?e.length-1:e.length,i=1;i<r;i++){var s=e[i];for(var a in s)n&&t.hasOwnProperty(a)||(t[a]=s[a])}return t},deepExtend:function(t,e){for(var n=arguments,r=!!this.isBoolean(n[n.length-1])&&n[n.length-1],i=this.isBoolean(n[n.length-1])?n.length-1:n.length,s=1;s<i;s++){var a=n[s];for(var o in a)r&&t.hasOwnProperty(o)||(this.isObject(t[o])&&this.isObject(a[o])?this.deepExtend(t[o],a[o],r):t[o]=a[o])}return t},clone:function(t){var e={};for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e},copy:function(t){return"object"!=typeof t?t:"function"==typeof t?null:JSON.parse(JSON.stringify(t))},queryPath:function(t,e){for(var n=t.split("."),r=0,i=e,s=n.length;r<s;){if(!(n[r]in i))return;if(i=i[n[r]],s<=++r||void 0===i)return i}},getValue:function(t,e){return void 0!==t?t:e},flatten:function(t){var e,n=[],r=t.length;for(e=0;e<r;e++)t[e]instanceof Array?n=n.concat(o.flatten(t[e])):n.push(t[e]);return n},paralle:function(t,e,n){var r,i,s,a;if(t instanceof Array){for(a=[],i=0;i<t.length;i++)a.push(o.paralle(t[i],e[i],n));return a}if(t instanceof Object){if((r=t.getClass&&t.getClass())&&r.parse)t=t.valueOf(),e=e.valueOf(),a=o.paralle(t,e,n),a=r.parse(a);else for(s in a={},t)t.hasOwnProperty(s)&&e.hasOwnProperty(s)&&(a[s]=o.paralle(t[s],e[s],n));return a}return!1===isNaN(parseFloat(t))?n(t,e):a},parallelize:function(n){return function(t,e){return o.paralle(t,e,n)}}};return o.each(["String","Function","Array","Number","RegExp","Object","Boolean"],function(e){o["is"+e]=function(t){return Object.prototype.toString.apply(t)=="[object "+e+"]"}}),o}},_p[13]={value:function(t,e,n){var r=_p.r(16),i=_p.r(12),s=_p.r(11).createClass("ColorMatrixEffect",{base:r,constructor:function(t,e){this.callBase(r.NAME_COLOR_MATRIX),this.set("type",i.getValue(t,s.TYPE_MATRIX)),this.set("in",i.getValue(e,r.INPUT_SOURCE_GRAPHIC))}});return i.extend(s,{TYPE_MATRIX:"matrix",TYPE_SATURATE:"saturate",TYPE_HUE_ROTATE:"hueRotate",TYPE_LUMINANCE_TO_ALPHA:"luminanceToAlpha",MATRIX_ORIGINAL:"10000010000010000010".split("").join(" "),MATRIX_EMPTY:"00000000000000000000".split("").join(" ")}),s}},_p[14]={value:function(t,e,n){var r=_p.r(16),i=_p.r(12),s=_p.r(11).createClass("CompositeEffect",{base:r,constructor:function(t,e,n){this.callBase(r.NAME_COMPOSITE),this.set("operator",i.getValue(t,s.OPERATOR_OVER)),e&&this.set("in",e),n&&this.set("in2",n)}});return i.extend(s,{OPERATOR_OVER:"over",OPERATOR_IN:"in",OPERATOR_OUT:"out",OPERATOR_ATOP:"atop",OPERATOR_XOR:"xor",OPERATOR_ARITHMETIC:"arithmetic"}),s}},_p[15]={value:function(t,e,n){var r=_p.r(16),i=_p.r(12),s=_p.r(11).createClass("ConvolveMatrixEffect",{base:r,constructor:function(t,e){this.callBase(r.NAME_CONVOLVE_MATRIX),this.set("edgeMode",i.getValue(t,s.MODE_DUPLICATE)),this.set("in",i.getValue(e,r.INPUT_SOURCE_GRAPHIC))}});return i.extend(s,{MODE_DUPLICATE:"duplicate",MODE_WRAP:"wrap",MODE_NONE:"none"}),s}},_p[16]={value:function(t,e,n){var r=_p.r(67),i=_p.r(11).createClass("Effect",{constructor:function(t){this.node=r.createNode(t)},getId:function(){return this.node.id},setId:function(t){return this.node.id=t,this},set:function(t,e){return this.node.setAttribute(t,e),this},get:function(t){return this.node.getAttribute(t)},getNode:function(){return this.node},toString:function(){return this.node.getAttribute("result")||""}});return _p.r(12).extend(i,{NAME_GAUSSIAN_BLUR:"feGaussianBlur",NAME_OFFSET:"feOffset",NAME_COMPOSITE:"feComposite",NAME_COLOR_MATRIX:"feColorMatrix",NAME_CONVOLVE_MATRIX:"feConvolveMatrix",INPUT_SOURCE_GRAPHIC:"SourceGraphic",INPUT_SOURCE_ALPHA:"SourceAlpha",INPUT_BACKGROUND_IMAGE:"BackgroundImage",INPUT_BACKGROUND_ALPHA:"BackgroundAlpha",INPUT_FILL_PAINT:"FillPaint",INPUT_STROKE_PAINT:"StrokePaint"}),i}},_p[17]={value:function(t,e,n){var r=_p.r(16),i=_p.r(12);return _p.r(11).createClass("GaussianblurEffect",{base:r,constructor:function(t,e){this.callBase(r.NAME_GAUSSIAN_BLUR),this.set("stdDeviation",i.getValue(t,1)),this.set("in",i.getValue(e,r.INPUT_SOURCE_GRAPHIC))}})}},_p[18]={value:function(t,e,n){var r=_p.r(16),i=_p.r(12);return _p.r(11).createClass("OffsetEffect",{base:r,constructor:function(t,e,n){this.callBase(r.NAME_OFFSET),this.set("dx",i.getValue(t,0)),this.set("dy",i.getValue(e,0)),this.set("in",i.getValue(n,r.INPUT_SOURCE_GRAPHIC))}})}},_p[19]={value:function(t){return _p.r(11).createClass("EffectContainer",{base:_p.r(29),addEffect:function(t,e){return this.addItem.apply(this,arguments)},prependEffect:function(){return this.prependItem.apply(this,arguments)},appendEffect:function(){return this.appendItem.apply(this,arguments)},removeEffect:function(t){return this.removeItem.apply(this,arguments)},addEffects:function(){return this.addItems.apply(this,arguments)},setEffects:function(){return this.setItems.apply(this,arguments)},getEffect:function(){return this.getItem.apply(this,arguments)},getEffects:function(){return this.getItems.apply(this,arguments)},getFirstEffect:function(){return this.getFirstItem.apply(this,arguments)},getLastEffect:function(){return this.getLastItem.apply(this,arguments)},handleAdd:function(t,e){var n=this.getEffects().length,r=this.getItem(e+1);n!==e+1?this.node.insertBefore(t.getNode(),r.getNode()):this.node.appendChild(t.getNode())}})}},_p[20]={value:function(t,e,n){var i=_p.r(67),r=_p.r(11),s=r.createClass("Filter",{mixins:[_p.r(19)],constructor:function(t,e,n,r){this.node=i.createNode("filter"),void 0!==t&&this.set("x",t),void 0!==e&&this.set("y",e),void 0!==n&&this.set("width",n),void 0!==r&&this.set("height",r)},getId:function(){return this.id},setId:function(t){return this.node.id=t,this},set:function(t,e){return this.node.setAttribute(t,e),this},get:function(t){return this.node.getAttribute(t)},getNode:function(){return this.node}}),a=_p.r(60);return r.extendClass(a,{applyFilter:function(t){var e=t.get("id");return e&&this.node.setAttribute("filter","url(#"+e+")"),this}}),s}},_p[21]={value:function(t,e,n){var r=_p.r(17);return _p.r(11).createClass("GaussianblurFilter",{base:_p.r(20),constructor:function(t){this.callBase(),this.addEffect(new r(t))}})}},_p[22]={value:function(t,e,n){var r=_p.r(17),i=_p.r(16),s=_p.r(13),a=_p.r(28),o=_p.r(12),u=_p.r(14),h=_p.r(18);return _p.r(11).createClass("ProjectionFilter",{base:_p.r(20),constructor:function(t,e,n){this.callBase(),this.gaussianblurEffect=new r(t,i.INPUT_SOURCE_ALPHA),this.gaussianblurEffect.set("result","gaussianblur"),this.addEffect(this.gaussianblurEffect),this.offsetEffect=new h(e,n,this.gaussianblurEffect),this.offsetEffect.set("result","offsetBlur"),this.addEffect(this.offsetEffect),this.colorMatrixEffect=new s(s.TYPE_MATRIX,this.offsetEffect),this.colorMatrixEffect.set("values",s.MATRIX_ORIGINAL),this.colorMatrixEffect.set("result","colorOffsetBlur"),this.addEffect(this.colorMatrixEffect),this.compositeEffect=new u(u.OPERATOR_OVER,i.INPUT_SOURCE_GRAPHIC,this.colorMatrixEffect),this.addEffect(this.compositeEffect)},setColor:function(t){var e=null,n=[];if(o.isString(t)&&(t=a.parse(t)),!t)return this;e=s.MATRIX_EMPTY.split(" "),n.push(t.get("r")),n.push(t.get("g")),n.push(t.get("b"));for(var r=0,i=n.length;r<i;r++)e[5*r+3]=n[r]/255;return e[18]=t.get("a"),this.colorMatrixEffect.set("values",e.join(" ")),this},setOpacity:function(t){var e=this.colorMatrixEffect.get("values").split(" ");return e[18]=t,this.colorMatrixEffect.set("values",e.join(" ")),this},setOffset:function(t,e){this.setOffsetX(t),this.setOffsetY(e)},setOffsetX:function(t){this.offsetEffect.set("dx",t)},setOffsetY:function(t){this.offsetEffect.set("dy",t)},setDeviation:function(t){this.gaussianblurEffect.set("stdDeviation",t)}})}},_p[23]={value:function(t,e,n){return _p.r(11).createClass("Bezier",{mixins:[_p.r(51)],base:_p.r(46),constructor:function(t){this.callBase(),t=t||[],this.changeable=!0,this.setBezierPoints(t)},getBezierPoints:function(){return this.getPoints()},setBezierPoints:function(t){return this.setPoints(t)},onContainerChanged:function(){this.changeable&&this.update()},update:function(){var t=null,e=this.getBezierPoints();if(!(e.length<2)){(t=this.getDrawer()).clear();var n=e[0].getVertex(),r=null,i=null;t.moveTo(n.x,n.y);for(var s=1,a=e.length;s<a;s++)n=e[s].getVertex(),i=e[s].getBackward(),r=e[s-1].getForward(),t.bezierTo(r.x,r.y,i.x,i.y,n.x,n.y);return this}}})}},_p[24]={value:function(t,e,n){var r=_p.r(63),s=_p.r(73),i=_p.r(11).createClass("BezierPoint",{constructor:function(t,e,n){this.vertex=new r(t,e),this.forward=new r(t,e),this.backward=new r(t,e),this.setSmooth(void 0===n||n),this.setSymReflaction(!0)},clone:function(){var t=new i,e=null;return e=this.getVertex(),t.setVertex(e.x,e.y),e=this.getForward(),t.setForward(e.x,e.y),e=this.getBackward(),t.setBackward(e.x,e.y),t.setSymReflaction(this.isSymReflaction),t.setSmooth(this.isSmooth()),t},setVertex:function(t,e){return this.vertex.setPoint(t,e),this.update(),this},moveTo:function(t,e){var n=this.forward.getPoint(),r=this.backward.getPoint(),i=this.vertex.getPoint(),s=t-i.x,a=e-i.y;this.forward.setPoint(n.x+s,n.y+a),this.backward.setPoint(r.x+s,r.y+a),this.vertex.setPoint(t,e),this.update()},setForward:function(t,e){return this.forward.setPoint(t,e),this.smooth&&this.updateAnother(this.forward,this.backward),this.update(),this.lastControlPointSet=this.forward,this},setBackward:function(t,e){return this.backward.setPoint(t,e),this.smooth&&this.updateAnother(this.backward,this.forward),this.update(),this.lastControlPointSet=this.backward,this},setSymReflaction:function(t){return this.symReflaction=t,this.smooth&&this.setSmooth(!0),this},isSymReflaction:function(){return this.symReflaction},updateAnother:function(t,e){var n=this.getVertex(),r=s.fromPoints(t.getPoint(),n),i=s.fromPoints(n,e.getPoint());return i=r.normalize(this.isSymReflaction()?r.length():i.length()),e.setPoint(n.x+i.x,n.y+i.y),this},setSmooth:function(t){var e;return this.smooth=!!t,this.smooth&&(e=this.lastControlPointSet)&&this.updateAnother(e,e==this.forward?this.backward:this.forward),this},isSmooth:function(){return this.smooth},getVertex:function(){return this.vertex.getPoint()},getForward:function(){return this.forward.getPoint()},getBackward:function(){return this.backward.getPoint()},update:function(){if(!this.container)return this;this.container.update&&this.container.update(this)}});return i}},_p[25]={value:function(t,e,n){var u=_p.r(11).createClass("Box",{constructor:function(t,e,n,r){var i=t;i&&"object"==typeof i&&(t=i.x,e=i.y,n=i.width,r=i.height),n<0&&(t-=n=-n),r<0&&(e-=r=-r),this.x=t||0,this.y=e||0,this.width=n||0,this.height=r||0,this.left=this.x,this.right=this.x+this.width,this.top=this.y,this.bottom=this.y+this.height,this.cx=this.x+this.width/2,this.cy=this.y+this.height/2},getRangeX:function(){return[this.left,this.right]},getRangeY:function(){return[this.top,this.bottom]},merge:function(t){if(this.isEmpty())return new u(t.x,t.y,t.width,t.height);var e=Math.min(this.left,t.left),n=Math.max(this.right,t.right),r=Math.min(this.top,t.top),i=Math.max(this.bottom,t.bottom);return new u(e,r,n-e,i-r)},intersect:function(t){!t instanceof u&&(t=new u(t));var e=Math.max(this.left,t.left),n=Math.min(this.right,t.right),r=Math.max(this.top,t.top),i=Math.min(this.bottom,t.bottom);return n<e||i<r?new u:new u(e,r,n-e,i-r)},expand:function(t,e,n,r){if(arguments.length<1)return new u(this);arguments.length<2&&(e=t),arguments.length<3&&(n=t),arguments.length<4&&(r=e);var i=this.left-r,s=this.top-t,a=this.width+e,o=this.height+t;return new u(i,s,a,o)},valueOf:function(){return[this.x,this.y,this.width,this.height]},toString:function(){return this.valueOf().join(" ")},isEmpty:function(){return!this.width||!this.height}});return u.parse=function(t){return"string"==typeof t?u.parse(t.split(/[\s,]+/).map(parseFloat)):t instanceof Array?new u(t[0],t[1],t[2],t[3]):"x"in t?new u(t):null},u}},_p[26]={value:function(t,e,n){return _p.r(11).createClass("Circle",{base:_p.r(32),constructor:function(t,e,n){this.callBase(t,t,e,n)},getRadius:function(){return this.getRadiusX()},setRadius:function(t){return this.callBase(t,t)}})}},_p[27]={value:function(t,e,n){var r=_p.r(11),i=_p.r(60),s=r.createClass("Clip",{base:i,mixins:[_p.r(61)],constructor:function(t){this.callBase("clipPath",t)},clip:function(t){return t.getNode().setAttribute("clip-path",this),this}});return r.extendClass(i,{clipWith:function(t){return t instanceof i&&(t=new s(t.getPaper()).addShape(t)),t.clip(this),this}}),s}},_p[28]={value:function(t,e,n){var s=_p.r(12),r=_p.r(64),i={},a=_p.r(11).createClass("Color",{constructor:function(){var t=null;"string"==typeof arguments[0]?null===(t=i.parseToValue(arguments[0]))&&(t={r:0,g:0,b:0,h:0,s:0,l:0,a:1}):(t={r:0|arguments[0],g:0|arguments[1],b:0|arguments[2],a:void 0===arguments[3]?1:parseFloat(arguments[3])},t=i.overflowFormat(t),t=s.extend(t,i.rgbValueToHslValue(t))),this._color=t},set:function(t,e){if(!a._MAX_VALUE[t])throw new Error("Color set(): Illegal parameter");return"a"!==t&&(e=Math.floor(e)),"h"==t&&(e=(e+360)%360),this._color[t]=Math.max(a._MIN_VALUE[t],Math.min(a._MAX_VALUE[t],e)),-1!=="rgb".indexOf(t)?this._color=s.extend(this._color,i.rgbValueToHslValue(this._color)):-1!=="hsl".indexOf(t)&&(this._color=s.extend(this._color,i.hslValueToRGBValue(this._color))),this},inc:function(t,e){return e=this.get(t)+e,e="h"==t?(e+360)%360:(e=Math.min(a._MAX_VALUE[t],e),Math.max(a._MIN_VALUE[t],e)),this.clone().set(t,e)},dec:function(t,e){return this.inc(t,-e)},clone:function(){return new a(this.toRGBA())},get:function(t){return a._MAX_VALUE[t]?this._color[t]:null},getValues:function(){return s.clone(this._color)},valueOf:function(){return this.getValues()},toRGB:function(){return i.toString(this._color,"rgb")},toRGBA:function(){return i.toString(this._color,"rgba")},toHEX:function(){return i.toString(this._color,"hex")},toHSL:function(){return i.toString(this._color,"hsl")},toHSLA:function(){return i.toString(this._color,"hsla")},toString:function(){return 1===this._color.a?this.toRGB():this.toRGBA()}});return s.extend(a,{_MAX_VALUE:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},_MIN_VALUE:{r:0,g:0,b:0,h:0,s:0,l:0,a:0},R:"r",G:"g",B:"b",H:"h",S:"s",L:"l",A:"a",parse:function(t){var e;return s.isString(t)&&(e=i.parseToValue(t)),s.isObject(t)&&"r"in t&&(e=t),null===e?new a:new a(e.r,e.g,e.b,e.a)},createHSL:function(t,e,n){return a.createHSLA(t,e,n,1)},createHSLA:function(t,e,n,r){var i=null;return i=["hsla("+t,e+="%",n+="%",r+")"],a.parse(i.join(", "))},createRGB:function(t,e,n){return a.createRGBA(t,e,n,1)},createRGBA:function(t,e,n,r){return new a(t,e,n,r)}}),s.extend(i,{parseToValue:function(t){var e={};if(t=r.EXTEND_STANDARD[t]||r.COLOR_STANDARD[t]||t,/^#([0-9a-f]{3}|[0-9a-f]{6})$/i.test(t))e=i.hexToValue(t);else if(/^(rgba?)/i.test(t))e=i.rgbaToValue(t);else{if(!/^(hsla?)/i.test(t))return null;e=i.hslaToValue(t)}return i.overflowFormat(e)},hexToValue:function(n){var r={};return/^#([0-9a-f]{3}|[0-9a-f]{6})$/i.test(n)?(n=RegExp.$1.split(""),s.each(["r","g","b"],function(t,e){3===n.length?r[t]=i.toNumber(n[e]+n[e]):r[t]=i.toNumber(n[2*e]+n[2*e+1])}),(r=s.extend(r,i.rgbValueToHslValue(r))).a=1,r):null},rgbaToValue:function(n){var r={},t=!1;return/^(rgba?)/i.test(n)?(t=4===RegExp.$1.length,n=n.replace(/^rgba?/i,"").replace(/\s+/g,"").replace(/[^0-9,.]/g,"").split(","),s.each(["r","g","b"],function(t,e){r[t]=0|n[e]}),(r=s.extend(r,i.rgbValueToHslValue(r))).a=t?parseFloat(n[3]):1,r):null},hslaToValue:function(t){var e={},n=!1;return/^(hsla?)/i.test(t)?(n=4===RegExp.$1.length,t=t.replace(/^hsla?/i,"").replace(/\s+/g,"").replace(/[^0-9,.]/g,"").split(","),e.h=0|t[0],e.s=0|t[1],e.l=0|t[2],e=s.extend(e,i.hslValueToRGBValue(e)),(e=i.hslValueToRGBValue(e)).a=n?parseFloat(t[3]):1,e):null},hslValueToRGBValue:function(t){function e(t,e,n){return n<0?n+=1:1<n&&--n,6*n<1?t+6*(e-t)*n:2*n<1?e:3*n<2?t+6*(2/3-n)*(e-t):t}var n=null,r=null,i={};return(t=s.extend({},t)).h=t.h/360,t.s=t.s/100,t.l=t.l/100,0===t.s?i.r=i.g=i.b=t.l:(n=t.l<.5?t.l*(1+t.s):t.l+t.s-t.l*t.s,r=2*t.l-n,i.r=e(r,n,t.h+1/3),i.g=e(r,n,t.h),i.b=e(r,n,t.h-1/3)),i.r=Math.min(Math.round(255*i.r),255),i.g=Math.min(Math.round(255*i.g),255),i.b=Math.min(Math.round(255*i.b),255),i},rgbValueToHslValue:function(t){var e,n,r={};return(t=s.extend({},t)).r=t.r/255,t.g=t.g/255,t.b=t.b/255,(e=Math.max(t.r,t.g,t.b))===(n=Math.min(t.r,t.g,t.b))?r.h=0:e===t.r?t.g>=t.b?r.h=60*(t.g-t.b)/(e-n):r.h=60*(t.g-t.b)/(e-n)+360:e===t.g?r.h=60*(t.b-t.r)/(e-n)+120:e===t.b&&(r.h=60*(t.r-t.g)/(e-n)+240),r.l=(e+n)/2,0===r.l||e===n?r.s=0:0<r.l&&r.l<=.5?r.s=(e-n)/(e+n):r.s=(e-n)/(2-e-n),r.h=Math.round(r.h),r.s=Math.round(100*r.s),r.l=Math.round(100*r.l),r},toString:function(e,t){var n=[];return e=s.extend({},e),-1!==t.indexOf("hsl")&&(e.s+="%",e.l+="%"),"hex"!==t?(s.each(t.split(""),function(t){n.push(e[t])}),(t+"("+n.join(", ")+")").toLowerCase()):(n.push(i.toHexValue(+e.r)),n.push(i.toHexValue(+e.g)),n.push(i.toHexValue(+e.b)),("#"+n.join("")).toLowerCase())},toNumber:function(t){return 0|Number("0x"+t)},toHexValue:function(t){var e=t.toString(16);return 1===e.length?"0"+e:e},overflowFormat:function(t){var e=s.extend({},t);return s.each("rgba".split(""),function(t){e.hasOwnProperty(t)&&(e[t]=Math.min(a._MAX_VALUE[t],e[t]),e[t]=Math.max(a._MIN_VALUE[t],e[t]))}),e}}),a}},_p[29]={value:function(t,e,n){function s(){return this.container.removeItem(this),this}return _p.r(11).createClass("Container",{getItems:function(){return this.items||(this.items=[])},getItem:function(t){return this.getItems()[t]},getFirstItem:function(){return this.getItem(0)},getLastItem:function(){return this.getItem(this.getItems().length-1)},indexOf:function(t){return this.getItems().indexOf(t)},eachItem:function(t){var e,n=this.getItems(),r=n.length;for(e=0;e<r;e++)t.call(this,e,n[e]);return this},addItem:function(t,e,n){var r=this.getItems(),i=r.length;return~r.indexOf(t)||(0<=e&&e<i||(e=i),r.splice(e,0,t),"object"==typeof t&&(t.container=this,t.remove=s),this.handleAdd(t,e),n||this.onContainerChanged("add",[t])),this},addItems:function(t){for(var e=0,n=t.length;e<n;e++)this.addItem(t[e],-1,!0);return this.onContainerChanged("add",t),this},setItems:function(t){return this.clear().addItems(t)},appendItem:function(t){return this.addItem(t)},prependItem:function(t){return this.addItem(t,0)},removeItem:function(t,e){if("number"!=typeof t)return this.removeItem(this.indexOf(t));var n=this.getItems(),r=(n.length,n[t]);return void 0===r||(n.splice(t,1),r.container&&delete r.container,r.remove&&delete r.remove,this.handleRemove(r,t),e||this.onContainerChanged("remove",[r])),this},clear:function(){for(var t,e=[];t=this.getFirstItem();)e.push(t),this.removeItem(0,!0);return this.onContainerChanged("remove",e),this},onContainerChanged:function(t,e){},handleAdd:function(t,e){},handleRemove:function(t,e){}})}},_p[30]={value:function(t,e,n){var c=_p.r(12),u={getCurvePanLines:function(t,e){var n=u.getCenterPoints(t),r=u.getPanLine(t.length,n);return u.getMovedPanLines(t,r,e)},getCenterPoints:function(t){for(var e={},n=0,r=0,i=t.length;n<i;n++)e[n+","+(r=n===i-1?0:n+1)]={x:(t[n].x+t[r].y)/2,y:(t[n].x+t[r].y)/2};return e},getPanLine:function(t,e){for(var n,r={},i=null,s=0;s<t;s++){var a,o;a=e[s+","+(i=n=(s+1)%t)],o=e[(s=n)+","+(n=(s+1)%t)],r[i]={points:[{x:a.x,y:a.y},{x:o.x,y:o.y}],center:{x:(a.x+o.x)/2,y:(a.y+o.y)/2}},s=(i+t-1)%t}return r},getMovedPanLines:function(t,i,h){var s={};return c.each(t,function(t,e){var n=i[e],r=n.center,a=r.x-t.x,o=r.y-t.y,u=s[e]={points:[],center:{x:t.x,y:t.y}};c.each(n.points,function(t,e){var n={x:t.x-a,y:t.y-o},r=u.center,i=n.x-r.x,s=n.y-r.y;n.x=r.x+h*i,n.y=r.y+h*s,u.points.push(n)})}),s}};return _p.r(11).createClass("Curve",{base:_p.r(46),mixins:[_p.r(51)],constructor:function(t,e){this.callBase(),this.setPoints(t||[]),this.closeState=!!e,this.changeable=!0,this.smoothFactor=1,this.update()},onContainerChanged:function(){this.changeable&&this.update()},setSmoothFactor:function(t){return this.smoothFactor=t<0?0:t,this.update(),this},getSmoothFactor:function(){return this.smoothFactor},update:function(){var t,e=this.getPoints(),n=this.getDrawer(),r=null,i=null,s=null;if(n.clear(),0===e.length)return this;if(n.moveTo(e[0]),1===e.length)return this;if(2===e.length)return n.lineTo(e[1]),this;t=u.getCurvePanLines(e,this.getSmoothFactor());for(var a=1,o=e.length;a<o;a++)r=t[a].center,i=this.closeState||a!=o-1?t[a].points[0]:t[a].center,s=this.closeState||1!=a?t[a-1].points[1]:t[a-1].center,n.bezierTo(s.x,s.y,i.x,i.y,r.x,r.y);return this.closeState&&(r=t[0].center,i=t[0].points[0],s=t[e.length-1].points[1],n.bezierTo(s.x,s.y,i.x,i.y,r.x,r.y)),this},close:function(){return this.closeState=!0,this.update()},open:function(){return this.closeState=!1,this.update()},isClose:function(){return!!this.closeState}})}},_p[31]={value:function(t,e,n){return _p.r(11).createClass("Data",{constructor:function(){this._data={}},setData:function(t,e){return this._data[t]=e,this},getData:function(t){return this._data[t]},removeData:function(t){return delete this._data[t],this}})}},_p[32]={value:function(t,e,n){_p.r(12);var r=_p.r(50);return _p.r(11).createClass("Ellipse",{base:_p.r(46),constructor:function(t,e,n,r){this.callBase(),this.rx=t||0,this.ry=e||0,this.cx=n||0,this.cy=r||0,this.update()},update:function(){var t=this.rx,e=this.ry,n=this.cx+t,r=this.cx-t,i=this.cy,s=this.getDrawer();return s.clear(),s.moveTo(n,i),s.arcTo(t,e,0,1,1,r,i),s.arcTo(t,e,0,1,1,n,i),this},getRadius:function(){return{x:this.rx,y:this.ry}},getRadiusX:function(){return this.rx},getRadiusY:function(){return this.ry},getCenter:function(){return new r(this.cx,this.cy)},getCenterX:function(){return this.cx},getCenterY:function(){return this.cy},setRadius:function(t,e){return this.rx=t,this.ry=e,this.update()},setRadiusX:function(t){return this.rx=t,this.update()},setRadiusY:function(t){return this.ry=t,this.update()},setCenter:function(t,e){if(1==arguments.length){var n=r.parse(t);t=n.x,e=n.y}return this.cx=t,this.cy=e,this.update()},setCenterX:function(t){return this.cx=t,this.update()},setCenterY:function(t){return this.cy=t,this.update()}})}},_p[33]={value:function(t,e,n){function r(t,e){e=e||{bubbles:!1,cancelable:!1,detail:void 0};var n=document.createEvent("CustomEvent");return n.initCustomEvent(t,e.bubbles,e.cancelable,e.detail),n}r.prototype=window.Event.prototype,window.CustomEvent=r;var u=_p.r(12),o=_p.r(62),h={},c={},i=0;function s(t,e,n){return n=!!n,u.isString(t)&&(t=t.match(/\S+/g)),u.each(t,function(t){(function(t,r,e,i){var s=this._EVNET_UID,a=this;h[s]||(h[s]={});h[s][r]||(h[s][r]=function(n){n=new o(n||window.event),u.each(c[s][r],function(t){var e;return t&&(e=t.call(a,n),i&&a.off(r,t)),e},a)});c[s]||(c[s]={});c[s][r]?c[s][r].push(e):(c[s][r]=[e],t&&"on"+r in t&&function(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent("on"+e,n)}(t,r,h[s][r]))}).call(this,this.node,t,e,n)},this),this}return _p.r(11).createClass("EventHandler",{constructor:function(){this._EVNET_UID=++i},addEventListener:function(t,e){return s.call(this,t,e,!1)},addOnceEventListener:function(t,e){return s.call(this,t,e,!0)},removeEventListener:function(t,e){return function(t,n){var e,r,i,s=null,a=this._EVNET_UID,o=void 0===n;return s=c[a][t],o||(o=!0,u.each(s,function(t,e){t===n?delete s[e]:o=!1})),o&&(e=this.node,r=t,i=h[a][t],e.removeEventListener?e.removeEventListener(r,i,!1):e.detachEvent(r,i),delete c[a][t],delete h[a][t]),this}.call(this,t,e)},on:function(t,e){return this.addEventListener.apply(this,arguments)},once:function(t,e){return this.addOnceEventListener.apply(this,arguments)},off:function(){return this.removeEventListener.apply(this,arguments)},fire:function(t,e){return this.trigger.apply(this,arguments)},trigger:function(t,e){var n,r,i,s,a,o;return r=t,i=e,a=null,(o=h[(n=this)._EVNET_UID])&&(a=o[r])&&(s=u.extend({type:r,target:n},i||{}),a.call(n,s)),this}})}},_p[34]={value:function(t){var e=_p.r(12),o=_p.r(50),a=_p.r(73),n=_p.r(43),v={},r=/([achlmrqstvz])[\s,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\s]*,?\s*)+)/gi,u=/(-?\d*\.?\d*(?:e[\-+]?\d+)?)\s*,?\s*/gi,h={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0};function c(t){var e,n,r,i,s;for(e=[],n=0;n<t.length;n++)for(i=t[n],e.push(s=[]),r=0;r<i.length;r++)s.push(i[r]);return t.isUniform&&(e.isUniform=!0),t.isAbsolute&&(e.isAbsolute=!0),t.isCurve&&(e.isCurve=!0),e}function i(s,a,o){return function t(){var e=Array.prototype.slice.call(arguments,0),n=e.join(""),r=t.cache=t.cache||{},i=t.count=t.count||[];return r.hasOwnProperty(n)?function(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n]===e)return t.push(t.splice(n,1)[0])}(i,n):(1e3<=i.length&&delete r[i.shift()],i.push(n),r[n]=s.apply(a,e)),o?o(r[n]):r[n]}}function j(t,e,n,r,i,s,a,o,u,h){function c(t,e,n){return{x:t*U.cos(n)-e*U.sin(n),y:t*U.sin(n)+e*U.cos(n)}}var l,f,p,d,g,_,m,v,y,b,x,w,A,C,P,T,M,E,O,S,R,I,N,B,k,V,L,F,D,U=Math,H=U.PI,G=Math.abs,K=120*H/180,X=H/180*(+i||0),z=[];if(h?(b=h[0],x=h[1],v=h[2],y=h[3]):(t=(l=c(t,e,-X)).x,e=l.y,o=(l=c(o,u,-X)).x,u=l.y,U.cos(H/180*i),U.sin(H/180*i),1<(f=(p=(t-o)/2)*p/(n*n)+(d=(e-u)/2)*d/(r*r))&&(n*=f=U.sqrt(f),r*=f),g=n*n,_=r*r,v=(m=(s==a?-1:1)*U.sqrt(G((g*_-g*d*d-_*p*p)/(g*d*d+_*p*p))))*n*d/r+(t+o)/2,y=m*-r*p/n+(e+u)/2,b=U.asin(((e-y)/r).toFixed(9)),x=U.asin(((u-y)/r).toFixed(9)),(b=t<v?H-b:b)<0&&(b=2*H+b),(x=o<v?H-x:x)<0&&(x=2*H+x),a&&x<b&&(b-=2*H),!a&&b<x&&(x-=2*H)),G(w=x-b)>K&&(A=x,C=o,P=u,x=b+K*(a&&b<x?1:-1),z=j(o=v+n*U.cos(x),u=y+r*U.sin(x),n,r,i,0,a,C,P,[x,A,v,y])),w=x-b,T=U.cos(b),M=U.sin(b),E=U.cos(x),O=U.sin(x),k=[o+(R=4/3*n*(S=U.tan(w/4)))*O,u-(I=4/3*r*S)*E],V=[o,u],(B=[t+R*M,e-I*T])[0]=2*(N=[t,e])[0]-B[0],B[1]=2*N[1]-B[1],h)return[B,k,V].concat(z);for(L=[],F=0,D=(z=[B,k,V].concat(z).join().split(",")).length;F<D;F++)L[F]=F%2?c(z[F-1],z[F],X).y:c(z[F],z[F+1],X).x;return L}function d(t,e,n,r,i,s){return[1/3*t+2/3*n,1/3*e+2/3*r,1/3*i+2/3*n,1/3*s+2/3*r,i,s]}function l(t,e){var n,r=(n=e||.5,function(t,e){return t+n*(e-t)}),i=t[0],s=t[1],a=t[2],o=t[3],u=t[4],h=t[5],c=t[6],l=t[7],f=r(i,a),p=r(s,o),d=r(a,u),g=r(o,h),_=r(u,c),m=r(h,l),v=r(f,d),y=r(p,g),b=r(d,_),x=r(g,m),w=r(v,b),A=r(y,x);return[[i,s,f,p,v,y,w,A],[w,A,b,x,_,m,c,l]]}v.pathToString=function(t){return"string"==typeof(t=t||this)?t:t instanceof Array?(t=e.flatten(t)).join(",").replace(/,?([achlmqrstvxz]),?/gi,"$1"):void 0},v.parsePathString=i(function(t){var s=[];return t.replace(r,function(t,e,n){var r=[],i=e.toLowerCase();if(n.replace(u,function(t,e){e&&r.push(+e)}),"m"==i&&2<r.length&&(s.push([e].concat(r.splice(0,2))),i="l",e="m"==e?"l":"L"),"r"==i)s.push([e].concat(r));else for(;r.length>=h[i]&&(s.push([e].concat(r.splice(0,h[i]))),h[i]););}),s.isUniform=!0,s.toString=v.pathToString,s}),v.pathToAbsolute=i(function(t){var e,n,r,i,s,a,o,u,h=t.isUniform?t:v.parsePathString(v.pathToString(t)),c=[],l=0,f=0,p=0,d=0,g=0;for("M"==h[0][0]&&(p=l=+h[0][1],d=f=+h[0][2],g++,c[0]=["M",l,f]),r=g,a=h.length;r<a;r++){if(c.push(e=[]),(n=h[r])[0]!=n[0].toUpperCase())switch(e[0]=n[0].toUpperCase(),e[0]){case"A":e[1]=n[1],e[2]=n[2],e[3]=n[3],e[4]=n[4],e[5]=n[5],e[6]=+(n[6]+l),e[7]=+(n[7]+f);break;case"V":e[1]=+n[1]+f;break;case"H":e[1]=+n[1]+l;break;case"M":p=+n[1]+l,d=+n[2]+f;break;default:for(i=1,o=n.length;i<o;i++)e[i]=+n[i]+(i%2?l:f)}else for(s=0,u=n.length;s<u;s++)e[s]=n[s];switch(e[0]){case"Z":l=p,f=d;break;case"H":l=e[1];break;case"V":f=e[1];break;case"M":p=e[e.length-2],d=e[e.length-1];break;default:l=e[e.length-2],f=e[e.length-1]}}return c.isUniform=!0,c.isAbsolute=!0,c.toString=v.pathToString,c}),v.pathToCurve=i(function(t){var e,n,r,i,s,a,o,u,h,c,l,f,p=[];for(t.isAbsolute||(t=v.pathToAbsolute(t)),e=0;e<t.length;e++)if(r=t[e][0],i=t[e].slice(1),"M"!=r){switch("Z"==r&&(u=!0,r="L",i=s),o=i.slice(i.length-2),"H"==r&&(o=[i[0],a[1]],r="L"),"V"==r&&(o=[a[0],i[0]],r="L"),"S"!=r&&"T"!=r||(c=[a[0]+(a[0]-h[0]),a[1]+(a[1]-h[1])]),r){case"L":l=a,f=o;break;case"C":l=i.slice(0,2),f=i.slice(2,4);break;case"S":l=c.slice(),f=i.slice(0,2);break;case"Q":h=i.slice(0,2),l=(i=d.apply(null,a.concat(i))).slice(0,2),f=i.slice(2,4);break;case"T":l=(i=d.apply(null,a.concat(c).concat(i))).slice(0,2),f=i.slice(2,4);break;case"A":for(i=j.apply(null,a.concat(i)),n=0;n in i;)l=i.slice(n,n+2),f=i.slice(n+2,n+4),o=i.slice(n+4,n+6),p.push(["C"].concat(l).concat(f).concat(o)),n+=6}"A"!=r&&p.push(["C"].concat(l).concat(f).concat(o)),a=o,"Q"!=r&&(h=f),u&&(p.push(["Z"]),u=!1)}else s=h=a=i,p.push(t[e]);return p.isUniform=!0,p.isAbsolute=!0,p.isCurve=!0,p.toString=v.pathToString,p}),v.cutBezier=i(l),v.subBezier=function(t,e,n){var r=l(t,e)[0];return n?l(r,n/e)[1]:r},v.pointAtBezier=function(t,e){var n=l(t,e)[0],r=o.parse(n.slice(6)),i=o.parse(n.slice(4,2)),s=a.fromPoints(i,r);return r.tan=0===e?v.pointAtBezier(t,.01).tan:s.normalize(),r},v.bezierLength=i(function(t){function e(t){var e=u*Math.pow(t,4)+h*Math.pow(t,3)+c*Math.pow(t,2)+l*t+f;return e<0&&(e=0),Math.pow(e,.5)}var n,r,i,s,a,o,u,h,c,l,f;return n=-3*t[0]+9*t[2]-9*t[4]+3*t[6],r=6*t[0]-12*t[2]+6*t[4],i=-3*t[0]+3*t[2],s=-3*t[1]+9*t[3]-9*t[5]+3*t[7],a=6*t[1]-12*t[3]+6*t[5],o=-3*t[1]+3*t[3],u=Math.pow(n,2)+Math.pow(s,2),h=2*(n*r+s*a),c=2*(n*i+s*o)+Math.pow(r,2)+Math.pow(a,2),l=2*(r*i+a*o),f=Math.pow(i,2)+Math.pow(o,2),(e(0)+e(1)+4*(e(.125)+e(.375)+e(.625)+e(.875))+2*(e(.25)+e(.5)+e(.75)))/24});var y=i(function(t){var e,n,r,i,s,a,o;for(a=[],e=o=0,n=t.length;e<n;e++)"M"!=(r=t[e])[0]?"Z"!=r[0]?(s=v.bezierLength(i.concat(r.slice(1))),a.push([o,o+s]),o+=s,i=r.slice(4)):a.push(null):(i=r.slice(1),a.push(null));return a.totalLength=o,a});v.subPath=function(t,e,n){var r;if(r=e-(n=n||0),1<(e=(n-=0|n)+(r-=0|r)))return v.subPath(t,1,n).concat(v.subPath(t,e-1));t.isCurve||(t=v.pathToCurve(t));var i,s,a,o,u,h,c,l,f,p=y(t),d=p.totalLength,g=d*e,_=d*(n||0),m=[];for(i=0,s=t.length;i<s;i++)if("M"!=t[i][0]){if("Z"!=t[i][0])if(a=p[i][0],u=(o=p[i][1])-a,c=h.concat(t[i].slice(1)),o<_)h=c.slice(c.length-2);else{if(a<=_)f=!0,h=(l=v.subBezier(c,Math.min((g-a)/u,1),(_-a)/u)).slice(0,2),m.push(["M"].concat(l.slice(0,2))),m.push(["C"].concat(l.slice(2)));else if(o<=g)m.push(t[i].slice());else{if(!(a<=g))break;l=v.subBezier(c,(g-a)/u),m.push(["C"].concat(l.slice(2))),f=!1}h=c.slice(c.length-2)}}else h=t[i].slice(1),f&&m.push(t[i].slice());return m.isAbsolute=!0,m.isCurve=!0,m.isUniform=!0,m.toString=v.pathToString,m},v.pointAtPath=function(t,e){t.isCurve||(t=v.pathToCurve(t));var n=v.subPath(t,e),r="Z"==n[n.length-1][0]?n[n.length-2]:n[n.length-1];r=r.slice(1);var i=o.parse(r.slice(4)),s=o.parse(r.slice(2,4));return i.tan=a.fromPoints(s,i).normalize(),i},v.pathLength=i(function(t){return t.isCurve||(t=v.pathToCurve(t)),y(t).totalLength}),v.pathKeyPoints=i(function(t){var e,n,r;for(t.isCurve||(t=v.pathToCurve(t)),r=[],e=0,n=t.length;e<n;e++)"z"!=t[e][0]&&r.push(t[e].slice(t[e].length-2));return r});var f=i(function(t,e){t.isCurve||(t=v.pathToCurve(t)),e.isCurve||(e=v.pathToCurve(e));var n=c(t),r=c(e);function i(t,e){return t[e||t.i]&&t[e||t.i][0]}function s(t,e){var n,r,i=(n=t)[(r=e)||n.i]&&n[r||n.i].slice(1);return i&&i.slice(-2)}function a(t){return"Z"==i(t)&&(t.splice(t.i,1),1)}function o(t){return"M"==i(t)&&(t.o.splice(t.o.i,0,["M"].concat(s(t.o,t.o.i-1))),t.i++,t.o.i++,1)}function u(t){for(var e,n=1;!e;)e=s(t,t.length-n++);for(t.o.i=t.i;t.length<t.o.length;)a(t.o)||o(t.o)||(t.push(["C"].concat(e).concat(e).concat(e)),t.i++,t.o.i++)}for(n.i=0,r.i=0,(n.o=r).o=n;n.i<n.length&&r.i<r.length;)a(n)||a(r)||i(n)!=i(r)&&(o(n)||o(r))||(n.i++,r.i++);return n.i==n.length&&u(n),r.i==r.length&&u(r),delete n.i,delete n.o,delete r.i,delete r.o,[n,r]});return v.alignCurve=f,v.pathTween=function(t,e,n){if(0===n)return t;if(1===n)return e;var r,i,s,a=f(t,e),o=[];for(t=a[0],e=a[1],i=0;i<t.length;i++)for(o.push(r=[]),r.push(t[i][0]),s=1;s<t[i].length;s++)r.push(t[i][s]+n*(e[i][s]-t[i][s]));return o.isUniform=o.isCurve=o.isAbsolute=!0,o},v.transformPath=i(function(t,e){var n,r,i,s,a;for(t.isCurve||(t=v.pathToCurve(t)),s=[],n=0,r=t.length;n<r;n++)for(s.push([t[n][0]]),i=1;i<t[n].length;i+=2)a=t[n].slice(i,i+2),a=e.transformPoint(o.parse(a)),s.push(a);return s}),_p.r(11).extendClass(n,{transformPath:function(t){return v.transformPath(t,this)}}),v}},_p[35]={value:function(t,e,n){var i=_p.r(67),r=_p.r(58),s=_p.r(28);return _p.r(11).createClass("GradientBrush",{base:r,constructor:function(t,e){this.callBase(t,e),this.stops=[]},addStop:function(t,e,n){var r=i.createNode("stop");return e instanceof s||(e=s.parse(e)),void 0===n&&(n=e.get("a")),r.setAttribute("offset",t),r.setAttribute("stop-color",e.toRGB()),n<1&&r.setAttribute("stop-opacity",n),this.node.appendChild(r),this}})}},_p[36]={value:function(t,e,n){var r=_p.r(61);return _p.r(11).createClass("Group",{mixins:[r],base:_p.r(60),constructor:function(){this.callBase("g")}})}},_p[37]={value:function(t,e,n){var r=_p.r(61);return _p.r(11).createClass("HyperLink",{mixins:[r],base:_p.r(60),constructor:function(t){this.callBase("a"),this.setHref(t)},setHref:function(t){return this.node.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",t),this},getHref:function(){return this.node.getAttributeNS("xlink:href")},setTarget:function(t){return this.node.setAttribute("target",t),this},getTarget:function(){return this.node.getAttribute("target")}})}},_p[38]={value:function(t,e,n){return _p.r(11).createClass("Image",{base:_p.r(60),constructor:function(t,e,n,r,i){this.callBase("image"),this.url=t,this.width=e||0,this.height=n||0,this.x=r||0,this.y=i||0,this.update()},update:function(){return this.node.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",this.url),this.node.setAttribute("x",this.x),this.node.setAttribute("y",this.y),this.node.setAttribute("width",this.width),this.node.setAttribute("height",this.height),this},setUrl:function(t){return this.url=""===t?null:t,this.update()},getUrl:function(){return this.url},setWidth:function(t){return this.width=t,this.update()},getWidth:function(){return this.width},setHeight:function(t){return this.height=t,this.update()},getHeight:function(){return this.height},setX:function(t){return this.x=t,this.update()},getX:function(){return this.x},setY:function(t){return this.y=t,this.update()},getY:function(){return this.y}})}},_p[39]={value:function(t,e,n){return _p.r(11).createClass("Line",{base:_p.r(46),constructor:function(t,e,n,r){this.callBase(),this.point1={x:t||0,y:e||0},this.point2={x:n||0,y:r||0},this.update()},setPoint1:function(t,e){return this.point1.x=t,this.point1.y=e,this.update()},setPoint2:function(t,e){return this.point2.x=t,this.point2.y=e,this.update()},getPoint1:function(){return{x:this.point1.x,y:this.point1.y}},getPoint2:function(){return{x:this.point2.x,y:this.point2.y}},update:function(){var t=this.getDrawer();return t.clear(),t.moveTo(this.point1.x,this.point1.y),t.lineTo(this.point2.x,this.point2.y),this}})}},_p[40]={value:function(t,e,n){_p.r(67);var r=_p.r(35);return _p.r(11).createClass("LinearGradientBrush",{base:r,constructor:function(t){this.callBase("linearGradient",t),this.setStartPosition(0,0),this.setEndPosition(1,0)},setStartPosition:function(t,e){return this.node.setAttribute("x1",t),this.node.setAttribute("y1",e),this},setEndPosition:function(t,e){return this.node.setAttribute("x2",t),this.node.setAttribute("y2",e),this},getStartPosition:function(){return{x:+this.node.getAttribute("x1"),y:+this.node.getAttribute("y1")}},getEndPosition:function(){return{x:+this.node.getAttribute("x2"),y:+this.node.getAttribute("y2")}}})}},_p[41]={value:function(t,e,n){var r=_p.r(50),i=_p.r(11).createClass("Marker",{base:_p.r(58),mixins:[_p.r(61),_p.r(75)],constructor:function(){this.callBase("marker"),this.setOrient("auto")},setRef:function(t,e){return 1===arguments.length&&(e=t.y,t=t.x),this.node.setAttribute("refX",t),this.node.setAttribute("refY",e),this},getRef:function(){return new r(+this.node.getAttribute("refX"),+this.node.getAttribute("refY"))},setWidth:function(t){return this.node.setAttribute("markerWidth",this.width=t),this},setOrient:function(t){return this.node.setAttribute("orient",this.orient=t),this},getOrient:function(){return this.orient},getWidth:function(){return+this.width},setHeight:function(t){return this.node.setAttribute("markerHeight",this.height=t),this},getHeight:function(){return+this.height}}),s=_p.r(46);return _p.r(11).extendClass(s,{setMarker:function(t,e){return e=e||"end",t?this.node.setAttribute("marker-"+e,t.toString()):this.node.removeAttribute("marker-"+e),this}}),i}},_p[42]={value:function(t,e,n){var r=_p.r(11),i=_p.r(60),s=r.createClass("Mask",{base:i,mixins:[_p.r(61)],constructor:function(){this.callBase("mask")},mask:function(t){return t.getNode().setAttribute("mask","url(#"+this.getId()+")"),this}});return r.extendClass(i,{maskWith:function(t){return t.mask(this),this}}),s}},_p[43]={value:function(t,e,n){var c=_p.r(12),l=_p.r(25),i=/matrix\s*\((.+)\)/i,r=_p.r(50);function s(t,e){return{a:e.a*t.a+e.c*t.b,b:e.b*t.a+e.d*t.b,c:e.a*t.c+e.c*t.d,d:e.b*t.c+e.d*t.d,e:e.a*t.e+e.c*t.f+e.e,f:e.b*t.e+e.d*t.f+e.f}}function a(t){return t*Math.PI/180}var f=_p.r(11).createClass("Matrix",{constructor:function(){arguments.length?this.setMatrix.apply(this,arguments):this.setMatrix(1,0,0,1,0,0)},translate:function(t,e){return this.m=s(this.m,{a:1,c:0,e:t,b:0,d:1,f:e}),this},rotate:function(t){var e=a(t),n=Math.sin(e),r=Math.cos(e);return this.m=s(this.m,{a:r,c:-n,e:0,b:n,d:r,f:0}),this},scale:function(t,e){return void 0===e&&(e=t),this.m=s(this.m,{a:t,c:0,e:0,b:0,d:e,f:0}),this},skew:function(t,e){void 0===e&&(e=t);var n=Math.tan(a(t)),r=Math.tan(a(e));return this.m=s(this.m,{a:1,c:n,e:0,b:r,d:1,f:0}),this},inverse:function(){var t,e=this.m,n=e.a,r=e.b,i=e.c,s=e.d,a=e.e,o=e.f;return new f(s/(t=n*s-r*i),-r/t,-i/t,n/t,(i*o-a*s)/t,(r*a-n*o)/t)},setMatrix:function(t,e,n,r,i,s){return this.m=1===arguments.length?c.clone(t):{a:t,b:e,c:n,d:r,e:i,f:s},this},getMatrix:function(){return c.clone(this.m)},getTranslate:function(){var t=this.m;return{x:t.e/t.a,y:t.f/t.d}},mergeMatrix:function(t){return new f(s(this.m,t.m))},merge:function(t){return this.mergeMatrix(t)},toString:function(){return this.valueOf().join(" ")},valueOf:function(){var t=this.m;return[t.a,t.b,t.c,t.d,t.e,t.f]},equals:function(t){var e=this.m,n=t.m;return e.a==n.a&&e.b==n.b&&e.c==n.c&&e.d==n.d&&e.e==n.e&&e.f==n.f},transformPoint:function(){return f.transformPoint.apply(null,[].slice.call(arguments).concat([this.m]))},transformBox:function(t){return f.transformBox(t,this.m)},clone:function(){return new f(this.m)}});return f.parse=function(t){var e,n=parseFloat;if(t instanceof Array)return new f({a:t[0],b:t[1],c:t[2],d:t[3],e:t[4],f:t[5]});if(e=i.exec(t)){var r=e[1].split(",");return 6!=r.length&&(r=e[1].split(" ")),new f({a:n(r[0]),b:n(r[1]),c:n(r[2]),d:n(r[3]),e:n(r[4]),f:n(r[5])})}return new f},f.transformPoint=function(t,e,n){return 2===arguments.length&&(n=e,e=t.y,t=t.x),new r(n.a*t+n.c*e+n.e,n.b*t+n.d*e+n.f)},f.transformBox=function(t,e){for(var n,r,i=Number.MAX_VALUE,s=-Number.MAX_VALUE,a=Number.MAX_VALUE,o=-Number.MAX_VALUE,u=[[t.x,t.y],[t.x+t.width,t.y],[t.x,t.y+t.height],[t.x+t.width,t.y+t.height]],h=[];n=u.pop();)r=f.transformPoint(n[0],n[1],e),h.push(r),i=Math.min(i,r.x),s=Math.max(s,r.x),a=Math.min(a,r.y),o=Math.max(o,r.y);return t=new l({x:i,y:a,width:s-i,height:o-a}),c.extend(t,{closurePoints:h}),t},f.getCTM=function(t,e){var n={a:1,b:0,c:0,d:1,e:0,f:0},r=t.shapeNode||t.node;function i(t,e){var n;try{n=e.getScreenCTM().inverse()}catch(t){throw new Error("Can not inverse source element' ctm.")}return n.multiply(t.getScreenCTM())}switch(e=e||"parent"){case"screen":n=r.getScreenCTM();break;case"doc":case"paper":n=r.getCTM();break;case"view":case"top":t.getPaper()&&(n=void 0!==r.getTransformToElement?r.getTransformToElement(t.getPaper().shapeNode):i(r,t.getPaper().shapeNode));break;case"parent":t.node.parentNode&&(n=void 0!==r.getTransformToElement?r.getTransformToElement(t.node.parentNode):i(r,t.node.parentNode));break;default:e.node&&(n=void 0!==r.getTransformToElement?r.getTransformToElement(e.shapeNode||e.node):i(r,e.shapeNode||e.node))}return n?new f(n.a,n.b,n.c,n.d,n.e,n.f):new f},f}},_p[44]={value:function(t,e,n){var r=_p.r(64),i=_p.r(28),s=_p.r(12),a=_p.r(11).createClass("Palette",{constructor:function(){this.color={}},get:function(t){var e=this.color[t]||r.EXTEND_STANDARD[t]||r.COLOR_STANDARD[t]||"";return e?new i(e):null},getColorValue:function(t){return this.color[t]||r.EXTEND_STANDARD[t]||r.COLOR_STANDARD[t]||""},add:function(t,e){return this.color[t]="string"==typeof e?new i(e).toRGBA():e.toRGBA(),e},remove:function(t){return!!this.color.hasOwnProperty(t)&&(delete this.color[t],!0)}});return s.extend(a,{getColor:function(t){var e=r.EXTEND_STANDARD[t]||r.COLOR_STANDARD[t];return e?new i(e):null},getColorValue:function(t){return r.EXTEND_STANDARD[t]||r.COLOR_STANDARD[t]||""},addColor:function(t,e){return r.EXTEND_STANDARD[t]="string"==typeof e?new i(e).toRGBA():e.toRGBA(),e},removeColor:function(t){return!!r.EXTEND_STANDARD.hasOwnProperty(t)&&(delete r.EXTEND_STANDARD[t],!0)}}),a}},_p[45]={value:function(t,e,n){var r=_p.r(11),i=_p.r(12),s=_p.r(67),a=_p.r(29),o=_p.r(61),u=_p.r(75),h=_p.r(33),c=_p.r(66),l=_p.r(43),f=r.createClass("Paper",{mixins:[o,h,c,u],constructor:function(t){this.callBase(),this.node=this.createSVGNode(),(this.node.paper=this).node.appendChild(this.resourceNode=s.createNode("defs")),this.node.appendChild(this.shapeNode=s.createNode("g")),this.resources=new a,this.setWidth("100%").setHeight("100%"),t&&this.renderTo(t),this.callMixin()},renderTo:function(t){i.isString(t)&&(t=document.getElementById(t)),(this.container=t).appendChild(this.node)},createSVGNode:function(){var t=s.createNode("svg");return t.setAttribute("xmlns","http://www.w3.org/2000/svg"),t.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.setAttribute("version","1.1"),t},getNode:function(){return this.node},getContainer:function(){return this.container},getWidth:function(){return this.node.clientWidth},setWidth:function(t){return this.node.setAttribute("width",t),this},getHeight:function(){return this.node.clientHeight},setHeight:function(t){return this.node.setAttribute("height",t),this},setViewPort:function(t,e,n){var r,i;1==arguments.length&&(t=(r=t).center.x,e=r.center.y,n=r.zoom),n=n||1,i=this.getViewBox();var s=new l,a=i.x+i.width/2-t,o=i.y+i.height/2-e;return s.translate(-t,-e),s.scale(n),s.translate(t,e),s.translate(a,o),this.shapeNode.setAttribute("transform","matrix("+s+")"),this.viewport={center:{x:t,y:e},offset:{x:a,y:o},zoom:n},this},getViewPort:function(){if(this.viewport)return this.viewport;var t=this.getViewBox();return{zoom:1,center:{x:t.x+t.width/2,y:t.y+t.height/2},offset:{x:0,y:0}}},getViewPortMatrix:function(){return l.parse(this.shapeNode.getAttribute("transform"))},getViewPortTransform:function(){var t=this.shapeNode.getCTM();return new l(t.a,t.b,t.c,t.d,t.e,t.f)},getTransform:function(){return this.getViewPortTransform().reverse()},addResource:function(t){return this.resources.appendItem(t),t.node&&this.resourceNode.appendChild(t.node),this},removeResource:function(t){return t.remove&&t.remove(),t.node&&this.resourceNode.removeChild(t.node),this},getPaper:function(){return this}}),p=_p.r(60);return r.extendClass(p,{getPaper:function(){for(var t=this.container;t&&t instanceof f==!1;)t=t.container;return t},isAttached:function(){return!!this.getPaper()},whenPaperReady:function(e){var n=this;function r(){var t=n.getPaper();return t&&e&&e.call(n,t),t}return r()||this.on("add treeadd",function t(){r()&&(n.off("add",t),n.off("treeadd",t))}),this}}),f}},_p[46]={value:function(t,e,n){var r=_p.r(12),i=_p.r(11).createClass,s=_p.r(60),a=_p.r(67),o=_p.r(34),u=Array.prototype.slice,h=(r.flatten,i("PathDrawer",{constructor:function(t){this.segment=[],this.path=t,this.__clear=!1},getPath:function(){return this.path},redraw:function(){return this._transation=this._transation||[],this.clear()},done:function(){var t=this._transation;return this._transation=null,this.push(t),this},clear:function(){return this._transation?this._transation=[]:this.path.setPathData("M 0 0"),this._clear=!0,this},push:function(){var t,e=u.call(arguments);return this._transation?this._transation.push(e):(this._clear?(t="",this._clear=!1):t=this.path.getPathData(),t=t||"",this.path.setPathData(t+o.pathToString(e))),this},moveTo:function(t,e){return this.push("M",u.call(arguments))},moveBy:function(t,e){return this.push("m",u.call(arguments))},lineTo:function(t,e){return this.push("L",u.call(arguments))},lineBy:function(t,e){return this.push("l",u.call(arguments))},arcTo:function(t,e,n,r,i,s,a){return this.push("A",u.call(arguments))},arcBy:function(t,e,n,r,i,s,a){return this.push("a",arguments)},carcTo:function(t,e,n,r,i){return this.push("A",[t,t,0].concat(u.call(arguments,1)))},carcBy:function(t,e,n,r,i){return this.push("a",[t,t,0].concat(u.call(arguments,1)))},bezierTo:function(t,e,n,r,i,s){return this.push("C",u.call(arguments))},bezierBy:function(t,e,n,r,i,s){return this.push("c",u.call(arguments))},close:function(){return this.push("z")}}));return i("Path",{base:s,constructor:function(t){this.callBase("path"),t&&this.setPathData(t),this.node.setAttribute("fill",a.defaults.fill),this.node.setAttribute("stroke",a.defaults.stroke)},setPathData:function(t){return t=t||"M0,0",this.pathdata=o.pathToString(t),this.node.setAttribute("d",this.pathdata),this.trigger("shapeupdate",{type:"pathdata"}),this},getPathData:function(){return this.pathdata||""},getDrawer:function(){return new h(this)},isClosed:function(){var t=this.getPathData();return!!~t.indexOf("z")||!!~t.indexOf("Z")}})}},_p[47]={value:function(t,e,n){var r=_p.r(58),i=_p.r(61);_p.r(67);return _p.r(11).createClass("PatternBrush",{base:r,mixins:[i],constructor:function(t){this.callBase("pattern",t),this.node.setAttribute("patternUnits","userSpaceOnUse")},setX:function(t){return this.x=t,this.node.setAttribute("x",t),this},setY:function(t){return this.y=t,this.node.setAttribute("y",t),this},setWidth:function(t){return this.width=t,this.node.setAttribute("width",t),this},setHeight:function(t){return this.height=t,this.node.setAttribute("height",t),this},getWidth:function(){return this.width},getHeight:function(){return this.height}})}},_p[48]={value:function(t,e,n){var r=_p.r(28);return _p.r(11).createClass("Pen",{constructor:function(t,e){this.brush=t,this.width=e||1,this.linecap=null,this.linejoin=null,this.dashArray=null,this.opacity=1},getBrush:function(){return this.brush},setBrush:function(t){return this.brush=t,this},setColor:function(t){return this.setBrush(t)},getColor:function(){return this.brush instanceof r?this.brush:null},getWidth:function(){return this.width},setWidth:function(t){return this.width=t,this},getOpacity:function(){return this.opacity},setOpacity:function(t){this.opacity=t},getLineCap:function(){return this.linecap},setLineCap:function(t){return this.linecap=t,this},getLineJoin:function(){return this.linejoin},setLineJoin:function(t){return this.linejoin=t,this},getDashArray:function(){return this.dashArray},setDashArray:function(t){return this.dashArray=t,this},stroke:function(t){var e=t.node;e.setAttribute("stroke",this.brush.toString()),e.setAttribute("stroke-width",this.getWidth()),this.getOpacity()<1&&e.setAttribute("stroke-opacity",this.getOpacity()),this.getLineCap()&&e.setAttribute("stroke-linecap",this.getLineCap()),this.getLineJoin()&&e.setAttribute("stroke-linejoin",this.getLineJoin()),this.getDashArray()&&e.setAttribute("stroke-dasharray",this.getDashArray())}})}},_p[49]={value:function(t,e,n){return _p.r(11).createClass({base:_p.r(68),constructor:function(t,e,n){this.callBase([0,t],e,n)},getRadius:function(){return this.getSectionArray()[1]},setRadius:function(t){this.setSectionArray([0,t])}})}},_p[50]={value:function(t,e,n){var r=_p.r(11).createClass("Point",{constructor:function(t,e){this.x=t||0,this.y=e||0},offset:function(t,e){return 1==arguments.length&&(e=t.y,t=t.x),new r(this.x+t,this.y+e)},valueOf:function(){return[this.x,this.y]},toString:function(){return this.valueOf().join(" ")},spof:function(){return new r(.5+(0|this.x),.5+(0|this.y))},round:function(){return new r(0|this.x,0|this.y)},isOrigin:function(){return 0===this.x&&0===this.y}});return r.fromPolar=function(t,e,n){return"rad"!=n&&(e=e/180*Math.PI),new r(t*Math.cos(e),t*Math.sin(e))},r.parse=function(t){return t?t instanceof r?t:"string"==typeof t?r.parse(t.split(/\s*[\s,]\s*/)):"0"in t&&"1"in t?new r(t[0],t[1]):void 0:new r},r}},_p[51]={value:function(t,e,n){return _p.r(11).createClass("PointContainer",{base:_p.r(29),constructor:function(){this.callBase()},addPoint:function(t,e){return this.addItem.apply(this,arguments)},prependPoint:function(){return this.prependItem.apply(this,arguments)},appendPoint:function(){return this.appendItem.apply(this,arguments)},removePoint:function(t){return this.removeItem.apply(this,arguments)},addPoints:function(){return this.addItems.apply(this,arguments)},setPoints:function(){return this.setItems.apply(this,arguments)},getPoint:function(){return this.getItem.apply(this,arguments)},getPoints:function(){return this.getItems.apply(this,arguments)},getFirstPoint:function(){return this.getFirstItem.apply(this,arguments)},getLastPoint:function(){return this.getLastItem.apply(this,arguments)}})}},_p[52]={value:function(t,e,n){_p.r(12);return _p.r(11).createClass("Poly",{base:_p.r(46),mixins:[_p.r(51)],constructor:function(t,e){this.callBase(),this.closeable=!!e,this.setPoints(t||[]),this.changeable=!0,this.update()},onContainerChanged:function(){this.changeable&&this.update()},update:function(){var t=this.getDrawer(),e=this.getPoints();if(t.clear(),!e.length)return this;t.moveTo(e[0]);for(var n,r=1,i=e.length;r<i;r++)n=e[r],t.lineTo(n);return this.closeable&&2<e.length&&t.close(),this}})}},_p[53]={value:function(t,e,n){return _p.r(11).createClass("Polygon",{base:_p.r(52),constructor:function(t){this.callBase(t,!0)}})}},_p[54]={value:function(t,e,n){return _p.r(11).createClass("Polyline",{base:_p.r(52),constructor:function(t){this.callBase(t)}})}},_p[55]={value:function(t,e,n){var r=_p.r(35);return _p.r(11).createClass("RadialGradientBrush",{base:r,constructor:function(t){this.callBase("radialGradient",t),this.setCenter(.5,.5),this.setFocal(.5,.5),this.setRadius(.5)},setCenter:function(t,e){return this.node.setAttribute("cx",t),this.node.setAttribute("cy",e),this},getCenter:function(){return{x:+this.node.getAttribute("cx"),y:+this.node.getAttribute("cy")}},setFocal:function(t,e){return this.node.setAttribute("fx",t),this.node.setAttribute("fy",e),this},getFocal:function(){return{x:+this.node.getAttribute("fx"),y:+this.node.getAttribute("fy")}},setRadius:function(t){return this.node.setAttribute("r",t),this},getRadius:function(){return+this.node.getAttribute("r")}})}},_p[56]={value:function(t,e,n){var s={},r=_p.r(12),i=_p.r(50),a=_p.r(25);return r.extend(s,{formatRadius:function(t,e,n){var r=Math.floor(Math.min(t/2,e/2));return Math.min(r,n)}}),_p.r(11).createClass("Rect",{base:_p.r(46),constructor:function(t,e,n,r,i){this.callBase(),this.x=n||0,this.y=r||0,this.width=t||0,this.height=e||0,this.radius=s.formatRadius(this.width,this.height,i||0),this.update()},update:function(){var t=this.x,e=this.y,n=this.width,r=this.height,i=this.radius,s=this.getDrawer().redraw();return i?(n-=2*i,r-=2*i,s.push("M",t+i,e),s.push("h",n),s.push("a",i,i,0,0,1,i,i),s.push("v",r),s.push("a",i,i,0,0,1,-i,i),s.push("h",-n),s.push("a",i,i,0,0,1,-i,-i),s.push("v",-r),s.push("a",i,i,0,0,1,i,-i)):(s.push("M",t,e),s.push("h",n),s.push("v",r),s.push("h",-n)),s.push("z"),s.done(),this},setWidth:function(t){return this.width=t,this.update()},setHeight:function(t){return this.height=t,this.update()},setSize:function(t,e){return this.width=t,this.height=e,this.update()},setBox:function(t){return this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height,this.update()},getBox:function(){return new a(this.x,this.y,this.width,this.height)},getRadius:function(){return this.radius},setRadius:function(t){return this.radius=s.formatRadius(this.width,this.height,t||0),this.update()},getPosition:function(){return new i(this.x,this.y)},setPosition:function(t,e){if(1==arguments.length){var n=i.parse(t);e=n.y,t=n.x}return this.x=t,this.y=e,this.update()},getWidth:function(){return this.width},getHeight:function(){return this.height},getPositionX:function(){return this.x},getPositionY:function(){return this.y},setPositionX:function(t){return this.x=t,this.update()},setPositionY:function(t){return this.y=t,this.update()}})}},_p[57]={value:function(t,e,n){var s=_p.r(50);return _p.r(11).createClass("RegularPolygon",{base:_p.r(46),constructor:function(t,e,n,r){this.callBase(),this.radius=e||0,this.side=Math.max(t||3,3),2<arguments.length&&3==arguments.length&&(r=n.y,n=n.x),this.center=new s(n,r),this.draw()},getSide:function(){return this.side},setSide:function(t){return this.side=t,this.draw()},getRadius:function(){return this.radius},setRadius:function(t){return this.radius=t,this.draw()},draw:function(){var t,e=this.radius,n=this.side,r=2*Math.PI/n,i=this.getDrawer();for(i.clear(),i.moveTo(s.fromPolar(e,Math.PI/2,"rad").offset(this.center)),t=0;t<=n;t++)i.lineTo(s.fromPolar(e,r*t+Math.PI/2,"rad").offset(this.center));return i.close(),this}})}},_p[58]={value:function(t,e,n){var r=_p.r(67);return _p.r(11).createClass("Resource",{constructor:function(t,e){this.callBase(),this.node=r.createNode(t),e&&e.addResource(this)},toString:function(){return"url(#"+this.node.id+")"}})}},_p[59]={value:function(t,e,n){return _p.r(11).createClass({base:_p.r(68),constructor:function(t,e){this.callBase([t,e],360,0)},getInnerRadius:function(){return this.getSectionArray()[0]},getOuterRadius:function(){return this.getSectionArray()[1]},setInnerRadius:function(t){this.setSectionArray([t,this.getOuterRadius()])},setOuterRadius:function(t){this.setSectionArray([this.getInnerRadius(),t])}})}},_p[60]={value:function(t,e,n){var r=_p.r(67),i=_p.r(12),s=_p.r(33),a=_p.r(66),o=_p.r(31),u=_p.r(43),h=(_p.r(48),Array.prototype.slice),c=_p.r(25);return _p.r(11).createClass("Shape",{mixins:[s,a,o],constructor:function(t){this.node=r.createNode(t),(this.node.shape=this).transform={translate:null,rotate:null,scale:null,matrix:null},this.callMixin()},getId:function(){return this.node.id},setId:function(t){return this.node.id=t,this},getNode:function(){return this.node},getBoundaryBox:function(){var e;try{e=this.node.getBBox()}catch(t){e={x:this.node.clientLeft,y:this.node.clientTop,width:this.node.clientWidth,height:this.node.clientHeight}}return new c(e)},getRenderBox:function(t){var e=this.getBoundaryBox();return this.getTransform(t).transformBox(e)},getWidth:function(){return this.getRenderBox().width},getHeight:function(){return this.getRenderBox().height},getSize:function(){var t=this.getRenderBox();return delete t.x,delete t.y,t},setOpacity:function(t){return this.node.setAttribute("opacity",t),this},getOpacity:function(){var t=this.node.getAttribute("opacity");return t?+t:1},setVisible:function(t){return t?this.node.removeAttribute("display"):this.node.setAttribute("display","none"),this},getVisible:function(){this.node.getAttribute("display")},hasAncestor:function(t){for(var e=this.container;e;){if(e===t)return!0;e=e.container}return!1},getTransform:function(t){return u.getCTM(this,t)},clearTransform:function(){return this.node.removeAttribute("transform"),this.transform={translate:null,rotate:null,scale:null,matrix:null},this.trigger("shapeupdate",{type:"transform"}),this},_applyTransform:function(){var t=this.transform,e=[];return t.translate&&e.push(["translate(",t.translate,")"]),t.rotate&&e.push(["rotate(",t.rotate,")"]),t.scale&&e.push(["scale(",t.scale,")"]),t.matrix&&e.push(["matrix(",t.matrix,")"]),this.node.setAttribute("transform",i.flatten(e).join(" ")),this},setMatrix:function(t){return this.transform.matrix=t,this._applyTransform()},setTranslate:function(t){return this.transform.translate=null!==t&&h.call(arguments)||null,this._applyTransform()},setRotate:function(t){return this.transform.rotate=null!==t&&h.call(arguments)||null,this._applyTransform()},setScale:function(t){return this.transform.scale=null!==t&&h.call(arguments)||null,this._applyTransform()},translate:function(t,e){var n=this.transform.matrix||new u;return void 0===e&&(e=0),this.transform.matrix=n.translate(t,e),this._applyTransform()},rotate:function(t){var e=this.transform.matrix||new u;return this.transform.matrix=e.rotate(t),this._applyTransform()},scale:function(t,e){var n=this.transform.matrix||new u;return void 0===e&&(e=t),this.transform.matrix=n.scale(t,e),this._applyTransform()},skew:function(t,e){var n=this.transform.matrix||new u;return void 0===e&&(e=t),this.transform.matrix=n.skew(t,e),this._applyTransform()},stroke:function(t,e){return t&&t.stroke?t.stroke(this):t?(this.node.setAttribute("stroke",t.toString()),e&&this.node.setAttribute("stroke-width",e)):null===t&&this.node.removeAttribute("stroe"),this},fill:function(t){return t&&this.node.setAttribute("fill",t.toString()),null===t&&this.node.removeAttribute("fill"),this},setAttr:function(t,e){var n=this;return i.isObject(t)&&i.each(t,function(t,e){n.setAttr(e,t)}),null==e||""===e?this.node.removeAttribute(t):this.node.setAttribute(t,e),this},getAttr:function(t){return this.node.getAttribute(t)}})}},_p[61]={value:function(t,e,n){var r=_p.r(29),i=_p.r(12),s=_p.r(11).createClass("ShapeContainer",{base:r,isShapeContainer:!0,handleAdd:function(t,e){var n=this.getShapeNode();n.insertBefore(t.node,n.childNodes[e]||null),t.trigger("add",{container:this}),t.notifyTreeModification&&t.notifyTreeModification("treeadd",this)},handleRemove:function(t,e){this.getShapeNode().removeChild(t.node),t.trigger("remove",{container:this}),t.notifyTreeModification&&t.notifyTreeModification("treeremove",this)},notifyTreeModification:function(n,r){this.eachItem(function(t,e){e.notifyTreeModification&&e.notifyTreeModification(n,r),e.trigger(n,{container:r})})},getShape:function(t){return this.getItem(t)},addShape:function(t,e){return this.addItem(t,e)},put:function(t){return this.addShape(t),t},appendShape:function(t){return this.addShape(t)},prependShape:function(t){return this.addShape(t,0)},replaceShape:function(t,e){var n=this.indexOf(e);if(-1!==n)return this.removeShape(n),this.addShape(t,n),this},addShapeBefore:function(t,e){var n=this.indexOf(e);return this.addShape(t,n)},addShapeAfter:function(t,e){var n=this.indexOf(e);return this.addShape(t,-1===n?void 0:n+1)},addShapes:function(t){return this.addItems(t)},removeShape:function(t){return this.removeItem(t)},getShapes:function(){return this.getItems()},getShapesByType:function(n){var r=[];return function e(t){n.toLowerCase()==t.getType().toLowerCase()&&r.push(t),t.isShapeContainer&&i.each(t.getShapes(),function(t){e(t)})}(this),r},getShapeById:function(t){return this.getShapeNode().getElementById(t).shape},arrangeShape:function(t,e){return this.removeShape(t).addShape(t,e)},getShapeNode:function(){return this.shapeNode||this.node}}),a=_p.r(60);return _p.r(11).extendClass(a,{bringTo:function(t){return this.container.arrangeShape(this,t),this},bringFront:function(){return this.bringTo(this.container.indexOf(this)+1)},bringBack:function(){return this.bringTo(this.container.indexOf(this)-1)},bringTop:function(){return this.container.removeShape(this).addShape(this),this},bringRear:function(){return this.bringTo(0)},bringRefer:function(t,e){return t.container&&(this.remove&&this.remove(),t.container.addShape(this,t.container.indexOf(t)+(e||0))),this},bringAbove:function(t){return this.bringRefer(t)},bringBelow:function(t){return this.bringRefer(t,1)},replaceBy:function(t){return this.container&&(t.bringAbove(this),this.remove()),this}}),s}},_p[62]={value:function(t,e,n){var o=_p.r(43),r=_p.r(12),u=_p.r(50);return _p.r(11).createClass("ShapeEvent",{constructor:function(t){var e=null;r.isObject(t.target)?r.extend(this,t):(this.type=t.type,(e=t.target).correspondingUseElement&&(e=e.correspondingUseElement),this.originEvent=t,this.targetShape=e.shape||e.paper||t.currentTarget&&(t.currentTarget.shape||t.currentTarget.paper),t._kityParam&&r.extend(this,t._kityParam))},preventDefault:function(){var t=this.originEvent;return!t||(t.preventDefault?(t.preventDefault(),t.cancelable):!(t.returnValue=!1))},getPosition:function(t,e){if(!this.originEvent)return null;var n=this.originEvent.touches?this.originEvent.touches[e||0]:this.originEvent,r=this.targetShape,i=r.shapeNode||r.node,s=new u(n&&n.clientX||0,n&&n.clientY||0),a=o.transformPoint(s,i.getScreenCTM().inverse());return o.getCTM(r,t||"view").transformPoint(a)},stopPropagation:function(){var t=this.originEvent;if(!t)return!0;t.stopPropagation?t.stopPropagation():t.cancelBubble=!1}})}},_p[63]={value:function(t,e,n){return _p.r(11).createClass("ShapePoint",{base:_p.r(50),constructor:function(t,e){this.callBase(t,e)},setX:function(t){return this.setPoint(t,this.y)},setY:function(t){return this.setPoint(this.x,t)},setPoint:function(t,e){return this.x=t,this.y=e,this.update(),this},getPoint:function(){return this},update:function(){return this.container&&this.container.update&&this.container.update(),this}})}},_p[64]={value:{COLOR_STANDARD:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00"},EXTEND_STANDARD:{}}},_p[65]={value:function(t,e,n){var h={3:.2,5:.38196601125,6:.57735026919,8:.541196100146,10:.726542528005,12:.707106781187},c=_p.r(50);return _p.r(11).createClass("Star",{base:_p.r(46),constructor:function(t,e,n,r,i){this.callBase(),this.vertex=t||3,this.radius=e||0,this.shrink=n,this.offset=r||new c(0,0),this.angleOffset=i||0,this.draw()},getVertex:function(){return this.vertex},setVertex:function(t){return this.vertex=t,this.draw()},getRadius:function(){return this.radius},setRadius:function(t){return this.radius=t,this.draw()},getShrink:function(){return this.shrink},setShrink:function(t){return this.shrink=t,this.draw()},getOffset:function(){return this.offset},setOffset:function(t){return this.offset=t,this.draw()},getAngleOffset:function(){return this.angleOffset},setAngleOffset:function(t){return this.angleOffset=t,this.draw()},draw:function(){var t,e,n=this.radius,r=this.radius*(this.shrink||h[this.vertex]||.5),i=this.vertex,s=this.offset,a=180/i,o=this.angleOffset,u=this.getDrawer();for(u.clear(),u.moveTo(c.fromPolar(r,90)),t=1;t<=2*i;t++)e=90+a*t,t%2?u.lineTo(c.fromPolar(n,e+o).offset(s)):u.lineTo(c.fromPolar(r,e));u.close()}})}},_p[66]={value:function(t,e,n){var r=_p.r(11).createClass("ClassList",{constructor:function(t){this._node=t,this._list=t.className.toString().split(" ")},_update:function(){this._node.className=this._list.join(" ")},add:function(t){this._list.push(t),this._update()},remove:function(t){var e=this._list.indexOf(t);~e&&this._list.splice(e,1),this._update()},contains:function(t){return!!~this._list.indexOf(t)}});function i(t){return t.classList||(t.classList=new r(t)),t.classList}return _p.r(11).createClass("Styled",{addClass:function(t){return i(this.node).add(t),this},removeClass:function(t){return i(this.node).remove(t),this},hasClass:function(t){return i(this.node).contains(t)},setStyle:function(t){if(2==arguments.length)return this.node.style[t]=arguments[1],this;for(var e in t)t.hasOwnProperty(e)&&(this.node.style[e]=t[e]);return this}})}},_p[67]={value:function(t,e,n){var r=document,i=0,s={createNode:function(t){var e=r.createElementNS(s.ns,t);return e.id="kity_"+t+"_"+i++,e},defaults:{stroke:"none",fill:"none"},xlink:"http://www.w3.org/1999/xlink",ns:"http://www.w3.org/2000/svg"};return s}},_p[68]={value:function(t,e,n){var u=_p.r(50);return _p.r(11).createClass("Sweep",{base:_p.r(46),constructor:function(t,e,n){this.callBase(),this.sectionArray=t||[],this.angle=e||0,this.angleOffset=n||0,this.draw()},getSectionArray:function(){return this.sectionArray},setSectionArray:function(t){return this.sectionArray=t,this.draw()},getAngle:function(){return this.angle},setAngle:function(t){return this.angle=t,this.draw()},getAngleOffset:function(){return this.angleOffset},setAngleOffset:function(t){return this.angleOffset=t,this.draw()},draw:function(){var t,e=this.sectionArray;for(t=0;t<e.length;t+=2)this.drawSection(e[t],e[t+1]);return this},drawSection:function(t,e){var n=this.angle&&(this.angle%360?this.angle%360:360),r=this.angleOffset,i=r+n/2,s=r+n,a=n<0?0:1,o=this.getDrawer();o.redraw(),0!==n&&(o.moveTo(u.fromPolar(t,r)),o.lineTo(u.fromPolar(e,r)),e&&(o.carcTo(e,0,a,u.fromPolar(e,i)),o.carcTo(e,0,a,u.fromPolar(e,s))),o.lineTo(u.fromPolar(t,s)),t&&(o.carcTo(t,0,a,u.fromPolar(t,i)),o.carcTo(t,0,a,u.fromPolar(t,r))),o.close()),o.done()}})}},_p[69]={value:function(t,e,n){var r=_p.r(70),i=_p.r(61),s=_p.r(67),a=_p.r(12),o={};function u(t){var e=t._cachedFontHash;if(o[e])return o[e];var n=t.getContent();t.setContent("百度Fex");var r=t.getBoundaryBox(),i=t.getY();if(!r.height)return{top:0,bottom:0,middle:0};var s=i-r.y+ +t.node.getAttribute("dy"),a=s-r.height;return t.setContent(n),o[e]={top:s,bottom:a,middle:(s+a)/2}}return _p.r(11).createClass("Text",{base:r,mixins:[i],constructor:function(t){this.callBase("text"),void 0!==t&&this.setContent(t),this._buildFontHash()},fixPosition:function(){this.__fixedPosition||this.setVerticalAlign(this.getVerticalAlign())},_buildFontHash:function(){var t=window.getComputedStyle(this.node);this._cachedFontHash=[t.fontFamily,t.fontSize,t.fontStretch,t.fontStyle,t.fontVariant,t.fontWeight].join("-")},_fontChanged:function(t){var e=this._lastFont,n=a.extend({},e,t);if(!e)return this._lastFont=t,!0;var r=e.family!=n.family||e.size!=n.size||e.style!=n.style||e.weight!=n.weight;return this._lastFont=n,r},setX:function(t){return this.node.setAttribute("x",t),this},setPosition:function(t,e){return this.setX(t).setY(e)},setY:function(t){return this.node.setAttribute("y",t),this},getX:function(){return+this.node.getAttribute("x")||0},getY:function(){return+this.node.getAttribute("y")||0},setFont:function(t){return this.callBase(t),this._fontChanged(t)&&(this._buildFontHash(),this.setVerticalAlign(this.getVerticalAlign())),this},setTextAnchor:function(t){return this.node.setAttribute("text-anchor",t),this},getTextAnchor:function(){return this.node.getAttribute("text-anchor")||"start"},setVerticalAlign:function(e){return this.whenPaperReady(function(){var t;switch(e){case"top":t=u(this).top;break;case"bottom":t=u(this).bottom;break;case"middle":t=u(this).middle;break;default:t=0}t&&(this.__fixedPosition=!0),this.node.setAttribute("dy",t)}),this.verticalAlign=e,this},getVerticalAlign:function(){return this.verticalAlign||"baseline"},setStartOffset:function(t){this.shapeNode!=this.node&&this.shapeNode.setAttribute("startOffset",100*t+"%")},addSpan:function(t){return this.addShape(t),this},setPath:function(t){var e=this.shapeNode;if(this.shapeNode==this.node){for(e=this.shapeNode=s.createNode("textPath");this.node.firstChild;)this.shapeNode.appendChild(this.node.firstChild);this.node.appendChild(e)}return e.setAttributeNS(s.xlink,"xlink:href","#"+t.node.id),this.setTextAnchor(this.getTextAnchor()),this}})}},_p[70]={value:function(t,e,n){var r=_p.r(60);return _p.r(11).createClass("TextContent",{base:r,constructor:function(t){this.callBase(t),this.shapeNode=this.shapeNode||this.node,this.shapeNode.setAttribute("text-rendering","geometricPrecision")},clearContent:function(){for(;this.shapeNode.firstChild;)this.shapeNode.removeChild(this.shapeNode.firstChild);return this},setContent:function(t){return this.shapeNode.textContent=t,this},getContent:function(){return this.shapeNode.textContent},appendContent:function(t){return this.shapeNode.textContent+=t,this},setSize:function(t){return this.setFontSize(t)},setFontSize:function(t){return this.setFont({size:t})},setFontFamily:function(t){return this.setFont({family:t})},setFontBold:function(t){return this.setFont({weight:t?"bold":"normal"})},setFontItalic:function(t){return this.setFont({style:t?"italic":"normal"})},setFont:function(e){var n=this.node;return["family","size","weight","style"].forEach(function(t){null===e[t]?n.removeAttribute("font-"+t):e[t]&&n.setAttribute("font-"+t,e[t])}),this},getExtentOfChar:function(t){return this.node.getExtentOfChar(t)},getRotationOfChar:function(t){return this.node.getRotationOfChar(t)},getCharNumAtPosition:function(t,e){return this.node.getCharNumAtPosition(this.node.viewportElement.createSVGPoint(t,e))}})}},_p[71]={value:function(t,e,n){var r=_p.r(70),i=_p.r(66);return _p.r(11).createClass("TextSpan",{base:r,mixins:[i],constructor:function(t){this.callBase("tspan"),this.setContent(t)}})}},_p[72]={value:function(t,e,n){var r=_p.r(67),i=_p.r(11),s=i.createClass("Use",{base:_p.r(60),constructor:function(t){this.callBase("use"),this.ref(t)},ref:function(t){if(!t)return this.node.removeAttributeNS(r.xlink,"xlink:href"),this;var e=t.getId();return e&&this.node.setAttributeNS(r.xlink,"xlink:href","#"+e),"none"===t.node.getAttribute("fill")&&t.node.removeAttribute("fill"),"none"===t.node.getAttribute("stroke")&&t.node.removeAttribute("stroke"),this}}),a=_p.r(60);return i.extendClass(a,{use:function(){return new s(this)}}),s}},_p[73]={value:function(t,e,n){var r=_p.r(50),i=_p.r(43),s=_p.r(11).createClass("Vector",{base:r,constructor:function(t,e){this.callBase(t,e)},square:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.square())},add:function(t){return new s(this.x+t.x,this.y+t.y)},minus:function(t){return new s(this.x-t.x,this.y-t.y)},dot:function(t){return this.x*t.x+this.y*t.y},project:function(t){return t.multipy(this.dot(t)/t.square())},normalize:function(t){return void 0===t&&(t=1),this.multipy(t/this.length())},multipy:function(t){return new s(this.x*t,this.y*t)},rotate:function(t,e){"rad"==e&&(t=t/Math.PI*180);var n=(new i).rotate(t).transformPoint(this);return new s(n.x,n.y)},vertical:function(){return new s(this.y,-this.x)},reverse:function(){return this.multipy(-1)},getAngle:function(){var t=this.length();if(0===t)return 0;var e=Math.acos(this.x/t);return 180*(0<this.y?1:-1)*e/Math.PI}});return s.fromPoints=function(t,e){return new s(e.x-t.x,e.y-t.y)},s.fromPolar=function(){var t=r.fromPolar.apply(r,arguments);return new s(t.x,t.y)},_p.r(11).extendClass(r,{asVector:function(){return new s(this.x,this.y)}}),s}},_p[74]={value:function(t,e,n){var r=_p.r(61),i=_p.r(75);return _p.r(11).createClass("View",{mixins:[r,i],base:_p.r(74),constructor:function(){this.callBase("view")}})}},_p[75]={value:function(t,e,n){return _p.r(11).createClass("ViewBox",{getViewBox:function(){var t=this.node.getAttribute("viewBox");return null===t?{x:0,y:0,width:this.node.clientWidth||this.node.parentNode.clientWidth,height:this.node.clientHeight||this.node.parentNode.clientHeight}:{x:+(t=t.split(" "))[0],y:+t[1],width:+t[2],height:+t[3]}},setViewBox:function(t,e,n,r){return this.node.setAttribute("viewBox",[t,e,n,r].join(" ")),this}})}},_p[76]={value:function(t,e,n){var r={},i=_p.r(12);return r.version="2.0.0",i.extend(r,{createClass:_p.r(11).createClass,extendClass:_p.r(11).extendClass,Utils:i,Browser:_p.r(10),Box:_p.r(25),Bezier:_p.r(23),BezierPoint:_p.r(24),Circle:_p.r(26),Clip:_p.r(27),Color:_p.r(28),Container:_p.r(29),Curve:_p.r(30),Ellipse:_p.r(32),Group:_p.r(36),Gradient:_p.r(35),HyperLink:_p.r(37),Image:_p.r(38),Line:_p.r(39),LinearGradient:_p.r(40),Mask:_p.r(42),Matrix:_p.r(43),Marker:_p.r(41),Palette:_p.r(44),Paper:_p.r(45),Path:_p.r(46),Pattern:_p.r(47),Pen:_p.r(48),Point:_p.r(50),PointContainer:_p.r(51),Polygon:_p.r(53),Polyline:_p.r(54),Pie:_p.r(49),RadialGradient:_p.r(55),Resource:_p.r(58),Rect:_p.r(56),RegularPolygon:_p.r(57),Ring:_p.r(59),Shape:_p.r(60),ShapePoint:_p.r(63),ShapeContainer:_p.r(61),Sweep:_p.r(68),Star:_p.r(65),Text:_p.r(69),TextSpan:_p.r(71),Use:_p.r(72),Vector:_p.r(73),g:_p.r(34),Animator:_p.r(0),Easing:_p.r(1),OpacityAnimator:_p.r(4),RotateAnimator:_p.r(6),ScaleAnimator:_p.r(7),Timeline:_p.r(8),TranslateAnimator:_p.r(9),PathAnimator:_p.r(5),MotionAnimator:_p.r(3),requestFrame:_p.r(2).requestFrame,releaseFrame:_p.r(2).releaseFrame,Filter:_p.r(20),GaussianblurFilter:_p.r(21),ProjectionFilter:_p.r(22),ColorMatrixEffect:_p.r(13),CompositeEffect:_p.r(14),ConvolveMatrixEffect:_p.r(15),Effect:_p.r(16),GaussianblurEffect:_p.r(17),OffsetEffect:_p.r(18)}),window.kity=r}};var moduleMapping={kity:76};function use(t){_p.r([moduleMapping[t]])}use("kity")}();
\ No newline at end of file
UE.I18N.en={labelMap:{anchor:"Anchor",undo:"Undo",redo:"Redo",bold:"Bold",indent:"Indent",snapscreen:"SnapScreen",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",subscript:"SubScript",fontborder:"text border",superscript:"SuperScript",formatmatch:"Format Match",source:"Source",blockquote:"BlockQuote",pasteplain:"PastePlain",selectall:"SelectAll",print:"Print",preview:"Preview",horizontal:"Horizontal",gapfilling:"Gapfilling",removeformat:"RemoveFormat",time:"Time",date:"Date",unlink:"Unlink",insertrow:"InsertRow",insertcol:"InsertCol",mergeright:"MergeRight",mergedown:"MergeDown",deleterow:"DeleteRow",deletecol:"DeleteCol",splittorows:"SplitToRows",insertcode:"insert code",splittocols:"SplitToCols",splittocells:"SplitToCells",deletecaption:"DeleteCaption",inserttitle:"InsertTitle",mergecells:"MergeCells",deletetable:"DeleteTable",cleardoc:"Clear",insertparagraphbeforetable:"InsertParagraphBeforeTable",fontfamily:"FontFamily",fontsize:"FontSize",paragraph:"Paragraph",simpleupload:"Single Image",insertimage:"Multi Image",edittable:"Edit Table",edittd:"Edit Td",link:"Link",emotion:"Emotion",spechars:"Spechars",searchreplace:"SearchReplace",map:"BaiduMap",gmap:"GoogleMap",insertvideo:"Video",help:"Help",justifyleft:"JustifyLeft",justifyright:"JustifyRight",justifycenter:"JustifyCenter",justifyjustify:"Justify",forecolor:"FontColor",backcolor:"BackColor",insertorderedlist:"OL",insertunorderedlist:"UL",fullscreen:"FullScreen",directionalityltr:"EnterFromLeft",directionalityrtl:"EnterFromRight",rowspacingtop:"RowSpacingTop",rowspacingbottom:"RowSpacingBottom",pagebreak:"PageBreak",insertframe:"Iframe",imagenone:"Default",imageleft:"ImageLeft",imageright:"ImageRight",attachment:"Attachment",imagecenter:"ImageCenter",wordimage:"WordImage",lineheight:"LineHeight",edittip:"EditTip",customstyle:"CustomStyle",scrawl:"Scrawl",autotypeset:"AutoTypeset",webapp:"WebAPP",touppercase:"UpperCase",tolowercase:"LowerCase",template:"Template",background:"Background",inserttable:"InsertTable",music:"Music",charts:"charts",drafts:"Load from Drafts"},insertorderedlist:{num:"1,2,3...",num1:"1),2),3)...",num2:"(1),(2),(3)...",cn:"一,二,三....",cn1:"一),二),三)....",cn2:"(一),(二),(三)....",decimal:"1,2,3...","lower-alpha":"a,b,c...","lower-roman":"i,ii,iii...","upper-alpha":"A,B,C...","upper-roman":"I,II,III..."},insertunorderedlist:{circle:"○ Circle",disc:"● Circle dot",square:"■ Rectangle ",dash:"- Dash",dot:"。dot"},paragraph:{p:"Paragraph",h1:"Title 1",h2:"Title 2",h3:"Title 3",h4:"Title 4",h5:"Title 5",h6:"Title 6"},fontfamily:{songti:"Sim Sun",kaiti:"Sim Kai",heiti:"Sim Hei",lishu:"Sim Li",yahei:"Microsoft YaHei",andaleMono:"Andale Mono",arial:"Arial",arialBlack:"Arial Black",comicSansMs:"Comic Sans MS",impact:"Impact",timesNewRoman:"Times New Roman"},customstyle:{tc:"Title center",tl:"Title left",im:"Important",hi:"Highlight"},autoupload:{exceedSizeError:"File Size Exceed",exceedTypeError:"File Type Not Allow",jsonEncodeError:"Server Return Format Error",loading:"loading...",loadError:"load error",errorLoadConfig:"Server config not loaded, upload can not work."},simpleupload:{exceedSizeError:"File Size Exceed",exceedTypeError:"File Type Not Allow",jsonEncodeError:"Server Return Format Error",loading:"loading...",loadError:"load error",errorLoadConfig:"Server config not loaded, upload can not work."},elementPathTip:"Path",wordCountTip:"Word Count",wordCountMsg:"{#count} characters entered,{#leave} left. ",wordOverFlowMsg:'<span style="color:red;">The number of characters has exceeded allowable maximum values, the server may refuse to save!</span>',ok:"OK",cancel:"Cancel",closeDialog:"closeDialog",tableDrag:"You must import the file uiUtils.js before drag! ",autofloatMsg:"The plugin AutoFloat depends on EditorUI!",loadconfigError:"Get server config error.",loadconfigFormatError:"Server config format error.",loadconfigHttpError:"Get server config http error.",snapScreen_plugin:{browserMsg:"Only IE supported!",callBackErrorMsg:"The callback data is wrong,please check the config!",uploadErrorMsg:"Upload error,please check your server environment! "},insertcode:{as3:"ActionScript 3",bash:"Bash/Shell",cpp:"C/C++",css:"CSS",cf:"ColdFusion","c#":"C#",delphi:"Delphi",diff:"Diff",erlang:"Erlang",groovy:"Groovy",html:"HTML",java:"Java",jfx:"JavaFX",js:"JavaScript",pl:"Perl",php:"PHP",plain:"Plain Text",ps:"PowerShell",python:"Python",ruby:"Ruby",scala:"Scala",sql:"SQL",vb:"Visual Basic",xml:"XML"},confirmClear:"Do you confirm to clear the Document?",contextMenu:{delete:"Delete",selectall:"Select all",deletecode:"Delete Code",cleardoc:"Clear Document",confirmclear:"Do you confirm to clear the Document?",unlink:"Unlink",paragraph:"Paragraph",edittable:"Table property",aligncell:"Align cell",aligntable:"Table alignment",tableleft:"Left float",tablecenter:"Center",tableright:"Right float",aligntd:"Cell alignment",edittd:"Cell property",setbordervisible:"set table edge visible",table:"Table",justifyleft:"Justify Left",justifyright:"Justify Right",justifycenter:"Justify Center",justifyjustify:"Default",deletetable:"Delete table",insertparagraphbefore:"InsertedBeforeLine",insertparagraphafter:"InsertedAfterLine",inserttable:"Insert table",insertcaption:"Insert caption",deletecaption:"Delete Caption",inserttitle:"Insert Title",deletetitle:"Delete Title",inserttitlecol:"Insert Title Col",deletetitlecol:"Delete Title Col",averageDiseRow:"AverageDise Row",averageDisCol:"AverageDis Col",deleterow:"Delete row",deletecol:"Delete col",insertrow:"Insert row",insertcol:"Insert col",insertrownext:"Insert Row Next",insertcolnext:"Insert Col Next",mergeright:"Merge right",mergeleft:"Merge left",mergedown:"Merge down",mergecells:"Merge cells",splittocells:"Split to cells",splittocols:"Split to Cols",splittorows:"Split to Rows",tablesort:"Table sorting",enablesort:"Sorting Enable",disablesort:"Sorting Disable",reversecurrent:"Reverse current",orderbyasc:"Order By ASCII",reversebyasc:"Reverse By ASCII",orderbynum:"Order By Num",reversebynum:"Reverse By Num",borderbk:"Border shading",setcolor:"interlaced color",unsetcolor:"Cancel interlacedcolor",setbackground:"Background interlaced",unsetbackground:"Cancel Bk interlaced",redandblue:"Blue and red",threecolorgradient:"Three-color gradient",copy:"Copy(Ctrl + c)",copymsg:"Browser does not support. Please use 'Ctrl + c' instead!",paste:"Paste(Ctrl + v)",pastemsg:"Browser does not support. Please use 'Ctrl + v' instead!"},copymsg:"Browser does not support. Please use 'Ctrl + c' instead!",pastemsg:"Browser does not support. Please use 'Ctrl + v' instead!",anthorMsg:"Link",clearColor:"Clear",standardColor:"Standard color",themeColor:"Theme color",property:"Property",default:"Default",modify:"Modify",justifyleft:"Justify Left",justifyright:"Justify Right",justifycenter:"Justify Center",justify:"Default",clear:"Clear",anchorMsg:"Anchor",delete:"Delete",clickToUpload:"Click to upload",unset:"Language hasn't been set!",t_row:"row",t_col:"col",pasteOpt:"Paste Option",pasteSourceFormat:"Keep Source Formatting",tagFormat:"Keep tag",pasteTextFormat:"Keep Text only",more:"More",autoTypeSet:{mergeLine:"Merge empty line",delLine:"Del empty line",removeFormat:"Remove format",indent:"Indent",alignment:"Alignment",imageFloat:"Image float",removeFontsize:"Remove font size",removeFontFamily:"Remove fontFamily",removeHtml:"Remove redundant HTML code",pasteFilter:"Paste filter",run:"Done",symbol:"Symbol Conversion",bdc2sb:"Full-width to Half-width",tobdc:"Half-width to Full-width"},background:{static:{lang_background_normal:"Normal",lang_background_local:"Online",lang_background_set:"Background Set",lang_background_none:"No Background",lang_background_colored:"Colored Background",lang_background_color:"Color Set",lang_background_netimg:"Net-Image",lang_background_align:"Align Type",lang_background_position:"Position",repeatType:{options:["Center","Repeat-x","Repeat-y","Tile","Custom"]}},noUploadImage:"No pictures has been uploaded!",toggleSelect:"Change the active state by click!\n Image Size: "},insertimage:{static:{lang_tab_remote:"Insert",lang_tab_upload:"Local",lang_tab_online:"Manager",lang_tab_search:"Search",lang_input_url:"Address:",lang_input_size:"Size:",lang_input_width:"Width",lang_input_height:"Height",lang_input_border:"Border:",lang_input_vhspace:"Margins:",lang_input_title:"Title:",lang_input_align:"Image Float Style:",lang_imgLoading:"Loading...",lang_start_upload:"Start Upload",lock:{title:"Lock rate"},searchType:{title:"ImageType",options:["News","Wallpaper","emotions","photo"]},searchTxt:{value:"Enter the search keyword!"},searchBtn:{value:"Search"},searchReset:{value:"Clear"},noneAlign:{title:"None Float"},leftAlign:{title:"Left Float"},rightAlign:{title:"Right Float"},centerAlign:{title:"Center In A Line"}},uploadSelectFile:"Select File",uploadAddFile:"Add File",uploadStart:"Start Upload",uploadPause:"Pause Upload",uploadContinue:"Continue Upload",uploadRetry:"Retry Upload",uploadDelete:"Delete",uploadTurnLeft:"Turn Left",uploadTurnRight:"Turn Right",uploadPreview:"Doing Preview",uploadNoPreview:"Can Not Preview",updateStatusReady:"Selected _ pictures, total _KB.",updateStatusConfirm:"_ uploaded successfully and _ upload failed",updateStatusFinish:"Total _ pictures (_KB), _ uploaded successfully",updateStatusError:" and _ upload failed",errorNotSupport:"WebUploader does not support the browser you are using. Please upgrade your browser or flash player",errorLoadConfig:"Server config not loaded, upload can not work.",errorExceedSize:"File Size Exceed",errorFileType:"File Type Not Allow",errorInterrupt:"File Upload Interrupted",errorUploadRetry:"Upload Error, Please Retry.",errorHttp:"Http Error",errorServerUpload:"Server Result Error.",remoteLockError:"Cannot Lock the Proportion between width and height",numError:"Please enter the correct Num. e.g 123,400",imageUrlError:"The image format may be wrong!",imageLoadError:"Error,please check the network or URL!",searchRemind:"Enter the search keyword!",searchLoading:"Image is loading,please wait...",searchRetry:" Sorry,can't find the image,please try again!"},attachment:{static:{lang_tab_upload:"Upload",lang_tab_online:"Online",lang_start_upload:"Start upload",lang_drop_remind:"You can drop files here, a single maximum of 300 files"},uploadSelectFile:"Select File",uploadAddFile:"Add File",uploadStart:"Start Upload",uploadPause:"Pause Upload",uploadContinue:"Continue Upload",uploadRetry:"Retry Upload",uploadDelete:"Delete",uploadTurnLeft:"Turn Left",uploadTurnRight:"Turn Right",uploadPreview:"Doing Preview",updateStatusReady:"Selected _ files, total _KB.",updateStatusConfirm:"_ uploaded successfully and _ upload failed",updateStatusFinish:"Total _ files (_KB), _ uploaded successfully",updateStatusError:" and _ upload failed",errorNotSupport:"WebUploader does not support the browser you are using. Please upgrade your browser or flash player",errorLoadConfig:"Server config not loaded, upload can not work.",errorExceedSize:"File Size Exceed",errorFileType:"File Type Not Allow",errorInterrupt:"File Upload Interrupted",errorUploadRetry:"Upload Error, Please Retry.",errorHttp:"Http Error",errorServerUpload:"Server Result Error."},insertvideo:{static:{lang_tab_insertV:"Video",lang_tab_searchV:"Search",lang_tab_uploadV:"Upload",lang_video_url:" URL ",lang_video_size:"Video Size",lang_videoW:"Width",lang_videoH:"Height",lang_alignment:"Alignment",videoSearchTxt:{value:"Enter the search keyword!"},videoType:{options:["All","Hot","Entertainment","Funny","Sports","Science","variety"]},videoSearchBtn:{value:"Search in Baidu"},videoSearchReset:{value:"Clear result"},lang_input_fileStatus:" No file uploaded!",startUpload:{style:"background:url(upload.png) no-repeat;"},lang_upload_size:"Video Size",lang_upload_width:"Width",lang_upload_height:"Height",lang_upload_alignment:"Alignment",lang_format_advice:"Recommends mp4 format."},numError:"Please enter the correct Num. e.g 123,400",floatLeft:"Float left",floatRight:"Float right",default:"Default",block:"Display in block",urlError:"The video url format may be wrong!",loading:" &nbsp;The video is loading, please wait…",clickToSelect:"Click to select",goToSource:"Visit source video ",noVideo:" &nbsp; &nbsp;Sorry,can't find the video,please try again!",browseFiles:"Open files",uploadSuccess:"Upload Successful!",delSuccessFile:"Remove from the success of the queue",delFailSaveFile:"Remove the save failed file",statusPrompt:" file(s) uploaded! ",flashVersionError:"The current Flash version is too low, please update FlashPlayer,then try again!",flashLoadingError:"The Flash failed loading! Please check the path or network state",fileUploadReady:"Wait for uploading...",delUploadQueue:"Remove from the uploading queue ",limitPrompt1:"Can not choose more than single",limitPrompt2:"file(s)!Please choose again!",delFailFile:"Remove failure file",fileSizeLimit:"File size exceeds the limit!",emptyFile:"Can not upload an empty file!",fileTypeError:"File type error!",unknownError:"Unknown error!",fileUploading:"Uploading,please wait...",cancelUpload:"Cancel upload",netError:"Network error",failUpload:"Upload failed",serverIOError:"Server IO error!",noAuthority:"No Permission!",fileNumLimit:"Upload limit to the number",failCheck:"Authentication fails, the upload is skipped!",fileCanceling:"Cancel, please wait...",stopUploading:"Upload has stopped...",uploadSelectFile:"Select File",uploadAddFile:"Add File",uploadStart:"Start Upload",uploadPause:"Pause Upload",uploadContinue:"Continue Upload",uploadRetry:"Retry Upload",uploadDelete:"Delete",uploadTurnLeft:"Turn Left",uploadTurnRight:"Turn Right",uploadPreview:"Doing Preview",updateStatusReady:"Selected _ files, total _KB.",updateStatusConfirm:"_ uploaded successfully and _ upload failed",updateStatusFinish:"Total _ files (_KB), _ uploaded successfully",updateStatusError:" and _ upload failed",errorNotSupport:"WebUploader does not support the browser you are using. Please upgrade your browser or flash player",errorLoadConfig:"Server config not loaded, upload can not work.",errorExceedSize:"File Size Exceed",errorFileType:"File Type Not Allow",errorInterrupt:"File Upload Interrupted",errorUploadRetry:"Upload Error, Please Retry.",errorHttp:"Http Error",errorServerUpload:"Server Result Error."},webapp:{tip1:"This function provided by Baidu APP,please apply for baidu APPKey webmaster first!",tip2:"And then open the file ueditor.config.js to set it! ",applyFor:"APPLY FOR",anthorApi:"Baidu API"},template:{static:{lang_template_bkcolor:"Background Color",lang_template_clear:"Keep Content",lang_template_select:"Select Template"},blank:"Blank",blog:"Blog",resume:"Resume",richText:"Rich Text",scrPapers:"Scientific Papers"},scrawl:{static:{lang_input_previousStep:"Previous",lang_input_nextsStep:"Next",lang_input_clear:"Clear",lang_input_addPic:"AddImage",lang_input_ScalePic:"ScaleImage",lang_input_removePic:"RemoveImage",J_imgTxt:{title:"Add background image"}},noScarwl:"No paint, a white paper...",scrawlUpLoading:"Image is uploading, please wait...",continueBtn:"Try again",imageError:"Image failed to load!",backgroundUploading:"Image is uploading,please wait..."},music:{static:{lang_input_tips:"Input singer/song/album, search you interested in music!",J_searchBtn:{value:"Search songs"}},emptyTxt:"Not search to the relevant music results, please change a keyword try.",chapter:"Songs",singer:"Singer",special:"Album",listenTest:"Audition"},anchor:{static:{lang_input_anchorName:"Anchor Name:"}},charts:{static:{lang_data_source:"Data source:",lang_chart_format:"Chart format:",lang_data_align:"Align",lang_chart_align_same:"Consistent with the X-axis Y-axis",lang_chart_align_reverse:"X-axis Y-axis opposite",lang_chart_title:"Title",lang_chart_main_title:"main title:",lang_chart_sub_title:"sub title:",lang_chart_x_title:"X-axis title:",lang_chart_y_title:"Y-axis title:",lang_chart_tip:"Prompt",lang_cahrt_tip_prefix:"prefix:",lang_cahrt_tip_description:"仅饼图有效, 当鼠标移动到饼图中相应的块上时,提示框内的文字的前缀",lang_chart_data_unit:"Unit",lang_chart_data_unit_title:"unit:",lang_chart_data_unit_description:"显示在每个数据点上的数据的单位, 比如: 温度的单位 ℃",lang_chart_type:"Chart type:",lang_prev_btn:"Previous",lang_next_btn:"Next"}},emotion:{static:{lang_input_choice:"Choice",lang_input_Tuzki:"Tuzki",lang_input_lvdouwa:"LvDouWa",lang_input_BOBO:"BOBO",lang_input_babyCat:"BabyCat",lang_input_bubble:"Bubble",lang_input_youa:"YouA"}},gmap:{static:{lang_input_address:"Address:",lang_input_search:"Search",address:{value:"Beijing"}},searchError:"Unable to locate the address!"},help:{static:{lang_input_about:"About",lang_input_shortcuts:"Shortcuts",lang_input_introduction:"UEditor is developed by Baidu Co.ltd. It is lightweight, customizable , focusing on user experience and etc. , UEditor is based on open source BSD license , allowing free use and redistribution.",lang_Txt_shortcuts:"Shortcuts",lang_Txt_func:"Function",lang_Txt_bold:"Bold",lang_Txt_copy:"Copy",lang_Txt_cut:"Cut",lang_Txt_Paste:"Paste",lang_Txt_undo:"Undo",lang_Txt_redo:"Redo",lang_Txt_italic:"Italic",lang_Txt_underline:"Underline",lang_Txt_selectAll:"Select All",lang_Txt_visualEnter:"Submit",lang_Txt_fullscreen:"Fullscreen"}},insertframe:{static:{lang_input_address:"Address:",lang_input_width:"Width:",lang_input_height:"height:",lang_input_isScroll:"Enable scrollbars:",lang_input_frameborder:"Show frame border:",lang_input_alignMode:"Alignment:",align:{title:"Alignment",options:["Default","Left","Right","Center"]}},enterAddress:"Please enter an address!"},link:{static:{lang_input_text:"Text:",lang_input_url:"URL:",lang_input_title:"Title:",lang_input_target:"open in new window:"},validLink:"Supports only effective when a link is selected",httpPrompt:'The hyperlink you enter should start with "http|https|ftp://"!'},map:{static:{lang_city:"City",lang_address:"Address",city:{value:"Beijing"},lang_search:"Search",lang_dynamicmap:"Dynamic map"},cityMsg:"Please enter the city name!",errorMsg:"Can't find the place!"},searchreplace:{static:{lang_tab_search:"Search",lang_tab_replace:"Replace",lang_search1:"Search",lang_search2:"Search",lang_replace:"Replace",lang_searchReg:'Support regular expression ,which starts and ends with a slash ,for example "/expression/"',lang_searchReg1:'Support regular expression ,which starts and ends with a slash ,for example "/expression/"',lang_case_sensitive1:"Case sense",lang_case_sensitive2:"Case sense",nextFindBtn:{value:"Next"},preFindBtn:{value:"Preview"},nextReplaceBtn:{value:"Next"},preReplaceBtn:{value:"Preview"},repalceBtn:{value:"Replace"},repalceAllBtn:{value:"Replace all"}},getEnd:"Has the search to the bottom!",getStart:"Has the search to the top!",countMsg:"Altogether replaced {#count} character(s)!"},snapscreen:{static:{lang_showMsg:"You should install the UEditor screenshots program first!",lang_download:"Download!",lang_step1:"Step1:Download the program and then run it",lang_step2:"Step2:After complete install,try to click the button again"}},spechars:{static:{},tsfh:"Special",lmsz:"Roman",szfh:"Numeral",rwfh:"Japanese",xlzm:"The Greek",ewzm:"Russian",pyzm:"Phonetic",yyyb:"English",zyzf:"Others"},edittable:{static:{lang_tableStyle:"Table style",lang_insertCaption:"Add table header row",lang_insertTitle:"Add table title row",lang_insertTitleCol:"Add table title col",lang_tableSize:"Automatically adjust table size",lang_autoSizeContent:"Adaptive by form text",lang_orderbycontent:"Table of contents sortable",lang_autoSizePage:"Page width adaptive",lang_example:"Example",lang_borderStyle:"Table Border",lang_color:"Color:"},captionName:"Caption",titleName:"Title",cellsName:"text",errorMsg:"There are merged cells, can not sort."},edittip:{static:{lang_delRow:"Delete entire row",lang_delCol:"Delete entire col"}},edittd:{static:{lang_tdBkColor:"Background Color:"}},formula:{static:{}},wordimage:{static:{lang_resave:"The re-save step",uploadBtn:{src:"upload.png",alt:"Upload"},clipboard:{style:"background: url(copy.png) -153px -1px no-repeat;"},lang_step:" 1. Click top button to copy the url and then open the dialog to paste it. 2. Open after choose photos uploaded process."},fileType:"Image",flashError:"Flash initialization failed!",netError:"Network error! Please try again!",copySuccess:"URL has been copied!",flashI18n:{lang:encodeURI('{"UploadingState":"totalNum: ${a},uploadComplete: ${b}", "BeforeUpload":"waitingNum: ${a}", "ExceedSize":"Size exceed${a}", "ErrorInPreview":"Preview failed", "DefaultDescription":"Description", "LoadingImage":"Loading..."}'),uploadingTF:encodeURI('{"font":"Arial", "size":12, "color":"0x000", "bold":"true", "italic":"false", "underline":"false"}'),imageTF:encodeURI('{"font":"Arial", "size":11, "color":"red", "bold":"false", "italic":"false", "underline":"false"}'),textEncoding:"utf-8",addImageSkinURL:"addImage.png",allDeleteBtnUpSkinURL:"allDeleteBtnUpSkin.png",allDeleteBtnHoverSkinURL:"allDeleteBtnHoverSkin.png",rotateLeftBtnEnableSkinURL:"rotateLeftEnable.png",rotateLeftBtnDisableSkinURL:"rotateLeftDisable.png",rotateRightBtnEnableSkinURL:"rotateRightEnable.png",rotateRightBtnDisableSkinURL:"rotateRightDisable.png",deleteBtnEnableSkinURL:"deleteEnable.png",deleteBtnDisableSkinURL:"deleteDisable.png",backgroundURL:"",listBackgroundURL:"",buttonURL:"button.png"}},autosave:{success:"Local conservation success"}};
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment