=2*v&&3!==w&&(c[0]=g.a.cloneElement(c[0],{className:t+"-item-after-jump-prev"}),c.unshift(u)),l-w>=2*v&&w!==l-2&&(c[c.length-1]=g.a.cloneElement(c[c.length-1],{className:t+"-item-before-jump-next"}),c.push(h)),1!==N&&c.unshift(d),j!==l&&c.push(f)}var F=null;o.showTotal&&(F=g.a.createElement("li",{className:t+"-total-text"},o.showTotal(o.total,[0===o.total?0:(w-1)*x+1,w*x>o.total?o.total:w*x])));var V=!this.hasPrev()||!l,B=!this.hasNext()||!l;return g.a.createElement("ul",a()({className:y()(t,n,i()({},t+"-disabled",r)),style:o.style,unselectable:"unselectable",ref:this.savePaginationNode},_),F,g.a.createElement("li",{title:o.showTitle?s.prev_page:null,onClick:this.prev,tabIndex:V?null:0,onKeyPress:this.runIfEnterPrev,className:(V?t+"-disabled":"")+" "+t+"-prev","aria-disabled":V},o.itemRender(C,"prev",this.getItemIcon(o.prevIcon))),c,g.a.createElement("li",{title:o.showTitle?s.next_page:null,onClick:this.next,tabIndex:B?null:0,onKeyPress:this.runIfEnterNext,className:(B?t+"-disabled":"")+" "+t+"-next","aria-disabled":B},o.itemRender(S,"next",this.getItemIcon(o.nextIcon))),g.a.createElement(k,{disabled:r,locale:o.locale,rootPrefixCls:t,selectComponentClass:o.selectComponentClass,selectPrefixCls:o.selectPrefixCls,changeSize:this.props.showSizeChanger?this.changePageSize:null,current:this.state.current,pageSize:this.state.pageSize,pageSizeOptions:this.props.pageSizeOptions,quickGo:this.shouldDisplayQuickJumper()?this.handleChange:null,goButton:m}))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n={};if("current"in e&&(n.current=e.current,e.current!==t.current&&(n.currentInputValue=n.current)),"pageSize"in e&&e.pageSize!==t.pageSize){var r=t.current,i=P(e.pageSize,t,e);r=r>i?i:r,"current"in e||(n.current=r,n.currentInputValue=r),n.pageSize=e.pageSize}return n}}]),t}(g.a.Component);R.propTypes={disabled:w.a.bool,prefixCls:w.a.string,className:w.a.string,current:w.a.number,defaultCurrent:w.a.number,total:w.a.number,pageSize:w.a.number,defaultPageSize:w.a.number,onChange:w.a.func,hideOnSinglePage:w.a.bool,showSizeChanger:w.a.bool,showLessItems:w.a.bool,onShowSizeChange:w.a.func,selectComponentClass:w.a.func,showPrevNextJumpers:w.a.bool,showQuickJumper:w.a.oneOfType([w.a.bool,w.a.object]),showTitle:w.a.bool,pageSizeOptions:w.a.arrayOf(w.a.string),showTotal:w.a.func,locale:w.a.object,style:w.a.object,itemRender:w.a.func,prevIcon:w.a.oneOfType([w.a.func,w.a.node]),nextIcon:w.a.oneOfType([w.a.func,w.a.node]),jumpPrevIcon:w.a.oneOfType([w.a.func,w.a.node]),jumpNextIcon:w.a.oneOfType([w.a.func,w.a.node])},R.defaultProps={defaultCurrent:1,total:0,defaultPageSize:10,onChange:A,className:"",selectPrefixCls:"rc-select",prefixCls:"rc-pagination",selectComponentClass:null,hideOnSinglePage:!1,showPrevNextJumpers:!0,showQuickJumper:!1,showSizeChanger:!1,showLessItems:!1,showTitle:!0,onShowSizeChange:A,locale:_["a"],style:{},itemRender:T};var L=function(){var e=this;this.getJumpPrevPage=function(){return Math.max(1,e.state.current-(e.props.showLessItems?3:5))},this.getJumpNextPage=function(){return Math.min(P(void 0,e.state,e.props),e.state.current+(e.props.showLessItems?3:5))},this.getItemIcon=function(t){var n=e.props.prefixCls,r=t||g.a.createElement("a",{className:n+"-item-link"});return"function"===typeof t&&(r=g.a.createElement(t,a()({},e.props))),r},this.savePaginationNode=function(t){e.paginationNode=t},this.isValid=function(t){return M(t)&&t!==e.state.current},this.shouldDisplayQuickJumper=function(){var t=e.props,n=t.showQuickJumper,r=t.pageSize,i=t.total;return!(i<=r)&&n},this.handleKeyDown=function(e){e.keyCode!==C.ARROW_UP&&e.keyCode!==C.ARROW_DOWN||e.preventDefault()},this.handleKeyUp=function(t){var n=e.getValidValue(t),r=e.state.currentInputValue;n!==r&&e.setState({currentInputValue:n}),t.keyCode===C.ENTER?e.handleChange(n):t.keyCode===C.ARROW_UP?e.handleChange(n-1):t.keyCode===C.ARROW_DOWN&&e.handleChange(n+1)},this.changePageSize=function(t){var n=e.state.current,r=P(t,e.state,e.props);n=n>r?r:n,0===r&&(n=e.state.current),"number"===typeof t&&("pageSize"in e.props||e.setState({pageSize:t}),"current"in e.props||e.setState({current:n,currentInputValue:n})),e.props.onShowSizeChange(n,t)},this.handleChange=function(t){var n=e.props.disabled,r=t;if(e.isValid(r)&&!n){var i=P(void 0,e.state,e.props);r>i?r=i:r<1&&(r=1),"current"in e.props||e.setState({current:r,currentInputValue:r});var o=e.state.pageSize;return e.props.onChange(r,o),r}return e.state.current},this.prev=function(){e.hasPrev()&&e.handleChange(e.state.current-1)},this.next=function(){e.hasNext()&&e.handleChange(e.state.current+1)},this.jumpPrev=function(){e.handleChange(e.getJumpPrevPage())},this.jumpNext=function(){e.handleChange(e.getJumpNextPage())},this.hasPrev=function(){return e.state.current>1},this.hasNext=function(){return e.state.current2?n-2:0),i=2;i=c?e?"":void 0:(o=s.charCodeAt(l),o<55296||o>56319||l+1===c||(a=s.charCodeAt(l+1))<56320||a>57343?e?s.charAt(l):o:e?s.slice(l,l+2):a-56320+(o-55296<<10)+65536)}}},"6h3Y":function(e,t,n){"use strict";var r=function(e,t,n){e.prototype=t.prototype=n,n.constructor=e};function i(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function o(){}var a=.7,s=1/a,l="\\s*([+-]?\\d+)\\s*",c="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",u="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",h=/^#([0-9a-f]{3,8})$/,d=new RegExp("^rgb\\("+[l,l,l]+"\\)$"),f=new RegExp("^rgb\\("+[u,u,u]+"\\)$"),p=new RegExp("^rgba\\("+[l,l,l,c]+"\\)$"),m=new RegExp("^rgba\\("+[u,u,u,c]+"\\)$"),g=new RegExp("^hsl\\("+[c,u,u]+"\\)$"),v=new RegExp("^hsla\\("+[c,u,u,c]+"\\)$"),y={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function b(){return this.rgb().formatHex()}function w(){return R(this).formatHsl()}function x(){return this.rgb().formatRgb()}function E(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=h.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?C(t):3===n?new O(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?S(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?S(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=d.exec(e))?new O(t[1],t[2],t[3],1):(t=f.exec(e))?new O(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=p.exec(e))?S(t[1],t[2],t[3],t[4]):(t=m.exec(e))?S(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=g.exec(e))?P(t[1],t[2]/100,t[3]/100,1):(t=v.exec(e))?P(t[1],t[2]/100,t[3]/100,t[4]):y.hasOwnProperty(e)?C(y[e]):"transparent"===e?new O(NaN,NaN,NaN,0):null}function C(e){return new O(e>>16&255,e>>8&255,255&e,1)}function S(e,t,n,r){return r<=0&&(e=t=n=NaN),new O(e,t,n,r)}function k(e){return e instanceof o||(e=E(e)),e?(e=e.rgb(),new O(e.r,e.g,e.b,e.opacity)):new O}function _(e,t,n,r){return 1===arguments.length?k(e):new O(e,t,n,null==r?1:r)}function O(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function A(){return"#"+T(this.r)+T(this.g)+T(this.b)}function M(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(1===e?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function T(e){return e=Math.max(0,Math.min(255,Math.round(e)||0)),(e<16?"0":"")+e.toString(16)}function P(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new D(e,t,n,r)}function R(e){if(e instanceof D)return new D(e.h,e.s,e.l,e.opacity);if(e instanceof o||(e=E(e)),!e)return new D;if(e instanceof D)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),a=Math.max(t,n,r),s=NaN,l=a-i,c=(a+i)/2;return l?(s=t===a?(n-r)/l+6*(n0&&c<1?0:s,new D(s,l,c,e.opacity)}function L(e,t,n,r){return 1===arguments.length?R(e):new D(e,t,n,null==r?1:r)}function D(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function N(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}function j(e,t,n,r,i){var o=e*e,a=o*e;return((1-3*e+3*o-a)*t+(4-6*o+3*a)*n+(1+3*e+3*o-3*a)*r+a*i)/6}r(o,E,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:b,formatHex:b,formatHsl:w,formatRgb:x,toString:x}),r(O,_,i(o,{brighter:function(e){return e=null==e?s:Math.pow(s,e),new O(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?a:Math.pow(a,e),new O(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:A,formatHex:A,formatRgb:M,toString:M})),r(D,L,i(o,{brighter:function(e){return e=null==e?s:Math.pow(s,e),new D(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?a:Math.pow(a,e),new D(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new O(N(e>=240?e-240:e+120,i,r),N(e,i,r),N(e<120?e+240:e-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(1===e?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}));var $=function(e){var t=e.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),i=e[r],o=e[r+1],a=r>0?e[r-1]:2*i-o,s=ro&&(i=t.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,l.push({i:a,x:G(n,r)})),o=X.lastIndex;return oe.config);case 4:return u=n.sent,n.next=7,Object(l["b"])("/admin/config/save",s()({},u[i]));case 7:if(h=n.sent,200===h.code){n.next=10;break}return n.abrupt("return");case 10:return r["a"].success("\u4fdd\u5b58\u6210\u529f"),n.next=13,a({type:"fetch"});case 13:case"end":return n.stop()}},n)})()},getEmailTemplate(e,t){return o.a.mark(function e(){var n,r;return o.a.wrap(function(e){while(1)switch(e.prev=e.next){case 0:return n=t.put,e.next=3,Object(l["a"])("/admin/config/getEmailTemplate");case 3:if(r=e.sent,200===r.code){e.next=6;break}return e.abrupt("return");case 6:return e.next=8,n({type:"setState",payload:{emailTemplate:r.data}});case 8:case"end":return e.stop()}},e)})()},setTelegramWebhook(e,t){return o.a.mark(function n(){var i,a,s;return o.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return i=e.token,a=t.put,t.select,n.next=4,a({type:"setState",payload:{setTelegramWebhookLoading:!0}});case 4:return n.next=6,Object(l["b"])("/admin/config/setTelegramWebhook",{telegram_bot_token:i});case 6:return s=n.sent,n.next=9,a({type:"setState",payload:{setTelegramWebhookLoading:!1}});case 9:if(200===s.code){n.next=11;break}return n.abrupt("return");case 11:r["a"].success("webhook \u8bbe\u7f6e\u6210\u529f");case 12:case"end":return n.stop()}},n)})()}}}},"6tYh":function(e,t,n){var r=n("93I4"),i=n("5K7Z"),o=function(e,t){if(i(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{r=n("2GTP")(Function.call,n("vwuL").f(Object.prototype,"__proto__").set,2),r(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return o(e,n),t?e.__proto__=n:r(e,n),e}}({},!1):void 0),check:o}},"7ICb":function(e,t,n){"use strict";function r(e){return e.clone().startOf("month")}function i(e){return e.clone().endOf("month")}function o(e,t,n){return e.clone().add(t,n)}function a(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments[1],n=arguments[2];return e.some(function(e){return e.isSame(t,n)})}n.d(t,"b",function(){return r}),n.d(t,"a",function(){return i}),n.d(t,"c",function(){return o}),n.d(t,"d",function(){return a})},"7IPS":function(e,t,n){"use strict";t["a"]=function(e,t,n,r,i){var o,a=e.children,s=-1,l=a.length,c=e.value&&(i-n)/e.value;while(++s0?arguments[0]:void 0)}},b={get:function(e){if(u(e)){var t=m(e);return!0===t?v(h(this,p)).get(e):t?t[this._i]:void 0}},set:function(e,t){return c.def(h(this,p),e,t)}},w=e.exports=n("nWMQ")(p,y,b,c,!0,!0);d&&f&&(r=c.getConstructor(y,p),l(r.prototype,b),s.NEED=!0,o(["delete","has","get","set"],function(e){var t=w.prototype,n=t[e];a(t,e,function(t,i){if(u(t)&&!g(t)){this._f||(this._f=new r);var o=this._f[e](t,i);return"set"==e?this:o}return n.call(this,t,i)})}))},"7Uk0":function(e,t,n){"use strict";var r=n("il4q"),i=n("Spc3"),o=n("OsVd");e.exports=function(e){var t=r(this),n=o(t.length),a=arguments.length,s=i(a>1?arguments[1]:void 0,n),l=a>2?arguments[2]:void 0,c=void 0===l?n:i(l,n);while(c>s)t[s++]=e;return t}},"7ixt":function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r={adjustX:1,adjustY:1},i=[0,0],o={left:{points:["cr","cl"],overflow:r,offset:[-4,0],targetOffset:i},right:{points:["cl","cr"],overflow:r,offset:[4,0],targetOffset:i},top:{points:["bc","tc"],overflow:r,offset:[0,-4],targetOffset:i},bottom:{points:["tc","bc"],overflow:r,offset:[0,4],targetOffset:i},topLeft:{points:["bl","tl"],overflow:r,offset:[0,-4],targetOffset:i},leftTop:{points:["tr","tl"],overflow:r,offset:[-4,0],targetOffset:i},topRight:{points:["br","tr"],overflow:r,offset:[0,-4],targetOffset:i},rightTop:{points:["tl","tr"],overflow:r,offset:[4,0],targetOffset:i},bottomRight:{points:["tr","br"],overflow:r,offset:[0,4],targetOffset:i},rightBottom:{points:["bl","br"],overflow:r,offset:[4,0],targetOffset:i},bottomLeft:{points:["tl","bl"],overflow:r,offset:[0,4],targetOffset:i},leftBottom:{points:["br","bl"],overflow:r,offset:[-4,0],targetOffset:i}}},"7tDr":function(e,t,n){"use strict";n.r(t);var r=n("d6i3"),i=n.n(r),o=n("p0pE"),a=n.n(o);t["default"]={name:"layout",state:{showNav:!1},reducers:{save(e,t){return a()({},e,t.payload)}},effects:{showNav(e,t){return i.a.mark(function n(){var r,o,s,l;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.show,o=t.put,s=t.select,n.next=4,s(e=>e.layout);case 4:return l=n.sent,n.next=7,o({type:"save",payload:a()({},l,{showNav:"undefined"!==typeof r?r:!l.showNav})});case 7:case"end":return n.stop()}},n)})()}}}},"7tNx":function(e,t,n){"use strict";var r=n("7vYJ");e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},"7tlc":function(e,t,n){(function(e){var r=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),n={},r=0;r=o)return e;switch(e){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(e){return"[Circular]"}default:return e}}),l=r[n];n=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),y(n)?r.showHidden=n:n&&t._extend(r,n),S(r.showHidden)&&(r.showHidden=!1),S(r.depth)&&(r.depth=2),S(r.colors)&&(r.colors=!1),S(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=l),h(r,e,r.depth)}function l(e,t){var n=s.styles[t];return n?"\x1b["+s.colors[n][0]+"m"+e+"\x1b["+s.colors[n][1]+"m":e}function c(e,t){return e}function u(e){var t={};return e.forEach(function(e,n){t[e]=!0}),t}function h(e,n,r){if(e.customInspect&&n&&M(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var i=n.inspect(r,e);return E(i)||(i=h(e,i,r)),i}var o=d(e,n);if(o)return o;var a=Object.keys(n),s=u(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(n)),A(n)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return f(n);if(0===a.length){if(M(n)){var l=n.name?": "+n.name:"";return e.stylize("[Function"+l+"]","special")}if(k(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(O(n))return e.stylize(Date.prototype.toString.call(n),"date");if(A(n))return f(n)}var c,y="",b=!1,w=["{","}"];if(v(n)&&(b=!0,w=["[","]"]),M(n)){var x=n.name?": "+n.name:"";y=" [Function"+x+"]"}return k(n)&&(y=" "+RegExp.prototype.toString.call(n)),O(n)&&(y=" "+Date.prototype.toUTCString.call(n)),A(n)&&(y=" "+f(n)),0!==a.length||b&&0!=n.length?r<0?k(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special"):(e.seen.push(n),c=b?p(e,n,r,s,a):a.map(function(t){return m(e,n,r,s,t,b)}),e.seen.pop(),g(c,y,w)):w[0]+y+w[1]}function d(e,t){if(S(t))return e.stylize("undefined","undefined");if(E(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return x(t)?e.stylize(""+t,"number"):y(t)?e.stylize(""+t,"boolean"):b(t)?e.stylize("null","null"):void 0}function f(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,n,r,i){for(var o=[],a=0,s=t.length;a-1&&(s=o?s.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+s.split("\n").map(function(e){return" "+e}).join("\n"))):s=e.stylize("[Circular]","special")),S(a)){if(o&&i.match(/^\d+$/))return s;a=JSON.stringify(""+i),a.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function g(e,t,n){var r=e.reduce(function(e,t){return 0,t.indexOf("\n")>=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0);return r>60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}function v(e){return Array.isArray(e)}function y(e){return"boolean"===typeof e}function b(e){return null===e}function w(e){return null==e}function x(e){return"number"===typeof e}function E(e){return"string"===typeof e}function C(e){return"symbol"===typeof e}function S(e){return void 0===e}function k(e){return _(e)&&"[object RegExp]"===P(e)}function _(e){return"object"===typeof e&&null!==e}function O(e){return _(e)&&"[object Date]"===P(e)}function A(e){return _(e)&&("[object Error]"===P(e)||e instanceof Error)}function M(e){return"function"===typeof e}function T(e){return null===e||"boolean"===typeof e||"number"===typeof e||"string"===typeof e||"symbol"===typeof e||"undefined"===typeof e}function P(e){return Object.prototype.toString.call(e)}function R(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(n){if(S(o)&&(o=Object({NODE_ENV:"production"}).NODE_DEBUG||""),n=n.toUpperCase(),!a[n])if(new RegExp("\\b"+n+"\\b","i").test(o)){var r=e.pid;a[n]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",n,r,e)}}else a[n]=function(){};return a[n]},t.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=v,t.isBoolean=y,t.isNull=b,t.isNullOrUndefined=w,t.isNumber=x,t.isString=E,t.isSymbol=C,t.isUndefined=S,t.isRegExp=k,t.isObject=_,t.isDate=O,t.isError=A,t.isFunction=M,t.isPrimitive=T,t.isBuffer=n("j/1Z");var L=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function D(){var e=new Date,t=[R(e.getHours()),R(e.getMinutes()),R(e.getSeconds())].join(":");return[e.getDate(),L[e.getMonth()],t].join(" ")}function N(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",D(),t.format.apply(t,arguments))},t.inherits=n("FfBw"),t._extend=function(e,t){if(!t||!_(t))return e;var n=Object.keys(t),r=n.length;while(r--)e[n[r]]=t[n[r]];return e};var j="undefined"!==typeof Symbol?Symbol("util.promisify.custom"):void 0;function $(e,t){if(!e){var n=new Error("Promise was rejected with a falsy value");n.reason=e,e=n}return t(e)}function I(t){if("function"!==typeof t)throw new TypeError('The "original" argument must be of type Function');function n(){for(var n=[],r=0;r0)g=l(e,t,p,o(p.length),g,h-1)-1;else{if(g>=9007199254740991)throw TypeError();e[g]=p}g++}v++}return g}e.exports=l},"8Z/V":function(e,t,n){e.exports=!n("wUWy")(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},"8ifW":function(e,t,n){"use strict";(function(e){var r=n("q1tI"),i=n.n(r),o=n("1EPD"),a=n("17x9"),s=n.n(a),l=1073741823,c="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof window?window:"undefined"!==typeof e?e:{};function u(){var e="__global_unique_id__";return c[e]=(c[e]||0)+1}function h(e,t){return e===t?0!==e||1/e===1/t:e!==e&&t!==t}function d(e){var t=[];return{on:function(e){t.push(e)},off:function(e){t=t.filter(function(t){return t!==e})},get:function(){return e},set:function(n,r){e=n,t.forEach(function(t){return t(e,r)})}}}function f(e){return Array.isArray(e)?e[0]:e}function p(e,t){var n,i,a="__create-react-context-"+u()+"__",c=function(e){function n(){var t;return t=e.apply(this,arguments)||this,t.emitter=d(t.props.value),t}Object(o["a"])(n,e);var r=n.prototype;return r.getChildContext=function(){var e;return e={},e[a]=this.emitter,e},r.componentWillReceiveProps=function(e){if(this.props.value!==e.value){var n,r=this.props.value,i=e.value;h(r,i)?n=0:(n="function"===typeof t?t(r,i):l,n|=0,0!==n&&this.emitter.set(e.value,n))}},r.render=function(){return this.props.children},n}(r["Component"]);c.childContextTypes=(n={},n[a]=s.a.object.isRequired,n);var p=function(t){function n(){var e;return e=t.apply(this,arguments)||this,e.state={value:e.getValue()},e.onUpdate=function(t,n){var r=0|e.observedBits;0!==(r&n)&&e.setState({value:e.getValue()})},e}Object(o["a"])(n,t);var r=n.prototype;return r.componentWillReceiveProps=function(e){var t=e.observedBits;this.observedBits=void 0===t||null===t?l:t},r.componentDidMount=function(){this.context[a]&&this.context[a].on(this.onUpdate);var e=this.props.observedBits;this.observedBits=void 0===e||null===e?l:e},r.componentWillUnmount=function(){this.context[a]&&this.context[a].off(this.onUpdate)},r.getValue=function(){return this.context[a]?this.context[a].get():e},r.render=function(){return f(this.props.children)(this.state.value)},n}(r["Component"]);return p.contextTypes=(i={},i[a]=s.a.object,i),{Provider:c,Consumer:p}}var m=i.a.createContext||p;t["a"]=m}).call(this,n("yLpj"))},"8jRI":function(e,t,n){"use strict";var r="%[a-f0-9]{2}",i=new RegExp(r,"gi"),o=new RegExp("("+r+")+","gi");function a(e,t){try{return decodeURIComponent(e.join(""))}catch(e){}if(1===e.length)return e;t=t||1;var n=e.slice(0,t),r=e.slice(t);return Array.prototype.concat.call([],a(n),a(r))}function s(e){try{return decodeURIComponent(e)}catch(r){for(var t=e.match(i),n=1;n=n&&(e.updateKey=a[0].updateKey||a[0].key,a.shift()),a.push(e)),{notices:a}})},r.remove=function(e){r.setState(function(t){return{notices:t.notices.filter(function(t){return t.key!==e})}})},i=n,p()(r,i)}return g()(t,e),d()(t,[{key:"getTransitionName",value:function(){var e=this.props,t=e.transitionName;return!t&&e.animation&&(t=e.prefixCls+"-"+e.animation),t}},{key:"render",value:function(){var e,t=this,n=this.props,r=this.state.notices,i=r.map(function(e,i){var o=Boolean(i===r.length-1&&e.updateKey),a=e.updateKey?e.updateKey:e.key,s=Object(S["a"])(t.remove.bind(t,e.key),e.onClose);return y.a.createElement(A,l()({prefixCls:n.prefixCls},e,{key:a,update:o,onClose:s,onClick:e.onClick,closeIcon:n.closeIcon}),e.content)}),o=(e={},a()(e,n.prefixCls,1),a()(e,n.className,!!n.className),e);return y.a.createElement("div",{className:_()(o),style:n.style},y.a.createElement(C["a"],{transitionName:this.getTransitionName()},i))}}]),t}(v["Component"]);R.propTypes={prefixCls:w.a.string,transitionName:w.a.string,animation:w.a.oneOfType([w.a.string,w.a.object]),style:w.a.object,maxCount:w.a.number,closeIcon:w.a.node},R.defaultProps={prefixCls:"rc-notification",animation:"fade",style:{top:65,left:"50%"}},R.newInstance=function(e,t){var n=e||{},r=n.getContainer,o=i()(n,["getContainer"]),a=document.createElement("div");if(r){var s=r();s.appendChild(a)}else document.body.appendChild(a);var c=!1;function u(e){c||(c=!0,t({notice:function(t){e.add(t)},removeNotice:function(t){e.remove(t)},component:e,destroy:function(){E.a.unmountComponentAtNode(a),a.parentNode.removeChild(a)}}))}E.a.render(y.a.createElement(R,l()({},o,{ref:u})),a)};var L=R;t["a"]=L},"8zNj":function(e,t,n){"use strict";n("2qtc");var r=n("kLXV"),i=(n("5NDa"),n("5rEg")),o=(n("Pwec"),n("CtXQ")),a=n("p0pE"),s=n.n(a),l=n("q1tI"),c=n.n(l),u=(n("Bl7J"),n("/MKj"));class h extends c.a.Component{constructor(e){super(e),this.state={submit:s()({},this.props.record),visible:!1}}save(){var e=s()({},this.state.submit);this.props.dispatch({type:"serverGroup/save",params:e,callback:()=>{this.setState({visible:!1})}})}render(){var e=this.props.serverGroup.fetchLoading;return c.a.createElement(c.a.Fragment,null,c.a.cloneElement(this.props.children,{onClick:()=>this.setState({visible:!0})}),c.a.createElement(r["a"],{title:"".concat(this.state.submit.id?"\u7f16\u8f91\u7ec4":"\u521b\u5efa\u7ec4"),visible:this.state.visible,onCancel:()=>this.setState({visible:!1}),onOk:()=>e||this.save(),okText:e?c.a.createElement(o["a"],{type:"loading"}):"\u63d0\u4ea4",cancelText:"\u53d6\u6d88"},c.a.createElement("div",null,c.a.createElement("div",{className:"form-group"},c.a.createElement("label",{for:"example-text-input-alt"},"\u7ec4\u540d"),c.a.createElement(i["a"],{placeholder:"\u8bf7\u8f93\u5165\u7ec4\u540d",value:this.state.submit.name,onChange:e=>{this.setState({submit:s()({},this.state.submit,{name:e.target.value})})}})))))}}t["a"]=Object(u["c"])(e=>{var t=e.serverGroup;return{serverGroup:t}})(h)},"93I4":function(e,t){e.exports=function(e){return"object"===typeof e?null!==e:"function"===typeof e}},"9Do8":function(e,t,n){"use strict";e.exports=n("zt9T")},"9HFh":function(e,t,n){var r=n("xJie"),i=n("WFJy").concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},"9R94":function(e,t,n){"use strict";var r=!0,i="Invariant failed";function o(e,t){if(!e){if(r)throw new Error(i);throw new Error(i+": "+(t||""))}}t["a"]=o},"9WFV":function(e,t,n){var r=n("2we2");e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},"9lTW":function(e,t,n){"use strict";(function(t){function r(e,t){if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i=0;c--)if(u[c]!==h[c])return!1;for(c=u.length-1;c>=0;c--)if(l=u[c],!b(e[l],t[l],n,r))return!1;return!0}function E(e,t,n){b(e,t,!0)&&v(e,t,n,"notDeepStrictEqual",E)}function C(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function S(e){var t;try{e()}catch(e){t=e}return t}function k(e,t,n,r){var i;if("function"!==typeof t)throw new TypeError('"block" argument must be a function');"string"===typeof n&&(r=n,n=null),i=S(t),r=(n&&n.name?" ("+n.name+").":".")+(r?" "+r:"."),e&&!i&&v(i,n,"Missing expected exception"+r);var a="string"===typeof r,s=!e&&o.isError(i),l=!e&&i&&!n;if((s&&a&&C(i,n)||l)&&v(i,n,"Got unwanted exception"+r),e&&i&&n&&!C(i,n)||!e&&i)throw i}h.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=g(this),this.generatedMessage=!0);var t=e.stackStartFunction||v;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var n=new Error;if(n.stack){var r=n.stack,i=f(t),o=r.indexOf("\n"+i);if(o>=0){var a=r.indexOf("\n",o+1);r=r.substring(a+1)}this.stack=r}}},o.inherits(h.AssertionError,Error),h.fail=v,h.ok=y,h.equal=function(e,t,n){e!=t&&v(e,t,n,"==",h.equal)},h.notEqual=function(e,t,n){e==t&&v(e,t,n,"!=",h.notEqual)},h.deepEqual=function(e,t,n){b(e,t,!1)||v(e,t,n,"deepEqual",h.deepEqual)},h.deepStrictEqual=function(e,t,n){b(e,t,!0)||v(e,t,n,"deepStrictEqual",h.deepStrictEqual)},h.notDeepEqual=function(e,t,n){b(e,t,!1)&&v(e,t,n,"notDeepEqual",h.notDeepEqual)},h.notDeepStrictEqual=E,h.strictEqual=function(e,t,n){e!==t&&v(e,t,n,"===",h.strictEqual)},h.notStrictEqual=function(e,t,n){e===t&&v(e,t,n,"!==",h.notStrictEqual)},h.throws=function(e,t,n){k(!0,e,t,n)},h.doesNotThrow=function(e,t,n){k(!1,e,t,n)},h.ifError=function(e){if(e)throw e};var _=Object.keys||function(e){var t=[];for(var n in e)a.call(e,n)&&t.push(n);return t}}).call(this,n("yLpj"))},"9nSz":function(e,t,n){"use strict";var r=n("WGNW"),i=n("Y/ne"),o=n("08Qx"),a=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(o);r(r.P+r.F*a,"String",{padStart:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},A22h:function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e===1/t:e!=e&&t!=t}},A5Xg:function(e,t,n){var r=n("NsO/"),i=n("ar/p").f,o={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(e){try{return i(e)}catch(e){return a.slice()}};e.exports.f=function(e){return a&&"[object Window]"==o.call(e)?s(e):i(r(e))}},"A7R+":function(e,t,n){e.exports=!n("8Z/V")&&!n("wUWy")(function(){return 7!=Object.defineProperty(n("SfDG")("div"),"a",{get:function(){return 7}}).a})},AHJs:function(e,t,n){"use strict";function r(e){"@babel/helpers - typeof";return r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}function a(e,t){return a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},a(e,t)}function s(e){return function(){var t,n=h(e);if(u()){var r=h(this).constructor;t=Reflect.construct(n,arguments,r)}else t=n.apply(this,arguments);return l(this,t)}}function l(e,t){return!t||"object"!==r(t)&&"function"!==typeof t?c(e):t}function c(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function u(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(e){return!1}}function h(e){return h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},h(e)}var d=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t["default"]=e,t};Object.defineProperty(t,"__esModule",{value:!0});var f=d(n("q1tI")),p=function(e){o(n,e);var t=s(n);function n(){return i(this,n),t.apply(this,arguments)}return n}(f.Component);t.default=p,p.isTableColumnGroup=!0},ANjH:function(e,t,n){"use strict";n.d(t,"a",function(){return v}),n.d(t,"b",function(){return d}),n.d(t,"c",function(){return u}),n.d(t,"d",function(){return g}),n.d(t,"e",function(){return s});var r=n("bCCX"),i=function(){return Math.random().toString(36).substring(7).split("").join(".")},o={INIT:"@@redux/INIT"+i(),REPLACE:"@@redux/REPLACE"+i(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+i()}};function a(e){if("object"!==typeof e||null===e)return!1;var t=e;while(null!==Object.getPrototypeOf(t))t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function s(e,t,n){var i;if("function"===typeof t&&"function"===typeof n||"function"===typeof n&&"function"===typeof arguments[3])throw new Error("It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function.");if("function"===typeof t&&"undefined"===typeof n&&(n=t,t=void 0),"undefined"!==typeof n){if("function"!==typeof n)throw new Error("Expected the enhancer to be a function.");return n(s)(e,t)}if("function"!==typeof e)throw new Error("Expected the reducer to be a function.");var l=e,c=t,u=[],h=u,d=!1;function f(){h===u&&(h=u.slice())}function p(){if(d)throw new Error("You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return c}function m(e){if("function"!==typeof e)throw new Error("Expected the listener to be a function.");if(d)throw new Error("You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api-reference/store#subscribelistener for more details.");var t=!0;return f(),h.push(e),function(){if(t){if(d)throw new Error("You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api-reference/store#subscribelistener for more details.");t=!1,f();var n=h.indexOf(e);h.splice(n,1),u=null}}}function g(e){if(!a(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if("undefined"===typeof e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(d)throw new Error("Reducers may not dispatch actions.");try{d=!0,c=l(c,e)}finally{d=!1}for(var t=u=h,n=0;n2&&void 0!==arguments[2]&&arguments[2];return{type:r,payload:{location:e,action:t,isFirstRendering:n}}},o="@@router/CALL_HISTORY_METHOD",a=function(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r0?r:n)(e)}},AUvm:function(e,t,n){"use strict";var r=n("5T2Y"),i=n("B+OT"),o=n("jmDH"),a=n("Y7ZC"),s=n("kTiW"),l=n("6/1s").KEY,c=n("KUxP"),u=n("29s/"),h=n("RfKB"),d=n("YqAc"),f=n("UWiX"),p=n("zLkG"),m=n("Zxgi"),g=n("R+7+"),v=n("kAMH"),y=n("5K7Z"),b=n("93I4"),w=n("JB68"),x=n("NsO/"),E=n("G8Mo"),C=n("rr1i"),S=n("oVml"),k=n("A5Xg"),_=n("vwuL"),O=n("mqlF"),A=n("2faE"),M=n("w6GO"),T=_.f,P=A.f,R=k.f,L=r.Symbol,D=r.JSON,N=D&&D.stringify,j="prototype",$=f("_hidden"),I=f("toPrimitive"),F={}.propertyIsEnumerable,V=u("symbol-registry"),B=u("symbols"),W=u("op-symbols"),H=Object[j],U="function"==typeof L&&!!O.f,z=r.QObject,K=!z||!z[j]||!z[j].findChild,q=o&&c(function(){return 7!=S(P({},"a",{get:function(){return P(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=T(H,t);r&&delete H[t],P(e,t,n),r&&e!==H&&P(H,t,r)}:P,G=function(e){var t=B[e]=S(L[j]);return t._k=e,t},Y=U&&"symbol"==typeof L.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof L},Q=function(e,t,n){return e===H&&Q(W,t,n),y(e),t=E(t,!0),y(n),i(B,t)?(n.enumerable?(i(e,$)&&e[$][t]&&(e[$][t]=!1),n=S(n,{enumerable:C(0,!1)})):(i(e,$)||P(e,$,C(1,{})),e[$][t]=!0),q(e,t,n)):P(e,t,n)},X=function(e,t){y(e);var n,r=g(t=x(t)),i=0,o=r.length;while(o>i)Q(e,n=r[i++],t[n]);return e},J=function(e,t){return void 0===t?S(e):X(S(e),t)},Z=function(e){var t=F.call(this,e=E(e,!0));return!(this===H&&i(B,e)&&!i(W,e))&&(!(t||!i(this,e)||!i(B,e)||i(this,$)&&this[$][e])||t)},ee=function(e,t){if(e=x(e),t=E(t,!0),e!==H||!i(B,t)||i(W,t)){var n=T(e,t);return!n||!i(B,t)||i(e,$)&&e[$][t]||(n.enumerable=!0),n}},te=function(e){var t,n=R(x(e)),r=[],o=0;while(n.length>o)i(B,t=n[o++])||t==$||t==l||r.push(t);return r},ne=function(e){var t,n=e===H,r=R(n?W:x(e)),o=[],a=0;while(r.length>a)!i(B,t=r[a++])||n&&!i(H,t)||o.push(B[t]);return o};U||(L=function(){if(this instanceof L)throw TypeError("Symbol is not a constructor!");var e=d(arguments.length>0?arguments[0]:void 0),t=function(n){this===H&&t.call(W,n),i(this,$)&&i(this[$],e)&&(this[$][e]=!1),q(this,e,C(1,n))};return o&&K&&q(H,e,{configurable:!0,set:t}),G(e)},s(L[j],"toString",function(){return this._k}),_.f=ee,A.f=Q,n("ar/p").f=k.f=te,n("NV0k").f=Z,O.f=ne,o&&!n("uOPS")&&s(H,"propertyIsEnumerable",Z,!0),p.f=function(e){return G(f(e))}),a(a.G+a.W+a.F*!U,{Symbol:L});for(var re="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ie=0;re.length>ie;)f(re[ie++]);for(var oe=M(f.store),ae=0;oe.length>ae;)m(oe[ae++]);a(a.S+a.F*!U,"Symbol",{for:function(e){return i(V,e+="")?V[e]:V[e]=L(e)},keyFor:function(e){if(!Y(e))throw TypeError(e+" is not a symbol!");for(var t in V)if(V[t]===e)return t},useSetter:function(){K=!0},useSimple:function(){K=!1}}),a(a.S+a.F*!U,"Object",{create:J,defineProperty:Q,defineProperties:X,getOwnPropertyDescriptor:ee,getOwnPropertyNames:te,getOwnPropertySymbols:ne});var se=c(function(){O.f(1)});a(a.S+a.F*se,"Object",{getOwnPropertySymbols:function(e){return O.f(w(e))}}),D&&a(a.S+a.F*(!U||c(function(){var e=L();return"[null]"!=N([e])||"{}"!=N({a:e})||"{}"!=N(Object(e))})),"JSON",{stringify:function(e){var t,n,r=[e],i=1;while(arguments.length>i)r.push(arguments[i++]);if(n=t=r[1],(b(t)||void 0!==e)&&!Y(e))return v(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!Y(t))return t}),r[1]=t,N.apply(D,r)}}),L[j][I]||n("NegM")(L[j],I,L[j].valueOf),h(L,"Symbol"),h(Math,"Math",!0),h(r.JSON,"JSON",!0)},AyUB:function(e,t,n){e.exports={default:n("3GJH"),__esModule:!0}},"B+OT":function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},B6Jk:function(e,t,n){},B9Yq:function(e,t){e.exports=function(){throw new Error("define cannot be used indirect")}},BC81:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){return null};t.default=r},BFt8:function(e,t,n){var r=n("oxo0"),i=n("il4q"),o=n("J57/")("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=i(e),r(e,o)?e[o]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},"BGR+":function(e,t,n){"use strict";var r=n("QbLZ"),i=n.n(r);function o(e,t){for(var n=i()({},e),r=0;re.length)&&(t=e.length);for(var n=0,r=new Array(t);n1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[];i[n]=i[n]||[];var o=[],a=function(e){var t=i.length-n;e&&!e.children&&t>1&&(!e.rowSpan||e.rowSpan0?(c.children=e(c.children,n+1,c,i),r.colSpan+=c.colSpan):r.colSpan+=1;for(var h=0;h{s.a.push(n),this.props.dispatch({type:"layout/showNav",show:!1})}},r&&r,o.a.createElement("span",{className:"nav-main-link-name"},t)))}}isAdmin(){return-1!==this.props.location.pathname.indexOf("admin")}render(){return o.a.createElement("nav",{id:"sidebar"},o.a.createElement("div",{className:"smini-hidden bg-header-dark"},o.a.createElement("div",{className:"content-header justify-content-lg-center bg-black-10"},o.a.createElement("a",{className:"link-fx font-size-lg text-white",href:"/"},o.a.createElement("span",{className:"text-white-75"},window.settings.title?window.settings.title:"V2Board")),o.a.createElement("div",{className:"d-lg-none"},o.a.createElement("a",{className:"text-white ml-2","data-toggle":"layout","data-action":"sidebar_close",href:"javascript:void(0);",onClick:()=>this.props.dispatch({type:"layout/showNav"})},o.a.createElement("i",{className:"fa fa-times-circle"}))))),o.a.createElement("div",{className:"content-side content-side-full"},o.a.createElement("ul",{className:"nav-main"},this.state.nav.map(e=>{return this.renderMenu(e.type,e.title,e.href,e.icon)}))))}}var u=Object(l["c"])(e=>{var t=e.layout;return{layout:t}})(c),h=n("t3Un");class d extends o.a.Component{constructor(e){super(e),this.state={showAvatarMenu:!1,showSearchBar:!1}}componentDidMount(){var e=this.props.user.userInfo;e.email||this.props.dispatch({type:"user/getUserInfo"})}showAvatarMenu(){var e=this;this.setState({showAvatarMenu:!this.state.showAvatarMenu},()=>{document.onclick=function(t){e.state.showAvatarMenu&&e.setState({showAvatarMenu:!1}),document.onclick=void 0}})}logout(){Object(h["a"])("/user/logout").then(e=>{s.a.push("/login")})}render(){var e=this.props.user.userInfo;return o.a.createElement("header",{id:"page-header"},o.a.createElement("div",{className:"content-header"},o.a.createElement("div",{className:"sidebar-toggle",style:{display:this.props.search?"block":"none"}},o.a.createElement("button",{type:"button",className:"btn btn-dual mr-1 d-lg-none","data-toggle":"layout","data-action":"sidebar_toggle",onClick:()=>this.props.dispatch({type:"layout/showNav"})},o.a.createElement("i",{className:"fa fa-fw fa-bars"})),this.props.search&&o.a.createElement("button",{type:"button",className:"btn btn-dual",onClick:()=>{this.setState({showSearchBar:!0})}},o.a.createElement("i",{className:"fa fa-fw fa-search"})," ",o.a.createElement("span",{className:"ml-1 d-none d-sm-inline-block"},"\u641c\u7d22"))),o.a.createElement("div",null,this.props.title),o.a.createElement("div",null,this.state.loading?o.a.createElement("div",{className:"spinner-grow text-primary"}):o.a.createElement("div",{className:"dropdown d-inline-block"},o.a.createElement("button",{type:"button",className:"btn btn-dual",id:"page-header-user-dropdown","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false",onClick:()=>this.showAvatarMenu()},o.a.createElement("i",{className:"far fa fa-user-circle"}),o.a.createElement("span",{className:"d-none d-lg-inline ml-1"},e.email),o.a.createElement("i",{className:"fa fa-fw fa-angle-down ml-1"})),o.a.createElement("div",{className:"dropdown-menu dropdown-menu-right dropdown-menu-lg p-0 ".concat(this.state.showAvatarMenu&&"show"),"aria-labelledby":"page-header-user-dropdown"},o.a.createElement("div",{className:"p-2"},o.a.createElement("a",{className:"dropdown-item d-flex justify-content-between align-items-center",href:"javascript:void(0);",onClick:()=>this.logout()},"\u767b\u51fa",o.a.createElement("i",{className:"fa fa-fw fa-sign-out-alt text-danger ml-1"}))))))),this.props.search&&o.a.createElement("div",{className:"overlay-header bg-dark ".concat(this.state.showSearchBar?"show":"")},o.a.createElement("div",{className:"content-header bg-dark"},o.a.createElement("div",{className:"w-100"},o.a.createElement("div",{className:"input-group"},o.a.createElement("div",{className:"input-group-prepend"},o.a.createElement("button",{type:"button",className:"btn btn-dark",onClick:()=>{this.setState({showSearchBar:!1})}},o.a.createElement("i",{className:"fa fa-fw fa-times-circle"}))),o.a.createElement("input",{type:"text",className:"form-control border-0",placeholder:this.props.search.placeholder,onChange:e=>this.props.search.onChange(e.target.value),defaultValue:this.props.search.defaultValue}))))))}}var f=Object(l["c"])(e=>{var t=e.layout,n=e.user;return{layout:t,user:n}})(d);class p extends o.a.Component{render(){return o.a.createElement("footer",{id:"page-footer",className:"bg-body-light"},o.a.createElement("div",{className:"content py-0"},o.a.createElement("div",{className:"row font-size-sm"},o.a.createElement("div",{className:"col-sm-6 order-sm-2 mb-1 mb-sm-0 text-center text-sm-right"},o.a.createElement("i",{className:"fa fa-heart text-danger"})," ",window.settings.title?window.settings.title:"V2Board"),o.a.createElement("div",{className:"col-sm-6 order-sm-1 text-center text-sm-left"},o.a.createElement("a",{className:"font-w600",href:"javascript:void(0);"},window.settings.title?window.settings.title:"V2Board"," v1.5.1"),o.a.createElement("span",{"data-toggle":"year-copy"})))))}}var m=n("+Gva"),g=window.settings.theme;class v extends o.a.Component{componentDidMount(){window.scrollTo(0,0)}render(){return o.a.createElement(r["a"],{locale:m["a"]},o.a.createElement("div",{id:"page-container",className:"sidebar-o ".concat("dark"===g.sidebar?"sidebar-dark":""," ").concat("dark"===g.header?"page-header-dark":""," side-scroll page-header-fixed main-content-boxed side-trans-enabled ").concat(this.props.layout.showNav&&"sidebar-o-xs")},o.a.createElement("div",{onClick:()=>this.props.dispatch({type:"layout/showNav"}),className:"v2board-nav-mask",style:{display:this.props.layout.showNav?"block":"none"}}),o.a.createElement(u,this.props),o.a.createElement(f,{search:this.props.search,title:this.props.title}),this.props.loading?o.a.createElement("main",{id:"main-container"},o.a.createElement("div",{className:"content content-full"},o.a.createElement("div",{className:"spinner-grow text-primary",role:"status"},o.a.createElement("span",{className:"sr-only"},"Loading...")))):o.a.createElement("main",{id:"main-container"},o.a.createElement("div",{className:"p-0 p-lg-4"},this.props.children)),o.a.createElement(p,null)))}}t["a"]=Object(l["c"])(e=>{var t=e.layout;return{layout:t}})(v)},BnQZ:function(e,t,n){var r=n("2a/h"),i=n("gL7N")("iterator"),o=n("yw4e");e.exports=n("bV5f").getIteratorMethod=function(e){if(void 0!=e)return e[i]||e["@@iterator"]||o[r(e)]}},BsWD:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n("a3WO");function i(e,t){if(e){if("string"===typeof e)return Object(r["a"])(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(r["a"])(e,t):void 0}}},Bus3:function(e,t,n){n("Jaki")("Int8",1,function(e){return function(t,n,r){return e(this,t,n,r)}})},Bz7s:function(e,t,n){n("8Z/V")&&"g"!=/./g.flags&&n("V5/1").f(RegExp.prototype,"flags",{configurable:!0,get:n("7tNx")})},CSvP:function(e,t,n){"use strict";function r(){return 0}n.d(t,"a",function(){return r}),t["b"]=function(e){return function(){return e}}},CTsd:function(e,t,n){var r=n("OeOC"),i=n("9HFh").f,o={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(e){try{return i(e)}catch(e){return a.slice()}};e.exports.f=function(e){return a&&"[object Window]"==o.call(e)?s(e):i(r(e))}},CfL3:function(e,t,n){"use strict";var r=n("7vYJ"),i=n("8BMt"),o="number";e.exports=function(e){if("string"!==e&&e!==o&&"default"!==e)throw TypeError("Incorrect hint");return i(r(this),e!=o)}},CgOb:function(e,t,n){"use strict";n("bbsP");var r=n("/wGt"),i=(n("+L6B"),n("2/Rp")),o=(n("BoS7"),n("Sdc0")),a=(n("5Dmo"),n("3S7+")),s=(n("Pwec"),n("CtXQ")),l=(n("OaEy"),n("2fM7")),c=(n("iQDF"),n("+eQT")),u=(n("5NDa"),n("5rEg")),h=n("p0pE"),d=n.n(h),f=n("q1tI"),p=n.n(f),m=n("/MKj"),g=n("wd/R"),v=n.n(g);class y extends p.a.Component{constructor(e){super(e),this.state={visible:!1}}show(){this.setState({visible:!0},()=>{this.props.dispatch({type:"user/getUserInfoById",id:this.props.userId})})}hide(){this.setState({visible:!1},()=>{this.props.dispatch({type:"user/setState",payload:{user:{}}})})}formChange(e,t){this.props.dispatch({type:"user/setState",payload:{user:d()({},this.props.user.user,{[e]:t})}})}submit(){var e=d()({},this.props.user.user);this.props.dispatch({type:"user/update",params:e,callback:()=>{this.hide()}})}render(){var e=this.props.user,t=e.user,n=e.updateLoading,h=this.props.plan.plans,d=this.state.visible;return p.a.createElement(p.a.Fragment,null,p.a.cloneElement(this.props.children,{onClick:()=>this.show()}),p.a.createElement(r["a"],{id:"user",width:"80%",title:"\u7528\u6237\u7ba1\u7406",visible:d,onClose:()=>this.hide(),cancelText:"\u53d6\u6d88"},t.email?p.a.createElement("div",null,p.a.createElement("div",null,p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u90ae\u7bb1"),p.a.createElement(u["a"],{placeholder:"\u8bf7\u8f93\u5165\u90ae\u7bb1",defaultValue:t.email,onChange:e=>this.formChange("email",e.target.value)})),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u5bc6\u7801"),p.a.createElement(u["a"],{defaultValue:t.password,placeholder:"\u5982\u9700\u4fee\u6539\u5bc6\u7801\u8bf7\u8f93\u5165",onChange:e=>this.formChange("password",e.target.value)})),p.a.createElement("div",{className:"row"},p.a.createElement("div",{className:"form-group col-md-6 col-xs-12"},p.a.createElement("label",null,"\u4f59\u989d"),p.a.createElement(u["a"],{type:"number",addonAfter:"\xa5",placeholder:"\u4f59\u989d",defaultValue:t.balance,onChange:e=>this.formChange("balance",e.target.value)})),p.a.createElement("div",{className:"form-group col-md-6 col-xs-12"},p.a.createElement("label",null,"\u63a8\u5e7f\u4f63\u91d1"),p.a.createElement(u["a"],{type:"number",addonAfter:"\xa5",placeholder:"\u63a8\u5e7f\u4f63\u91d1",defaultValue:t.commission_balance,onChange:e=>this.formChange("commission_balance",e.target.value)}))),p.a.createElement("div",{className:"row"},p.a.createElement("div",{className:"form-group col-md-6 col-xs-12"},p.a.createElement("label",null,"\u5df2\u7528\u4e0a\u884c"),p.a.createElement(u["a"],{type:"number",addonAfter:"GB",placeholder:"\u5df2\u7528\u4e0a\u884c",defaultValue:t.u,onChange:e=>this.formChange("u",e.target.value)})),p.a.createElement("div",{className:"form-group col-md-6 col-xs-12"},p.a.createElement("label",null,"\u5df2\u7528\u4e0b\u884c"),p.a.createElement(u["a"],{type:"number",addonAfter:"GB",placeholder:"\u5df2\u7528\u4e0b\u884c",defaultValue:t.d,onChange:e=>this.formChange("d",e.target.value)}))),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u6d41\u91cf"),p.a.createElement(u["a"],{type:"number",addonAfter:"GB",defaultValue:t.transfer_enable,placeholder:"\u8bf7\u8f93\u5165\u6d41\u91cf",onChange:e=>this.formChange("transfer_enable",e.target.value)})),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u5230\u671f\u65f6\u95f4"),p.a.createElement("div",null,p.a.createElement(c["a"],{placeholder:"\u8bf7\u9009\u62e9\u7528\u6237\u5230\u671f\u65e5\u671f\uff0c\u4e3a\u7a7a\u5219\u4e0d\u9650\u5236\u5230\u671f\u65f6\u95f4",defaultValue:null!==t.expired_at&&v()(1e3*t.expired_at),style:{width:"100%"},onChange:e=>this.formChange("expired_at",e?e.format("X"):null)}))),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u8ba2\u9605\u8ba1\u5212"),p.a.createElement(l["a"],{placeholder:"\u8bf7\u9009\u62e9\u7528\u6237\u8ba2\u9605\u8ba1\u5212",style:{width:"100%"},defaultValue:t.plan_id||null,onChange:e=>this.formChange("plan_id",e)},p.a.createElement(l["a"].Option,{value:null},"\u65e0"),h.map(e=>{return p.a.createElement(l["a"].Option,{key:Math.random(),value:e.id},e.name)}))),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u8d26\u6237\u72b6\u6001"),p.a.createElement(l["a"],{style:{width:"100%"},defaultValue:t.banned?1:0,onChange:e=>this.formChange("banned",e)},p.a.createElement(l["a"].Option,{key:1,value:1},"\u5c01\u7981"),p.a.createElement(l["a"].Option,{key:0,value:0},"\u6b63\u5e38"))),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u63a8\u8350\u8fd4\u5229\u6bd4\u4f8b"),p.a.createElement(u["a"],{addonAfter:"%",defaultValue:t.commission_rate,placeholder:"\u8bf7\u8f93\u5165\u63a8\u8350\u8fd4\u5229\u6bd4\u4f8b(\u4e3a\u7a7a\u5219\u8ddf\u968f\u7ad9\u70b9\u8bbe\u7f6e\u8fd4\u5229\u6bd4\u4f8b)",onChange:e=>this.formChange("commission_rate",e.target.value)})),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u4e13\u4eab\u6298\u6263\u6bd4\u4f8b ",p.a.createElement(a["a"],{placement:"top",title:"\u8bbe\u7f6e\u540e\u8be5\u7528\u6237\u8d2d\u4e70\u4efb\u4f55\u8ba2\u9605\u5c06\u59cb\u7ec8\u4eab\u53d7\u8be5\u6298\u6263"},p.a.createElement(s["a"],{type:"question-circle"}))),p.a.createElement(u["a"],{addonAfter:"%",defaultValue:t.discount,placeholder:"\u8bf7\u8f93\u5165\u4e13\u4eab\u6298\u6263\u6bd4\u4f8b",onChange:e=>this.formChange("discount",e.target.value)})),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u662f\u5426\u7ba1\u7406\u5458"),p.a.createElement("div",null,p.a.createElement(o["a"],{checked:t.is_admin,onChange:e=>this.formChange("is_admin",e?1:0)}))),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{htmlFor:"example-text-input-alt"},"\u662f\u5426\u5458\u5de5"),p.a.createElement("div",null,p.a.createElement(o["a"],{checked:t.is_staff,onChange:e=>this.formChange("is_staff",e?1:0)}))),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{htmlFor:"example-text-input-alt"},"\u5907\u6ce8"),p.a.createElement("div",null,p.a.createElement(u["a"].TextArea,{rows:4,placeholder:"\u8bf7\u5728\u8fd9\u91cc\u8bb0\u5f55..",defaultValue:t.remarks,onChange:e=>this.formChange("remarks",e.target.value)})))),p.a.createElement("div",{className:"v2board-drawer-action"},p.a.createElement(i["a"],{style:{marginRight:8},onClick:()=>this.hide()},"\u53d6\u6d88"),p.a.createElement(i["a"],{disabled:n,loading:n,onClick:()=>this.submit(),type:"primary"},"\u63d0\u4ea4"))):p.a.createElement(s["a"],{type:"loading",style:{fontSize:24,color:"#415A94"}})))}}t["a"]=Object(m["c"])(e=>{var t=e.user,n=e.plan;return{user:t,plan:n}})(y)},Cit5:function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t["default"]=e,t},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(n("q1tI")),s=i(n("17x9")),l=o(n("TSYQ")),c=n("6Ogq"),u=o(n("UNrv"));function h(e,t){var n=t.table,i=n.props,o=i.prefixCls,s=i.scroll,h=i.showHeader,d=e.columns,f=e.fixed,p=e.tableClassName,m=e.handleBodyScrollLeft,g=e.expander,v=n.saveRef,y=n.props.useFixedHeader,b={},w=c.measureScrollbar({direction:"vertical"});if(s.y){y=!0;var x=c.measureScrollbar({direction:"horizontal",prefixCls:o});x>0&&!f&&(b.marginBottom="-".concat(x,"px"),b.paddingBottom="0px",b.minWidth="".concat(w,"px"),b.overflowX="scroll",b.overflowY=0===w?"hidden":"scroll")}return y&&h?a.createElement("div",{key:"headTable",ref:f?null:v("headTable"),className:l.default("".concat(o,"-header"),r({},"".concat(o,"-hide-scrollbar"),w>0)),style:b,onScroll:m},a.createElement(u.default,{tableClassName:p,hasHead:!0,hasBody:!1,fixed:f,columns:d,expander:g})):null}t.default=h,h.contextTypes={table:s.any}},CnBM:function(e,t,n){"use strict";var r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!==typeof t&&"function"!==typeof t?e:t}function a(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var s=n("q1tI"),l=n("17x9"),c=[],u=[];function h(e){return"object"===r(n.m)&&e().every(function(e){return"undefined"!==typeof e&&"undefined"!==typeof n.m[e]})}function d(e){var t=e(),n={loading:!0,loaded:null,error:null};return n.promise=t.then(function(e){return n.loading=!1,n.loaded=e,e}).catch(function(e){throw n.loading=!1,n.error=e,e}),n}function f(e){var t={loading:!1,loaded:{},error:null},n=[];try{Object.keys(e).forEach(function(r){var i=d(e[r]);i.loading?t.loading=!0:(t.loaded[r]=i.loaded,t.error=i.error),n.push(i.promise),i.promise.then(function(e){t.loaded[r]=e}).catch(function(e){t.error=e})})}catch(e){t.error=e}return t.promise=Promise.all(n).then(function(e){return t.loading=!1,e}).catch(function(e){throw t.loading=!1,e}),t}function p(e){return e&&e.__esModule?e.default:e}function m(e,t){return s.createElement(p(e),t)}function g(e,t){var n,r;if(!t.loading)throw new Error("react-loadable requires a `loading` component");var d=Object.assign({loader:null,loading:null,delay:200,timeout:null,render:m,webpack:null,modules:null},t),f=null;function p(){return f||(f=e(d.loader)),f.promise}return c.push(p),"function"===typeof d.webpack&&u.push(function(){if(h(d.webpack))return p()}),r=n=function(t){function n(r){i(this,n);var a=o(this,t.call(this,r));return a.retry=function(){a.setState({error:null,loading:!0,timedOut:!1}),f=e(d.loader),a._loadModule()},p(),a.state={error:f.error,pastDelay:!1,timedOut:!1,loading:f.loading,loaded:f.loaded},a}return a(n,t),n.preload=function(){return p()},n.prototype.componentWillMount=function(){this._mounted=!0,this._loadModule()},n.prototype._loadModule=function(){var e=this;if(this.context.loadable&&Array.isArray(d.modules)&&d.modules.forEach(function(t){e.context.loadable.report(t)}),f.loading){"number"===typeof d.delay&&(0===d.delay?this.setState({pastDelay:!0}):this._delay=setTimeout(function(){e.setState({pastDelay:!0})},d.delay)),"number"===typeof d.timeout&&(this._timeout=setTimeout(function(){e.setState({timedOut:!0})},d.timeout));var t=function(){e._mounted&&(e.setState({error:f.error,loaded:f.loaded,loading:f.loading}),e._clearTimeouts())};f.promise.then(function(){t()}).catch(function(e){t()})}},n.prototype.componentWillUnmount=function(){this._mounted=!1,this._clearTimeouts()},n.prototype._clearTimeouts=function(){clearTimeout(this._delay),clearTimeout(this._timeout)},n.prototype.render=function(){return this.state.loading||this.state.error?s.createElement(d.loading,{isLoading:this.state.loading,pastDelay:this.state.pastDelay,timedOut:this.state.timedOut,error:this.state.error,retry:this.retry}):this.state.loaded?d.render(this.state.loaded,this.props):null},n}(s.Component),n.contextTypes={loadable:l.shape({report:l.func.isRequired})},r}function v(e){return g(d,e)}function y(e){if("function"!==typeof e.render)throw new Error("LoadableMap requires a `render(loaded, props)` function");return g(f,e)}v.Map=y;var b=function(e){function t(){return i(this,t),o(this,e.apply(this,arguments))}return a(t,e),t.prototype.getChildContext=function(){return{loadable:{report:this.props.report}}},t.prototype.render=function(){return s.Children.only(this.props.children)},t}(s.Component);function w(e){var t=[];while(e.length){var n=e.pop();t.push(n())}return Promise.all(t).then(function(){if(e.length)return w(e)})}b.propTypes={report:l.func.isRequired},b.childContextTypes={loadable:l.shape({report:l.func.isRequired}).isRequired},v.Capture=b,v.preloadAll=function(){return new Promise(function(e,t){w(c).then(e,t)})},v.preloadReady=function(){return new Promise(function(e,t){w(u).then(e,e)})},e.exports=v},Crw4:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=P;var r=o(n("q1tI")),i=n("6YkS");function o(e){return e&&e.__esModule?e:{default:e}}function a(e){"@babel/helpers - typeof";return a="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}function s(e,t,n,r,i,o,a){try{var s=e[o](a),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(r,i)}function l(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var o=e.apply(t,n);function a(e){s(o,r,i,a,l,"next",e)}function l(e){s(o,r,i,a,l,"throw",e)}a(void 0)})}}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){for(var n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function S(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}var k={get:function(e){return e._routeInternalComponent},has:function(e){return void 0!==e._routeInternalComponent},set:function(e,t){e._routeInternalComponent=t}},_=function(e){var t=e.path,n=e.exact,o=e.strict,a=e.render,s=e.location,l=e.sensitive,c=C(e,["path","exact","strict","render","location","sensitive"]);return r.default.createElement(i.Route,{path:t,exact:n,strict:o,location:s,sensitive:l,render:function(e){return a(x({},e,{},c))}})};function O(e){var t={};return t}function A(e){if(k.has(e))return k.get(e);var t=e.Routes,n=t.length-1,i=function(e){var t=e.render,n=C(e,["render"]);return t(n)},o=function(){var e=t[n],o=i;i=function(t){return r.default.createElement(e,t,r.default.createElement(o,t))},n-=1};while(n>=0)o();var a=function(t){var n=t.render,o=C(t,["render"]);return r.default.createElement(_,b({},o,{render:function(t){return r.default.createElement(i,b({},t,{route:e,render:n}))}}))};return k.set(e,a),a}var M=!1;function T(e,t){var n,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n=function(n){d(a,n);var o=p(a);function a(e){var t;return c(this,a),t=o.call(this,e),t.wrappedWithInitialProps=!0,t.state={extraProps:x({},i)},M||(M=!window.g_useSSR||e.history&&"POP"!==e.history.action),t}return h(a,[{key:"componentDidMount",value:function(){var e=l(regeneratorRuntime.mark(function e(){return regeneratorRuntime.wrap(function(e){while(1)switch(e.prev=e.next){case 0:M&&this.getInitialProps();case 1:case"end":return e.stop()}},e,this)}));function t(){return e.apply(this,arguments)}return t}()},{key:"componentDidUpdate",value:function(e){var t=this.props.location;e.location.pathname!==t.pathname&&(M=!0,this.getInitialProps())}},{key:"componentWillUnmount",value:function(){M=!0}},{key:"getInitialProps",value:function(){var n=l(regeneratorRuntime.mark(function n(){var r,i,o,a,s;return regeneratorRuntime.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=this.props,i=r.match,o=r.location,a=this.state.extraProps,this.setState({extraProps:x({},a,{fetchingProps:!0})}),n.next=5,e.getInitialProps(x({isServer:!1,route:i,location:o,prevInitialProps:a},t));case 5:if(n.t0=n.sent,n.t0){n.next=8;break}n.t0={};case 8:s=n.t0,s.fetchingProps=!1,this.setState({extraProps:s});case 11:case"end":return n.stop()}},n,this)}));function r(){return n.apply(this,arguments)}return r}()},{key:"render",value:function(){return r.default.createElement(e,x({},this.props,{},this.state.extraProps))}}]),a}(r.default.Component),n}function P(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=n("PszG");return e?r.default.createElement(i.Switch,o,e.map(function(e,n){if(e.redirect)return r.default.createElement(i.Redirect,{key:e.key||n,from:e.path,to:e.redirect,exact:e.exact,strict:e.strict});var o=e.Routes?A(e):_;return r.default.createElement(o,{key:e.key||n,path:e.path,exact:e.exact,strict:e.strict,sensitive:e.sensitive,render:function(n){var i=n.location;M&&(t={});var o=P(e.routes,t,{location:i});if(e.component){var s=O(x({},n,{},t)),l=a.apply("modifyRouteProps",{initialValue:x({},n,{},t,{},s),args:{route:e}}),c=e.component;if(c.getInitialProps){var u=a.apply("modifyInitialProps",{initialValue:{}});c.wrappedWithInitialProps||(c=T(c,u,t),e.component=c)}return r.default.createElement(c,b({key:e.path},l,{route:e}),o)}return o}})})):null}},Ctgt:function(e,t,n){"use strict";n.r(t);var r=n("q1tI"),i=n.n(r),o=n("17x9"),a=n.n(o),s=n("VCL8");function l(){return l=Object.assign||function(e){for(var t=1;t=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function u(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){for(var n=0;n1?arguments[1]:void 0,3);while(n=n?n.n:this._f){r(n.v,n.k,this);while(n&&n.r)n=n.p}},has:function(e){return!!g(p(this,t),e)}}),d&&r(u.prototype,"size",{get:function(){return p(this,t)[m]}}),u},def:function(e,t,n){var r,i,o=g(e,t);return o?o.v=n:(e._l=o={i:i=f(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=o),r&&(r.n=o),e[m]++,"F"!==i&&(e._i[i]=o)),e},getEntry:g,setStrong:function(e,t,n){c(e,t,function(e,n){this._t=p(e,t),this._k=n,this._l=void 0},function(){var e=this,t=e._k,n=e._l;while(n&&n.r)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?u(0,"keys"==t?n.k:"values"==t?n.v:[n.k,n.v]):(e._t=void 0,u(1))},n?"entries":"values",!n,!0),h(t)}}},D8kY:function(e,t,n){var r=n("Ojgd"),i=Math.max,o=Math.min;e.exports=function(e,t){return e=r(e),e<0?i(e+t,0):o(e,t)}},DBt0:function(e,t,n){"use strict";var r=n("7vYJ"),i=n("il4q"),o=n("OsVd"),a=n("AUWw"),s=n("ETUh"),l=n("bsDr"),c=Math.max,u=Math.min,h=Math.floor,d=/\$([$&`']|\d\d?|<[^>]*>)/g,f=/\$([$&`']|\d\d?)/g,p=function(e){return void 0===e?e:String(e)};n("h7Gi")("replace",2,function(e,t,n,m){return[function(r,i){var o=e(this),a=void 0==r?void 0:r[t];return void 0!==a?a.call(r,o,i):n.call(String(o),r,i)},function(e,t){var i=m(n,e,this,t);if(i.done)return i.value;var h=r(e),d=String(this),f="function"===typeof t;f||(t=String(t));var v=h.global;if(v){var y=h.unicode;h.lastIndex=0}var b=[];while(1){var w=l(h,d);if(null===w)break;if(b.push(w),!v)break;var x=String(w[0]);""===x&&(h.lastIndex=s(d,o(h.lastIndex),y))}for(var E="",C=0,S=0;S=C&&(E+=d.slice(C,_)+P,C=_+k.length)}return E+d.slice(C)}];function g(e,t,r,o,a,s){var l=r+e.length,c=o.length,u=f;return void 0!==a&&(a=i(a),u=d),n.call(s,u,function(n,i){var s;switch(i.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,r);case"'":return t.slice(l);case"<":s=a[i.slice(1,-1)];break;default:var u=+i;if(0===u)return n;if(u>c){var d=h(u/10);return 0===d?n:d<=c?void 0===o[d-1]?i.charAt(1):o[d-1]+i.charAt(1):n}s=o[u-1]}return void 0===s?"":s})}})},DFAo:function(e,t,n){"use strict";n("Bz7s");var r=n("7vYJ"),i=n("7tNx"),o=n("8Z/V"),a="toString",s=/./[a],l=function(e){n("rKIl")(RegExp.prototype,a,e,!0)};n("wUWy")(function(){return"/a/b"!=s.call({source:"a",flags:"b"})})?l(function(){var e=r(this);return"/".concat(e.source,"/","flags"in e?e.flags:!o&&e instanceof RegExp?i.call(e):void 0)}):s.name!=a&&l(function(){return s.call(this)})},DIcO:function(e,t,n){var r=n("gL7N")("unscopables"),i=Array.prototype;void 0==i[r]&&n("VPOE")(i,r,{}),e.exports=function(e){i[r][e]=!0}},DN2a:function(e,t){window.MutationObserver||(window.MutationObserver=function(e){function t(e){this.i=[],this.m=e}function n(e){(function n(){var r=e.takeRecords();r.length&&e.m(r,e),e.h=setTimeout(n,t._period)})()}function r(t){var n,r={type:null,target:null,addedNodes:[],removedNodes:[],previousSibling:null,nextSibling:null,attributeName:null,attributeNamespace:null,oldValue:null};for(n in t)r[n]!==e&&t[n]!==e&&(r[n]=t[n]);return r}function i(e,t){var n=c(e,t);return function(i){var o=i.length;if(t.a&&3===e.nodeType&&e.nodeValue!==n.a&&i.push(new r({type:"characterData",target:e,oldValue:n.a})),t.b&&n.b&&s(i,e,n.b,t.f),t.c||t.g)var a=l(i,e,n,t);(a||i.length!==o)&&(n=c(e,t))}}function o(e,t){return t.value}function a(e,t){return"style"!==t.name?t.value:e.style.cssText}function s(t,n,i,o){for(var a,s,l={},c=n.attributes,u=c.length;u--;)a=c[u],s=a.name,o&&o[s]===e||(m(n,a)!==i[s]&&t.push(r({type:"attributes",target:n,attributeName:s,oldValue:i[s],attributeNamespace:a.namespaceURI})),l[s]=!0);for(s in i)l[s]||t.push(r({target:n,type:"attributes",attributeName:s,oldValue:i[s]}))}function l(t,n,i,o){function a(e,n,i,a,c){var u,h,d,f=e.length-1;for(c=-~((f-c)/2);d=e.pop();)u=i[d.j],h=a[d.l],o.c&&c&&Math.abs(d.j-d.l)>=f&&(t.push(r({type:"childList",target:n,addedNodes:[u],removedNodes:[u],nextSibling:u.nextSibling,previousSibling:u.previousSibling})),c--),o.b&&h.b&&s(t,u,h.b,o.f),o.a&&3===u.nodeType&&u.nodeValue!==h.a&&t.push(r({type:"characterData",target:u,oldValue:h.a})),o.g&&l(u,h)}function l(n,i){for(var h,d,p,m,g,v=n.childNodes,y=i.c,b=v.length,w=y?y.length:0,x=0,E=0,C=0;E=0?t:0)+"#"+e)},b=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(0,s.default)(d.canUseDOM,"Hash history needs a DOM");var t=window.history,n=(0,d.supportsGoWithoutReloadUsingHash)(),i=e.getUserConfirmation,a=void 0===i?d.getConfirmation:i,u=e.hashType,f=void 0===u?"slash":u,b=e.basename?(0,c.stripTrailingSlash)((0,c.addLeadingSlash)(e.basename)):"",w=m[f],x=w.encodePath,E=w.decodePath,C=function(){var e=E(g());return(0,o.default)(!b||(0,c.hasBasename)(e,b),'You are attempting to use a basename on a page whose URL path does not begin with the basename. Expected path "'+e+'" to begin with "'+b+'".'),b&&(e=(0,c.stripBasename)(e,b)),(0,l.createLocation)(e)},S=(0,h.default)(),k=function(e){r(K,e),K.length=t.length,S.notifyListeners(K.location,K.action)},_=!1,O=null,A=function(){var e=g(),t=x(e);if(e!==t)y(t);else{var n=C(),r=K.location;if(!_&&(0,l.locationsAreEqual)(r,n))return;if(O===(0,c.createPath)(n))return;O=null,M(n)}},M=function(e){if(_)_=!1,k();else{var t="POP";S.confirmTransitionTo(e,t,a,function(n){n?k({action:t,location:e}):T(e)})}},T=function(e){var t=K.location,n=D.lastIndexOf((0,c.createPath)(t));-1===n&&(n=0);var r=D.lastIndexOf((0,c.createPath)(e));-1===r&&(r=0);var i=n-r;i&&(_=!0,I(i))},P=g(),R=x(P);P!==R&&y(R);var L=C(),D=[(0,c.createPath)(L)],N=function(e){return"#"+x(b+(0,c.createPath)(e))},j=function(e,t){(0,o.default)(void 0===t,"Hash history cannot push state; it is ignored");var n="PUSH",r=(0,l.createLocation)(e,void 0,void 0,K.location);S.confirmTransitionTo(r,n,a,function(e){if(e){var t=(0,c.createPath)(r),i=x(b+t),a=g()!==i;if(a){O=t,v(i);var s=D.lastIndexOf((0,c.createPath)(K.location)),l=D.slice(0,-1===s?0:s+1);l.push(t),D=l,k({action:n,location:r})}else(0,o.default)(!1,"Hash history cannot PUSH the same path; a new entry will not be added to the history stack"),k()}})},$=function(e,t){(0,o.default)(void 0===t,"Hash history cannot replace state; it is ignored");var n="REPLACE",r=(0,l.createLocation)(e,void 0,void 0,K.location);S.confirmTransitionTo(r,n,a,function(e){if(e){var t=(0,c.createPath)(r),i=x(b+t),o=g()!==i;o&&(O=t,y(i));var a=D.indexOf((0,c.createPath)(K.location));-1!==a&&(D[a]=t),k({action:n,location:r})}})},I=function(e){(0,o.default)(n,"Hash history go(n) causes a full page reload in this browser"),t.go(e)},F=function(){return I(-1)},V=function(){return I(1)},B=0,W=function(e){B+=e,1===B?window.addEventListener(p,A):0===B&&window.removeEventListener(p,A)},H=!1,U=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=S.setPrompt(e);return H||(W(1),H=!0),function(){return H&&(H=!1,W(-1)),t()}},z=function(e){var t=S.appendListener(e);return W(1),function(){W(-1),t()}},K={length:t.length,action:"POP",location:L,createHref:N,push:j,replace:$,go:I,goBack:F,goForward:V,block:U,listen:z};return K};t.default=b},ERIh:function(e,t,n){"use strict";n.r(t),n.d(t,"dva",function(){return s});var r=window.settings,i=r.theme,o=r.host,a=document.createElement("link");a.rel="stylesheet",a.href=o?"./theme/".concat(i.color,".css"):"./assets/admin/theme/".concat(i.color,".css"),document.getElementsByTagName("head")[0].appendChild(a);var s={config:{onError(e){e.preventDefault()}}}},ETUh:function(e,t,n){"use strict";var r=n("6RnP")(!0);e.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},EVqI:function(e,t,n){"use strict";function r(){return r=Object.assign||function(e){for(var t=1;t-1?i:null}};function d(e){for(var t=[],n=1;n3?0:(e-e%10!==10?1:0)*e%10]}},y=d({},v),b=function(e){return y=d(y,e)},w=function(e){return e.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},x=function(e,t){void 0===t&&(t=2),e=String(e);while(e.length0?"-":"+")+x(100*Math.floor(Math.abs(t)/60)+Math.abs(t)%60,4)},Z:function(e){var t=e.getTimezoneOffset();return(t>0?"-":"+")+x(Math.floor(Math.abs(t)/60),2)+":"+x(Math.abs(t)%60,2)}},C=function(e){return+e-1},S=[null,i],k=[null,l],_=["isPm",l,function(e,t){var n=e.toLowerCase();return n===t.amPm[0]?0:n===t.amPm[1]?1:null}],O=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(e){var t=(e+"").match(/([+-]|\d\d)/gi);if(t){var n=60*+t[1]+parseInt(t[2],10);return"+"===t[0]?n:-n}return 0}],A={D:["day",i],DD:["day",o],Do:["day",i+l,function(e){return parseInt(e,10)}],M:["month",i,C],MM:["month",o,C],YY:["year",o,function(e){var t=new Date,n=+(""+t.getFullYear()).substr(0,2);return+(""+(+e>68?n-1:n)+e)}],h:["hour",i,void 0,"isPm"],hh:["hour",o,void 0,"isPm"],H:["hour",i],HH:["hour",o],m:["minute",i],mm:["minute",o],s:["second",i],ss:["second",o],YYYY:["year",s],S:["millisecond","\\d",function(e){return 100*+e}],SS:["millisecond",o,function(e){return 10*+e}],SSS:["millisecond",a],d:S,dd:S,ddd:k,dddd:k,MMM:["month",l,h("monthNamesShort")],MMMM:["month",l,h("monthNames")],a:_,A:_,ZZ:O,Z:O},M={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},T=function(e){return d(M,e)},P=function(e,t,n){if(void 0===t&&(t=M["default"]),void 0===n&&(n={}),"number"===typeof e&&(e=new Date(e)),"[object Date]"!==Object.prototype.toString.call(e)||isNaN(e.getTime()))throw new Error("Invalid Date pass to format");t=M[t]||t;var i=[];t=t.replace(c,function(e,t){return i.push(t),"@@@"});var o=d(d({},y),n);return t=t.replace(r,function(t){return E[t](e,o)}),t.replace(/@@@/g,function(){return i.shift()})};function R(e,t,n){if(void 0===n&&(n={}),"string"!==typeof t)throw new Error("Invalid format in fecha parse");if(t=M[t]||t,e.length>1e3)return null;var i=new Date,o={year:i.getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},a=[],s=[],l=t.replace(c,function(e,t){return s.push(w(t)),"@@@"}),u={},h={};l=w(l).replace(r,function(e){var t=A[e],n=t[0],r=t[1],i=t[3];if(u[n])throw new Error("Invalid format. "+n+" specified twice in format");return u[n]=!0,i&&(h[i]=!0),a.push(t),"("+r+")"}),Object.keys(h).forEach(function(e){if(!u[e])throw new Error("Invalid format. "+e+" is required in specified format")}),l=l.replace(/@@@/g,function(){return s.shift()});var f=e.match(new RegExp(l,"i"));if(!f)return null;for(var p=d(d({},y),n),m=1;m{return e.is_me?o.a.createElement("div",null,o.a.createElement("div",{className:"font-size-sm font-italic text-muted animated fadeIn my-2 text-right"},c()(1e3*e.created_at).format("YYYY/MM/DD HH:mm")),o.a.createElement("div",{className:"text-right ml-4"},o.a.createElement("div",{className:"d-inline-block font-w600 animated fadeIn bg-body-light border-3x px-3 py-2 mb-2 shadow-sm mw-100 border-right border-primary rounded-left text-left"},e.message))):o.a.createElement("div",null,o.a.createElement("div",{className:"font-size-sm font-italic text-muted animated fadeIn my-2"},c()(1e3*e.created_at).format("YYYY/MM/DD HH:mm")),o.a.createElement("div",{className:"mr-4"},o.a.createElement("div",{className:"d-inline-block font-w600 animated fadeIn bg-body-light border-3x px-3 py-2 mb-2 shadow-sm mw-100 border-left border-dark rounded-right"},e.message)))})),o.a.createElement("div",{className:"js-chat-form block-content p-2 bg-body-dark"},o.a.createElement("input",{onKeyDown:e=>this.props.onKeyDown(e,()=>{this.refs.message&&(this.refs.message.value="")}),ref:"message",type:"text",className:"js-chat-input form-control form-control-alt",placeholder:"\u8f93\u5165\u5185\u5bb9\u56de\u590d\u5de5\u5355...",onChange:e=>this.props.onChange(e)})))}}class d extends o.a.Component{constructor(e){super(e),this.state={message:void 0,submit:{}}}componentDidMount(){this.props.dispatch({type:"ticket/fetchById",id:this.props.match.params.ticket_id}),this.props.dispatch({type:"plan/fetch"}),this.check()}check(){r=setTimeout(()=>{this.props.dispatch({type:"ticket/fetchById",id:this.props.match.params.ticket_id}),this.check()},5e3)}componentWillUnmount(){clearTimeout(r)}reply(e){this.props.dispatch({type:"ticket/reply",id:this.props.match.params.ticket_id,msg:this.state.message,callback:()=>{e()}})}render(){var e=this.props.user.user,t=this.props.ticket,n=t.ticket,r=t.replyLoading;return o.a.createElement(h,{ticket:n,user:e,onKeyDown:(e,t)=>{13!==e.keyCode||r||this.reply(t)},onChange:e=>{this.setState({message:e.target.value})}})}}t["default"]=Object(a["c"])(e=>{var t=e.user,n=e.ticket;return{user:t,ticket:n}})(d)},FYw3:function(e,t,n){"use strict";t.__esModule=!0;var r=n("EJiy"),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}t.default=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!==("undefined"===typeof t?"undefined":(0,i.default)(t))&&"function"!==typeof t?e:t}},FfBw:function(e,t){"function"===typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},FlQf:function(e,t,n){"use strict";var r=n("ccE7")(!0);n("MPFp")(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})})},FpHa:function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},FqPH:function(e,t){e.exports=!1},FwrZ:function(e,t,n){"use strict";t.__esModule=!0;t.addLeadingSlash=function(e){return"/"===e.charAt(0)?e:"/"+e},t.stripLeadingSlash=function(e){return"/"===e.charAt(0)?e.substr(1):e};var r=t.hasBasename=function(e,t){return new RegExp("^"+t+"(\\/|\\?|#|$)","i").test(e)};t.stripBasename=function(e,t){return r(e,t)?e.substr(t.length):e},t.stripTrailingSlash=function(e){return"/"===e.charAt(e.length-1)?e.slice(0,-1):e},t.parsePath=function(e){var t=e||"/",n="",r="",i=t.indexOf("#");-1!==i&&(r=t.substr(i),t=t.substr(0,i));var o=t.indexOf("?");return-1!==o&&(n=t.substr(o),t=t.substr(0,o)),{pathname:t,search:"?"===n?"":n,hash:"#"===r?"":r}},t.createPath=function(e){var t=e.pathname,n=e.search,r=e.hash,i=t||"/";return n&&"?"!==n&&(i+="?"===n.charAt(0)?n:"?"+n),r&&"#"!==r&&(i+="#"===r.charAt(0)?r:"#"+r),i}},FxDU:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createSensor=void 0;var r=n("QO+J"),i=n("j5sG"),o="undefined"!==typeof ResizeObserver?i.createSensor:r.createSensor;t.createSensor=o},G7Hh:function(e,t,n){"use strict";var r=n("7vYJ"),i=n("A22h"),o=n("bsDr");n("h7Gi")("search",1,function(e,t,n,a){return[function(n){var r=e(this),i=void 0==n?void 0:n[t];return void 0!==i?i.call(n,r):new RegExp(n)[t](String(r))},function(e){var t=a(n,e,this);if(t.done)return t.value;var s=r(e),l=String(this),c=s.lastIndex;i(c,0)||(s.lastIndex=0);var u=o(s,l);return i(s.lastIndex,c)||(s.lastIndex=c),null===u?-1:u.index}]})},G8Mo:function(e,t,n){var r=n("93I4");e.exports=function(e,t){if(!r(e))return e;var n,i;if(t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;if("function"==typeof(n=e.valueOf)&&!r(i=n.call(e)))return i;if(!t&&"function"==typeof(n=e.toString)&&!r(i=n.call(e)))return i;throw TypeError("Can't convert object to primitive value")}},"GB+t":function(e,t,n){"use strict";var r=function(){};e.exports=r},GYWy:function(e,t,n){(function(e,r){var i;(function(o){t&&t.nodeType,e&&e.nodeType;var a="object"==typeof r&&r;a.global!==a&&a.window!==a&&a.self;var s,l=2147483647,c=36,u=1,h=26,d=38,f=700,p=72,m=128,g="-",v=/^xn--/,y=/[^\x20-\x7E]/,b=/[\x2E\u3002\uFF0E\uFF61]/g,w={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},x=c-u,E=Math.floor,C=String.fromCharCode;function S(e){throw new RangeError(w[e])}function k(e,t){var n=e.length,r=[];while(n--)r[n]=t(e[n]);return r}function _(e,t){var n=e.split("@"),r="";n.length>1&&(r=n[0]+"@",e=n[1]),e=e.replace(b,".");var i=e.split("."),o=k(i,t).join(".");return r+o}function O(e){var t,n,r=[],i=0,o=e.length;while(i=55296&&t<=56319&&i65535&&(e-=65536,t+=C(e>>>10&1023|55296),e=56320|1023&e),t+=C(e),t}).join("")}function M(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:c}function T(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function P(e,t,n){var r=0;for(e=n?E(e/f):e>>1,e+=E(e/t);e>x*h>>1;r+=c)e=E(e/x);return E(r+(x+1)*e/(e+d))}function R(e){var t,n,r,i,o,a,s,d,f,v,y=[],b=e.length,w=0,x=m,C=p;for(n=e.lastIndexOf(g),n<0&&(n=0),r=0;r=128&&S("not-basic"),y.push(e.charCodeAt(r));for(i=n>0?n+1:0;i=b&&S("invalid-input"),d=M(e.charCodeAt(i++)),(d>=c||d>E((l-w)/a))&&S("overflow"),w+=d*a,f=s<=C?u:s>=C+h?h:s-C,dE(l/v)&&S("overflow"),a*=v}t=y.length+1,C=P(w-o,t,0==o),E(w/t)>l-x&&S("overflow"),x+=E(w/t),w%=t,y.splice(w++,0,x)}return A(y)}function L(e){var t,n,r,i,o,a,s,d,f,v,y,b,w,x,k,_=[];for(e=O(e),b=e.length,t=m,n=0,o=p,a=0;a=t&&yE((l-n)/w)&&S("overflow"),n+=(s-t)*w,t=s,a=0;al&&S("overflow"),y==t){for(d=n,f=c;;f+=c){if(v=f<=o?u:f>=o+h?h:f-o,d{Object.keys(l["a"].cycleText).forEach(t=>{null!==e[t]&&(e[t]=null!==e[t]?e[t]/100:null)})}),e.next=13,n({type:"setState",payload:{plans:r.data}});case 13:case"end":return e.stop()}},e)})()},save(e,t){return i.a.mark(function n(){var r,o,a,c;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.params,o=e.callback,a=t.put,n.next=4,a({type:"setState",payload:{saveLoading:!0}});case 4:return Object.keys(l["a"].cycleText).forEach(e=>{null!==r[e]&&(r[e]=null!==r[e]?Math.round(100*r[e]):null)}),n.next=7,Object(s["b"])("/admin/plan/save",r);case 7:return c=n.sent,n.next=10,a({type:"setState",payload:{saveLoading:!1}});case 10:if(200===c.code){n.next=12;break}return n.abrupt("return");case 12:return n.next=14,a({type:"fetch"});case 14:"function"===typeof o&&o();case 15:case"end":return n.stop()}},n)})()},drop(e,t){return i.a.mark(function n(){var r,o,a;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.id,o=t.put,n.next=4,Object(s["b"])("/admin/plan/drop",{id:r});case 4:if(a=n.sent,200===a.code){n.next=7;break}return n.abrupt("return");case 7:return n.next=9,o({type:"fetch"});case 9:case"end":return n.stop()}},n)})()},update(e,t){return i.a.mark(function n(){var r,o,a,l,c;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.id,o=e.key,a=e.value,l=t.put,n.next=4,Object(s["b"])("/admin/plan/update",{id:r,[o]:a});case 4:if(c=n.sent,200===c.code){n.next=7;break}return n.abrupt("return");case 7:return n.next=9,l({type:"fetch"});case 9:case"end":return n.stop()}},n)})()},sort(e,t){return i.a.mark(function n(){var r,o,a,l,c,u,h;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.fromIndex,o=e.toIndex,a=t.select,l=t.put,n.next=4,l({type:"setState",payload:{fetchLoading:!0}});case 4:return n.next=6,a(e=>e.plan);case 6:return c=n.sent,u=c.plans,re.id)});case 13:if(h=n.sent,200===h.code){n.next=16;break}return n.abrupt("return");case 16:return n.next=18,l({type:"fetch"});case 18:case"end":return n.stop()}},n)})()}}}},GrtH:function(e,t,n){"use strict";n.d(t,"e",function(){return l}),n.d(t,"d",function(){return c}),n.d(t,"f",function(){return u}),n.d(t,"b",function(){return h}),n.d(t,"h",function(){return d}),n.d(t,"c",function(){return f}),n.d(t,"g",function(){return g}),n.d(t,"a",function(){return v});var r=n("QbLZ"),i=n.n(r),o=n("wd/R"),a=n.n(o),s={disabledHours:function(){return[]},disabledMinutes:function(){return[]},disabledSeconds:function(){return[]}};function l(e){var t=a()();return t.locale(e.locale()).utcOffset(e.utcOffset()),t}function c(e){return e.format("LL")}function u(e){var t=l(e);return c(t)}function h(e){var t=e.locale(),n=e.localeData();return n["zh-cn"===t?"months":"monthsShort"](e)}function d(e,t){a.a.isMoment(e)&&a.a.isMoment(t)&&(t.hour(e.hour()),t.minute(e.minute()),t.second(e.second()),t.millisecond(e.millisecond()))}function f(e,t){var n=t?t(e):{};return n=i()({},s,n),n}function p(e,t){var n=!1;if(e){var r=e.hour(),i=e.minute(),o=e.second(),a=t.disabledHours();if(-1===a.indexOf(r)){var s=t.disabledMinutes(r);if(-1===s.indexOf(i)){var l=t.disabledSeconds(r,i);n=-1!==l.indexOf(o)}else n=!0}else n=!0}return!n}function m(e,t){var n=f(e,t);return p(e,n)}function g(e,t,n){return(!t||!t(e))&&!(n&&!m(e,n))}function v(e,t){return e?(Array.isArray(t)&&(t=t[0]),e.format(t)):""}},GsrZ:function(e,t){e.exports="\t\n\v\f\r \xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029\ufeff"},Gytx:function(e,t){e.exports=function(e,t,n,r){var i=n?n.call(r,e,t):void 0;if(void 0!==i)return!!i;if(e===t)return!0;if("object"!==typeof e||!e||"object"!==typeof t||!t)return!1;var o=Object.keys(e),a=Object.keys(t);if(o.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),l=0;lo)a(n[o++]);e._c=[],e._n=!1,t&&!e._h&&N(e)})}},N=function(e){v.call(l,function(){var t,n,r,i=e._v,o=j(e);if(o&&(t=w(function(){M?k.emit("unhandledRejection",i,e):(n=l.onunhandledrejection)?n({promise:e,reason:i}):(r=l.console)&&r.error&&r.error("Unhandled promise rejection",i)}),e._h=M||j(e)?2:1),e._a=void 0,o&&t.e)throw t.v})},j=function(e){return 1!==e._h&&0===(e._a||e._c).length},$=function(e){v.call(l,function(){var t;M?k.emit("rejectionHandled",e):(t=l.onrejectionhandled)&&t({promise:e,reason:e._v})})},I=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),D(t,!0))},F=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw S("Promise can't be resolved itself");(t=L(e))?y(function(){var r={_w:n,_d:!1};try{t.call(e,c(F,r,1),c(I,r,1))}catch(e){I.call(r,e)}}):(n._v=e,n._s=1,D(n,!1))}catch(e){I.call({_w:n,_d:!1},e)}}};R||(A=function(e){p(this,A,C,"_h"),f(e),r.call(this);try{e(c(F,this,1),c(I,this,1))}catch(e){I.call(this,e)}},r=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},r.prototype=n("zNw+")(A.prototype,{then:function(e,t){var n=P(g(this,A));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=M?k.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&D(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),o=function(){var e=new r;this.promise=e,this.resolve=c(F,e,1),this.reject=c(I,e,1)},b.f=P=function(e){return e===A||e===a?new o(e):i(e)}),h(h.G+h.W+h.F*!R,{Promise:A}),n("lvAo")(A,C),n("gRqi")(C),a=n("bV5f")[C],h(h.S+h.F*!R,C,{reject:function(e){var t=P(this),n=t.reject;return n(e),t.promise}}),h(h.S+h.F*(s||!R),C,{resolve:function(e){return E(s&&this===a?A:this,e)}}),h(h.S+h.F*!(R&&n("cQyX")(function(e){A.all(e)["catch"](T)})),C,{all:function(e){var t=this,n=P(t),r=n.resolve,i=n.reject,o=w(function(){var n=[],o=0,a=1;m(e,!1,function(e){var s=o++,l=!1;n.push(void 0),a++,t.resolve(e).then(function(e){l||(l=!0,n[s]=e,--a||r(n))},i)}),--a||r(n)});return o.e&&i(o.v),n.promise},race:function(e){var t=this,n=P(t),r=n.reject,i=w(function(){m(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return i.e&&r(i.v),n.promise}})},Hfiw:function(e,t,n){var r=n("Y7ZC");r(r.S,"Object",{setPrototypeOf:n("6tYh").set})},Hsns:function(e,t,n){var r=n("93I4"),i=n("5T2Y").document,o=r(i)&&r(i.createElement);e.exports=function(e){return o?i.createElement(e):{}}},I4jL:function(e,t,n){"use strict";n.d(t,"b",function(){return o}),n.d(t,"c",function(){return a});var r=n("FPPI"),i=n("7IPS"),o=(1+Math.sqrt(5))/2;function a(e,t,n,o,a,s){var l,c,u,h,d,f,p,m,g,v,y,b=[],w=t.children,x=0,E=0,C=w.length,S=t.value;while(xp&&(p=c),y=d*d*v,m=Math.max(p/y,y/f),m>g){d-=c;break}g=m}b.push(l={value:d,dice:u1?t:1)},n}(o)},IOcx:function(e,t,n){"use strict";var r={};n.r(r),n.d(r,"create",function(){return o}),n.d(r,"fromMat4",function(){return a}),n.d(r,"clone",function(){return s}),n.d(r,"copy",function(){return l}),n.d(r,"fromValues",function(){return c}),n.d(r,"set",function(){return u}),n.d(r,"identity",function(){return h}),n.d(r,"transpose",function(){return d}),n.d(r,"invert",function(){return f}),n.d(r,"adjoint",function(){return p}),n.d(r,"determinant",function(){return m}),n.d(r,"multiply",function(){return g}),n.d(r,"translate",function(){return v}),n.d(r,"rotate",function(){return y}),n.d(r,"scale",function(){return b}),n.d(r,"fromTranslation",function(){return w}),n.d(r,"fromRotation",function(){return x}),n.d(r,"fromScaling",function(){return E}),n.d(r,"fromMat2d",function(){return C}),n.d(r,"fromQuat",function(){return S}),n.d(r,"normalFromMat4",function(){return k}),n.d(r,"projection",function(){return _}),n.d(r,"str",function(){return O}),n.d(r,"frob",function(){return A}),n.d(r,"add",function(){return M}),n.d(r,"subtract",function(){return T}),n.d(r,"multiplyScalar",function(){return P}),n.d(r,"multiplyScalarAndAdd",function(){return R}),n.d(r,"exactEquals",function(){return L}),n.d(r,"equals",function(){return D}),n.d(r,"mul",function(){return N}),n.d(r,"sub",function(){return j});var i=n("yU0y");function o(){var e=new i["a"](9);return i["a"]!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[5]=0,e[6]=0,e[7]=0),e[0]=1,e[4]=1,e[8]=1,e}function a(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[4],e[4]=t[5],e[5]=t[6],e[6]=t[8],e[7]=t[9],e[8]=t[10],e}function s(e){var t=new i["a"](9);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}function l(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e}function c(e,t,n,r,o,a,s,l,c){var u=new i["a"](9);return u[0]=e,u[1]=t,u[2]=n,u[3]=r,u[4]=o,u[5]=a,u[6]=s,u[7]=l,u[8]=c,u}function u(e,t,n,r,i,o,a,s,l,c){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e[4]=o,e[5]=a,e[6]=s,e[7]=l,e[8]=c,e}function h(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=1,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function d(e,t){if(e===t){var n=t[1],r=t[2],i=t[5];e[1]=t[3],e[2]=t[6],e[3]=n,e[5]=t[7],e[6]=r,e[7]=i}else e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8];return e}function f(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=t[4],s=t[5],l=t[6],c=t[7],u=t[8],h=u*a-s*c,d=-u*o+s*l,f=c*o-a*l,p=n*h+r*d+i*f;return p?(p=1/p,e[0]=h*p,e[1]=(-u*r+i*c)*p,e[2]=(s*r-i*a)*p,e[3]=d*p,e[4]=(u*n-i*l)*p,e[5]=(-s*n+i*o)*p,e[6]=f*p,e[7]=(-c*n+r*l)*p,e[8]=(a*n-r*o)*p,e):null}function p(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=t[4],s=t[5],l=t[6],c=t[7],u=t[8];return e[0]=a*u-s*c,e[1]=i*c-r*u,e[2]=r*s-i*a,e[3]=s*l-o*u,e[4]=n*u-i*l,e[5]=i*o-n*s,e[6]=o*c-a*l,e[7]=r*l-n*c,e[8]=n*a-r*o,e}function m(e){var t=e[0],n=e[1],r=e[2],i=e[3],o=e[4],a=e[5],s=e[6],l=e[7],c=e[8];return t*(c*o-a*l)+n*(-c*i+a*s)+r*(l*i-o*s)}function g(e,t,n){var r=t[0],i=t[1],o=t[2],a=t[3],s=t[4],l=t[5],c=t[6],u=t[7],h=t[8],d=n[0],f=n[1],p=n[2],m=n[3],g=n[4],v=n[5],y=n[6],b=n[7],w=n[8];return e[0]=d*r+f*a+p*c,e[1]=d*i+f*s+p*u,e[2]=d*o+f*l+p*h,e[3]=m*r+g*a+v*c,e[4]=m*i+g*s+v*u,e[5]=m*o+g*l+v*h,e[6]=y*r+b*a+w*c,e[7]=y*i+b*s+w*u,e[8]=y*o+b*l+w*h,e}function v(e,t,n){var r=t[0],i=t[1],o=t[2],a=t[3],s=t[4],l=t[5],c=t[6],u=t[7],h=t[8],d=n[0],f=n[1];return e[0]=r,e[1]=i,e[2]=o,e[3]=a,e[4]=s,e[5]=l,e[6]=d*r+f*a+c,e[7]=d*i+f*s+u,e[8]=d*o+f*l+h,e}function y(e,t,n){var r=t[0],i=t[1],o=t[2],a=t[3],s=t[4],l=t[5],c=t[6],u=t[7],h=t[8],d=Math.sin(n),f=Math.cos(n);return e[0]=f*r+d*a,e[1]=f*i+d*s,e[2]=f*o+d*l,e[3]=f*a-d*r,e[4]=f*s-d*i,e[5]=f*l-d*o,e[6]=c,e[7]=u,e[8]=h,e}function b(e,t,n){var r=n[0],i=n[1];return e[0]=r*t[0],e[1]=r*t[1],e[2]=r*t[2],e[3]=i*t[3],e[4]=i*t[4],e[5]=i*t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e}function w(e,t){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=1,e[5]=0,e[6]=t[0],e[7]=t[1],e[8]=1,e}function x(e,t){var n=Math.sin(t),r=Math.cos(t);return e[0]=r,e[1]=n,e[2]=0,e[3]=-n,e[4]=r,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function E(e,t){return e[0]=t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=t[1],e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function C(e,t){return e[0]=t[0],e[1]=t[1],e[2]=0,e[3]=t[2],e[4]=t[3],e[5]=0,e[6]=t[4],e[7]=t[5],e[8]=1,e}function S(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=n+n,s=r+r,l=i+i,c=n*a,u=r*a,h=r*s,d=i*a,f=i*s,p=i*l,m=o*a,g=o*s,v=o*l;return e[0]=1-h-p,e[3]=u-v,e[6]=d+g,e[1]=u+v,e[4]=1-c-p,e[7]=f-m,e[2]=d-g,e[5]=f+m,e[8]=1-c-h,e}function k(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=t[4],s=t[5],l=t[6],c=t[7],u=t[8],h=t[9],d=t[10],f=t[11],p=t[12],m=t[13],g=t[14],v=t[15],y=n*s-r*a,b=n*l-i*a,w=n*c-o*a,x=r*l-i*s,E=r*c-o*s,C=i*c-o*l,S=u*m-h*p,k=u*g-d*p,_=u*v-f*p,O=h*g-d*m,A=h*v-f*m,M=d*v-f*g,T=y*M-b*A+w*O+x*_-E*k+C*S;return T?(T=1/T,e[0]=(s*M-l*A+c*O)*T,e[1]=(l*_-a*M-c*k)*T,e[2]=(a*A-s*_+c*S)*T,e[3]=(i*A-r*M-o*O)*T,e[4]=(n*M-i*_+o*k)*T,e[5]=(r*_-n*A-o*S)*T,e[6]=(m*C-g*E+v*x)*T,e[7]=(g*w-p*C-v*b)*T,e[8]=(p*E-m*w+v*y)*T,e):null}function _(e,t,n){return e[0]=2/t,e[1]=0,e[2]=0,e[3]=0,e[4]=-2/n,e[5]=0,e[6]=-1,e[7]=1,e[8]=1,e}function O(e){return"mat3("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+")"}function A(e){return Math.hypot(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8])}function M(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e[3]=t[3]+n[3],e[4]=t[4]+n[4],e[5]=t[5]+n[5],e[6]=t[6]+n[6],e[7]=t[7]+n[7],e[8]=t[8]+n[8],e}function T(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e[3]=t[3]-n[3],e[4]=t[4]-n[4],e[5]=t[5]-n[5],e[6]=t[6]-n[6],e[7]=t[7]-n[7],e[8]=t[8]-n[8],e}function P(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*n,e[5]=t[5]*n,e[6]=t[6]*n,e[7]=t[7]*n,e[8]=t[8]*n,e}function R(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e[3]=t[3]+n[3]*r,e[4]=t[4]+n[4]*r,e[5]=t[5]+n[5]*r,e[6]=t[6]+n[6]*r,e[7]=t[7]+n[7]*r,e[8]=t[8]+n[8]*r,e}function L(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]}function D(e,t){var n=e[0],r=e[1],o=e[2],a=e[3],s=e[4],l=e[5],c=e[6],u=e[7],h=e[8],d=t[0],f=t[1],p=t[2],m=t[3],g=t[4],v=t[5],y=t[6],b=t[7],w=t[8];return Math.abs(n-d)<=i["b"]*Math.max(1,Math.abs(n),Math.abs(d))&&Math.abs(r-f)<=i["b"]*Math.max(1,Math.abs(r),Math.abs(f))&&Math.abs(o-p)<=i["b"]*Math.max(1,Math.abs(o),Math.abs(p))&&Math.abs(a-m)<=i["b"]*Math.max(1,Math.abs(a),Math.abs(m))&&Math.abs(s-g)<=i["b"]*Math.max(1,Math.abs(s),Math.abs(g))&&Math.abs(l-v)<=i["b"]*Math.max(1,Math.abs(l),Math.abs(v))&&Math.abs(c-y)<=i["b"]*Math.max(1,Math.abs(c),Math.abs(y))&&Math.abs(u-b)<=i["b"]*Math.max(1,Math.abs(u),Math.abs(b))&&Math.abs(h-w)<=i["b"]*Math.max(1,Math.abs(h),Math.abs(w))}var N=g,j=T,$=n("ZxFD"),I=n("n+fv");n.d(t,"a",function(){return r}),n.d(t,"b",function(){return $}),n.d(t,"c",function(){return I})},IR7R:function(e,t,n){"use strict";var r=n("WGNW"),i=n("Y/ne"),o=n("08Qx"),a=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(o);r(r.P+r.F*a,"String",{padEnd:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},IX3V:function(e,t){function n(e,t){var n,r=0,i=e.length;for(r;r{this.state.visible||this.setState({submit:{}})})}save(){this.props.dispatch({type:"notice/save",params:d()({},this.state.submit),callback:()=>{this.modalVisible()}})}drop(e){this.props.dispatch({type:"notice/drop",id:e.id})}render(){var e=this.props.notice,t=e.notices,n=e.fetchLoading,r=[{title:"#",dataIndex:"id",key:"id"},{title:"\u6807\u9898",dataIndex:"title",key:"title"},{title:"\u521b\u5efa\u65f6\u95f4",dataIndex:"created_at",key:"created_at",align:"right",render:e=>{return v()(1e3*e).format("YYYY/MM/DD HH:mm")}},{title:"\u64cd\u4f5c",dataIndex:"action",key:"action",align:"right",render:(e,n,r)=>{return p.a.createElement("div",null,p.a.createElement("a",{onClick:()=>this.setState({submit:t[r]},()=>this.modalVisible()),href:"javascript:void(0);"},"\u7f16\u8f91"),p.a.createElement(u["a"],{type:"vertical"}),p.a.createElement("a",{onClick:()=>this.drop(n),href:"javascript:void(0);"},"\u5220\u9664"))}}];return p.a.createElement(m["a"],i()({},this.props,{title:"\u516c\u544a\u7ba1\u7406"}),p.a.createElement("div",{className:"d-flex justify-content-between align-items-center"}),p.a.createElement("div",{className:"block block-rounded block-bordered ".concat(n?"block-mode-loading":"")},p.a.createElement("div",{className:"bg-white"},p.a.createElement("div",{style:{padding:15}},p.a.createElement(l["a"],{onClick:()=>this.modalVisible()},p.a.createElement(c["a"],{type:"plus"})," \u6dfb\u52a0\u516c\u544a")),p.a.createElement(s["a"],{tableLayout:"auto",dataSource:t,pagination:!1,columns:r,scroll:{x:950}}))),p.a.createElement(o["a"],{title:"".concat(this.state.submit.id?"\u7f16\u8f91\u516c\u544a":"\u65b0\u5efa\u516c\u544a"),visible:this.state.visible,onCancel:()=>this.modalVisible(),onOk:()=>this.state.saveLoading||this.save(),okText:this.state.saveLoading?p.a.createElement(c["a"],{type:"loading"}):"\u63d0\u4ea4",cancelText:"\u53d6\u6d88"},p.a.createElement("div",null,p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u6807\u9898"),p.a.createElement(a["a"],{placeholder:"\u8bf7\u8f93\u5165\u516c\u544a\u6807\u9898",value:this.state.submit.title,onChange:e=>{this.setState({submit:d()({},this.state.submit,{title:e.target.value})})}})),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u516c\u544a\u5185\u5bb9"),p.a.createElement(a["a"].TextArea,{rows:12,value:this.state.submit.content,placeholder:"\u8bf7\u8f93\u5165\u516c\u544a\u5185\u5bb9",onChange:e=>{this.setState({submit:d()({},this.state.submit,{content:e.target.value})})}})),p.a.createElement("div",{className:"form-group"},p.a.createElement("label",{for:"example-text-input-alt"},"\u56fe\u7247URL"),p.a.createElement(a["a"],{placeholder:"\u8bf7\u8f93\u5165\u56fe\u7247URL",value:this.state.submit.img_url,onChange:e=>{this.setState({submit:d()({},this.state.submit,{img_url:e.target.value})})}})))))}}t["default"]=Object(y["c"])(e=>{var t=e.notice;return{notice:t}})(b)},Jaki:function(e,t,n){"use strict";if(n("8Z/V")){var r=n("FqPH"),i=n("c0Oy"),o=n("wUWy"),a=n("WGNW"),s=n("88Vn"),l=n("yLMY"),c=n("wHrr"),u=n("YEVI"),h=n("pQGJ"),d=n("VPOE"),f=n("zNw+"),p=n("AUWw"),m=n("OsVd"),g=n("nYLq"),v=n("Spc3"),y=n("8BMt"),b=n("oxo0"),w=n("2a/h"),x=n("u8+u"),E=n("il4q"),C=n("ULMT"),S=n("/Mfd"),k=n("BFt8"),_=n("9HFh").f,O=n("BnQZ"),A=n("kCK5"),M=n("gL7N"),T=n("+o5p"),P=n("Lnex"),R=n("VeyY"),L=n("OERk"),D=n("yw4e"),N=n("cQyX"),j=n("gRqi"),$=n("7Uk0"),I=n("wlPd"),F=n("V5/1"),V=n("15BC"),B=F.f,W=V.f,H=i.RangeError,U=i.TypeError,z=i.Uint8Array,K="ArrayBuffer",q="Shared"+K,G="BYTES_PER_ELEMENT",Y="prototype",Q=Array[Y],X=l.ArrayBuffer,J=l.DataView,Z=T(0),ee=T(2),te=T(3),ne=T(4),re=T(5),ie=T(6),oe=P(!0),ae=P(!1),se=L.values,le=L.keys,ce=L.entries,ue=Q.lastIndexOf,he=Q.reduce,de=Q.reduceRight,fe=Q.join,pe=Q.sort,me=Q.slice,ge=Q.toString,ve=Q.toLocaleString,ye=M("iterator"),be=M("toStringTag"),we=A("typed_constructor"),xe=A("def_constructor"),Ee=s.CONSTR,Ce=s.TYPED,Se=s.VIEW,ke="Wrong length!",_e=T(1,function(e,t){return Pe(R(e,e[xe]),t)}),Oe=o(function(){return 1===new z(new Uint16Array([1]).buffer)[0]}),Ae=!!z&&!!z[Y].set&&o(function(){new z(1).set({})}),Me=function(e,t){var n=p(e);if(n<0||n%t)throw H("Wrong offset!");return n},Te=function(e){if(x(e)&&Ce in e)return e;throw U(e+" is not a typed array!")},Pe=function(e,t){if(!(x(e)&&we in e))throw U("It is not a typed array constructor!");return new e(t)},Re=function(e,t){return Le(R(e,e[xe]),t)},Le=function(e,t){var n=0,r=t.length,i=Pe(e,r);while(r>n)i[n]=t[n++];return i},De=function(e,t,n){B(e,t,{get:function(){return this._d[n]}})},Ne=function(e){var t,n,r,i,o,a,s=E(e),l=arguments.length,u=l>1?arguments[1]:void 0,h=void 0!==u,d=O(s);if(void 0!=d&&!C(d)){for(a=d.call(s),r=[],t=0;!(o=a.next()).done;t++)r.push(o.value);s=r}for(h&&l>2&&(u=c(u,arguments[2],2)),t=0,n=m(s.length),i=Pe(this,n);n>t;t++)i[t]=h?u(s[t],t):s[t];return i},je=function(){var e=0,t=arguments.length,n=Pe(this,t);while(t>e)n[e]=arguments[e++];return n},$e=!!z&&o(function(){ve.call(new z(1))}),Ie=function(){return ve.apply($e?me.call(Te(this)):Te(this),arguments)},Fe={copyWithin:function(e,t){return I.call(Te(this),e,t,arguments.length>2?arguments[2]:void 0)},every:function(e){return ne(Te(this),e,arguments.length>1?arguments[1]:void 0)},fill:function(e){return $.apply(Te(this),arguments)},filter:function(e){return Re(this,ee(Te(this),e,arguments.length>1?arguments[1]:void 0))},find:function(e){return re(Te(this),e,arguments.length>1?arguments[1]:void 0)},findIndex:function(e){return ie(Te(this),e,arguments.length>1?arguments[1]:void 0)},forEach:function(e){Z(Te(this),e,arguments.length>1?arguments[1]:void 0)},indexOf:function(e){return ae(Te(this),e,arguments.length>1?arguments[1]:void 0)},includes:function(e){return oe(Te(this),e,arguments.length>1?arguments[1]:void 0)},join:function(e){return fe.apply(Te(this),arguments)},lastIndexOf:function(e){return ue.apply(Te(this),arguments)},map:function(e){return _e(Te(this),e,arguments.length>1?arguments[1]:void 0)},reduce:function(e){return he.apply(Te(this),arguments)},reduceRight:function(e){return de.apply(Te(this),arguments)},reverse:function(){var e,t=this,n=Te(t).length,r=Math.floor(n/2),i=0;while(i1?arguments[1]:void 0)},sort:function(e){return pe.call(Te(this),e)},subarray:function(e,t){var n=Te(this),r=n.length,i=v(e,r);return new(R(n,n[xe]))(n.buffer,n.byteOffset+i*n.BYTES_PER_ELEMENT,m((void 0===t?r:v(t,r))-i))}},Ve=function(e,t){return Re(this,me.call(Te(this),e,t))},Be=function(e){Te(this);var t=Me(arguments[1],1),n=this.length,r=E(e),i=m(r.length),o=0;if(i+t>n)throw H(ke);while(o255?255:255&r),i.v[f](n*t+i.o,r,Oe)},M=function(e,t){B(e,t,{get:function(){return O(this,t)},set:function(e){return A(this,t,e)},enumerable:!0})};b?(p=n(function(e,n,r,i){u(e,p,c,"_d");var o,a,s,l,h=0,f=0;if(x(n)){if(!(n instanceof X||(l=w(n))==K||l==q))return Ce in n?Le(p,n):Ne.call(p,n);o=n,f=Me(r,t);var v=n.byteLength;if(void 0===i){if(v%t)throw H(ke);if(a=v-f,a<0)throw H(ke)}else if(a=m(i)*t,a+f>v)throw H(ke);s=a/t}else s=g(n),a=s*t,o=new X(a);d(e,"_d",{b:o,o:f,l:a,e:s,v:new J(o)});while(h{b()}).catch(e=>{window.console&&window.console.error(e)});t["default"]=null;n("AQSi")},L9pr:function(e,t,n){"use strict";t["a"]={today:"\u4eca\u5929",now:"\u6b64\u523b",backToToday:"\u8fd4\u56de\u4eca\u5929",ok:"\u786e\u5b9a",timeSelect:"\u9009\u62e9\u65f6\u95f4",dateSelect:"\u9009\u62e9\u65e5\u671f",weekSelect:"\u9009\u62e9\u5468",clear:"\u6e05\u9664",month:"\u6708",year:"\u5e74",previousMonth:"\u4e0a\u4e2a\u6708 (\u7ffb\u9875\u4e0a\u952e)",nextMonth:"\u4e0b\u4e2a\u6708 (\u7ffb\u9875\u4e0b\u952e)",monthSelect:"\u9009\u62e9\u6708\u4efd",yearSelect:"\u9009\u62e9\u5e74\u4efd",decadeSelect:"\u9009\u62e9\u5e74\u4ee3",yearFormat:"YYYY\u5e74",dayFormat:"D\u65e5",dateFormat:"YYYY\u5e74M\u6708D\u65e5",dateTimeFormat:"YYYY\u5e74M\u6708D\u65e5 HH\u65f6mm\u5206ss\u79d2",previousYear:"\u4e0a\u4e00\u5e74 (Control\u952e\u52a0\u5de6\u65b9\u5411\u952e)",nextYear:"\u4e0b\u4e00\u5e74 (Control\u952e\u52a0\u53f3\u65b9\u5411\u952e)",previousDecade:"\u4e0a\u4e00\u5e74\u4ee3",nextDecade:"\u4e0b\u4e00\u5e74\u4ee3",previousCentury:"\u4e0a\u4e00\u4e16\u7eaa",nextCentury:"\u4e0b\u4e00\u4e16\u7eaa"}},LIAx:function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t["default"]=a;var i=n("E0u0"),o=r(i);function a(e,t,n,r){function i(t){var r=new o["default"](t);n.call(e,r)}if(e.addEventListener){var a=function(){var n=!1;return"object"===typeof r?n=r.capture||!1:"boolean"===typeof r&&(n=r),e.addEventListener(t,i,r||!1),{v:{remove:function(){e.removeEventListener(t,i,n)}}}}();if("object"===typeof a)return a.v}else if(e.attachEvent)return e.attachEvent("on"+t,i),{remove:function(){e.detachEvent("on"+t,i)}}}e.exports=t["default"]},LMyI:function(e,t,n){"use strict";n.r(t);var r=n("d6i3"),i=n.n(r),o=n("p0pE"),a=n.n(o),s=n("t3Un"),l={switchLoading:{},saveLoading:!1};t["default"]={name:"serverShadowsocks",state:a()({},l),reducers:{setState(e,t){var n=t.payload;return a()({},e,n)}},effects:{update(e,t){return i.a.mark(function n(){var r,o,a,l,c;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.id,o=e.key,a=e.value,l=t.put,n.next=4,Object(s["b"])("/admin/server/shadowsocks/update",{id:r,[o]:a});case 4:if(c=n.sent,200===c.code){n.next=7;break}return n.abrupt("return");case 7:return n.next=9,l({type:"serverManage/getNodes"});case 9:case"end":return n.stop()}},n)})()},drop(e,t){return i.a.mark(function n(){var r,o,a;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.id,o=t.put,n.next=4,Object(s["b"])("/admin/server/shadowsocks/drop",{id:r});case 4:if(a=n.sent,200===a.code){n.next=7;break}return n.abrupt("return");case 7:return n.next=9,o({type:"serverManage/getNodes"});case 9:case"end":return n.stop()}},n)})()},copy(e,t){return i.a.mark(function n(){var r,o,a;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.id,o=t.put,n.next=4,Object(s["b"])("/admin/server/shadowsocks/copy",{id:r});case 4:if(a=n.sent,200===a.code){n.next=7;break}return n.abrupt("return");case 7:return n.next=9,o({type:"serverManage/getNodes"});case 9:case"end":return n.stop()}},n)})()},save(e,t){return i.a.mark(function n(){var r,o,a,l;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.params,o=e.callback,a=t.put,n.next=4,a({type:"setState",payload:{saveLoading:!0}});case 4:return n.next=6,Object(s["b"])("/admin/server/shadowsocks/save",r);case 6:return l=n.sent,n.next=9,a({type:"setState",payload:{saveLoading:!1}});case 9:if(200===l.code){n.next=11;break}return n.abrupt("return");case 11:return n.next=13,a({type:"serverManage/getNodes"});case 13:"function"===typeof o&&o();case 14:case"end":return n.stop()}},n)})()}}}},LdHM:function(e,t,n){"use strict";var r=n("q1tI"),i=n.n(r);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){return!t||"object"!==typeof t&&"function"!==typeof t?s(e):t}function s(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}function c(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}function u(e,t){return u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},u(e,t)}var h=function(e){function t(){return o(this,t),a(this,l(t).apply(this,arguments))}return c(t,e),t}(r["Component"]);h.isSelectOptGroup=!0;var d=n("17x9");function f(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function p(e,t){return!t||"object"!==typeof t&&"function"!==typeof t?m(e):t}function m(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function g(e){return g=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},g(e)}function v(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&y(e,t)}function y(e,t){return y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},y(e,t)}var b=function(e){function t(){return f(this,t),p(this,g(t).apply(this,arguments))}return v(t,e),t}(r["Component"]);function w(e){return C(e)||E(e)||x()}function x(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function E(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}function C(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0)return!0;return!1}function ce(e,t){var n=new RegExp("[".concat(t.join(),"]"));return e.split(n).filter(function(e){return e})}function ue(e,t){if(t.props.disabled)return!1;var n=Z(q(t,this.props.optionFilterProp)).join("");return n.toLowerCase().indexOf(e.toLowerCase())>-1}function he(e,t){if(!J(t)&&!G(t)&&"string"!==typeof e)throw new Error("Invalid `value` of type `".concat(typeof e,"` supplied to Option, ")+"expected `string` when `tags/combobox` is `true`.")}function de(e,t){return function(n){e[t]=n}}function fe(){var e=(new Date).getTime(),t="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(t){var n=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"===t?n:7&n|8).toString(16)});return t}function pe(){return pe=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},r=t.needFocus,i=t.fireSearch,o=n.props,a=n.state;if(a.open!==e){n.props.onDropdownVisibleChange&&n.props.onDropdownVisibleChange(e);var s={open:e,backfillValue:""};!e&&J(o)&&o.showSearch&&n.setInputValue("",i),e||n.maybeFocus(e,!!r),n.setState(Ie({open:e},s),function(){e&&n.maybeFocus(e,!!r)})}else n.maybeFocus(e,!!r)},n.setInputValue=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],r=n.props.onSearch;e!==n.state.inputValue&&n.setState(function(n){return t&&e!==n.inputValue&&r&&r(e),{inputValue:e}},n.forcePopupAlign)},n.getValueByInput=function(e){var t=n.props,r=t.multiple,i=t.tokenSeparators,o=n.state.value,a=!1;return ce(e,i).forEach(function(e){var t=[e];if(r){var i=n.getValueByLabel(e);i&&-1===ne(o,i)&&(o=o.concat(i),a=!0,n.fireSelect(i))}else-1===ne(o,e)&&(o=o.concat(t),a=!0,n.fireSelect(e))}),a?o:void 0},n.getRealOpenState=function(e){var t=n.props.open;if("boolean"===typeof t)return t;var r=(e||n.state).open,i=n._options||[];return!X(n.props)&&n.props.showSearch||r&&!i.length&&(r=!1),r},n.markMouseDown=function(){n._mouseDown=!0},n.markMouseLeave=function(){n._mouseDown=!1},n.handleBackfill=function(e){if(n.props.backfill&&(J(n.props)||Y(n.props))){var t=K(e);Y(n.props)&&n.setInputValue(t,!1),n.setState({value:[t],backfillValue:t})}},n.filterOption=function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ue,i=n.state.value,o=i[i.length-1];if(!e||o&&o===n.state.backfillValue)return!0;var a=n.props.filterOption;return"filterOption"in n.props?!0===a&&(a=r.bind(Ue(n))):a=r.bind(Ue(n)),!a||("function"===typeof a?a.call(Ue(n),e,t):!t.props.disabled)},n.timeoutFocus=function(){var e=n.props.onFocus;n.focusTimer&&n.clearFocusTime(),n.focusTimer=window.setTimeout(function(){e&&e()},10)},n.clearFocusTime=function(){n.focusTimer&&(clearTimeout(n.focusTimer),n.focusTimer=null)},n.clearBlurTime=function(){n.blurTimer&&(clearTimeout(n.blurTimer),n.blurTimer=null)},n.clearComboboxTime=function(){n.comboboxTimer&&(clearTimeout(n.comboboxTimer),n.comboboxTimer=null)},n.updateFocusClassName=function(){var e=n.rootRef,t=n.props;n._focused?T()(e).add("".concat(t.prefixCls,"-focused")):T()(e).remove("".concat(t.prefixCls,"-focused"))},n.maybeFocus=function(e,t){if(t||e){var r=n.getInputDOMNode(),i=document,o=i.activeElement;r&&(e||X(n.props))?o!==r&&(r.focus(),n._focused=!0):o!==n.selectionRef&&n.selectionRef&&(n.selectionRef.focus(),n._focused=!0)}},n.removeSelected=function(e,t){var r=n.props;if(!r.disabled&&!n.isChildDisabled(e)){t&&t.stopPropagation&&t.stopPropagation();var i=n.state.value,o=i.filter(function(t){return t!==e}),a=Q(r);if(a){var s=e;r.labelInValue&&(s={key:e,label:n.getLabelBySingleValue(e)}),r.onDeselect&&r.onDeselect(s,n.getOptionBySingleValue(e))}n.fireChange(o)}},n.openIfHasChildren=function(){var e=n.props;(r["Children"].count(e.children)||J(e))&&n.setOpenState(!0)},n.fireSelect=function(e){n.props.onSelect&&n.props.onSelect(n.getVLBySingleValue(e),n.getOptionBySingleValue(e))},n.fireChange=function(e){var t=n.props;"value"in t||n.setState({value:e},n.forcePopupAlign);var r=n.getVLForOnChange(e),i=n.getOptionsBySingleValue(e);t.onChange&&t.onChange(r,Q(n.props)?i:i[0])},n.isChildDisabled=function(e){return D(n.props.children).some(function(t){var n=K(t);return n===e&&t.props&&t.props.disabled})},n.forcePopupAlign=function(){n.state.open&&n.selectTriggerRef&&n.selectTriggerRef.triggerRef&&n.selectTriggerRef.triggerRef.forcePopupAlign()},n.renderFilterOptions=function(){var e=n.state.inputValue,t=n.props,i=t.children,o=t.tags,a=t.notFoundContent,s=[],l=[],c=!1,u=n.renderFilterOptionsFromChildren(i,l,s);if(o){var h=n.state.value;h=h.filter(function(t){return-1===l.indexOf(t)&&(!e||String(t).indexOf(String(e))>-1)}),h.sort(function(e,t){return e.length-t.length}),h.forEach(function(e){var t=e,n=r["createElement"](R["b"],{style:oe,role:"option",attribute:ae,value:t,key:t},t);u.push(n),s.push(n)}),e&&s.every(function(t){return K(t)!==e})&&u.unshift(r["createElement"](R["b"],{style:oe,role:"option",attribute:ae,value:e,key:e},e))}return!u.length&&a&&(c=!0,u=[r["createElement"](R["b"],{style:oe,attribute:ae,disabled:!0,role:"option",value:"NOT_FOUND",key:"NOT_FOUND"},a)]),{empty:c,options:u}},n.renderFilterOptionsFromChildren=function(e,t,i){var o=[],a=n.props,s=n.state.inputValue,l=a.tags;return r["Children"].forEach(e,function(e){if(e){var a=e.type;if(a.isSelectOptGroup){var c=e.props.label,u=e.key;if(u||"string"!==typeof c?!c&&u&&(c=u):u=c,s&&n.filterOption(s,e)){var h=D(e.props.children).map(function(e){var t=K(e)||e.key;return r["createElement"](R["b"],Ie({key:t,value:t},e.props))});o.push(r["createElement"](R["c"],{key:u,title:c},h))}else{var d=n.renderFilterOptionsFromChildren(e.props.children,t,i);d.length&&o.push(r["createElement"](R["c"],{key:u,title:c},d))}}else{F()(a.isSelectOption,"the children of `Select` should be `Select.Option` or `Select.OptGroup`, "+"instead of `".concat(a.name||a.displayName||e.type,"`."));var f=K(e);if(he(f,n.props),n.filterOption(s,e)){var p=r["createElement"](R["b"],Ie({style:oe,attribute:ae,value:f,key:f,role:"option"},e.props));o.push(p),i.push(p)}l&&t.push(f)}}}),o},n.renderTopControlNode=function(){var e=n.state,t=e.open,i=e.inputValue,o=n.state.value,a=n.props,s=a.choiceTransitionName,l=a.prefixCls,c=a.maxTagTextLength,u=a.maxTagCount,h=a.showSearch,d=a.removeIcon,f=a.maxTagPlaceholder,p="".concat(l,"-selection__rendered"),m=null;if(J(a)){var g=null;if(o.length){var v=!1,y=1;h&&t?(v=!i,v&&(y=.4)):v=!0;var b=o[0],w=n.getOptionInfoBySingleValue(b),x=w.label,E=w.title;g=r["createElement"]("div",{key:"value",className:"".concat(l,"-selection-selected-value"),title:z(E||x),style:{display:v?"block":"none",opacity:y}},x)}m=h?[g,r["createElement"]("div",{className:"".concat(l,"-search ").concat(l,"-search--inline"),key:"input",style:{display:t?"block":"none"}},n.getInputElement())]:[g]}else{var C,S=[],k=o;if(void 0!==u&&o.length>u){k=k.slice(0,u);var _=n.getVLForOnChange(o.slice(u,o.length)),O="+ ".concat(o.length-u," ...");f&&(O="function"===typeof f?f(_):f),C=r["createElement"]("li",Ie({style:oe},ae,{role:"presentation",onMouseDown:te,className:"".concat(l,"-selection__choice ").concat(l,"-selection__choice__disabled"),key:"maxTagPlaceholder",title:z(O)}),r["createElement"]("div",{className:"".concat(l,"-selection__choice__content")},O))}Q(a)&&(S=k.map(function(e){var t=n.getOptionInfoBySingleValue(e),i=t.label,o=t.title||i;c&&"string"===typeof i&&i.length>c&&(i="".concat(i.slice(0,c),"..."));var a=n.isChildDisabled(e),s=a?"".concat(l,"-selection__choice ").concat(l,"-selection__choice__disabled"):"".concat(l,"-selection__choice");return r["createElement"]("li",Ie({style:oe},ae,{onMouseDown:te,className:s,role:"presentation",key:e||Ge,title:z(o)}),r["createElement"]("div",{className:"".concat(l,"-selection__choice__content")},i),a?null:r["createElement"]("span",{onClick:function(t){n.removeSelected(e,t)},className:"".concat(l,"-selection__choice__remove")},d||r["createElement"]("i",{className:"".concat(l,"-selection__choice__remove-icon")},"\xd7")))})),C&&S.push(C),S.push(r["createElement"]("li",{className:"".concat(l,"-search ").concat(l,"-search--inline"),key:"__input"},n.getInputElement())),m=Q(a)&&s?r["createElement"](P["a"],{onLeave:n.onChoiceAnimationLeave,component:"ul",transitionName:s},S):r["createElement"]("ul",null,S)}return r["createElement"]("div",{className:p,ref:n.saveTopCtrlRef},n.getPlaceholderElement(),m)};var i=t.getOptionsInfoFromProps(e);if(e.tags&&"function"!==typeof e.filterOption){var o=Object.keys(i).some(function(e){return i[e].disabled});F()(!o,"Please avoid setting option to disabled in tags mode since user can always type text as tag.")}return n.state={value:t.getValueFromProps(e,!0),inputValue:e.combobox?t.getInputValueForCombobox(e,i,!0):"",open:e.defaultOpen,optionsInfo:i,backfillValue:"",skipBuildOptionsInfo:!0,ariaId:""},n.saveInputRef=de(Ue(n),"inputRef"),n.saveInputMirrorRef=de(Ue(n),"inputMirrorRef"),n.saveTopCtrlRef=de(Ue(n),"topCtrlRef"),n.saveSelectTriggerRef=de(Ue(n),"selectTriggerRef"),n.saveRootRef=de(Ue(n),"rootRef"),n.saveSelectionRef=de(Ue(n),"selectionRef"),n}return ze(t,e),Be(t,[{key:"componentDidMount",value:function(){(this.props.autoFocus||this.state.open)&&this.focus(),this.setState({ariaId:fe()})}},{key:"componentDidUpdate",value:function(){if(Q(this.props)){var e=this.getInputDOMNode(),t=this.getInputMirrorDOMNode();e&&e.value&&t?(e.style.width="",e.style.width="".concat(t.clientWidth,"px")):e&&(e.style.width="")}this.forcePopupAlign()}},{key:"componentWillUnmount",value:function(){this.clearFocusTime(),this.clearBlurTime(),this.clearComboboxTime(),this.dropdownContainer&&(j["unmountComponentAtNode"](this.dropdownContainer),document.body.removeChild(this.dropdownContainer),this.dropdownContainer=null)}},{key:"focus",value:function(){J(this.props)&&this.selectionRef?this.selectionRef.focus():this.getInputDOMNode()&&this.getInputDOMNode().focus()}},{key:"blur",value:function(){J(this.props)&&this.selectionRef?this.selectionRef.blur():this.getInputDOMNode()&&this.getInputDOMNode().blur()}},{key:"renderArrow",value:function(e){var t=this.props,n=t.showArrow,i=void 0===n?!e:n,o=t.loading,a=t.inputIcon,s=t.prefixCls;if(!i&&!o)return null;var l=o?r["createElement"]("i",{className:"".concat(s,"-arrow-loading")}):r["createElement"]("i",{className:"".concat(s,"-arrow-icon")});return r["createElement"]("span",Ie({key:"arrow",className:"".concat(s,"-arrow"),style:oe},ae,{onClick:this.onArrowClick}),a||l)}},{key:"renderClear",value:function(){var e=this.props,t=e.prefixCls,n=e.allowClear,i=e.clearIcon,o=this.state.inputValue,a=this.state.value,s=r["createElement"]("span",Ie({key:"clear",className:"".concat(t,"-selection__clear"),onMouseDown:te,style:oe},ae,{onClick:this.onClearSelection}),i||r["createElement"]("i",{className:"".concat(t,"-selection__clear-icon")},"\xd7"));return n?Y(this.props)?o?s:null:o||a.length?s:null:null}},{key:"render",value:function(){var e,t=this.props,n=Q(t),i=t.showArrow,o=void 0===i||i,a=this.state,s=t.className,l=t.disabled,c=t.prefixCls,u=t.loading,h=this.renderTopControlNode(),d=this.state,f=d.open,p=d.ariaId;if(f){var m=this.renderFilterOptions();this._empty=m.empty,this._options=m.options}var g=this.getRealOpenState(),v=this._empty,y=this._options||[],b={};Object.keys(t).forEach(function(e){!Object.prototype.hasOwnProperty.call(t,e)||"data-"!==e.substr(0,5)&&"aria-"!==e.substr(0,5)&&"role"!==e||(b[e]=t[e])});var w=Ie({},b);X(t)||(w=Ie(Ie({},w),{onKeyDown:this.onKeyDown,tabIndex:t.disabled?-1:t.tabIndex}));var x=(e={},$e(e,s,!!s),$e(e,c,1),$e(e,"".concat(c,"-open"),f),$e(e,"".concat(c,"-focused"),f||!!this._focused),$e(e,"".concat(c,"-combobox"),Y(t)),$e(e,"".concat(c,"-disabled"),l),$e(e,"".concat(c,"-enabled"),!l),$e(e,"".concat(c,"-allow-clear"),!!t.allowClear),$e(e,"".concat(c,"-no-arrow"),!o),$e(e,"".concat(c,"-loading"),!!u),e);return r["createElement"](je,{onPopupFocus:this.onPopupFocus,onMouseEnter:this.props.onMouseEnter,onMouseLeave:this.props.onMouseLeave,dropdownAlign:t.dropdownAlign,dropdownClassName:t.dropdownClassName,dropdownMatchSelectWidth:t.dropdownMatchSelectWidth,defaultActiveFirstOption:t.defaultActiveFirstOption,dropdownMenuStyle:t.dropdownMenuStyle,transitionName:t.transitionName,animation:t.animation,prefixCls:t.prefixCls,dropdownStyle:t.dropdownStyle,combobox:t.combobox,showSearch:t.showSearch,options:y,empty:v,multiple:n,disabled:l,visible:g,inputValue:a.inputValue,value:a.value,backfillValue:a.backfillValue,firstActiveValue:t.firstActiveValue,onDropdownVisibleChange:this.onDropdownVisibleChange,getPopupContainer:t.getPopupContainer,onMenuSelect:this.onMenuSelect,onMenuDeselect:this.onMenuDeselect,onPopupScroll:t.onPopupScroll,showAction:t.showAction,ref:this.saveSelectTriggerRef,menuItemSelectedIcon:t.menuItemSelectedIcon,dropdownRender:t.dropdownRender,ariaId:p},r["createElement"]("div",{id:t.id,style:t.style,ref:this.saveRootRef,onBlur:this.onOuterBlur,onFocus:this.onOuterFocus,className:A()(x),onMouseDown:this.markMouseDown,onMouseUp:this.markMouseLeave,onMouseOut:this.markMouseLeave},r["createElement"]("div",Ie({ref:this.saveSelectionRef,key:"selection",className:"".concat(c,"-selection\n ").concat(c,"-selection--").concat(n?"multiple":"single"),role:"combobox","aria-autocomplete":"list","aria-haspopup":"true","aria-controls":p,"aria-expanded":g},w),h,this.renderClear(),this.renderArrow(!!n))))}}]),t}(r["Component"]);Xe.propTypes=_,Xe.defaultProps={prefixCls:"rc-select",defaultOpen:!1,labelInValue:!1,defaultActiveFirstOption:!0,showSearch:!0,allowClear:!1,placeholder:"",onChange:Ye,onFocus:Ye,onBlur:Ye,onSelect:Ye,onSearch:Ye,onDeselect:Ye,onInputKeyDown:Ye,dropdownMatchSelectWidth:!0,dropdownStyle:{},dropdownMenuStyle:{},optionFilterProp:"value",optionLabelProp:"value",notFoundContent:"Not Found",backfill:!1,showAction:["click"],tokenSeparators:[],autoClearSearchValue:!0,tabIndex:0,dropdownRender:function(e){return e}},Xe.getDerivedStateFromProps=function(e,t){var n=t.skipBuildOptionsInfo?t.optionsInfo:Xe.getOptionsInfoFromProps(e,t),r={optionsInfo:n,skipBuildOptionsInfo:!1};if("open"in e&&(r.open=e.open),e.disabled&&t.open&&(r.open=!1),"value"in e){var i=Xe.getValueFromProps(e);r.value=i,e.combobox&&(r.inputValue=Xe.getInputValueForCombobox(e,n))}return r},Xe.getOptionsFromChildren=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return r["Children"].forEach(e,function(e){if(e){var n=e.type;n.isSelectOptGroup?Xe.getOptionsFromChildren(e.props.children,t):t.push(e)}}),t},Xe.getInputValueForCombobox=function(e,t,n){var r=[];if("value"in e&&!n&&(r=Z(e.value)),"defaultValue"in e&&n&&(r=Z(e.defaultValue)),!r.length)return"";r=r[0];var i=r;return e.labelInValue?i=r.label:t[ee(r)]&&(i=t[ee(r)].label),void 0===i&&(i=""),i},Xe.getLabelFromOption=function(e,t){return q(t,e.optionLabelProp)},Xe.getOptionsInfoFromProps=function(e,t){var n=Xe.getOptionsFromChildren(e.children),r={};if(n.forEach(function(t){var n=K(t);r[ee(n)]={option:t,value:n,label:Xe.getLabelFromOption(e,t),title:t.props.title,disabled:t.props.disabled}}),t){var i=t.optionsInfo,o=t.value;o&&o.forEach(function(e){var t=ee(e);r[t]||void 0===i[t]||(r[t]=i[t])})}return r},Xe.getValueFromProps=function(e,t){var n=[];return"value"in e&&!t&&(n=Z(e.value)),"defaultValue"in e&&t&&(n=Z(e.defaultValue)),e.labelInValue&&(n=n.map(function(e){return e.key})),n},Xe.displayName="Select",Object($["polyfill"])(Xe);var Je=Xe;n.d(t,"b",function(){return b}),n.d(t,"a",function(){return h}),Je.Option=b,Je.OptGroup=h;t["c"]=Je},Lnex:function(e,t,n){var r=n("OeOC"),i=n("OsVd"),o=n("Spc3");e.exports=function(e){return function(t,n,a){var s,l=r(t),c=i(l.length),u=o(a,c);if(e&&n!=n){while(c>u)if(s=l[u++],s!=s)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}}},LpSC:function(e,t,n){n("bZMm"),e.exports=self.fetch.bind(self)},LsAW:function(e,t){t.f={}.propertyIsEnumerable},M1xp:function(e,t,n){var r=n("a0xu");e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},MFj2:function(e,t,n){"use strict";var r=n("QbLZ"),i=n.n(r),o=n("YEIV"),a=n.n(o),s=n("iCc5"),l=n.n(s),c=n("V7oC"),u=n.n(c),h=n("FYw3"),d=n.n(h),f=n("mRg0"),p=n.n(f),m=n("q1tI"),g=n.n(m),v=n("17x9"),y=n.n(v),b=function(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");return"function"!==typeof t.componentWillReceiveProps?e:g.a.Profiler?(t.UNSAFE_componentWillReceiveProps=t.componentWillReceiveProps,delete t.componentWillReceiveProps,e):e},w=b;function x(e){var t=[];return g.a.Children.forEach(e,function(e){t.push(e)}),t}function E(e,t){var n=null;return e&&e.forEach(function(e){n||e&&e.key===t&&(n=e)}),n}function C(e,t,n){var r=null;return e&&e.forEach(function(e){if(e&&e.key===t&&e.props[n]){if(r)throw new Error("two child with same key for children");r=e}}),r}function S(e,t,n){var r=e.length===t.length;return r&&e.forEach(function(e,i){var o=t[i];e&&o&&(e&&!o||!e&&o?r=!1:e.key!==o.key?r=!1:n&&e.props[n]!==o.props[n]&&(r=!1))}),r}function k(e,t){var n=[],r={},i=[];return e.forEach(function(e){e&&E(t,e.key)?i.length&&(r[e.key]=i,i=[]):i.push(e)}),t.forEach(function(e){e&&Object.prototype.hasOwnProperty.call(r,e.key)&&(n=n.concat(r[e.key])),n.push(e)}),n=n.concat(i),n}var _=n("i8i4"),O=n.n(_),A=n("EJiy"),M=n.n(A),T=n("/dDc"),P=n("PFWz"),R=n.n(P),L=0!==T["a"].endEvents.length,D=["Webkit","Moz","O","ms"],N=["-webkit-","-moz-","-o-","ms-",""];function j(e,t){for(var n=window.getComputedStyle(e,null),r="",i=0;i children");return g.a.createElement(z,{key:n.key,ref:function(t){e.childrenRefs[n.key]=t},animation:t.animation,transitionName:t.transitionName,transitionEnter:t.transitionEnter,transitionAppear:t.transitionAppear,transitionLeave:t.transitionLeave},n)}));var o=t.component;if(o){var a=t;return"string"===typeof o&&(a=i()({className:t.className,style:t.style},t.componentProps)),g.a.createElement(o,a,r)}return r[0]||null}}]),t}(g.a.Component);Y.isAnimate=!0,Y.propTypes={className:y.a.string,style:y.a.object,component:y.a.any,componentProps:y.a.object,animation:y.a.object,transitionName:y.a.oneOfType([y.a.string,y.a.object]),transitionEnter:y.a.bool,transitionAppear:y.a.bool,exclusive:y.a.bool,transitionLeave:y.a.bool,onEnd:y.a.func,onEnter:y.a.func,onLeave:y.a.func,onAppear:y.a.func,showProp:y.a.string,children:y.a.node},Y.defaultProps={animation:{},component:"span",componentProps:{},transitionEnter:!0,transitionLeave:!0,transitionAppear:!1,onEnd:G,onEnter:G,onLeave:G,onAppear:G};var Q=function(){var e=this;this.performEnter=function(t){e.childrenRefs[t]&&(e.currentlyAnimatingKeys[t]=!0,e.childrenRefs[t].componentWillEnter(e.handleDoneAdding.bind(e,t,"enter")))},this.performAppear=function(t){e.childrenRefs[t]&&(e.currentlyAnimatingKeys[t]=!0,e.childrenRefs[t].componentWillAppear(e.handleDoneAdding.bind(e,t,"appear")))},this.handleDoneAdding=function(t,n){var r=e.props;if(delete e.currentlyAnimatingKeys[t],!r.exclusive||r===e.nextProps){var i=x(q(r));e.isValidChildByKey(i,t)?"appear"===n?W.allowAppearCallback(r)&&(r.onAppear(t),r.onEnd(t,!0)):W.allowEnterCallback(r)&&(r.onEnter(t),r.onEnd(t,!0)):e.performLeave(t)}},this.performLeave=function(t){e.childrenRefs[t]&&(e.currentlyAnimatingKeys[t]=!0,e.childrenRefs[t].componentWillLeave(e.handleDoneLeaving.bind(e,t)))},this.handleDoneLeaving=function(t){var n=e.props;if(delete e.currentlyAnimatingKeys[t],!n.exclusive||n===e.nextProps){var r=x(q(n));if(e.isValidChildByKey(r,t))e.performEnter(t);else{var i=function(){W.allowLeaveCallback(n)&&(n.onLeave(t),n.onEnd(t,!1))};S(e.state.children,r,n.showProp)?i():e.setState({children:r},i)}}}};t["a"]=w(Y)},MPFp:function(e,t,n){"use strict";var r=n("uOPS"),i=n("Y7ZC"),o=n("kTiW"),a=n("NegM"),s=n("SBuE"),l=n("j2DC"),c=n("RfKB"),u=n("U+KD"),h=n("UWiX")("iterator"),d=!([].keys&&"next"in[].keys()),f="@@iterator",p="keys",m="values",g=function(){return this};e.exports=function(e,t,n,v,y,b,w){l(n,t,v);var x,E,C,S=function(e){if(!d&&e in A)return A[e];switch(e){case p:return function(){return new n(this,e)};case m:return function(){return new n(this,e)}}return function(){return new n(this,e)}},k=t+" Iterator",_=y==m,O=!1,A=e.prototype,M=A[h]||A[f]||y&&A[y],T=M||S(y),P=y?_?S("entries"):T:void 0,R="Array"==t&&A.entries||M;if(R&&(C=u(R.call(new e)),C!==Object.prototype&&C.next&&(c(C,k,!0),r||"function"==typeof C[h]||a(C,h,g))),_&&M&&M.name!==m&&(O=!0,T=function(){return M.call(this)}),r&&!w||!d&&!O&&A[h]||a(A,h,T),s[t]=T,s[k]=g,y)if(x={values:_?T:S(m),keys:b?T:S(p),entries:P},w)for(E in x)E in A||o(A,E,x[E]);else i(i.P+i.F*(d||O),t,x);return x}},MWgS:function(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}n.d(t,"a",function(){return r})},MgzW:function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function s(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(t).map(function(e){return t[e]});if("0123456789"!==r.join(""))return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach(function(e){i[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},i)).join("")}catch(e){return!1}}e.exports=s()?Object.assign:function(e,t){for(var n,s,l=a(e),c=1;c=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function i(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function a(e){for(var t=1;t1&&0===n&&i&&"auto"!==i?parseInt(i.toString(),10):i},m);return u.createElement(h,Object.assign({},p,{style:g}),t.map(function(e,t){var n,i=e.column,o=e.isLast,l=r(e,["column","isLast"]),h=i.onHeaderCell?i.onHeaderCell(i):{};return i.align&&(h.style=a({},h.style,{textAlign:i.align})),h.className=d.default(h.className,i.className,(n={},s(n,"".concat(c,"-align-").concat(i.align),!!i.align),s(n,"".concat(c,"-row-cell-ellipsis"),!!i.ellipsis),s(n,"".concat(c,"-row-cell-break-word"),!!i.width),s(n,"".concat(c,"-row-cell-last"),o),n)),u.createElement(f,Object.assign({},l,h,{key:i.key||i.dataIndex||t}))}))}function p(e,t){var n=e.fixedColumnsHeadRowsHeight,r=t.columns,i=t.rows,o=t.fixed,a=n[0];return o&&a&&r?"auto"===a?"auto":a/i.length:null}t.default=h.connect(function(e,t){return{height:p(e,t)}})(f)},MvwC:function(e,t,n){var r=n("5T2Y").document;e.exports=r&&r.documentElement},N2Kk:function(e,t,n){"use strict";t["a"]={items_per_page:"\u6761/\u9875",jump_to:"\u8df3\u81f3",jump_to_confirm:"\u786e\u5b9a",page:"\u9875",prev_page:"\u4e0a\u4e00\u9875",next_page:"\u4e0b\u4e00\u9875",prev_5:"\u5411\u524d 5 \u9875",next_5:"\u5411\u540e 5 \u9875",prev_3:"\u5411\u524d 3 \u9875",next_3:"\u5411\u540e 3 \u9875"}},N4uP:function(e,t,n){var r=n("c0Oy"),i=n("WGNW"),o=n("08Qx"),a=[].slice,s=/MSIE .\./.test(o),l=function(e){return function(t,n){var r=arguments.length>2,i=!!r&&a.call(arguments,2);return e(r?function(){("function"==typeof t?t:Function(t)).apply(this,i)}:t,n)}};i(i.G+i.B+i.F*s,{setTimeout:l(r.setTimeout),setInterval:l(r.setInterval)})},N9RS:function(e,t,n){"use strict";n.r(t);var r=n("d6i3"),i=n.n(r),o=n("p0pE"),a=n.n(o),s=n("t3Un"),l=(n("tI4l"),{payments:[],fetchLoading:!1});t["default"]={name:"payment",state:a()({},l),reducers:{setState(e,t){var n=t.payload;return a()({},e,n)}},effects:{fetch(e,t){return i.a.mark(function e(){var n,r;return i.a.wrap(function(e){while(1)switch(e.prev=e.next){case 0:return n=t.put,e.next=3,n({type:"setState",payload:{fetchLoading:!0}});case 3:return e.next=5,Object(s["a"])("/admin/payment/fetch");case 5:return r=e.sent,e.next=8,n({type:"setState",payload:{fetchLoading:!1}});case 8:if(200===r.code){e.next=10;break}return e.abrupt("return");case 10:return e.next=12,n({type:"setState",payload:{payments:r.data}});case 12:case"end":return e.stop()}},e)})()},getPaymentMethods(e){return i.a.mark(function t(){var n,r;return i.a.wrap(function(t){while(1)switch(t.prev=t.next){case 0:return n=e.complete,t.next=3,Object(s["a"])("/admin/payment/getPaymentMethods");case 3:if(r=t.sent,200===r.code){t.next=6;break}return t.abrupt("return");case 6:n(r.data);case 7:case"end":return t.stop()}},t)})()},getPaymentForm(e){return i.a.mark(function t(){var n,r,o,a;return i.a.wrap(function(t){while(1)switch(t.prev=t.next){case 0:return n=e.complete,r=e.payment,o=e.id,t.next=3,Object(s["b"])("/admin/payment/getPaymentForm",{payment:r,id:o});case 3:if(a=t.sent,200===a.code){t.next=6;break}return t.abrupt("return");case 6:n(a.data);case 7:case"end":return t.stop()}},t)})()},save(e,t){return i.a.mark(function n(){var r,o,l,c;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.params,o=e.complete,l=t.put,n.next=4,Object(s["b"])("/admin/payment/save",a()({},r));case 4:if(c=n.sent,200===c.code){n.next=7;break}return n.abrupt("return");case 7:return"function"===typeof o&&o(c.data),n.next=10,l({type:"fetch"});case 10:case"end":return n.stop()}},n)})()},drop(e,t){return i.a.mark(function n(){var r,o,a;return i.a.wrap(function(n){while(1)switch(n.prev=n.next){case 0:return r=e.id,o=t.put,n.next=4,Object(s["b"])("/admin/payment/drop",{id:r});case 4:if(a=n.sent,200===a.code){n.next=7;break}return n.abrupt("return");case 7:return n.next=9,o({type:"fetch"});case 9:case"end":return n.stop()}},n)})()}}}},NV0k:function(e,t){t.f={}.propertyIsEnumerable},NaAv:function(e,t){e.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},NegM:function(e,t,n){var r=n("2faE"),i=n("rr1i");e.exports=n("jmDH")?function(e,t,n){return r.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},NohK:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t["default"]=void 0;var r=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:60,n=null;return function(){for(var r=this,i=arguments.length,o=new Array(i),a=0;a0?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(i(this,o),e);return t&&t.v},set:function(e,t){return r.def(i(this,o),0===e?0:e,t)}},r,!0)},OERk:function(e,t,n){"use strict";var r=n("DIcO"),i=n("48Dx"),o=n("yw4e"),a=n("OeOC");e.exports=n("XdPT")(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,i(1)):i(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])},"values"),o.Arguments=o.Array,r("keys"),r("values"),r("entries")},OHgp:function(e,t,n){"use strict";var r=n("2a/h"),i={};i[n("gL7N")("toStringTag")]="z",i+""!="[object z]"&&n("rKIl")(Object.prototype,"toString",function(){return"[object "+r(this)+"]"},!0)},OJuA:function(e,t,n){"use strict";e.exports=n("FqPH")||!n("wUWy")(function(){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete n("c0Oy")[e]})},OLES:function(e,t,n){"use strict";var r=n("QbLZ"),i=n.n(r),o=n("jo6Y"),a=n.n(o),s=n("iCc5"),l=n.n(s),c=n("FYw3"),u=n.n(c),h=n("mRg0"),d=n.n(h),f=n("q1tI"),p=n.n(f),m=n("17x9"),g=n.n(m),v=n("uciX"),y=n("7ixt"),b=function(e){function t(){return l()(this,t),u()(this,e.apply(this,arguments))}return d()(t,e),t.prototype.componentDidUpdate=function(){var e=this.props.trigger;e&&e.forcePopupAlign()},t.prototype.render=function(){var e=this.props,t=e.overlay,n=e.prefixCls,r=e.id;return p.a.createElement("div",{className:n+"-inner",id:r,role:"tooltip"},"function"===typeof t?t():t)},t}(p.a.Component);b.propTypes={prefixCls:g.a.string,overlay:g.a.oneOfType([g.a.node,g.a.func]).isRequired,id:g.a.string,trigger:g.a.any};var w=b,x=function(e){function t(){var n,r,i;l()(this,t);for(var o=arguments.length,a=Array(o),s=0;s0?r:n)(e)}},OsVd:function(e,t,n){var r=n("AUWw"),i=Math.min;e.exports=function(e){return e>0?i(r(e),9007199254740991):0}},P2sY:function(e,t,n){e.exports={default:n("UbbE"),__esModule:!0}},P4Qj:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeSensor=t.getSensor=void 0;var r=a(n("chpo")),i=n("FxDU"),o=n("24YM");function a(e){return e&&e.__esModule?e:{default:e}}var s={},l=function(e){var t=e.getAttribute(o.SizeSensorId);if(t&&s[t])return s[t];var n=(0,r["default"])();e.setAttribute(o.SizeSensorId,n);var a=(0,i.createSensor)(e);return s[n]=a,a};t.getSensor=l;var c=function(e){var t=e.element.getAttribute(o.SizeSensorId);e.element.removeAttribute(o.SizeSensorId),e.destroy(),t&&s[t]&&delete s[t]};t.removeSensor=c},PFWz:function(e,t,n){try{var r=n("zs13")}catch(e){r=n("zs13")}var i=/\s+/,o=Object.prototype.toString;function a(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}e.exports=function(e){return new a(e)},a.prototype.add=function(e){if(this.list)return this.list.add(e),this;var t=this.array(),n=r(t,e);return~n||t.push(e),this.el.className=t.join(" "),this},a.prototype.remove=function(e){if("[object RegExp]"==o.call(e))return this.removeMatching(e);if(this.list)return this.list.remove(e),this;var t=this.array(),n=r(t,e);return~n&&t.splice(n,1),this.el.className=t.join(" "),this},a.prototype.removeMatching=function(e){for(var t=this.array(),n=0;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n4&&void 0!==arguments[4]&&arguments[4];n&&n.stopPropagation();var a=r.props,l=a.onExpandedRowsChange,c=a.onExpand,u=r.store.getState(),h=u.expandedRowKeys;if(e)h=[].concat(s(h),[i]);else{var d=h.indexOf(i);-1!==d&&(h=T.remove(h,i))}r.props.expandedRowKeys||r.store.setState({expandedRowKeys:h}),r.latestExpandedRows&&A.default(r.latestExpandedRows,h)||(r.latestExpandedRows=h,l(h)),o||c(e,t)},r.renderExpandIndentCell=function(e,t){var n=r.props,i=n.prefixCls,a=n.expandIconAsCell;if(a&&"right"!==t&&e.length){var s={key:"rc-table-expand-icon-cell",className:"".concat(i,"-expand-icon-th"),title:"",rowSpan:e.length};e[0].unshift(o({},s,{column:s}))}},r.renderRows=function(e,t,n,i,o,a,l,c){var u=r.props,h=u.expandedRowClassName,d=u.expandedRowRender,f=u.childrenColumnName,p=n[f],m=[].concat(s(c),[l]),g=o+1;d&&t.push(r.renderExpandedRow(n,i,d,h(n,i,o),m,g,a)),p&&t.push.apply(t,s(e(p,g,m)))};var i=e.data,a=e.childrenColumnName,l=e.defaultExpandAllRows,c=e.expandedRowKeys,u=e.defaultExpandedRowKeys,h=e.getRowKey,d=[],p=s(i);if(l)for(var m=0;m{this.state.visible||this.setState({submit:this.defaultValue})})}generate(){var e=g()({},this.state.submit);this.props.dispatch({type:"coupon/generate",params:e,callback:()=>{this.modalVisible()}})}drop(e){this.props.dispatch({type:"coupon/drop",id:e.id})}tableOnChange(e,t){this.props.dispatch({type:"coupon/changeTable",pagination:e,sort:{sort_type:"ascend"===t.order?"ASC":"DESC",sort:t.columnKey}})}render(){var e=this.props.coupon,t=e.coupons,n=e.fetchLoading,r=e.saveLoading,m=e.pagination,v=this.props.plan.plans,w=[{title:"#",dataIndex:"id",key:"id"},{title:"\u5238\u540d\u79f0",dataIndex:"name",key:"name"},{title:"\u7c7b\u578b",dataIndex:"type",key:"type",render:e=>{return 1===e?"\u91d1\u989d":"\u6bd4\u4f8b"}},{title:"\u5238\u7801",dataIndex:"code",key:"code",render:e=>{return y.a.createElement(f["a"],{style:{cursor:"pointer"},onClick:()=>{C()(e),p["a"].success("\u590d\u5236\u6210\u529f")}},e)}},{title:"\u5269\u4f59\u6b21\u6570",dataIndex:"limit_use",key:"limit_use",render:e=>{return y.a.createElement(f["a"],null,null!==e?e:"\u65e0\u9650")}},{title:"\u6709\u6548\u671f",dataIndex:"started_at",key:"started_at",align:"left",render:(e,t)=>{return"".concat(x()(1e3*t.started_at).format("YYYY/MM/DD HH:mm")," ~ ").concat(x()(1e3*t.ended_at).format("YYYY/MM/DD HH:mm"))}},{title:"\u64cd\u4f5c",dataIndex:"action",key:"action",align:"right",render:(e,n,r)=>{return y.a.createElement("div",null,y.a.createElement("a",{onClick:()=>{this.setState({submit:t[r]},()=>{this.modalVisible()})},href:"javascript:void(0);"},"\u7f16\u8f91"),y.a.createElement(d["a"],{type:"vertical"}),y.a.createElement("a",{onClick:()=>this.drop(n),href:"javascript:void(0);"},"\u5220\u9664"))}}];return y.a.createElement(b["a"],i()({},this.props,{title:"\u4f18\u60e0\u5238\u7ba1\u7406"}),y.a.createElement("div",{className:"mb-0 block border-bottom ".concat(n?"block-mode-loading":"")},y.a.createElement("div",{className:"bg-white"},y.a.createElement("div",{style:{padding:15}},y.a.createElement(u["a"],{onClick:()=>this.modalVisible()},y.a.createElement(h["a"],{type:"plus"})," \u6dfb\u52a0\u4f18\u60e0\u5238")),y.a.createElement(c["a"],{tableLayout:"auto",dataSource:t,columns:w,scroll:{x:1050},pagination:g()({},m,{size:"small",showSizeChanger:!0,pageSizeOptions:[10,50,100,150]}),onChange:(e,t,n)=>this.tableOnChange(e,n)}))),y.a.createElement(o["a"],{title:"".concat(this.state.submit.id?"\u7f16\u8f91\u4f18\u60e0\u5238":"\u65b0\u5efa\u4f18\u60e0\u5238"),visible:this.state.visible,onCancel:()=>this.modalVisible(),onOk:()=>this.generate(),okText:"\u63d0\u4ea4",cancelText:"\u53d6\u6d88",okButtonProps:{loading:r},key:this.key},y.a.createElement("div",null,y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{for:"example-text-input-alt"},"\u540d\u79f0"),y.a.createElement(l["a"],{placeholder:"\u8bf7\u8f93\u5165\u4f18\u60e0\u5238\u540d\u79f0",value:this.state.submit.name,onChange:e=>{this.setState({submit:g()({},this.state.submit,{name:e.target.value})})}})),!this.state.submit.generate_count&&y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{for:"example-text-input-alt"},"\u81ea\u5b9a\u4e49\u4f18\u60e0\u5238\u7801"),y.a.createElement(l["a"],{placeholder:"\u81ea\u5b9a\u4e49\u4f18\u60e0\u5238\u7801(\u7559\u7a7a\u968f\u673a\u751f\u6210)",value:this.state.submit.code,onChange:e=>{this.setState({submit:g()({},this.state.submit,{code:e.target.value,generate_count:void 0})})}})),y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{for:"example-text-input-alt"},"\u4f18\u60e0\u4fe1\u606f"),y.a.createElement(l["a"],{type:"number",addonBefore:y.a.createElement(s["a"],{style:{width:120},value:this.state.submit.type,onChange:e=>{this.setState({submit:g()({},this.state.submit,{type:e})})}},y.a.createElement(s["a"].Option,{value:1},"\u6309\u91d1\u989d\u4f18\u60e0"),y.a.createElement(s["a"].Option,{value:2},"\u6309\u6bd4\u4f8b\u4f18\u60e0")),addonAfter:1===this.state.submit.type?"\xa5":"%",placeholder:"\u8bf7\u8f93\u5165\u503c",value:this.state.submit.value,onChange:e=>{this.setState({submit:g()({},this.state.submit,{value:e.target.value})})}})),y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{for:"example-text-input-alt"},"\u4f18\u60e0\u5238\u6709\u6548\u671f"),y.a.createElement(a["a"].RangePicker,{style:{width:"100%"},showTime:{format:"HH:mm"},format:"YYYY-MM-DD HH:mm",placeholder:["Start Time","End Time"],value:[this.state.submit.started_at?x()(1e3*this.state.submit.started_at):null,this.state.submit.ended_at?x()(1e3*this.state.submit.ended_at):null],onChange:e=>this.setState({submit:g()({},this.state.submit,{started_at:e[0]?e[0].format("X"):null,ended_at:e[1]?e[1].format("X"):null})}),onOk:e=>this.setState({submit:g()({},this.state.submit,{started_at:e[0]?e[0].format("X"):null,ended_at:e[1]?e[1].format("X"):null})})})),y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{for:"example-text-input-alt"},"\u4f7f\u7528\u6b21\u6570"),y.a.createElement(l["a"],{placeholder:"\u9650\u5236\u4f7f\u7528\u6b21\u6570\uff0c\u7528\u5b8c\u5219\u65e0\u6cd5\u4f7f\u7528(\u4e3a\u7a7a\u5219\u4e0d\u9650\u5236)",value:this.state.submit.limit_use,onChange:e=>{this.setState({submit:g()({},this.state.submit,{limit_use:e.target.value})})}})),y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{for:"example-text-input-alt"},"\u6307\u5b9a\u8ba2\u9605"),y.a.createElement("div",null,y.a.createElement(s["a"],{value:this.state.submit.limit_plan_ids||[],onChange:e=>{this.setState({submit:g()({},this.state.submit,{limit_plan_ids:e.length?e:null})})},mode:"multiple",placeholder:"\u9650\u5236\u6307\u5b9a\u8ba2\u9605\u53ef\u4ee5\u4f7f\u7528\u4f18\u60e0(\u4e3a\u7a7a\u5219\u4e0d\u9650\u5236)",style:{width:"100%"}},v.map(e=>{return y.a.createElement(s["a"].Option,{key:Math.random(),value:"".concat(e.id)},e.name)})))),!this.state.submit.code&&!this.state.submit.id&&y.a.createElement("div",{className:"form-group"},y.a.createElement("label",{htmlFor:"example-text-input-alt"},"\u751f\u6210\u6570\u91cf"),y.a.createElement(l["a"],{placeholder:"\u8f93\u5165\u6570\u91cf\u6279\u91cf\u751f\u6210",value:this.state.submit.generate_count,onChange:e=>{this.setState({submit:g()({},this.state.submit,{generate_count:e.target.value,code:void 0})})}})))))}}t["default"]=Object(S["c"])(e=>{var t=e.coupon,n=e.plan;return{coupon:t,plan:n}})(k)},Q6cQ:function(e,t,n){"use strict";var r=n("u8+u"),i=n("BFt8"),o=n("gL7N")("hasInstance"),a=Function.prototype;o in a||n("V5/1").f(a,o,{value:function(e){if("function"!=typeof this||!r(e))return!1;if(!r(this.prototype))return e instanceof this;while(e=i(e))if(this.prototype===e)return!0;return!1}})},"QC+M":function(e,t,n){"use strict";n.d(t,"a",function(){return w});var r=n("q1tI"),i=n.n(r),o=n("i8i4"),a=n.n(o),s=n("17x9"),l=n.n(s);function c(e){"@babel/helpers - typeof";return c="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t){for(var n=0;nc)l.call(e,a=s[c++])&&t.push(a)}return t}},"R64+":function(e,t,n){"use strict";t.__esModule=!0;var r=n("GB+t"),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}var a=function(){var e=null,t=function(t){return(0,i.default)(null==e,"A history supports only one prompt at a time"),e=t,function(){e===t&&(e=null)}},n=function(t,n,r,o){if(null!=e){var a="function"===typeof e?e(t,n):e;"string"===typeof a?"function"===typeof r?r(a,o):((0,i.default)(!1,"A history needs a getUserConfirmation function in order to use a prompt message"),o(!0)):o(!1!==a)}else o(!0)},r=[],o=function(e){var t=!0,n=function(){t&&e.apply(void 0,arguments)};return r.push(n),function(){t=!1,r=r.filter(function(e){return e!==n})}},a=function(){for(var e=arguments.length,t=Array(e),n=0;n{return h[e]}},{title:"\u5de5\u5355\u72b6\u6001",dataIndex:"reply_status",key:"reply_status",render:(e,t)=>{return 1===t.status?d.a.createElement("span",null,d.a.createElement(u["a"],{status:"success"}),"\u5df2\u5173\u95ed"):d.a.createElement("span",null,d.a.createElement(u["a"],{status:e?"error":"processing"}),e?"\u5f85\u56de\u590d":"\u5df2\u56de\u590d")}},{title:"\u521b\u5efa\u65f6\u95f4",dataIndex:"created_at",key:"created_at",render:e=>{return g()(1e3*e).format("YYYY/MM/DD HH:mm")}},{title:"\u6700\u540e\u56de\u590d",dataIndex:"updated_at",key:"updated_at",render:e=>{return g()(1e3*e).format("YYYY/MM/DD HH:mm")}},{title:"\u64cd\u4f5c",dataIndex:"action",key:"action",align:"right",render:(e,t)=>{return d.a.createElement("div",null,d.a.createElement("a",{href:"javascript:void(0);",onClick:()=>this.toChat(t.id)},"\u67e5\u770b"),d.a.createElement(c["a"],{type:"vertical"}),d.a.createElement("a",{disabled:t.status,href:"javascript:void(0);",onClick:()=>this.close(t.id)},"\u5173\u95ed"))}}];return d.a.createElement(f["a"],i()({},this.props,{title:"\u5de5\u5355\u7ba1\u7406"}),d.a.createElement("div",{className:"mb-0 block border-bottom ".concat(n?"block-mode-loading":"")},d.a.createElement("div",{className:"bg-white"},d.a.createElement("div",{className:"p-3"},d.a.createElement(l["a"].Group,{value:a.status,onChange:e=>this.filter(e.target.value)},d.a.createElement(l["a"].Button,{value:0},"\u5df2\u5f00\u542f"),d.a.createElement(l["a"].Button,{value:1},"\u5df2\u5173\u95ed"))),d.a.createElement(o["a"],{tableLayout:"auto",dataSource:t,pagination:s()({},r,{size:"small"}),columns:p,scroll:{x:900},onChange:(e,t,n)=>this.tableOnChange(e,n)}))))}}t["default"]=Object(p["c"])(e=>{var t=e.ticket;return{ticket:t}})(v)},"RU/L":function(e,t,n){n("Rqdy");var r=n("WEpk").Object;e.exports=function(e,t,n){return r.defineProperty(e,t,n)}},RXBc:function(e,t,n){"use strict";n.r(t),n.d(t,"default",function(){return s});var r=n("q1tI"),i=n.n(r),o=n("3a4m"),a=n.n(o);class s extends i.a.Component{componentDidMount(){a.a.push("/login")}render(){return i.a.createElement("div",null)}}},RfKB:function(e,t,n){var r=n("2faE").f,i=n("B+OT"),o=n("UWiX")("toStringTag");e.exports=function(e,t,n){e&&!i(e=n?e:e.prototype,o)&&r(e,o,{configurable:!0,value:t})}},Rqdy:function(e,t,n){var r=n("Y7ZC");r(r.S+r.F*!n("jmDH"),"Object",{defineProperty:n("2faE").f})},SBuE:function(e,t){e.exports={}},SEkw:function(e,t,n){e.exports={default:n("RU/L"),__esModule:!0}},SGa5:function(e,t,n){"use strict";n.r(t);n("Pwec");var r=n("CtXQ"),i=n("q1tI"),o=n.n(i),a=n("/MKj");class s extends o.a.Component{constructor(e){super(e),this.state={},this.keyDown=this.keyDown.bind(this)}keyDown(e){13===e.keyCode&&this.login()}componentDidMount(){var e=this.props.location.query.verify,t=this.props.location.query.redirect;e&&this.props.dispatch({type:"passport/token2Login",verify:e,redirect:t}),this.props.dispatch({type:"passport/check",redirect:t}),window.addEventListener("keydown",this.keyDown,!1)}componentWillUnmount(){window.removeEventListener("keydown",this.keyDown,!1)}login(){this.props.dispatch({type:"passport/login",email:this.refs.email.value,password:this.refs.password.value})}render(){var e=this.props.passport.loginLoading;return o.a.createElement("div",{id:"page-container"},o.a.createElement("main",{id:"main-container",className:"v2board-background",style:{backgroundImage:window.settings.background_url&&"url(".concat(window.settings.background_url,")")}},o.a.createElement("div",{className:"no-gutters",style:{height:"100%"}},o.a.createElement("div",{className:"",style:{maxWidth:450,top:"calc(50% - 182.5px)",position:"absolute",right:0,left:0,margin:"auto"}},o.a.createElement("div",{className:"block block-rounded block-transparent block-fx-pop w-100 mb-0 overflow-hidden bg-image",style:{boxShadow:"0 0.5rem 2rem #0000000d"}},o.a.createElement("div",{className:"row no-gutters"},o.a.createElement("div",{className:"col-md-12 order-md-1 bg-white"},o.a.createElement("div",{className:"block-content block-content-full px-lg-4 py-md-4 py-lg-4"},o.a.createElement("div",{className:"mb-2 text-center"},o.a.createElement("a",{className:"link-fx font-w700 font-size-h1",href:"javascript:void(0);"},o.a.createElement("span",{className:"text-dark"},window.settings.title||"V2Board")),o.a.createElement("p",{className:"text-uppercase font-w700 font-size-sm text-muted"},"\u767b\u5f55\u5230\u7ba1\u7406\u4e2d\u5fc3")),o.a.createElement("div",{className:"form-group"},o.a.createElement("input",{type:"text",className:"form-control form-control-alt",placeholder:"\u90ae\u7bb1",ref:"email"})),o.a.createElement("div",{className:"form-group"},o.a.createElement("input",{type:"password",className:"form-control form-control-alt",placeholder:"\u5bc6\u7801",ref:"password"})),o.a.createElement("div",{className:"form-group"},o.a.createElement("button",{disabled:e,type:"submit",className:"btn btn-block btn-hero-primary",onClick:()=>this.login()},e?o.a.createElement(r["a"],{type:"loading"}):o.a.createElement("span",null,o.a.createElement("i",{className:"si si-login mr-1"}),"\u767b\u5165")))))))))))}}t["default"]=Object(a["c"])(e=>{var t=e.passport;return{passport:t}})(s)},SLVX:function(e,t,n){"use strict";function r(e){var t,n=e.Symbol;return"function"===typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}n.d(t,"a",function(){return r})},SPFY:function(e,t,n){n("Jaki")("Float64",8,function(e){return function(t,n,r){return e(this,t,n,r)}})},SfDG:function(e,t,n){var r=n("u8+u"),i=n("c0Oy").document,o=r(i)&&r(i.createElement);e.exports=function(e){return o?i.createElement(e):{}}},Spc3:function(e,t,n){var r=n("AUWw"),i=Math.max,o=Math.min;e.exports=function(e,t){return e=r(e),e<0?i(e+t,0):o(e,t)}},T1nr:function(e,t,n){var r=n("Igga"),i=n("e6w7"),o=n("LsAW");e.exports=function(e){var t=r(e),n=i.f;if(n){var a,s=n(e),l=o.f,c=0;while(s.length>c)l.call(e,a=s[c++])&&t.push(a)}return t}},T4gb:function(e,t,n){"use strict";n.r(t);var r=n("d6i3"),i=n.n(r),o=n("p0pE"),a=n.n(o),s=n("t3Un"),l={};t["default"]={name:"stat",state:a()({},l),reducers:{save(e,t){var n=t.payload;return a()({},e,n)}},effects:{getOverride(e,t){return i.a.mark(function e(){var n,r;return i.a.wrap(function(e){while(1)switch(e.prev=e.next){case 0:return n=t.put,e.next=3,Object(s["a"])("/admin/stat/getOverride");case 3:if(r=e.sent,200===r.code){e.next=6;break}return e.abrupt("return");case 6:return e.next=8,n({type:"save",payload:a()({},r.data)});case 8:case"end":return e.stop()}},e)})()},getOrder(e){return i.a.mark(function t(){var n,r;return i.a.wrap(function(t){while(1)switch(t.prev=t.next){case 0:return n=e.complete,t.next=3,Object(s["a"])("/admin/stat/getOrder");case 3:if(r=t.sent,200===r.code){t.next=6;break}return t.abrupt("return");case 6:n(r.data);case 7:case"end":return t.stop()}},t)})()},getServerLastRank(e){return i.a.mark(function t(){var n,r;return i.a.wrap(function(t){while(1)switch(t.prev=t.next){case 0:return n=e.complete,t.next=3,Object(s["a"])("/admin/stat/getServerLastRank");case 3:if(r=t.sent,200===r.code){t.next=6;break}return t.abrupt("return");case 6:n(r.data);case 7:case"end":return t.stop()}},t)})()}}}},T8I8:function(e,t){e.exports=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/},TOwV:function(e,t,n){"use strict";e.exports=n("qT12")},TSYQ:function(e,t,n){var r,i;(function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;ti&&(e.splice(r+1,0,d),n=!0)}return n}}function h(e,t,n,r){var i=r-e*e,o=Math.abs(i)<1e-24?0:(n-e*t)/i,a=t-o*e;return[a,o]}function d(){var e,n=function(e){return e[0]},r=function(e){return e[1]};function i(i){var o=0,l=0,c=0,d=0,f=0,p=0,m=e?+e[0]:1/0,g=e?+e[1]:-1/0;a(i,n,r,function(t,n){var r=Math.log(n),i=t*n;++o,l+=(n-l)/o,d+=(i-d)/o,p+=(t*i-p)/o,c+=(n*r-c)/o,f+=(i*r-f)/o,e||(tg&&(g=t))});var v=h(d/l,c/l,f/l,p/l),y=t(v,2),b=y[0],w=y[1];b=Math.exp(b);var x=function(e){return b*Math.exp(w*e)},E=u(m,g,x);return E.a=b,E.b=w,E.predict=x,E.rSquared=s(i,n,r,l,x),E}return i.domain=function(t){return arguments.length?(e=t,i):e},i.x=function(e){return arguments.length?(n=e,i):n},i.y=function(e){return arguments.length?(r=e,i):r},i}function f(){var e,n=function(e){return e[0]},r=function(e){return e[1]};function i(i){var o=0,l=0,c=0,u=0,d=0,f=e?+e[0]:1/0,p=e?+e[1]:-1/0;a(i,n,r,function(t,n){++o,l+=(t-l)/o,c+=(n-c)/o,u+=(t*n-u)/o,d+=(t*t-d)/o,e||(tp&&(p=t))});var m=h(l,c,u,d),g=t(m,2),v=g[0],y=g[1],b=function(e){return y*e+v},w=[[f,b(f)],[p,b(p)]];return w.a=y,w.b=v,w.predict=b,w.rSquared=s(i,n,r,c,b),w}return i.domain=function(t){return arguments.length?(e=t,i):e},i.x=function(e){return arguments.length?(n=e,i):n},i.y=function(e){return arguments.length?(r=e,i):r},i}function p(e){e.sort(function(e,t){return e-t});var t=e.length/2;return t%1===0?(e[t-1]+e[t])/2:e[Math.floor(t)]}var m=2,g=1e-12;function v(){var e=function(e){return e[0]},n=function(e){return e[1]},r=.3;function i(i){for(var a=o(i,e,n,!0),s=t(a,4),l=s[0],c=s[1],u=s[2],d=s[3],f=l.length,v=Math.max(2,~~(r*f)),x=new Float64Array(f),E=new Float64Array(f),C=new Float64Array(f).fill(1),S=-1;++S<=m;){for(var k=[0,v-1],_=0;_l[M]-O?A:M,P=0,R=0,L=0,D=0,N=0,j=1/Math.abs(l[T]-O||1),$=A;$<=M;++$){var I=l[$],F=c[$],V=y(Math.abs(O-I)*j)*C[$],B=I*V;P+=V,R+=B,L+=F*V,D+=F*B,N+=I*B}var W=h(R/P,L/P,D/P,N/P),H=t(W,2),U=H[0],z=H[1];x[_]=U+z*O,E[_]=Math.abs(c[_]-x[_]),b(l,_+1,k)}if(S===m)break;var K=p(E);if(Math.abs(K)=1?g:(G=1-q*q)*G}return w(l,x,u,d)}return i.bandwidth=function(e){return arguments.length?(r=e,i):r},i.x=function(t){return arguments.length?(e=t,i):e},i.y=function(e){return arguments.length?(n=e,i):n},i}function y(e){return(e=1-e*e*e)*e*e}function b(e,t,n){var r=e[t],i=n[0],o=n[1]+1;if(!(o>=e.length))while(t>i&&e[o]-r<=r-e[i])n[0]=++i,n[1]=o,++o}function w(e,t,n,r){for(var i,o=e.length,a=[],s=0,l=0,c=[];sg&&(g=t))});var y=h(c,d,f,p),b=t(y,2),w=b[0],x=b[1],E=function(e){return x*Math.log(e)/v+w},C=u(m,g,E);return C.a=x,C.b=w,C.predict=E,C.rSquared=s(o,n,r,d,E),C}return o.domain=function(t){return arguments.length?(e=t,o):e},o.x=function(e){return arguments.length?(n=e,o):n},o.y=function(e){return arguments.length?(r=e,o):r},o.base=function(e){return arguments.length?(i=e,o):i},o}function E(){var e,n=function(e){return e[0]},r=function(e){return e[1]};function i(i){var l,c,h,d,f=o(i,n,r),p=t(f,4),m=p[0],g=p[1],v=p[2],y=p[3],b=m.length,w=0,x=0,E=0,C=0,S=0;for(l=0;lA&&(A=t))});var M=E-w*w,T=w*M-x*x,P=(S*w-C*x)/T,R=(C*M-S*x)/T,L=-P*w,D=function(e){return e-=v,P*e*e+R*e+L+y},N=u(O,A,D);return N.a=P,N.b=R-2*P*v,N.c=L-R*v+P*v*v+y,N.predict=D,N.rSquared=s(i,n,r,k,D),N}return i.domain=function(t){return arguments.length?(e=t,i):e},i.x=function(e){return arguments.length?(n=e,i):n},i.y=function(e){return arguments.length?(r=e,i):r},i}function C(){var e,n=function(e){return e[0]},r=function(e){return e[1]},i=3;function l(l){if(1===i){var c=f().x(n).y(r).domain(e)(l);return c.coefficients=[c.b,c.a],delete c.a,delete c.b,c}if(2===i){var h=E().x(n).y(r).domain(e)(l);return h.coefficients=[h.c,h.b,h.a],delete h.a,delete h.b,delete h.c,h}var d,p,m,g,v,y=o(l,n,r),b=t(y,4),w=b[0],x=b[1],C=b[2],_=b[3],O=w.length,A=[],M=[],T=i+1,P=0,R=0,L=e?+e[0]:1/0,D=e?+e[1]:-1/0;for(a(l,n,r,function(t,n){++R,P+=(n-P)/R,e||(tD&&(D=t))}),d=0;d=0;--i)for(a=t[i],s=1,l[i]+=a,o=1;o<=i;++o)s*=(i+1-o)/o,l[i-o]+=a*Math.pow(n,o)*s;return l[0]+=r,l}function k(e){var t,n,r,i,o,a=e.length-1,s=[];for(t=0;tMath.abs(e[t][i])&&(i=n);for(r=t;r=t;r--)e[r][n]-=e[r][t]*e[t][n]/e[t][t]}for(n=a-1;n>=0;--n){for(o=0,r=n+1;rg&&(g=t))});var v=h(l,c,d,f),y=t(v,2),b=y[0],w=y[1];b=Math.exp(b);var x=function(e){return b*Math.pow(e,w)},E=u(m,g,x);return E.a=b,E.b=w,E.predict=x,E.rSquared=s(i,n,r,p,x),E}return i.domain=function(t){return arguments.length?(e=t,i):e},i.x=function(e){return arguments.length?(n=e,i):n},i.y=function(e){return arguments.length?(r=e,i):r},i}e.regressionExp=d,e.regressionLinear=f,e.regressionLoess=v,e.regressionLog=x,e.regressionPoly=C,e.regressionPow=_,e.regressionQuad=E,Object.defineProperty(e,"__esModule",{value:!0})})},"U+KD":function(e,t,n){var r=n("B+OT"),i=n("JB68"),o=n("VVlx")("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=i(e),r(e,o)?e[o]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},U8pU:function(e,t,n){"use strict";function r(e){"@babel/helpers - typeof";return r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}n.d(t,"a",function(){return r})},ULMT:function(e,t,n){var r=n("yw4e"),i=n("gL7N")("iterator"),o=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||o[i]===e)}},UNrv:function(e,t,n){"use strict";function r(e){"@babel/helpers - typeof";return r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function o(e){for(var t=1;t2&&void 0!==arguments[2]?arguments[2]:[],i=e.context.table,o=i.columnManager,a=i.components,s=i.props,l=s.prefixCls,c=s.childrenColumnName,u=s.rowClassName,h=s.rowRef,d=s.onRowClick,f=s.onRowDoubleClick,p=s.onRowContextMenu,m=s.onRowMouseEnter,g=s.onRowMouseLeave,v=s.onRow,y=e.props,w=y.getRowKey,x=y.fixed,E=y.expander,C=y.isAnyColumnsFixed,S=[],O=function(i){var s=t[i],y=w(s,i),O="string"===typeof u?u:u(s,i,n),A={};o.isAnyColumnsFixed()&&(A.onHover=e.handleRowHover);var M=void 0;M="left"===x?o.leftLeafColumns():"right"===x?o.rightLeafColumns():e.getColumns(o.leafColumns());var T="".concat(l,"-row"),P=b.createElement(_.default,Object.assign({},E.props,{fixed:x,index:i,prefixCls:T,record:s,key:y,rowKey:y,onRowClick:d,needIndentSpaced:E.needIndentSpaced,onExpandedChange:E.handleExpandChange}),function(e){return b.createElement(k.default,Object.assign({fixed:x,indent:n,className:O,record:s,index:i,prefixCls:T,childrenColumnName:c,columns:M,onRow:v,onRowDoubleClick:f,onRowContextMenu:p,onRowMouseEnter:m,onRowMouseLeave:g},A,{rowKey:y,ancestorKeys:r,ref:h(s,i,n),components:a,isAnyColumnsFixed:C},e))});S.push(P),E.renderRows(e.renderRows,S,s,i,n,x,y,r)},A=0;A0})}var c=function(e,t){var n=t.table,r=n.components,i=n.props,a=i.prefixCls,c=i.showHeader,u=i.onHeaderRow,h=e.expander,d=e.columns,f=e.fixed;if(!c)return null;var p=l({columns:d});h.renderExpandIndentCell(p,f);var m=r.header.wrapper;return o.createElement(m,{className:"".concat(a,"-thead")},p.map(function(e,t){return o.createElement(s.default,{prefixCls:a,key:t,index:t,fixed:f,columns:d,rows:p,row:e,components:r,onHeaderRow:u})}))};c.contextTypes={table:a.any},t.default=c},VPOE:function(e,t,n){var r=n("V5/1"),i=n("pQGJ");e.exports=n("8Z/V")?function(e,t,n){return r.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},VVlx:function(e,t,n){var r=n("29s/")("keys"),i=n("YqAc");e.exports=function(e){return r[e]||(r[e]=i(e))}},VeWa:function(e,t,n){(function(e){ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text_highlight_rules").TextHighlightRules,o=function(){this.$rules={start:[{token:"variable",regex:'["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'},{token:"string",regex:'"',next:"string"},{token:"constant.numeric",regex:"0[xX][0-9a-fA-F]+\\b"},{token:"constant.numeric",regex:"[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},{token:"constant.language.boolean",regex:"(?:true|false)\\b"},{token:"text",regex:"['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"},{token:"comment",regex:"\\/\\/.*$"},{token:"comment.start",regex:"\\/\\*",next:"comment"},{token:"paren.lparen",regex:"[[({]"},{token:"paren.rparen",regex:"[\\])}]"},{token:"text",regex:"\\s+"}],string:[{token:"constant.language.escape",regex:/\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/},{token:"string",regex:'"|$',next:"start"},{defaultToken:"string"}],comment:[{token:"comment.end",regex:"\\*\\/",next:"start"},{defaultToken:"comment"}]}};r.inherits(o,i),t.JsonHighlightRules=o}),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../range").Range,i=function(){};(function(){this.checkOutdent=function(e,t){return!!/^\s+$/.test(e)&&/^\s*\}/.test(t)},this.autoOutdent=function(e,t){var n=e.getLine(t),i=n.match(/^(\s*\})/);if(!i)return 0;var o=i[1].length,a=e.findMatchingBracket({row:t,column:o});if(!a||a.row==t)return 0;var s=this.$getIndent(e.getLine(a.row));e.replace(new r(t,0,t,o-1),s)},this.$getIndent=function(e){return e.match(/^\s*/)[0]}}).call(i.prototype),t.MatchingBraceOutdent=i}),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(e,t,n){"use strict";var r=e("../../lib/oop"),i=e("../../range").Range,o=e("./fold_mode").FoldMode,a=t.FoldMode=function(e){e&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+e.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+e.end)))};r.inherits(a,o),function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);if(this.singleLineBlockCommentRe.test(r)&&!this.startRegionRe.test(r)&&!this.tripleStarBlockCommentRe.test(r))return"";var i=this._getFoldWidgetBase(e,t,n);return!i&&this.startRegionRe.test(r)?"start":i},this.getFoldWidgetRange=function(e,t,n,r){var i=e.getLine(n);if(this.startRegionRe.test(i))return this.getCommentRegionBlock(e,i,n);var o=i.match(this.foldingStartMarker);if(o){var a=o.index;if(o[1])return this.openingBracketBlock(e,o[1],n,a);var s=e.getCommentFoldRange(n,a+o[0].length,1);return s&&!s.isMultiLine()&&(r?s=this.getSectionRange(e,n):"all"!=t&&(s=null)),s}if("markbegin"!==t){o=i.match(this.foldingStopMarker);if(o){a=o.index+o[0].length;return o[1]?this.closingBracketBlock(e,o[1],n,a):e.getCommentFoldRange(n,a,-1)}}},this.getSectionRange=function(e,t){var n=e.getLine(t),r=n.search(/\S/),o=t,a=n.length;t+=1;var s=t,l=e.getLength();while(++tc)break;var u=this.getFoldWidgetRange(e,"all",t);if(u){if(u.start.row<=o)break;if(u.isMultiLine())t=u.end.row;else if(r==c)break}s=t}}return new i(o,a,s,e.getLine(s).length)},this.getCommentRegionBlock=function(e,t,n){var r=t.search(/\s*$/),o=e.getLength(),a=n,s=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,l=1;while(++na)return new i(a,r,u,t.length)}}.call(a.prototype)}),ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/worker/worker_client"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text").Mode,o=e("./json_highlight_rules").JsonHighlightRules,a=e("./matching_brace_outdent").MatchingBraceOutdent,s=e("./behaviour/cstyle").CstyleBehaviour,l=e("./folding/cstyle").FoldMode,c=e("../worker/worker_client").WorkerClient,u=function(){this.HighlightRules=o,this.$outdent=new a,this.$behaviour=new s,this.foldingRules=new l};r.inherits(u,i),function(){this.lineCommentStart="//",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(e,t,n){var r=this.$getIndent(t);if("start"==e){var i=t.match(/^.*[\{\(\[]\s*$/);i&&(r+=n)}return r},this.checkOutdent=function(e,t,n){return this.$outdent.checkOutdent(t,n)},this.autoOutdent=function(e,t,n){this.$outdent.autoOutdent(t,n)},this.createWorker=function(e){var t=new c(["ace"],"ace/mode/json_worker","JsonWorker");return t.attachToDocument(e.getDocument()),t.on("annotate",function(t){e.setAnnotations(t.data)}),t.on("terminate",function(){e.clearAnnotations()}),t},this.$id="ace/mode/json"}.call(u.prototype),t.Mode=u}),function(){ace.require(["ace/mode/json"],function(t){e&&(e.exports=t)})}()}).call(this,n("YuTi")(e))},Vegh:function(e,t,n){"use strict";var r=n("iCc5"),i=n.n(r),o=n("FYw3"),a=n.n(o),s=n("mRg0"),l=n.n(s),c=n("q1tI"),u=n.n(c),h=n("i8i4"),d=n.n(h),f=n("17x9"),p=n.n(f),m=n("4IlW"),g=n("VCL8"),v=n("wd/R"),y=n.n(v),b=n("GrtH"),w=void 0,x=void 0,E=void 0,C=function(e){function t(n){i()(this,t);var r=a()(this,e.call(this,n));S.call(r);var o=n.selectedValue;return r.state={str:Object(b["a"])(o,r.props.format),invalid:!1,hasFocus:!1},r}return l()(t,e),t.prototype.componentDidUpdate=function(){!E||!this.state.hasFocus||this.state.invalid||0===w&&0===x||E.setSelectionRange(w,x)},t.getDerivedStateFromProps=function(e,t){var n={};E&&(w=E.selectionStart,x=E.selectionEnd);var r=e.selectedValue;return t.hasFocus||(n={str:Object(b["a"])(r,e.format),invalid:!1}),n},t.getInstance=function(){return E},t.prototype.render=function(){var e=this.props,t=this.state,n=t.invalid,r=t.str,i=e.locale,o=e.prefixCls,a=e.placeholder,s=e.clearIcon,l=e.inputMode,c=n?o+"-input-invalid":"";return u.a.createElement("div",{className:o+"-input-wrap"},u.a.createElement("div",{className:o+"-date-input-wrap"},u.a.createElement("input",{ref:this.saveDateInput,className:o+"-input "+c,value:r,disabled:e.disabled,placeholder:a,onChange:this.onInputChange,onKeyDown:this.onKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,inputMode:l})),e.showClear?u.a.createElement("a",{role:"button",title:i.clear,onClick:this.onClear},s||u.a.createElement("span",{className:o+"-clear-btn"})):null)},t}(u.a.Component);C.propTypes={prefixCls:p.a.string,timePicker:p.a.object,value:p.a.object,disabledTime:p.a.any,format:p.a.oneOfType([p.a.string,p.a.arrayOf(p.a.string)]),locale:p.a.object,disabledDate:p.a.func,onChange:p.a.func,onClear:p.a.func,placeholder:p.a.string,onSelect:p.a.func,selectedValue:p.a.object,clearIcon:p.a.node,inputMode:p.a.string};var S=function(){var e=this;this.onClear=function(){e.setState({str:""}),e.props.onClear(null)},this.onInputChange=function(t){var n=t.target.value,r=e.props,i=r.disabledDate,o=r.format,a=r.onChange,s=r.selectedValue;if(!n)return a(null),void e.setState({invalid:!1,str:n});var l=y()(n,o,!0);if(l.isValid()){var c=e.props.value.clone();c.year(l.year()).month(l.month()).date(l.date()).hour(l.hour()).minute(l.minute()).second(l.second()),!c||i&&i(c)?e.setState({invalid:!0,str:n}):(s!==c||s&&c&&!s.isSame(c))&&(e.setState({invalid:!1,str:n}),a(c))}else e.setState({invalid:!0,str:n})},this.onFocus=function(){e.setState({hasFocus:!0})},this.onBlur=function(){e.setState(function(e,t){return{hasFocus:!1,str:Object(b["a"])(t.value,t.format)}})},this.onKeyDown=function(t){var n=t.keyCode,r=e.props,i=r.onSelect,o=r.value,a=r.disabledDate;if(n===m["a"].ENTER&&i){var s=!a||!a(o);s&&i(o.clone()),t.preventDefault()}},this.getRootDOMNode=function(){return d.a.findDOMNode(e)},this.focus=function(){E&&E.focus()},this.saveDateInput=function(e){E=e}};Object(g["polyfill"])(C),t["a"]=C},VeyY:function(e,t,n){var r=n("7vYJ"),i=n("wYm8"),o=n("gL7N")("species");e.exports=function(e,t){var n,a=r(e).constructor;return void 0===a||void 0==(n=r(a)[o])?t:i(n)}},VxKu:function(e,t,n){"use strict";var r=n("WGNW"),i=n("Lnex")(!0);r(r.P,"Array",{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),n("DIcO")("includes")},VyuQ:function(e,t,n){var r=n("bV5f"),i=n("c0Oy"),o="__core-js_shared__",a=i[o]||(i[o]={});(e.exports=function(e,t){return a[e]||(a[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:n("FqPH")?"pure":"global",copyright:"\xa9 2019 Denis Pushkarev (zloirock.ru)"})},W070:function(e,t,n){var r=n("NsO/"),i=n("tEej"),o=n("D8kY");e.exports=function(e){return function(t,n,a){var s,l=r(t),c=i(l.length),u=o(a,c);if(e&&n!=n){while(c>u)if(s=l[u++],s!=s)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}}},W3Xk:function(e,t,n){var r=n("WGNW"),i=n("ZDr/"),o=n("wUWy"),a=n("GsrZ"),s="["+a+"]",l="\u200b\x85",c=RegExp("^"+s+s+"*"),u=RegExp(s+s+"*$"),h=function(e,t,n){var i={},s=o(function(){return!!a[e]()||l[e]()!=l}),c=i[e]=s?t(d):a[e];n&&(i[n]=c),r(r.P+r.F*s,"String",i)},d=h.trim=function(e,t){return e=String(i(e)),1&t&&(e=e.replace(c,"")),2&t&&(e=e.replace(u,"")),e};e.exports=h},W5Cv:function(e,t,n){"use strict";function r(e,t){var n=window.Element.prototype,r=n.matches||n.mozMatchesSelector||n.msMatchesSelector||n.oMatchesSelector||n.webkitMatchesSelector;if(!e||1!==e.nodeType)return!1;var i=e.parentNode;if(r)return r.call(e,t);for(var o=i.querySelectorAll(t),a=o.length,s=0;s-1}function Qe(e,t){var n=this.__data__,r=ft(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function Xe(e){var t=-1,n=null==e?0:e.length;this.clear();while(++tc))return!1;var h=s.get(e);if(h&&s.get(t))return h==t;var d=-1,f=!0,p=n&a?new rt:void 0;s.set(e,t),s.set(t,e);while(++d-1&&e%1==0&&e-1&&e%1==0&&e<=s}function zt(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Kt(e){return null!=e&&"object"==typeof e}var qt=X?ne(X):wt;function Gt(e){return Vt(e)?dt(e):xt(e)}function Yt(){return[]}function Qt(){return!1}n.exports=Wt}).call(this,n("yLpj"),n("YuTi")(e))},XaS2:function(e,t,n){"use strict";function r(e){"@babel/helpers - typeof";return r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){if(null==e)return{};var n,r,i=o(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function o(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function s(e){for(var t=1;t=0&&this.setRowHeight())}},{key:"render",value:function(){if(!this.state.shouldRender)return null;var e=this.props,t=e.prefixCls,n=e.columns,r=e.record,o=e.rowKey,a=e.index,l=e.onRow,c=e.indent,u=e.indentSize,h=e.hovered,d=e.height,f=e.visible,p=e.components,m=e.hasExpandIcon,g=e.renderExpandIcon,v=e.renderExpandIconCell,y=e.onRowClick,b=e.onRowDoubleClick,w=e.onRowMouseEnter,E=e.onRowMouseLeave,S=e.onRowContextMenu,k=p.body.row,A=p.body.cell,M=this.props.className;h&&(M+=" ".concat(t,"-hover"));var T=[];v(T);for(var P=0;P=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}e.exports=i},"Y/ne":function(e,t,n){var r=n("OsVd"),i=n("03ni"),o=n("ZDr/");e.exports=function(e,t,n,a){var s=String(o(e)),l=s.length,c=void 0===n?" ":String(n),u=r(t);if(u<=l||""==c)return s;var h=u-l,d=i.call(c,Math.ceil(h/c.length));return d.length>h&&(d=d.slice(0,h)),a?d+s:s+d}},Y7ZC:function(e,t,n){var r=n("5T2Y"),i=n("WEpk"),o=n("2GTP"),a=n("NegM"),s=n("B+OT"),l="prototype",c=function(e,t,n){var u,h,d,f=e&c.F,p=e&c.G,m=e&c.S,g=e&c.P,v=e&c.B,y=e&c.W,b=p?i:i[t]||(i[t]={}),w=b[l],x=p?r:m?r[t]:(r[t]||{})[l];for(u in p&&(n=t),n)h=!f&&x&&void 0!==x[u],h&&s(b,u)||(d=h?x[u]:n[u],b[u]=p&&"function"!=typeof x[u]?n[u]:v&&h?o(d,r):y&&x[u]==d?function(e){var t=function(t,n,r){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,n)}return new e(t,n,r)}return e.apply(this,arguments)};return t[l]=e[l],t}(d):g&&"function"==typeof d?o(Function.call,d):d,g&&((b.virtual||(b.virtual={}))[u]=d,e&c.R&&w&&!w[u]&&a(w,u,d)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,e.exports=c},YEIV:function(e,t,n){"use strict";t.__esModule=!0;var r=n("SEkw"),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}t.default=function(e,t,n){return t in e?(0,i.default)(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},YEVI:function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},YVYq:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n("q1tI"),i=n.n(r);function o(e){var t=e.prefixCls,n=e.locale,r=e.okDisabled,o=e.onOk,a=t+"-ok-btn";return r&&(a+=" "+t+"-ok-btn-disabled"),i.a.createElement("a",{className:a,role:"button",onClick:r?null:o},n.ok)}},Yf6U:function(e,t,n){var r=n("W5Cv");e.exports=function(e,t,n){n=n||document,e={parentNode:e};while((e=e.parentNode)&&e!==n)if(r(e,t))return e}},YqAc:function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},YqDF:function(e,t,n){"use strict";function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function i(e){for(var t=1;t0&&c&&(w.marginBottom="-".concat(E,"px"),w.paddingBottom="0px")}var C,S=l.createElement(h.default,{tableClassName:d,hasHead:!b,hasBody:!0,fixed:c,columns:s,expander:g,getRowKey:f,isAnyColumnsFixed:v});if(c&&s.length)return"left"===s[0].fixed||!0===s[0].fixed?C="fixedColumnsBodyLeft":"right"===s[0].fixed&&(C="fixedColumnsBodyRight"),delete w.overflowX,delete w.overflowY,l.createElement("div",{key:"bodyTable",className:"".concat(o,"-body-outer"),style:i({},w)},l.createElement("div",{className:"".concat(o,"-body-inner"),style:x,ref:y(C),onWheel:m,onScroll:p},S));var k=a&&(a.x||a.y);return l.createElement("div",{tabIndex:k?-1:void 0,key:"bodyTable",className:"".concat(o,"-body"),style:w,ref:y("bodyTable"),onWheel:m,onScroll:p},S)}t.default=d,d.contextTypes={table:c.any}},YuTi:function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},Z4ex:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;nt.length?e:t,u=e.length>t.length?t:e,h=c.indexOf(u);if(-1!=h)return l=[new n.Diff(i,c.substring(0,h)),new n.Diff(o,u),new n.Diff(i,c.substring(h+u.length))],e.length>t.length&&(l[0][0]=l[2][0]=r),l;if(1==u.length)return[new n.Diff(r,e),new n.Diff(i,t)];var d=this.diff_halfMatch_(e,t);if(d){var f=d[0],p=d[1],m=d[2],g=d[3],v=d[4],y=this.diff_main(f,m,a,s),b=this.diff_main(p,g,a,s);return y.concat([new n.Diff(o,v)],b)}return a&&e.length>100&&t.length>100?this.diff_lineMode_(e,t,s):this.diff_bisect_(e,t,s)},n.prototype.diff_lineMode_=function(e,t,a){var s=this.diff_linesToChars_(e,t);e=s.chars1,t=s.chars2;var l=s.lineArray,c=this.diff_main(e,t,!1,a);this.diff_charsToLines_(c,l),this.diff_cleanupSemantic(c),c.push(new n.Diff(o,""));var u=0,h=0,d=0,f="",p="";while(u=1&&d>=1){c.splice(u-h-d,h+d),u=u-h-d;for(var m=this.diff_main(f,p,!1,a),g=m.length-1;g>=0;g--)c.splice(u,0,m[g]);u+=m.length}d=0,h=0,f="",p="";break}u++}return c.pop(),c},n.prototype.diff_bisect_=function(e,t,o){for(var a=e.length,s=t.length,l=Math.ceil((a+s)/2),c=l,u=2*l,h=new Array(u),d=new Array(u),f=0;fo)break;for(var x=-w+g;x<=w-v;x+=2){var E=c+x;A=x==-w||x!=w&&h[E-1]a)v+=2;else if(C>s)g+=2;else if(m){var S=c+p-x;if(S>=0&&S=k)return this.diff_bisectSplit_(e,t,A,C,o)}}}for(var _=-w+y;_<=w-b;_+=2){S=c+_;k=_==-w||_!=w&&d[S-1]a)b+=2;else if(O>s)y+=2;else if(!m){E=c+p-_;if(E>=0&&E=k)return this.diff_bisectSplit_(e,t,A,C,o)}}}}return[new n.Diff(r,e),new n.Diff(i,t)]},n.prototype.diff_bisectSplit_=function(e,t,n,r,i){var o=e.substring(0,n),a=t.substring(0,r),s=e.substring(n),l=t.substring(r),c=this.diff_main(o,a,!1,i),u=this.diff_main(s,l,!1,i);return c.concat(u)},n.prototype.diff_linesToChars_=function(e,t){var n=[],r={};function i(e){var t="",i=0,a=-1,s=n.length;while(ar?e=e.substring(n-r):nt.length?e:t,r=e.length>t.length?t:e;if(n.length<4||2*r.length=e.length?[r,o,a,s,u]:null}var a,s,l,c,u,h=o(n,r,Math.ceil(n.length/4)),d=o(n,r,Math.ceil(n.length/2));if(!h&&!d)return null;a=d?h&&h[4].length>d[4].length?h:d:h,e.length>t.length?(s=a[0],l=a[1],c=a[2],u=a[3]):(c=a[0],u=a[1],s=a[2],l=a[3]);var f=a[4];return[s,l,c,u,f]},n.prototype.diff_cleanupSemantic=function(e){var t=!1,a=[],s=0,l=null,c=0,u=0,h=0,d=0,f=0;while(c0?a[s-1]:-1,u=0,h=0,d=0,f=0,l=null,t=!0)),c++;t&&this.diff_cleanupMerge(e),this.diff_cleanupSemanticLossless(e),c=1;while(c=v?(g>=p.length/2||g>=m.length/2)&&(e.splice(c,0,new n.Diff(o,m.substring(0,g))),e[c-1][1]=p.substring(0,p.length-g),e[c+1][1]=m.substring(g),c++):(v>=p.length/2||v>=m.length/2)&&(e.splice(c,0,new n.Diff(o,p.substring(0,v))),e[c-1][0]=i,e[c-1][1]=m.substring(0,m.length-v),e[c+1][0]=r,e[c+1][1]=p.substring(v),c++),c++}c++}},n.prototype.diff_cleanupSemanticLossless=function(e){function t(e,t){if(!e||!t)return 6;var r=e.charAt(e.length-1),i=t.charAt(0),o=r.match(n.nonAlphaNumericRegex_),a=i.match(n.nonAlphaNumericRegex_),s=o&&r.match(n.whitespaceRegex_),l=a&&i.match(n.whitespaceRegex_),c=s&&r.match(n.linebreakRegex_),u=l&&i.match(n.linebreakRegex_),h=c&&e.match(n.blanklineEndRegex_),d=u&&t.match(n.blanklineStartRegex_);return h||d?5:c||u?4:o&&!s&&l?3:s||l?2:o||a?1:0}var r=1;while(r=f&&(f=p,u=i,h=a,d=s)}e[r-1][1]!=u&&(u?e[r-1][1]=u:(e.splice(r-1,1),r--),e[r][1]=h,d?e[r+1][1]=d:(e.splice(r+1,1),r--))}r++}},n.nonAlphaNumericRegex_=/[^a-zA-Z0-9]/,n.whitespaceRegex_=/\s/,n.linebreakRegex_=/[\r\n]/,n.blanklineEndRegex_=/\n\r?\n$/,n.blanklineStartRegex_=/^\r?\n\r?\n/,n.prototype.diff_cleanupEfficiency=function(e){var t=!1,a=[],s=0,l=null,c=0,u=!1,h=!1,d=!1,f=!1;while(c0?a[s-1]:-1,d=f=!1),t=!0)),c++;t&&this.diff_cleanupMerge(e)},n.prototype.diff_cleanupMerge=function(e){e.push(new n.Diff(o,""));var t,a=0,s=0,l=0,c="",u="";while(a1?(0!==s&&0!==l&&(t=this.diff_commonPrefix(u,c),0!==t&&(a-s-l>0&&e[a-s-l-1][0]==o?e[a-s-l-1][1]+=u.substring(0,t):(e.splice(0,0,new n.Diff(o,u.substring(0,t))),a++),u=u.substring(t),c=c.substring(t)),t=this.diff_commonSuffix(u,c),0!==t&&(e[a][1]=u.substring(u.length-t)+e[a][1],u=u.substring(0,u.length-t),c=c.substring(0,c.length-t))),a-=s+l,e.splice(a,s+l),c.length&&(e.splice(a,0,new n.Diff(r,c)),a++),u.length&&(e.splice(a,0,new n.Diff(i,u)),a++),a++):0!==a&&e[a-1][0]==o?(e[a-1][1]+=e[a][1],e.splice(a,1)):a++,l=0,s=0,c="",u="";break}""===e[e.length-1][1]&&e.pop();var h=!1;a=1;while(at)break;s=o,l=a}return e.length!=n&&e[n][0]===r?l:l+(t-s)},n.prototype.diff_prettyHtml=function(e){for(var t=[],n=/&/g,a=//g,l=/\n/g,c=0;c");switch(u){case i:t[c]=''+d+"";break;case r:t[c]=''+d+"";break;case o:t[c]=""+d+"";break}}return t.join("")},n.prototype.diff_text1=function(e){for(var t=[],n=0;nthis.Match_MaxBits)throw new Error("Pattern too long for this browser.");var r=this.match_alphabet_(t),i=this;function o(e,r){var o=e/t.length,a=Math.abs(n-r);return i.Match_Distance?o+a/i.Match_Distance:a?1:o}var a=this.Match_Threshold,s=e.indexOf(t,n);-1!=s&&(a=Math.min(o(0,s),a),s=e.lastIndexOf(t,n+t.length),-1!=s&&(a=Math.min(o(0,s),a)));var l,c,u=1<=p;v--){var y=r[e.charAt(v-1)];if(g[v]=0===f?(g[v+1]<<1|1)&y:(g[v+1]<<1|1)&y|(h[v+1]|h[v])<<1|1|h[v+1],g[v]&u){var b=o(f,v-1);if(b<=a){if(a=b,s=v-1,!(s>n))break;p=Math.max(1,2*n-s)}}}if(o(f+1,n)>a)break;h=g}return s},n.prototype.match_alphabet_=function(e){for(var t={},n=0;n2&&(this.diff_cleanupSemantic(l),this.diff_cleanupEfficiency(l));else if(e&&"object"==typeof e&&"undefined"==typeof t&&"undefined"==typeof a)l=e,s=this.diff_text1(l);else if("string"==typeof e&&t&&"object"==typeof t&&"undefined"==typeof a)s=e,l=t;else{if("string"!=typeof e||"string"!=typeof t||!a||"object"!=typeof a)throw new Error("Unknown call format to patch_make.");s=e,l=a}if(0===l.length)return[];for(var c=[],u=new n.patch_obj,h=0,d=0,f=0,p=s,m=s,g=0;g=2*this.Patch_Margin&&h&&(this.patch_addContext_(u,p),c.push(u),u=new n.patch_obj,h=0,p=m,d=f);break}v!==i&&(d+=y.length),v!==r&&(f+=y.length)}return h&&(this.patch_addContext_(u,p),c.push(u)),c},n.prototype.patch_deepCopy=function(e){for(var t=[],r=0;rthis.Match_MaxBits?(c=this.match_main(t,d.substring(0,this.Match_MaxBits),h),-1!=c&&(f=this.match_main(t,d.substring(d.length-this.Match_MaxBits),h+d.length-this.Match_MaxBits),(-1==f||c>=f)&&(c=-1))):c=this.match_main(t,d,h),-1==c)s[l]=!1,a-=e[l].length2-e[l].length1;else if(s[l]=!0,a=c-h,u=-1==f?t.substring(c,c+d.length):t.substring(c,f+this.Match_MaxBits),d==u)t=t.substring(0,c)+this.diff_text2(e[l].diffs)+t.substring(c+d.length);else{var p=this.diff_main(d,u,!1);if(d.length>this.Match_MaxBits&&this.diff_levenshtein(p)/d.length>this.Patch_DeleteThreshold)s[l]=!1;else{this.diff_cleanupSemanticLossless(p);for(var m,g=0,v=0;vs[0][1].length){var l=t-s[0][1].length;s[0][1]=r.substring(s[0][1].length)+s[0][1],a.start1-=l,a.start2-=l,a.length1+=l,a.length2+=l}if(a=e[e.length-1],s=a.diffs,0==s.length||s[s.length-1][0]!=o)s.push(new n.Diff(o,r)),a.length1+=t,a.length2+=t;else if(t>s[s.length-1][1].length){l=t-s[s.length-1][1].length;s[s.length-1][1]+=r.substring(0,l),a.length1+=l,a.length2+=l}return r},n.prototype.patch_splitMax=function(e){for(var t=this.Match_MaxBits,a=0;a2*t?(h.length1+=p.length,l+=p.length,d=!1,h.diffs.push(new n.Diff(f,p)),s.diffs.shift()):(p=p.substring(0,t-h.length1-this.Patch_Margin),h.length1+=p.length,l+=p.length,f===o?(h.length2+=p.length,c+=p.length):d=!1,h.diffs.push(new n.Diff(f,p)),p==s.diffs[0][1]?s.diffs.shift():s.diffs[0][1]=s.diffs[0][1].substring(p.length))}u=this.diff_text2(h.diffs),u=u.substring(u.length-this.Patch_Margin);var m=this.diff_text1(s.diffs).substring(0,this.Patch_Margin);""!==m&&(h.length1+=m.length,h.length2+=m.length,0!==h.diffs.length&&h.diffs[h.diffs.length-1][0]===o?h.diffs[h.diffs.length-1][1]+=m:h.diffs.push(new n.Diff(o,m))),d||e.splice(++a,0,h)}}},n.prototype.patch_toText=function(e){for(var t=[],n=0;n.5?l/(2-o-a):l/(o+a),o){case e:r=(t-n)/l+(t1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}if(e=F(e,360),t=F(t,100),n=F(n,100),0===t)r=i=o=n;else{var s=n<.5?n*(1+t):n+t-n*t,l=2*n-s;r=a(l,s,e+1/3),i=a(l,s,e),o=a(l,s,e-1/3)}return{r:255*r,g:255*i,b:255*o}}function v(e,t,n){e=F(e,255),t=F(t,255),n=F(n,255);var r,i,o=u(e,t,n),a=c(e,t,n),s=o,l=o-a;if(i=0===o?0:l/o,o==a)r=0;else{switch(o){case e:r=(t-n)/l+(t>1)+720)%360;--t;)r.h=(r.h+i)%360,o.push(d(r));return o}function D(e,t){t=t||6;var n=d(e).toHsv(),r=n.h,i=n.s,o=n.v,a=[],s=1/t;while(t--)a.push(d({h:r,s:i,v:o})),o=(o+s)%1;return a}d.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,n,r,o,a,s=this.toRgb();return e=s.r/255,t=s.g/255,n=s.b/255,r=e<=.03928?e/12.92:i.pow((e+.055)/1.055,2.4),o=t<=.03928?t/12.92:i.pow((t+.055)/1.055,2.4),a=n<=.03928?n/12.92:i.pow((n+.055)/1.055,2.4),.2126*r+.7152*o+.0722*a},setAlpha:function(e){return this._a=I(e),this._roundA=l(100*this._a)/100,this},toHsv:function(){var e=v(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=v(this._r,this._g,this._b),t=l(360*e.h),n=l(100*e.s),r=l(100*e.v);return 1==this._a?"hsv("+t+", "+n+"%, "+r+"%)":"hsva("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHsl:function(){var e=m(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=m(this._r,this._g,this._b),t=l(360*e.h),n=l(100*e.s),r=l(100*e.l);return 1==this._a?"hsl("+t+", "+n+"%, "+r+"%)":"hsla("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHex:function(e){return b(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return w(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:l(this._r),g:l(this._g),b:l(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+l(this._r)+", "+l(this._g)+", "+l(this._b)+")":"rgba("+l(this._r)+", "+l(this._g)+", "+l(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:l(100*F(this._r,255))+"%",g:l(100*F(this._g,255))+"%",b:l(100*F(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+l(100*F(this._r,255))+"%, "+l(100*F(this._g,255))+"%, "+l(100*F(this._b,255))+"%)":"rgba("+l(100*F(this._r,255))+"%, "+l(100*F(this._g,255))+"%, "+l(100*F(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(j[b(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+x(this._r,this._g,this._b,this._a),n=t,r=this._gradientType?"GradientType = 1, ":"";if(e){var i=d(e);n="#"+x(i._r,i._g,i._b,i._a)}return"progid:DXImageTransform.Microsoft.gradient("+r+"startColorstr="+t+",endColorstr="+n+")"},toString:function(e){var t=!!e;e=e||this._format;var n=!1,r=this._a<1&&this._a>=0,i=!t&&r&&("hex"===e||"hex6"===e||"hex3"===e||"hex4"===e||"hex8"===e||"name"===e);return i?"name"===e&&0===this._a?this.toName():this.toRgbString():("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString())},clone:function(){return d(this.toString())},_applyModification:function(e,t){var n=e.apply(null,[this].concat([].slice.call(t)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(k,arguments)},brighten:function(){return this._applyModification(_,arguments)},darken:function(){return this._applyModification(O,arguments)},desaturate:function(){return this._applyModification(E,arguments)},saturate:function(){return this._applyModification(C,arguments)},greyscale:function(){return this._applyModification(S,arguments)},spin:function(){return this._applyModification(A,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(L,arguments)},complement:function(){return this._applyCombination(M,arguments)},monochromatic:function(){return this._applyCombination(D,arguments)},splitcomplement:function(){return this._applyCombination(R,arguments)},triad:function(){return this._applyCombination(T,arguments)},tetrad:function(){return this._applyCombination(P,arguments)}},d.fromRatio=function(e,t){if("object"==typeof e){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]="a"===r?e[r]:z(e[r]));e=n}return d(e,t)},d.equals=function(e,t){return!(!e||!t)&&d(e).toRgbString()==d(t).toRgbString()},d.random=function(){return d.fromRatio({r:h(),g:h(),b:h()})},d.mix=function(e,t,n){n=0===n?0:n||50;var r=d(e).toRgb(),i=d(t).toRgb(),o=n/100,a={r:(i.r-r.r)*o+r.r,g:(i.g-r.g)*o+r.g,b:(i.b-r.b)*o+r.b,a:(i.a-r.a)*o+r.a};return d(a)},d.readability=function(e,t){var n=d(e),r=d(t);return(i.max(n.getLuminance(),r.getLuminance())+.05)/(i.min(n.getLuminance(),r.getLuminance())+.05)},d.isReadable=function(e,t,n){var r,i,o=d.readability(e,t);switch(i=!1,r=X(n),r.level+r.size){case"AAsmall":case"AAAlarge":i=o>=4.5;break;case"AAlarge":i=o>=3;break;case"AAAsmall":i=o>=7;break}return i},d.mostReadable=function(e,t,n){var r,i,o,a,s=null,l=0;n=n||{},i=n.includeFallbackColors,o=n.level,a=n.size;for(var c=0;cl&&(l=r,s=d(t[c]));return d.isReadable(e,s,{level:o,size:a})||!i?s:(n.includeFallbackColors=!1,d.mostReadable(e,["#fff","#000"],n))};var N=d.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",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:"f0f",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:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",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",rebeccapurple:"663399",red:"f00",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:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},j=d.hexNames=$(N);function $(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}function I(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function F(e,t){W(e)&&(e="100%");var n=H(e);return e=c(t,u(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),i.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function V(e){return c(1,u(0,e))}function B(e){return parseInt(e,16)}function W(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)}function H(e){return"string"===typeof e&&-1!=e.indexOf("%")}function U(e){return 1==e.length?"0"+e:""+e}function z(e){return e<=1&&(e=100*e+"%"),e}function K(e){return i.round(255*parseFloat(e)).toString(16)}function q(e){return B(e)/255}var G=function(){var e="[-\\+]?\\d+%?",t="[-\\+]?\\d*\\.\\d+%?",n="(?:"+t+")|(?:"+e+")",r="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?",i="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?";return{CSS_UNIT:new RegExp(n),rgb:new RegExp("rgb"+r),rgba:new RegExp("rgba"+i),hsl:new RegExp("hsl"+r),hsla:new RegExp("hsla"+i),hsv:new RegExp("hsv"+r),hsva:new RegExp("hsva"+i),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function Y(e){return!!G.CSS_UNIT.exec(e)}function Q(e){e=e.replace(o,"").replace(a,"").toLowerCase();var t,n=!1;if(N[e])e=N[e],n=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};return(t=G.rgb.exec(e))?{r:t[1],g:t[2],b:t[3]}:(t=G.rgba.exec(e))?{r:t[1],g:t[2],b:t[3],a:t[4]}:(t=G.hsl.exec(e))?{h:t[1],s:t[2],l:t[3]}:(t=G.hsla.exec(e))?{h:t[1],s:t[2],l:t[3],a:t[4]}:(t=G.hsv.exec(e))?{h:t[1],s:t[2],v:t[3]}:(t=G.hsva.exec(e))?{h:t[1],s:t[2],v:t[3],a:t[4]}:(t=G.hex8.exec(e))?{r:B(t[1]),g:B(t[2]),b:B(t[3]),a:q(t[4]),format:n?"name":"hex8"}:(t=G.hex6.exec(e))?{r:B(t[1]),g:B(t[2]),b:B(t[3]),format:n?"name":"hex"}:(t=G.hex4.exec(e))?{r:B(t[1]+""+t[1]),g:B(t[2]+""+t[2]),b:B(t[3]+""+t[3]),a:q(t[4]+""+t[4]),format:n?"name":"hex8"}:!!(t=G.hex3.exec(e))&&{r:B(t[1]+""+t[1]),g:B(t[2]+""+t[2]),b:B(t[3]+""+t[3]),format:n?"name":"hex"}}function X(e){var t,n;return e=e||{level:"AA",size:"small"},t=(e.level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA"),"small"!==n&&"large"!==n&&(n="small"),{level:t,size:n}}e.exports?e.exports=d:(r=function(){return d}.call(t,n,t,e),void 0===r||(e.exports=r))})(Math)},ZxFD:function(e,t,n){"use strict";n.r(t),n.d(t,"create",function(){return i}),n.d(t,"clone",function(){return o}),n.d(t,"fromValues",function(){return a}),n.d(t,"copy",function(){return s}),n.d(t,"set",function(){return l}),n.d(t,"add",function(){return c}),n.d(t,"subtract",function(){return u}),n.d(t,"multiply",function(){return h}),n.d(t,"divide",function(){return d}),n.d(t,"ceil",function(){return f}),n.d(t,"floor",function(){return p}),n.d(t,"min",function(){return m}),n.d(t,"max",function(){return g}),n.d(t,"round",function(){return v}),n.d(t,"scale",function(){return y}),n.d(t,"scaleAndAdd",function(){return b}),n.d(t,"distance",function(){return w}),n.d(t,"squaredDistance",function(){return x}),n.d(t,"length",function(){return E}),n.d(t,"squaredLength",function(){return C}),n.d(t,"negate",function(){return S}),n.d(t,"inverse",function(){return k}),n.d(t,"normalize",function(){return _}),n.d(t,"dot",function(){return O}),n.d(t,"cross",function(){return A}),n.d(t,"lerp",function(){return M}),n.d(t,"random",function(){return T}),n.d(t,"transformMat2",function(){return P}),n.d(t,"transformMat2d",function(){return R}),n.d(t,"transformMat3",function(){return L}),n.d(t,"transformMat4",function(){return D}),n.d(t,"rotate",function(){return N}),n.d(t,"angle",function(){return j}),n.d(t,"zero",function(){return $}),n.d(t,"str",function(){return I}),n.d(t,"exactEquals",function(){return F}),n.d(t,"equals",function(){return V}),n.d(t,"len",function(){return B}),n.d(t,"sub",function(){return W}),n.d(t,"mul",function(){return H}),n.d(t,"div",function(){return U}),n.d(t,"dist",function(){return z}),n.d(t,"sqrDist",function(){return K}),n.d(t,"sqrLen",function(){return q}),n.d(t,"forEach",function(){return G});var r=n("yU0y");function i(){var e=new r["a"](2);return r["a"]!=Float32Array&&(e[0]=0,e[1]=0),e}function o(e){var t=new r["a"](2);return t[0]=e[0],t[1]=e[1],t}function a(e,t){var n=new r["a"](2);return n[0]=e,n[1]=t,n}function s(e,t){return e[0]=t[0],e[1]=t[1],e}function l(e,t,n){return e[0]=t,e[1]=n,e}function c(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function u(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function h(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e}function d(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e}function f(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e}function p(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e}function m(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function g(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}function v(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e}function y(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function b(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e}function w(e,t){var n=t[0]-e[0],r=t[1]-e[1];return Math.hypot(n,r)}function x(e,t){var n=t[0]-e[0],r=t[1]-e[1];return n*n+r*r}function E(e){var t=e[0],n=e[1];return Math.hypot(t,n)}function C(e){var t=e[0],n=e[1];return t*t+n*n}function S(e,t){return e[0]=-t[0],e[1]=-t[1],e}function k(e,t){return e[0]=1/t[0],e[1]=1/t[1],e}function _(e,t){var n=t[0],r=t[1],i=n*n+r*r;return i>0&&(i=1/Math.sqrt(i)),e[0]=t[0]*i,e[1]=t[1]*i,e}function O(e,t){return e[0]*t[0]+e[1]*t[1]}function A(e,t,n){var r=t[0]*n[1]-t[1]*n[0];return e[0]=e[1]=0,e[2]=r,e}function M(e,t,n,r){var i=t[0],o=t[1];return e[0]=i+r*(n[0]-i),e[1]=o+r*(n[1]-o),e}function T(e,t){t=t||1;var n=2*r["c"]()*Math.PI;return e[0]=Math.cos(n)*t,e[1]=Math.sin(n)*t,e}function P(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i,e[1]=n[1]*r+n[3]*i,e}function R(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function L(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[3]*i+n[6],e[1]=n[1]*r+n[4]*i+n[7],e}function D(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[4]*i+n[12],e[1]=n[1]*r+n[5]*i+n[13],e}function N(e,t,n,r){var i=t[0]-n[0],o=t[1]-n[1],a=Math.sin(r),s=Math.cos(r);return e[0]=i*s-o*a+n[0],e[1]=i*a+o*s+n[1],e}function j(e,t){var n=e[0],r=e[1],i=t[0],o=t[1],a=Math.sqrt(n*n+r*r)*Math.sqrt(i*i+o*o),s=a&&(n*i+r*o)/a;return Math.acos(Math.min(Math.max(s,-1),1))}function $(e){return e[0]=0,e[1]=0,e}function I(e){return"vec2("+e[0]+", "+e[1]+")"}function F(e,t){return e[0]===t[0]&&e[1]===t[1]}function V(e,t){var n=e[0],i=e[1],o=t[0],a=t[1];return Math.abs(n-o)<=r["b"]*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(i-a)<=r["b"]*Math.max(1,Math.abs(i),Math.abs(a))}var B=E,W=u,H=h,U=d,z=w,K=x,q=C,G=function(){var e=i();return function(t,n,r,i,o,a){var s,l;for(n||(n=2),r||(r=0),l=i?Math.min(i*n+r,t.length):t.length,s=r;se.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)t+=n[r].value;else t=1;e.value=t}var i=function(){return this.eachAfter(r)};function o(e,t){var n;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=a(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,s=!0,l=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){l=!0,o=e},f:function(){try{s||null==n.return||n.return()}finally{if(l)throw o}}}}function a(e,t){if(e){if("string"===typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0;--r)o.push(n[r]);return this},u=function(e,t){var n,r,i,o=this,a=[o],s=[],l=-1;while(o=a.pop())if(s.push(o),n=o.children)for(r=0,i=n.length;r=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,o=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function d(e,t){if(e){if("string"===typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?f(e,t):void 0}}function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)n+=r[i].value;t.value=n})},g=function(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})},v=function(e){var t=this,n=y(t,e),r=[t];while(t!==n)t=t.parent,r.push(t);var i=r.length;while(e!==n)r.splice(i,0,e),e=e.parent;return r};function y(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;e=n.pop(),t=r.pop();while(e===t)i=e,e=n.pop(),t=r.pop();return i}var b=function(){var e=this,t=[e];while(e=e.parent)t.push(e);return t},w=function(){return Array.from(this)},x=function(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e},E=function(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t},C=n("d6i3"),S=n.n(C),k=S.a.mark(_);function _(){var e,t,n,r,i,o;return S.a.wrap(function(a){while(1)switch(a.prev=a.next){case 0:e=this,n=[e];case 1:t=n.reverse(),n=[];case 2:if(!(e=t.pop())){a.next=8;break}return a.next=5,e;case 5:if(r=e.children)for(i=0,o=r.length;i=0;--o)l.push(r=i[o]=new L(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(R)}function A(){return O(this).eachBefore(P)}function M(e){return e.children}function T(e){return Array.isArray(e)?e[1]:null}function P(e){void 0!==e.data.value&&(e.value=e.data.value),e.data=e.data.data}function R(e){var t=0;do{e.height=t}while((e=e.parent)&&e.height<++t)}function L(e){this.data=e,this.depth=this.height=0,this.parent=null}n.d(t,"c",function(){return O}),n.d(t,"b",function(){return R}),n.d(t,"a",function(){return L}),L.prototype=O.prototype={constructor:L,count:i,each:l,eachAfter:u,eachBefore:c,find:p,sum:m,sort:g,path:v,ancestors:b,descendants:w,leaves:x,links:E,copy:A,[Symbol.iterator]:_}},aSE1:function(e,t,n){"use strict";var r=n("V5/1"),i=n("pQGJ");e.exports=function(e,t,n){t in e?r.f(e,t,i(0,n)):e[t]=n}},adOz:function(e,t,n){n("Zxgi")("asyncIterator")},agew:function(e,t,n){"use strict";var r=n("iCc5"),i=n.n(r),o=n("FYw3"),a=n.n(o),s=n("mRg0"),l=n.n(s),c=n("q1tI"),u=n.n(c),h=n("i8i4"),d=n.n(h),f=n("17x9"),p=n.n(f),m=n("VCL8"),g=n("2GS6"),v=n("4IlW"),y={adjustX:1,adjustY:1},b=[0,0],w={bottomLeft:{points:["tl","tl"],overflow:y,offset:[0,-3],targetOffset:b},bottomRight:{points:["tr","tr"],overflow:y,offset:[0,-3],targetOffset:b},topRight:{points:["br","br"],overflow:y,offset:[0,3],targetOffset:b},topLeft:{points:["bl","bl"],overflow:y,offset:[0,3],targetOffset:b}},x=w,E=n("uciX");function C(){}function S(e,t){this[e]=t}var k=function(e){function t(n){i()(this,t);var r=a()(this,e.call(this,n));_.call(r);var o=void 0;o="open"in n?n.open:n.defaultOpen;var s=n.value||n.defaultValue;return r.saveCalendarRef=S.bind(r,"calendarInstance"),r.state={open:o,value:s},r}return l()(t,e),t.prototype.componentDidUpdate=function(e,t){!t.open&&this.state.open&&(this.focusTimeout=setTimeout(this.focusCalendar,0,this))},t.prototype.componentWillUnmount=function(){clearTimeout(this.focusTimeout)},t.getDerivedStateFromProps=function(e){var t={},n=e.value,r=e.open;return"value"in e&&(t.value=n),void 0!==r&&(t.open=r),t},t.prototype.render=function(){var e=this.props,t=e.prefixCls,n=e.placement,r=e.style,i=e.getCalendarContainer,o=e.align,a=e.animation,s=e.disabled,l=e.dropdownClassName,c=e.transitionName,h=e.children,d=this.state;return u.a.createElement(E["a"],{popup:this.getCalendarElement(),popupAlign:o,builtinPlacements:x,popupPlacement:n,action:s&&!d.open?[]:["click"],destroyPopupOnHide:!0,getPopupContainer:i,popupStyle:r,popupAnimation:a,popupTransitionName:c,popupVisible:d.open,onPopupVisibleChange:this.onVisibleChange,prefixCls:t,popupClassName:l},u.a.cloneElement(h(d,e),{onKeyDown:this.onKeyDown}))},t}(u.a.Component);k.propTypes={animation:p.a.oneOfType([p.a.func,p.a.string]),disabled:p.a.bool,transitionName:p.a.string,onChange:p.a.func,onOpenChange:p.a.func,children:p.a.func,getCalendarContainer:p.a.func,calendar:p.a.element,style:p.a.object,open:p.a.bool,defaultOpen:p.a.bool,prefixCls:p.a.string,placement:p.a.any,value:p.a.oneOfType([p.a.object,p.a.array]),defaultValue:p.a.oneOfType([p.a.object,p.a.array]),align:p.a.object,dateRender:p.a.func,onBlur:p.a.func},k.defaultProps={prefixCls:"rc-calendar-picker",style:{},align:{},placement:"bottomLeft",defaultOpen:!1,onChange:C,onOpenChange:C,onBlur:C};var _=function(){var e=this;this.onCalendarKeyDown=function(t){t.keyCode===v["a"].ESC&&(t.stopPropagation(),e.close(e.focus))},this.onCalendarSelect=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e.props;"value"in r||e.setState({value:t}),("keyboard"===n.source||"dateInputSelect"===n.source||!r.calendar.props.timePicker&&"dateInput"!==n.source||"todayButton"===n.source)&&e.close(e.focus),r.onChange(t)},this.onKeyDown=function(t){e.state.open||t.keyCode!==v["a"].DOWN&&t.keyCode!==v["a"].ENTER||(e.open(),t.preventDefault())},this.onCalendarOk=function(){e.close(e.focus)},this.onCalendarClear=function(){e.close(e.focus)},this.onCalendarBlur=function(){e.setOpen(!1)},this.onVisibleChange=function(t){e.setOpen(t)},this.getCalendarElement=function(){var t=e.props,n=e.state,r=t.calendar.props,i=n.value,o=i,a={ref:e.saveCalendarRef,defaultValue:o||r.defaultValue,selectedValue:i,onKeyDown:e.onCalendarKeyDown,onOk:Object(g["a"])(r.onOk,e.onCalendarOk),onSelect:Object(g["a"])(r.onSelect,e.onCalendarSelect),onClear:Object(g["a"])(r.onClear,e.onCalendarClear),onBlur:Object(g["a"])(r.onBlur,e.onCalendarBlur)};return u.a.cloneElement(t.calendar,a)},this.setOpen=function(t,n){var r=e.props.onOpenChange;e.state.open!==t&&("open"in e.props||e.setState({open:t},n),r(t))},this.open=function(t){e.setOpen(!0,t)},this.close=function(t){e.setOpen(!1,t)},this.focus=function(){e.state.open||d.a.findDOMNode(e).focus()},this.focusCalendar=function(){e.state.open&&e.calendarInstance&&e.calendarInstance.focus()}};Object(m["polyfill"])(k);t["a"]=k},"ar/p":function(e,t,n){var r=n("5vMV"),i=n("FpHa").concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},b5re:function(e,t,n){e.exports=n("VyuQ")("native-function-to-string",Function.toString)},b9EY:function(e,t){e.exports=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/},bALw:function(e,t,n){var r=n("49sm");e.exports=y,e.exports.parse=o,e.exports.compile=a,e.exports.tokensToFunction=c,e.exports.tokensToRegExp=v;var i=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function o(e,t){var n,r=[],o=0,a=0,s="",l=t&&t.delimiter||"/";while(null!=(n=i.exec(e))){var c=n[0],d=n[1],f=n.index;if(s+=e.slice(a,f),a=f+c.length,d)s+=d[1];else{var p=e[a],m=n[2],g=n[3],v=n[4],y=n[5],b=n[6],w=n[7];s&&(r.push(s),s="");var x=null!=m&&null!=p&&p!==m,E="+"===b||"*"===b,C="?"===b||"*"===b,S=n[2]||l,k=v||y;r.push({name:g||o++,prefix:m||"",delimiter:S,optional:C,repeat:E,partial:x,asterisk:!!w,pattern:k?h(k):w?".*":"[^"+u(S)+"]+?"})}}return a=0?parseFloat((o.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((o.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),t.isOldIE=t.isIE&&t.isIE<9,t.isGecko=t.isMozilla=o.match(/ Gecko\/\d+/),t.isOpera="object"==typeof opera&&"[object Opera]"==Object.prototype.toString.call(window.opera),t.isWebKit=parseFloat(o.split("WebKit/")[1])||void 0,t.isChrome=parseFloat(o.split(" Chrome/")[1])||void 0,t.isEdge=parseFloat(o.split(" Edge/")[1])||void 0,t.isAIR=o.indexOf("AdobeAIR")>=0,t.isAndroid=o.indexOf("Android")>=0,t.isChromeOS=o.indexOf(" CrOS ")>=0,t.isIOS=/iPad|iPhone|iPod/.test(o)&&!window.MSStream,t.isIOS&&(t.isMac=!0),t.isMobile=t.isIOS||t.isAndroid}),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("./useragent"),i="http://www.w3.org/1999/xhtml";if(t.buildDom=function e(t,n,r){if("string"==typeof t&&t){var i=document.createTextNode(t);return n&&n.appendChild(i),i}if(!Array.isArray(t))return t&&t.appendChild&&n&&n.appendChild(t),t;if("string"!=typeof t[0]||!t[0]){for(var o=[],a=0;a=1.5,"undefined"!==typeof document){var o=document.createElement("div");t.HI_DPI&&void 0!==o.style.transform&&(t.HAS_CSS_TRANSFORMS=!0),r.isEdge||"undefined"===typeof o.style.animationName||(t.HAS_CSS_ANIMATION=!0),o=null}t.HAS_CSS_TRANSFORMS?t.translate=function(e,t,n){e.style.transform="translate("+Math.round(t)+"px, "+Math.round(n)+"px)"}:t.translate=function(e,t,n){e.style.top=Math.round(n)+"px",e.style.left=Math.round(t)+"px"}}),ace.define("ace/lib/oop",["require","exports","module"],function(e,t,n){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./oop"),i=function(){var e,t,n={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta",91:"MetaLeft",92:"MetaRight",93:"ContextMenu"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,super:8,meta:8,command:8,cmd:8,control:1},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete",96:"Numpad0",97:"Numpad1",98:"Numpad2",99:"Numpad3",100:"Numpad4",101:"Numpad5",102:"Numpad6",103:"Numpad7",104:"Numpad8",105:"Numpad9","-13":"NumpadEnter",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",61:"=",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",107:"+",109:"-",110:".",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",111:"/",106:"*"}};for(t in n.FUNCTION_KEYS)e=n.FUNCTION_KEYS[t].toLowerCase(),n[e]=parseInt(t,10);for(t in n.PRINTABLE_KEYS)e=n.PRINTABLE_KEYS[t].toLowerCase(),n[e]=parseInt(t,10);return r.mixin(n,n.MODIFIER_KEYS),r.mixin(n,n.PRINTABLE_KEYS),r.mixin(n,n.FUNCTION_KEYS),n.enter=n["return"],n.escape=n.esc,n.del=n["delete"],n[173]="-",function(){for(var e=["cmd","ctrl","alt","shift"],t=Math.pow(2,e.length);t--;)n.KEY_MODS[t]=e.filter(function(e){return t&n.KEY_MODS[e]}).join("-")+"-"}(),n.KEY_MODS[0]="",n.KEY_MODS[-1]="input-",n}();r.mixin(t,i),t.keyCodeToString=function(e){var t=i[e];return"string"!=typeof t&&(t=String.fromCharCode(e)),t.toLowerCase()}}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";var r,i=e("./keys"),o=e("./useragent"),a=null,s=0;function l(){r=!1;try{document.createComment("").addEventListener("test",function(){},{get passive(){r={passive:!1}}})}catch(e){}}function c(){return void 0==r&&l(),r}function u(e,t,n){this.elem=e,this.type=t,this.callback=n}u.prototype.destroy=function(){d(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var h=t.addListener=function(e,t,n,r){e.addEventListener(t,n,c()),r&&r.$toDestroy.push(new u(e,t,n))},d=t.removeListener=function(e,t,n){e.removeEventListener(t,n,c())};t.stopEvent=function(e){return t.stopPropagation(e),t.preventDefault(e),!1},t.stopPropagation=function(e){e.stopPropagation&&e.stopPropagation()},t.preventDefault=function(e){e.preventDefault&&e.preventDefault()},t.getButton=function(e){return"dblclick"==e.type?0:"contextmenu"==e.type||o.isMac&&e.ctrlKey&&!e.altKey&&!e.shiftKey?2:e.button},t.capture=function(e,t,n){var r=e&&e.ownerDocument||document;function i(e){t&&t(e),n&&n(e),d(r,"mousemove",t),d(r,"mouseup",i),d(r,"dragstart",i)}return h(r,"mousemove",t),h(r,"mouseup",i),h(r,"dragstart",i),i},t.addMouseWheelListener=function(e,t,n){"onmousewheel"in e?h(e,"mousewheel",function(e){var n=8;void 0!==e.wheelDeltaX?(e.wheelX=-e.wheelDeltaX/n,e.wheelY=-e.wheelDeltaY/n):(e.wheelX=0,e.wheelY=-e.wheelDelta/n),t(e)},n):"onwheel"in e?h(e,"wheel",function(e){var n=.35;switch(e.deltaMode){case e.DOM_DELTA_PIXEL:e.wheelX=e.deltaX*n||0,e.wheelY=e.deltaY*n||0;break;case e.DOM_DELTA_LINE:case e.DOM_DELTA_PAGE:e.wheelX=5*(e.deltaX||0),e.wheelY=5*(e.deltaY||0);break}t(e)},n):h(e,"DOMMouseScroll",function(e){e.axis&&e.axis==e.HORIZONTAL_AXIS?(e.wheelX=5*(e.detail||0),e.wheelY=0):(e.wheelX=0,e.wheelY=5*(e.detail||0)),t(e)},n)},t.addMultiMouseDownListener=function(e,n,r,i,a){var s,l,c,u=0,d={2:"dblclick",3:"tripleclick",4:"quadclick"};function f(e){if(0!==t.getButton(e)?u=0:e.detail>1?(u++,u>4&&(u=1)):u=1,o.isIE){var a=Math.abs(e.clientX-s)>5||Math.abs(e.clientY-l)>5;c&&!a||(u=1),c&&clearTimeout(c),c=setTimeout(function(){c=null},n[u-1]||600),1==u&&(s=e.clientX,l=e.clientY)}if(e._clicks=u,r[i]("mousedown",e),u>4)u=0;else if(u>1)return r[i](d[u],e)}Array.isArray(e)||(e=[e]),e.forEach(function(e){h(e,"mousedown",f,a)})};var f=function(e){return 0|(e.ctrlKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.metaKey?8:0)};function p(e,t,n){var r=f(t);if(!o.isMac&&a){if(t.getModifierState&&(t.getModifierState("OS")||t.getModifierState("Win"))&&(r|=8),a.altGr){if(3==(3&r))return;a.altGr=0}if(18===n||17===n){var l="location"in t?t.location:t.keyLocation;if(17===n&&1===l)1==a[n]&&(s=t.timeStamp);else if(18===n&&3===r&&2===l){var c=t.timeStamp-s;c<50&&(a.altGr=!0)}}}if(n in i.MODIFIER_KEYS&&(n=-1),!r&&13===n){l="location"in t?t.location:t.keyLocation;if(3===l&&(e(t,r,-n),t.defaultPrevented))return}if(o.isChromeOS&&8&r){if(e(t,r,n),t.defaultPrevented)return;r&=-9}return!!(r||n in i.FUNCTION_KEYS||n in i.PRINTABLE_KEYS)&&e(t,r,n)}function m(){a=Object.create(null)}if(t.getModifierString=function(e){return i.KEY_MODS[f(e)]},t.addCommandKeyListener=function(e,n,r){if(o.isOldGecko||o.isOpera&&!("KeyboardEvent"in window)){var i=null;h(e,"keydown",function(e){i=e.keyCode},r),h(e,"keypress",function(e){return p(n,e,i)},r)}else{var s=null;h(e,"keydown",function(e){a[e.keyCode]=(a[e.keyCode]||0)+1;var t=p(n,e,e.keyCode);return s=e.defaultPrevented,t},r),h(e,"keypress",function(e){s&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey)&&(t.stopEvent(e),s=null)},r),h(e,"keyup",function(e){a[e.keyCode]=null},r),a||(m(),h(window,"focus",m))}},"object"==typeof window&&window.postMessage&&!o.isOldIE){var g=1;t.nextTick=function(e,n){n=n||window;var r="zero-timeout-message-"+g++,i=function(o){o.data==r&&(t.stopPropagation(o),d(n,"message",i),e())};h(n,"message",i),n.postMessage(r,"*")}}t.$idleBlocked=!1,t.onIdle=function(e,n){return setTimeout(function n(){t.$idleBlocked?setTimeout(n,100):e()},n)},t.$idleBlockId=null,t.blockIdle=function(e){t.$idleBlockId&&clearTimeout(t.$idleBlockId),t.$idleBlocked=!0,t.$idleBlockId=setTimeout(function(){t.$idleBlocked=!1},e||100)},t.nextFrame="object"==typeof window&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),t.nextFrame?t.nextFrame=t.nextFrame.bind(window):t.nextFrame=function(e){setTimeout(e,17)}}),ace.define("ace/range",["require","exports","module"],function(e,t,n){"use strict";var r=function(e,t){return e.row-t.row||e.column-t.column},i=function(e,t,n,r){this.start={row:e,column:t},this.end={row:n,column:r}};(function(){this.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column},this.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},this.contains=function(e,t){return 0==this.compare(e,t)},this.compareRange=function(e){var t,n=e.end,r=e.start;return t=this.compare(n.row,n.column),1==t?(t=this.compare(r.row,r.column),1==t?2:0==t?1:0):-1==t?-2:(t=this.compare(r.row,r.column),-1==t?-1:1==t?42:0)},this.comparePoint=function(e){return this.compare(e.row,e.column)},this.containsRange=function(e){return 0==this.comparePoint(e.start)&&0==this.comparePoint(e.end)},this.intersects=function(e){var t=this.compareRange(e);return-1==t||0==t||1==t},this.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},this.isStart=function(e,t){return this.start.row==e&&this.start.column==t},this.setStart=function(e,t){"object"==typeof e?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},this.setEnd=function(e,t){"object"==typeof e?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},this.inside=function(e,t){return 0==this.compare(e,t)&&(!this.isEnd(e,t)&&!this.isStart(e,t))},this.insideStart=function(e,t){return 0==this.compare(e,t)&&!this.isEnd(e,t)},this.insideEnd=function(e,t){return 0==this.compare(e,t)&&!this.isStart(e,t)},this.compare=function(e,t){return this.isMultiLine()||e!==this.start.row?ethis.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0:tthis.end.column?1:0},this.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},this.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.clipRows=function(e,t){if(this.end.row>t)var n={row:t+1,column:0};else if(this.end.rowt)var r={row:t+1,column:0};else if(this.start.row0)1&t&&(n+=e),(t>>=1)&&(e+=e);return n};var r=/^\s\s*/,i=/\s\s*$/;t.stringTrimLeft=function(e){return e.replace(r,"")},t.stringTrimRight=function(e){return e.replace(i,"")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){for(var t=[],n=0,r=e.length;nDate.now()-50)||(r=!1)},cancel:function(){r=Date.now()}}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),o=e("../lib/dom"),a=e("../lib/lang"),s=e("../clipboard"),l=i.isChrome<18,c=i.isIE,u=i.isChrome>63,h=400,d=e("../lib/keys"),f=d.KEY_MODS,p=i.isIOS,m=p?/\s/:/\n/,g=i.isMobile,v=function(e,t){var n=o.createElement("textarea");n.className="ace_text-input",n.setAttribute("wrap","off"),n.setAttribute("autocorrect","off"),n.setAttribute("autocapitalize","off"),n.setAttribute("spellcheck",!1),n.style.opacity="0",e.insertBefore(n,e.firstChild);var v=!1,y=!1,b=!1,w=!1,x="";g||(n.style.fontSize="1px");var E=!1,C=!1,S="",k=0,_=0,O=0;try{var A=document.activeElement===n}catch(e){}r.addListener(n,"blur",function(e){C||(t.onBlur(e),A=!1)},t),r.addListener(n,"focus",function(e){if(!C){if(A=!0,i.isEdge)try{if(!document.hasFocus())return}catch(e){}t.onFocus(e),i.isEdge?setTimeout(M):M()}},t),this.$focusScroll=!1,this.focus=function(){if(x||u||"browser"==this.$focusScroll)return n.focus({preventScroll:!0});var e=n.style.top;n.style.position="fixed",n.style.top="0px";try{var t=0!=n.getBoundingClientRect().top}catch(e){return}var r=[];if(t){var i=n.parentElement;while(i&&1==i.nodeType)r.push(i),i.setAttribute("ace_nocontext",!0),i=!i.parentElement&&i.getRootNode?i.getRootNode().host:i.parentElement}n.focus({preventScroll:!0}),t&&r.forEach(function(e){e.removeAttribute("ace_nocontext")}),setTimeout(function(){n.style.position="","0px"==n.style.top&&(n.style.top=e)},0)},this.blur=function(){n.blur()},this.isFocused=function(){return A},t.on("beforeEndOperation",function(){var e=t.curOp,r=e&&e.command&&e.command.name;if("insertstring"!=r){var i=r&&(e.docChanged||e.selectionChanged);b&&i&&(S=n.value="",H()),M()}});var M=p?function(e){if(A&&(!v||e)&&!w){e||(e="");var r="\n ab"+e+"cde fg\n";r!=n.value&&(n.value=S=r);var i=4,o=4+(e.length||(t.selection.isEmpty()?0:1));k==i&&_==o||n.setSelectionRange(i,o),k=i,_=o}}:function(){if(!b&&!w&&(A||L)){b=!0;var e=0,r=0,i="";if(t.session){var o=t.selection,a=o.getRange(),s=o.cursor.row;if(e=a.start.column,r=a.end.column,i=t.session.getLine(s),a.start.row!=s){var l=t.session.getLine(s-1);e=a.start.rows+1?c.length:r,r+=i.length+1,i=i+"\n"+c}else g&&s>0&&(i="\n"+i,r+=1,e+=1);i.length>h&&(e=S.length&&e.value===S&&S&&e.selectionEnd!==_},P=function(e){b||(v?v=!1:T(n)?(t.selectAll(),M()):g&&n.selectionStart!=k&&M())},R=null;this.setInputHandler=function(e){R=e},this.getInputHandler=function(){return R};var L=!1,D=function(e,r){if(L&&(L=!1),y)return M(),e&&t.onPaste(e),y=!1,"";var o=n.selectionStart,a=n.selectionEnd,s=k,l=S.length-_,c=e,u=e.length-o,h=e.length-a,d=0;while(s>0&&S[d]==e[d])d++,s--;c=c.slice(d),d=1;while(l>0&&S.length-d>k-1&&S[S.length-d]==e[e.length-d])d++,l--;u-=d-1,h-=d-1;var f=c.length-d+1;if(f<0&&(s=-f,f=0),c=c.slice(0,f),!r&&!c&&!u&&!s&&!l&&!h)return"";w=!0;var p=!1;return i.isAndroid&&". "==c&&(c=" ",p=!0),c&&!s&&!l&&!u&&!h||E?t.onTextInput(c):t.onTextInput(c,{extendLeft:s,extendRight:l,restoreStart:u,restoreEnd:h}),w=!1,S=e,k=o,_=a,O=h,p?"\n":c},N=function(e){if(b)return W();if(e&&e.inputType){if("historyUndo"==e.inputType)return t.execCommand("undo");if("historyRedo"==e.inputType)return t.execCommand("redo")}var r=n.value,i=D(r,!0);(r.length>h+100||m.test(i)||g&&k<1&&k==_)&&M()},j=function(e,t,n){var r=e.clipboardData||window.clipboardData;if(r&&!l){var i=c||n?"Text":"text/plain";try{return t?!1!==r.setData(i,t):r.getData(i)}catch(e){if(!n)return j(e,t,!0)}}},$=function(e,i){var o=t.getCopyText();if(!o)return r.preventDefault(e);j(e,o)?(p&&(M(o),v=o,setTimeout(function(){v=!1},10)),i?t.onCut():t.onCopy(),r.preventDefault(e)):(v=!0,n.value=o,n.select(),setTimeout(function(){v=!1,M(),i?t.onCut():t.onCopy()}))},I=function(e){$(e,!0)},F=function(e){$(e,!1)},V=function(e){var o=j(e);s.pasteCancelled()||("string"==typeof o?(o&&t.onPaste(o,e),i.isIE&&setTimeout(M),r.preventDefault(e)):(n.value="",y=!0))};r.addCommandKeyListener(n,t.onCommandKey.bind(t),t),r.addListener(n,"select",P,t),r.addListener(n,"input",N,t),r.addListener(n,"cut",I,t),r.addListener(n,"copy",F,t),r.addListener(n,"paste",V,t),"oncut"in n&&"oncopy"in n&&"onpaste"in n||r.addListener(e,"keydown",function(e){if((!i.isMac||e.metaKey)&&e.ctrlKey)switch(e.keyCode){case 67:F(e);break;case 86:V(e);break;case 88:I(e);break}},t);var B=function(e){if(!b&&t.onCompositionStart&&!t.$readOnly&&(b={},!E)){e.data&&(b.useTextareaForIME=!1),setTimeout(W,0),t._signal("compositionStart"),t.on("mousedown",U);var r=t.getSelectionRange();r.end.row=r.start.row,r.end.column=r.start.column,b.markerRange=r,b.selectionStart=k,t.onCompositionStart(b),b.useTextareaForIME?(S=n.value="",k=0,_=0):(n.msGetInputContext&&(b.context=n.msGetInputContext()),n.getInputContext&&(b.context=n.getInputContext()))}},W=function(){if(b&&t.onCompositionUpdate&&!t.$readOnly){if(E)return U();if(b.useTextareaForIME)t.onCompositionUpdate(n.value);else{var e=n.value;D(e),b.markerRange&&(b.context&&(b.markerRange.start.column=b.selectionStart=b.context.compositionStartOffset),b.markerRange.end.column=b.markerRange.start.column+_-b.selectionStart+O)}}},H=function(e){t.onCompositionEnd&&!t.$readOnly&&(b=!1,t.onCompositionEnd(),t.off("mousedown",U),e&&N())};function U(){C=!0,n.blur(),n.focus(),C=!1}var z,K=a.delayedCall(W,50).schedule.bind(null,null);function q(e){27==e.keyCode&&n.value.length_&&"\n"==S[o]?a=d.end:r_&&S.slice(0,o).split("\n").length>2?a=d.down:o>_&&" "==S[o-1]?(a=d.right,s=f.option):(o>_||o==_&&_!=k&&r==o)&&(a=d.right),r!==o&&(s|=f.shift),a){var l=t.onCommandKey({},s,a);if(!l&&t.commands){a=d.keyCodeToString(a);var c=t.commands.findKeyCommand(s,a);c&&t.execCommand(c)}k=r,_=o,M("")}}};document.addEventListener("selectionchange",o),t.on("destroy",function(){document.removeEventListener("selectionchange",o)})}r.addListener(n,"mouseup",Y,t),r.addListener(n,"mousedown",function(e){e.preventDefault(),G()},t),r.addListener(t.renderer.scroller,"contextmenu",Y,t),r.addListener(n,"contextmenu",Y,t),p&&Q(e,t,n)};t.TextInput=v,t.$setUserAgentForTests=function(e,t){g=e,p=t}}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/useragent"),i=0,o=550;function a(e){e.$clickSelection=null;var t=e.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(e)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(e)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(e)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(e)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(e));var n=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];n.forEach(function(t){e[t]=this[t]},this),e.selectByLines=this.extendSelectionBy.bind(e,"getLineRange"),e.selectByWords=this.extendSelectionBy.bind(e,"getWordRange")}function s(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}function l(e,t){if(e.start.row==e.end.row)var n=2*t.column-e.start.column-e.end.column;else if(e.start.row!=e.end.row-1||e.start.column||e.end.column)n=2*t.row-e.start.row-e.end.row;else var n=t.column-4;return n<0?{cursor:e.start,anchor:e.end}:{cursor:e.end,anchor:e.start}}(function(){this.onMouseDown=function(e){var t=e.inSelection(),n=e.getDocumentPosition();this.mousedownEvent=e;var i=this.editor,o=e.getButton();if(0!==o){var a=i.getSelectionRange(),s=a.isEmpty();return(s||1==o)&&i.selection.moveToPosition(n),void(2==o&&(i.textInput.onContextMenu(e.domEvent),r.isMozilla||e.preventDefault()))}return this.mousedownEvent.time=Date.now(),!t||i.isFocused()||(i.focus(),!this.$focusTimeout||this.$clickSelection||i.inMultiSelectMode)?(this.captureMouse(e),this.startSelect(n,e.domEvent._clicks>1),e.preventDefault()):(this.setState("focusWait"),void this.captureMouse(e))},this.startSelect=function(e,t){e=e||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var n=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?n.selection.selectToPosition(e):t||n.selection.moveToPosition(e),t||this.select(),n.renderer.scroller.setCapture&&n.renderer.scroller.setCapture(),n.setStyle("ace_selecting"),this.setState("select"))},this.select=function(){var e,t=this.editor,n=t.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var r=this.$clickSelection.comparePoint(n);if(-1==r)e=this.$clickSelection.end;else if(1==r)e=this.$clickSelection.start;else{var i=l(this.$clickSelection,n);n=i.cursor,e=i.anchor}t.selection.setSelectionAnchor(e.row,e.column)}t.selection.selectToPosition(n),t.renderer.scrollCursorIntoView()},this.extendSelectionBy=function(e){var t,n=this.editor,r=n.renderer.screenToTextCoordinates(this.x,this.y),i=n.selection[e](r.row,r.column);if(this.$clickSelection){var o=this.$clickSelection.comparePoint(i.start),a=this.$clickSelection.comparePoint(i.end);if(-1==o&&a<=0)t=this.$clickSelection.end,i.end.row==r.row&&i.end.column==r.column||(r=i.start);else if(1==a&&o>=0)t=this.$clickSelection.start,i.start.row==r.row&&i.start.column==r.column||(r=i.end);else if(-1==o&&1==a)r=i.end,t=i.start;else{var s=l(this.$clickSelection,r);r=s.cursor,t=s.anchor}n.selection.setSelectionAnchor(t.row,t.column)}n.selection.selectToPosition(r),n.renderer.scrollCursorIntoView()},this.selectEnd=this.selectAllEnd=this.selectByWordsEnd=this.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting"),this.editor.renderer.scroller.releaseCapture&&this.editor.renderer.scroller.releaseCapture()},this.focusWait=function(){var e=s(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),t=Date.now();(e>i||t-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},this.onDoubleClick=function(e){var t=e.getDocumentPosition(),n=this.editor,r=n.session,i=r.getBracketRange(t);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=n.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},this.onTripleClick=function(e){var t=e.getDocumentPosition(),n=this.editor;this.setState("selectByLines");var r=n.getSelectionRange();r.isMultiLine()&&r.contains(t.row,t.column)?(this.$clickSelection=n.selection.getLineRange(r.start.row),this.$clickSelection.end=n.selection.getLineRange(r.end.row).end):this.$clickSelection=n.selection.getLineRange(t.row),this.select()},this.onQuadClick=function(e){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},this.onMouseWheel=function(e){if(!e.getAccelKey()){e.getShiftKey()&&e.wheelY&&!e.wheelX&&(e.wheelX=e.wheelY,e.wheelY=0);var t=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var n=this.$lastScroll,r=e.domEvent.timeStamp,i=r-n.t,a=i?e.wheelX/i:n.vx,s=i?e.wheelY/i:n.vy;i=1&&t.renderer.isScrollableBy(e.wheelX*e.speed,0)&&(c=!0),l<=1&&t.renderer.isScrollableBy(0,e.wheelY*e.speed)&&(c=!0),c)n.allowed=r;else if(r-n.alloweda.session.documentToScreenRow(u.row,u.column))return h()}if(i!=r)if(i=r.text.join("
"),c.setHtml(i),c.show(),a._signal("showGutterTooltip",c),a.on("mousewheel",h),e.$tooltipFollowsMouse)d(n);else{var f=n.domEvent.target,p=f.getBoundingClientRect(),m=c.getElement().style;m.left=p.right+"px",m.top=p.bottom+"px"}}function h(){t&&(t=clearTimeout(t)),i&&(c.hide(),i=null,a._signal("hideGutterTooltip",c),a.off("mousewheel",h))}function d(e){c.setPosition(e.x,e.y)}e.editor.setDefaultHandler("guttermousedown",function(t){if(a.isFocused()&&0==t.getButton()){var n=s.getRegion(t);if("foldWidgets"!=n){var r=t.getDocumentPosition().row,i=a.session.selection;if(t.getShiftKey())i.selectTo(r,0);else{if(2==t.domEvent.detail)return a.selectAll(),t.preventDefault();e.$clickSelection=a.selection.getLineRange(r)}return e.setState("selectByLines"),e.captureMouse(t),t.preventDefault()}}}),e.editor.setDefaultHandler("guttermousemove",function(o){var a=o.domEvent.target||o.domEvent.srcElement;if(r.hasCssClass(a,"ace_fold-widget"))return h();i&&e.$tooltipFollowsMouse&&d(o),n=o,t||(t=setTimeout(function(){t=null,n&&!e.isMousePressed?u():h()},50))}),o.addListener(a.renderer.$gutter,"mouseout",function(e){n=null,i&&!t&&(t=setTimeout(function(){t=null,h()},50))},a),a.on("changeSession",h)}function l(e){a.call(this,e)}i.inherits(l,a),function(){this.setPosition=function(e,t){var n=window.innerWidth||document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight,i=this.getWidth(),o=this.getHeight();e+=15,t+=15,e+i>n&&(e-=e+i-n),t+o>r&&(t-=20+o),a.prototype.setPosition.call(this,e,t)}}.call(l.prototype),t.GutterHandler=s}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),o=t.MouseEvent=function(e,t){this.domEvent=e,this.editor=t,this.x=this.clientX=e.clientX,this.y=this.clientY=e.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1};(function(){this.stopPropagation=function(){r.stopPropagation(this.domEvent),this.propagationStopped=!0},this.preventDefault=function(){r.preventDefault(this.domEvent),this.defaultPrevented=!0},this.stop=function(){this.stopPropagation(),this.preventDefault()},this.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},this.inSelection=function(){if(null!==this.$inSelection)return this.$inSelection;var e=this.editor,t=e.getSelectionRange();if(t.isEmpty())this.$inSelection=!1;else{var n=this.getDocumentPosition();this.$inSelection=t.contains(n.row,n.column)}return this.$inSelection},this.getButton=function(){return r.getButton(this.domEvent)},this.getShiftKey=function(){return this.domEvent.shiftKey},this.getAccelKey=i.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}).call(o.prototype)}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/event"),o=e("../lib/useragent"),a=200,s=200,l=5;function c(e){var t=e.editor,n=r.createElement("img");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",o.isOpera&&(n.style.cssText="width:1px;height:1px;position:fixed;top:0;left:0;z-index:2147483647;opacity:0;");var c=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];c.forEach(function(t){e[t]=this[t]},this),t.on("mousedown",this.onMouseDown.bind(e));var h,d,f,p,m,g,v,y,b,w,x,E=t.container,C=0;function S(e,n){var r=Date.now(),i=!n||e.row!=n.row,o=!n||e.column!=n.column;if(!w||i||o)t.moveCursorToPosition(e),w=r,x={x:d,y:f};else{var a=u(x.x,x.y,d,f);a>l?w=null:r-w>=s&&(t.renderer.scrollCursorIntoView(),w=null)}}function k(e,n){var r=Date.now(),i=t.renderer.layerConfig.lineHeight,o=t.renderer.layerConfig.characterWidth,s=t.renderer.scroller.getBoundingClientRect(),l={x:{left:d-s.left,right:s.right-d},y:{top:f-s.top,bottom:s.bottom-f}},c=Math.min(l.x.left,l.x.right),u=Math.min(l.y.top,l.y.bottom),h={row:e.row,column:e.column};c/o<=2&&(h.column+=l.x.left=a&&t.renderer.scrollCursorIntoView(h):b=r:b=null}function _(){var e=g;g=t.renderer.screenToTextCoordinates(d,f),S(g,e),k(g,e)}function O(){m=t.selection.toOrientedRange(),h=t.session.addMarker(m,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(p),_(),p=setInterval(_,20),C=0,i.addListener(document,"mousemove",T)}function A(){clearInterval(p),t.session.removeMarker(h),h=null,t.selection.fromOrientedRange(m),t.isFocused()&&!y&&t.$resetCursorStyle(),m=null,g=null,C=0,b=null,w=null,i.removeListener(document,"mousemove",T)}this.onDragStart=function(e){if(this.cancelDrag||!E.draggable){var r=this;return setTimeout(function(){r.startSelect(),r.captureMouse(e)},0),e.preventDefault()}m=t.getSelectionRange();var i=e.dataTransfer;i.effectAllowed=t.getReadOnly()?"copy":"copyMove",o.isOpera&&(t.container.appendChild(n),n.scrollTop=0),i.setDragImage&&i.setDragImage(n,0,0),o.isOpera&&t.container.removeChild(n),i.clearData(),i.setData("Text",t.session.getTextRange()),y=!0,this.setState("drag")},this.onDragEnd=function(e){if(E.draggable=!1,y=!1,this.setState(null),!t.getReadOnly()){var n=e.dataTransfer.dropEffect;v||"move"!=n||t.session.remove(t.getSelectionRange()),t.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(e){if(!t.getReadOnly()&&P(e.dataTransfer))return d=e.clientX,f=e.clientY,h||O(),C++,e.dataTransfer.dropEffect=v=R(e),i.preventDefault(e)},this.onDragOver=function(e){if(!t.getReadOnly()&&P(e.dataTransfer))return d=e.clientX,f=e.clientY,h||(O(),C++),null!==M&&(M=null),e.dataTransfer.dropEffect=v=R(e),i.preventDefault(e)},this.onDragLeave=function(e){if(C--,C<=0&&h)return A(),v=null,i.preventDefault(e)},this.onDrop=function(e){if(g){var n=e.dataTransfer;if(y)switch(v){case"move":m=m.contains(g.row,g.column)?{start:g,end:g}:t.moveText(m,g);break;case"copy":m=t.moveText(m,g,!0);break}else{var r=n.getData("Text");m={start:g,end:t.session.insert(g,r)},t.focus(),v=null}return A(),i.preventDefault(e)}},i.addListener(E,"dragstart",this.onDragStart.bind(e),t),i.addListener(E,"dragend",this.onDragEnd.bind(e),t),i.addListener(E,"dragenter",this.onDragEnter.bind(e),t),i.addListener(E,"dragover",this.onDragOver.bind(e),t),i.addListener(E,"dragleave",this.onDragLeave.bind(e),t),i.addListener(E,"drop",this.onDrop.bind(e),t);var M=null;function T(){null==M&&(M=setTimeout(function(){null!=M&&h&&A()},20))}function P(e){var t=e.types;return!t||Array.prototype.some.call(t,function(e){return"text/plain"==e||"Text"==e})}function R(e){var t=["copy","copymove","all","uninitialized"],n=["move","copymove","linkmove","all","uninitialized"],r=o.isMac?e.altKey:e.ctrlKey,i="uninitialized";try{i=e.dataTransfer.effectAllowed.toLowerCase()}catch(e){}var a="none";return r&&t.indexOf(i)>=0?a="copy":n.indexOf(i)>=0?a="move":t.indexOf(i)>=0&&(a="copy"),a}}function u(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}(function(){this.dragWait=function(){var e=Date.now()-this.mousedownEvent.time;e>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var e=this.editor.container;e.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(e){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var e=this.editor,t=e.container;t.draggable=!0,e.renderer.$cursorLayer.setBlinking(!1),e.setStyle("ace_dragging");var n=o.isWin?"default":"move";e.renderer.setCursorStyle(n),this.setState("dragReady")},this.onMouseDrag=function(e){var t=this.editor.container;if(o.isIE&&"dragReady"==this.state){var n=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>3&&t.dragDrop()}if("dragWait"===this.state){n=u(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(e){if(this.$dragEnabled){this.mousedownEvent=e;var t=this.editor,n=e.inSelection(),r=e.getButton(),i=e.domEvent.detail||1;if(1===i&&0===r&&n){if(e.editor.inMultiSelectMode&&(e.getAccelKey()||e.getShiftKey()))return;this.mousedownEvent.time=Date.now();var a=e.domEvent.target||e.domEvent.srcElement;if("unselectable"in a&&(a.unselectable="on"),t.getDragDelay()){if(o.isWebKit){this.cancelDrag=!0;var s=t.container;s.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(e,this.onMouseDrag.bind(this)),e.defaultPrevented=!0}}}}).call(c.prototype),t.DragdropHandler=c}),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],function(e,t,n){"use strict";var r=e("./mouse_event").MouseEvent,i=e("../lib/event"),o=e("../lib/dom");t.addTouchListeners=function(e,t){var n,a,s,l,c,u,h,d,f,p="scroll",m=0,g=0,v=0,y=0;function b(){var e=window.navigator&&window.navigator.clipboard,n=!1,r=function(){var r=t.getCopyText(),i=t.session.getUndoManager().hasUndo();f.replaceChild(o.buildDom(n?["span",!r&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],r&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],r&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],e&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],i&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],["span",{class:"ace_mobile-button",action:"find"},"Find"],["span",{class:"ace_mobile-button",action:"openCommandPallete"},"Pallete"]]:["span"]),f.firstChild)},i=function(i){var o=i.target.getAttribute("action");if("more"==o||!n)return n=!n,r();"paste"==o?e.readText().then(function(e){t.execCommand(o,e)}):o&&("cut"!=o&&"copy"!=o||(e?e.writeText(t.getCopyText()):document.execCommand("copy")),t.execCommand(o)),f.firstChild.style.display="none",n=!1,"openCommandPallete"!=o&&t.focus()};f=o.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(e){p="menu",e.stopPropagation(),e.preventDefault(),t.textInput.focus()},ontouchend:function(e){e.stopPropagation(),e.preventDefault(),i(e)},onclick:i},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],t.container)}function w(){f||b();var e=t.selection.cursor,n=t.renderer.textToScreenCoordinates(e.row,e.column),r=t.renderer.textToScreenCoordinates(0,0).pageX,i=t.renderer.scrollLeft,o=t.container.getBoundingClientRect();f.style.top=n.pageY-o.top-3+"px",n.pageX-o.left=2?t.selection.getLineRange(h.row):t.session.getBracketRange(h);e&&!e.isEmpty()?t.selection.setRange(e):t.selection.selectWord(),p="wait"}function S(){m+=60,u=setInterval(function(){m--<=0&&(clearInterval(u),u=null),Math.abs(v)<.01&&(v=0),Math.abs(y)<.01&&(y=0),m<20&&(v*=.9),m<20&&(y*=.9);var e=t.session.getScrollTop();t.renderer.scrollBy(10*v,10*y),e==t.session.getScrollTop()&&(m=0)},10)}i.addListener(e,"contextmenu",function(e){if(d){var n=t.textInput.getElement();n.focus()}},t),i.addListener(e,"touchstart",function(e){var i=e.touches;if(c||i.length>1)return clearTimeout(c),c=null,s=-1,void(p="zoom");d=t.$mouseHandler.isMousePressed=!0;var o=t.renderer.layerConfig.lineHeight,u=t.renderer.layerConfig.lineHeight,f=e.timeStamp;l=f;var b=i[0],w=b.clientX,x=b.clientY;Math.abs(n-w)+Math.abs(a-x)>o&&(s=-1),n=e.clientX=w,a=e.clientY=x,v=y=0;var S=new r(e,t);if(h=S.getDocumentPosition(),f-s<500&&1==i.length&&!m)g++,e.preventDefault(),e.button=0,C();else{g=0;var k=t.selection.cursor,_=t.selection.isEmpty()?k:t.selection.anchor,O=t.renderer.$cursorLayer.getPixelPosition(k,!0),A=t.renderer.$cursorLayer.getPixelPosition(_,!0),M=t.renderer.scroller.getBoundingClientRect(),T=t.renderer.layerConfig.offset,P=t.renderer.scrollLeft,R=function(e,t){return e/=u,t=t/o-.75,e*e+t*t};if(e.clientXD?"cursor":"anchor"),p=D<3.5?"anchor":L<3.5?"cursor":"scroll",c=setTimeout(E,450)}s=f},t),i.addListener(e,"touchend",function(e){d=t.$mouseHandler.isMousePressed=!1,u&&clearInterval(u),"zoom"==p?(p="",m=0):c?(t.selection.moveToPosition(h),m=0,w()):"scroll"==p?(S(),x()):w(),clearTimeout(c),c=null},t),i.addListener(e,"touchmove",function(e){c&&(clearTimeout(c),c=null);var i=e.touches;if(!(i.length>1||"zoom"==p)){var o=i[0],s=n-o.clientX,u=a-o.clientY;if("wait"==p){if(!(s*s+u*u>4))return e.preventDefault();p="cursor"}n=o.clientX,a=o.clientY,e.clientX=o.clientX,e.clientY=o.clientY;var h=e.timeStamp,d=h-l;if(l=h,"scroll"==p){var f=new r(e,t);f.speed=1,f.wheelX=s,f.wheelY=u,10*Math.abs(s)1&&(i=n[n.length-2]);var a=l[t+"Path"];return null==a?a=l.basePath:"/"==r&&(t=r=""),a&&"/"!=a.slice(-1)&&(a+="/"),a+t+r+i+this.get("suffix")},t.setModuleUrl=function(e,t){return l.$moduleUrls[e]=t},t.$loading={},t.loadModule=function(n,r){var i,a;Array.isArray(n)&&(a=n[0],n=n[1]);try{i=e(n)}catch(e){}if(i&&!t.$loading[n])return r&&r(i);if(t.$loading[n]||(t.$loading[n]=[]),t.$loading[n].push(r),!(t.$loading[n].length>1)){var s=function(){e([n],function(e){t._emit("load.module",{name:n,module:e});var r=t.$loading[n];t.$loading[n]=null,r.forEach(function(t){t&&t(e)})})};if(!t.get("packaged"))return s();o.loadScript(t.moduleUrl(n,a),s),c()}};var c=function(){l.basePath||l.workerPath||l.modePath||l.themePath||Object.keys(l.$moduleUrls).length||(console.error("Unable to infer path to ace from script src,","use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes","or with webpack use ace/webpack-resolver"),c=function(){})};function u(i){if(s&&s.document){l.packaged=i||e.packaged||r.packaged||s.define&&n("B9Yq").packaged;for(var o={},a="",c=document.currentScript||document._currentScript,u=c&&c.ownerDocument||document,d=u.getElementsByTagName("script"),f=0;f0)if(16==g){for(E=x;E-1){for(E=x;E=0;k--){if(u[k]!=w)break;t[k]=r}}}function D(e,t,n){if(!(i=e){o=d+1;while(o=e)o++;for(s=d,l=o-1;s=t.length||(l=n[i-1])!=p&&l!=m||(c=t[i+1])!=p&&c!=m?g:(o&&(c=m),c==l?c:g);case E:return l=i>0?n[i-1]:v,l==p&&i+10&&n[i-1]==p)return p;if(o)return g;h=i+1,u=t.length;while(h=1425&&R<=2303||64286==R;if(l=t[h],L&&(l==f||l==b))return f}return i<1||(l=t[i-1])==v?g:n[i-1];case v:return o=!1,a=!0,r;case y:return s=!0,g;case k:case _:case A:case M:case O:o=!1;case T:return g}}function j(e){var t=e.charCodeAt(0),n=t>>8;return 0==n?t>191?d:P[t]:5==n?/[\u0591-\u05f4]/.test(e)?f:d:6==n?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(e)?S:/[\u0660-\u0669\u066b-\u066c]/.test(e)?m:1642==t?C:/[\u06f0-\u06f9]/.test(e)?p:b:32==n&&t<=8287?R[255&t]:254==n&&t>=65136?b:g}t.L=d,t.R=f,t.EN=p,t.ON_R=3,t.AN=4,t.R_H=5,t.B=6,t.RLE=7,t.DOT="\xb7",t.doBidiReorder=function(e,n,i){if(e.length<2)return{};var o=e.split(""),a=new Array(o.length),s=new Array(o.length),l=[];r=i?h:u,L(o,l,o.length,n);for(var c=0;cb&&n[c]0&&"\u0644"===o[c-1]&&/\u0622|\u0623|\u0625|\u0627/.test(o[c])&&(l[c-1]=l[c]=t.R_H,c++);o[o.length-1]===t.DOT&&(l[o.length-1]=t.B),"\u202b"===o[0]&&(l[0]=t.RLE);for(c=0;c=0&&(e=this.session.$docRowCache[n])}return e},this.getSplitIndex=function(){var e=0,t=this.session.$screenRowCache;if(t.length){var n,r=this.session.$getRowCacheIndex(t,this.currentRow);while(this.currentRow-e>0){if(n=this.session.$getRowCacheIndex(t,this.currentRow-e-1),n!==r)break;r=n,e++}}else e=this.currentRow;return e},this.updateRowLine=function(e,t){void 0===e&&(e=this.getDocumentRow());var n=e===this.session.getLength()-1,o=n?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(e),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var a=this.session.$wrapData[e];a&&(void 0===t&&(t=this.getSplitIndex()),t>0&&a.length?(this.wrapIndent=a.indent,this.wrapOffset=this.wrapIndent*this.charWidths[r.L],this.line=tt?this.session.getOverwrite()?e:e-1:t,i=r.getVisualFromLogicalIdx(n,this.bidiMap),o=this.bidiMap.bidiLevels,a=0;!this.session.getOverwrite()&&e<=t&&o[i]%2!==0&&i++;for(var s=0;st&&o[i]%2===0&&(a+=this.charWidths[o[i]]),this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(a+=this.rtlLineOffset),a},this.getSelections=function(e,t){var n,r=this.bidiMap,i=r.bidiLevels,o=[],a=0,s=Math.min(e,t)-this.wrapIndent,l=Math.max(e,t)-this.wrapIndent,c=!1,u=!1,h=0;this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var d,f=0;f=s&&dn+o/2){if(n+=o,r===i.length-1){o=0;break}o=this.charWidths[i[++r]]}return r>0&&i[r-1]%2!==0&&i[r]%2===0?(e0&&i[r-1]%2===0&&i[r]%2!==0?t=1+(e>n?this.bidiMap.logicalFromVisual[r]:this.bidiMap.logicalFromVisual[r-1]):this.isRtlDir&&r===i.length-1&&0===o&&i[r-1]%2===0||!this.isRtlDir&&0===r&&i[r]%2!==0?t=1+this.bidiMap.logicalFromVisual[r]:(r>0&&i[r-1]%2!==0&&0!==o&&r--,t=this.bidiMap.logicalFromVisual[r]),0===t&&this.isRtlDir&&t++,t+this.wrapIndent}}).call(a.prototype),t.BidiHandler=a}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),o=e("./lib/event_emitter").EventEmitter,a=e("./range").Range,s=function(e){this.session=e,this.doc=e.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var t=this;this.cursor.on("change",function(e){t.$cursorChanged=!0,t.$silent||t._emit("changeCursor"),t.$isEmpty||t.$silent||t._emit("changeSelection"),t.$keepDesiredColumnOnChange||e.old.column==e.value.column||(t.$desiredColumn=null)}),this.anchor.on("change",function(){t.$anchorChanged=!0,t.$isEmpty||t.$silent||t._emit("changeSelection")})};(function(){r.implement(this,o),this.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},this.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},this.getCursor=function(){return this.lead.getPosition()},this.setSelectionAnchor=function(e,t){this.$isEmpty=!1,this.anchor.setPosition(e,t)},this.getAnchor=this.getSelectionAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},this.getSelectionLead=function(){return this.lead.getPosition()},this.isBackwards=function(){var e=this.anchor,t=this.lead;return e.row>t.row||e.row==t.row&&e.column>t.column},this.getRange=function(){var e=this.anchor,t=this.lead;return this.$isEmpty?a.fromPoints(t,t):this.isBackwards()?a.fromPoints(t,e):a.fromPoints(e,t)},this.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},this.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},this.setRange=this.setSelectionRange=function(e,t){var n=t?e.end:e.start,r=t?e.start:e.end;this.$setSelection(n.row,n.column,r.row,r.column)},this.$setSelection=function(e,t,n,r){if(!this.$silent){var i=this.$isEmpty,o=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(e,t),this.cursor.setPosition(n,r),this.$isEmpty=!a.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||i!=this.$isEmpty||o)&&this._emit("changeSelection")}},this.$moveSelection=function(e){var t=this.lead;this.$isEmpty&&this.setSelectionAnchor(t.row,t.column),e.call(this)},this.selectTo=function(e,t){this.$moveSelection(function(){this.moveCursorTo(e,t)})},this.selectToPosition=function(e){this.$moveSelection(function(){this.moveCursorToPosition(e)})},this.moveTo=function(e,t){this.clearSelection(),this.moveCursorTo(e,t)},this.moveToPosition=function(e){this.clearSelection(),this.moveCursorToPosition(e)},this.selectUp=function(){this.$moveSelection(this.moveCursorUp)},this.selectDown=function(){this.$moveSelection(this.moveCursorDown)},this.selectRight=function(){this.$moveSelection(this.moveCursorRight)},this.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},this.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},this.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},this.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},this.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},this.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},this.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},this.getWordRange=function(e,t){if("undefined"==typeof t){var n=e||this.lead;e=n.row,t=n.column}return this.session.getWordRange(e,t)},this.selectWord=function(){this.setSelectionRange(this.getWordRange())},this.selectAWord=function(){var e=this.getCursor(),t=this.session.getAWordRange(e.row,e.column);this.setSelectionRange(t)},this.getLineRange=function(e,t){var n,r="number"==typeof e?e:this.lead.row,i=this.session.getFoldLine(r);return i?(r=i.start.row,n=i.end.row):n=r,!0===t?new a(r,0,n,this.session.getLine(n).length):new a(r,0,n+1,0)},this.selectLine=function(){this.setSelectionRange(this.getLineRange())},this.moveCursorUp=function(){this.moveCursorBy(-1,0)},this.moveCursorDown=function(){this.moveCursorBy(1,0)},this.wouldMoveIntoSoftTab=function(e,t,n){var r=e.column,i=e.column+t;return n<0&&(r=e.column-t,i=e.column),this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(r,i).split(" ").length-1==t},this.moveCursorLeft=function(){var e,t=this.lead.getPosition();if(e=this.session.getFoldAt(t.row,t.column,-1))this.moveCursorTo(e.start.row,e.start.column);else if(0===t.column)t.row>0&&this.moveCursorTo(t.row-1,this.doc.getLine(t.row-1).length);else{var n=this.session.getTabSize();this.wouldMoveIntoSoftTab(t,n,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-n):this.moveCursorBy(0,-1)}},this.moveCursorRight=function(){var e,t=this.lead.getPosition();if(e=this.session.getFoldAt(t.row,t.column,1))this.moveCursorTo(e.end.row,e.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row0&&(t.column=r)}}this.moveCursorTo(t.row,t.column)},this.moveCursorFileEnd=function(){var e=this.doc.getLength()-1,t=this.doc.getLine(e).length;this.moveCursorTo(e,t)},this.moveCursorFileStart=function(){this.moveCursorTo(0,0)},this.moveCursorLongWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var i=this.session.getFoldAt(e,t,1);if(i)this.moveCursorTo(i.end.row,i.end.column);else{if(this.session.nonTokenRe.exec(r)&&(t+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,r=n.substring(t)),t>=n.length)return this.moveCursorTo(e,n.length),this.moveCursorRight(),void(e0&&this.moveCursorWordLeft());this.session.tokenRe.exec(o)&&(n-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(t,n)}},this.$shortWordEndIndex=function(e){var t,n=0,r=/\s/,i=this.session.tokenRe;if(i.lastIndex=0,this.session.tokenRe.exec(e))n=this.session.tokenRe.lastIndex;else{while((t=e[n])&&r.test(t))n++;if(n<1){i.lastIndex=0;while((t=e[n])&&!i.test(t))if(i.lastIndex=0,n++,r.test(t)){if(n>2){n--;break}while((t=e[n])&&r.test(t))n++;if(n>2)break}}}return i.lastIndex=0,n},this.moveCursorShortWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i=this.session.getFoldAt(e,t,1);if(i)return this.moveCursorTo(i.end.row,i.end.column);if(t==n.length){var o=this.doc.getLength();do{e++,r=this.doc.getLine(e)}while(e0&&/^\s*$/.test(r));n=r.length,/\s+$/.test(r)||(r="")}var o=i.stringReverse(r),a=this.$shortWordEndIndex(o);return this.moveCursorTo(t,n-a)},this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},this.moveCursorBy=function(e,t){var n,r=this.session.documentToScreenPosition(this.lead.row,this.lead.column);if(0===t&&(0!==e&&(this.session.$bidiHandler.isBidiRow(r.row,this.lead.row)?(n=this.session.$bidiHandler.getPosLeft(r.column),r.column=Math.round(n/this.session.$bidiHandler.charWidths[0])):n=r.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?r.column=this.$desiredColumn:this.$desiredColumn=r.column),0!=e&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var i=this.session.lineWidgets[this.lead.row];e<0?e-=i.rowsAbove||0:e>0&&(e+=i.rowCount-(i.rowsAbove||0))}var o=this.session.screenToDocumentPosition(r.row+e,r.column,n);0!==e&&0===t&&o.row===this.lead.row&&(o.column,this.lead.column),this.moveCursorTo(o.row,o.column+t,0===t)},this.moveCursorToPosition=function(e){this.moveCursorTo(e.row,e.column)},this.moveCursorTo=function(e,t,n){var r=this.session.getFoldAt(e,t,1);r&&(e=r.start.row,t=r.start.column),this.$keepDesiredColumnOnChange=!0;var i=this.session.getLine(e);/[\uDC00-\uDFFF]/.test(i.charAt(t))&&i.charAt(t-1)&&(this.lead.row==e&&this.lead.column==t+1?t-=1:t+=1),this.lead.setPosition(e,t),this.$keepDesiredColumnOnChange=!1,n||(this.$desiredColumn=null)},this.moveCursorToScreen=function(e,t,n){var r=this.session.screenToDocumentPosition(e,t);this.moveCursorTo(r.row,r.column,n)},this.detach=function(){this.lead.detach(),this.anchor.detach(),this.session=this.doc=null},this.fromOrientedRange=function(e){this.setSelectionRange(e,e.cursor==e.start),this.$desiredColumn=e.desiredColumn||this.$desiredColumn},this.toOrientedRange=function(e){var t=this.getRange();return e?(e.start.column=t.start.column,e.start.row=t.start.row,e.end.column=t.end.column,e.end.row=t.end.row):e=t,e.cursor=this.isBackwards()?e.start:e.end,e.desiredColumn=this.$desiredColumn,e},this.getRangeOfMovements=function(e){var t=this.getCursor();try{e(this);var n=this.getCursor();return a.fromPoints(t,n)}catch(e){return a.fromPoints(t,t)}finally{this.moveCursorToPosition(t)}},this.toJSON=function(){if(this.rangeCount)var e=this.ranges.map(function(e){var t=e.clone();return t.isBackwards=e.cursor==e.start,t});else{e=this.getRange();e.isBackwards=this.isBackwards()}return e},this.fromJSON=function(e){if(void 0==e.start){if(this.rangeList&&e.length>1){this.toSingleRange(e[0]);for(var t=e.length;t--;){var n=a.fromPoints(e[t].start,e[t].end);e[t].isBackwards&&(n.cursor=n.start),this.addRange(n,!0)}return}e=e[0]}this.rangeList&&this.toSingleRange(e),this.setSelectionRange(e,e.isBackwards)},this.isEqual=function(e){if((e.length||this.rangeCount)&&e.length!=this.rangeCount)return!1;if(!e.length||!this.ranges)return this.getRange().isEqual(e);for(var t=this.ranges.length;t--;)if(!this.ranges[t].isEqual(e[t]))return!1;return!0}}).call(s.prototype),t.Selection=s}),ace.define("ace/tokenizer",["require","exports","module","ace/config"],function(e,t,n){"use strict";var r=e("./config"),i=2e3,o=function(e){for(var t in this.states=e,this.regExps={},this.matchMappings={},this.states){for(var n=this.states[t],r=[],i=0,o=this.matchMappings[t]={defaultToken:"text"},a="g",s=[],l=0;l1?this.$applyToken:c.token),h>1&&(/\\\d/.test(c.regex)?u=c.regex.replace(/\\([0-9]+)/g,function(e,t){return"\\"+(parseInt(t,10)+i+1)}):(h=1,u=this.removeCapturingGroups(c.regex)),c.splitRegex||"string"==typeof c.token||s.push(c)),o[i]=l,i+=h,r.push(u),c.onMatch||(c.onMatch=null)}}r.length||(o[0]=0,r.push("$")),s.forEach(function(e){e.splitRegex=this.createSplitterRegexp(e.regex,a)},this),this.regExps[t]=new RegExp("("+r.join(")|(")+")|($)",a)}};(function(){this.$setMaxTokenCount=function(e){i=0|e},this.$applyToken=function(e){var t=this.splitRegex.exec(e).slice(1),n=this.token.apply(this,t);if("string"===typeof n)return[{type:n,value:e}];for(var r=[],i=0,o=n.length;iu){var v=e.substring(u,g-m.length);d.type==f?d.value+=v:(d.type&&c.push(d),d={type:f,value:v})}for(var y=0;yi){h>2*e.length&&this.reportError("infinite loop with in ace tokenizer",{startState:t,line:e});while(u1&&n[0]!==r&&n.unshift("#tmp",r),{tokens:c,state:n.length?n:r}},this.reportError=r.reportError}).call(o.prototype),t.Tokenizer=o}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/lang"),i=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}};(function(){this.addRules=function(e,t){if(t)for(var n in e){for(var r=e[n],i=0;i=this.$rowTokens.length){if(this.$row+=1,e||(e=this.$session.getLength()),this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},this.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},this.getCurrentTokenRow=function(){return this.$row},this.getCurrentTokenColumn=function(){var e=this.$rowTokens,t=this.$tokenIndex,n=e[t].start;if(void 0!==n)return n;n=0;while(t>0)t-=1,n+=e[t].value.length;return n},this.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},this.getCurrentTokenRange=function(){var e=this.$rowTokens[this.$tokenIndex],t=this.getCurrentTokenColumn();return new r(this.$row,t,this.$row,t+e.value.length)}}).call(i.prototype),t.TokenIterator=i}),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],function(e,t,n){"use strict";var r,i=e("../../lib/oop"),o=e("../behaviour").Behaviour,a=e("../../token_iterator").TokenIterator,s=e("../../lib/lang"),l=["text","paren.rparen","rparen","paren","punctuation.operator"],c=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],u={},h={'"':'"',"'":"'"},d=function(e){var t=-1;if(e.multiSelect&&(t=e.selection.index,u.rangeCount!=e.multiSelect.rangeCount&&(u={rangeCount:e.multiSelect.rangeCount})),u[t])return r=u[t];r=u[t]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},f=function(e,t,n,r){var i=e.end.row-e.start.row;return{text:n+t+r,selection:[0,e.start.column+1,i,e.end.column+(i?0:1)]}},p=function(e){this.add("braces","insertion",function(t,n,i,o,a){var l=i.getCursorPosition(),c=o.doc.getLine(l.row);if("{"==a){d(i);var u=i.getSelectionRange(),h=o.doc.getTextRange(u);if(""!==h&&"{"!==h&&i.getWrapBehavioursEnabled())return f(u,h,"{","}");if(p.isSaneInsertion(i,o))return/[\]\}\)]/.test(c[l.column])||i.inMultiSelectMode||e&&e.braces?(p.recordAutoInsert(i,o,"}"),{text:"{}",selection:[1,1]}):(p.recordMaybeInsert(i,o,"{"),{text:"{",selection:[1,1]})}else if("}"==a){d(i);var m=c.substring(l.column,l.column+1);if("}"==m){var g=o.$findOpeningBracket("}",{column:l.column+1,row:l.row});if(null!==g&&p.isAutoInsertedClosing(l,c,a))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}else{if("\n"==a||"\r\n"==a){d(i);var v="";p.isMaybeInsertedClosing(l,c)&&(v=s.stringRepeat("}",r.maybeInsertedBrackets),p.clearMaybeInsertedClosing());m=c.substring(l.column,l.column+1);if("}"===m){var y=o.findMatchingBracket({row:l.row,column:l.column+1},"}");if(!y)return null;var b=this.$getIndent(o.getLine(y.row))}else{if(!v)return void p.clearMaybeInsertedClosing();b=this.$getIndent(c)}var w=b+o.getTabString();return{text:"\n"+w+"\n"+b+v,selection:[1,w.length,1,w.length]}}p.clearMaybeInsertedClosing()}}),this.add("braces","deletion",function(e,t,n,i,o){var a=i.doc.getTextRange(o);if(!o.isMultiLine()&&"{"==a){d(n);var s=i.doc.getLine(o.start.row),l=s.substring(o.end.column,o.end.column+1);if("}"==l)return o.end.column++,o;r.maybeInsertedBrackets--}}),this.add("parens","insertion",function(e,t,n,r,i){if("("==i){d(n);var o=n.getSelectionRange(),a=r.doc.getTextRange(o);if(""!==a&&n.getWrapBehavioursEnabled())return f(o,a,"(",")");if(p.isSaneInsertion(n,r))return p.recordAutoInsert(n,r,")"),{text:"()",selection:[1,1]}}else if(")"==i){d(n);var s=n.getCursorPosition(),l=r.doc.getLine(s.row),c=l.substring(s.column,s.column+1);if(")"==c){var u=r.$findOpeningBracket(")",{column:s.column+1,row:s.row});if(null!==u&&p.isAutoInsertedClosing(s,l,i))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("parens","deletion",function(e,t,n,r,i){var o=r.doc.getTextRange(i);if(!i.isMultiLine()&&"("==o){d(n);var a=r.doc.getLine(i.start.row),s=a.substring(i.start.column+1,i.start.column+2);if(")"==s)return i.end.column++,i}}),this.add("brackets","insertion",function(e,t,n,r,i){if("["==i){d(n);var o=n.getSelectionRange(),a=r.doc.getTextRange(o);if(""!==a&&n.getWrapBehavioursEnabled())return f(o,a,"[","]");if(p.isSaneInsertion(n,r))return p.recordAutoInsert(n,r,"]"),{text:"[]",selection:[1,1]}}else if("]"==i){d(n);var s=n.getCursorPosition(),l=r.doc.getLine(s.row),c=l.substring(s.column,s.column+1);if("]"==c){var u=r.$findOpeningBracket("]",{column:s.column+1,row:s.row});if(null!==u&&p.isAutoInsertedClosing(s,l,i))return p.popAutoInsertedClosing(),{text:"",selection:[1,1]}}}}),this.add("brackets","deletion",function(e,t,n,r,i){var o=r.doc.getTextRange(i);if(!i.isMultiLine()&&"["==o){d(n);var a=r.doc.getLine(i.start.row),s=a.substring(i.start.column+1,i.start.column+2);if("]"==s)return i.end.column++,i}}),this.add("string_dquotes","insertion",function(e,t,n,r,i){var o=r.$mode.$quotes||h;if(1==i.length&&o[i]){if(this.lineCommentStart&&-1!=this.lineCommentStart.indexOf(i))return;d(n);var a=i,s=n.getSelectionRange(),l=r.doc.getTextRange(s);if(!(""===l||1==l.length&&o[l])&&n.getWrapBehavioursEnabled())return f(s,l,a,a);if(!l){var c=n.getCursorPosition(),u=r.doc.getLine(c.row),p=u.substring(c.column-1,c.column),m=u.substring(c.column,c.column+1),g=r.getTokenAt(c.row,c.column),v=r.getTokenAt(c.row,c.column+1);if("\\"==p&&g&&/escape/.test(g.type))return null;var y,b=g&&/string|escape/.test(g.type),w=!v||/string|escape/.test(v.type);if(m==a)y=b!==w,y&&/string\.end/.test(v.type)&&(y=!1);else{if(b&&!w)return null;if(b&&w)return null;var x=r.$mode.tokenRe;x.lastIndex=0;var E=x.test(p);x.lastIndex=0;var C=x.test(p);if(E||C)return null;if(m&&!/[\s;,.})\]\\]/.test(m))return null;var S=u[c.column-2];if(p==a&&(S==a||x.test(S)))return null;y=!0}return{text:y?a+a:"",selection:[1,1]}}}}),this.add("string_dquotes","deletion",function(e,t,n,r,i){var o=r.$mode.$quotes||h,a=r.doc.getTextRange(i);if(!i.isMultiLine()&&o.hasOwnProperty(a)){d(n);var s=r.doc.getLine(i.start.row),l=s.substring(i.start.column+1,i.start.column+2);if(l==a)return i.end.column++,i}})};p.isSaneInsertion=function(e,t){var n=e.getCursorPosition(),r=new a(t,n.row,n.column);if(!this.$matchTokenType(r.getCurrentToken()||"text",l)){if(/[)}\]]/.test(e.session.getLine(n.row)[n.column]))return!0;var i=new a(t,n.row,n.column+1);if(!this.$matchTokenType(i.getCurrentToken()||"text",l))return!1}return r.stepForward(),r.getCurrentTokenRow()!==n.row||this.$matchTokenType(r.getCurrentToken()||"text",c)},p.$matchTokenType=function(e,t){return t.indexOf(e.type||e)>-1},p.recordAutoInsert=function(e,t,n){var i=e.getCursorPosition(),o=t.doc.getLine(i.row);this.isAutoInsertedClosing(i,o,r.autoInsertedLineEnd[0])||(r.autoInsertedBrackets=0),r.autoInsertedRow=i.row,r.autoInsertedLineEnd=n+o.substr(i.column),r.autoInsertedBrackets++},p.recordMaybeInsert=function(e,t,n){var i=e.getCursorPosition(),o=t.doc.getLine(i.row);this.isMaybeInsertedClosing(i,o)||(r.maybeInsertedBrackets=0),r.maybeInsertedRow=i.row,r.maybeInsertedLineStart=o.substr(0,i.column)+n,r.maybeInsertedLineEnd=o.substr(i.column),r.maybeInsertedBrackets++},p.isAutoInsertedClosing=function(e,t,n){return r.autoInsertedBrackets>0&&e.row===r.autoInsertedRow&&n===r.autoInsertedLineEnd[0]&&t.substr(e.column)===r.autoInsertedLineEnd},p.isMaybeInsertedClosing=function(e,t){return r.maybeInsertedBrackets>0&&e.row===r.maybeInsertedRow&&t.substr(e.column)===r.maybeInsertedLineEnd&&t.substr(0,e.column)==r.maybeInsertedLineStart},p.popAutoInsertedClosing=function(){r.autoInsertedLineEnd=r.autoInsertedLineEnd.substr(1),r.autoInsertedBrackets--},p.clearMaybeInsertedClosing=function(){r&&(r.maybeInsertedBrackets=0,r.maybeInsertedRow=-1)},i.inherits(p,o),t.CstyleBehaviour=p}),ace.define("ace/unicode",["require","exports","module"],function(e,t,n){"use strict";for(var r=[48,9,8,25,5,0,2,25,48,0,11,0,5,0,6,22,2,30,2,457,5,11,15,4,8,0,2,0,18,116,2,1,3,3,9,0,2,2,2,0,2,19,2,82,2,138,2,4,3,155,12,37,3,0,8,38,10,44,2,0,2,1,2,1,2,0,9,26,6,2,30,10,7,61,2,9,5,101,2,7,3,9,2,18,3,0,17,58,3,100,15,53,5,0,6,45,211,57,3,18,2,5,3,11,3,9,2,1,7,6,2,2,2,7,3,1,3,21,2,6,2,0,4,3,3,8,3,1,3,3,9,0,5,1,2,4,3,11,16,2,2,5,5,1,3,21,2,6,2,1,2,1,2,1,3,0,2,4,5,1,3,2,4,0,8,3,2,0,8,15,12,2,2,8,2,2,2,21,2,6,2,1,2,4,3,9,2,2,2,2,3,0,16,3,3,9,18,2,2,7,3,1,3,21,2,6,2,1,2,4,3,8,3,1,3,2,9,1,5,1,2,4,3,9,2,0,17,1,2,5,4,2,2,3,4,1,2,0,2,1,4,1,4,2,4,11,5,4,4,2,2,3,3,0,7,0,15,9,18,2,2,7,2,2,2,22,2,9,2,4,4,7,2,2,2,3,8,1,2,1,7,3,3,9,19,1,2,7,2,2,2,22,2,9,2,4,3,8,2,2,2,3,8,1,8,0,2,3,3,9,19,1,2,7,2,2,2,22,2,15,4,7,2,2,2,3,10,0,9,3,3,9,11,5,3,1,2,17,4,23,2,8,2,0,3,6,4,0,5,5,2,0,2,7,19,1,14,57,6,14,2,9,40,1,2,0,3,1,2,0,3,0,7,3,2,6,2,2,2,0,2,0,3,1,2,12,2,2,3,4,2,0,2,5,3,9,3,1,35,0,24,1,7,9,12,0,2,0,2,0,5,9,2,35,5,19,2,5,5,7,2,35,10,0,58,73,7,77,3,37,11,42,2,0,4,328,2,3,3,6,2,0,2,3,3,40,2,3,3,32,2,3,3,6,2,0,2,3,3,14,2,56,2,3,3,66,5,0,33,15,17,84,13,619,3,16,2,25,6,74,22,12,2,6,12,20,12,19,13,12,2,2,2,1,13,51,3,29,4,0,5,1,3,9,34,2,3,9,7,87,9,42,6,69,11,28,4,11,5,11,11,39,3,4,12,43,5,25,7,10,38,27,5,62,2,28,3,10,7,9,14,0,89,75,5,9,18,8,13,42,4,11,71,55,9,9,4,48,83,2,2,30,14,230,23,280,3,5,3,37,3,5,3,7,2,0,2,0,2,0,2,30,3,52,2,6,2,0,4,2,2,6,4,3,3,5,5,12,6,2,2,6,67,1,20,0,29,0,14,0,17,4,60,12,5,0,4,11,18,0,5,0,3,9,2,0,4,4,7,0,2,0,2,0,2,3,2,10,3,3,6,4,5,0,53,1,2684,46,2,46,2,132,7,6,15,37,11,53,10,0,17,22,10,6,2,6,2,6,2,6,2,6,2,6,2,6,2,6,2,31,48,0,470,1,36,5,2,4,6,1,5,85,3,1,3,2,2,89,2,3,6,40,4,93,18,23,57,15,513,6581,75,20939,53,1164,68,45,3,268,4,27,21,31,3,13,13,1,2,24,9,69,11,1,38,8,3,102,3,1,111,44,25,51,13,68,12,9,7,23,4,0,5,45,3,35,13,28,4,64,15,10,39,54,10,13,3,9,7,22,4,1,5,66,25,2,227,42,2,1,3,9,7,11171,13,22,5,48,8453,301,3,61,3,105,39,6,13,4,6,11,2,12,2,4,2,0,2,1,2,1,2,107,34,362,19,63,3,53,41,11,5,15,17,6,13,1,25,2,33,4,2,134,20,9,8,25,5,0,2,25,12,88,4,5,3,5,3,5,3,2],i=0,o=[],a=0;a2?r%c!=c-1:r%c==0})}else{if(!this.blockComment)return!1;var f=this.blockComment.start,p=this.blockComment.end,m=new RegExp("^(\\s*)(?:"+l.escapeRegExp(f)+")"),g=new RegExp("(?:"+l.escapeRegExp(p)+")\\s*$"),v=function(e,t){b(e,t)||o&&!/\S/.test(e)||(i.insertInLine({row:t,column:e.length},p),i.insertInLine({row:t,column:s},f))},y=function(e,t){var n;(n=e.match(g))&&i.removeInLine(t,e.length-n[0].length,e.length),(n=e.match(m))&&i.removeInLine(t,n[1].length,n[0].length)},b=function(e,n){if(m.test(e))return!0;for(var r=t.getTokens(n),i=0;ie.length&&(x=e.length)}),s==1/0&&(s=x,o=!1,a=!1),u&&s%c!=0&&(s=Math.floor(s/c)*c),w(a?y:v)},this.toggleBlockComment=function(e,t,n,r){var i=this.blockComment;if(i){!i.start&&i[0]&&(i=i[0]);var o,a,s=new c(t,r.row,r.column),l=s.getCurrentToken(),h=(t.selection,t.selection.toOrientedRange());if(l&&/comment/.test(l.type)){var d,f;while(l&&/comment/.test(l.type)){var p=l.value.indexOf(i.start);if(-1!=p){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+p;d=new u(m,g,m,g+i.start.length);break}l=s.stepBackward()}s=new c(t,r.row,r.column),l=s.getCurrentToken();while(l&&/comment/.test(l.type)){p=l.value.indexOf(i.end);if(-1!=p){m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+p;f=new u(m,g,m,g+i.end.length);break}l=s.stepForward()}f&&t.remove(f),d&&(t.remove(d),o=d.start.row,a=-i.start.length)}else a=i.start.length,o=n.start.row,t.insert(n.end,i.end),t.insert(n.start,i.start);h.start.row==o&&(h.start.column+=a),h.end.row==o&&(h.end.column+=a),t.selection.fromOrientedRange(h)}},this.getNextLineIndent=function(e,t,n){return this.$getIndent(t)},this.checkOutdent=function(e,t,n){return!1},this.autoOutdent=function(e,t,n){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){for(var t in this.$embeds=[],this.$modes={},e)if(e[t]){var n=e[t],i=n.prototype.$id,o=r.$modes[i];o||(r.$modes[i]=o=new n),r.$modes[t]||(r.$modes[t]=o),this.$embeds.push(t),this.$modes[t]=o}var a=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"];for(t=0;tthis.row)){var n=t(e,{row:this.row,column:this.column},this.$insertRight);this.setPosition(n.row,n.column,!0)}},this.setPosition=function(e,t,n){var r;if(r=n?{row:e,column:t}:this.$clipPositionToDocument(e,t),this.row!=r.row||this.column!=r.column){var i={row:this.row,column:this.column};this.row=r.row,this.column=r.column,this._signal("change",{old:i,value:r})}},this.detach=function(){this.document.off("change",this.$onChange)},this.attach=function(e){this.document=e||this.document,this.document.on("change",this.$onChange)},this.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n}}).call(o.prototype)}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./apply_delta").applyDelta,o=e("./lib/event_emitter").EventEmitter,a=e("./range").Range,s=e("./anchor").Anchor,l=function(e){this.$lines=[""],0===e.length?this.$lines=[""]:Array.isArray(e)?this.insertMergedLines({row:0,column:0},e):this.insert({row:0,column:0},e)};(function(){r.implement(this,o),this.setValue=function(e){var t=this.getLength()-1;this.remove(new a(0,0,t,this.getLine(t).length)),this.insert({row:0,column:0},e)},this.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},this.createAnchor=function(e,t){return new s(this,e,t)},0==="aaa".split(/a/).length?this.$split=function(e){return e.replace(/\r\n|\r/g,"\n").split("\n")}:this.$split=function(e){return e.split(/\r\n|\r|\n/)},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")},this.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}},this.$autoNewLine="",this.$newLineMode="auto",this.setNewLineMode=function(e){this.$newLineMode!==e&&(this.$newLineMode=e,this._signal("changeNewLineMode"))},this.getNewLineMode=function(){return this.$newLineMode},this.isNewLine=function(e){return"\r\n"==e||"\r"==e||"\n"==e},this.getLine=function(e){return this.$lines[e]||""},this.getLines=function(e,t){return this.$lines.slice(e,t+1)},this.getAllLines=function(){return this.getLines(0,this.getLength())},this.getLength=function(){return this.$lines.length},this.getTextRange=function(e){return this.getLinesForRange(e).join(this.getNewLineCharacter())},this.getLinesForRange=function(e){var t;if(e.start.row===e.end.row)t=[this.getLine(e.start.row).substring(e.start.column,e.end.column)];else{t=this.getLines(e.start.row,e.end.row),t[0]=(t[0]||"").substring(e.start.column);var n=t.length-1;e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column))}return t},this.insertLines=function(e,t){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(e,t)},this.removeLines=function(e,t){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(e,t)},this.insertNewLine=function(e){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(e,["",""])},this.insert=function(e,t){return this.getLength()<=1&&this.$detectNewLine(t),this.insertMergedLines(e,this.$split(t))},this.insertInLine=function(e,t){var n=this.clippedPos(e.row,e.column),r=this.pos(e.row,e.column+t.length);return this.applyDelta({start:n,end:r,action:"insert",lines:[t]},!0),this.clonePos(r)},this.clippedPos=function(e,t){var n=this.getLength();void 0===e?e=n:e<0?e=0:e>=n&&(e=n-1,t=void 0);var r=this.getLine(e);return void 0==t&&(t=r.length),t=Math.min(Math.max(t,0),r.length),{row:e,column:t}},this.clonePos=function(e){return{row:e.row,column:e.column}},this.pos=function(e,t){return{row:e,column:t}},this.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):(e.row=Math.max(0,e.row),e.column=Math.min(Math.max(e.column,0),this.getLine(e.row).length)),e},this.insertFullLines=function(e,t){e=Math.min(Math.max(e,0),this.getLength());var n=0;e0,r=t=0&&this.applyDelta({start:this.pos(e,this.getLine(e).length),end:this.pos(e+1,0),action:"remove",lines:["",""]})},this.replace=function(e,t){return e instanceof a||(e=a.fromPoints(e.start,e.end)),0===t.length&&e.isEmpty()?e.start:t==this.getTextRange(e)?e.end:(this.remove(e),n=t?this.insert(e.start,t):e.start,n);var n},this.applyDeltas=function(e){for(var t=0;t=0;t--)this.revertDelta(e[t])},this.applyDelta=function(e,t){var n="insert"==e.action;(n?e.lines.length<=1&&!e.lines[0]:!a.comparePoints(e.start,e.end))||(n&&e.lines.length>2e4?this.$splitAndapplyLargeDelta(e,2e4):(i(this.$lines,e,t),this._signal("change",e)))},this.$safeApplyDelta=function(e){var t=this.$lines.length;("remove"==e.action&&e.start.row20){n.running=setTimeout(n.$worker,20);break}}n.currentLine=t,-1==r&&(r=t),o<=r&&n.fireUpdateEvent(o,r)}}};(function(){r.implement(this,i),this.setTokenizer=function(e){this.tokenizer=e,this.lines=[],this.states=[],this.start(0)},this.setDocument=function(e){this.doc=e,this.lines=[],this.states=[],this.stop()},this.fireUpdateEvent=function(e,t){var n={first:e,last:t};this._signal("update",{data:n})},this.start=function(e){this.currentLine=Math.min(e||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},this.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},this.$updateOnChange=function(e){var t=e.start.row,n=e.end.row-t;if(0===n)this.lines[t]=null;else if("remove"==e.action)this.lines.splice(t,n+1,null),this.states.splice(t,n+1,null);else{var r=Array(n+1);r.unshift(t,1),this.lines.splice.apply(this.lines,r),this.states.splice.apply(this.states,r)}this.currentLine=Math.min(t,this.currentLine,this.doc.getLength()),this.stop()},this.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},this.getTokens=function(e){return this.lines[e]||this.$tokenizeRow(e)},this.getState=function(e){return this.currentLine==e&&this.$tokenizeRow(e),this.states[e]||"start"},this.$tokenizeRow=function(e){var t=this.doc.getLine(e),n=this.states[e-1],r=this.tokenizer.getLineTokens(t,n,e);return this.states[e]+""!==r.state+""?(this.states[e]=r.state,this.lines[e+1]=null,this.currentLine>e+1&&(this.currentLine=e+1)):this.currentLine==e&&(this.currentLine=e+1),this.lines[e]=r.tokens}}).call(o.prototype),t.BackgroundTokenizer=o}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=(e("./lib/oop"),e("./range").Range),o=function(e,t,n){this.setRegexp(e),this.clazz=t,this.type=n||"text"};(function(){this.MAX_RANGES=500,this.setRegexp=function(e){this.regExp+""!=e+""&&(this.regExp=e,this.cache=[])},this.update=function(e,t,n,o){if(this.regExp)for(var a=o.firstRow,s=o.lastRow,l=a;l<=s;l++){var c=this.cache[l];null==c&&(c=r.getMatchOffsets(n.getLine(l),this.regExp),c.length>this.MAX_RANGES&&(c=c.slice(0,this.MAX_RANGES)),c=c.map(function(e){return new i(l,e.offset,l,e.offset+e.length)}),this.cache[l]=c.length?c:"");for(var u=c.length;u--;)t.drawSingleLineMarker(e,c[u].toScreenRange(n),this.clazz,o)}}}).call(o.prototype),t.SearchHighlight=o}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../range").Range;function i(e,t){this.foldData=e,Array.isArray(t)?this.folds=t:t=this.folds=[t];var n=t[t.length-1];this.range=new r(t[0].start.row,t[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(e){e.setFoldLine(this)},this)}(function(){this.shiftRow=function(e){this.start.row+=e,this.end.row+=e,this.folds.forEach(function(t){t.start.row+=e,t.end.row+=e})},this.addFold=function(e){if(e.sameRow){if(e.start.rowthis.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(e),this.folds.sort(function(e,t){return-e.range.compareEnd(t.start.row,t.start.column)}),this.range.compareEnd(e.start.row,e.start.column)>0?(this.end.row=e.end.row,this.end.column=e.end.column):this.range.compareStart(e.end.row,e.end.column)<0&&(this.start.row=e.start.row,this.start.column=e.start.column)}else if(e.start.row==this.end.row)this.folds.push(e),this.end.row=e.end.row,this.end.column=e.end.column;else{if(e.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(e),this.start.row=e.start.row,this.start.column=e.start.column}e.foldLine=this},this.containsRow=function(e){return e>=this.start.row&&e<=this.end.row},this.walk=function(e,t,n){var r,i,o,a=0,s=this.folds,l=!0;null==t&&(t=this.end.row,n=this.end.column);for(var c=0;c0)){var l=i(e,a.start);return 0===s?t&&0!==l?-o-2:o:l>0||0===l&&!t?o:-o-1}}return-o-1},this.add=function(e){var t=!e.isEmpty(),n=this.pointIndex(e.start,t);n<0&&(n=-n-1);var r=this.pointIndex(e.end,t,n);return r<0?r=-r-1:r++,this.ranges.splice(n,r-n,e)},this.addList=function(e){for(var t=[],n=e.length;n--;)t.push.apply(t,this.add(e[n]));return t},this.substractPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges.splice(t,1)},this.merge=function(){var e=[],t=this.ranges;t=t.sort(function(e,t){return i(e.start,t.start)});for(var n,r=t[0],o=1;o=0},this.containsPoint=function(e){return this.pointIndex(e)>=0},this.rangeAtPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges[t]},this.clipRows=function(e,t){var n=this.ranges;if(n[0].start.row>t||n[n.length-1].start.row=r)break}if("insert"==e.action)for(var c=i-r,u=-t.column+n.column;ar)break;if(l.start.row==r&&l.start.column>=t.column&&(l.start.column==t.column&&this.$bias<=0||(l.start.column+=u,l.start.row+=c)),l.end.row==r&&l.end.column>=t.column){if(l.end.column==t.column&&this.$bias<0)continue;l.end.column==t.column&&u>0&&al.start.column&&l.end.column==o[a+1].start.column&&(l.end.column-=u),l.end.column+=u,l.end.row+=c}}else for(c=r-i,u=t.column-n.column;ai)break;l.end.rowt.column)&&(l.end.column=t.column,l.end.row=t.row):(l.end.column+=u,l.end.row+=c):l.end.row>i&&(l.end.row+=c),l.start.rowt.column)&&(l.start.column=t.column,l.start.row=t.row):(l.start.column+=u,l.start.row+=c):l.start.row>i&&(l.start.row+=c)}if(0!=c&&a=e)return i;if(i.end.row>e)return null}return null},this.getNextFoldLine=function(e,t){var n=this.$foldData,r=0;for(t&&(r=n.indexOf(t)),-1==r&&(r=0),r;r=e)return i}return null},this.getFoldedRowCount=function(e,t){for(var n=this.$foldData,r=t-e+1,i=0;i=t){s=e?r-=t-s:r=0);break}a>=e&&(r-=s>=e?a-s:a-e+1)}return r},this.$addFoldLine=function(e){return this.$foldData.push(e),this.$foldData.sort(function(e,t){return e.start.row-t.start.row}),e},this.addFold=function(e,t){var n,r=this.$foldData,a=!1;e instanceof o?n=e:(n=new o(t,e),n.collapseChildren=t.collapseChildren),this.$clipRangeToDocument(n.range);var s=n.start.row,l=n.start.column,c=n.end.row,u=n.end.column,h=this.getFoldAt(s,l,1),d=this.getFoldAt(c,u,-1);if(h&&d==h)return h.addSubFold(n);h&&!h.range.isStart(s,l)&&this.removeFold(h),d&&!d.range.isEnd(c,u)&&this.removeFold(d);var f=this.getFoldsInRange(n.range);f.length>0&&(this.removeFolds(f),n.collapseChildren||f.forEach(function(e){n.addSubFold(e)}));for(var p=0;p0&&this.foldAll(e.start.row+1,e.end.row,e.collapseChildren-1),e.subFolds=[]},this.expandFolds=function(e){e.forEach(function(e){this.expandFold(e)},this)},this.unfold=function(e,t){var n,i;if(null==e?(n=new r(0,0,this.getLength(),0),null==t&&(t=!0)):n="number"==typeof e?new r(e,0,e,this.getLine(e).length):"row"in e?r.fromPoints(e,e):e,i=this.getFoldsInRangeList(n),0!=t?this.removeFolds(i):this.expandFolds(i),i.length)return i},this.isRowFolded=function(e,t){return!!this.getFoldLine(e,t)},this.getRowFoldEnd=function(e,t){var n=this.getFoldLine(e,t);return n?n.end.row:e},this.getRowFoldStart=function(e,t){var n=this.getFoldLine(e,t);return n?n.start.row:e},this.getFoldDisplayLine=function(e,t,n,r,i){null==r&&(r=e.start.row),null==i&&(i=0),null==t&&(t=e.end.row),null==n&&(n=this.getLine(t).length);var o=this.doc,a="";return e.walk(function(e,t,n,s){if(!(tu)break}while(o&&l.test(o.type));o=i.stepBackward()}else o=i.getCurrentToken();return c.end.row=i.getCurrentTokenRow(),c.end.column=i.getCurrentTokenColumn()+o.value.length-2,c}},this.foldAll=function(e,t,n,r){void 0==n&&(n=1e5);var i=this.foldWidgets;if(i){t=t||this.getLength(),e=e||0;for(var o=e;o=e&&(o=a.end.row,a.collapseChildren=n,this.addFold("...",a))}}},this.foldToLevel=function(e){this.foldAll();while(e-- >0)this.unfold(null,!1)},this.foldAllComments=function(){var e=this;this.foldAll(null,null,null,function(t){for(var n=e.getTokens(t),r=0;r=0){var o=n[i];if(null==o&&(o=n[i]=this.getFoldWidget(i)),"start"==o){var a=this.getFoldWidgetRange(i);if(r||(r=a),a&&a.end.row>=e)break}i--}return{range:-1!==i&&a,firstRange:r}},this.onFoldWidgetClick=function(e,t){t=t.domEvent;var n={children:t.shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey},r=this.$toggleFoldWidget(e,n);if(!r){var i=t.target||t.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(e,t){if(this.getFoldWidget){var n=this.getFoldWidget(e),r=this.getLine(e),i="end"===n?-1:1,o=this.getFoldAt(e,-1===i?0:r.length,i);if(o)return t.children||t.all?this.removeFold(o):this.expandFold(o),o;var a=this.getFoldWidgetRange(e,!0);if(a&&!a.isMultiLine()&&(o=this.getFoldAt(a.start.row,a.start.column,1),o&&a.isEqual(o.range)))return this.removeFold(o),o;if(t.siblings){var s=this.getParentFoldRangeData(e);if(s.range)var l=s.range.start.row+1,c=s.range.end.row;this.foldAll(l,c,t.all?1e4:0)}else t.children?(c=a?a.end.row:this.getLength(),this.foldAll(e+1,c,t.all?1e4:0)):a&&(t.all&&(a.collapseChildren=1e4),this.addFold("...",a));return a}},this.toggleFoldWidget=function(e){var t=this.selection.getCursor().row;t=this.getRowFoldStart(t);var n=this.$toggleFoldWidget(t,{});if(!n){var r=this.getParentFoldRangeData(t,!0);if(n=r.range||r.firstRange,n){t=n.start.row;var i=this.getFoldAt(t,this.getLine(t).length,1);i?this.removeFold(i):this.addFold("...",n)}}},this.updateFoldWidgets=function(e){var t=e.start.row,n=e.end.row-t;if(0===n)this.foldWidgets[t]=null;else if("remove"==e.action)this.foldWidgets.splice(t,n+1,null);else{var r=Array(n+1);r.unshift(t,1),this.foldWidgets.splice.apply(this.foldWidgets,r)}},this.tokenizerUpdateFoldWidgets=function(e){var t=e.data;t.first!=t.last&&this.foldWidgets.length>t.first&&this.foldWidgets.splice(t.first,this.foldWidgets.length)}}t.Folding=s}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(e,t,n){"use strict";var r=e("../token_iterator").TokenIterator,i=e("../range").Range;function o(){this.findMatchingBracket=function(e,t){if(0==e.column)return null;var n=t||this.getLine(e.row).charAt(e.column-1);if(""==n)return null;var r=n.match(/([\(\[\{])|([\)\]\}])/);return r?r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e):null},this.getBracketRange=function(e){var t,n=this.getLine(e.row),r=!0,o=n.charAt(e.column-1),a=o&&o.match(/([\(\[\{])|([\)\]\}])/);if(a||(o=n.charAt(e.column),e={row:e.row,column:e.column+1},a=o&&o.match(/([\(\[\{])|([\)\]\}])/),r=!1),!a)return null;if(a[1]){var s=this.$findClosingBracket(a[1],e);if(!s)return null;t=i.fromPoints(e,s),r||(t.end.column++,t.start.column--),t.cursor=t.end}else{s=this.$findOpeningBracket(a[2],e);if(!s)return null;t=i.fromPoints(s,e),r||(t.start.column++,t.end.column--),t.cursor=t.start}return t},this.getMatchingBracketRanges=function(e){var t=this.getLine(e.row),n=t.charAt(e.column-1),r=n&&n.match(/([\(\[\{])|([\)\]\}])/);if(r||(n=t.charAt(e.column),e={row:e.row,column:e.column+1},r=n&&n.match(/([\(\[\{])|([\)\]\}])/)),!r)return null;var o=new i(e.row,e.column-1,e.row,e.column),a=r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e);if(!a)return[o];var s=new i(a.row,a.column,a.row,a.column+1);return[o,s]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(e,t,n){var i=this.$brackets[e],o=1,a=new r(this,t.row,t.column),s=a.getCurrentToken();if(s||(s=a.stepForward()),s){n||(n=new RegExp("(\\.?"+s.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)")+")+"));var l=t.column-a.getCurrentTokenColumn()-2,c=s.value;while(1){while(l>=0){var u=c.charAt(l);if(u==i){if(o-=1,0==o)return{row:a.getCurrentTokenRow(),column:l+a.getCurrentTokenColumn()}}else u==e&&(o+=1);l-=1}do{s=a.stepBackward()}while(s&&!n.test(s.type));if(null==s)break;c=s.value,l=c.length-1}return null}},this.$findClosingBracket=function(e,t,n){var i=this.$brackets[e],o=1,a=new r(this,t.row,t.column),s=a.getCurrentToken();if(s||(s=a.stepForward()),s){n||(n=new RegExp("(\\.?"+s.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)")+")+"));var l=t.column-a.getCurrentTokenColumn();while(1){var c=s.value,u=c.length;while(ln&&(this.$docRowCache.splice(n,t),this.$screenRowCache.splice(n,t))},this.$getRowCacheIndex=function(e,t){var n=0,r=e.length-1;while(n<=r){var i=n+r>>1,o=e[i];if(t>o)n=i+1;else{if(!(t=t)break;return n=r[o],n?(n.index=o,n.start=i-n.value.length,n):null},this.setUndoManager=function(e){if(this.$undoManager=e,this.$informUndoManager&&this.$informUndoManager.cancel(),e){var t=this;e.addSession(this),this.$syncInformUndoManager=function(){t.$informUndoManager.cancel(),t.mergeUndoDeltas=!1},this.$informUndoManager=i.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},this.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},this.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},this.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},this.getTabString=function(){return this.getUseSoftTabs()?i.stringRepeat(" ",this.getTabSize()):"\t"},this.setUseSoftTabs=function(e){this.setOption("useSoftTabs",e)},this.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},this.setTabSize=function(e){this.setOption("tabSize",e)},this.getTabSize=function(){return this.$tabSize},this.isTabStop=function(e){return this.$useSoftTabs&&e.column%this.$tabSize===0},this.setNavigateWithinSoftTabs=function(e){this.setOption("navigateWithinSoftTabs",e)},this.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},this.$overwrite=!1,this.setOverwrite=function(e){this.setOption("overwrite",e)},this.getOverwrite=function(){return this.$overwrite},this.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},this.addGutterDecoration=function(e,t){this.$decorations[e]||(this.$decorations[e]=""),this.$decorations[e]+=" "+t,this._signal("changeBreakpoint",{})},this.removeGutterDecoration=function(e,t){this.$decorations[e]=(this.$decorations[e]||"").replace(" "+t,""),this._signal("changeBreakpoint",{})},this.getBreakpoints=function(){return this.$breakpoints},this.setBreakpoints=function(e){this.$breakpoints=[];for(var t=0;t0&&(r=!!n.charAt(t-1).match(this.tokenRe)),r||(r=!!n.charAt(t).match(this.tokenRe)),r)var i=this.tokenRe;else if(/^\s+$/.test(n.slice(t-1,t+1)))i=/\s/;else i=this.nonTokenRe;var o=t;if(o>0){do{o--}while(o>=0&&n.charAt(o).match(i));o++}var a=t;while(ae&&(e=t.screenWidth)}),this.lineWidgetWidth=e},this.$computeWidth=function(e){if(this.$modified||e){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var t=this.doc.getAllLines(),n=this.$rowLengthCache,r=0,i=0,o=this.$foldData[i],a=o?o.start.row:1/0,s=t.length,l=0;la){if(l=o.end.row+1,l>=s)break;o=this.$foldData[i++],a=o?o.start.row:1/0}null==n[l]&&(n[l]=this.$getStringScreenWidth(t[l])[0]),n[l]>r&&(r=n[l])}this.screenWidth=r}},this.getLine=function(e){return this.doc.getLine(e)},this.getLines=function(e,t){return this.doc.getLines(e,t)},this.getLength=function(){return this.doc.getLength()},this.getTextRange=function(e){return this.doc.getTextRange(e||this.selection.getRange())},this.insert=function(e,t){return this.doc.insert(e,t)},this.remove=function(e){return this.doc.remove(e)},this.removeFullLines=function(e,t){return this.doc.removeFullLines(e,t)},this.undoChanges=function(e,t){if(e.length){this.$fromUndo=!0;for(var n=e.length-1;-1!=n;n--){var r=e[n];"insert"==r.action||"remove"==r.action?this.doc.revertDelta(r):r.folds&&this.addFolds(r.folds)}!t&&this.$undoSelect&&(e.selectionBefore?this.selection.fromJSON(e.selectionBefore):this.selection.setRange(this.$getUndoSelection(e,!0))),this.$fromUndo=!1}},this.redoChanges=function(e,t){if(e.length){this.$fromUndo=!0;for(var n=0;ne.end.column&&(o.start.column+=s),o.end.row==e.end.row&&o.end.column>e.end.column&&(o.end.column+=s)),a&&o.start.row>=e.end.row&&(o.start.row+=a,o.end.row+=a)}if(o.end=this.insert(o.start,r),i.length){var l=e.start,c=o.start;a=c.row-l.row,s=c.column-l.column;this.addFolds(i.map(function(e){return e=e.clone(),e.start.row==l.row&&(e.start.column+=s),e.end.row==l.row&&(e.end.column+=s),e.start.row+=a,e.end.row+=a,e}))}return o},this.indentRows=function(e,t,n){n=n.replace(/\t/g,this.getTabString());for(var r=e;r<=t;r++)this.doc.insertInLine({row:r,column:0},n)},this.outdentRows=function(e){for(var t=e.collapseRows(),n=new u(0,0,0,0),r=this.getTabSize(),i=t.start.row;i<=t.end.row;++i){var o=this.getLine(i);n.start.row=i,n.end.row=i;for(var a=0;a0){r=this.getRowFoldEnd(t+n);if(r>this.doc.getLength()-1)return 0;i=r-t}else{e=this.$clipRowToDocument(e),t=this.$clipRowToDocument(t);i=t-e+1}var o=new u(e,0,t,Number.MAX_VALUE),a=this.getFoldsInRange(o).map(function(e){return e=e.clone(),e.start.row+=i,e.end.row+=i,e}),s=0==n?this.doc.getLines(e,t):this.doc.removeFullLines(e,t);return this.doc.insertFullLines(e+i,s),a.length&&this.addFolds(a),i},this.moveLinesUp=function(e,t){return this.$moveLines(e,t,-1)},this.moveLinesDown=function(e,t){return this.$moveLines(e,t,1)},this.duplicateLines=function(e,t){return this.$moveLines(e,t,0)},this.$clipRowToDocument=function(e){return Math.max(0,Math.min(e,this.doc.getLength()-1))},this.$clipColumnToRow=function(e,t){return t<0?0:Math.min(this.doc.getLine(e).length,t)},this.$clipPositionToDocument=function(e,t){if(t=Math.max(0,t),e<0)e=0,t=0;else{var n=this.doc.getLength();e>=n?(e=n-1,t=this.doc.getLine(n-1).length):t=Math.min(this.doc.getLine(e).length,t)}return{row:e,column:t}},this.$clipRangeToDocument=function(e){e.start.row<0?(e.start.row=0,e.start.column=0):e.start.column=this.$clipColumnToRow(e.start.row,e.start.column);var t=this.doc.getLength()-1;return e.end.row>t?(e.end.row=t,e.end.column=this.doc.getLine(t).length):e.end.column=this.$clipColumnToRow(e.end.row,e.end.column),e},this.$wrapLimit=80,this.$useWrapMode=!1,this.$wrapLimitRange={min:null,max:null},this.setUseWrapMode=function(e){if(e!=this.$useWrapMode){if(this.$useWrapMode=e,this.$modified=!0,this.$resetRowCache(0),e){var t=this.getLength();this.$wrapData=Array(t),this.$updateWrapData(0,t-1)}this._signal("changeWrapMode")}},this.getUseWrapMode=function(){return this.$useWrapMode},this.setWrapLimitRange=function(e,t){this.$wrapLimitRange.min===e&&this.$wrapLimitRange.max===t||(this.$wrapLimitRange={min:e,max:t},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},this.adjustWrapLimit=function(e,t){var n=this.$wrapLimitRange;n.max<0&&(n={min:t,max:t});var r=this.$constrainWrapLimit(e,n.min,n.max);return r!=this.$wrapLimit&&r>1&&(this.$wrapLimit=r,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0)},this.$constrainWrapLimit=function(e,t,n){return t&&(e=Math.max(t,e)),n&&(e=Math.min(n,e)),e},this.getWrapLimit=function(){return this.$wrapLimit},this.setWrapLimit=function(e){this.setWrapLimitRange(e,e)},this.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},this.$updateInternalDataOnChange=function(e){var t=this.$useWrapMode,n=e.action,r=e.start,i=e.end,o=r.row,a=i.row,s=a-o,l=null;if(this.$updating=!0,0!=s)if("remove"===n){this[t?"$wrapData":"$rowLengthCache"].splice(o,s);var c=this.$foldData;l=this.getFoldsInRange(e),this.removeFolds(l);var u=this.getFoldLine(i.row),h=0;if(u){u.addRemoveChars(i.row,i.column,r.column-i.column),u.shiftRow(-s);var d=this.getFoldLine(o);d&&d!==u&&(d.merge(u),u=d),h=c.indexOf(u)+1}for(h;h=i.row&&u.shiftRow(-s)}a=o}else{var f=Array(s);f.unshift(o,0);var p=t?this.$wrapData:this.$rowLengthCache;p.splice.apply(p,f);c=this.$foldData,u=this.getFoldLine(o),h=0;if(u){var m=u.range.compareInside(r.row,r.column);0==m?(u=u.split(r.row,r.column),u&&(u.shiftRow(s),u.addRemoveChars(a,0,i.column-r.column))):-1==m&&(u.addRemoveChars(o,0,i.column-r.column),u.shiftRow(s)),h=c.indexOf(u)+1}for(h;h=o&&u.shiftRow(s)}}else{s=Math.abs(e.start.column-e.end.column),"remove"===n&&(l=this.getFoldsInRange(e),this.removeFolds(l),s=-s);u=this.getFoldLine(o);u&&u.addRemoveChars(o,r.column,s)}return t&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,t?this.$updateWrapData(o,a):this.$updateRowLengthCache(o,a),l},this.$updateRowLengthCache=function(e,t,n){this.$rowLengthCache[e]=null,this.$rowLengthCache[t]=null},this.$updateWrapData=function(e,t){var r,i,a=this.doc.getAllLines(),s=this.getTabSize(),l=this.$wrapData,c=this.$wrapLimit,u=e;t=Math.min(t,a.length-1);while(u<=t)i=this.getFoldLine(u,i),i?(r=[],i.walk(function(e,t,i,s){var l;if(null!=e){l=this.$getDisplayTokens(e,r.length),l[0]=n;for(var c=1;c=4352&&e<=4447||e>=4515&&e<=4519||e>=4602&&e<=4607||e>=9001&&e<=9002||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12283||e>=12288&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12589||e>=12593&&e<=12686||e>=12688&&e<=12730||e>=12736&&e<=12771||e>=12784&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=13054||e>=13056&&e<=19903||e>=19968&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=55216&&e<=55238||e>=55243&&e<=55291||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=65281&&e<=65376||e>=65504&&e<=65510)}this.$computeWrapSplits=function(e,r,i){if(0==e.length)return[];var a=[],s=e.length,c=0,u=0,d=this.$wrapAsCode,f=this.$indentedSoftWrap,g=r<=Math.max(2*i,8)||!1===f?0:Math.floor(r/2);function v(){var t=0;if(0===g)return t;if(f)for(var n=0;nr-b){var w=c+r-b;if(e[w-1]>=h&&e[w]>=h)y(w);else if(e[w]!=n&&e[w]!=o){var x=Math.max(w-(r-(r>>2)),c-1);while(w>x&&e[w]x&&e[w]x&&e[w]==l)w--}else while(w>x&&e[w]x?y(++w):(w=c+r,e[w]==t&&w--,y(w-b))}else{for(w;w!=c-1;w--)if(e[w]==n)break;if(w>c){y(w);continue}for(w=c+r,w;w39&&s<48||s>57&&s<64?o.push(l):s>=4352&&g(s)?o.push(e,t):o.push(e)}return o},this.$getStringScreenWidth=function(e,t,n){if(0==t)return[0,0];var r,i;for(null==t&&(t=1/0),n=n||0,i=0;i=4352&&g(r)?n+=2:n+=1,n>t)break;return[n,i]},this.lineWidgets=null,this.getRowLength=function(e){var t=1;return this.lineWidgets&&(t+=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0),this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+t:t},this.getRowLineCount=function(e){return this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+1:1},this.getRowWrapIndent=function(e){if(this.$useWrapMode){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE),n=this.$wrapData[t.row];return n.length&&n[0]=0){s=c[u],o=this.$docRowCache[u];var d=e>c[h-1]}else d=!h;var f=this.getLength()-1,p=this.getNextFoldLine(o),m=p?p.start.row:1/0;while(s<=e){if(l=this.getRowLength(o),s+l>e||o>=f)break;s+=l,o++,o>m&&(o=p.end.row+1,p=this.getNextFoldLine(o,p),m=p?p.start.row:1/0),d&&(this.$docRowCache.push(o),this.$screenRowCache.push(s))}if(p&&p.start.row<=o)r=this.getFoldDisplayLine(p),o=p.start.row;else{if(s+l<=e||o>f)return{row:f,column:this.getLine(f).length};r=this.getLine(o),p=null}var g=0,v=Math.floor(e-s);if(this.$useWrapMode){var y=this.$wrapData[o];y&&(i=y[v],v>0&&y.length&&(g=y.indent,a=y[v-1]||y[y.length-1],r=r.substring(a)))}return void 0!==n&&this.$bidiHandler.isBidiRow(s+v,o,v)&&(t=this.$bidiHandler.offsetToCol(n)),a+=this.$getStringScreenWidth(r,t-g)[1],this.$useWrapMode&&a>=i&&(a=i-1),p?p.idxToPosition(a):{row:o,column:a}},this.documentToScreenPosition=function(e,t){if("undefined"===typeof t)var n=this.$clipPositionToDocument(e.row,e.column);else n=this.$clipPositionToDocument(e,t);e=n.row,t=n.column;var r=0,i=null,o=null;o=this.getFoldAt(e,t,1),o&&(e=o.start.row,t=o.start.column);var a,s=0,l=this.$docRowCache,c=this.$getRowCacheIndex(l,e),u=l.length;if(u&&c>=0){s=l[c],r=this.$screenRowCache[c];var h=e>l[u-1]}else h=!u;var d=this.getNextFoldLine(s),f=d?d.start.row:1/0;while(s=f){if(a=d.end.row+1,a>e)break;d=this.getNextFoldLine(a,d),f=d?d.start.row:1/0}else a=s+1;r+=this.getRowLength(s),s=a,h&&(this.$docRowCache.push(s),this.$screenRowCache.push(r))}var p="";d&&s>=f?(p=this.getFoldDisplayLine(d,e,t),i=d.start.row):(p=this.getLine(e).substring(0,t),i=e);var m=0;if(this.$useWrapMode){var g=this.$wrapData[i];if(g){var v=0;while(p.length>=g[v])r++,v++;p=p.substring(g[v-1]||0,p.length),m=v>0?g.indent:0}}return this.lineWidgets&&this.lineWidgets[s]&&this.lineWidgets[s].rowsAbove&&(r+=this.lineWidgets[s].rowsAbove),{row:r,column:m+this.$getStringScreenWidth(p)[0]}},this.documentToScreenColumn=function(e,t){return this.documentToScreenPosition(e,t).column},this.documentToScreenRow=function(e,t){return this.documentToScreenPosition(e,t).row},this.getScreenLength=function(){var e=0,t=null;if(this.$useWrapMode){var n=this.$wrapData.length,r=0,i=(s=0,t=this.$foldData[s++],t?t.start.row:1/0);while(ri&&(r=t.end.row+1,t=this.$foldData[s++],i=t?t.start.row:1/0)}}else{e=this.getLength();for(var a=this.$foldData,s=0;sn)break;return[r,o]})},this.destroy=function(){this.bgTokenizer&&(this.bgTokenizer.setDocument(null),this.bgTokenizer=null),this.$stopWorker(),this.removeAllListeners(),this.selection.detach()},this.isFullWidth=g}.call(p.prototype),e("./edit_session/folding").Folding.call(p.prototype),e("./edit_session/bracket_match").BracketMatch.call(p.prototype),a.defineOptions(p.prototype,"session",{wrap:{set:function(e){if(e&&"off"!=e?"free"==e?e=!0:"printMargin"==e?e=-1:"string"==typeof e&&(e=parseInt(e,10)||!1):e=!1,this.$wrap!=e)if(this.$wrap=e,e){var t="number"==typeof e?e:null;this.setWrapLimitRange(t,t),this.setUseWrapMode(!0)}else this.setUseWrapMode(!1)},get:function(){return this.getUseWrapMode()?-1==this.$wrap?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(e){e="auto"==e?"text"!=this.$mode.type:"text"!=e,e!=this.$wrapAsCode&&(this.$wrapAsCode=e,this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0)))},initialValue:"auto"},indentedSoftWrap:{set:function(){this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0))},initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(e){this.$useWorker=e,this.$stopWorker(),e&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(e){e=parseInt(e),e>0&&this.$tabSize!==e&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=e,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(e){this.setFoldStyle(e)},handlesSet:!0},overwrite:{set:function(e){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(e){this.doc.setNewLineMode(e)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(e){this.setMode(e)},get:function(){return this.$modeId},handlesSet:!0}}),t.EditSession=p}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),o=e("./range").Range,a=function(){this.$options={}};function s(e,t){function n(e){return/\w/.test(e)||t.regExp?"\\b":""}return n(e[0])+e+n(e[e.length-1])}(function(){this.set=function(e){return i.mixin(this.$options,e),this},this.getOptions=function(){return r.copyObject(this.$options)},this.setOptions=function(e){this.$options=e},this.find=function(e){var t=this.$options,n=this.$matchIterator(e,t);if(!n)return!1;var r=null;return n.forEach(function(e,n,i,a){return r=new o(e,n,i,a),!(n==a&&t.start&&t.start.start&&0!=t.skipCurrent&&r.isEqual(t.start))||(r=null,!1)}),r},this.findAll=function(e){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var n=t.range,i=n?e.getLines(n.start.row,n.end.row):e.doc.getAllLines(),a=[],s=t.re;if(t.$isMultiLine){var l,c=s.length,u=i.length-c;e:for(var h=s.offset||0;h<=u;h++){for(var d=0;dm||(a.push(l=new o(h,m,h+c-1,g)),c>2&&(h=h+c-2))}}else for(var v=0;vx&&a[d].end.row==n.end.row)d--;for(a=a.slice(v,d+1),v=0,d=a.length;v=s;n--)if(h(n,Number.MAX_VALUE,e))return;if(0!=t.wrap)for(n=l,s=a.row;n>=s;n--)if(h(n,Number.MAX_VALUE,e))return}};else c=function(e){var n=a.row;if(!h(n,a.column,e)){for(n+=1;n<=l;n++)if(h(n,0,e))return;if(0!=t.wrap)for(n=s,l=a.row;n<=l;n++)if(h(n,0,e))return}};if(t.$isMultiLine)var u=n.length,h=function(t,i,o){var a=r?t-u+1:t;if(!(a<0)){var s=e.getLine(a),l=s.search(n[0]);if(!(!r&&li))return!!o(a,l,a+u-1,h)||void 0}}};else if(r)h=function(t,r,i){var o,a=e.getLine(t),s=[],l=0;n.lastIndex=0;while(o=n.exec(a)){var c=o[0].length;if(l=o.index,!c){if(l>=a.length)break;n.lastIndex=l+=1}if(o.index+c>r)break;s.push(o.index,c)}for(var u=s.length-1;u>=0;u-=2){var h=s[u-1];c=s[u];if(i(t,h,t,h+c))return!0}};else h=function(t,r,i){var o,a,s=e.getLine(t);n.lastIndex=r;while(a=n.exec(s)){var l=a[0].length;if(o=a.index,i(t,o,t,o+l))return!0;if(!l&&(n.lastIndex=o+=1,o>=s.length))return!1}};return{forEach:c}}}).call(a.prototype),t.Search=a}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/keys"),i=e("../lib/useragent"),o=r.KEY_MODS;function a(e,t){this.platform=t||(i.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(e),this.$singleCommand=!0}function s(e,t){a.call(this,e,t),this.$singleCommand=!1}s.prototype=a.prototype,function(){function e(e){return"object"==typeof e&&e.bindKey&&e.bindKey.position||(e.isDefault?-100:0)}this.addCommand=function(e){this.commands[e.name]&&this.removeCommand(e),this.commands[e.name]=e,e.bindKey&&this._buildKeyHash(e)},this.removeCommand=function(e,t){var n=e&&("string"===typeof e?e:e.name);e=this.commands[n],t||delete this.commands[n];var r=this.commandKeyBinding;for(var i in r){var o=r[i];if(o==e)delete r[i];else if(Array.isArray(o)){var a=o.indexOf(e);-1!=a&&(o.splice(a,1),1==o.length&&(r[i]=o[0]))}}},this.bindKey=function(e,t,n){if("object"==typeof e&&e&&(void 0==n&&(n=e.position),e=e[this.platform]),e)return"function"==typeof t?this.addCommand({exec:t,bindKey:e,name:t.name||e}):void e.split("|").forEach(function(e){var r="";if(-1!=e.indexOf(" ")){var i=e.split(/\s+/);e=i.pop(),i.forEach(function(e){var t=this.parseKeys(e),n=o[t.hashId]+t.key;r+=(r?" ":"")+n,this._addCommandToBinding(r,"chainKeys")},this),r+=" "}var a=this.parseKeys(e),s=o[a.hashId]+a.key;this._addCommandToBinding(r+s,t,n)},this)},this._addCommandToBinding=function(t,n,r){var i,o=this.commandKeyBinding;if(n)if(!o[t]||this.$singleCommand)o[t]=n;else{Array.isArray(o[t])?-1!=(i=o[t].indexOf(n))&&o[t].splice(i,1):o[t]=[o[t]],"number"!=typeof r&&(r=e(n));var a=o[t];for(i=0;ir)break}a.splice(i,0,n)}else delete o[t]},this.addCommands=function(e){e&&Object.keys(e).forEach(function(t){var n=e[t];if(n){if("string"===typeof n)return this.bindKey(n,t);"function"===typeof n&&(n={exec:n}),"object"===typeof n&&(n.name||(n.name=t),this.addCommand(n))}},this)},this.removeCommands=function(e){Object.keys(e).forEach(function(t){this.removeCommand(e[t])},this)},this.bindKeys=function(e){Object.keys(e).forEach(function(t){this.bindKey(t,e[t])},this)},this._buildKeyHash=function(e){this.bindKey(e.bindKey,e)},this.parseKeys=function(e){var t=e.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(e){return e}),n=t.pop(),i=r[n];if(r.FUNCTION_KEYS[i])n=r.FUNCTION_KEYS[i].toLowerCase();else{if(!t.length)return{key:n,hashId:-1};if(1==t.length&&"shift"==t[0])return{key:n.toUpperCase(),hashId:-1}}for(var o=0,a=t.length;a--;){var s=r.KEY_MODS[t[a]];if(null==s)return"undefined"!=typeof console&&console.error("invalid modifier "+t[a]+" in "+e),!1;o|=s}return{key:n,hashId:o}},this.findKeyCommand=function(e,t){var n=o[e]+t;return this.commandKeyBinding[n]},this.handleKeyboard=function(e,t,n,r){if(!(r<0)){var i=o[t]+n,a=this.commandKeyBinding[i];return e.$keyChain&&(e.$keyChain+=" "+i,a=this.commandKeyBinding[e.$keyChain]||a),!a||"chainKeys"!=a&&"chainKeys"!=a[a.length-1]?(e.$keyChain&&(t&&4!=t||1!=n.length?(-1==t||r>0)&&(e.$keyChain=""):e.$keyChain=e.$keyChain.slice(0,-i.length-1)),{command:a}):(e.$keyChain=e.$keyChain||i,{command:"null"})}},this.getStatusText=function(e,t){return t.$keyChain||""}}.call(a.prototype),t.HashHandler=a,t.MultiHashHandler=s}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../keyboard/hash_handler").MultiHashHandler,o=e("../lib/event_emitter").EventEmitter,a=function(e,t){i.call(this,t,e),this.byName=this.commands,this.setDefaultHandler("exec",function(e){return e.command.exec(e.editor,e.args||{})})};r.inherits(a,i),function(){r.implement(this,o),this.exec=function(e,t,n){if(Array.isArray(e)){for(var r=e.length;r--;)if(this.exec(e[r],t,n))return!0;return!1}if("string"===typeof e&&(e=this.commands[e]),!e)return!1;if(t&&t.$readOnly&&!e.readOnly)return!1;if(0!=this.$checkCommandState&&e.isAvailable&&!e.isAvailable(t))return!1;var i={editor:t,command:e,args:n};return i.returnValue=this._emit("exec",i),this._signal("afterExec",i),!1!==i.returnValue},this.toggleRecording=function(e){if(!this.$inReplay)return e&&e._emit("changeStatus"),this.recording?(this.macro.pop(),this.off("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(e){this.macro.push([e.command,e.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},this.replay=function(e){if(!this.$inReplay&&this.macro){if(this.recording)return this.toggleRecording(e);try{this.$inReplay=!0,this.macro.forEach(function(t){"string"==typeof t?this.exec(t,e):this.exec(t[0],e,t[1])},this)}finally{this.$inReplay=!1}}},this.trimMacro=function(e){return e.map(function(e){return"string"!=typeof e[0]&&(e[0]=e[0].name),e[1]||(e=e[0]),e})}}.call(a.prototype),t.CommandManager=a}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(e,t,n){"use strict";var r=e("../lib/lang"),i=e("../config"),o=e("../range").Range;function a(e,t){return{win:e,mac:t}}t.commands=[{name:"showSettingsMenu",bindKey:a("Ctrl-,","Command-,"),exec:function(e){i.loadModule("ace/ext/settings_menu",function(t){t.init(e),e.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",bindKey:a("Alt-E","F4"),exec:function(e){i.loadModule("./ext/error_marker",function(t){t.showErrorMarker(e,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",bindKey:a("Alt-Shift-E","Shift-F4"),exec:function(e){i.loadModule("./ext/error_marker",function(t){t.showErrorMarker(e,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:a("Ctrl-A","Command-A"),exec:function(e){e.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:a(null,"Ctrl-L"),exec:function(e){e.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:a("Ctrl-L","Command-L"),exec:function(e,t){"number"!==typeof t||isNaN(t)||e.gotoLine(t),e.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:a("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(e){e.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:a("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(e){e.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",bindKey:a("F2","F2"),exec:function(e){e.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",bindKey:a("Alt-F2","Alt-F2"),exec:function(e){e.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:a(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:a(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:a("Alt-0","Command-Option-0"),exec:function(e){e.session.foldAll(),e.session.unfold(e.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:a("Alt-Shift-0","Command-Option-Shift-0"),exec:function(e){e.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:a("Ctrl-K","Command-G"),exec:function(e){e.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:a("Ctrl-Shift-K","Command-Shift-G"),exec:function(e){e.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:a("Alt-K","Ctrl-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:a("Alt-Shift-K","Ctrl-Shift-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:a("Ctrl-F","Command-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e)})},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(e){e.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:a("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(e){e.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:a("Ctrl-Home","Command-Home|Command-Up"),exec:function(e){e.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:a("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(e){e.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:a("Up","Up|Ctrl-P"),exec:function(e,t){e.navigateUp(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:a("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(e){e.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:a("Ctrl-End","Command-End|Command-Down"),exec:function(e){e.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:a("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(e){e.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:a("Down","Down|Ctrl-N"),exec:function(e,t){e.navigateDown(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:a("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(e){e.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:a("Ctrl-Left","Option-Left"),exec:function(e){e.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:a("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:a("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(e){e.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:a("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(e){e.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:a("Left","Left|Ctrl-B"),exec:function(e,t){e.navigateLeft(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:a("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(e){e.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:a("Ctrl-Right","Option-Right"),exec:function(e){e.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:a("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:a("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(e){e.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:a("Shift-Right","Shift-Right"),exec:function(e){e.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:a("Right","Right|Ctrl-F"),exec:function(e,t){e.navigateRight(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(e){e.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:a(null,"Option-PageDown"),exec:function(e){e.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:a("PageDown","PageDown|Ctrl-V"),exec:function(e){e.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(e){e.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:a(null,"Option-PageUp"),exec:function(e){e.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(e){e.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:a("Ctrl-Up",null),exec:function(e){e.renderer.scrollBy(0,-2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:a("Ctrl-Down",null),exec:function(e){e.renderer.scrollBy(0,2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:a("Ctrl-Alt-E","Command-Option-E"),exec:function(e){e.commands.toggleRecording(e)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:a("Ctrl-Shift-E","Command-Shift-E"),exec:function(e){e.commands.replay(e)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:a("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(e){e.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:a("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(e){e.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:a("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(e){e.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:a(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(e){},readOnly:!0},{name:"cut",description:"Cut",exec:function(e){var t=e.$copyWithEmptySelection&&e.selection.isEmpty(),n=t?e.selection.getLineRange():e.selection.getRange();e._emit("cut",n),n.isEmpty()||e.session.remove(n),e.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(e,t){e.$handlePaste(t)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:a("Ctrl-D","Command-D"),exec:function(e){e.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:a("Ctrl-Shift-D","Command-Shift-D"),exec:function(e){e.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:a("Ctrl-Alt-S","Command-Alt-S"),exec:function(e){e.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:a("Ctrl-/","Command-/"),exec:function(e){e.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:a("Ctrl-Shift-/","Command-Shift-/"),exec:function(e){e.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:a("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(e){e.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:a("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(e){e.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:a("Ctrl-H","Command-Option-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e,!0)})}},{name:"undo",description:"Undo",bindKey:a("Ctrl-Z","Command-Z"),exec:function(e){e.undo()}},{name:"redo",description:"Redo",bindKey:a("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(e){e.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:a("Alt-Shift-Up","Command-Option-Up"),exec:function(e){e.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:a("Alt-Up","Option-Up"),exec:function(e){e.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:a("Alt-Shift-Down","Command-Option-Down"),exec:function(e){e.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:a("Alt-Down","Option-Down"),exec:function(e){e.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:a("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(e){e.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:a("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(e){e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:a("Shift-Delete",null),exec:function(e){if(!e.selection.isEmpty())return!1;e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:a("Alt-Backspace","Command-Backspace"),exec:function(e){e.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:a("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(e){e.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:a("Ctrl-Shift-Backspace",null),exec:function(e){var t=e.selection.getRange();t.start.column=0,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:a("Ctrl-Shift-Delete",null),exec:function(e){var t=e.selection.getRange();t.end.column=Number.MAX_VALUE,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:a("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(e){e.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:a("Ctrl-Delete","Alt-Delete"),exec:function(e){e.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:a("Shift-Tab","Shift-Tab"),exec:function(e){e.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:a("Tab","Tab"),exec:function(e){e.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:a("Ctrl-[","Ctrl-["),exec:function(e){e.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:a("Ctrl-]","Ctrl-]"),exec:function(e){e.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(e,t){e.insert(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(e,t){e.insert(r.stringRepeat(t.text||"",t.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:a(null,"Ctrl-O"),exec:function(e){e.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:a("Alt-Shift-X","Ctrl-T"),exec:function(e){e.transposeLetters()},multiSelectAction:function(e){e.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:a("Ctrl-U","Ctrl-U"),exec:function(e){e.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:a("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(e){e.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:a(null,null),exec:function(e){e.autoIndent()},multiSelectAction:"forEachLine",scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:a("Ctrl-Shift-L","Command-Shift-L"),exec:function(e){var t=e.selection.getRange();t.start.column=t.end.column=0,t.end.row++,e.selection.setRange(t,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"joinlines",description:"Join lines",bindKey:a(null,null),exec:function(e){for(var t=e.selection.isBackwards(),n=t?e.selection.getSelectionLead():e.selection.getSelectionAnchor(),i=t?e.selection.getSelectionAnchor():e.selection.getSelectionLead(),a=e.session.doc.getLine(n.row).length,s=e.session.doc.getTextRange(e.selection.getRange()),l=s.replace(/\n\s*/," ").length,c=e.session.doc.getLine(n.row),u=n.row+1;u<=i.row+1;u++){var h=r.stringTrimLeft(r.stringTrimRight(e.session.doc.getLine(u)));0!==h.length&&(h=" "+h),c+=h}i.row+10?(e.selection.moveCursorTo(n.row,n.column),e.selection.selectTo(n.row,n.column+l)):(a=e.session.doc.getLine(n.row).length>a?a+1:a,e.selection.moveCursorTo(n.row,a))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:a(null,null),exec:function(e){var t=e.session.doc.getLength()-1,n=e.session.doc.getLine(t).length,r=e.selection.rangeList.ranges,i=[];r.length<1&&(r=[e.selection.getRange()]);for(var a=0;a=i.lastRow||r.end.row<=i.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break;default:break}"animate"==n&&this.renderer.animateScrolling(this.curOp.scrollTop)}var o=this.selection.toJSON();this.curOp.selectionAfter=o,this.$lastSel=this.selection.toJSON(),this.session.getUndoManager().addSelection(o),this.prevOp=this.curOp,this.curOp=null}},this.$mergeableCommands=["backspace","del","insertstring"],this.$historyTracker=function(e){if(this.$mergeUndoDeltas){var t=this.prevOp,n=this.$mergeableCommands,r=t.command&&e.command.name==t.command.name;if("insertstring"==e.command.name){var i=e.args;void 0===this.mergeNextCommand&&(this.mergeNextCommand=!0),r=r&&this.mergeNextCommand&&(!/\s/.test(i)||/\s/.test(t.args)),this.mergeNextCommand=!0}else r=r&&-1!==n.indexOf(e.command.name);"always"!=this.$mergeUndoDeltas&&Date.now()-this.sequenceStartTime>2e3&&(r=!1),r?this.session.mergeUndoDeltas=!0:-1!==n.indexOf(e.command.name)&&(this.sequenceStartTime=Date.now())}},this.setKeyboardHandler=function(e,t){if(e&&"string"===typeof e&&"ace"!=e){this.$keybindingId=e;var n=this;v.loadModule(["keybinding",e],function(r){n.$keybindingId==e&&n.keyBinding.setKeyboardHandler(r&&r.handler),t&&t()})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(e),t&&t()},this.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},this.setSession=function(e){if(this.session!=e){this.curOp&&this.endOperation(),this.curOp={};var t=this.session;if(t){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange);var n=this.session.getSelection();n.off("changeCursor",this.$onCursorChange),n.off("changeSelection",this.$onSelectionChange)}this.session=e,e?(this.$onDocumentChange=this.onDocumentChange.bind(this),e.on("change",this.$onDocumentChange),this.renderer.setSession(e),this.$onChangeMode=this.onChangeMode.bind(this),e.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),e.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),e.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),e.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),e.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),e.on("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.on("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.on("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.on("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.on("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.on("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.on("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.on("changeScrollLeft",this.$onScrollLeftChange),this.selection=e.getSelection(),this.selection.on("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.onChangeMode(),this.onCursorChange(),this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(e)),this._signal("changeSession",{session:e,oldSession:t}),this.curOp=null,t&&t._signal("changeEditor",{oldEditor:this}),e&&e._signal("changeEditor",{editor:this}),e&&e.bgTokenizer&&e.bgTokenizer.scheduleStart()}},this.getSession=function(){return this.session},this.setValue=function(e,t){return this.session.doc.setValue(e),t?1==t?this.navigateFileEnd():-1==t&&this.navigateFileStart():this.selectAll(),e},this.getValue=function(){return this.session.getValue()},this.getSelection=function(){return this.selection},this.resize=function(e){this.renderer.onResize(e)},this.setTheme=function(e,t){this.renderer.setTheme(e,t)},this.getTheme=function(){return this.renderer.getTheme()},this.setStyle=function(e){this.renderer.setStyle(e)},this.unsetStyle=function(e){this.renderer.unsetStyle(e)},this.getFontSize=function(){return this.getOption("fontSize")||i.computedStyle(this.container).fontSize},this.setFontSize=function(e){this.setOption("fontSize",e)},this.$highlightBrackets=function(){if(!this.$highlightPending){var e=this;this.$highlightPending=!0,setTimeout(function(){e.$highlightPending=!1;var t=e.session;if(t&&t.bgTokenizer){t.$bracketHighlight&&(t.$bracketHighlight.markerIds.forEach(function(e){t.removeMarker(e)}),t.$bracketHighlight=null);var n=t.getMatchingBracketRanges(e.getCursorPosition());if(!n&&t.$mode.getMatching&&(n=t.$mode.getMatching(e.session)),n){var r="ace_bracket";Array.isArray(n)?1==n.length&&(r="ace_error_bracket"):n=[n],2==n.length&&(0==f.comparePoints(n[0].end,n[1].start)?n=[f.fromPoints(n[0].start,n[1].end)]:0==f.comparePoints(n[0].start,n[1].end)&&(n=[f.fromPoints(n[1].start,n[0].end)])),t.$bracketHighlight={ranges:n,markerIds:n.map(function(e){return t.addMarker(e,r,"text")})}}}},50)}},this.$highlightTags=function(){if(!this.$highlightTagPending){var e=this;this.$highlightTagPending=!0,setTimeout(function(){e.$highlightTagPending=!1;var t=e.session;if(t&&t.bgTokenizer){var n=e.getCursorPosition(),r=new y(e.session,n.row,n.column),i=r.getCurrentToken();if(!i||!/\b(?:tag-open|tag-name)/.test(i.type))return t.removeMarker(t.$tagHighlight),void(t.$tagHighlight=null);if(-1===i.type.indexOf("tag-open")||(i=r.stepForward(),i)){var o=i.value,a=i.value,s=0,l=r.stepBackward();if("<"===l.value)do{l=i,i=r.stepForward(),i&&(-1!==i.type.indexOf("tag-name")?(a=i.value,o===a&&("<"===l.value?s++:""===l.value&&s--)):o===a&&"/>"===i.value&&s--)}while(i&&s>=0);else{do{if(i=l,l=r.stepBackward(),i)if(-1!==i.type.indexOf("tag-name"))o===i.value&&("<"===l.value?s++:""===l.value&&s--);else if("/>"===i.value){var c=0,u=l;while(u){if(-1!==u.type.indexOf("tag-name")&&u.value===o){s--;break}if("<"===u.value)break;u=r.stepBackward(),c++}for(var h=0;h1||(e=!1)),t.$highlightLineMarker&&!e)t.removeMarker(t.$highlightLineMarker.id),t.$highlightLineMarker=null;else if(!t.$highlightLineMarker&&e){var n=new f(e.row,e.column,e.row,1/0);n.id=t.addMarker(n,"ace_active-line","screenLine"),t.$highlightLineMarker=n}else e&&(t.$highlightLineMarker.start.row=e.row,t.$highlightLineMarker.end.row=e.row,t.$highlightLineMarker.start.column=e.column,t._signal("changeBackMarker"))},this.onSelectionChange=function(e){var t=this.session;if(t.$selectionMarker&&t.removeMarker(t.$selectionMarker),t.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var n=this.selection.getRange(),r=this.getSelectionStyle();t.$selectionMarker=t.addMarker(n,"ace_selection",r)}var i=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(i),this._signal("changeSelection")},this.$getSelectionHighLightRegexp=function(){var e=this.session,t=this.getSelectionRange();if(!t.isEmpty()&&!t.isMultiLine()){var n=t.start.column,r=t.end.column,i=e.getLine(t.start.row),o=i.substring(n,r);if(!(o.length>5e3)&&/[\w\d]/.test(o)){var a=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:o}),s=i.substring(n-1,r+1);if(a.test(s))return a}}},this.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},this.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},this.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},this.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},this.onChangeMode=function(e){this.renderer.updateText(),this._emit("changeMode",e)},this.onChangeWrapLimit=function(){this.renderer.updateFull()},this.onChangeWrapMode=function(){this.renderer.onResize(!0)},this.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},this.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},this.getCopyText=function(){var e=this.getSelectedText(),t=this.session.doc.getNewLineCharacter(),n=!1;if(!e&&this.$copyWithEmptySelection){n=!0;for(var r=this.selection.getAllRanges(),i=0;is.search(/\S|$/)){var l=s.substr(i.column).search(/\S|$/);n.doc.removeInLine(i.row,i.column,i.column+l)}}this.clearSelection();var c=i.column,u=n.getState(i.row),h=(s=n.getLine(i.row),r.checkOutdent(u,s,e));if(n.insert(i,e),o&&o.selection&&(2==o.selection.length?this.selection.setSelectionRange(new f(i.row,c+o.selection[0],i.row,c+o.selection[1])):this.selection.setSelectionRange(new f(i.row+o.selection[0],o.selection[1],i.row+o.selection[2],o.selection[3]))),this.$enableAutoIndent){if(n.getDocument().isNewLine(e)){var d=r.getNextLineIndent(u,s.slice(0,i.column),n.getTabString());n.insert({row:i.row+1,column:0},d)}h&&r.autoOutdent(u,n,i.row)}},this.autoIndent=function(){var e,t,n=this.session,r=n.getMode();if(this.selection.isEmpty())e=0,t=n.doc.getLength()-1;else{var i=this.getSelectionRange();e=i.start.row,t=i.end.row}for(var o,a,s,l="",c="",u="",h=n.getTabString(),d=e;d<=t;d++)d>0&&(l=n.getState(d-1),c=n.getLine(d-1),u=r.getNextLineIndent(l,c,h)),o=n.getLine(d),a=r.$getIndent(o),u!==a&&(a.length>0&&(s=new f(d,0,d,a.length),n.remove(s)),u.length>0&&n.insert({row:d,column:0},u)),r.autoOutdent(l,n,d)},this.onTextInput=function(e,t){if(!t)return this.keyBinding.onTextInput(e);this.startOperation({command:{name:"insertstring"}});var n=this.applyComposition.bind(this,e,t);this.selection.rangeCount?this.forEachSelection(n):n(),this.endOperation()},this.applyComposition=function(e,t){if(t.extendLeft||t.extendRight){var n=this.selection.getRange();n.start.column-=t.extendLeft,n.end.column+=t.extendRight,n.start.column<0&&(n.start.row--,n.start.column+=this.session.getLine(n.start.row).length+1),this.selection.setRange(n),e||n.isEmpty()||this.remove()}if(!e&&this.selection.isEmpty()||this.insert(e,!0),t.restoreStart||t.restoreEnd){n=this.selection.getRange();n.start.column-=t.restoreStart,n.end.column-=t.restoreEnd,this.selection.setRange(n)}},this.onCommandKey=function(e,t,n){return this.keyBinding.onCommandKey(e,t,n)},this.setOverwrite=function(e){this.session.setOverwrite(e)},this.getOverwrite=function(){return this.session.getOverwrite()},this.toggleOverwrite=function(){this.session.toggleOverwrite()},this.setScrollSpeed=function(e){this.setOption("scrollSpeed",e)},this.getScrollSpeed=function(){return this.getOption("scrollSpeed")},this.setDragDelay=function(e){this.setOption("dragDelay",e)},this.getDragDelay=function(){return this.getOption("dragDelay")},this.setSelectionStyle=function(e){this.setOption("selectionStyle",e)},this.getSelectionStyle=function(){return this.getOption("selectionStyle")},this.setHighlightActiveLine=function(e){this.setOption("highlightActiveLine",e)},this.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.setHighlightSelectedWord=function(e){this.setOption("highlightSelectedWord",e)},this.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},this.setAnimatedScroll=function(e){this.renderer.setAnimatedScroll(e)},this.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},this.setShowInvisibles=function(e){this.renderer.setShowInvisibles(e)},this.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},this.setDisplayIndentGuides=function(e){this.renderer.setDisplayIndentGuides(e)},this.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},this.setShowPrintMargin=function(e){this.renderer.setShowPrintMargin(e)},this.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},this.setPrintMarginColumn=function(e){this.renderer.setPrintMarginColumn(e)},this.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},this.setReadOnly=function(e){this.setOption("readOnly",e)},this.getReadOnly=function(){return this.getOption("readOnly")},this.setBehavioursEnabled=function(e){this.setOption("behavioursEnabled",e)},this.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},this.setWrapBehavioursEnabled=function(e){this.setOption("wrapBehavioursEnabled",e)},this.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},this.setShowFoldWidgets=function(e){this.setOption("showFoldWidgets",e)},this.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.remove=function(e){this.selection.isEmpty()&&("left"==e?this.selection.selectLeft():this.selection.selectRight());var t=this.getSelectionRange();if(this.getBehavioursEnabled()){var n=this.session,r=n.getState(t.start.row),i=n.getMode().transformAction(r,"deletion",this,n,t);if(0===t.end.column){var o=n.getTextRange(t);if("\n"==o[o.length-1]){var a=n.getLine(t.end.row);/^\s+$/.test(a)&&(t.end.column=a.length)}}i&&(t=i)}this.session.remove(t),this.clearSelection()},this.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var e=this.getSelectionRange();e.start.column==e.end.column&&e.start.row==e.end.row&&(e.end.column=0,e.end.row++),this.session.remove(e),this.clearSelection()},this.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var e=this.getCursorPosition();this.insert("\n"),this.moveCursorToPosition(e)},this.transposeLetters=function(){if(this.selection.isEmpty()){var e=this.getCursorPosition(),t=e.column;if(0!==t){var n,r,i=this.session.getLine(e.row);tt.toLowerCase()?1:0});var i=new f(0,0,0,0);for(r=e.first;r<=e.last;r++){var o=t.getLine(r);i.start.row=r,i.end.row=r,i.end.column=o.length,t.replace(i,n[r-e.first])}},this.toggleCommentLines=function(){var e=this.session.getState(this.getCursorPosition().row),t=this.$getSelectedRows();this.session.getMode().toggleCommentLines(e,this.session,t.first,t.last)},this.toggleBlockComment=function(){var e=this.getCursorPosition(),t=this.session.getState(e.row),n=this.getSelectionRange();this.session.getMode().toggleBlockComment(t,this.session,n,e)},this.getNumberAt=function(e,t){var n=/[\-]?[0-9]+(?:\.[0-9]+)?/g;n.lastIndex=0;var r=this.session.getLine(e);while(n.lastIndex=t){var o={value:i[0],start:i.index,end:i.index+i[0].length};return o}}return null},this.modifyNumber=function(e){var t=this.selection.getCursor().row,n=this.selection.getCursor().column,r=new f(t,n-1,t,n),i=this.session.getTextRange(r);if(!isNaN(parseFloat(i))&&isFinite(i)){var o=this.getNumberAt(t,n);if(o){var a=o.value.indexOf(".")>=0?o.start+o.value.indexOf(".")+1:o.end,s=o.start+o.value.length-a,l=parseFloat(o.value);l*=Math.pow(10,s),a!==o.end&&n=s&&a<=l&&(n=t,c.selection.clearSelection(),c.moveCursorTo(e,s+r),c.selection.selectTo(e,l+r)),s=l});for(var u,h=this.$toggleWordPairs,d=0;df+1)break;f=p.last}u--,s=this.session.$moveLines(d,f,t?0:e),t&&-1==e&&(h=u+1);while(h<=u)a[h].moveBy(s,0),h++;t||(s=0),l+=s}i.fromOrientedRange(i.ranges[0]),i.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},this.$getSelectedRows=function(e){return e=(e||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(e.start.row),last:this.session.getRowFoldEnd(e.end.row)}},this.onCompositionStart=function(e){this.renderer.showComposition(e)},this.onCompositionUpdate=function(e){this.renderer.setCompositionText(e)},this.onCompositionEnd=function(){this.renderer.hideComposition()},this.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},this.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},this.isRowVisible=function(e){return e>=this.getFirstVisibleRow()&&e<=this.getLastVisibleRow()},this.isRowFullyVisible=function(e){return e>=this.renderer.getFirstFullyVisibleRow()&&e<=this.renderer.getLastFullyVisibleRow()},this.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},this.$moveByPage=function(e,t){var n=this.renderer,r=this.renderer.layerConfig,i=e*Math.floor(r.height/r.lineHeight);!0===t?this.selection.$moveSelection(function(){this.moveCursorBy(i,0)}):!1===t&&(this.selection.moveCursorBy(i,0),this.selection.clearSelection());var o=n.scrollTop;n.scrollBy(0,i*r.lineHeight),null!=t&&n.scrollCursorIntoView(null,.5),n.animateScrolling(o)},this.selectPageDown=function(){this.$moveByPage(1,!0)},this.selectPageUp=function(){this.$moveByPage(-1,!0)},this.gotoPageDown=function(){this.$moveByPage(1,!1)},this.gotoPageUp=function(){this.$moveByPage(-1,!1)},this.scrollPageDown=function(){this.$moveByPage(1)},this.scrollPageUp=function(){this.$moveByPage(-1)},this.scrollToRow=function(e){this.renderer.scrollToRow(e)},this.scrollToLine=function(e,t,n,r){this.renderer.scrollToLine(e,t,n,r)},this.centerSelection=function(){var e=this.getSelectionRange(),t={row:Math.floor(e.start.row+(e.end.row-e.start.row)/2),column:Math.floor(e.start.column+(e.end.column-e.start.column)/2)};this.renderer.alignCursor(t,.5)},this.getCursorPosition=function(){return this.selection.getCursor()},this.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},this.getSelectionRange=function(){return this.selection.getRange()},this.selectAll=function(){this.selection.selectAll()},this.clearSelection=function(){this.selection.clearSelection()},this.moveCursorTo=function(e,t){this.selection.moveCursorTo(e,t)},this.moveCursorToPosition=function(e){this.selection.moveCursorToPosition(e)},this.jumpToMatching=function(e,t){var n=this.getCursorPosition(),r=new y(this.session,n.row,n.column),i=r.getCurrentToken(),o=i||r.stepForward();if(o){var a,s,l=!1,c={},u=n.column-o.start,h={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(o.value.match(/[{}()\[\]]/g)){for(;u=0;--o)this.$tryReplace(n[o],e)&&r++;return this.selection.setSelectionRange(i),r},this.$tryReplace=function(e,t){var n=this.session.getTextRange(e);return t=this.$search.replace(n,t),null!==t?(e.end=this.session.replace(e,t),e):null},this.getLastSearchOptions=function(){return this.$search.getOptions()},this.find=function(e,t,n){t||(t={}),"string"==typeof e||e instanceof RegExp?t.needle=e:"object"==typeof e&&r.mixin(t,e);var i=this.selection.getRange();null==t.needle&&(e=this.session.getTextRange(i)||this.$search.$options.needle,e||(i=this.session.getWordRange(i.start.row,i.start.column),e=this.session.getTextRange(i)),this.$search.set({needle:e})),this.$search.set(t),t.start||this.$search.set({start:i});var o=this.$search.find(this.session);return t.preventScroll?o:o?(this.revealRange(o,n),o):(t.backwards?i.start=i.end:i.end=i.start,void this.selection.setRange(i))},this.findNext=function(e,t){this.find({skipCurrent:!0,backwards:!1},e,t)},this.findPrevious=function(e,t){this.find(e,{skipCurrent:!0,backwards:!0},t)},this.revealRange=function(e,t){this.session.unfold(e),this.selection.setSelectionRange(e);var n=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(e.start,e.end,.5),!1!==t&&this.renderer.animateScrolling(n)},this.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},this.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},this.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach(function(e){e.destroy()}),this.$toDestroy=null),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},this.setAutoScrollEditorIntoView=function(e){if(e){var t,n=this,r=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var i=this.$scrollAnchor;i.style.cssText="position:absolute",this.container.insertBefore(i,this.container.firstChild);var o=this.on("changeSelection",function(){r=!0}),a=this.renderer.on("beforeRender",function(){r&&(t=n.renderer.container.getBoundingClientRect())}),s=this.renderer.on("afterRender",function(){if(r&&t&&(n.isFocused()||n.searchBox&&n.searchBox.isFocused())){var e=n.renderer,o=e.$cursorLayer.$pixelPos,a=e.layerConfig,s=o.top-a.offset;r=o.top>=0&&s+t.top<0||!(o.topwindow.innerHeight)&&null,null!=r&&(i.style.top=s+"px",i.style.left=o.left+"px",i.style.height=a.lineHeight+"px",i.scrollIntoView(r)),r=t=null}});this.setAutoScrollEditorIntoView=function(e){e||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",o),this.renderer.off("afterRender",s),this.renderer.off("beforeRender",a))}}},this.$resetCursorStyle=function(){var e=this.$cursorStyle||"ace",t=this.renderer.$cursorLayer;t&&(t.setSmoothBlinking(/smooth/.test(e)),t.isBlinking=!this.$readOnly&&"wide"!=e,i.setCssClass(t.element,"ace_slim-cursors",/slim/.test(e)))},this.prompt=function(e,t,n){var r=this;v.loadModule("./ext/prompt",function(i){i.prompt(r,e,t,n)})}}.call(w.prototype),v.defineOptions(w.prototype,"editor",{selectionStyle:{set:function(e){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:e})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(e){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(e){this.textInput.setReadOnly(e),this.$resetCursorStyle()},initialValue:!1},copyWithEmptySelection:{set:function(e){this.textInput.setCopyWithEmptySelection(e)},initialValue:!1},cursorStyle:{set:function(e){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},enableAutoIndent:{initialValue:!0},autoScrollEditorIntoView:{set:function(e){this.setAutoScrollEditorIntoView(e)}},keyboardHandler:{set:function(e){this.setKeyboardHandler(e)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(e){this.session.setValue(e)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(e){this.setSession(e)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(e){this.renderer.$gutterLayer.setShowLineNumbers(e),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),e&&this.$relativeLineNumbers?x.attach(this):x.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(e){this.$showLineNumbers&&e?x.attach(this):x.detach(this)}},placeholder:{set:function(e){this.$updatePlaceholder||(this.$updatePlaceholder=function(){var e=this.session&&(this.renderer.$composition||this.getValue());if(e&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),i.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(e||this.renderer.placeholderNode)!e&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"");else{this.renderer.on("afterRender",this.$updatePlaceholder),i.addCssClass(this.container,"ace_hasPlaceholder");var t=i.createElement("div");t.className="ace_placeholder",t.textContent=this.$placeholder||"",this.renderer.placeholderNode=t,this.renderer.content.appendChild(this.renderer.placeholderNode)}}.bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var x={getText:function(e,t){return(Math.abs(e.selection.lead.row-t)||t+1+(t<9?"\xb7":""))+""},getWidth:function(e,t,n){return Math.max(t.toString().length,(n.lastRow+1).toString().length,2)*n.characterWidth},update:function(e,t){t.renderer.$loop.schedule(t.renderer.CHANGE_GUTTER)},attach:function(e){e.renderer.$gutterLayer.$renderer=this,e.on("changeSelection",this.update),this.update(null,e)},detach:function(e){e.renderer.$gutterLayer.$renderer==this&&(e.renderer.$gutterLayer.$renderer=null),e.off("changeSelection",this.update),this.update(null,e)}};t.Editor=w}),ace.define("ace/undomanager",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=function(){this.$maxRev=0,this.$fromUndo=!1,this.reset()};function i(e,t){for(var n=t;n--;){var r=e[n];if(r&&!r[0].ignore){while(n0},this.canRedo=function(){return this.$redoStack.length>0},this.bookmark=function(e){void 0==e&&(e=this.$rev),this.mark=e},this.isAtBookmark=function(){return this.$rev===this.mark},this.toJSON=function(){},this.fromJSON=function(){},this.hasUndo=this.canUndo,this.hasRedo=this.canRedo,this.isClean=this.isAtBookmark,this.markClean=this.bookmark,this.$prettyPrint=function(e){return e?c(e):c(this.$undoStack)+"\n---\n"+c(this.$redoStack)}}).call(r.prototype);var o=e("./range").Range,a=o.comparePoints;o.comparePoints;function s(e){return{row:e.row,column:e.column}}function l(e){return{start:s(e.start),end:s(e.end),action:e.action,lines:e.lines.slice()}}function c(e){if(e=e||this,Array.isArray(e))return e.map(c).join("\n");var t="";return e.action?(t="insert"==e.action?"+":"-",t+="["+e.lines+"]"):e.value&&(t=Array.isArray(e.value)?e.value.map(u).join("\n"):u(e.value)),e.start&&(t+=u(e)),(e.id||e.rev)&&(t+="\t("+(e.id||e.rev)+")"),t}function u(e){return e.start.row+":"+e.start.column+"=>"+e.end.row+":"+e.end.column}function h(e,t){var n="insert"==e.action,r="insert"==t.action;if(n&&r)if(a(t.start,e.end)>=0)p(t,e,-1);else{if(!(a(t.start,e.start)<=0))return null;p(e,t,1)}else if(n&&!r)if(a(t.start,e.end)>=0)p(t,e,-1);else{if(!(a(t.end,e.start)<=0))return null;p(e,t,-1)}else if(!n&&r)if(a(t.start,e.start)>=0)p(t,e,1);else{if(!(a(t.start,e.start)<=0))return null;p(e,t,1)}else if(!n&&!r)if(a(t.start,e.start)>=0)p(t,e,1);else{if(!(a(t.end,e.start)<=0))return null;p(e,t,-1)}return[t,e]}function d(e,t){for(var n=e.length;n--;)for(var r=0;r=0?p(e,t,-1):a(e.start,t.start)<=0?p(t,e,1):(p(e,o.fromPoints(t.start,e.start),-1),p(t,e,1));else if(!n&&r)a(t.start,e.end)>=0?p(t,e,-1):a(t.start,e.start)<=0?p(e,t,1):(p(t,o.fromPoints(e.start,t.start),-1),p(e,t,1));else if(!n&&!r)if(a(t.start,e.end)>=0)p(t,e,-1);else{var i,s;if(!(a(t.end,e.start)<=0))return a(e.start,t.start)<0&&(i=e,e=g(e,t.start)),a(e.end,t.end)>0&&(s=g(e,t.end)),m(t.end,e.start,e.end,-1),s&&!i&&(e.lines=s.lines,e.start=s.start,e.end=s.end,s=e),[t,i,s].filter(Boolean);p(e,t,-1)}return[t,e]}function p(e,t,n){m(e.start,t.start,t.end,n),m(e.end,t.start,t.end,n)}function m(e,t,n,r){e.row==(1==r?t:n).row&&(e.column+=r*(n.column-t.column)),e.row+=r*(n.row-t.row)}function g(e,t){var n=e.lines,r=e.end;e.end=s(t);var i=e.end.row-e.start.row,o=n.splice(i,n.length),a=i?t.column:t.column-e.start.column;n.push(o[0].substring(0,a)),o[0]=o[0].substr(a);var l={start:s(t),end:r,lines:o,action:e.action};return l}function v(e,t){t=l(t);for(var n=e.length;n--;){for(var r=e[n],i=0;io&&(l=i.end.row+1,i=t.getNextFoldLine(l,i),o=i?i.start.row:1/0),l>r){while(this.$lines.getLength()>s+1)this.$lines.pop();break}a=this.$lines.get(++s),a?a.row=l:(a=this.$lines.createCell(l,e,this.session,c),this.$lines.push(a)),this.$renderCell(a,e,i,l),l++}this._signal("afterRender"),this.$updateGutterWidth(e)},this.$updateGutterWidth=function(e){var t=this.session,n=t.gutterRenderer||this.$renderer,r=t.$firstLineNumber,i=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||t.$useWrapMode)&&(i=t.getLength()+r-1);var o=n?n.getWidth(t,i,e):i.toString().length*e.characterWidth,a=this.$padding||this.$computePadding();o+=a.left+a.right,o===this.gutterWidth||isNaN(o)||(this.gutterWidth=o,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",o))},this.$updateCursorRow=function(){if(this.$highlightGutterLine){var e=this.session.selection.getCursor();this.$cursorRow!==e.row&&(this.$cursorRow=e.row)}},this.updateLineHighlight=function(){if(this.$highlightGutterLine){var e=this.session.selection.cursor.row;if(this.$cursorRow=e,!this.$cursorCell||this.$cursorCell.row!=e){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var t=this.$lines.cells;this.$cursorCell=null;for(var n=0;n=this.$cursorRow){if(r.row>this.$cursorRow){var i=this.session.getFoldLine(this.$cursorRow);if(!(n>0&&i&&i.start.row==t[n-1].row))break;r=t[n-1]}r.element.className="ace_gutter-active-line "+r.element.className,this.$cursorCell=r;break}}}}},this.scrollLines=function(e){var t=this.config;if(this.config=e,this.$updateCursorRow(),this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=Math.min(e.lastRow+e.gutterOffset,this.session.getLength()-1),r=this.oldLastRow;if(this.oldLastRow=n,!t||r0;i--)this.$lines.shift();if(r>n)for(i=this.session.getFoldedRowCount(n+1,r);i>0;i--)this.$lines.pop();e.firstRowr&&this.$lines.push(this.$renderLines(e,r+1,n)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(e)},this.$renderLines=function(e,t,n){var r=[],i=t,o=this.session.getNextFoldLine(i),a=o?o.start.row:1/0;while(1){if(i>a&&(i=o.end.row+1,o=this.session.getNextFoldLine(i,o),a=o?o.start.row:1/0),i>n)break;var s=this.$lines.createCell(i,e,this.session,c);this.$renderCell(s,e,o,i),r.push(s),i++}return r},this.$renderCell=function(e,t,n,i){var o=e.element,a=this.session,s=o.childNodes[0],l=o.childNodes[1],c=a.$firstLineNumber,u=a.$breakpoints,h=a.$decorations,d=a.gutterRenderer||this.$renderer,f=this.$showFoldWidgets&&a.foldWidgets,p=n?n.start.row:Number.MAX_VALUE,m="ace_gutter-cell ";if(this.$highlightGutterLine&&(i==this.$cursorRow||n&&i=p&&this.$cursorRow<=n.end.row)&&(m+="ace_gutter-active-line ",this.$cursorCell!=e&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=e)),u[i]&&(m+=u[i]),h[i]&&(m+=h[i]),this.$annotations[i]&&(m+=this.$annotations[i].className),o.className!=m&&(o.className=m),f){var g=f[i];null==g&&(g=f[i]=a.getFoldWidget(i))}if(g){m="ace_fold-widget ace_"+g;"start"==g&&i==p&&in.right-t.right?"foldWidgets":void 0}}).call(l.prototype),t.Gutter=l}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../range").Range,i=e("../lib/dom"),o=function(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_marker-layer",e.appendChild(this.element)};(function(){function e(e,t,n,r){return(e?1:0)|(t?2:0)|(n?4:0)|(r?8:0)}this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setMarkers=function(e){this.markers=e},this.elt=function(e,t){var n=-1!=this.i&&this.element.childNodes[this.i];n?this.i++:(n=document.createElement("div"),this.element.appendChild(n),this.i=-1),n.style.cssText=t,n.className=e},this.update=function(e){if(e){var t;for(var n in this.config=e,this.i=0,this.markers){var r=this.markers[n];if(r.range){var i=r.range.clipRows(e.firstRow,e.lastRow);if(!i.isEmpty())if(i=i.toScreenRange(this.session),r.renderer){var o=this.$getTop(i.start.row,e),a=this.$padding+i.start.column*e.characterWidth;r.renderer(t,i,a,o,e)}else"fullLine"==r.type?this.drawFullLineMarker(t,i,r.clazz,e):"screenLine"==r.type?this.drawScreenLineMarker(t,i,r.clazz,e):i.isMultiLine()?"text"==r.type?this.drawTextMarker(t,i,r.clazz,e):this.drawMultiLineMarker(t,i,r.clazz,e):this.drawSingleLineMarker(t,i,r.clazz+" ace_start ace_br15",e)}else r.update(t,this,this.session,e)}if(-1!=this.i)while(this.if,u==c),o,u==c?0:1,a)},this.drawMultiLineMarker=function(e,t,n,r,i){var o=this.$padding,a=r.lineHeight,s=this.$getTop(t.start.row,r),l=o+t.start.column*r.characterWidth;if(i=i||"",this.session.$bidiHandler.isBidiRow(t.start.row)){var c=t.clone();c.end.row=c.start.row,c.end.column=this.session.getLine(c.start.row).length,this.drawBidiSingleLineMarker(e,c,n+" ace_br1 ace_start",r,null,i)}else this.elt(n+" ace_br1 ace_start","height:"+a+"px;right:0;top:"+s+"px;left:"+l+"px;"+(i||""));if(this.session.$bidiHandler.isBidiRow(t.end.row)){c=t.clone();c.start.row=c.end.row,c.start.column=0,this.drawBidiSingleLineMarker(e,c,n+" ace_br12",r,null,i)}else{s=this.$getTop(t.end.row,r);var u=t.end.column*r.characterWidth;this.elt(n+" ace_br12","height:"+a+"px;width:"+u+"px;top:"+s+"px;left:"+o+"px;"+(i||""))}if(a=(t.end.row-t.start.row-1)*r.lineHeight,!(a<=0)){s=this.$getTop(t.start.row+1,r);var h=(t.start.column?1:0)|(t.end.column?0:8);this.elt(n+(h?" ace_br"+h:""),"height:"+a+"px;right:0;top:"+s+"px;left:"+o+"px;"+(i||""))}},this.drawSingleLineMarker=function(e,t,n,r,i,o){if(this.session.$bidiHandler.isBidiRow(t.start.row))return this.drawBidiSingleLineMarker(e,t,n,r,i,o);var a=r.lineHeight,s=(t.end.column+(i||0)-t.start.column)*r.characterWidth,l=this.$getTop(t.start.row,r),c=this.$padding+t.start.column*r.characterWidth;this.elt(n,"height:"+a+"px;width:"+s+"px;top:"+l+"px;left:"+c+"px;"+(o||""))},this.drawBidiSingleLineMarker=function(e,t,n,r,i,o){var a=r.lineHeight,s=this.$getTop(t.start.row,r),l=this.$padding,c=this.session.$bidiHandler.getSelections(t.start.column,t.end.column);c.forEach(function(e){this.elt(n,"height:"+a+"px;width:"+e.width+(i||0)+"px;top:"+s+"px;left:"+(l+e.left)+"px;"+(o||""))},this)},this.drawFullLineMarker=function(e,t,n,r,i){var o=this.$getTop(t.start.row,r),a=r.lineHeight;t.start.row!=t.end.row&&(a+=this.$getTop(t.end.row,r)-o),this.elt(n,"height:"+a+"px;top:"+o+"px;left:0;right:0;"+(i||""))},this.drawScreenLineMarker=function(e,t,n,r,i){var o=this.$getTop(t.start.row,r),a=r.lineHeight;this.elt(n,"height:"+a+"px;top:"+o+"px;left:0;right:0;"+(i||""))}}).call(o.prototype),t.Marker=o}),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/layer/lines","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/dom"),o=e("../lib/lang"),a=e("./lines").Lines,s=e("../lib/event_emitter").EventEmitter,l=function(e){this.dom=i,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new a(this.element)};(function(){r.implement(this,s),this.EOF_CHAR="\xb6",this.EOL_CHAR_LF="\xac",this.EOL_CHAR_CRLF="\xa4",this.EOL_CHAR=this.EOL_CHAR_LF,this.TAB_CHAR="\u2014",this.SPACE_CHAR="\xb7",this.$padding=0,this.MAX_LINE_LENGTH=1e4,this.$updateEolChar=function(){var e=this.session.doc,t="\n"==e.getNewLineCharacter()&&"windows"!=e.getNewLineMode(),n=t?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=n)return this.EOL_CHAR=n,!0},this.setPadding=function(e){this.$padding=e,this.element.style.margin="0 "+e+"px"},this.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},this.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},this.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},this.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},this.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},this.setSession=function(e){this.session=e,e&&this.$computeTabString()},this.showInvisibles=!1,this.showSpaces=!1,this.showTabs=!1,this.showEOL=!1,this.setShowInvisibles=function(e){return this.showInvisibles!=e&&(this.showInvisibles=e,"string"==typeof e?(this.showSpaces=/tab/i.test(e),this.showTabs=/space/i.test(e),this.showEOL=/eol/i.test(e)):this.showSpaces=this.showTabs=this.showEOL=e,this.$computeTabString(),!0)},this.displayIndentGuides=!0,this.setDisplayIndentGuides=function(e){return this.displayIndentGuides!=e&&(this.displayIndentGuides=e,this.$computeTabString(),!0)},this.$tabStrings=[],this.onChangeTabSize=this.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;for(var t=this.$tabStrings=[0],n=1;nu&&(s=l.end.row+1,l=this.session.getNextFoldLine(s,l),u=l?l.start.row:1/0),s>i)break;var h=o[a++];if(h){this.dom.removeChildren(h),this.$renderLine(h,s,s==u&&l),c&&(h.style.top=this.$lines.computeLineTop(s,e,this.session)+"px");var d=e.lineHeight*this.session.getRowLength(s)+"px";h.style.height!=d&&(c=!0,h.style.height=d)}s++}if(c)while(a0;i--)this.$lines.shift();if(t.lastRow>e.lastRow)for(i=this.session.getFoldedRowCount(e.lastRow+1,t.lastRow);i>0;i--)this.$lines.pop();e.firstRowt.lastRow&&this.$lines.push(this.$renderLinesFragment(e,t.lastRow+1,e.lastRow))},this.$renderLinesFragment=function(e,t,n){var r=[],o=t,a=this.session.getNextFoldLine(o),s=a?a.start.row:1/0;while(1){if(o>s&&(o=a.end.row+1,a=this.session.getNextFoldLine(o,a),s=a?a.start.row:1/0),o>n)break;var l=this.$lines.createCell(o,e,this.session),c=l.element;this.dom.removeChildren(c),i.setStyle(c.style,"height",this.$lines.computeLineHeight(o,e,this.session)+"px"),i.setStyle(c.style,"top",this.$lines.computeLineTop(o,e,this.session)+"px"),this.$renderLine(c,o,o==s&&a),this.$useLineGroups()?c.className="ace_line_group":c.className="ace_line",r.push(l),o++}return r},this.update=function(e){this.$lines.moveContainer(e),this.config=e;var t=e.firstRow,n=e.lastRow,r=this.$lines;while(r.getLength())r.pop();r.push(this.$renderLinesFragment(e,t,n))},this.$textToken={text:!0,rparen:!0,lparen:!0},this.$renderToken=function(e,t,n,r){var i,a=this,s=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,l=this.dom.createFragment(this.element),c=0;while(i=s.exec(r)){var u=i[1],h=i[2],d=i[3],f=i[4],p=i[5];if(a.showSpaces||!h){var m=c!=i.index?r.slice(c,i.index):"";if(c=i.index+i[0].length,m&&l.appendChild(this.dom.createTextNode(m,this.element)),u){var g=a.session.getScreenTabSize(t+i.index);l.appendChild(a.$tabStrings[g].cloneNode(!0)),t+=g-1}else if(h)if(a.showSpaces){var v=this.dom.createElement("span");v.className="ace_invisible ace_invisible_space",v.textContent=o.stringRepeat(a.SPACE_CHAR,h.length),l.appendChild(v)}else l.appendChild(this.com.createTextNode(h,this.element));else if(d){v=this.dom.createElement("span");v.className="ace_invisible ace_invisible_space ace_invalid",v.textContent=o.stringRepeat(a.SPACE_CHAR,d.length),l.appendChild(v)}else if(f){t+=1;v=this.dom.createElement("span");v.style.width=2*a.config.characterWidth+"px",v.className=a.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",v.textContent=a.showSpaces?a.SPACE_CHAR:f,l.appendChild(v)}else if(p){t+=1;v=this.dom.createElement("span");v.style.width=2*a.config.characterWidth+"px",v.className="ace_cjk",v.textContent=p,l.appendChild(v)}}}if(l.appendChild(this.dom.createTextNode(c?r.slice(c):r,this.element)),this.$textToken[n.type])e.appendChild(l);else{var y="ace_"+n.type.replace(/\./g," ace_");v=this.dom.createElement("span");"fold"==n.type&&(v.style.width=n.value.length*this.config.characterWidth+"px"),v.className=y,v.appendChild(l),e.appendChild(v)}return t+r.length},this.renderIndentGuide=function(e,t,n){var r=t.search(this.$indentGuideRe);if(r<=0||r>=n)return t;if(" "==t[0]){r-=r%this.tabSize;for(var i=r/this.tabSize,o=0;o=a)s=this.$renderToken(l,s,u,h.substring(0,a-r)),h=h.substring(a-r),r=a,l=this.$createLineElement(),e.appendChild(l),l.appendChild(this.dom.createTextNode(o.stringRepeat("\xa0",n.indent),this.element)),i++,s=0,a=n[i]||Number.MAX_VALUE;0!=h.length&&(r+=h.length,s=this.$renderToken(l,s,u,h))}}n[n.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(l,s,null,"",!0)},this.$renderSimpleLine=function(e,t){var n=0,r=t[0],i=r.value;this.displayIndentGuides&&(i=this.renderIndentGuide(e,i)),i&&(n=this.$renderToken(e,n,r,i));for(var o=1;othis.MAX_LINE_LENGTH)return this.$renderOverflowMessage(e,n,r,i);n=this.$renderToken(e,n,r,i)}},this.$renderOverflowMessage=function(e,t,n,r,i){n&&this.$renderToken(e,t,n,r.slice(0,this.MAX_LINE_LENGTH-t));var o=this.dom.createElement("span");o.className="ace_inline_button ace_keyword ace_toggle_wrap",o.textContent=i?"":"",e.appendChild(o)},this.$renderLine=function(e,t,n){if(n||0==n||(n=this.session.getFoldLine(t)),n)var r=this.$getFoldLineTokens(t,n);else r=this.session.getTokens(t);var i=e;if(r.length){var o=this.session.getRowSplitData(t);if(o&&o.length){this.$renderWrappedLine(e,r,o);i=e.lastChild}else{i=e;this.$useLineGroups()&&(i=this.$createLineElement(),e.appendChild(i)),this.$renderSimpleLine(i,r)}}else this.$useLineGroups()&&(i=this.$createLineElement(),e.appendChild(i));if(this.showEOL&&i){n&&(t=n.end.row);var a=this.dom.createElement("span");a.className="ace_invisible ace_invisible_eol",a.textContent=t==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,i.appendChild(a)}},this.$getFoldLineTokens=function(e,t){var n=this.session,r=[];function i(e,t,n){var i=0,o=0;while(o+e[i].value.lengthn-t&&(a=a.substring(0,n-t)),r.push({type:e[i].type,value:a}),o=t+a.length,i+=1}while(on?r.push({type:e[i].type,value:a.substring(0,n-o)}):r.push(e[i]),o+=a.length,i+=1}}var o=n.getTokens(e);return t.walk(function(e,t,a,s,l){null!=e?r.push({type:"fold",value:e}):(l&&(o=n.getTokens(t)),o.length&&i(o,s,a))},t.end.row,this.session.getLine(t.end.row).length),r},this.$useLineGroups=function(){return this.session.getUseWrapMode()},this.destroy=function(){}}).call(l.prototype),t.Text=l}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_cursor-layer",e.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),r.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)};(function(){this.$updateOpacity=function(e){for(var t=this.cursors,n=t.length;n--;)r.setStyle(t[n].style,"opacity",e?"":"0")},this.$startCssAnimation=function(){for(var e=this.cursors,t=e.length;t--;)e[t].style.animationDuration=this.blinkInterval+"ms";setTimeout(function(){r.addCssClass(this.element,"ace_animate-blinking")}.bind(this))},this.$stopCssAnimation=function(){r.removeCssClass(this.element,"ace_animate-blinking")},this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setBlinking=function(e){e!=this.isBlinking&&(this.isBlinking=e,this.restartTimer())},this.setBlinkInterval=function(e){e!=this.blinkInterval&&(this.blinkInterval=e,this.restartTimer())},this.setSmoothBlinking=function(e){e!=this.smoothBlinking&&(this.smoothBlinking=e,r.setCssClass(this.element,"ace_smooth-blinking",e),this.$updateCursors(!0),this.restartTimer())},this.addCursor=function(){var e=r.createElement("div");return e.className="ace_cursor",this.element.appendChild(e),this.cursors.push(e),e},this.removeCursor=function(){if(this.cursors.length>1){var e=this.cursors.pop();return e.parentNode.removeChild(e),e}},this.hideCursor=function(){this.isVisible=!1,r.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.showCursor=function(){this.isVisible=!0,r.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.restartTimer=function(){var e=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&r.removeCssClass(this.element,"ace_smooth-blinking"),e(!0),this.isBlinking&&this.blinkInterval&&this.isVisible)if(this.smoothBlinking&&setTimeout(function(){r.addCssClass(this.element,"ace_smooth-blinking")}.bind(this)),r.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var t=function(){this.timeoutId=setTimeout(function(){e(!1)},.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval(function(){e(!0),t()},this.blinkInterval),t()}else this.$stopCssAnimation()},this.getPixelPosition=function(e,t){if(!this.config||!this.session)return{left:0,top:0};e||(e=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(e),r=this.$padding+(this.session.$bidiHandler.isBidiRow(n.row,e.row)?this.session.$bidiHandler.getPosLeft(n.column):n.column*this.config.characterWidth),i=(n.row-(t?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:r,top:i}},this.isCursorInView=function(e,t){return e.top>=0&&e.tope.height+e.offset||a.top<0)&&n>1)){var s=this.cursors[i++]||this.addCursor(),l=s.style;this.drawCursor?this.drawCursor(s,a,e,t[n],this.session):this.isCursorInView(a,e)?(r.setStyle(l,"display","block"),r.translate(s,a.left,a.top),r.setStyle(l,"width",Math.round(e.characterWidth)+"px"),r.setStyle(l,"height",e.lineHeight+"px")):r.setStyle(l,"display","none")}}while(this.cursors.length>i)this.removeCursor();var c=this.session.getOverwrite();this.$setOverwrite(c),this.$pixelPos=a,this.restartTimer()},this.drawCursor=null,this.$setOverwrite=function(e){e!=this.overwrite&&(this.overwrite=e,e?r.addCssClass(this.element,"ace_overwrite-cursors"):r.removeCssClass(this.element,"ace_overwrite-cursors"))},this.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)}}).call(i.prototype),t.Cursor=i}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),o=e("./lib/event"),a=e("./lib/event_emitter").EventEmitter,s=32768,l=function(e){this.element=i.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+this.classSuffix,this.inner=i.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent="\xa0",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,o.addListener(this.element,"scroll",this.onScroll.bind(this)),o.addListener(this.element,"mousedown",o.preventDefault)};(function(){r.implement(this,a),this.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1}}).call(l.prototype);var c=function(e,t){l.call(this,e),this.scrollTop=0,this.scrollHeight=0,t.$scrollbarWidth=this.width=i.scrollbarWidth(e.ownerDocument),this.inner.style.width=this.element.style.width=(this.width||15)+5+"px",this.$minWidth=0};r.inherits(c,l),function(){this.classSuffix="-v",this.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,1!=this.coeff){var e=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-e)/(this.coeff-e)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},this.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},this.setHeight=function(e){this.element.style.height=e+"px"},this.setInnerHeight=this.setScrollHeight=function(e){this.scrollHeight=e,e>s?(this.coeff=s/e,e=s):1!=this.coeff&&(this.coeff=1),this.inner.style.height=e+"px"},this.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=e,this.element.scrollTop=e*this.coeff)}}.call(c.prototype);var u=function(e,t){l.call(this,e),this.scrollLeft=0,this.height=t.$scrollbarWidth,this.inner.style.height=this.element.style.height=(this.height||15)+5+"px"};r.inherits(u,l),function(){this.classSuffix="-h",this.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},this.getHeight=function(){return this.isVisible?this.height:0},this.setWidth=function(e){this.element.style.width=e+"px"},this.setInnerWidth=function(e){this.inner.style.width=e+"px"},this.setScrollWidth=function(e){this.inner.style.width=e+"px"},this.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)}}.call(u.prototype),t.ScrollBar=c,t.ScrollBarV=c,t.ScrollBarH=u,t.VScrollBar=c,t.HScrollBar=u}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(e,t,n){"use strict";var r=e("./lib/event"),i=function(e,t){this.onRender=e,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=t||window;var n=this;this._flush=function(e){n.pending=!1;var t=n.changes;if(t&&(r.blockIdle(100),n.changes=0,n.onRender(t)),n.changes){if(n.$recursionLimit--<0)return;n.schedule()}else n.$recursionLimit=2}};(function(){this.schedule=function(e){this.changes=this.changes|e,this.changes&&!this.pending&&(r.nextFrame(this._flush),this.pending=!0)},this.clear=function(e){var t=this.changes;return this.changes=0,t}}).call(i.prototype),t.RenderLoop=i}),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/lib/useragent","ace/lib/event_emitter"],function(e,t,n){var r=e("../lib/oop"),i=e("../lib/dom"),o=e("../lib/lang"),a=e("../lib/event"),s=e("../lib/useragent"),l=e("../lib/event_emitter").EventEmitter,c=256,u="function"==typeof ResizeObserver,h=200,d=t.FontMetrics=function(e){this.el=i.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=i.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=i.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),e.appendChild(this.el),this.$measureNode.textContent=o.stringRepeat("X",c),this.$characterSize={width:0,height:0},u?this.$addObserver():this.checkForSizeChanges()};(function(){r.implement(this,l),this.$characterSize={width:0,height:0},this.$setMeasureNodeStyles=function(e,t){e.width=e.height="auto",e.left=e.top="0px",e.visibility="hidden",e.position="absolute",e.whiteSpace="pre",s.isIE<8?e["font-family"]="inherit":e.font="inherit",e.overflow=t?"hidden":"visible"},this.checkForSizeChanges=function(e){if(void 0===e&&(e=this.$measureSizes()),e&&(this.$characterSize.width!==e.width||this.$characterSize.height!==e.height)){this.$measureNode.style.fontWeight="bold";var t=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=e,this.charSizes=Object.create(null),this.allowBoldFonts=t&&t.width===e.width&&t.height===e.height,this._emit("changeCharacterSize",{data:e})}},this.$addObserver=function(){var e=this;this.$observer=new window.ResizeObserver(function(t){e.checkForSizeChanges()}),this.$observer.observe(this.$measureNode)},this.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var e=this;return this.$pollSizeChangesTimer=a.onIdle(function t(){e.checkForSizeChanges(),a.onIdle(t,500)},500)},this.setPolling=function(e){e?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},this.$measureSizes=function(e){var t={height:(e||this.$measureNode).clientHeight,width:(e||this.$measureNode).clientWidth/c};return 0===t.width||0===t.height?null:t},this.$measureCharWidth=function(e){this.$main.textContent=o.stringRepeat(e,c);var t=this.$main.getBoundingClientRect();return t.width/c},this.getCharacterWidth=function(e){var t=this.charSizes[e];return void 0===t&&(t=this.charSizes[e]=this.$measureCharWidth(e)/this.$characterSize.width),t},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},this.$getZoom=function e(t){return t&&t.parentElement?(window.getComputedStyle(t).zoom||1)*e(t.parentElement):1},this.$initTransformMeasureNodes=function(){var e=function(e,t){return["div",{style:"position: absolute;top:"+e+"px;left:"+t+"px;"}]};this.els=i.buildDom([e(0,0),e(h,0),e(0,h),e(h,h)],this.el)},this.transformCoordinates=function(e,t){if(e){var n=this.$getZoom(this.el);e=a(1/n,e)}function r(e,t,n){var r=e[1]*t[0]-e[0]*t[1];return[(-t[1]*n[0]+t[0]*n[1])/r,(+e[1]*n[0]-e[0]*n[1])/r]}function i(e,t){return[e[0]-t[0],e[1]-t[1]]}function o(e,t){return[e[0]+t[0],e[1]+t[1]]}function a(e,t){return[e*t[0],e*t[1]]}function s(e){var t=e.getBoundingClientRect();return[t.left,t.top]}this.els||this.$initTransformMeasureNodes();var l=s(this.els[0]),c=s(this.els[1]),u=s(this.els[2]),d=s(this.els[3]),f=r(i(d,c),i(d,u),i(o(c,u),o(d,l))),p=a(1+f[0],i(c,l)),m=a(1+f[1],i(u,l));if(t){var g=t,v=f[0]*g[0]/h+f[1]*g[1]/h+1,y=o(a(g[0],p),a(g[1],m));return o(a(1/v/h,y),l)}var b=i(e,l),w=r(i(p,a(f[0],b)),i(m,a(f[1],b)),b);return a(h,w)}}).call(d.prototype)}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),o=e("./config"),a=e("./layer/gutter").Gutter,s=e("./layer/marker").Marker,l=e("./layer/text").Text,c=e("./layer/cursor").Cursor,u=e("./scrollbar").HScrollBar,h=e("./scrollbar").VScrollBar,d=e("./renderloop").RenderLoop,f=e("./layer/font_metrics").FontMetrics,p=e("./lib/event_emitter").EventEmitter,m='.ace_br1 {border-top-left-radius : 3px;}.ace_br2 {border-top-right-radius : 3px;}.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}.ace_br4 {border-bottom-right-radius: 3px;}.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}.ace_br8 {border-bottom-left-radius : 3px;}.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}.ace_editor {position: relative;overflow: hidden;padding: 0;font: 12px/normal \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'source-code-pro\', monospace;direction: ltr;text-align: left;-webkit-tap-highlight-color: rgba(0, 0, 0, 0);}.ace_scroller {position: absolute;overflow: hidden;top: 0;bottom: 0;background-color: inherit;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;cursor: text;}.ace_content {position: absolute;box-sizing: border-box;min-width: 100%;contain: style size layout;font-variant-ligatures: no-common-ligatures;}.ace_dragging .ace_scroller:before{position: absolute;top: 0;left: 0;right: 0;bottom: 0;content: \'\';background: rgba(250, 250, 250, 0.01);z-index: 1000;}.ace_dragging.ace_dark .ace_scroller:before{background: rgba(0, 0, 0, 0.01);}.ace_selecting, .ace_selecting * {cursor: text !important;}.ace_gutter {position: absolute;overflow : hidden;width: auto;top: 0;bottom: 0;left: 0;cursor: default;z-index: 4;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;contain: style size layout;}.ace_gutter-active-line {position: absolute;left: 0;right: 0;}.ace_scroller.ace_scroll-left {box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;}.ace_gutter-cell {position: absolute;top: 0;left: 0;right: 0;padding-left: 19px;padding-right: 6px;background-repeat: no-repeat;}.ace_gutter-cell.ace_error {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: 2px center;}.ace_gutter-cell.ace_warning {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");background-position: 2px center;}.ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");background-position: 2px center;}.ace_dark .ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");}.ace_scrollbar {contain: strict;position: absolute;right: 0;bottom: 0;z-index: 6;}.ace_scrollbar-inner {position: absolute;cursor: text;left: 0;top: 0;}.ace_scrollbar-v{overflow-x: hidden;overflow-y: scroll;top: 0;}.ace_scrollbar-h {overflow-x: scroll;overflow-y: hidden;left: 0;}.ace_print-margin {position: absolute;height: 100%;}.ace_text-input {position: absolute;z-index: 0;width: 0.5em;height: 1em;opacity: 0;background: transparent;-moz-appearance: none;appearance: none;border: none;resize: none;outline: none;overflow: hidden;font: inherit;padding: 0 1px;margin: 0 -1px;contain: strict;-ms-user-select: text;-moz-user-select: text;-webkit-user-select: text;user-select: text;white-space: pre!important;}.ace_text-input.ace_composition {background: transparent;color: inherit;z-index: 1000;opacity: 1;}.ace_composition_placeholder { color: transparent }.ace_composition_marker { border-bottom: 1px solid;position: absolute;border-radius: 0;margin-top: 1px;}[ace_nocontext=true] {transform: none!important;filter: none!important;clip-path: none!important;mask : none!important;contain: none!important;perspective: none!important;mix-blend-mode: initial!important;z-index: auto;}.ace_layer {z-index: 1;position: absolute;overflow: hidden;word-wrap: normal;white-space: pre;height: 100%;width: 100%;box-sizing: border-box;pointer-events: none;}.ace_gutter-layer {position: relative;width: auto;text-align: right;pointer-events: auto;height: 1000000px;contain: style size layout;}.ace_text-layer {font: inherit !important;position: absolute;height: 1000000px;width: 1000000px;contain: style size layout;}.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {contain: style size layout;position: absolute;top: 0;left: 0;right: 0;}.ace_hidpi .ace_text-layer,.ace_hidpi .ace_gutter-layer,.ace_hidpi .ace_content,.ace_hidpi .ace_gutter {contain: strict;will-change: transform;}.ace_hidpi .ace_text-layer > .ace_line, .ace_hidpi .ace_text-layer > .ace_line_group {contain: strict;}.ace_cjk {display: inline-block;text-align: center;}.ace_cursor-layer {z-index: 4;}.ace_cursor {z-index: 4;position: absolute;box-sizing: border-box;border-left: 2px solid;transform: translatez(0);}.ace_multiselect .ace_cursor {border-left-width: 1px;}.ace_slim-cursors .ace_cursor {border-left-width: 1px;}.ace_overwrite-cursors .ace_cursor {border-left-width: 0;border-bottom: 1px solid;}.ace_hidden-cursors .ace_cursor {opacity: 0.2;}.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {opacity: 0;}.ace_smooth-blinking .ace_cursor {transition: opacity 0.18s;}.ace_animate-blinking .ace_cursor {animation-duration: 1000ms;animation-timing-function: step-end;animation-name: blink-ace-animate;animation-iteration-count: infinite;}.ace_animate-blinking.ace_smooth-blinking .ace_cursor {animation-duration: 1000ms;animation-timing-function: ease-in-out;animation-name: blink-ace-animate-smooth;}@keyframes blink-ace-animate {from, to { opacity: 1; }60% { opacity: 0; }}@keyframes blink-ace-animate-smooth {from, to { opacity: 1; }45% { opacity: 1; }60% { opacity: 0; }85% { opacity: 0; }}.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {position: absolute;z-index: 3;}.ace_marker-layer .ace_selection {position: absolute;z-index: 5;}.ace_marker-layer .ace_bracket {position: absolute;z-index: 6;}.ace_marker-layer .ace_error_bracket {position: absolute;border-bottom: 1px solid #DE5555;border-radius: 0;}.ace_marker-layer .ace_active-line {position: absolute;z-index: 2;}.ace_marker-layer .ace_selected-word {position: absolute;z-index: 4;box-sizing: border-box;}.ace_line .ace_fold {box-sizing: border-box;display: inline-block;height: 11px;margin-top: -2px;vertical-align: middle;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");background-repeat: no-repeat, repeat-x;background-position: center center, top left;color: transparent;border: 1px solid black;border-radius: 2px;cursor: pointer;pointer-events: auto;}.ace_dark .ace_fold {}.ace_fold:hover{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");}.ace_tooltip {background-color: #FFF;background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));border: 1px solid gray;border-radius: 1px;box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);color: black;max-width: 100%;padding: 3px 4px;position: fixed;z-index: 999999;box-sizing: border-box;cursor: default;white-space: pre;word-wrap: break-word;line-height: normal;font-style: normal;font-weight: normal;letter-spacing: normal;pointer-events: none;}.ace_folding-enabled > .ace_gutter-cell {padding-right: 13px;}.ace_fold-widget {box-sizing: border-box;margin: 0 -12px 0 1px;display: none;width: 11px;vertical-align: top;background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: center;border-radius: 3px;border: 1px solid transparent;cursor: pointer;}.ace_folding-enabled .ace_fold-widget {display: inline-block; }.ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");}.ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");}.ace_fold-widget:hover {border: 1px solid rgba(0, 0, 0, 0.3);background-color: rgba(255, 255, 255, 0.2);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);}.ace_fold-widget:active {border: 1px solid rgba(0, 0, 0, 0.4);background-color: rgba(0, 0, 0, 0.05);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);}.ace_dark .ace_fold-widget {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");}.ace_dark .ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget:hover {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);background-color: rgba(255, 255, 255, 0.1);}.ace_dark .ace_fold-widget:active {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);}.ace_inline_button {border: 1px solid lightgray;display: inline-block;margin: -1px 8px;padding: 0 5px;pointer-events: auto;cursor: pointer;}.ace_inline_button:hover {border-color: gray;background: rgba(200,200,200,0.2);display: inline-block;pointer-events: auto;}.ace_fold-widget.ace_invalid {background-color: #FFB4B4;border-color: #DE5555;}.ace_fade-fold-widgets .ace_fold-widget {transition: opacity 0.4s ease 0.05s;opacity: 0;}.ace_fade-fold-widgets:hover .ace_fold-widget {transition: opacity 0.05s ease 0.05s;opacity:1;}.ace_underline {text-decoration: underline;}.ace_bold {font-weight: bold;}.ace_nobold .ace_bold {font-weight: normal;}.ace_italic {font-style: italic;}.ace_error-marker {background-color: rgba(255, 0, 0,0.2);position: absolute;z-index: 9;}.ace_highlight-marker {background-color: rgba(255, 255, 0,0.2);position: absolute;z-index: 8;}.ace_mobile-menu {position: absolute;line-height: 1.5;border-radius: 4px;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;background: white;box-shadow: 1px 3px 2px grey;border: 1px solid #dcdcdc;color: black;}.ace_dark > .ace_mobile-menu {background: #333;color: #ccc;box-shadow: 1px 3px 2px grey;border: 1px solid #444;}.ace_mobile-button {padding: 2px;cursor: pointer;overflow: hidden;}.ace_mobile-button:hover {background-color: #eee;opacity:1;}.ace_mobile-button:active {background-color: #ddd;}.ace_placeholder {font-family: arial;transform: scale(0.9);transform-origin: left;white-space: pre;opacity: 0.7;margin: 0 10px;}',g=e("./lib/useragent"),v=g.isIE;i.importCssString(m,"ace_editor.css");var y=function(e,t){var n=this;this.container=e||i.createElement("div"),i.addCssClass(this.container,"ace_editor"),i.HI_DPI&&i.addCssClass(this.container,"ace_hidpi"),this.setTheme(t),this.$gutter=i.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden",!0),this.scroller=i.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=i.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new a(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new s(this.content);var r=this.$textLayer=new l(this.content);this.canvas=r.element,this.$markerFront=new s(this.content),this.$cursorLayer=new c(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new h(this.container,this),this.scrollBarH=new u(this.container,this),this.scrollBarV.on("scroll",function(e){n.$scrollAnimation||n.session.setScrollTop(e.data-n.scrollMargin.top)}),this.scrollBarH.on("scroll",function(e){n.$scrollAnimation||n.session.setScrollLeft(e.data-n.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new f(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",function(e){n.updateCharacterSize(),n.onResize(!0,n.gutterWidth,n.$size.width,n.$size.height),n._signal("changeCharacterSize",e)}),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.margin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$keepTextAreaAtCursor=!g.isIOS,this.$loop=new d(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),o.resetOptions(this),o._signal("renderer",this)};(function(){this.CHANGE_CURSOR=1,this.CHANGE_MARKER=2,this.CHANGE_GUTTER=4,this.CHANGE_SCROLL=8,this.CHANGE_LINES=16,this.CHANGE_TEXT=32,this.CHANGE_SIZE=64,this.CHANGE_MARKER_BACK=128,this.CHANGE_MARKER_FRONT=256,this.CHANGE_FULL=512,this.CHANGE_H_SCROLL=1024,r.implement(this,p),this.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin(),i.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},this.setSession=function(e){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=e,e&&this.scrollMargin.top&&e.getScrollTop()<=0&&e.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(e),this.$markerBack.setSession(e),this.$markerFront.setSession(e),this.$gutterLayer.setSession(e),this.$textLayer.setSession(e),e&&(this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode))},this.updateLines=function(e,t,n){if(void 0===t&&(t=1/0),this.$changedLines?(this.$changedLines.firstRow>e&&(this.$changedLines.firstRow=e),this.$changedLines.lastRowthis.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},this.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},this.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},this.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},this.updateFull=function(e){e?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},this.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},this.$changes=0,this.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},this.onResize=function(e,t,n,r){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=e?1:0;var i=this.container;r||(r=i.clientHeight||i.scrollHeight),n||(n=i.clientWidth||i.scrollWidth);var o=this.$updateCachedSize(e,t,n,r);if(!this.$size.scrollerHeight||!n&&!r)return this.resizing=0;e&&(this.$gutterLayer.$padding=null),e?this.$renderChanges(o|this.$changes,!0):this.$loop.schedule(o|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarV.scrollLeft=this.scrollBarV.scrollTop=null}},this.$updateCachedSize=function(e,t,n,r){r-=this.$extraHeight||0;var o=0,a=this.$size,s={width:a.width,height:a.height,scrollerHeight:a.scrollerHeight,scrollerWidth:a.scrollerWidth};if(r&&(e||a.height!=r)&&(a.height=r,o|=this.CHANGE_SIZE,a.scrollerHeight=a.height,this.$horizScroll&&(a.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",o|=this.CHANGE_SCROLL),n&&(e||a.width!=n)){o|=this.CHANGE_SIZE,a.width=n,null==t&&(t=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=t,i.setStyle(this.scrollBarH.element.style,"left",t+"px"),i.setStyle(this.scroller.style,"left",t+this.margin.left+"px"),a.scrollerWidth=Math.max(0,n-t-this.scrollBarV.getWidth()-this.margin.h),i.setStyle(this.$gutter.style,"left",this.margin.left+"px");var l=this.scrollBarV.getWidth()+"px";i.setStyle(this.scrollBarH.element.style,"right",l),i.setStyle(this.scroller.style,"right",l),i.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||e)&&(o|=this.CHANGE_FULL)}return a.$dirty=!n||!r,o&&this._signal("resize",s),o},this.onGutterResize=function(e){var t=this.$showGutter?e:0;t!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,t,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},this.adjustWrapLimit=function(){var e=this.$size.scrollerWidth-2*this.$padding,t=Math.floor(e/this.characterWidth);return this.session.adjustWrapLimit(t,this.$showPrintMargin&&this.$printMarginColumn)},this.setAnimatedScroll=function(e){this.setOption("animatedScroll",e)},this.getAnimatedScroll=function(){return this.$animatedScroll},this.setShowInvisibles=function(e){this.setOption("showInvisibles",e),this.session.$bidiHandler.setShowInvisibles(e)},this.getShowInvisibles=function(){return this.getOption("showInvisibles")},this.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},this.setDisplayIndentGuides=function(e){this.setOption("displayIndentGuides",e)},this.setShowPrintMargin=function(e){this.setOption("showPrintMargin",e)},this.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},this.setPrintMarginColumn=function(e){this.setOption("printMarginColumn",e)},this.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},this.getShowGutter=function(){return this.getOption("showGutter")},this.setShowGutter=function(e){return this.setOption("showGutter",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.$updatePrintMargin=function(){if(this.$showPrintMargin||this.$printMarginEl){if(!this.$printMarginEl){var e=i.createElement("div");e.className="ace_layer ace_print-margin-layer",this.$printMarginEl=i.createElement("div"),this.$printMarginEl.className="ace_print-margin",e.appendChild(this.$printMarginEl),this.content.insertBefore(e,this.content.firstChild)}var t=this.$printMarginEl.style;t.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",t.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&-1==this.session.$wrap&&this.adjustWrapLimit()}},this.getContainerElement=function(){return this.container},this.getMouseEventTarget=function(){return this.scroller},this.getTextAreaContainer=function(){return this.container},this.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var e=this.textarea.style,t=this.$composition;if(this.$keepTextAreaAtCursor||t){var n=this.$cursorLayer.$pixelPos;if(n){t&&t.markerRange&&(n=this.$cursorLayer.getPixelPosition(t.markerRange.start,!0));var r=this.layerConfig,o=n.top,a=n.left;o-=r.offset;var s=t&&t.useTextareaForIME?this.lineHeight:v?0:1;if(o<0||o>r.height-s)i.translate(this.textarea,0,0);else{var l=1,c=this.$size.height-s;if(t)if(t.useTextareaForIME){var u=this.textarea.value;l=this.characterWidth*this.session.$getStringScreenWidth(u)[0]}else o+=this.lineHeight+2;else o+=this.lineHeight;a-=this.scrollLeft,a>this.$size.scrollerWidth-l&&(a=this.$size.scrollerWidth-l),a+=this.gutterWidth+this.margin.left,i.setStyle(e,"height",s+"px"),i.setStyle(e,"width",l+"px"),i.translate(this.textarea,Math.min(a,this.$size.scrollerWidth-l),Math.min(o,c))}}}else i.translate(this.textarea,-100,0)}},this.getFirstVisibleRow=function(){return this.layerConfig.firstRow},this.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(0===this.layerConfig.offset?0:1)},this.getLastFullyVisibleRow=function(){var e=this.layerConfig,t=e.lastRow,n=this.session.documentToScreenRow(t,0)*e.lineHeight;return n-this.session.getScrollTop()>e.height-e.lineHeight?t-1:t},this.getLastVisibleRow=function(){return this.layerConfig.lastRow},this.$padding=null,this.setPadding=function(e){this.$padding=e,this.$textLayer.setPadding(e),this.$cursorLayer.setPadding(e),this.$markerFront.setPadding(e),this.$markerBack.setPadding(e),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},this.setScrollMargin=function(e,t,n,r){var i=this.scrollMargin;i.top=0|e,i.bottom=0|t,i.right=0|r,i.left=0|n,i.v=i.top+i.bottom,i.h=i.left+i.right,i.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-i.top),this.updateFull()},this.setMargin=function(e,t,n,r){var i=this.margin;i.top=0|e,i.bottom=0|t,i.right=0|r,i.left=0|n,i.v=i.top+i.bottom,i.h=i.left+i.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},this.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setHScrollBarAlwaysVisible=function(e){this.setOption("hScrollBarAlwaysVisible",e)},this.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},this.setVScrollBarAlwaysVisible=function(e){this.setOption("vScrollBarAlwaysVisible",e)},this.$updateScrollBarV=function(){var e=this.layerConfig.maxHeight,t=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(e-=(t-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>e-t&&(e=this.scrollTop+t,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(e+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},this.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},this.$frozen=!1,this.freeze=function(){this.$frozen=!0},this.unfreeze=function(){this.$frozen=!1},this.$renderChanges=function(e,t){if(this.$changes&&(e|=this.$changes,this.$changes=0),this.session&&this.container.offsetWidth&&!this.$frozen&&(e||t)){if(this.$size.$dirty)return this.$changes|=e,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",e),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var n=this.layerConfig;if(e&this.CHANGE_FULL||e&this.CHANGE_SIZE||e&this.CHANGE_TEXT||e&this.CHANGE_LINES||e&this.CHANGE_SCROLL||e&this.CHANGE_H_SCROLL){if(e|=this.$computeLayerConfig()|this.$loop.clear(),n.firstRow!=this.layerConfig.firstRow&&n.firstRowScreen==this.layerConfig.firstRowScreen){var r=this.scrollTop+(n.firstRow-this.layerConfig.firstRow)*this.lineHeight;r>0&&(this.scrollTop=r,e|=this.CHANGE_SCROLL,e|=this.$computeLayerConfig()|this.$loop.clear())}n=this.layerConfig,this.$updateScrollBarV(),e&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),i.translate(this.content,-this.scrollLeft,-n.offset);var o=n.width+2*this.$padding+"px",a=n.minHeight+"px";i.setStyle(this.content.style,"width",o),i.setStyle(this.content.style,"height",a)}if(e&this.CHANGE_H_SCROLL&&(i.translate(this.content,-this.scrollLeft,-n.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller":"ace_scroller ace_scroll-left"),e&this.CHANGE_FULL)return this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),void this._signal("afterRender",e);if(e&this.CHANGE_SCROLL)return this.$changedLines=null,e&this.CHANGE_TEXT||e&this.CHANGE_LINES?this.$textLayer.update(n):this.$textLayer.scrollLines(n),this.$showGutter&&(e&this.CHANGE_GUTTER||e&this.CHANGE_LINES?this.$gutterLayer.update(n):this.$gutterLayer.scrollLines(n)),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),void this._signal("afterRender",e);e&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n)):e&this.CHANGE_LINES?(this.$updateLines()||e&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(n):e&this.CHANGE_TEXT||e&this.CHANGE_GUTTER?this.$showGutter&&this.$gutterLayer.update(n):e&this.CHANGE_CURSOR&&this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(n),e&this.CHANGE_CURSOR&&(this.$cursorLayer.update(n),this.$moveTextAreaToCursor()),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(n),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(n),this._signal("afterRender",e)}else this.$changes|=e},this.$autosize=function(){var e=this.session.getScreenLength()*this.lineHeight,t=this.$maxLines*this.lineHeight,n=Math.min(t,Math.max((this.$minLines||1)*this.lineHeight,e))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(n+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&n>this.$maxPixelHeight&&(n=this.$maxPixelHeight);var r=n<=2*this.lineHeight,i=!r&&e>t;if(n!=this.desiredHeight||this.$size.height!=this.desiredHeight||i!=this.$vScroll){i!=this.$vScroll&&(this.$vScroll=i,this.scrollBarV.setVisible(i));var o=this.container.clientWidth;this.container.style.height=n+"px",this.$updateCachedSize(!0,this.$gutterWidth,o,n),this.desiredHeight=n,this._signal("autosize")}},this.$computeLayerConfig=function(){var e=this.session,t=this.$size,n=t.height<=2*this.lineHeight,r=this.session.getScreenLength(),i=r*this.lineHeight,o=this.$getLongestLine(),a=!n&&(this.$hScrollBarAlwaysVisible||t.scrollerWidth-o-2*this.$padding<0),s=this.$horizScroll!==a;s&&(this.$horizScroll=a,this.scrollBarH.setVisible(a));var l=this.$vScroll;this.$maxLines&&this.lineHeight>1&&this.$autosize();var c=t.scrollerHeight+this.lineHeight,u=!this.$maxLines&&this.$scrollPastEnd?(t.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;i+=u;var h=this.scrollMargin;this.session.setScrollTop(Math.max(-h.top,Math.min(this.scrollTop,i-t.scrollerHeight+h.bottom))),this.session.setScrollLeft(Math.max(-h.left,Math.min(this.scrollLeft,o+2*this.$padding-t.scrollerWidth+h.right)));var d=!n&&(this.$vScrollBarAlwaysVisible||t.scrollerHeight-i+u<0||this.scrollTop>h.top),f=l!==d;f&&(this.$vScroll=d,this.scrollBarV.setVisible(d));var p,m,g=this.scrollTop%this.lineHeight,v=Math.ceil(c/this.lineHeight)-1,y=Math.max(0,Math.round((this.scrollTop-g)/this.lineHeight)),b=y+v,w=this.lineHeight;y=e.screenToDocumentRow(y,0);var x=e.getFoldLine(y);x&&(y=x.start.row),p=e.documentToScreenRow(y,0),m=e.getRowLength(y)*w,b=Math.min(e.screenToDocumentRow(b,0),e.getLength()-1),c=t.scrollerHeight+e.getRowLength(b)*w+m,g=this.scrollTop-p*w;var E=0;return(this.layerConfig.width!=o||s)&&(E=this.CHANGE_H_SCROLL),(s||f)&&(E|=this.$updateCachedSize(!0,this.gutterWidth,t.width,t.height),this._signal("scrollbarVisibilityChanged"),f&&(o=this.$getLongestLine())),this.layerConfig={width:o,padding:this.$padding,firstRow:y,firstRowScreen:p,lastRow:b,lineHeight:w,characterWidth:this.characterWidth,minHeight:c,maxHeight:i,offset:g,gutterOffset:w?Math.max(0,Math.ceil((g+t.height-t.scrollerHeight)/w)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(o-this.$padding),E},this.$updateLines=function(){if(this.$changedLines){var e=this.$changedLines.firstRow,t=this.$changedLines.lastRow;this.$changedLines=null;var n=this.layerConfig;if(!(e>n.lastRow+1)&&!(tthis.$textLayer.MAX_LINE_LENGTH&&(e=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(e*this.characterWidth))},this.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},this.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},this.addGutterDecoration=function(e,t){this.$gutterLayer.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){this.$gutterLayer.removeGutterDecoration(e,t)},this.updateBreakpoints=function(e){this.$loop.schedule(this.CHANGE_GUTTER)},this.setAnnotations=function(e){this.$gutterLayer.setAnnotations(e),this.$loop.schedule(this.CHANGE_GUTTER)},this.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},this.hideCursor=function(){this.$cursorLayer.hideCursor()},this.showCursor=function(){this.$cursorLayer.showCursor()},this.scrollSelectionIntoView=function(e,t,n){this.scrollCursorIntoView(e,n),this.scrollCursorIntoView(t,n)},this.scrollCursorIntoView=function(e,t,n){if(0!==this.$size.scrollerHeight){var r=this.$cursorLayer.getPixelPosition(e),i=r.left,o=r.top,a=n&&n.top||0,s=n&&n.bottom||0,l=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;l+a>o?(t&&l+a>o+this.lineHeight&&(o-=t*this.$size.scrollerHeight),0===o&&(o=-this.scrollMargin.top),this.session.setScrollTop(o)):l+this.$size.scrollerHeight-si?(i=1-this.scrollMargin.top||(t>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||(e<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||(e>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right||void 0)))},this.pixelToScreenCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var r=this.$fontMetrics.transformCoordinates([e,t]);e=r[1]-this.gutterWidth-this.margin.left,t=r[0]}else n=this.scroller.getBoundingClientRect();var i=e+this.scrollLeft-n.left-this.$padding,o=i/this.characterWidth,a=Math.floor((t+this.scrollTop-n.top)/this.lineHeight),s=this.$blockCursor?Math.floor(o):Math.round(o);return{row:a,column:s,side:o-s>0?1:-1,offsetX:i}},this.screenToTextCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var r=this.$fontMetrics.transformCoordinates([e,t]);e=r[1]-this.gutterWidth-this.margin.left,t=r[0]}else n=this.scroller.getBoundingClientRect();var i=e+this.scrollLeft-n.left-this.$padding,o=i/this.characterWidth,a=this.$blockCursor?Math.floor(o):Math.round(o),s=Math.floor((t+this.scrollTop-n.top)/this.lineHeight);return this.session.screenToDocumentPosition(s,Math.max(a,0),i)},this.textToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=this.session.documentToScreenPosition(e,t),i=this.$padding+(this.session.$bidiHandler.isBidiRow(r.row,e)?this.session.$bidiHandler.getPosLeft(r.column):Math.round(r.column*this.characterWidth)),o=r.row*this.lineHeight;return{pageX:n.left+i-this.scrollLeft,pageY:n.top+o-this.scrollTop}},this.visualizeFocus=function(){i.addCssClass(this.container,"ace_focus")},this.visualizeBlur=function(){i.removeCssClass(this.container,"ace_focus")},this.showComposition=function(e){this.$composition=e,e.cssText||(e.cssText=this.textarea.style.cssText),void 0==e.useTextareaForIME&&(e.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(i.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):e.markerId=this.session.addMarker(e.markerRange,"ace_composition_marker","text")},this.setCompositionText=function(e){var t=this.session.selection.cursor;this.addToken(e,"composition_placeholder",t.row,t.column),this.$moveTextAreaToCursor()},this.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),i.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var e=this.session.selection.cursor;this.removeExtraToken(e.row,e.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},this.addToken=function(e,t,n,r){var i=this.session;i.bgTokenizer.lines[n]=null;var o={type:t,value:e},a=i.getTokens(n);if(null==r)a.push(o);else for(var s=0,l=0;l50&&e.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:e}))}}).call(c.prototype);var u=function(e,t,n){var r=null,i=!1,s=Object.create(o),l=[],u=new c({messageBuffer:l,terminate:function(){},postMessage:function(e){l.push(e),r&&(i?setTimeout(h):h())}});u.setEmitSync=function(e){i=e};var h=function(){var e=l.shift();e.command?r[e.command].apply(r,e.args):e.event&&s._signal(e.event,e.data)};return s.postMessage=function(e){u.onMessage({data:e})},s.callback=function(e,t){this.postMessage({type:"call",id:t,data:e})},s.emit=function(e,t){this.postMessage({type:"event",name:e,data:t})},a.loadModule(["worker",t],function(e){r=new e[n](s);while(l.length)h()}),u};t.UIWorkerClient=u,t.WorkerClient=c,t.createWorker=l}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./range").Range,i=e("./lib/event_emitter").EventEmitter,o=e("./lib/oop"),a=function(e,t,n,r,i,o){var a=this;this.length=t,this.session=e,this.doc=e.getDocument(),this.mainClass=i,this.othersClass=o,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate),this.$others=r,this.$onCursorChange=function(){setTimeout(function(){a.onCursorChange()})},this.$pos=n;var s=e.getUndoManager().$undoStack||e.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=s.length,this.setup(),e.selection.on("changeCursor",this.$onCursorChange)};(function(){o.implement(this,i),this.setup=function(){var e=this,t=this.doc,n=this.session;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=t.createAnchor(this.$pos.row,this.$pos.column);var i=this.pos;i.$insertRight=!0,i.detach(),i.markerId=n.addMarker(new r(i.row,i.column,i.row,i.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach(function(n){var r=t.createAnchor(n.row,n.column);r.$insertRight=!0,r.detach(),e.others.push(r)}),n.setUndoSelect(!1)},this.showOtherMarkers=function(){if(!this.othersActive){var e=this.session,t=this;this.othersActive=!0,this.others.forEach(function(n){n.markerId=e.addMarker(new r(n.row,n.column,n.row,n.column+t.length),t.othersClass,null,!1)})}},this.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var e=0;e=this.pos.column&&t.start.column<=this.pos.column+this.length+1,o=t.start.column-this.pos.column;if(this.updateAnchors(e),i&&(this.length+=n),i&&!this.session.$fromUndo)if("insert"===e.action)for(var a=this.others.length-1;a>=0;a--){var s=this.others[a],l={row:s.row,column:s.column+o};this.doc.insertMergedLines(l,e.lines)}else if("remove"===e.action)for(a=this.others.length-1;a>=0;a--){s=this.others[a],l={row:s.row,column:s.column+o};this.doc.remove(new r(l.row,l.column,l.row,l.column-n))}this.$updating=!1,this.updateMarkers()}},this.updateAnchors=function(e){this.pos.onChange(e);for(var t=this.others.length;t--;)this.others[t].onChange(e);this.updateMarkers()},this.updateMarkers=function(){if(!this.$updating){var e=this,t=this.session,n=function(n,i){t.removeMarker(n.markerId),n.markerId=t.addMarker(new r(n.row,n.column,n.row,n.column+e.length),i,null,!1)};n(this.pos,this.mainClass);for(var i=this.others.length;i--;)n(this.others[i],this.othersClass)}},this.onCursorChange=function(e){if(!this.$updating&&this.session){var t=this.session.selection.getCursor();t.row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",e)):(this.hideOtherMarkers(),this._emit("cursorLeave",e))}},this.detach=function(){this.session.removeMarker(this.pos&&this.pos.markerId),this.hideOtherMarkers(),this.doc.off("change",this.$onUpdate),this.session.selection.off("changeCursor",this.$onCursorChange),this.session.setUndoSelect(!0),this.session=null},this.cancel=function(){if(-1!==this.$undoStackDepth){for(var e=this.session.getUndoManager(),t=(e.$undoStack||e.$undostack).length-this.$undoStackDepth,n=0;n1?e.multiSelect.joinSelections():e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(e){e.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],t.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];var r=e("../keyboard/hash_handler").HashHandler;t.keyboardHandler=new r(t.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(e,t,n){var r=e("./range_list").RangeList,i=e("./range").Range,o=e("./selection").Selection,a=e("./mouse/multi_select_handler").onMouseDown,s=e("./lib/event"),l=e("./lib/lang"),c=e("./commands/multi_select_commands");t.commands=c.defaultCommands.concat(c.multiSelectCommands);var u=e("./search").Search,h=new u;function d(e,t,n){return h.$options.wrap=!0,h.$options.needle=t,h.$options.backwards=-1==n,h.find(e)}var f=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(f.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(e,t){if(e){if(!this.inMultiSelectMode&&0===this.rangeCount){var n=this.toOrientedRange();if(this.rangeList.add(n),this.rangeList.add(e),2!=this.rangeList.ranges.length)return this.rangeList.removeAll(),t||this.fromOrientedRange(e);this.rangeList.removeAll(),this.rangeList.add(n),this.$onAddRange(n)}e.cursor||(e.cursor=e.end);var r=this.rangeList.add(e);return this.$onAddRange(e),r.length&&this.$onRemoveRange(r),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),t||this.fromOrientedRange(e)}},this.toSingleRange=function(e){e=e||this.ranges[0];var t=this.rangeList.removeAll();t.length&&this.$onRemoveRange(t),e&&this.fromOrientedRange(e)},this.substractPoint=function(e){var t=this.rangeList.substractPoint(e);if(t)return this.$onRemoveRange(t),t[0]},this.mergeOverlappingRanges=function(){var e=this.rangeList.merge();e.length&&this.$onRemoveRange(e)},this.$onAddRange=function(e){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(e),this._signal("addRange",{range:e})},this.$onRemoveRange=function(e){if(this.rangeCount=this.rangeList.ranges.length,1==this.rangeCount&&this.inMultiSelectMode){var t=this.rangeList.ranges.pop();e.push(t),this.rangeCount=0}for(var n=e.length;n--;){var r=this.ranges.indexOf(e[n]);this.ranges.splice(r,1)}this._signal("removeRange",{ranges:e}),0===this.rangeCount&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),t=t||this.ranges[0],t&&!t.isEqual(this.getRange())&&this.fromOrientedRange(t)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new r,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var e=this.ranges.length?this.ranges:[this.getRange()],t=[],n=0;n1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var r=this.session.documentToScreenPosition(this.cursor),o=this.session.documentToScreenPosition(this.anchor),a=this.rectangularRangeBlock(r,o);a.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(e,t,n){var r=[],o=e.column0)v--;if(v>0){var y=0;while(r[y].isEmpty())y++}for(var b=v;b>=y;b--)r[b].isEmpty()&&r.splice(b,1)}return r}}.call(o.prototype);var p=e("./editor").Editor;function m(e,t){return e.row==t.row&&e.column==t.column}function g(e){e.$multiselectOnSessionChange||(e.$onAddRange=e.$onAddRange.bind(e),e.$onRemoveRange=e.$onRemoveRange.bind(e),e.$onMultiSelect=e.$onMultiSelect.bind(e),e.$onSingleSelect=e.$onSingleSelect.bind(e),e.$multiselectOnSessionChange=t.onSessionChange.bind(e),e.$checkMultiselectChange=e.$checkMultiselectChange.bind(e),e.$multiselectOnSessionChange(e),e.on("changeSession",e.$multiselectOnSessionChange),e.on("mousedown",a),e.commands.addCommands(c.defaultCommands),v(e))}function v(e){if(e.textInput){var t=e.textInput.getElement(),n=!1;s.addListener(t,"keydown",function(t){var i=18==t.keyCode&&!(t.ctrlKey||t.shiftKey||t.metaKey);e.$blockSelectEnabled&&i?n||(e.renderer.setMouseCursor("crosshair"),n=!0):n&&r()},e),s.addListener(t,"keyup",r,e),s.addListener(t,"blur",r,e)}function r(t){n&&(e.renderer.setMouseCursor(""),n=!1)}}(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(e){e.cursor||(e.cursor=e.end);var t=this.getSelectionStyle();return e.marker=this.session.addMarker(e,"ace_selection",t),this.session.$selectionMarkers.push(e),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,e},this.removeSelectionMarker=function(e){if(e.marker){this.session.removeMarker(e.marker);var t=this.session.$selectionMarkers.indexOf(e);-1!=t&&this.session.$selectionMarkers.splice(t,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(e){for(var t=this.session.$selectionMarkers,n=e.length;n--;){var r=e[n];if(r.marker){this.session.removeMarker(r.marker);var i=t.indexOf(r);-1!=i&&t.splice(i,1)}}this.session.selectionMarkerCount=t.length},this.$onAddRange=function(e){this.addSelectionMarker(e.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(e){this.removeSelectionMarkers(e.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(e){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(c.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(e){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(c.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(e){var t=e.command,n=e.editor;if(n.multiSelect){if(t.multiSelectAction)"forEach"==t.multiSelectAction?r=n.forEachSelection(t,e.args):"forEachLine"==t.multiSelectAction?r=n.forEachSelection(t,e.args,!0):"single"==t.multiSelectAction?(n.exitMultiSelectMode(),r=t.exec(n,e.args||{})):r=t.multiSelectAction(n,e.args||{});else{var r=t.exec(n,e.args||{});n.multiSelect.addRange(n.multiSelect.toOrientedRange()),n.multiSelect.mergeOverlappingRanges()}return r}},this.forEachSelection=function(e,t,n){if(!this.inVirtualSelectionMode){var r,i=n&&n.keepOrder,a=1==n||n&&n.$byLines,s=this.session,l=this.selection,c=l.rangeList,u=(i?l:c).ranges;if(!u.length)return e.exec?e.exec(this,t||{}):e(this,t||{});var h=l._eventRegistry;l._eventRegistry={};var d=new o(s);this.inVirtualSelectionMode=!0;for(var f=u.length;f--;){if(a)while(f>0&&u[f].start.row==u[f-1].end.row)f--;d.fromOrientedRange(u[f]),d.index=f,this.selection=s.selection=d;var p=e.exec?e.exec(this,t||{}):e(this,t||{});r||void 0===p||(r=p),d.toOrientedRange(u[f])}d.detach(),this.selection=s.selection=l,this.inVirtualSelectionMode=!1,l._eventRegistry=h,l.mergeOverlappingRanges(),l.ranges[0]&&l.fromOrientedRange(l.ranges[0]);var m=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),m&&m.from==m.to&&this.renderer.animateScrolling(m.from),r}},this.exitMultiSelectMode=function(){this.inMultiSelectMode&&!this.inVirtualSelectionMode&&this.multiSelect.toSingleRange()},this.getSelectedText=function(){var e="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var t=this.multiSelect.rangeList.ranges,n=[],r=0;ra&&(a=n.column),iu?e.insert(r,l.stringRepeat(" ",o-u)):e.remove(new i(r.row,r.column,r.row,r.column-o+u)),t.start.column=t.end.column=a,t.start.row=t.end.row=r.row,t.cursor=t.end}),t.fromOrientedRange(n[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}else{var u=this.selection.getRange(),h=u.start.row,d=u.end.row,f=h==d;if(f){var p,m=this.session.getLength();do{p=this.session.getLine(d)}while(/[=:]/.test(p)&&++d0);h<0&&(h=0),d>=m&&(d=m-1)}var g=this.session.removeFullLines(h,d);g=this.$reAlignText(g,f),this.session.insert({row:h,column:0},g.join("\n")+"\n"),f||(u.start.column=0,u.end.column=g[g.length-1].length),this.selection.setRange(u)}},this.$reAlignText=function(e,t){var n,r,i,o=!0,a=!0;return e.map(function(e){var t=e.match(/(\s*)(.*?)(\s*)([=:].*)/);return t?null==n?(n=t[1].length,r=t[2].length,i=t[3].length,t):(n+r+i!=t[1].length+t[2].length+t[3].length&&(a=!1),n!=t[1].length&&(o=!1),n>t[1].length&&(n=t[1].length),rt[3].length&&(i=t[3].length),t):[e]}).map(t?c:o?a?u:c:h);function s(e){return l.stringRepeat(" ",e)}function c(e){return e[2]?s(n)+e[2]+s(r-e[2].length+i)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function u(e){return e[2]?s(n+r-e[2].length)+e[2]+s(i)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function h(e){return e[2]?s(n)+e[2]+s(i)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}}}).call(p.prototype),t.onSessionChange=function(e){var t=e.session;t&&!t.multiSelect&&(t.$selectionMarkers=[],t.selection.$initRangeList(),t.multiSelect=t.selection),this.multiSelect=t&&t.multiSelect;var n=e.oldSession;n&&(n.multiSelect.off("addRange",this.$onAddRange),n.multiSelect.off("removeRange",this.$onRemoveRange),n.multiSelect.off("multiSelect",this.$onMultiSelect),n.multiSelect.off("singleSelect",this.$onSingleSelect),n.multiSelect.lead.off("change",this.$checkMultiselectChange),n.multiSelect.anchor.off("change",this.$checkMultiselectChange)),t&&(t.multiSelect.on("addRange",this.$onAddRange),t.multiSelect.on("removeRange",this.$onRemoveRange),t.multiSelect.on("multiSelect",this.$onMultiSelect),t.multiSelect.on("singleSelect",this.$onSingleSelect),t.multiSelect.lead.on("change",this.$checkMultiselectChange),t.multiSelect.anchor.on("change",this.$checkMultiselectChange)),t&&this.inMultiSelectMode!=t.selection.inMultiSelectMode&&(t.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},t.MultiSelect=g,e("./config").defineOptions(p.prototype,"editor",{enableMultiselect:{set:function(e){g(this),e?(this.on("changeSession",this.$multiselectOnSessionChange),this.on("mousedown",a)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",a))},value:!0},enableBlockSelect:{set:function(e){this.$blockSelectEnabled=e},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../../range").Range,i=t.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);return this.foldingStartMarker.test(r)?"start":"markbeginend"==t&&this.foldingStopMarker&&this.foldingStopMarker.test(r)?"end":""},this.getFoldWidgetRange=function(e,t,n){return null},this.indentationBlock=function(e,t,n){var i=/\S/,o=e.getLine(t),a=o.search(i);if(-1!=a){var s=n||o.length,l=e.getLength(),c=t,u=t;while(++tc){var f=e.getLine(u).length;return new r(c,s,u,f)}}},this.openingBracketBlock=function(e,t,n,i,o){var a={row:n,column:i+1},s=e.$findClosingBracket(t,a,o);if(s){var l=e.foldWidgets[s.row];return null==l&&(l=e.getFoldWidget(s.row)),"start"==l&&s.row>a.row&&(s.row--,s.column=e.getLine(s.row).length),r.fromPoints(a,s)}},this.closingBracketBlock=function(e,t,n,i,o){var a={row:n,column:i},s=e.$findOpeningBracket(t,a);if(s)return s.column++,a.column--,r.fromPoints(s,a)}}).call(i.prototype)}),ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText='.ace-tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width: 1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm {background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm .ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid {background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121, 222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136, 107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color: rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color: rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color: rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213, 255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px white;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192, 192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0, 0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}',t.$id="ace/theme/textmate";var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass)}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("./lib/dom");function i(e){this.session=e,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.$onChangeEditor=this.$onChangeEditor.bind(this),this.session.on("change",this.updateOnChange),this.session.on("changeFold",this.updateOnFold),this.session.on("changeEditor",this.$onChangeEditor)}(function(){this.getRowLength=function(e){var t;return t=this.lineWidgets&&this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0,this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+1+t:1+t},this.$getWidgetScreenLength=function(){var e=0;return this.lineWidgets.forEach(function(t){t&&t.rowCount&&!t.hidden&&(e+=t.rowCount)}),e},this.$onChangeEditor=function(e){this.attach(e.editor)},this.attach=function(e){e&&e.widgetManager&&e.widgetManager!=this&&e.widgetManager.detach(),this.editor!=e&&(this.detach(),this.editor=e,e&&(e.widgetManager=this,e.renderer.on("beforeRender",this.measureWidgets),e.renderer.on("afterRender",this.renderWidgets)))},this.detach=function(e){var t=this.editor;if(t){this.editor=null,t.widgetManager=null,t.renderer.off("beforeRender",this.measureWidgets),t.renderer.off("afterRender",this.renderWidgets);var n=this.session.lineWidgets;n&&n.forEach(function(e){e&&e.el&&e.el.parentNode&&(e._inDocument=!1,e.el.parentNode.removeChild(e.el))})}},this.updateOnFold=function(e,t){var n=t.lineWidgets;if(n&&e.action){for(var r=e.data,i=r.start.row,o=r.end.row,a="add"==e.action,s=i+1;st[n].column&&n++,o.unshift(n,0),t.splice.apply(t,o),this.$updateRows()}}},this.$updateRows=function(){var e=this.session.lineWidgets;if(e){var t=!0;e.forEach(function(e,n){if(e){t=!1,e.row=n;while(e.$oldWidget)e.$oldWidget.row=n,e=e.$oldWidget}}),t&&(this.session.lineWidgets=null)}},this.$registerLineWidget=function(e){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var t=this.session.lineWidgets[e.row];return t&&(e.$oldWidget=t,t.el&&t.el.parentNode&&(t.el.parentNode.removeChild(t.el),t._inDocument=!1)),this.session.lineWidgets[e.row]=e,e},this.addLineWidget=function(e){if(this.$registerLineWidget(e),e.session=this.session,!this.editor)return e;var t=this.editor.renderer;e.html&&!e.el&&(e.el=r.createElement("div"),e.el.innerHTML=e.html),e.el&&(r.addCssClass(e.el,"ace_lineWidgetContainer"),e.el.style.position="absolute",e.el.style.zIndex=5,t.container.appendChild(e.el),e._inDocument=!0,e.coverGutter||(e.el.style.zIndex=3),null==e.pixelHeight&&(e.pixelHeight=e.el.offsetHeight)),null==e.rowCount&&(e.rowCount=e.pixelHeight/t.layerConfig.lineHeight);var n=this.session.getFoldAt(e.row,0);if(e.$fold=n,n){var i=this.session.lineWidgets;e.row!=n.end.row||i[n.start.row]?e.hidden=!0:i[n.start.row]=e}return this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows(),this.renderWidgets(null,t),this.onWidgetChanged(e),e},this.removeLineWidget=function(e){if(e._inDocument=!1,e.session=null,e.el&&e.el.parentNode&&e.el.parentNode.removeChild(e.el),e.editor&&e.editor.destroy)try{e.editor.destroy()}catch(e){}if(this.session.lineWidgets){var t=this.session.lineWidgets[e.row];if(t==e)this.session.lineWidgets[e.row]=e.$oldWidget,e.$oldWidget&&this.onWidgetChanged(e.$oldWidget);else while(t){if(t.$oldWidget==e){t.$oldWidget=e.$oldWidget;break}t=t.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows()},this.getWidgetsAtRow=function(e){var t=this.session.lineWidgets,n=t&&t[e],r=[];while(n)r.push(n),n=n.$oldWidget;return r},this.onWidgetChanged=function(e){this.session._changedWidgets.push(e),this.editor&&this.editor.renderer.updateFull()},this.measureWidgets=function(e,t){var n=this.session._changedWidgets,r=t.layerConfig;if(n&&n.length){for(var i=1/0,o=0;o