1
0
mirror of https://github.com/pdemian/human2regex.git synced 2025-05-16 04:20:35 -07:00
human2regex/docs/bundle.min.js
2020-11-01 05:19:46 -05:00

31 lines
244 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

!function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=6)}([function(t,e,n){"use strict";function r(t){return t&&0===t.length}function i(t){return null==t?[]:Object.keys(t)}function o(t){for(var e=[],n=Object.keys(t),r=0;r<n.length;r++)e.push(t[n[r]]);return e}function a(t,e){for(var n=[],r=i(t),o=0;o<r.length;o++){var a=r[o];n.push(e.call(null,t[a],a))}return n}function s(t,e){for(var n=[],r=0;r<t.length;r++)n.push(e.call(null,t[r],r));return n}function c(t){for(var e=[],n=0;n<t.length;n++){var r=t[n];Array.isArray(r)?e=e.concat(c(r)):e.push(r)}return e}function u(t){return r(t)?void 0:t[0]}function l(t){var e=t&&t.length;return e?t[e-1]:void 0}function f(t,e){if(Array.isArray(t))for(var n=0;n<t.length;n++)e.call(null,t[n],n);else{if(!w(t))throw Error("non exhaustive match");var r=i(t);for(n=0;n<r.length;n++){var o=r[n],a=t[o];e.call(null,a,o)}}}function p(t){return"string"==typeof t}function h(t){return void 0===t}function d(t){return t instanceof Function}function m(t,e){return void 0===e&&(e=1),t.slice(e,t.length)}function v(t,e){return void 0===e&&(e=1),t.slice(0,t.length-e)}function g(t,e){var n=[];if(Array.isArray(t))for(var r=0;r<t.length;r++){var i=t[r];e.call(null,i)&&n.push(i)}return n}function y(t,e){return g(t,(function(t){return!e(t)}))}function T(t,e){for(var n=Object.keys(t),r={},i=0;i<n.length;i++){var o=n[i],a=t[o];e(a)&&(r[o]=a)}return r}function O(t,e){return!!w(t)&&t.hasOwnProperty(e)}function E(t,e){return void 0!==N(t,(function(t){return t===e}))}function b(t){for(var e=[],n=0;n<t.length;n++)e.push(t[n]);return e}function S(t){var e={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function N(t,e){for(var n=0;n<t.length;n++){var r=t[n];if(e.call(null,r))return r}}function x(t,e){for(var n=[],r=0;r<t.length;r++){var i=t[r];e.call(null,i)&&n.push(i)}return n}function A(t,e,n){for(var r=Array.isArray(t),a=r?t:o(t),s=r?[]:i(t),c=n,u=0;u<a.length;u++)c=e.call(null,c,a[u],r?u:s[u]);return c}function R(t){return y(t,(function(t){return null==t}))}function C(t,e){void 0===e&&(e=function(t){return t});var n=[];return A(t,(function(t,r){var i=e(r);return E(n,i)?t:(n.push(i),t.concat(r))}),[])}function I(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var r=[null],i=r.concat(e);return Function.bind.apply(t,i)}function k(t){return Array.isArray(t)}function L(t){return t instanceof RegExp}function w(t){return t instanceof Object}function _(t,e){for(var n=0;n<t.length;n++)if(!e(t[n],n))return!1;return!0}function j(t,e){return y(t,(function(t){return E(e,t)}))}function M(t,e){for(var n=0;n<t.length;n++)if(e(t[n]))return!0;return!1}function P(t,e){for(var n=0;n<t.length;n++)if(t[n]===e)return n;return-1}function D(t,e){var n=b(t);return n.sort((function(t,n){return e(t)-e(n)})),n}function U(t,e){if(t.length!==e.length)throw Error("can't zipObject with different number of keys and values!");for(var n={},r=0;r<t.length;r++)n[t[r]]=e[r];return n}function F(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];for(var r=0;r<e.length;r++)for(var o=e[r],a=i(o),s=0;s<a.length;s++){var c=a[s];t[c]=o[c]}return t}function B(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];for(var r=0;r<e.length;r++)for(var o=e[r],a=i(o),s=0;s<a.length;s++){var c=a[s];O(t,c)||(t[c]=o[c])}return t}function H(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return B.apply(null,[{}].concat(t))}function W(t,e){var n={};return f(t,(function(t){var r=e(t),i=n[r];i?i.push(t):n[r]=[t]})),n}function G(t,e){for(var n=S(t),r=i(e),o=0;o<r.length;o++){var a=r[o],s=e[a];n[a]=s}return n}function q(){}function V(t){return t}function K(t){for(var e=[],n=0;n<t.length;n++){var r=t[n];e.push(void 0!==r?r:void 0)}return e}function z(t){console&&console.error&&console.error("Error: "+t)}function $(t){console&&console.warn&&console.warn("Warning: "+t)}function Y(){return"function"==typeof Map}function X(t,e){e.forEach((function(e){var n=e.prototype;Object.getOwnPropertyNames(n).forEach((function(r){if("constructor"!==r){var i=Object.getOwnPropertyDescriptor(n,r);i&&(i.get||i.set)?Object.defineProperty(t.prototype,r,i):t.prototype[r]=e.prototype[r]}}))}))}function J(t){function e(){}e.prototype=t;var n=new e;function r(){return typeof n.bar}return r(),r(),t}function Q(t){return t[t.length-1]}function Z(t){var e=(new Date).getTime(),n=t();return{time:(new Date).getTime()-e,value:n}}n.d(e,"A",(function(){return r})),n.d(e,"G",(function(){return i})),n.d(e,"U",(function(){return o})),n.d(e,"J",(function(){return a})),n.d(e,"I",(function(){return s})),n.d(e,"t",(function(){return c})),n.d(e,"s",(function(){return u})),n.d(e,"H",(function(){return l})),n.d(e,"u",(function(){return f})),n.d(e,"E",(function(){return p})),n.d(e,"F",(function(){return h})),n.d(e,"B",(function(){return d})),n.d(e,"m",(function(){return m})),n.d(e,"n",(function(){return v})),n.d(e,"p",(function(){return g})),n.d(e,"P",(function(){return y})),n.d(e,"N",(function(){return T})),n.d(e,"w",(function(){return O})),n.d(e,"j",(function(){return E})),n.d(e,"g",(function(){return b})),n.d(e,"h",(function(){return S})),n.d(e,"q",(function(){return N})),n.d(e,"r",(function(){return x})),n.d(e,"O",(function(){return A})),n.d(e,"i",(function(){return R})),n.d(e,"T",(function(){return C})),n.d(e,"y",(function(){return k})),n.d(e,"D",(function(){return L})),n.d(e,"C",(function(){return w})),n.d(e,"o",(function(){return _})),n.d(e,"l",(function(){return j})),n.d(e,"Q",(function(){return M})),n.d(e,"x",(function(){return P})),n.d(e,"f",(function(){return F})),n.d(e,"k",(function(){return H})),n.d(e,"v",(function(){return W})),n.d(e,"K",(function(){return G})),n.d(e,"b",(function(){return q})),n.d(e,"a",(function(){return V})),n.d(e,"L",(function(){return K})),n.d(e,"c",(function(){return z})),n.d(e,"d",(function(){return $})),n.d(e,"z",(function(){return Y})),n.d(e,"e",(function(){return X})),n.d(e,"S",(function(){return J})),n.d(e,"M",(function(){return Q})),n.d(e,"R",(function(){return Z}))},function(t,e,n){var r,i,o;"undefined"!=typeof self&&self,i=[],void 0===(o="function"==typeof(r=function(){function t(){}t.prototype.saveState=function(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}},t.prototype.restoreState=function(t){this.idx=t.idx,this.input=t.input,this.groupIdx=t.groupIdx},t.prototype.pattern=function(t){this.idx=0,this.input=t,this.groupIdx=0,this.consumeChar("/");var e=this.disjunction();this.consumeChar("/");for(var n={type:"Flags",loc:{begin:this.idx,end:t.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};this.isRegExpFlag();)switch(this.popChar()){case"g":s(n,"global");break;case"i":s(n,"ignoreCase");break;case"m":s(n,"multiLine");break;case"u":s(n,"unicode");break;case"y":s(n,"sticky")}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:n,value:e,loc:this.loc(0)}},t.prototype.disjunction=function(){var t=[],e=this.idx;for(t.push(this.alternative());"|"===this.peekChar();)this.consumeChar("|"),t.push(this.alternative());return{type:"Disjunction",value:t,loc:this.loc(e)}},t.prototype.alternative=function(){for(var t=[],e=this.idx;this.isTerm();)t.push(this.term());return{type:"Alternative",value:t,loc:this.loc(e)}},t.prototype.term=function(){return this.isAssertion()?this.assertion():this.atom()},t.prototype.assertion=function(){var t=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(t)};case"$":return{type:"EndAnchor",loc:this.loc(t)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(t)};case"B":return{type:"NonWordBoundary",loc:this.loc(t)}}throw Error("Invalid Assertion Escape");case"(":var e;switch(this.consumeChar("?"),this.popChar()){case"=":e="Lookahead";break;case"!":e="NegativeLookahead"}c(e);var n=this.disjunction();return this.consumeChar(")"),{type:e,value:n,loc:this.loc(t)}}!function(){throw Error("Internal Error - Should never get here!")}()},t.prototype.quantifier=function(t){var e,n=this.idx;switch(this.popChar()){case"*":e={atLeast:0,atMost:1/0};break;case"+":e={atLeast:1,atMost:1/0};break;case"?":e={atLeast:0,atMost:1};break;case"{":var r=this.integerIncludingZero();switch(this.popChar()){case"}":e={atLeast:r,atMost:r};break;case",":e=this.isDigit()?{atLeast:r,atMost:this.integerIncludingZero()}:{atLeast:r,atMost:1/0},this.consumeChar("}")}if(!0===t&&void 0===e)return;c(e)}if(!0!==t||void 0!==e)return c(e),"?"===this.peekChar(0)?(this.consumeChar("?"),e.greedy=!1):e.greedy=!0,e.type="Quantifier",e.loc=this.loc(n),e},t.prototype.atom=function(){var t,e=this.idx;switch(this.peekChar()){case".":t=this.dotAll();break;case"\\":t=this.atomEscape();break;case"[":t=this.characterClass();break;case"(":t=this.group()}return void 0===t&&this.isPatternCharacter()&&(t=this.patternCharacter()),c(t),t.loc=this.loc(e),this.isQuantifier()&&(t.quantifier=this.quantifier()),t},t.prototype.dotAll=function(){return this.consumeChar("."),{type:"Set",complement:!0,value:[o("\n"),o("\r"),o("\u2028"),o("\u2029")]}},t.prototype.atomEscape=function(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}},t.prototype.decimalEscapeAtom=function(){return{type:"GroupBackReference",value:this.positiveInteger()}},t.prototype.characterClassEscape=function(){var t,e=!1;switch(this.popChar()){case"d":t=u;break;case"D":t=u,e=!0;break;case"s":t=f;break;case"S":t=f,e=!0;break;case"w":t=l;break;case"W":t=l,e=!0}return c(t),{type:"Set",value:t,complement:e}},t.prototype.controlEscapeAtom=function(){var t;switch(this.popChar()){case"f":t=o("\f");break;case"n":t=o("\n");break;case"r":t=o("\r");break;case"t":t=o("\t");break;case"v":t=o("\v")}return c(t),{type:"Character",value:t}},t.prototype.controlLetterEscapeAtom=function(){this.consumeChar("c");var t=this.popChar();if(!1===/[a-zA-Z]/.test(t))throw Error("Invalid ");return{type:"Character",value:t.toUpperCase().charCodeAt(0)-64}},t.prototype.nulCharacterAtom=function(){return this.consumeChar("0"),{type:"Character",value:o("\0")}},t.prototype.hexEscapeSequenceAtom=function(){return this.consumeChar("x"),this.parseHexDigits(2)},t.prototype.regExpUnicodeEscapeSequenceAtom=function(){return this.consumeChar("u"),this.parseHexDigits(4)},t.prototype.identityEscapeAtom=function(){return{type:"Character",value:o(this.popChar())}},t.prototype.classPatternCharacterAtom=function(){switch(this.peekChar()){case"\n":case"\r":case"\u2028":case"\u2029":case"\\":case"]":throw Error("TBD");default:return{type:"Character",value:o(this.popChar())}}},t.prototype.characterClass=function(){var t=[],e=!1;for(this.consumeChar("["),"^"===this.peekChar(0)&&(this.consumeChar("^"),e=!0);this.isClassAtom();){var n=this.classAtom();if("Character"===n.type&&this.isRangeDash()){this.consumeChar("-");var r=this.classAtom();if("Character"===r.type){if(r.value<n.value)throw Error("Range out of order in character class");t.push({from:n.value,to:r.value})}else a(n.value,t),t.push(o("-")),a(r.value,t)}else a(n.value,t)}return this.consumeChar("]"),{type:"Set",complement:e,value:t}},t.prototype.classAtom=function(){switch(this.peekChar()){case"]":case"\n":case"\r":case"\u2028":case"\u2029":throw Error("TBD");case"\\":return this.classEscape();default:return this.classPatternCharacterAtom()}},t.prototype.classEscape=function(){switch(this.consumeChar("\\"),this.peekChar()){case"b":return this.consumeChar("b"),{type:"Character",value:o("\b")};case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}},t.prototype.group=function(){var t=!0;switch(this.consumeChar("("),this.peekChar(0)){case"?":this.consumeChar("?"),this.consumeChar(":"),t=!1;break;default:this.groupIdx++}var e=this.disjunction();this.consumeChar(")");var n={type:"Group",capturing:t,value:e};return t&&(n.idx=this.groupIdx),n},t.prototype.positiveInteger=function(){var t=this.popChar();if(!1===i.test(t))throw Error("Expecting a positive integer");for(;r.test(this.peekChar(0));)t+=this.popChar();return parseInt(t,10)},t.prototype.integerIncludingZero=function(){var t=this.popChar();if(!1===r.test(t))throw Error("Expecting an integer");for(;r.test(this.peekChar(0));)t+=this.popChar();return parseInt(t,10)},t.prototype.patternCharacter=function(){var t=this.popChar();switch(t){case"\n":case"\r":case"\u2028":case"\u2029":case"^":case"$":case"\\":case".":case"*":case"+":case"?":case"(":case")":case"[":case"|":throw Error("TBD");default:return{type:"Character",value:o(t)}}},t.prototype.isRegExpFlag=function(){switch(this.peekChar(0)){case"g":case"i":case"m":case"u":case"y":return!0;default:return!1}},t.prototype.isRangeDash=function(){return"-"===this.peekChar()&&this.isClassAtom(1)},t.prototype.isDigit=function(){return r.test(this.peekChar(0))},t.prototype.isClassAtom=function(t){switch(void 0===t&&(t=0),this.peekChar(t)){case"]":case"\n":case"\r":case"\u2028":case"\u2029":return!1;default:return!0}},t.prototype.isTerm=function(){return this.isAtom()||this.isAssertion()},t.prototype.isAtom=function(){if(this.isPatternCharacter())return!0;switch(this.peekChar(0)){case".":case"\\":case"[":case"(":return!0;default:return!1}},t.prototype.isAssertion=function(){switch(this.peekChar(0)){case"^":case"$":return!0;case"\\":switch(this.peekChar(1)){case"b":case"B":return!0;default:return!1}case"(":return"?"===this.peekChar(1)&&("="===this.peekChar(2)||"!"===this.peekChar(2));default:return!1}},t.prototype.isQuantifier=function(){var t=this.saveState();try{return void 0!==this.quantifier(!0)}catch(t){return!1}finally{this.restoreState(t)}},t.prototype.isPatternCharacter=function(){switch(this.peekChar()){case"^":case"$":case"\\":case".":case"*":case"+":case"?":case"(":case")":case"[":case"|":case"/":case"\n":case"\r":case"\u2028":case"\u2029":return!1;default:return!0}},t.prototype.parseHexDigits=function(t){for(var e="",r=0;r<t;r++){var i=this.popChar();if(!1===n.test(i))throw Error("Expecting a HexDecimal digits");e+=i}return{type:"Character",value:parseInt(e,16)}},t.prototype.peekChar=function(t){return void 0===t&&(t=0),this.input[this.idx+t]},t.prototype.popChar=function(){var t=this.peekChar(0);return this.consumeChar(),t},t.prototype.consumeChar=function(t){if(void 0!==t&&this.input[this.idx]!==t)throw Error("Expected: '"+t+"' but found: '"+this.input[this.idx]+"' at offset: "+this.idx);if(this.idx>=this.input.length)throw Error("Unexpected end of input");this.idx++},t.prototype.loc=function(t){return{begin:t,end:this.idx}};var e,n=/[0-9a-fA-F]/,r=/[0-9]/,i=/[1-9]/;function o(t){return t.charCodeAt(0)}function a(t,e){void 0!==t.length?t.forEach((function(t){e.push(t)})):e.push(t)}function s(t,e){if(!0===t[e])throw"duplicate flag "+e;t[e]=!0}function c(t){if(void 0===t)throw Error("Internal Error - Should never get here!")}var u=[];for(e=o("0");e<=o("9");e++)u.push(e);var l=[o("_")].concat(u);for(e=o("a");e<=o("z");e++)l.push(e);for(e=o("A");e<=o("Z");e++)l.push(e);var f=[o(" "),o("\f"),o("\n"),o("\r"),o("\t"),o("\v"),o("\t"),o(" "),o(""),o(" "),o(""),o(""),o(""),o(""),o(""),o(""),o(""),o(""),o(""),o(""),o("\u2028"),o("\u2029"),o(""),o(""),o(" "),o("\ufeff")];function p(){}return p.prototype.visitChildren=function(t){for(var e in t){var n=t[e];t.hasOwnProperty(e)&&(void 0!==n.type?this.visit(n):Array.isArray(n)&&n.forEach((function(t){this.visit(t)}),this))}},p.prototype.visit=function(t){switch(t.type){case"Pattern":this.visitPattern(t);break;case"Flags":this.visitFlags(t);break;case"Disjunction":this.visitDisjunction(t);break;case"Alternative":this.visitAlternative(t);break;case"StartAnchor":this.visitStartAnchor(t);break;case"EndAnchor":this.visitEndAnchor(t);break;case"WordBoundary":this.visitWordBoundary(t);break;case"NonWordBoundary":this.visitNonWordBoundary(t);break;case"Lookahead":this.visitLookahead(t);break;case"NegativeLookahead":this.visitNegativeLookahead(t);break;case"Character":this.visitCharacter(t);break;case"Set":this.visitSet(t);break;case"Group":this.visitGroup(t);break;case"GroupBackReference":this.visitGroupBackReference(t);break;case"Quantifier":this.visitQuantifier(t)}this.visitChildren(t)},p.prototype.visitPattern=function(t){},p.prototype.visitFlags=function(t){},p.prototype.visitDisjunction=function(t){},p.prototype.visitAlternative=function(t){},p.prototype.visitStartAnchor=function(t){},p.prototype.visitEndAnchor=function(t){},p.prototype.visitWordBoundary=function(t){},p.prototype.visitNonWordBoundary=function(t){},p.prototype.visitLookahead=function(t){},p.prototype.visitNegativeLookahead=function(t){},p.prototype.visitCharacter=function(t){},p.prototype.visitSet=function(t){},p.prototype.visitGroup=function(t){},p.prototype.visitGroupBackReference=function(t){},p.prototype.visitQuantifier=function(t){},{RegExpParser:t,BaseRegExpVisitor:p,VERSION:"0.5.0"}})?r.apply(e,i):r)||(t.exports=o)},function(t,e,n){"use strict";
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */Object.defineProperty(e,"__esModule",{value:!0}),e.semanticErrorToCommonError=e.parseErrorToCommonError=e.lexErrorToCommonError=e.regexEscape=e.removeQuotes=e.findLastIndexPredicate=e.findLastIndex=e.last=e.first=e.isSingleRegexCharacter=e.combineFlags=e.hasFlag=void 0,e.hasFlag=function(t,e){return 0!=(t&e)},e.combineFlags=function(t,e){return t|e},e.isSingleRegexCharacter=function(t){return t.startsWith("\\u")&&6===t.length||t.startsWith("\\U")&&8===t.length||t.startsWith("\\")&&2===t.length||1===t.length},e.first=function(t){return t[0]},e.last=function(t){return t[t.length-1]},e.findLastIndex=function(t,e){for(let n=t.length-1;n>=0;n--)if(t[n]===e)return n;return-1},e.findLastIndexPredicate=function(t,e){for(let n=t.length-1;n>=0;n--)if(e(t[n]))return n;return-1},e.removeQuotes=function(t){return t.substring(1,t.length-1)},e.regexEscape=function(t){return t.replace("\\","\\\\").replace(/([=:\-\.\[\]\^\|\(\)\*\+\?\{\}\$\/])/g,"\\$1")},e.lexErrorToCommonError=function(t){return{type:"Lexer Error",startLine:t.line,startColumn:t.column,length:t.length,message:t.message}},e.parseErrorToCommonError=function(t){var e,n,r;return{type:"Parser Error",startLine:null!==(e=t.token.startLine)&&void 0!==e?e:NaN,startColumn:null!==(n=t.token.startColumn)&&void 0!==n?n:NaN,length:null!==(r=t.token.endOffset)&&void 0!==r?r:NaN-t.token.startOffset,message:t.name+": "+t.message}},e.semanticErrorToCommonError=function(t){return t.type="Semantic Error",t}},function(t,e,n){"use strict";n.r(e),n.d(e,"VERSION",(function(){return r})),n.d(e,"CstParser",(function(){return rn})),n.d(e,"EmbeddedActionsParser",(function(){return on})),n.d(e,"ParserDefinitionErrorType",(function(){return Qe})),n.d(e,"EMPTY_ALT",(function(){return en})),n.d(e,"Lexer",(function(){return $})),n.d(e,"LexerDefinitionErrorType",(function(){return V})),n.d(e,"createToken",(function(){return Q})),n.d(e,"createTokenInstance",(function(){return tt})),n.d(e,"EOF",(function(){return Z})),n.d(e,"tokenLabel",(function(){return Y})),n.d(e,"tokenMatcher",(function(){return et})),n.d(e,"tokenName",(function(){return X})),n.d(e,"defaultGrammarResolverErrorProvider",(function(){return It})),n.d(e,"defaultGrammarValidatorErrorProvider",(function(){return kt})),n.d(e,"defaultParserErrorProvider",(function(){return Ct})),n.d(e,"EarlyExitException",(function(){return ge})),n.d(e,"isRecognitionException",(function(){return he})),n.d(e,"MismatchedTokenException",(function(){return de})),n.d(e,"NotAllInputParsedException",(function(){return ve})),n.d(e,"NoViableAltException",(function(){return me})),n.d(e,"defaultLexerErrorProvider",(function(){return K})),n.d(e,"Alternation",(function(){return pt})),n.d(e,"Alternative",(function(){return at})),n.d(e,"NonTerminal",(function(){return it})),n.d(e,"Option",(function(){return st})),n.d(e,"Repetition",(function(){return lt})),n.d(e,"RepetitionMandatory",(function(){return ct})),n.d(e,"RepetitionMandatoryWithSeparator",(function(){return ut})),n.d(e,"RepetitionWithSeparator",(function(){return ft})),n.d(e,"Rule",(function(){return ot})),n.d(e,"Terminal",(function(){return ht})),n.d(e,"serializeGrammar",(function(){return dt})),n.d(e,"serializeProduction",(function(){return mt})),n.d(e,"GAstVisitor",(function(){return yt})),n.d(e,"assignOccurrenceIndices",(function(){return fe})),n.d(e,"resolveGrammar",(function(){return ue})),n.d(e,"validateGrammar",(function(){return le})),n.d(e,"clearCache",(function(){return gn})),n.d(e,"createSyntaxDiagramsCode",(function(){return an})),n.d(e,"generateParserFactory",(function(){return mn})),n.d(e,"generateParserModule",(function(){return vn})),n.d(e,"Parser",(function(){return yn}));var r="7.0.2",i=n(0),o=n(1),a={},s=new o.RegExpParser;function c(t){var e=t.toString();if(a.hasOwnProperty(e))return a[e];var n=s.pattern(e);return a[e]=n,n}var u,l=(u=function(t,e){return(u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}u(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),f='Unable to use "first char" lexer optimizations:\n';function p(t,e){void 0===e&&(e=!1);try{var n=c(t);return function t(e,n,r){switch(e.type){case"Disjunction":for(var o=0;o<e.value.length;o++)t(e.value[o],n,r);break;case"Alternative":var a=e.value;for(o=0;o<a.length;o++){var s=a[o];switch(s.type){case"EndAnchor":case"GroupBackReference":case"Lookahead":case"NegativeLookahead":case"StartAnchor":case"WordBoundary":case"NonWordBoundary":continue}var c=s;switch(c.type){case"Character":h(c.value,n,r);break;case"Set":if(!0===c.complement)throw Error("Complement Sets are not supported for first char optimization");Object(i.u)(c.value,(function(t){if("number"==typeof t)h(t,n,r);else{var e=t;if(!0===r)for(var i=e.from;i<=e.to;i++)h(i,n,r);else{for(i=e.from;i<=e.to&&i<j;i++)h(i,n,r);if(e.to>=j)for(var o=e.from>=j?e.from:j,a=e.to,s=M(o),c=M(a),u=s;u<=c;u++)n[u]=u}}}));break;case"Group":t(c.value,n,r);break;default:throw Error("Non Exhaustive Match")}var u=void 0!==c.quantifier&&0===c.quantifier.atLeast;if("Group"===c.type&&!1===m(c)||"Group"!==c.type&&!1===u)break}break;default:throw Error("non exhaustive match!")}return Object(i.U)(n)}(n.value,{},n.flags.ignoreCase)}catch(n){if("Complement Sets are not supported for first char optimization"===n.message)e&&Object(i.d)(f+"\tUnable to optimize: < "+t.toString()+" >\n\tComplement Sets cannot be automatically optimized.\n\tThis will disable the lexer's first char optimizations.\n\tSee: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.");else{var r="";e&&(r="\n\tThis will disable the lexer's first char optimizations.\n\tSee: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details."),Object(i.c)(f+"\n\tFailed parsing: < "+t.toString()+" >\n\tUsing the regexp-to-ast library version: "+o.VERSION+"\n\tPlease open an issue at: https://github.com/bd82/regexp-to-ast/issues"+r)}}return[]}function h(t,e,n){var r=M(t);e[r]=r,!0===n&&function(t,e){var n=String.fromCharCode(t),r=n.toUpperCase();if(r!==n){var i=M(r.charCodeAt(0));e[i]=i}else{var o=n.toLowerCase();if(o!==n){i=M(o.charCodeAt(0));e[i]=i}}}(t,e)}function d(t,e){return Object(i.q)(t.value,(function(t){if("number"==typeof t)return Object(i.j)(e,t);var n=t;return void 0!==Object(i.q)(e,(function(t){return n.from<=t&&t<=n.to}))}))}function m(t){return!(!t.quantifier||0!==t.quantifier.atLeast)||!!t.value&&(Object(i.y)(t.value)?Object(i.o)(t.value,m):m(t.value))}var v=function(t){function e(e){var n=t.call(this)||this;return n.targetCharCodes=e,n.found=!1,n}return l(e,t),e.prototype.visitChildren=function(e){if(!0!==this.found){switch(e.type){case"Lookahead":return void this.visitLookahead(e);case"NegativeLookahead":return void this.visitNegativeLookahead(e)}t.prototype.visitChildren.call(this,e)}},e.prototype.visitCharacter=function(t){Object(i.j)(this.targetCharCodes,t.value)&&(this.found=!0)},e.prototype.visitSet=function(t){t.complement?void 0===d(t,this.targetCharCodes)&&(this.found=!0):void 0!==d(t,this.targetCharCodes)&&(this.found=!0)},e}(o.BaseRegExpVisitor);function g(t,e){if(e instanceof RegExp){var n=c(e),r=new v(t);return r.visit(n),r.found}return void 0!==Object(i.q)(e,(function(e){return Object(i.j)(t,e.charCodeAt(0))}))}var y=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),T="PATTERN",O="boolean"==typeof new RegExp("(?:)").sticky;function E(t,e){var n,r=(e=Object(i.k)(e,{useSticky:O,debug:!1,safeMode:!1,positionTracking:"full",lineTerminatorCharacters:["\r","\n"],tracer:function(t,e){return e()}})).tracer;r("initCharCodeToOptimizedIndexMap",(function(){!function(){if(Object(i.A)(P)){P=new Array(65536);for(var t=0;t<65536;t++)P[t]=t>255?255+~~(t/255):t}}()})),r("Reject Lexer.NA",(function(){n=Object(i.P)(t,(function(t){return t[T]===$.NA}))}));var o,a,s,c,u,l,h,d,m,v,y,E=!1;r("Transform Patterns",(function(){E=!1,o=Object(i.I)(n,(function(t){var n=t[T];if(Object(i.D)(n)){var r=n.source;return 1!==r.length||"^"===r||"$"===r||"."===r||n.ignoreCase?2!==r.length||"\\"!==r[0]||Object(i.j)(["d","D","s","S","t","r","n","t","0","c","b","B","f","v","w","W"],r[1])?e.useSticky?A(n):x(n):r[1]:r}if(Object(i.B)(n))return E=!0,{exec:n};if(Object(i.w)(n,"exec"))return E=!0,n;if("string"==typeof n){if(1===n.length)return n;var o=n.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),a=new RegExp(o);return e.useSticky?A(a):x(a)}throw Error("non exhaustive match")}))})),r("misc mapping",(function(){a=Object(i.I)(n,(function(t){return t.tokenTypeIdx})),s=Object(i.I)(n,(function(t){var e=t.GROUP;if(e!==$.SKIPPED){if(Object(i.E)(e))return e;if(Object(i.F)(e))return!1;throw Error("non exhaustive match")}})),c=Object(i.I)(n,(function(t){var e=t.LONGER_ALT;if(e)return Object(i.x)(n,e)})),u=Object(i.I)(n,(function(t){return t.PUSH_MODE})),l=Object(i.I)(n,(function(t){return Object(i.w)(t,"POP_MODE")}))})),r("Line Terminator Handling",(function(){var t=w(e.lineTerminatorCharacters);h=Object(i.I)(n,(function(t){return!1})),"onlyOffset"!==e.positionTracking&&(h=Object(i.I)(n,(function(e){return Object(i.w)(e,"LINE_BREAKS")?e.LINE_BREAKS:!1===L(e,t)?g(t,e.PATTERN):void 0})))})),r("Misc Mapping #2",(function(){d=Object(i.I)(n,C),m=Object(i.I)(o,I),v=Object(i.O)(n,(function(t,e){var n=e.GROUP;return Object(i.E)(n)&&n!==$.SKIPPED&&(t[n]=[]),t}),{}),y=Object(i.I)(o,(function(t,e){return{pattern:o[e],longerAlt:c[e],canLineTerminator:h[e],isCustom:d[e],short:m[e],group:s[e],push:u[e],pop:l[e],tokenTypeIdx:a[e],tokenType:n[e]}}))}));var b=!0,S=[];return e.safeMode||r("First Char Optimization",(function(){S=Object(i.O)(n,(function(t,n,r){if("string"==typeof n.PATTERN){var o=M(n.PATTERN.charCodeAt(0));_(t,o,y[r])}else if(Object(i.y)(n.START_CHARS_HINT)){var a;Object(i.u)(n.START_CHARS_HINT,(function(e){var n=M("string"==typeof e?e.charCodeAt(0):e);a!==n&&(a=n,_(t,n,y[r]))}))}else if(Object(i.D)(n.PATTERN))if(n.PATTERN.unicode)b=!1,e.ensureOptimizations&&Object(i.c)(f+"\tUnable to analyze < "+n.PATTERN.toString()+" > pattern.\n\tThe regexp unicode flag is not currently supported by the regexp-to-ast library.\n\tThis will disable the lexer's first char optimizations.\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE");else{var s=p(n.PATTERN,e.ensureOptimizations);Object(i.A)(s)&&(b=!1),Object(i.u)(s,(function(e){_(t,e,y[r])}))}else e.ensureOptimizations&&Object(i.c)(f+"\tTokenType: <"+n.name+"> is using a custom token pattern without providing <start_chars_hint> parameter.\n\tThis will disable the lexer's first char optimizations.\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE"),b=!1;return t}),[])})),r("ArrayPacking",(function(){S=Object(i.L)(S)})),{emptyGroups:v,patternIdxToConfig:y,charCodeToPatternIdxToConfig:S,hasCustom:E,canBeOptimized:b}}function b(t,e){var n=[],r=function(t){var e=Object(i.p)(t,(function(t){return!Object(i.w)(t,T)})),n=Object(i.I)(e,(function(t){return{message:"Token Type: ->"+t.name+"<- missing static 'PATTERN' property",type:V.MISSING_PATTERN,tokenTypes:[t]}})),r=Object(i.l)(t,e);return{errors:n,valid:r}}(t);n=n.concat(r.errors);var a=function(t){var e=Object(i.p)(t,(function(t){var e=t[T];return!(Object(i.D)(e)||Object(i.B)(e)||Object(i.w)(e,"exec")||Object(i.E)(e))})),n=Object(i.I)(e,(function(t){return{message:"Token Type: ->"+t.name+"<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.",type:V.INVALID_PATTERN,tokenTypes:[t]}})),r=Object(i.l)(t,e);return{errors:n,valid:r}}(r.valid),s=a.valid;return n=(n=(n=(n=(n=n.concat(a.errors)).concat(function(t){var e=[],n=Object(i.p)(t,(function(t){return Object(i.D)(t[T])}));return e=(e=(e=(e=(e=e.concat(function(t){var e=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.found=!1,e}return y(e,t),e.prototype.visitEndAnchor=function(t){this.found=!0},e}(o.BaseRegExpVisitor),n=Object(i.p)(t,(function(t){var n=t[T];try{var r=c(n),i=new e;return i.visit(r),i.found}catch(t){return S.test(n.source)}}));return Object(i.I)(n,(function(t){return{message:"Unexpected RegExp Anchor Error:\n\tToken Type: ->"+t.name+"<- static 'PATTERN' cannot contain end of input anchor '$'\n\tSee sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#ANCHORS\tfor details.",type:V.EOI_ANCHOR_FOUND,tokenTypes:[t]}}))}(n))).concat(function(t){var e=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.found=!1,e}return y(e,t),e.prototype.visitStartAnchor=function(t){this.found=!0},e}(o.BaseRegExpVisitor),n=Object(i.p)(t,(function(t){var n=t[T];try{var r=c(n),i=new e;return i.visit(r),i.found}catch(t){return N.test(n.source)}}));return Object(i.I)(n,(function(t){return{message:"Unexpected RegExp Anchor Error:\n\tToken Type: ->"+t.name+"<- static 'PATTERN' cannot contain start of input anchor '^'\n\tSee https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#ANCHORS\tfor details.",type:V.SOI_ANCHOR_FOUND,tokenTypes:[t]}}))}(n))).concat(function(t){var e=Object(i.p)(t,(function(t){var e=t[T];return e instanceof RegExp&&(e.multiline||e.global)}));return Object(i.I)(e,(function(t){return{message:"Token Type: ->"+t.name+"<- static 'PATTERN' may NOT contain global('g') or multiline('m')",type:V.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[t]}}))}(n))).concat(function(t){var e=[],n=Object(i.I)(t,(function(n){return Object(i.O)(t,(function(t,r){return n.PATTERN.source!==r.PATTERN.source||Object(i.j)(e,r)||r.PATTERN===$.NA||(e.push(r),t.push(r)),t}),[])}));n=Object(i.i)(n);var r=Object(i.p)(n,(function(t){return t.length>1}));return Object(i.I)(r,(function(t){var e=Object(i.I)(t,(function(t){return t.name}));return{message:"The same RegExp pattern ->"+Object(i.s)(t).PATTERN+"<-has been used in all of the following Token Types: "+e.join(", ")+" <-",type:V.DUPLICATE_PATTERNS_FOUND,tokenTypes:t}}))}(n))).concat(function(t){var e=Object(i.p)(t,(function(t){return t[T].test("")}));return Object(i.I)(e,(function(t){return{message:"Token Type: ->"+t.name+"<- static 'PATTERN' must not match an empty string",type:V.EMPTY_MATCH_PATTERN,tokenTypes:[t]}}))}(n))}(s))).concat(function(t){var e=Object(i.p)(t,(function(t){if(!Object(i.w)(t,"GROUP"))return!1;var e=t.GROUP;return e!==$.SKIPPED&&e!==$.NA&&!Object(i.E)(e)}));return Object(i.I)(e,(function(t){return{message:"Token Type: ->"+t.name+"<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String",type:V.INVALID_GROUP_TYPE_FOUND,tokenTypes:[t]}}))}(s))).concat(function(t,e){var n=Object(i.p)(t,(function(t){return void 0!==t.PUSH_MODE&&!Object(i.j)(e,t.PUSH_MODE)}));return Object(i.I)(n,(function(t){return{message:"Token Type: ->"+t.name+"<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->"+t.PUSH_MODE+"<-which does not exist",type:V.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[t]}}))}(s,e))).concat(function(t){var e=[],n=Object(i.O)(t,(function(t,e,n){var r,o=e.PATTERN;return o===$.NA||(Object(i.E)(o)?t.push({str:o,idx:n,tokenType:e}):Object(i.D)(o)&&(r=o,void 0===Object(i.q)([".","\\","[","]","|","^","$","(",")","?","*","+","{"],(function(t){return-1!==r.source.indexOf(t)})))&&t.push({str:o.source,idx:n,tokenType:e})),t}),[]);return Object(i.u)(t,(function(t,r){Object(i.u)(n,(function(n){var o=n.str,a=n.idx,s=n.tokenType;if(r<a&&function(t,e){if(Object(i.D)(e)){var n=e.exec(t);return null!==n&&0===n.index}if(Object(i.B)(e))return e(t,0,[],{});if(Object(i.w)(e,"exec"))return e.exec(t,0,[],{});if("string"==typeof e)return e===t;throw Error("non exhaustive match")}(o,t.PATTERN)){var c="Token: ->"+s.name+"<- can never be matched.\nBecause it appears AFTER the Token Type ->"+t.name+"<-in the lexer's definition.\nSee https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#UNREACHABLE";e.push({message:c,type:V.UNREACHABLE_PATTERN,tokenTypes:[t,s]})}}))})),e}(s))}var S=/[^\\][\$]/;var N=/[^\\[][\^]|^\^/;function x(t){var e=t.ignoreCase?"i":"";return new RegExp("^(?:"+t.source+")",e)}function A(t){var e=t.ignoreCase?"iy":"y";return new RegExp(""+t.source,e)}function R(t,e,n){var r=[],o=!1,a=Object(i.i)(Object(i.t)(Object(i.J)(t.modes,(function(t){return t})))),s=Object(i.P)(a,(function(t){return t[T]===$.NA})),c=w(n);return e&&Object(i.u)(s,(function(t){var e=L(t,c);if(!1!==e){var n={message:function(t,e){if(e.issue===V.IDENTIFY_TERMINATOR)return"Warning: unable to identify line terminator usage in pattern.\n\tThe problem is in the <"+t.name+"> Token Type\n\t Root cause: "+e.errMsg+".\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR";if(e.issue===V.CUSTOM_LINE_BREAK)return"Warning: A Custom Token Pattern should specify the <line_breaks> option.\n\tThe problem is in the <"+t.name+"> Token Type\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK";throw Error("non exhaustive match")}(t,e),type:e.issue,tokenType:t};r.push(n)}else Object(i.w)(t,"LINE_BREAKS")?!0===t.LINE_BREAKS&&(o=!0):g(c,t.PATTERN)&&(o=!0)})),e&&!o&&r.push({message:"Warning: No LINE_BREAKS Found.\n\tThis Lexer has been defined to track line and column information,\n\tBut none of the Token Types can be identified as matching a line terminator.\n\tSee https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#LINE_BREAKS \n\tfor details.",type:V.NO_LINE_BREAKS_FLAGS}),r}function C(t){var e=t.PATTERN;if(Object(i.D)(e))return!1;if(Object(i.B)(e))return!0;if(Object(i.w)(e,"exec"))return!0;if(Object(i.E)(e))return!1;throw Error("non exhaustive match")}function I(t){return!(!Object(i.E)(t)||1!==t.length)&&t.charCodeAt(0)}var k={test:function(t){for(var e=t.length,n=this.lastIndex;n<e;n++){var r=t.charCodeAt(n);if(10===r)return this.lastIndex=n+1,!0;if(13===r)return 10===t.charCodeAt(n+1)?this.lastIndex=n+2:this.lastIndex=n+1,!0}return!1},lastIndex:0};function L(t,e){if(Object(i.w)(t,"LINE_BREAKS"))return!1;if(Object(i.D)(t.PATTERN)){try{g(e,t.PATTERN)}catch(t){return{issue:V.IDENTIFY_TERMINATOR,errMsg:t.message}}return!1}if(Object(i.E)(t.PATTERN))return!1;if(C(t))return{issue:V.CUSTOM_LINE_BREAK};throw Error("non exhaustive match")}function w(t){return Object(i.I)(t,(function(t){return Object(i.E)(t)&&t.length>0?t.charCodeAt(0):t}))}function _(t,e,n){void 0===t[e]?t[e]=[n]:t[e].push(n)}var j=256;function M(t){return t<j?t:P[t]}var P=[];function D(t,e){var n=t.tokenTypeIdx;return n===e.tokenTypeIdx||!0===e.isParent&&!0===e.categoryMatchesMap[n]}function U(t,e){return t.tokenTypeIdx===e.tokenTypeIdx}var F=1,B={};function H(t){var e=function(t){var e=Object(i.g)(t),n=t,r=!0;for(;r;){n=Object(i.i)(Object(i.t)(Object(i.I)(n,(function(t){return t.CATEGORIES}))));var o=Object(i.l)(n,e);e=e.concat(o),Object(i.A)(o)?r=!1:n=o}return e}(t);!function(t){Object(i.u)(t,(function(t){var e;W(t)||(B[F]=t,t.tokenTypeIdx=F++),G(t)&&!Object(i.y)(t.CATEGORIES)&&(t.CATEGORIES=[t.CATEGORIES]),G(t)||(t.CATEGORIES=[]),e=t,Object(i.w)(e,"categoryMatches")||(t.categoryMatches=[]),function(t){return Object(i.w)(t,"categoryMatchesMap")}(t)||(t.categoryMatchesMap={})}))}(e),function(t){Object(i.u)(t,(function(t){!function t(e,n){Object(i.u)(e,(function(t){n.categoryMatchesMap[t.tokenTypeIdx]=!0})),Object(i.u)(n.CATEGORIES,(function(r){var o=e.concat(n);Object(i.j)(o,r)||t(o,r)}))}([],t)}))}(e),function(t){Object(i.u)(t,(function(t){t.categoryMatches=[],Object(i.u)(t.categoryMatchesMap,(function(e,n){t.categoryMatches.push(B[n].tokenTypeIdx)}))}))}(e),Object(i.u)(e,(function(t){t.isParent=t.categoryMatches.length>0}))}function W(t){return Object(i.w)(t,"tokenTypeIdx")}function G(t){return Object(i.w)(t,"CATEGORIES")}function q(t){return Object(i.w)(t,"tokenTypeIdx")}var V,K={buildUnableToPopLexerModeMessage:function(t){return"Unable to pop Lexer Mode after encountering Token ->"+t.image+"<- The Mode Stack is empty"},buildUnexpectedCharactersMessage:function(t,e,n,r,i){return"unexpected character: ->"+t.charAt(e)+"<- at offset: "+e+", skipped "+n+" characters."}};!function(t){t[t.MISSING_PATTERN=0]="MISSING_PATTERN",t[t.INVALID_PATTERN=1]="INVALID_PATTERN",t[t.EOI_ANCHOR_FOUND=2]="EOI_ANCHOR_FOUND",t[t.UNSUPPORTED_FLAGS_FOUND=3]="UNSUPPORTED_FLAGS_FOUND",t[t.DUPLICATE_PATTERNS_FOUND=4]="DUPLICATE_PATTERNS_FOUND",t[t.INVALID_GROUP_TYPE_FOUND=5]="INVALID_GROUP_TYPE_FOUND",t[t.PUSH_MODE_DOES_NOT_EXIST=6]="PUSH_MODE_DOES_NOT_EXIST",t[t.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]="MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE",t[t.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]="MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY",t[t.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]="MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST",t[t.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]="LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED",t[t.SOI_ANCHOR_FOUND=11]="SOI_ANCHOR_FOUND",t[t.EMPTY_MATCH_PATTERN=12]="EMPTY_MATCH_PATTERN",t[t.NO_LINE_BREAKS_FLAGS=13]="NO_LINE_BREAKS_FLAGS",t[t.UNREACHABLE_PATTERN=14]="UNREACHABLE_PATTERN",t[t.IDENTIFY_TERMINATOR=15]="IDENTIFY_TERMINATOR",t[t.CUSTOM_LINE_BREAK=16]="CUSTOM_LINE_BREAK"}(V||(V={}));var z={deferDefinitionErrorsHandling:!1,positionTracking:"full",lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:["\n","\r"],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:K,traceInitPerf:!1,skipValidations:!1};Object.freeze(z);var $=function(){function t(t,e){var n=this;if(void 0===e&&(e=z),this.lexerDefinition=t,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.config=void 0,this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},"boolean"==typeof e)throw Error("The second argument to the Lexer constructor is now an ILexerConfig Object.\na boolean 2nd argument is no longer supported");this.config=Object(i.K)(z,e);var r=this.config.traceInitPerf;!0===r?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):"number"==typeof r&&(this.traceInitMaxIdent=r,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT("Lexer Constructor",(function(){var r,o=!0;n.TRACE_INIT("Lexer Config handling",(function(){if(n.config.lineTerminatorsPattern===z.lineTerminatorsPattern)n.config.lineTerminatorsPattern=k;else if(n.config.lineTerminatorCharacters===z.lineTerminatorCharacters)throw Error("Error: Missing <lineTerminatorCharacters> property on the Lexer config.\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS");if(e.safeMode&&e.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');n.trackStartLines=/full|onlyStart/i.test(n.config.positionTracking),n.trackEndLines=/full/i.test(n.config.positionTracking),Object(i.y)(t)?((r={modes:{}}).modes.defaultMode=Object(i.g)(t),r.defaultMode="defaultMode"):(o=!1,r=Object(i.h)(t))})),!1===n.config.skipValidations&&(n.TRACE_INIT("performRuntimeChecks",(function(){n.lexerDefinitionErrors=n.lexerDefinitionErrors.concat(function(t,e,n){var r=[];return Object(i.w)(t,"defaultMode")||r.push({message:"A MultiMode Lexer cannot be initialized without a <defaultMode> property in its definition\n",type:V.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),Object(i.w)(t,"modes")||r.push({message:"A MultiMode Lexer cannot be initialized without a <modes> property in its definition\n",type:V.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),Object(i.w)(t,"modes")&&Object(i.w)(t,"defaultMode")&&!Object(i.w)(t.modes,t.defaultMode)&&r.push({message:"A MultiMode Lexer cannot be initialized with a defaultMode: <"+t.defaultMode+">which does not exist\n",type:V.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),Object(i.w)(t,"modes")&&Object(i.u)(t.modes,(function(t,e){Object(i.u)(t,(function(t,n){Object(i.F)(t)&&r.push({message:"A Lexer cannot be initialized using an undefined Token Type. Mode:<"+e+"> at index: <"+n+">\n",type:V.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED})}))})),r}(r,n.trackStartLines,n.config.lineTerminatorCharacters))})),n.TRACE_INIT("performWarningRuntimeChecks",(function(){n.lexerDefinitionWarning=n.lexerDefinitionWarning.concat(R(r,n.trackStartLines,n.config.lineTerminatorCharacters))}))),r.modes=r.modes?r.modes:{},Object(i.u)(r.modes,(function(t,e){r.modes[e]=Object(i.P)(t,(function(t){return Object(i.F)(t)}))}));var s=Object(i.G)(r.modes);if(Object(i.u)(r.modes,(function(t,r){n.TRACE_INIT("Mode: <"+r+"> processing",(function(){var o;(n.modes.push(r),!1===n.config.skipValidations&&n.TRACE_INIT("validatePatterns",(function(){n.lexerDefinitionErrors=n.lexerDefinitionErrors.concat(b(t,s))})),Object(i.A)(n.lexerDefinitionErrors))&&(H(t),n.TRACE_INIT("analyzeTokenTypes",(function(){o=E(t,{lineTerminatorCharacters:n.config.lineTerminatorCharacters,positionTracking:e.positionTracking,ensureOptimizations:e.ensureOptimizations,safeMode:e.safeMode,tracer:n.TRACE_INIT.bind(n)})})),n.patternIdxToConfig[r]=o.patternIdxToConfig,n.charCodeToPatternIdxToConfig[r]=o.charCodeToPatternIdxToConfig,n.emptyGroups=Object(i.K)(n.emptyGroups,o.emptyGroups),n.hasCustom=o.hasCustom||n.hasCustom,n.canModeBeOptimized[r]=o.canBeOptimized)}))})),n.defaultMode=r.defaultMode,!Object(i.A)(n.lexerDefinitionErrors)&&!n.config.deferDefinitionErrorsHandling){var c=Object(i.I)(n.lexerDefinitionErrors,(function(t){return t.message})).join("-----------------------\n");throw new Error("Errors detected in definition of Lexer:\n"+c)}Object(i.u)(n.lexerDefinitionWarning,(function(t){Object(i.d)(t.message)})),n.TRACE_INIT("Choosing sub-methods implementations",(function(){if(O?(n.chopInput=i.a,n.match=n.matchWithTest):(n.updateLastIndex=i.b,n.match=n.matchWithExec),o&&(n.handleModes=i.b),!1===n.trackStartLines&&(n.computeNewColumn=i.a),!1===n.trackEndLines&&(n.updateTokenEndLineColumnLocation=i.b),/full/i.test(n.config.positionTracking))n.createTokenInstance=n.createFullToken;else if(/onlyStart/i.test(n.config.positionTracking))n.createTokenInstance=n.createStartOnlyToken;else{if(!/onlyOffset/i.test(n.config.positionTracking))throw Error('Invalid <positionTracking> config option: "'+n.config.positionTracking+'"');n.createTokenInstance=n.createOffsetOnlyToken}n.hasCustom?(n.addToken=n.addTokenUsingPush,n.handlePayload=n.handlePayloadWithCustom):(n.addToken=n.addTokenUsingMemberAccess,n.handlePayload=n.handlePayloadNoCustom)})),n.TRACE_INIT("Failed Optimization Warnings",(function(){var t=Object(i.O)(n.canModeBeOptimized,(function(t,e,n){return!1===e&&t.push(n),t}),[]);if(e.ensureOptimizations&&!Object(i.A)(t))throw Error("Lexer Modes: < "+t.join(", ")+' > cannot be optimized.\n\t Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode.\n\t Or inspect the console log for details on how to resolve these issues.')})),n.TRACE_INIT("clearRegExpParserCache",(function(){a={}})),n.TRACE_INIT("toFastProperties",(function(){Object(i.S)(n)}))}))}return t.prototype.tokenize=function(t,e){if(void 0===e&&(e=this.defaultMode),!Object(i.A)(this.lexerDefinitionErrors)){var n=Object(i.I)(this.lexerDefinitionErrors,(function(t){return t.message})).join("-----------------------\n");throw new Error("Unable to Tokenize because Errors detected in definition of Lexer:\n"+n)}return this.tokenizeInternal(t,e)},t.prototype.tokenizeInternal=function(t,e){var n,r,o,a,s,c,u,l,f,p,h,d,m,v,g,y,T,O=this,E=t,b=E.length,S=0,N=0,x=this.hasCustom?0:Math.floor(t.length/10),A=new Array(x),R=[],C=this.trackStartLines?1:void 0,I=this.trackStartLines?1:void 0,k=(g=this.emptyGroups,y={},T=Object(i.G)(g),Object(i.u)(T,(function(t){var e=g[t];if(!Object(i.y)(e))throw Error("non exhaustive match");y[t]=[]})),y),L=this.trackStartLines,w=this.config.lineTerminatorsPattern,_=0,j=[],P=[],D=[],U=[];Object.freeze(U);var F=void 0;function B(){return j}function H(t){var e=M(t),n=P[e];return void 0===n?U:n}var W,G=function(t){if(1===D.length&&void 0===t.tokenType.PUSH_MODE){var e=O.config.errorMessageProvider.buildUnableToPopLexerModeMessage(t);R.push({offset:t.startOffset,line:void 0!==t.startLine?t.startLine:void 0,column:void 0!==t.startColumn?t.startColumn:void 0,length:t.image.length,message:e})}else{D.pop();var n=Object(i.H)(D);j=O.patternIdxToConfig[n],P=O.charCodeToPatternIdxToConfig[n],_=j.length;var r=O.canModeBeOptimized[n]&&!1===O.config.safeMode;F=P&&r?H:B}};function q(t){D.push(t),P=this.charCodeToPatternIdxToConfig[t],j=this.patternIdxToConfig[t],_=j.length,_=j.length;var e=this.canModeBeOptimized[t]&&!1===this.config.safeMode;F=P&&e?H:B}for(q.call(this,e);S<b;){s=null;var V=E.charCodeAt(S),K=F(V),z=K.length;for(n=0;n<z;n++){var $=(W=K[n]).pattern;if(c=null,!1!==(it=W.short)?V===it&&(s=$):!0===W.isCustom?null!==(v=$.exec(E,S,A,k))?(s=v[0],void 0!==v.payload&&(c=v.payload)):s=null:(this.updateLastIndex($,S),s=this.match($,t,S)),null!==s){if(void 0!==(a=W.longerAlt)){var Y=j[a],X=Y.pattern;u=null,!0===Y.isCustom?null!==(v=X.exec(E,S,A,k))?(o=v[0],void 0!==v.payload&&(u=v.payload)):o=null:(this.updateLastIndex(X,S),o=this.match(X,t,S)),o&&o.length>s.length&&(s=o,c=u,W=Y)}break}}if(null!==s){if(l=s.length,void 0!==(f=W.group)&&(p=W.tokenTypeIdx,h=this.createTokenInstance(s,S,p,W.tokenType,C,I,l),this.handlePayload(h,c),!1===f?N=this.addToken(A,N,h):k[f].push(h)),t=this.chopInput(t,l),S+=l,I=this.computeNewColumn(I,l),!0===L&&!0===W.canLineTerminator){var J=0,Q=void 0,Z=void 0;w.lastIndex=0;do{!0===(Q=w.test(s))&&(Z=w.lastIndex-1,J++)}while(!0===Q);0!==J&&(C+=J,I=l-Z,this.updateTokenEndLineColumnLocation(h,f,Z,J,C,I,l))}this.handleModes(W,G,q,h)}else{for(var tt=S,et=C,nt=I,rt=!1;!rt&&S<b;)for(E.charCodeAt(S),t=this.chopInput(t,1),S++,r=0;r<_;r++){var it,ot=j[r];$=ot.pattern;if(!1!==(it=ot.short)?E.charCodeAt(S)===it&&(rt=!0):!0===ot.isCustom?rt=null!==$.exec(E,S,A,k):(this.updateLastIndex($,S),rt=null!==$.exec(t)),!0===rt)break}d=S-tt,m=this.config.errorMessageProvider.buildUnexpectedCharactersMessage(E,tt,d,et,nt),R.push({offset:tt,line:et,column:nt,length:d,message:m})}}return this.hasCustom||(A.length=N),{tokens:A,groups:k,errors:R}},t.prototype.handleModes=function(t,e,n,r){if(!0===t.pop){var i=t.push;e(r),void 0!==i&&n.call(this,i)}else void 0!==t.push&&n.call(this,t.push)},t.prototype.chopInput=function(t,e){return t.substring(e)},t.prototype.updateLastIndex=function(t,e){t.lastIndex=e},t.prototype.updateTokenEndLineColumnLocation=function(t,e,n,r,i,o,a){var s,c;void 0!==e&&(c=(s=n===a-1)?-1:0,1===r&&!0===s||(t.endLine=i+c,t.endColumn=o-1-c))},t.prototype.computeNewColumn=function(t,e){return t+e},t.prototype.createTokenInstance=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return null},t.prototype.createOffsetOnlyToken=function(t,e,n,r){return{image:t,startOffset:e,tokenTypeIdx:n,tokenType:r}},t.prototype.createStartOnlyToken=function(t,e,n,r,i,o){return{image:t,startOffset:e,startLine:i,startColumn:o,tokenTypeIdx:n,tokenType:r}},t.prototype.createFullToken=function(t,e,n,r,i,o,a){return{image:t,startOffset:e,endOffset:e+a-1,startLine:i,endLine:i,startColumn:o,endColumn:o+a-1,tokenTypeIdx:n,tokenType:r}},t.prototype.addToken=function(t,e,n){return 666},t.prototype.addTokenUsingPush=function(t,e,n){return t.push(n),e},t.prototype.addTokenUsingMemberAccess=function(t,e,n){return t[e]=n,++e},t.prototype.handlePayload=function(t,e){},t.prototype.handlePayloadNoCustom=function(t,e){},t.prototype.handlePayloadWithCustom=function(t,e){null!==e&&(t.payload=e)},t.prototype.match=function(t,e,n){return null},t.prototype.matchWithTest=function(t,e,n){return!0===t.test(e)?e.substring(n,t.lastIndex):null},t.prototype.matchWithExec=function(t,e){var n=t.exec(e);return null!==n?n[0]:n},t.prototype.TRACE_INIT=function(t,e){if(!0===this.traceInitPerf){this.traceInitIndent++;var n=new Array(this.traceInitIndent+1).join("\t");this.traceInitIndent<this.traceInitMaxIdent&&console.log(n+"--\x3e <"+t+">");var r=Object(i.R)(e),o=r.time,a=r.value,s=o>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&s(n+"<-- <"+t+"> time: "+o+"ms"),this.traceInitIndent--,a}return e()},t.SKIPPED="This marks a skipped Token pattern, this means each token identified by it willbe consumed and then thrown into oblivion, this can be used to for example to completely ignore whitespace.",t.NA=/NOT_APPLICABLE/,t}();function Y(t){return J(t)?t.LABEL:t.name}function X(t){return t.name}function J(t){return Object(i.E)(t.LABEL)&&""!==t.LABEL}function Q(t){return function(t){var e=t.pattern,n={};n.name=t.name,Object(i.F)(e)||(n.PATTERN=e);if(Object(i.w)(t,"parent"))throw"The parent property is no longer supported.\nSee: https://github.com/SAP/chevrotain/issues/564#issuecomment-349062346 for details.";Object(i.w)(t,"categories")&&(n.CATEGORIES=t.categories);H([n]),Object(i.w)(t,"label")&&(n.LABEL=t.label);Object(i.w)(t,"group")&&(n.GROUP=t.group);Object(i.w)(t,"pop_mode")&&(n.POP_MODE=t.pop_mode);Object(i.w)(t,"push_mode")&&(n.PUSH_MODE=t.push_mode);Object(i.w)(t,"longer_alt")&&(n.LONGER_ALT=t.longer_alt);Object(i.w)(t,"line_breaks")&&(n.LINE_BREAKS=t.line_breaks);Object(i.w)(t,"start_chars_hint")&&(n.START_CHARS_HINT=t.start_chars_hint);return n}(t)}var Z=Q({name:"EOF",pattern:$.NA});function tt(t,e,n,r,i,o,a,s){return{image:e,startOffset:n,endOffset:r,startLine:i,endLine:o,startColumn:a,endColumn:s,tokenTypeIdx:t.tokenTypeIdx,tokenType:t}}function et(t,e){return D(t,e)}H([Z]);var nt=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),rt=function(){function t(t){this.definition=t}return t.prototype.accept=function(t){t.visit(this),Object(i.u)(this.definition,(function(e){e.accept(t)}))},t}(),it=function(t){function e(e){var n=t.call(this,[])||this;return n.idx=1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),Object.defineProperty(e.prototype,"definition",{get:function(){return void 0!==this.referencedRule?this.referencedRule.definition:[]},set:function(t){},enumerable:!1,configurable:!0}),e.prototype.accept=function(t){t.visit(this)},e}(rt),ot=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.orgText="",Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),at=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.ignoreAmbiguities=!1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),st=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.idx=1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),ct=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.idx=1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),ut=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.idx=1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),lt=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.idx=1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),ft=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.idx=1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),pt=function(t){function e(e){var n=t.call(this,e.definition)||this;return n.idx=1,n.ignoreAmbiguities=!1,n.hasPredicates=!1,Object(i.f)(n,Object(i.N)(e,(function(t){return void 0!==t}))),n}return nt(e,t),e}(rt),ht=function(){function t(t){this.idx=1,Object(i.f)(this,Object(i.N)(t,(function(t){return void 0!==t})))}return t.prototype.accept=function(t){t.visit(this)},t}();function dt(t){return Object(i.I)(t,mt)}function mt(t){function e(t){return Object(i.I)(t,mt)}if(t instanceof it)return{type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};if(t instanceof at)return{type:"Alternative",definition:e(t.definition)};if(t instanceof st)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof ct)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof ut)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:mt(new ht({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof ft)return{type:"RepetitionWithSeparator",idx:t.idx,separator:mt(new ht({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof lt)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof pt)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof ht){var n={type:"Terminal",name:t.terminalType.name,label:Y(t.terminalType),idx:t.idx},r=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(n.pattern=Object(i.D)(r)?r.source:r),n}if(t instanceof ot)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}var vt=function(){function t(){}return t.prototype.walk=function(t,e){var n=this;void 0===e&&(e=[]),Object(i.u)(t.definition,(function(r,o){var a=Object(i.m)(t.definition,o+1);if(r instanceof it)n.walkProdRef(r,a,e);else if(r instanceof ht)n.walkTerminal(r,a,e);else if(r instanceof at)n.walkFlat(r,a,e);else if(r instanceof st)n.walkOption(r,a,e);else if(r instanceof ct)n.walkAtLeastOne(r,a,e);else if(r instanceof ut)n.walkAtLeastOneSep(r,a,e);else if(r instanceof ft)n.walkManySep(r,a,e);else if(r instanceof lt)n.walkMany(r,a,e);else{if(!(r instanceof pt))throw Error("non exhaustive match");n.walkOr(r,a,e)}}))},t.prototype.walkTerminal=function(t,e,n){},t.prototype.walkProdRef=function(t,e,n){},t.prototype.walkFlat=function(t,e,n){var r=e.concat(n);this.walk(t,r)},t.prototype.walkOption=function(t,e,n){var r=e.concat(n);this.walk(t,r)},t.prototype.walkAtLeastOne=function(t,e,n){var r=[new st({definition:t.definition})].concat(e,n);this.walk(t,r)},t.prototype.walkAtLeastOneSep=function(t,e,n){var r=gt(t,e,n);this.walk(t,r)},t.prototype.walkMany=function(t,e,n){var r=[new st({definition:t.definition})].concat(e,n);this.walk(t,r)},t.prototype.walkManySep=function(t,e,n){var r=gt(t,e,n);this.walk(t,r)},t.prototype.walkOr=function(t,e,n){var r=this,o=e.concat(n);Object(i.u)(t.definition,(function(t){var e=new at({definition:[t]});r.walk(e,o)}))},t}();function gt(t,e,n){return[new st({definition:[new ht({terminalType:t.separator})].concat(t.definition)})].concat(e,n)}var yt=function(){function t(){}return t.prototype.visit=function(t){var e=t;switch(e.constructor){case it:return this.visitNonTerminal(e);case at:return this.visitAlternative(e);case st:return this.visitOption(e);case ct:return this.visitRepetitionMandatory(e);case ut:return this.visitRepetitionMandatoryWithSeparator(e);case ft:return this.visitRepetitionWithSeparator(e);case lt:return this.visitRepetition(e);case pt:return this.visitAlternation(e);case ht:return this.visitTerminal(e);case ot:return this.visitRule(e);default:throw Error("non exhaustive match")}},t.prototype.visitNonTerminal=function(t){},t.prototype.visitAlternative=function(t){},t.prototype.visitOption=function(t){},t.prototype.visitRepetition=function(t){},t.prototype.visitRepetitionMandatory=function(t){},t.prototype.visitRepetitionMandatoryWithSeparator=function(t){},t.prototype.visitRepetitionWithSeparator=function(t){},t.prototype.visitAlternation=function(t){},t.prototype.visitTerminal=function(t){},t.prototype.visitRule=function(t){},t}(),Tt=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();function Ot(t,e){return void 0===e&&(e=[]),!!(t instanceof st||t instanceof lt||t instanceof ft)||(t instanceof pt?Object(i.Q)(t.definition,(function(t){return Ot(t,e)})):!(t instanceof it&&Object(i.j)(e,t))&&(t instanceof rt&&(t instanceof it&&e.push(t),Object(i.o)(t.definition,(function(t){return Ot(t,e)})))))}function Et(t){if(t instanceof it)return"SUBRULE";if(t instanceof st)return"OPTION";if(t instanceof pt)return"OR";if(t instanceof ct)return"AT_LEAST_ONE";if(t instanceof ut)return"AT_LEAST_ONE_SEP";if(t instanceof ft)return"MANY_SEP";if(t instanceof lt)return"MANY";if(t instanceof ht)return"CONSUME";throw Error("non exhaustive match")}var bt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.separator="-",e.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]},e}return Tt(e,t),e.prototype.reset=function(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}},e.prototype.visitTerminal=function(t){var e=t.terminalType.name+this.separator+"Terminal";Object(i.w)(this.dslMethods,e)||(this.dslMethods[e]=[]),this.dslMethods[e].push(t)},e.prototype.visitNonTerminal=function(t){var e=t.nonTerminalName+this.separator+"Terminal";Object(i.w)(this.dslMethods,e)||(this.dslMethods[e]=[]),this.dslMethods[e].push(t)},e.prototype.visitOption=function(t){this.dslMethods.option.push(t)},e.prototype.visitRepetitionWithSeparator=function(t){this.dslMethods.repetitionWithSeparator.push(t)},e.prototype.visitRepetitionMandatory=function(t){this.dslMethods.repetitionMandatory.push(t)},e.prototype.visitRepetitionMandatoryWithSeparator=function(t){this.dslMethods.repetitionMandatoryWithSeparator.push(t)},e.prototype.visitRepetition=function(t){this.dslMethods.repetition.push(t)},e.prototype.visitAlternation=function(t){this.dslMethods.alternation.push(t)},e}(yt),St=new bt;function Nt(t){if(t instanceof it)return Nt(t.referencedRule);if(t instanceof ht)return[t.terminalType];if(function(t){return t instanceof at||t instanceof st||t instanceof lt||t instanceof ct||t instanceof ut||t instanceof ft||t instanceof ht||t instanceof ot}(t))return function(t){var e,n=[],r=t.definition,o=0,a=r.length>o,s=!0;for(;a&&s;)e=r[o],s=Ot(e),n=n.concat(Nt(e)),o+=1,a=r.length>o;return Object(i.T)(n)}(t);if(function(t){return t instanceof pt}(t))return function(t){var e=Object(i.I)(t.definition,(function(t){return Nt(t)}));return Object(i.T)(Object(i.t)(e))}(t);throw Error("non exhaustive match")}var xt="_~IN~_",At=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Rt=function(t){function e(e){var n=t.call(this)||this;return n.topProd=e,n.follows={},n}return At(e,t),e.prototype.startWalking=function(){return this.walk(this.topProd),this.follows},e.prototype.walkTerminal=function(t,e,n){},e.prototype.walkProdRef=function(t,e,n){var r,i,o=(r=t.referencedRule,i=t.idx,r.name+i+xt+this.topProd.name),a=e.concat(n),s=Nt(new at({definition:a}));this.follows[o]=s},e}(vt);var Ct={buildMismatchTokenMessage:function(t){var e=t.expected,n=t.actual;t.previous,t.ruleName;return"Expecting "+(J(e)?"--\x3e "+Y(e)+" <--":"token of type --\x3e "+e.name+" <--")+" but found --\x3e '"+n.image+"' <--"},buildNotAllInputParsedMessage:function(t){var e=t.firstRedundant;t.ruleName;return"Redundant input, expecting EOF but found: "+e.image},buildNoViableAltMessage:function(t){var e=t.expectedPathsPerAlt,n=t.actual,r=(t.previous,t.customUserDescription),o=(t.ruleName,"\nbut found: '"+Object(i.s)(n).image+"'");if(r)return"Expecting: "+r+o;var a=Object(i.O)(e,(function(t,e){return t.concat(e)}),[]),s=Object(i.I)(a,(function(t){return"["+Object(i.I)(t,(function(t){return Y(t)})).join(", ")+"]"}));return"Expecting: "+("one of these possible Token sequences:\n"+Object(i.I)(s,(function(t,e){return" "+(e+1)+". "+t})).join("\n"))+o},buildEarlyExitMessage:function(t){var e=t.expectedIterationPaths,n=t.actual,r=t.customUserDescription,o=(t.ruleName,"\nbut found: '"+Object(i.s)(n).image+"'");return r?"Expecting: "+r+o:"Expecting: "+("expecting at least one iteration which starts with one of these possible Token sequences::\n <"+Object(i.I)(e,(function(t){return"["+Object(i.I)(t,(function(t){return Y(t)})).join(",")+"]"})).join(" ,")+">")+o}};Object.freeze(Ct);var It={buildRuleNotFoundError:function(t,e){return"Invalid grammar, reference to a rule which is not defined: ->"+e.nonTerminalName+"<-\ninside top level rule: ->"+t.name+"<-"}},kt={buildDuplicateFoundError:function(t,e){var n,r=t.name,o=Object(i.s)(e),a=o.idx,s=Et(o),c=(n=o)instanceof ht?n.terminalType.name:n instanceof it?n.nonTerminalName:"",u="->"+s+(a>0?a:"")+"<- "+(c?"with argument: ->"+c+"<-":"")+"\n appears more than once ("+e.length+" times) in the top level rule: ->"+r+"<-. \n For further details see: https://sap.github.io/chevrotain/docs/FAQ.html#NUMERICAL_SUFFIXES \n ";return u=(u=u.replace(/[ \t]+/g," ")).replace(/\s\s+/g,"\n")},buildNamespaceConflictError:function(t){return"Namespace conflict found in grammar.\nThe grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <"+t.name+">.\nTo resolve this make sure each Terminal and Non-Terminal names are unique\nThis is easy to accomplish by using the convention that Terminal names start with an uppercase letter\nand Non-Terminal names start with a lower case letter."},buildAlternationPrefixAmbiguityError:function(t){var e=Object(i.I)(t.prefixPath,(function(t){return Y(t)})).join(", "),n=0===t.alternation.idx?"":t.alternation.idx;return"Ambiguous alternatives: <"+t.ambiguityIndices.join(" ,")+"> due to common lookahead prefix\nin <OR"+n+"> inside <"+t.topLevelRule.name+"> Rule,\n<"+e+"> may appears as a prefix path in all these alternatives.\nSee: https://sap.github.io/chevrotain/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX\nFor Further details."},buildAlternationAmbiguityError:function(t){var e=Object(i.I)(t.prefixPath,(function(t){return Y(t)})).join(", "),n=0===t.alternation.idx?"":t.alternation.idx,r="Ambiguous Alternatives Detected: <"+t.ambiguityIndices.join(" ,")+"> in <OR"+n+"> inside <"+t.topLevelRule.name+"> Rule,\n<"+e+"> may appears as a prefix path in all these alternatives.\n";return r+="See: https://sap.github.io/chevrotain/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES\nFor Further details."},buildEmptyRepetitionError:function(t){var e=Et(t.repetition);return 0!==t.repetition.idx&&(e+=t.repetition.idx),"The repetition <"+e+"> within Rule <"+t.topLevelRule.name+"> can never consume any tokens.\nThis could lead to an infinite loop."},buildTokenNameError:function(t){return"Invalid Grammar Token name: ->"+t.tokenType.name+"<- it must match the pattern: ->"+t.expectedPattern.toString()+"<-"},buildEmptyAlternationError:function(t){return"Ambiguous empty alternative: <"+(t.emptyChoiceIdx+1)+"> in <OR"+t.alternation.idx+"> inside <"+t.topLevelRule.name+"> Rule.\nOnly the last alternative may be an empty alternative."},buildTooManyAlternativesError:function(t){return"An Alternation cannot have more than 256 alternatives:\n<OR"+t.alternation.idx+"> inside <"+t.topLevelRule.name+"> Rule.\n has "+(t.alternation.definition.length+1)+" alternatives."},buildLeftRecursionError:function(t){var e=t.topLevelRule.name;return"Left Recursion found in grammar.\nrule: <"+e+"> can be invoked from itself (directly or indirectly)\nwithout consuming any Tokens. The grammar path that causes this is: \n "+(e+" --\x3e "+i.I(t.leftRecursionPath,(function(t){return t.name})).concat([e]).join(" --\x3e "))+"\n To fix this refactor your grammar to remove the left recursion.\nsee: https://en.wikipedia.org/wiki/LL_parser#Left_Factoring."},buildInvalidRuleNameError:function(t){return"Invalid grammar rule name: ->"+t.topLevelRule.name+"<- it must match the pattern: ->"+t.expectedPattern.toString()+"<-"},buildDuplicateRuleNameError:function(t){return"Duplicate definition, rule: ->"+(t.topLevelRule instanceof ot?t.topLevelRule.name:t.topLevelRule)+"<- is already defined in the grammar: ->"+t.grammarName+"<-"}},Lt=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();var wt=function(t){function e(e,n){var r=t.call(this)||this;return r.nameToTopRule=e,r.errMsgProvider=n,r.errors=[],r}return Lt(e,t),e.prototype.resolveRefs=function(){var t=this;Object(i.u)(Object(i.U)(this.nameToTopRule),(function(e){t.currTopLevel=e,e.accept(t)}))},e.prototype.visitNonTerminal=function(t){var e=this.nameToTopRule[t.nonTerminalName];if(e)t.referencedRule=e;else{var n=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,t);this.errors.push({message:n,type:Qe.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:t.nonTerminalName})}},e}(yt),_t=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),jt=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.path=n,r.nextTerminalName="",r.nextTerminalOccurrence=0,r.nextTerminalName=r.path.lastTok.name,r.nextTerminalOccurrence=r.path.lastTokOccurrence,r}return _t(e,t),e.prototype.walkTerminal=function(t,e,n){if(this.isAtEndOfPath&&t.terminalType.name===this.nextTerminalName&&t.idx===this.nextTerminalOccurrence&&!this.found){var r=e.concat(n),i=new at({definition:r});this.possibleTokTypes=Nt(i),this.found=!0}},e}(function(t){function e(e,n){var r=t.call(this)||this;return r.topProd=e,r.path=n,r.possibleTokTypes=[],r.nextProductionName="",r.nextProductionOccurrence=0,r.found=!1,r.isAtEndOfPath=!1,r}return _t(e,t),e.prototype.startWalking=function(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error("The path does not start with the walker's top Rule!");return this.ruleStack=Object(i.g)(this.path.ruleStack).reverse(),this.occurrenceStack=Object(i.g)(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes},e.prototype.walk=function(e,n){void 0===n&&(n=[]),this.found||t.prototype.walk.call(this,e,n)},e.prototype.walkProdRef=function(t,e,n){if(t.referencedRule.name===this.nextProductionName&&t.idx===this.nextProductionOccurrence){var r=e.concat(n);this.updateExpectedNext(),this.walk(t.referencedRule,r)}},e.prototype.updateExpectedNext=function(){Object(i.A)(this.ruleStack)?(this.nextProductionName="",this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())},e}(vt)),Mt=function(t){function e(e,n){var r=t.call(this)||this;return r.topRule=e,r.occurrence=n,r.result={token:void 0,occurrence:void 0,isEndOfRule:void 0},r}return _t(e,t),e.prototype.startWalking=function(){return this.walk(this.topRule),this.result},e}(vt),Pt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return _t(e,t),e.prototype.walkMany=function(e,n,r){if(e.idx===this.occurrence){var o=Object(i.s)(n.concat(r));this.result.isEndOfRule=void 0===o,o instanceof ht&&(this.result.token=o.terminalType,this.result.occurrence=o.idx)}else t.prototype.walkMany.call(this,e,n,r)},e}(Mt),Dt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return _t(e,t),e.prototype.walkManySep=function(e,n,r){if(e.idx===this.occurrence){var o=Object(i.s)(n.concat(r));this.result.isEndOfRule=void 0===o,o instanceof ht&&(this.result.token=o.terminalType,this.result.occurrence=o.idx)}else t.prototype.walkManySep.call(this,e,n,r)},e}(Mt),Ut=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return _t(e,t),e.prototype.walkAtLeastOne=function(e,n,r){if(e.idx===this.occurrence){var o=Object(i.s)(n.concat(r));this.result.isEndOfRule=void 0===o,o instanceof ht&&(this.result.token=o.terminalType,this.result.occurrence=o.idx)}else t.prototype.walkAtLeastOne.call(this,e,n,r)},e}(Mt),Ft=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return _t(e,t),e.prototype.walkAtLeastOneSep=function(e,n,r){if(e.idx===this.occurrence){var o=Object(i.s)(n.concat(r));this.result.isEndOfRule=void 0===o,o instanceof ht&&(this.result.token=o.terminalType,this.result.occurrence=o.idx)}else t.prototype.walkAtLeastOneSep.call(this,e,n,r)},e}(Mt);function Bt(t,e,n){void 0===n&&(n=[]),n=Object(i.g)(n);var r=[],o=0;function a(a){var s=Bt(a.concat(Object(i.m)(t,o+1)),e,n);return r.concat(s)}for(;n.length<e&&o<t.length;){var s=t[o];if(s instanceof at)return a(s.definition);if(s instanceof it)return a(s.definition);if(s instanceof st)r=a(s.definition);else{if(s instanceof ct)return a(c=s.definition.concat([new lt({definition:s.definition})]));if(s instanceof ut)return a(c=[new at({definition:s.definition}),new lt({definition:[new ht({terminalType:s.separator})].concat(s.definition)})]);if(s instanceof ft){var c=s.definition.concat([new lt({definition:[new ht({terminalType:s.separator})].concat(s.definition)})]);r=a(c)}else if(s instanceof lt){c=s.definition.concat([new lt({definition:s.definition})]);r=a(c)}else{if(s instanceof pt)return Object(i.u)(s.definition,(function(t){!1===Object(i.A)(t.definition)&&(r=a(t.definition))})),r;if(!(s instanceof ht))throw Error("non exhaustive match");n.push(s.terminalType)}}o++}return r.push({partialPath:n,suffixDef:Object(i.m)(t,o)}),r}function Ht(t,e,n,r){var o=["EXIT_NONE_TERMINAL"],a=!1,s=e.length,c=s-r-1,u=[],l=[];for(l.push({idx:-1,def:t,ruleStack:[],occurrenceStack:[]});!Object(i.A)(l);){var f=l.pop();if("EXIT_ALTERNATIVE"!==f){var p=f.def,h=f.idx,d=f.ruleStack,m=f.occurrenceStack;if(!Object(i.A)(p)){var v=p[0];if("EXIT_NONE_TERMINAL"===v){var g={idx:h,def:Object(i.m)(p),ruleStack:Object(i.n)(d),occurrenceStack:Object(i.n)(m)};l.push(g)}else if(v instanceof ht)if(h<s-1){var y=h+1;if(n(e[y],v.terminalType)){g={idx:y,def:Object(i.m)(p),ruleStack:d,occurrenceStack:m};l.push(g)}}else{if(h!==s-1)throw Error("non exhaustive match");u.push({nextTokenType:v.terminalType,nextTokenOccurrence:v.idx,ruleStack:d,occurrenceStack:m}),a=!0}else if(v instanceof it){var T=Object(i.g)(d);T.push(v.nonTerminalName);var O=Object(i.g)(m);O.push(v.idx);g={idx:h,def:v.definition.concat(o,Object(i.m)(p)),ruleStack:T,occurrenceStack:O};l.push(g)}else if(v instanceof st){var E={idx:h,def:Object(i.m)(p),ruleStack:d,occurrenceStack:m};l.push(E),l.push("EXIT_ALTERNATIVE");var b={idx:h,def:v.definition.concat(Object(i.m)(p)),ruleStack:d,occurrenceStack:m};l.push(b)}else if(v instanceof ct){var S=new lt({definition:v.definition,idx:v.idx});g={idx:h,def:v.definition.concat([S],Object(i.m)(p)),ruleStack:d,occurrenceStack:m};l.push(g)}else if(v instanceof ut){var N=new ht({terminalType:v.separator});S=new lt({definition:[N].concat(v.definition),idx:v.idx}),g={idx:h,def:v.definition.concat([S],Object(i.m)(p)),ruleStack:d,occurrenceStack:m};l.push(g)}else if(v instanceof ft){E={idx:h,def:Object(i.m)(p),ruleStack:d,occurrenceStack:m};l.push(E),l.push("EXIT_ALTERNATIVE");N=new ht({terminalType:v.separator});var x=new lt({definition:[N].concat(v.definition),idx:v.idx});b={idx:h,def:v.definition.concat([x],Object(i.m)(p)),ruleStack:d,occurrenceStack:m};l.push(b)}else if(v instanceof lt){E={idx:h,def:Object(i.m)(p),ruleStack:d,occurrenceStack:m};l.push(E),l.push("EXIT_ALTERNATIVE");x=new lt({definition:v.definition,idx:v.idx}),b={idx:h,def:v.definition.concat([x],Object(i.m)(p)),ruleStack:d,occurrenceStack:m};l.push(b)}else if(v instanceof pt)for(var A=v.definition.length-1;A>=0;A--){var R={idx:h,def:v.definition[A].definition.concat(Object(i.m)(p)),ruleStack:d,occurrenceStack:m};l.push(R),l.push("EXIT_ALTERNATIVE")}else if(v instanceof at)l.push({idx:h,def:v.definition.concat(Object(i.m)(p)),ruleStack:d,occurrenceStack:m});else{if(!(v instanceof ot))throw Error("non exhaustive match");l.push(Wt(v,h,d,m))}}}else a&&Object(i.H)(l).idx<=c&&l.pop()}return u}function Wt(t,e,n,r){var o=Object(i.g)(n);o.push(t.name);var a=Object(i.g)(r);return a.push(1),{idx:e,def:t.definition,ruleStack:o,occurrenceStack:a}}var Gt,qt=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();!function(t){t[t.OPTION=0]="OPTION",t[t.REPETITION=1]="REPETITION",t[t.REPETITION_MANDATORY=2]="REPETITION_MANDATORY",t[t.REPETITION_MANDATORY_WITH_SEPARATOR=3]="REPETITION_MANDATORY_WITH_SEPARATOR",t[t.REPETITION_WITH_SEPARATOR=4]="REPETITION_WITH_SEPARATOR",t[t.ALTERNATION=5]="ALTERNATION"}(Gt||(Gt={}));var Vt=function(t){function e(e,n,r){var i=t.call(this)||this;return i.topProd=e,i.targetOccurrence=n,i.targetProdType=r,i}return qt(e,t),e.prototype.startWalking=function(){return this.walk(this.topProd),this.restDef},e.prototype.checkIsTarget=function(t,e,n,r){return t.idx===this.targetOccurrence&&this.targetProdType===e&&(this.restDef=n.concat(r),!0)},e.prototype.walkOption=function(e,n,r){this.checkIsTarget(e,Gt.OPTION,n,r)||t.prototype.walkOption.call(this,e,n,r)},e.prototype.walkAtLeastOne=function(e,n,r){this.checkIsTarget(e,Gt.REPETITION_MANDATORY,n,r)||t.prototype.walkOption.call(this,e,n,r)},e.prototype.walkAtLeastOneSep=function(e,n,r){this.checkIsTarget(e,Gt.REPETITION_MANDATORY_WITH_SEPARATOR,n,r)||t.prototype.walkOption.call(this,e,n,r)},e.prototype.walkMany=function(e,n,r){this.checkIsTarget(e,Gt.REPETITION,n,r)||t.prototype.walkOption.call(this,e,n,r)},e.prototype.walkManySep=function(e,n,r){this.checkIsTarget(e,Gt.REPETITION_WITH_SEPARATOR,n,r)||t.prototype.walkOption.call(this,e,n,r)},e}(vt),Kt=function(t){function e(e,n,r){var i=t.call(this)||this;return i.targetOccurrence=e,i.targetProdType=n,i.targetRef=r,i.result=[],i}return qt(e,t),e.prototype.checkIsTarget=function(t,e){t.idx!==this.targetOccurrence||this.targetProdType!==e||void 0!==this.targetRef&&t!==this.targetRef||(this.result=t.definition)},e.prototype.visitOption=function(t){this.checkIsTarget(t,Gt.OPTION)},e.prototype.visitRepetition=function(t){this.checkIsTarget(t,Gt.REPETITION)},e.prototype.visitRepetitionMandatory=function(t){this.checkIsTarget(t,Gt.REPETITION_MANDATORY)},e.prototype.visitRepetitionMandatoryWithSeparator=function(t){this.checkIsTarget(t,Gt.REPETITION_MANDATORY_WITH_SEPARATOR)},e.prototype.visitRepetitionWithSeparator=function(t){this.checkIsTarget(t,Gt.REPETITION_WITH_SEPARATOR)},e.prototype.visitAlternation=function(t){this.checkIsTarget(t,Gt.ALTERNATION)},e}(yt);function zt(t){for(var e=new Array(t),n=0;n<t;n++)e[n]=[];return e}function $t(t){for(var e=[""],n=0;n<t.length;n++){for(var r=t[n],i=[],o=0;o<e.length;o++){var a=e[o];i.push(a+"_"+r.tokenTypeIdx);for(var s=0;s<r.categoryMatches.length;s++){var c="_"+r.categoryMatches[s];i.push(a+c)}}e=i}return e}function Yt(t,e,n){for(var r=0;r<t.length;r++)if(r!==n)for(var i=t[r],o=0;o<e.length;o++){if(!0===i[e[o]])return!1}return!0}function Xt(t,e){for(var n=Object(i.I)(t,(function(t){return Bt([t],1)})),r=zt(n.length),o=Object(i.I)(n,(function(t){var e={};return Object(i.u)(t,(function(t){var n=$t(t.partialPath);Object(i.u)(n,(function(t){e[t]=!0}))})),e})),a=n,s=1;s<=e;s++){var c=a;a=zt(c.length);for(var u=function(t){for(var n=c[t],u=0;u<n.length;u++){var l=n[u].partialPath,f=n[u].suffixDef,p=$t(l);if(Yt(o,p,t)||Object(i.A)(f)||l.length===e){var h=r[t];if(!1===Zt(h,l)){h.push(l);for(var d=0;d<p.length;d++){var m=p[d];o[t][m]=!0}}}else{var v=Bt(f,s+1,l);a[t]=a[t].concat(v),Object(i.u)(v,(function(e){var n=$t(e.partialPath);Object(i.u)(n,(function(e){o[t][e]=!0}))}))}}},l=0;l<c.length;l++)u(l)}return r}function Jt(t,e,n,r){var i=new Kt(t,Gt.ALTERNATION,r);return e.accept(i),Xt(i.result,n)}function Qt(t,e,n,r){var i=new Kt(t,n);e.accept(i);var o=i.result,a=new Vt(e,t,n).startWalking();return Xt([new at({definition:o}),new at({definition:a})],r)}function Zt(t,e){t:for(var n=0;n<t.length;n++){var r=t[n];if(r.length===e.length){for(var i=0;i<r.length;i++){var o=e[i],a=r[i];if(!1===(o===a||void 0!==a.categoryMatchesMap[o.tokenTypeIdx]))continue t}return!0}}return!1}function te(t){return Object(i.o)(t,(function(t){return Object(i.o)(t,(function(t){return Object(i.o)(t,(function(t){return Object(i.A)(t.categoryMatches)}))}))}))}var ee=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();function ne(t,e,n,r,o){var a=i.I(t,(function(t){return function(t,e){var n=new oe;t.accept(n);var r=n.allProductions,o=i.v(r,re),a=i.N(o,(function(t){return t.length>1}));return i.I(i.U(a),(function(n){var r=i.s(n),o=e.buildDuplicateFoundError(t,n),a=Et(r),s={message:o,type:Qe.DUPLICATE_PRODUCTIONS,ruleName:t.name,dslName:a,occurrence:r.idx},c=ie(r);return c&&(s.parameter=c),s}))}(t,r)})),s=i.I(t,(function(t){return function t(e,n,r,o){void 0===o&&(o=[]);var a=[],s=function t(e){var n=[];if(i.A(e))return n;var r=i.s(e);if(r instanceof it)n.push(r.referencedRule);else if(r instanceof at||r instanceof st||r instanceof ct||r instanceof ut||r instanceof ft||r instanceof lt)n=n.concat(t(r.definition));else if(r instanceof pt)n=i.t(i.I(r.definition,(function(e){return t(e.definition)})));else if(!(r instanceof ht))throw Error("non exhaustive match");var o=Ot(r),a=e.length>1;if(o&&a){var s=i.m(e);return n.concat(t(s))}return n}(n.definition);if(i.A(s))return[];var c=e.name;i.j(s,e)&&a.push({message:r.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:o}),type:Qe.LEFT_RECURSION,ruleName:c});var u=i.l(s,o.concat([e])),l=i.I(u,(function(n){var a=i.g(o);return a.push(n),t(e,n,r,a)}));return a.concat(i.t(l))}(t,t,r)})),c=[],u=[],l=[];Object(i.o)(s,i.A)&&(c=Object(i.I)(t,(function(t){return function(t,e){var n=new se;t.accept(n);var r=n.alternations;return i.O(r,(function(n,r){var o=i.n(r.definition),a=i.I(o,(function(n,o){var a=Ht([n],[],null,1);return i.A(a)?{message:e.buildEmptyAlternationError({topLevelRule:t,alternation:r,emptyChoiceIdx:o}),type:Qe.NONE_LAST_EMPTY_ALT,ruleName:t.name,occurrence:r.idx,alternative:o+1}:null}));return n.concat(i.i(a))}),[])}(t,r)})),u=Object(i.I)(t,(function(t){return function(t,e,n){var r=new se;t.accept(r);var o=r.alternations;return o=Object(i.P)(o,(function(t){return!0===t.ignoreAmbiguities})),i.O(o,(function(r,o){var a=o.idx,s=o.maxLookahead||e,c=Jt(a,t,s,o),u=function(t,e,n,r){var o=[],a=Object(i.O)(t,(function(n,r,a){return!0===e.definition[a].ignoreAmbiguities||Object(i.u)(r,(function(r){var s=[a];Object(i.u)(t,(function(t,n){a!==n&&Zt(t,r)&&!0!==e.definition[n].ignoreAmbiguities&&s.push(n)})),s.length>1&&!Zt(o,r)&&(o.push(r),n.push({alts:s,path:r}))})),n}),[]);return i.I(a,(function(t){var o=Object(i.I)(t.alts,(function(t){return t+1}));return{message:r.buildAlternationAmbiguityError({topLevelRule:n,alternation:e,ambiguityIndices:o,prefixPath:t.path}),type:Qe.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:e.idx,alternatives:[t.alts]}}))}(c,o,t,n),l=function(t,e,n,r){var o=[],a=Object(i.O)(t,(function(t,e,n){var r=Object(i.I)(e,(function(t){return{idx:n,path:t}}));return t.concat(r)}),[]);return Object(i.u)(a,(function(t){if(!0!==e.definition[t.idx].ignoreAmbiguities){var s=t.idx,c=t.path,u=Object(i.r)(a,(function(t){return!0!==e.definition[t.idx].ignoreAmbiguities&&t.idx<s&&(n=t.path,r=c,n.length<r.length&&Object(i.o)(n,(function(t,e){var n=r[e];return t===n||n.categoryMatchesMap[t.tokenTypeIdx]})));var n,r})),l=Object(i.I)(u,(function(t){var i=[t.idx+1,s+1],o=0===e.idx?"":e.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:e,ambiguityIndices:i,prefixPath:t.path}),type:Qe.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:o,alternatives:i}}));o=o.concat(l)}})),o}(c,o,t,n);return r.concat(u,l)}),[])}(t,e,r)})),l=function(t,e,n){var r=[];return Object(i.u)(t,(function(t){var o=new ce;t.accept(o);var a=o.allProductions;Object(i.u)(a,(function(o){var a=function(t){if(t instanceof st)return Gt.OPTION;if(t instanceof lt)return Gt.REPETITION;if(t instanceof ct)return Gt.REPETITION_MANDATORY;if(t instanceof ut)return Gt.REPETITION_MANDATORY_WITH_SEPARATOR;if(t instanceof ft)return Gt.REPETITION_WITH_SEPARATOR;if(t instanceof pt)return Gt.ALTERNATION;throw Error("non exhaustive match")}(o),s=o.maxLookahead||e,c=Qt(o.idx,t,a,s)[0];if(Object(i.A)(Object(i.t)(c))){var u=n.buildEmptyRepetitionError({topLevelRule:t,repetition:o});r.push({message:u,type:Qe.NO_NON_EMPTY_LOOKAHEAD,ruleName:t.name})}}))})),r}(t,e,r));var f=function(t,e,n){var r=[],o=Object(i.I)(e,(function(t){return t.name}));return Object(i.u)(t,(function(t){var e=t.name;if(Object(i.j)(o,e)){var a=n.buildNamespaceConflictError(t);r.push({message:a,type:Qe.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:e})}})),r}(t,n,r),p=i.I(n,(function(t){return function(t,e){var n=[];t.name.match(ae)||n.push({message:e.buildTokenNameError({tokenType:t,expectedPattern:ae}),type:Qe.INVALID_TOKEN_NAME});return n}(t,r)})),h=Object(i.I)(t,(function(t){return function(t,e){var n=new se;t.accept(n);var r=n.alternations;return i.O(r,(function(n,r){return r.definition.length>255&&n.push({message:e.buildTooManyAlternativesError({topLevelRule:t,alternation:r}),type:Qe.TOO_MANY_ALTS,ruleName:t.name,occurrence:r.idx}),n}),[])}(t,r)})),d=Object(i.I)(t,(function(t){return function(t,e){var n=[],r=t.name;r.match(ae)||n.push({message:e.buildInvalidRuleNameError({topLevelRule:t,expectedPattern:ae}),type:Qe.INVALID_RULE_NAME,ruleName:r});return n}(t,r)})),m=Object(i.I)(t,(function(e){return function(t,e,n,r){var o=[];if(Object(i.O)(e,(function(e,n){return n.name===t.name?e+1:e}),0)>1){var a=r.buildDuplicateRuleNameError({topLevelRule:t,grammarName:n});o.push({message:a,type:Qe.DUPLICATE_RULE_NAME,ruleName:t.name})}return o}(e,t,o,r)}));return i.t(a.concat(p,l,s,c,u,f,h,d,m))}function re(t){return Et(t)+"_#_"+t.idx+"_#_"+ie(t)}function ie(t){return t instanceof ht?t.terminalType.name:t instanceof it?t.nonTerminalName:""}var oe=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.allProductions=[],e}return ee(e,t),e.prototype.visitNonTerminal=function(t){this.allProductions.push(t)},e.prototype.visitOption=function(t){this.allProductions.push(t)},e.prototype.visitRepetitionWithSeparator=function(t){this.allProductions.push(t)},e.prototype.visitRepetitionMandatory=function(t){this.allProductions.push(t)},e.prototype.visitRepetitionMandatoryWithSeparator=function(t){this.allProductions.push(t)},e.prototype.visitRepetition=function(t){this.allProductions.push(t)},e.prototype.visitAlternation=function(t){this.allProductions.push(t)},e.prototype.visitTerminal=function(t){this.allProductions.push(t)},e}(yt),ae=/^[a-zA-Z_]\w*$/;var se=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.alternations=[],e}return ee(e,t),e.prototype.visitAlternation=function(t){this.alternations.push(t)},e}(yt);var ce=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.allProductions=[],e}return ee(e,t),e.prototype.visitRepetitionWithSeparator=function(t){this.allProductions.push(t)},e.prototype.visitRepetitionMandatory=function(t){this.allProductions.push(t)},e.prototype.visitRepetitionMandatoryWithSeparator=function(t){this.allProductions.push(t)},e.prototype.visitRepetition=function(t){this.allProductions.push(t)},e}(yt);function ue(t){t=Object(i.k)(t,{errMsgProvider:It});var e,n,r,o={};return Object(i.u)(t.rules,(function(t){o[t.name]=t})),e=o,n=t.errMsgProvider,(r=new wt(e,n)).resolveRefs(),r.errors}function le(t){return ne((t=Object(i.k)(t,{errMsgProvider:kt})).rules,t.maxLookahead,t.tokenTypes,t.errMsgProvider,t.grammarName)}function fe(t){Object(i.u)(t.rules,(function(t){var e=new bt;t.accept(e),Object(i.u)(e.dslMethods,(function(t){Object(i.u)(t,(function(t,e){t.idx=e+1}))}))}))}var pe=["MismatchedTokenException","NoViableAltException","EarlyExitException","NotAllInputParsedException"];function he(t){return Object(i.j)(pe,t.name)}function de(t,e,n){this.name="MismatchedTokenException",this.message=t,this.token=e,this.previousToken=n,this.resyncedTokens=[]}function me(t,e,n){this.name="NoViableAltException",this.message=t,this.token=e,this.previousToken=n,this.resyncedTokens=[]}function ve(t,e){this.name="NotAllInputParsedException",this.message=t,this.token=e,this.resyncedTokens=[]}function ge(t,e,n){this.name="EarlyExitException",this.message=t,this.token=e,this.previousToken=n,this.resyncedTokens=[]}Object.freeze(pe),de.prototype=Error.prototype,me.prototype=Error.prototype,ve.prototype=Error.prototype,ge.prototype=Error.prototype;var ye={};function Te(t){this.name="InRuleRecoveryException",this.message=t}Te.prototype=Error.prototype;var Oe=function(){function t(){}return t.prototype.initRecoverable=function(t){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=Object(i.w)(t,"recoveryEnabled")?t.recoveryEnabled:Ze.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=Ee)},t.prototype.getTokenToInsert=function(t){var e=tt(t,"",NaN,NaN,NaN,NaN,NaN,NaN);return e.isInsertedInRecovery=!0,e},t.prototype.canTokenTypeBeInsertedInRecovery=function(t){return!0},t.prototype.tryInRepetitionRecovery=function(t,e,n,r){for(var o=this,a=this.findReSyncTokenType(),s=this.exportLexerState(),c=[],u=!1,l=this.LA(1),f=this.LA(1),p=function(){var t=o.LA(0),e=new de(o.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:l,previous:t,ruleName:o.getCurrRuleFullName()}),l,o.LA(0));e.resyncedTokens=Object(i.n)(c),o.SAVE_ERROR(e)};!u;){if(this.tokenMatcher(f,r))return void p();if(n.call(this))return p(),void t.apply(this,e);this.tokenMatcher(f,a)?u=!0:(f=this.SKIP_TOKEN(),this.addToResyncTokens(f,c))}this.importLexerState(s)},t.prototype.shouldInRepetitionRecoveryBeTried=function(t,e,n){return!1!==n&&(void 0!==t&&void 0!==e&&(!this.tokenMatcher(this.LA(1),t)&&(!this.isBackTracking()&&!this.canPerformInRuleRecovery(t,this.getFollowsForInRuleRecovery(t,e)))))},t.prototype.getFollowsForInRuleRecovery=function(t,e){var n=this.getCurrentGrammarPath(t,e);return this.getNextPossibleTokenTypes(n)},t.prototype.tryInRuleRecovery=function(t,e){if(this.canRecoverWithSingleTokenInsertion(t,e))return this.getTokenToInsert(t);if(this.canRecoverWithSingleTokenDeletion(t)){var n=this.SKIP_TOKEN();return this.consumeToken(),n}throw new Te("sad sad panda")},t.prototype.canPerformInRuleRecovery=function(t,e){return this.canRecoverWithSingleTokenInsertion(t,e)||this.canRecoverWithSingleTokenDeletion(t)},t.prototype.canRecoverWithSingleTokenInsertion=function(t,e){var n=this;if(!this.canTokenTypeBeInsertedInRecovery(t))return!1;if(Object(i.A)(e))return!1;var r=this.LA(1);return void 0!==Object(i.q)(e,(function(t){return n.tokenMatcher(r,t)}))},t.prototype.canRecoverWithSingleTokenDeletion=function(t){return this.tokenMatcher(this.LA(2),t)},t.prototype.isInCurrentRuleReSyncSet=function(t){var e=this.getCurrFollowKey(),n=this.getFollowSetFromFollowKey(e);return Object(i.j)(n,t)},t.prototype.findReSyncTokenType=function(){for(var t=this.flattenFollowSet(),e=this.LA(1),n=2;;){var r=e.tokenType;if(Object(i.j)(t,r))return r;e=this.LA(n),n++}},t.prototype.getCurrFollowKey=function(){if(1===this.RULE_STACK.length)return ye;var t=this.getLastExplicitRuleShortName(),e=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(t),idxInCallingRule:e,inRule:this.shortRuleNameToFullName(n)}},t.prototype.buildFullFollowKeyStack=function(){var t=this,e=this.RULE_STACK,n=this.RULE_OCCURRENCE_STACK;return Object(i.I)(e,(function(r,i){return 0===i?ye:{ruleName:t.shortRuleNameToFullName(r),idxInCallingRule:n[i],inRule:t.shortRuleNameToFullName(e[i-1])}}))},t.prototype.flattenFollowSet=function(){var t=this,e=Object(i.I)(this.buildFullFollowKeyStack(),(function(e){return t.getFollowSetFromFollowKey(e)}));return Object(i.t)(e)},t.prototype.getFollowSetFromFollowKey=function(t){if(t===ye)return[Z];var e=t.ruleName+t.idxInCallingRule+xt+t.inRule;return this.resyncFollows[e]},t.prototype.addToResyncTokens=function(t,e){return this.tokenMatcher(t,Z)||e.push(t),e},t.prototype.reSyncTo=function(t){for(var e=[],n=this.LA(1);!1===this.tokenMatcher(n,t);)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,e);return Object(i.n)(e)},t.prototype.attemptInRepetitionRecovery=function(t,e,n,r,i,o,a){},t.prototype.getCurrentGrammarPath=function(t,e){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:Object(i.g)(this.RULE_OCCURRENCE_STACK),lastTok:t,lastTokOccurrence:e}},t.prototype.getHumanReadableRuleStack=function(){var t=this;return Object(i.I)(this.RULE_STACK,(function(e){return t.shortRuleNameToFullName(e)}))},t}();function Ee(t,e,n,r,i,o,a){var s=this.getKeyForAutomaticLookahead(r,i),c=this.firstAfterRepMap[s];if(void 0===c){var u=this.getCurrRuleFullName();c=new o(this.getGAstProductions()[u],i).startWalking(),this.firstAfterRepMap[s]=c}var l=c.token,f=c.occurrence,p=c.isEndOfRule;1===this.RULE_STACK.length&&p&&void 0===l&&(l=Z,f=1),this.shouldInRepetitionRecoveryBeTried(l,f,a)&&this.tryInRepetitionRecovery(t,e,n,l)}function be(t,e,n){return n|e|t}var Se=function(){function t(){}return t.prototype.initLooksAhead=function(t){this.dynamicTokensEnabled=Object(i.w)(t,"dynamicTokensEnabled")?t.dynamicTokensEnabled:Ze.dynamicTokensEnabled,this.maxLookahead=Object(i.w)(t,"maxLookahead")?t.maxLookahead:Ze.maxLookahead,this.lookAheadFuncsCache=Object(i.z)()?new Map:[],Object(i.z)()?(this.getLaFuncFromCache=this.getLaFuncFromMap,this.setLaFuncCache=this.setLaFuncCacheUsingMap):(this.getLaFuncFromCache=this.getLaFuncFromObj,this.setLaFuncCache=this.setLaFuncUsingObj)},t.prototype.preComputeLookaheadFunctions=function(t){var e=this;Object(i.u)(t,(function(t){e.TRACE_INIT(t.name+" Rule Lookahead",(function(){var n=function(t){St.reset(),t.accept(St);var e=St.dslMethods;return St.reset(),e}(t),r=n.alternation,o=n.repetition,a=n.option,s=n.repetitionMandatory,c=n.repetitionMandatoryWithSeparator,u=n.repetitionWithSeparator;Object(i.u)(r,(function(n){var r=0===n.idx?"":n.idx;e.TRACE_INIT(""+Et(n)+r,(function(){var r,i,o,a,s,c,u,l=(r=n.idx,i=t,o=n.maxLookahead||e.maxLookahead,a=n.hasPredicates,s=e.dynamicTokensEnabled,c=e.lookAheadBuilderForAlternatives,u=Jt(r,i,o),c(u,a,te(u)?U:D,s)),f=be(e.fullRuleNameToShort[t.name],256,n.idx);e.setLaFuncCache(f,l)}))})),Object(i.u)(o,(function(n){e.computeLookaheadFunc(t,n.idx,768,Gt.REPETITION,n.maxLookahead,Et(n))})),Object(i.u)(a,(function(n){e.computeLookaheadFunc(t,n.idx,512,Gt.OPTION,n.maxLookahead,Et(n))})),Object(i.u)(s,(function(n){e.computeLookaheadFunc(t,n.idx,1024,Gt.REPETITION_MANDATORY,n.maxLookahead,Et(n))})),Object(i.u)(c,(function(n){e.computeLookaheadFunc(t,n.idx,1536,Gt.REPETITION_MANDATORY_WITH_SEPARATOR,n.maxLookahead,Et(n))})),Object(i.u)(u,(function(n){e.computeLookaheadFunc(t,n.idx,1280,Gt.REPETITION_WITH_SEPARATOR,n.maxLookahead,Et(n))}))}))}))},t.prototype.computeLookaheadFunc=function(t,e,n,r,i,o){var a=this;this.TRACE_INIT(""+o+(0===e?"":e),(function(){var o=function(t,e,n,r,i,o){var a=Qt(t,e,i,n),s=te(a)?U:D;return o(a[0],s,r)}(e,t,i||a.maxLookahead,a.dynamicTokensEnabled,r,a.lookAheadBuilderForOptional),s=be(a.fullRuleNameToShort[t.name],n,e);a.setLaFuncCache(s,o)}))},t.prototype.lookAheadBuilderForOptional=function(t,e,n){return function(t,e,n){var r=Object(i.o)(t,(function(t){return 1===t.length})),o=t.length;if(r&&!n){var a=Object(i.t)(t);if(1===a.length&&Object(i.A)(a[0].categoryMatches)){var s=a[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===s}}var c=Object(i.O)(a,(function(t,e,n){return t[e.tokenTypeIdx]=!0,Object(i.u)(e.categoryMatches,(function(e){t[e]=!0})),t}),[]);return function(){var t=this.LA(1);return!0===c[t.tokenTypeIdx]}}return function(){t:for(var n=0;n<o;n++){for(var r=t[n],i=r.length,a=0;a<i;a++){var s=this.LA(a+1);if(!1===e(s,r[a]))continue t}return!0}return!1}}(t,e,n)},t.prototype.lookAheadBuilderForAlternatives=function(t,e,n,r){return function(t,e,n,r){var o=t.length,a=Object(i.o)(t,(function(t){return Object(i.o)(t,(function(t){return 1===t.length}))}));if(e)return function(e){for(var r=Object(i.I)(e,(function(t){return t.GATE})),a=0;a<o;a++){var s=t[a],c=s.length,u=r[a];if(void 0===u||!1!==u.call(this))t:for(var l=0;l<c;l++){for(var f=s[l],p=f.length,h=0;h<p;h++){var d=this.LA(h+1);if(!1===n(d,f[h]))continue t}return a}}};if(a&&!r){var s=Object(i.I)(t,(function(t){return Object(i.t)(t)})),c=Object(i.O)(s,(function(t,e,n){return Object(i.u)(e,(function(e){Object(i.w)(t,e.tokenTypeIdx)||(t[e.tokenTypeIdx]=n),Object(i.u)(e.categoryMatches,(function(e){Object(i.w)(t,e)||(t[e]=n)}))})),t}),[]);return function(){var t=this.LA(1);return c[t.tokenTypeIdx]}}return function(){for(var e=0;e<o;e++){var r=t[e],i=r.length;t:for(var a=0;a<i;a++){for(var s=r[a],c=s.length,u=0;u<c;u++){var l=this.LA(u+1);if(!1===n(l,s[u]))continue t}return e}}}}(t,e,n,r)},t.prototype.getKeyForAutomaticLookahead=function(t,e){return be(this.getLastExplicitRuleShortName(),t,e)},t.prototype.getLaFuncFromCache=function(t){},t.prototype.getLaFuncFromMap=function(t){return this.lookAheadFuncsCache.get(t)},t.prototype.getLaFuncFromObj=function(t){return this.lookAheadFuncsCache[t]},t.prototype.setLaFuncCache=function(t,e){},t.prototype.setLaFuncCacheUsingMap=function(t,e){this.lookAheadFuncsCache.set(t,e)},t.prototype.setLaFuncUsingObj=function(t,e){this.lookAheadFuncsCache[t]=e},t}();function Ne(t,e){!0===isNaN(t.startOffset)?(t.startOffset=e.startOffset,t.endOffset=e.endOffset):t.endOffset<e.endOffset==!0&&(t.endOffset=e.endOffset)}function xe(t,e){!0===isNaN(t.startOffset)?(t.startOffset=e.startOffset,t.startColumn=e.startColumn,t.startLine=e.startLine,t.endOffset=e.endOffset,t.endColumn=e.endColumn,t.endLine=e.endLine):t.endOffset<e.endOffset==!0&&(t.endOffset=e.endOffset,t.endColumn=e.endColumn,t.endLine=e.endLine)}var Ae,Re=/^\s*function\s*(\S*)\s*\(/;function Ce(t){var e=t.name;return e||t.toString().match(Re)[1]}function Ie(t,e){var n=Object.getOwnPropertyDescriptor(t,"name");return!(!Object(i.F)(n)&&!n.configurable)&&(Object.defineProperty(t,"name",{enumerable:!1,configurable:!0,writable:!1,value:e}),!0)}function ke(t,e){for(var n=Object(i.G)(t),r=n.length,o=0;o<r;o++)for(var a=t[n[o]],s=a.length,c=0;c<s;c++){var u=a[c];void 0===u.tokenTypeIdx&&this[u.name](u.children,e)}}function Le(t,e){var n=function(){};return Ie(n,t+"BaseSemantics"),(n.prototype={visit:function(t,e){if(Object(i.y)(t)&&(t=t[0]),!Object(i.F)(t))return this[t.name](t.children,e)},validateVisitor:function(){var t=function(t,e){var n=function(t,e){var n=Object(i.I)(e,(function(e){if(!Object(i.B)(t[e]))return{msg:"Missing visitor method: <"+e+"> on "+Ce(t.constructor)+" CST Visitor.",type:Ae.MISSING_METHOD,methodName:e}}));return Object(i.i)(n)}(t,e),r=function(t,e){var n=[];for(var r in t)ae.test(r)&&Object(i.B)(t[r])&&!Object(i.j)(we,r)&&!Object(i.j)(e,r)&&n.push({msg:"Redundant visitor method: <"+r+"> on "+Ce(t.constructor)+" CST Visitor\nThere is no Grammar Rule corresponding to this method's name.\nFor utility methods on visitor classes use methods names that do not match /"+ae.source+"/.",type:Ae.REDUNDANT_METHOD,methodName:r});return n}(t,e);return n.concat(r)}(this,e);if(!Object(i.A)(t)){var n=Object(i.I)(t,(function(t){return t.msg}));throw Error("Errors Detected in CST Visitor <"+Ce(this.constructor)+">:\n\t"+n.join("\n\n").replace(/\n/g,"\n\t"))}}}).constructor=n,n._RULE_NAMES=e,n}!function(t){t[t.REDUNDANT_METHOD=0]="REDUNDANT_METHOD",t[t.MISSING_METHOD=1]="MISSING_METHOD"}(Ae||(Ae={}));var we=["constructor","visit","validateVisitor"];var _e=function(){function t(){}return t.prototype.initTreeBuilder=function(t){if(this.CST_STACK=[],this.outputCst=t.outputCst,this.nodeLocationTracking=Object(i.w)(t,"nodeLocationTracking")?t.nodeLocationTracking:Ze.nodeLocationTracking,this.outputCst)if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=xe,this.setNodeLocationFromNode=xe,this.cstPostRule=i.b,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=i.b,this.setNodeLocationFromNode=i.b,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Ne,this.setNodeLocationFromNode=Ne,this.cstPostRule=i.b,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=i.b,this.setNodeLocationFromNode=i.b,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else{if(!/none/i.test(this.nodeLocationTracking))throw Error('Invalid <nodeLocationTracking> config option: "'+t.nodeLocationTracking+'"');this.setNodeLocationFromToken=i.b,this.setNodeLocationFromNode=i.b,this.cstPostRule=i.b,this.setInitialNodeLocation=i.b}else this.cstInvocationStateUpdate=i.b,this.cstFinallyStateUpdate=i.b,this.cstPostTerminal=i.b,this.cstPostNonTerminal=i.b,this.cstPostRule=i.b},t.prototype.setInitialNodeLocationOnlyOffsetRecovery=function(t){t.location={startOffset:NaN,endOffset:NaN}},t.prototype.setInitialNodeLocationOnlyOffsetRegular=function(t){t.location={startOffset:this.LA(1).startOffset,endOffset:NaN}},t.prototype.setInitialNodeLocationFullRecovery=function(t){t.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.setInitialNodeLocationFullRegular=function(t){var e=this.LA(1);t.location={startOffset:e.startOffset,startLine:e.startLine,startColumn:e.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.cstInvocationStateUpdate=function(t,e){var n={name:t,children:{}};this.setInitialNodeLocation(n),this.CST_STACK.push(n)},t.prototype.cstFinallyStateUpdate=function(){this.CST_STACK.pop()},t.prototype.cstPostRuleFull=function(t){var e=this.LA(0),n=t.location;n.startOffset<=e.startOffset==!0?(n.endOffset=e.endOffset,n.endLine=e.endLine,n.endColumn=e.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)},t.prototype.cstPostRuleOnlyOffset=function(t){var e=this.LA(0),n=t.location;n.startOffset<=e.startOffset==!0?n.endOffset=e.endOffset:n.startOffset=NaN},t.prototype.cstPostTerminal=function(t,e){var n,r,i,o=this.CST_STACK[this.CST_STACK.length-1];r=e,i=t,void 0===(n=o).children[i]?n.children[i]=[r]:n.children[i].push(r),this.setNodeLocationFromToken(o.location,e)},t.prototype.cstPostNonTerminal=function(t,e){var n=this.CST_STACK[this.CST_STACK.length-1];!function(t,e,n){void 0===t.children[e]?t.children[e]=[n]:t.children[e].push(n)}(n,e,t),this.setNodeLocationFromNode(n.location,t.location)},t.prototype.getBaseCstVisitorConstructor=function(){if(Object(i.F)(this.baseCstVisitorConstructor)){var t=Le(this.className,Object(i.G)(this.gastProductionsCache));return this.baseCstVisitorConstructor=t,t}return this.baseCstVisitorConstructor},t.prototype.getBaseCstVisitorConstructorWithDefaults=function(){if(Object(i.F)(this.baseCstVisitorWithDefaultsConstructor)){var t=function(t,e,n){var r=function(){};Ie(r,t+"BaseSemanticsWithDefaults");var o=Object.create(n.prototype);return Object(i.u)(e,(function(t){o[t]=ke})),(r.prototype=o).constructor=r,r}(this.className,Object(i.G)(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=t,t}return this.baseCstVisitorWithDefaultsConstructor},t.prototype.getLastExplicitRuleShortName=function(){var t=this.RULE_STACK;return t[t.length-1]},t.prototype.getPreviousExplicitRuleShortName=function(){var t=this.RULE_STACK;return t[t.length-2]},t.prototype.getLastExplicitRuleOccurrenceIndex=function(){var t=this.RULE_OCCURRENCE_STACK;return t[t.length-1]},t}(),je=function(){function t(){}return t.prototype.initLexerAdapter=function(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1},Object.defineProperty(t.prototype,"input",{get:function(){return this.tokVector},set:function(t){if(!0!==this.selfAnalysisDone)throw Error("Missing <performSelfAnalysis> invocation at the end of the Parser's constructor.");this.reset(),this.tokVector=t,this.tokVectorLength=t.length},enumerable:!1,configurable:!0}),t.prototype.SKIP_TOKEN=function(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):Je},t.prototype.LA=function(t){var e=this.currIdx+t;return e<0||this.tokVectorLength<=e?Je:this.tokVector[e]},t.prototype.consumeToken=function(){this.currIdx++},t.prototype.exportLexerState=function(){return this.currIdx},t.prototype.importLexerState=function(t){this.currIdx=t},t.prototype.resetLexerState=function(){this.currIdx=-1},t.prototype.moveToTerminatedState=function(){this.currIdx=this.tokVector.length-1},t.prototype.getLexerPosition=function(){return this.exportLexerState()},t}(),Me=function(){function t(){}return t.prototype.ACTION=function(t){return t.call(this)},t.prototype.consume=function(t,e,n){return this.consumeInternal(e,t,n)},t.prototype.subrule=function(t,e,n){return this.subruleInternal(e,t,n)},t.prototype.option=function(t,e){return this.optionInternal(e,t)},t.prototype.or=function(t,e){return this.orInternal(e,t)},t.prototype.many=function(t,e){return this.manyInternal(t,e)},t.prototype.atLeastOne=function(t,e){return this.atLeastOneInternal(t,e)},t.prototype.CONSUME=function(t,e){return this.consumeInternal(t,0,e)},t.prototype.CONSUME1=function(t,e){return this.consumeInternal(t,1,e)},t.prototype.CONSUME2=function(t,e){return this.consumeInternal(t,2,e)},t.prototype.CONSUME3=function(t,e){return this.consumeInternal(t,3,e)},t.prototype.CONSUME4=function(t,e){return this.consumeInternal(t,4,e)},t.prototype.CONSUME5=function(t,e){return this.consumeInternal(t,5,e)},t.prototype.CONSUME6=function(t,e){return this.consumeInternal(t,6,e)},t.prototype.CONSUME7=function(t,e){return this.consumeInternal(t,7,e)},t.prototype.CONSUME8=function(t,e){return this.consumeInternal(t,8,e)},t.prototype.CONSUME9=function(t,e){return this.consumeInternal(t,9,e)},t.prototype.SUBRULE=function(t,e){return this.subruleInternal(t,0,e)},t.prototype.SUBRULE1=function(t,e){return this.subruleInternal(t,1,e)},t.prototype.SUBRULE2=function(t,e){return this.subruleInternal(t,2,e)},t.prototype.SUBRULE3=function(t,e){return this.subruleInternal(t,3,e)},t.prototype.SUBRULE4=function(t,e){return this.subruleInternal(t,4,e)},t.prototype.SUBRULE5=function(t,e){return this.subruleInternal(t,5,e)},t.prototype.SUBRULE6=function(t,e){return this.subruleInternal(t,6,e)},t.prototype.SUBRULE7=function(t,e){return this.subruleInternal(t,7,e)},t.prototype.SUBRULE8=function(t,e){return this.subruleInternal(t,8,e)},t.prototype.SUBRULE9=function(t,e){return this.subruleInternal(t,9,e)},t.prototype.OPTION=function(t){return this.optionInternal(t,0)},t.prototype.OPTION1=function(t){return this.optionInternal(t,1)},t.prototype.OPTION2=function(t){return this.optionInternal(t,2)},t.prototype.OPTION3=function(t){return this.optionInternal(t,3)},t.prototype.OPTION4=function(t){return this.optionInternal(t,4)},t.prototype.OPTION5=function(t){return this.optionInternal(t,5)},t.prototype.OPTION6=function(t){return this.optionInternal(t,6)},t.prototype.OPTION7=function(t){return this.optionInternal(t,7)},t.prototype.OPTION8=function(t){return this.optionInternal(t,8)},t.prototype.OPTION9=function(t){return this.optionInternal(t,9)},t.prototype.OR=function(t){return this.orInternal(t,0)},t.prototype.OR1=function(t){return this.orInternal(t,1)},t.prototype.OR2=function(t){return this.orInternal(t,2)},t.prototype.OR3=function(t){return this.orInternal(t,3)},t.prototype.OR4=function(t){return this.orInternal(t,4)},t.prototype.OR5=function(t){return this.orInternal(t,5)},t.prototype.OR6=function(t){return this.orInternal(t,6)},t.prototype.OR7=function(t){return this.orInternal(t,7)},t.prototype.OR8=function(t){return this.orInternal(t,8)},t.prototype.OR9=function(t){return this.orInternal(t,9)},t.prototype.MANY=function(t){this.manyInternal(0,t)},t.prototype.MANY1=function(t){this.manyInternal(1,t)},t.prototype.MANY2=function(t){this.manyInternal(2,t)},t.prototype.MANY3=function(t){this.manyInternal(3,t)},t.prototype.MANY4=function(t){this.manyInternal(4,t)},t.prototype.MANY5=function(t){this.manyInternal(5,t)},t.prototype.MANY6=function(t){this.manyInternal(6,t)},t.prototype.MANY7=function(t){this.manyInternal(7,t)},t.prototype.MANY8=function(t){this.manyInternal(8,t)},t.prototype.MANY9=function(t){this.manyInternal(9,t)},t.prototype.MANY_SEP=function(t){this.manySepFirstInternal(0,t)},t.prototype.MANY_SEP1=function(t){this.manySepFirstInternal(1,t)},t.prototype.MANY_SEP2=function(t){this.manySepFirstInternal(2,t)},t.prototype.MANY_SEP3=function(t){this.manySepFirstInternal(3,t)},t.prototype.MANY_SEP4=function(t){this.manySepFirstInternal(4,t)},t.prototype.MANY_SEP5=function(t){this.manySepFirstInternal(5,t)},t.prototype.MANY_SEP6=function(t){this.manySepFirstInternal(6,t)},t.prototype.MANY_SEP7=function(t){this.manySepFirstInternal(7,t)},t.prototype.MANY_SEP8=function(t){this.manySepFirstInternal(8,t)},t.prototype.MANY_SEP9=function(t){this.manySepFirstInternal(9,t)},t.prototype.AT_LEAST_ONE=function(t){this.atLeastOneInternal(0,t)},t.prototype.AT_LEAST_ONE1=function(t){return this.atLeastOneInternal(1,t)},t.prototype.AT_LEAST_ONE2=function(t){this.atLeastOneInternal(2,t)},t.prototype.AT_LEAST_ONE3=function(t){this.atLeastOneInternal(3,t)},t.prototype.AT_LEAST_ONE4=function(t){this.atLeastOneInternal(4,t)},t.prototype.AT_LEAST_ONE5=function(t){this.atLeastOneInternal(5,t)},t.prototype.AT_LEAST_ONE6=function(t){this.atLeastOneInternal(6,t)},t.prototype.AT_LEAST_ONE7=function(t){this.atLeastOneInternal(7,t)},t.prototype.AT_LEAST_ONE8=function(t){this.atLeastOneInternal(8,t)},t.prototype.AT_LEAST_ONE9=function(t){this.atLeastOneInternal(9,t)},t.prototype.AT_LEAST_ONE_SEP=function(t){this.atLeastOneSepFirstInternal(0,t)},t.prototype.AT_LEAST_ONE_SEP1=function(t){this.atLeastOneSepFirstInternal(1,t)},t.prototype.AT_LEAST_ONE_SEP2=function(t){this.atLeastOneSepFirstInternal(2,t)},t.prototype.AT_LEAST_ONE_SEP3=function(t){this.atLeastOneSepFirstInternal(3,t)},t.prototype.AT_LEAST_ONE_SEP4=function(t){this.atLeastOneSepFirstInternal(4,t)},t.prototype.AT_LEAST_ONE_SEP5=function(t){this.atLeastOneSepFirstInternal(5,t)},t.prototype.AT_LEAST_ONE_SEP6=function(t){this.atLeastOneSepFirstInternal(6,t)},t.prototype.AT_LEAST_ONE_SEP7=function(t){this.atLeastOneSepFirstInternal(7,t)},t.prototype.AT_LEAST_ONE_SEP8=function(t){this.atLeastOneSepFirstInternal(8,t)},t.prototype.AT_LEAST_ONE_SEP9=function(t){this.atLeastOneSepFirstInternal(9,t)},t.prototype.RULE=function(t,e,n){if(void 0===n&&(n=tn),Object(i.j)(this.definedRulesNames,t)){var r={message:kt.buildDuplicateRuleNameError({topLevelRule:t,grammarName:this.className}),type:Qe.DUPLICATE_RULE_NAME,ruleName:t};this.definitionErrors.push(r)}this.definedRulesNames.push(t);var o=this.defineRule(t,e,n);return this[t]=o,o},t.prototype.OVERRIDE_RULE=function(t,e,n){void 0===n&&(n=tn);var r,o,a,s,c,u=[];u=u.concat((r=t,o=this.definedRulesNames,a=this.className,c=[],i.j(o,r)||(s="Invalid rule override, rule: ->"+r+"<- cannot be overridden in the grammar: ->"+a+"<-as it is not defined in any of the super grammars ",c.push({message:s,type:Qe.INVALID_RULE_OVERRIDE,ruleName:r})),c)),this.definitionErrors.push.apply(this.definitionErrors,u);var l=this.defineRule(t,e,n);return this[t]=l,l},t.prototype.BACKTRACK=function(t,e){return function(){this.isBackTrackingStack.push(1);var n=this.saveRecogState();try{return t.apply(this,e),!0}catch(t){if(he(t))return!1;throw t}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}},t.prototype.getGAstProductions=function(){return this.gastProductionsCache},t.prototype.getSerializedGastProductions=function(){return dt(Object(i.U)(this.gastProductionsCache))},t}(),Pe=function(){function t(){}return t.prototype.initRecognizerEngine=function(t,e){if(this.className=Ce(this.constructor),this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=U,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},Object(i.w)(e,"serializedGrammar"))throw Error("The Parser's configuration can no longer contain a <serializedGrammar> property.\n\tSee: https://sap.github.io/chevrotain/docs/changes/BREAKING_CHANGES.html#_6-0-0\n\tFor Further details.");if(Object(i.y)(t)){if(Object(i.A)(t))throw Error("A Token Vocabulary cannot be empty.\n\tNote that the first argument for the parser constructor\n\tis no longer a Token vector (since v4.0).");if("number"==typeof t[0].startOffset)throw Error("The Parser constructor no longer accepts a token vector as the first argument.\n\tSee: https://sap.github.io/chevrotain/docs/changes/BREAKING_CHANGES.html#_4-0-0\n\tFor Further details.")}if(Object(i.y)(t))this.tokensMap=Object(i.O)(t,(function(t,e){return t[e.name]=e,t}),{});else if(Object(i.w)(t,"modes")&&Object(i.o)(Object(i.t)(Object(i.U)(t.modes)),q)){var n=Object(i.t)(Object(i.U)(t.modes)),r=Object(i.T)(n);this.tokensMap=Object(i.O)(r,(function(t,e){return t[e.name]=e,t}),{})}else{if(!Object(i.C)(t))throw new Error("<tokensDictionary> argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition");this.tokensMap=Object(i.h)(t)}this.tokensMap.EOF=Z;var o=Object(i.o)(Object(i.U)(t),(function(t){return Object(i.A)(t.categoryMatches)}));this.tokenMatcher=o?U:D,H(Object(i.U)(this.tokensMap))},t.prototype.defineRule=function(t,e,n){if(this.selfAnalysisDone)throw Error("Grammar rule <"+t+"> may not be defined after the 'performSelfAnalysis' method has been called'\nMake sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.");var r,o=Object(i.w)(n,"resyncEnabled")?n.resyncEnabled:tn.resyncEnabled,a=Object(i.w)(n,"recoveryValueFunc")?n.recoveryValueFunc:tn.recoveryValueFunc,s=this.ruleShortNameIdx<<12;function c(t){try{if(!0===this.outputCst){e.apply(this,t);var n=this.CST_STACK[this.CST_STACK.length-1];return this.cstPostRule(n),n}return e.apply(this,t)}catch(t){return this.invokeRuleCatch(t,o,a)}finally{this.ruleFinallyStateUpdate()}}this.ruleShortNameIdx++,this.shortRuleNameToFull[s]=t,this.fullRuleNameToShort[t]=s;return(r=function(e,n){return void 0===e&&(e=0),this.ruleInvocationStateUpdate(s,t,e),c.call(this,n)}).ruleName=t,r.originalGrammarAction=e,r},t.prototype.invokeRuleCatch=function(t,e,n){var r=1===this.RULE_STACK.length,i=e&&!this.isBackTracking()&&this.recoveryEnabled;if(he(t)){var o=t;if(i){var a,s=this.findReSyncTokenType();if(this.isInCurrentRuleReSyncSet(s))return o.resyncedTokens=this.reSyncTo(s),this.outputCst?((a=this.CST_STACK[this.CST_STACK.length-1]).recoveredNode=!0,a):n();throw this.outputCst&&((a=this.CST_STACK[this.CST_STACK.length-1]).recoveredNode=!0,o.partialCstResult=a),o}if(r)return this.moveToTerminatedState(),n();throw o}throw t},t.prototype.optionInternal=function(t,e){var n=this.getKeyForAutomaticLookahead(512,e);return this.optionInternalLogic(t,e,n)},t.prototype.optionInternalLogic=function(t,e,n){var r,i,o=this,a=this.getLaFuncFromCache(n);if(void 0!==t.DEF){if(r=t.DEF,void 0!==(i=t.GATE)){var s=a;a=function(){return i.call(o)&&s.call(o)}}}else r=t;if(!0===a.call(this))return r.call(this)},t.prototype.atLeastOneInternal=function(t,e){var n=this.getKeyForAutomaticLookahead(1024,t);return this.atLeastOneInternalLogic(t,e,n)},t.prototype.atLeastOneInternalLogic=function(t,e,n){var r,i,o=this,a=this.getLaFuncFromCache(n);if(void 0!==e.DEF){if(r=e.DEF,void 0!==(i=e.GATE)){var s=a;a=function(){return i.call(o)&&s.call(o)}}}else r=e;if(!0!==a.call(this))throw this.raiseEarlyExitException(t,Gt.REPETITION_MANDATORY,e.ERR_MSG);for(var c=this.doSingleRepetition(r);!0===a.call(this)&&!0===c;)c=this.doSingleRepetition(r);this.attemptInRepetitionRecovery(this.atLeastOneInternal,[t,e],a,1024,t,Ut)},t.prototype.atLeastOneSepFirstInternal=function(t,e){var n=this.getKeyForAutomaticLookahead(1536,t);this.atLeastOneSepFirstInternalLogic(t,e,n)},t.prototype.atLeastOneSepFirstInternalLogic=function(t,e,n){var r=this,i=e.DEF,o=e.SEP;if(!0!==this.getLaFuncFromCache(n).call(this))throw this.raiseEarlyExitException(t,Gt.REPETITION_MANDATORY_WITH_SEPARATOR,e.ERR_MSG);i.call(this);for(var a=function(){return r.tokenMatcher(r.LA(1),o)};!0===this.tokenMatcher(this.LA(1),o);)this.CONSUME(o),i.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[t,o,a,i,Ft],a,1536,t,Ft)},t.prototype.manyInternal=function(t,e){var n=this.getKeyForAutomaticLookahead(768,t);return this.manyInternalLogic(t,e,n)},t.prototype.manyInternalLogic=function(t,e,n){var r,i,o=this,a=this.getLaFuncFromCache(n);if(void 0!==e.DEF){if(r=e.DEF,void 0!==(i=e.GATE)){var s=a;a=function(){return i.call(o)&&s.call(o)}}}else r=e;for(var c=!0;!0===a.call(this)&&!0===c;)c=this.doSingleRepetition(r);this.attemptInRepetitionRecovery(this.manyInternal,[t,e],a,768,t,Pt,c)},t.prototype.manySepFirstInternal=function(t,e){var n=this.getKeyForAutomaticLookahead(1280,t);this.manySepFirstInternalLogic(t,e,n)},t.prototype.manySepFirstInternalLogic=function(t,e,n){var r=this,i=e.DEF,o=e.SEP;if(!0===this.getLaFuncFromCache(n).call(this)){i.call(this);for(var a=function(){return r.tokenMatcher(r.LA(1),o)};!0===this.tokenMatcher(this.LA(1),o);)this.CONSUME(o),i.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[t,o,a,i,Dt],a,1280,t,Dt)}},t.prototype.repetitionSepSecondInternal=function(t,e,n,r,i){for(;n();)this.CONSUME(e),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[t,e,n,r,i],n,1536,t,i)},t.prototype.doSingleRepetition=function(t){var e=this.getLexerPosition();return t.call(this),this.getLexerPosition()>e},t.prototype.orInternal=function(t,e){var n=this.getKeyForAutomaticLookahead(256,e),r=Object(i.y)(t)?t:t.DEF,o=this.getLaFuncFromCache(n).call(this,r);if(void 0!==o)return r[o].ALT.call(this);this.raiseNoAltException(e,t.ERR_MSG)},t.prototype.ruleFinallyStateUpdate=function(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),0===this.RULE_STACK.length&&!1===this.isAtEndOfInput()){var t=this.LA(1),e=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:t,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new ve(e,t))}},t.prototype.subruleInternal=function(t,e,n){var r;try{var i=void 0!==n?n.ARGS:void 0;return r=t.call(this,e,i),this.cstPostNonTerminal(r,void 0!==n&&void 0!==n.LABEL?n.LABEL:t.ruleName),r}catch(e){this.subruleInternalError(e,n,t.ruleName)}},t.prototype.subruleInternalError=function(t,e,n){throw he(t)&&void 0!==t.partialCstResult&&(this.cstPostNonTerminal(t.partialCstResult,void 0!==e&&void 0!==e.LABEL?e.LABEL:n),delete t.partialCstResult),t},t.prototype.consumeInternal=function(t,e,n){var r;try{var i=this.LA(1);!0===this.tokenMatcher(i,t)?(this.consumeToken(),r=i):this.consumeInternalError(t,i,n)}catch(n){r=this.consumeInternalRecovery(t,e,n)}return this.cstPostTerminal(void 0!==n&&void 0!==n.LABEL?n.LABEL:t.name,r),r},t.prototype.consumeInternalError=function(t,e,n){var r,i=this.LA(0);throw r=void 0!==n&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:t,actual:e,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new de(r,e,i))},t.prototype.consumeInternalRecovery=function(t,e,n){if(!this.recoveryEnabled||"MismatchedTokenException"!==n.name||this.isBackTracking())throw n;var r=this.getFollowsForInRuleRecovery(t,e);try{return this.tryInRuleRecovery(t,r)}catch(t){throw"InRuleRecoveryException"===t.name?n:t}},t.prototype.saveRecogState=function(){var t=this.errors,e=Object(i.g)(this.RULE_STACK);return{errors:t,lexerState:this.exportLexerState(),RULE_STACK:e,CST_STACK:this.CST_STACK}},t.prototype.reloadRecogState=function(t){this.errors=t.errors,this.importLexerState(t.lexerState),this.RULE_STACK=t.RULE_STACK},t.prototype.ruleInvocationStateUpdate=function(t,e,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(t),this.cstInvocationStateUpdate(e,t)},t.prototype.isBackTracking=function(){return 0!==this.isBackTrackingStack.length},t.prototype.getCurrRuleFullName=function(){var t=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[t]},t.prototype.shortRuleNameToFullName=function(t){return this.shortRuleNameToFull[t]},t.prototype.isAtEndOfInput=function(){return this.tokenMatcher(this.LA(1),Z)},t.prototype.reset=function(){this.resetLexerState(),this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]},t}(),De=function(){function t(){}return t.prototype.initErrorHandler=function(t){this._errors=[],this.errorMessageProvider=Object(i.w)(t,"errorMessageProvider")?t.errorMessageProvider:Ze.errorMessageProvider},t.prototype.SAVE_ERROR=function(t){if(he(t))return t.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:Object(i.g)(this.RULE_OCCURRENCE_STACK)},this._errors.push(t),t;throw Error("Trying to save an Error which is not a RecognitionException")},Object.defineProperty(t.prototype,"errors",{get:function(){return Object(i.g)(this._errors)},set:function(t){this._errors=t},enumerable:!1,configurable:!0}),t.prototype.raiseEarlyExitException=function(t,e,n){for(var r=this.getCurrRuleFullName(),i=Qt(t,this.getGAstProductions()[r],e,this.maxLookahead)[0],o=[],a=1;a<=this.maxLookahead;a++)o.push(this.LA(a));var s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:i,actual:o,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new ge(s,this.LA(1),this.LA(0)))},t.prototype.raiseNoAltException=function(t,e){for(var n=this.getCurrRuleFullName(),r=Jt(t,this.getGAstProductions()[n],this.maxLookahead),i=[],o=1;o<=this.maxLookahead;o++)i.push(this.LA(o));var a=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:r,actual:i,previous:a,customUserDescription:e,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new me(s,this.LA(1),a))},t}(),Ue=function(){function t(){}return t.prototype.initContentAssist=function(){},t.prototype.computeContentAssist=function(t,e){var n=this.gastProductionsCache[t];if(Object(i.F)(n))throw Error("Rule ->"+t+"<- does not exist in this grammar.");return Ht([n],e,this.tokenMatcher,this.maxLookahead)},t.prototype.getNextPossibleTokenTypes=function(t){var e=Object(i.s)(t.ruleStack),n=this.getGAstProductions()[e];return new jt(n,t).startWalking()},t}(),Fe={description:"This Object indicates the Parser is during Recording Phase"};Object.freeze(Fe);var Be=Math.pow(2,8)-1,He=Q({name:"RECORDING_PHASE_TOKEN",pattern:$.NA});H([He]);var We=tt(He,"This IToken indicates the Parser is in Recording Phase\n\tSee: https://sap.github.io/chevrotain/docs/guide/internals.html#grammar-recording for details",-1,-1,-1,-1,-1,-1);Object.freeze(We);var Ge={name:"This CSTNode indicates the Parser is in Recording Phase\n\tSee: https://sap.github.io/chevrotain/docs/guide/internals.html#grammar-recording for details",children:{}},qe=function(){function t(){}return t.prototype.initGastRecorder=function(t){this.recordingProdStack=[],this.RECORDING_PHASE=!1},t.prototype.enableRecording=function(){var t=this;this.RECORDING_PHASE=!0,this.TRACE_INIT("Enable Recording",(function(){for(var e=function(e){var n=e>0?e:"";t["CONSUME"+n]=function(t,n){return this.consumeInternalRecord(t,e,n)},t["SUBRULE"+n]=function(t,n){return this.subruleInternalRecord(t,e,n)},t["OPTION"+n]=function(t){return this.optionInternalRecord(t,e)},t["OR"+n]=function(t){return this.orInternalRecord(t,e)},t["MANY"+n]=function(t){this.manyInternalRecord(e,t)},t["MANY_SEP"+n]=function(t){this.manySepFirstInternalRecord(e,t)},t["AT_LEAST_ONE"+n]=function(t){this.atLeastOneInternalRecord(e,t)},t["AT_LEAST_ONE_SEP"+n]=function(t){this.atLeastOneSepFirstInternalRecord(e,t)}},n=0;n<10;n++)e(n);t.consume=function(t,e,n){return this.consumeInternalRecord(e,t,n)},t.subrule=function(t,e,n){return this.subruleInternalRecord(e,t,n)},t.option=function(t,e){return this.optionInternalRecord(e,t)},t.or=function(t,e){return this.orInternalRecord(e,t)},t.many=function(t,e){this.manyInternalRecord(t,e)},t.atLeastOne=function(t,e){this.atLeastOneInternalRecord(t,e)},t.ACTION=t.ACTION_RECORD,t.BACKTRACK=t.BACKTRACK_RECORD,t.LA=t.LA_RECORD}))},t.prototype.disableRecording=function(){var t=this;this.RECORDING_PHASE=!1,this.TRACE_INIT("Deleting Recording methods",(function(){for(var e=0;e<10;e++){var n=e>0?e:"";delete t["CONSUME"+n],delete t["SUBRULE"+n],delete t["OPTION"+n],delete t["OR"+n],delete t["MANY"+n],delete t["MANY_SEP"+n],delete t["AT_LEAST_ONE"+n],delete t["AT_LEAST_ONE_SEP"+n]}delete t.consume,delete t.subrule,delete t.option,delete t.or,delete t.many,delete t.atLeastOne,delete t.ACTION,delete t.BACKTRACK,delete t.LA}))},t.prototype.ACTION_RECORD=function(t){},t.prototype.BACKTRACK_RECORD=function(t,e){return function(){return!0}},t.prototype.LA_RECORD=function(t){return Je},t.prototype.topLevelRuleRecord=function(t,e){try{var n=new ot({definition:[],name:t});return n.name=t,this.recordingProdStack.push(n),e.call(this),this.recordingProdStack.pop(),n}catch(t){if(!0!==t.KNOWN_RECORDER_ERROR)try{t.message=t.message+'\n\t This error was thrown during the "grammar recording phase" For more info see:\n\thttps://sap.github.io/chevrotain/docs/guide/internals.html#grammar-recording'}catch(e){throw t}throw t}},t.prototype.optionInternalRecord=function(t,e){return Ve.call(this,st,t,e)},t.prototype.atLeastOneInternalRecord=function(t,e){Ve.call(this,ct,e,t)},t.prototype.atLeastOneSepFirstInternalRecord=function(t,e){Ve.call(this,ut,e,t,!0)},t.prototype.manyInternalRecord=function(t,e){Ve.call(this,lt,e,t)},t.prototype.manySepFirstInternalRecord=function(t,e){Ve.call(this,ft,e,t,!0)},t.prototype.orInternalRecord=function(t,e){return Ke.call(this,t,e)},t.prototype.subruleInternalRecord=function(t,e,n){if($e(e),!t||!1===Object(i.w)(t,"ruleName")){var r=new Error("<SUBRULE"+ze(e)+"> argument is invalid expecting a Parser method reference but got: <"+JSON.stringify(t)+">\n inside top level rule: <"+this.recordingProdStack[0].name+">");throw r.KNOWN_RECORDER_ERROR=!0,r}var o=Object(i.M)(this.recordingProdStack),a=t.ruleName,s=new it({idx:e,nonTerminalName:a,referencedRule:void 0});return o.definition.push(s),this.outputCst?Ge:Fe},t.prototype.consumeInternalRecord=function(t,e,n){if($e(e),!W(t)){var r=new Error("<CONSUME"+ze(e)+"> argument is invalid expecting a TokenType reference but got: <"+JSON.stringify(t)+">\n inside top level rule: <"+this.recordingProdStack[0].name+">");throw r.KNOWN_RECORDER_ERROR=!0,r}var o=Object(i.M)(this.recordingProdStack),a=new ht({idx:e,terminalType:t});return o.definition.push(a),We},t}();function Ve(t,e,n,r){void 0===r&&(r=!1),$e(n);var o=Object(i.M)(this.recordingProdStack),a=Object(i.B)(e)?e:e.DEF,s=new t({definition:[],idx:n});return r&&(s.separator=e.SEP),Object(i.w)(e,"MAX_LOOKAHEAD")&&(s.maxLookahead=e.MAX_LOOKAHEAD),this.recordingProdStack.push(s),a.call(this),o.definition.push(s),this.recordingProdStack.pop(),Fe}function Ke(t,e){var n=this;$e(e);var r=Object(i.M)(this.recordingProdStack),o=!1===Object(i.y)(t),a=!1===o?t:t.DEF,s=new pt({definition:[],idx:e,ignoreAmbiguities:o&&!0===t.IGNORE_AMBIGUITIES});Object(i.w)(t,"MAX_LOOKAHEAD")&&(s.maxLookahead=t.MAX_LOOKAHEAD);var c=Object(i.Q)(a,(function(t){return Object(i.B)(t.GATE)}));return s.hasPredicates=c,r.definition.push(s),Object(i.u)(a,(function(t){var e=new at({definition:[]});s.definition.push(e),Object(i.w)(t,"IGNORE_AMBIGUITIES")?e.ignoreAmbiguities=t.IGNORE_AMBIGUITIES:Object(i.w)(t,"GATE")&&(e.ignoreAmbiguities=!0),n.recordingProdStack.push(e),t.ALT.call(n),n.recordingProdStack.pop()})),Fe}function ze(t){return 0===t?"":""+t}function $e(t){if(t<0||t>Be){var e=new Error("Invalid DSL Method idx value: <"+t+">\n\tIdx value must be a none negative value smaller than "+(Be+1));throw e.KNOWN_RECORDER_ERROR=!0,e}}var Ye=function(){function t(){}return t.prototype.initPerformanceTracer=function(t){if(Object(i.w)(t,"traceInitPerf")){var e=t.traceInitPerf,n="number"==typeof e;this.traceInitMaxIdent=n?e:1/0,this.traceInitPerf=n?e>0:e}else this.traceInitMaxIdent=0,this.traceInitPerf=Ze.traceInitPerf;this.traceInitIndent=-1},t.prototype.TRACE_INIT=function(t,e){if(!0===this.traceInitPerf){this.traceInitIndent++;var n=new Array(this.traceInitIndent+1).join("\t");this.traceInitIndent<this.traceInitMaxIdent&&console.log(n+"--\x3e <"+t+">");var r=Object(i.R)(e),o=r.time,a=r.value,s=o>10?console.warn:console.log;return this.traceInitIndent<this.traceInitMaxIdent&&s(n+"<-- <"+t+"> time: "+o+"ms"),this.traceInitIndent--,a}return e()},t}(),Xe=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Je=tt(Z,"",NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(Je);var Qe,Ze=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:Ct,nodeLocationTracking:"none",traceInitPerf:!1,skipValidations:!1}),tn=Object.freeze({recoveryValueFunc:function(){},resyncEnabled:!0});function en(t){return void 0===t&&(t=void 0),function(){return t}}!function(t){t[t.INVALID_RULE_NAME=0]="INVALID_RULE_NAME",t[t.DUPLICATE_RULE_NAME=1]="DUPLICATE_RULE_NAME",t[t.INVALID_RULE_OVERRIDE=2]="INVALID_RULE_OVERRIDE",t[t.DUPLICATE_PRODUCTIONS=3]="DUPLICATE_PRODUCTIONS",t[t.UNRESOLVED_SUBRULE_REF=4]="UNRESOLVED_SUBRULE_REF",t[t.LEFT_RECURSION=5]="LEFT_RECURSION",t[t.NONE_LAST_EMPTY_ALT=6]="NONE_LAST_EMPTY_ALT",t[t.AMBIGUOUS_ALTS=7]="AMBIGUOUS_ALTS",t[t.CONFLICT_TOKENS_RULES_NAMESPACE=8]="CONFLICT_TOKENS_RULES_NAMESPACE",t[t.INVALID_TOKEN_NAME=9]="INVALID_TOKEN_NAME",t[t.NO_NON_EMPTY_LOOKAHEAD=10]="NO_NON_EMPTY_LOOKAHEAD",t[t.AMBIGUOUS_PREFIX_ALTS=11]="AMBIGUOUS_PREFIX_ALTS",t[t.TOO_MANY_ALTS=12]="TOO_MANY_ALTS"}(Qe||(Qe={}));var nn=function(){function t(t,e){this.definitionErrors=[],this.selfAnalysisDone=!1;if(this.initErrorHandler(e),this.initLexerAdapter(),this.initLooksAhead(e),this.initRecognizerEngine(t,e),this.initRecoverable(e),this.initTreeBuilder(e),this.initContentAssist(),this.initGastRecorder(e),this.initPerformanceTracer(e),Object(i.w)(e,"ignoredIssues"))throw new Error("The <ignoredIssues> IParserConfig property has been deprecated.\n\tPlease use the <IGNORE_AMBIGUITIES> flag on the relevant DSL method instead.\n\tSee: https://sap.github.io/chevrotain/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES\n\tFor further details.");this.skipValidations=Object(i.w)(e,"skipValidations")?e.skipValidations:Ze.skipValidations}return t.performSelfAnalysis=function(t){throw Error("The **static** `performSelfAnalysis` method has been deprecated.\t\nUse the **instance** method with the same name instead.")},t.prototype.performSelfAnalysis=function(){var e=this;this.TRACE_INIT("performSelfAnalysis",(function(){var n;e.selfAnalysisDone=!0;var r=e.className;e.TRACE_INIT("toFastProps",(function(){Object(i.S)(e)})),e.TRACE_INIT("Grammar Recording",(function(){try{e.enableRecording(),Object(i.u)(e.definedRulesNames,(function(t){var n=e[t].originalGrammarAction,r=void 0;e.TRACE_INIT(t+" Rule",(function(){r=e.topLevelRuleRecord(t,n)})),e.gastProductionsCache[t]=r}))}finally{e.disableRecording()}}));var o=[];if(e.TRACE_INIT("Grammar Resolving",(function(){o=ue({rules:Object(i.U)(e.gastProductionsCache)}),e.definitionErrors.push.apply(e.definitionErrors,o)})),e.TRACE_INIT("Grammar Validations",(function(){if(Object(i.A)(o)&&!1===e.skipValidations){var t=le({rules:Object(i.U)(e.gastProductionsCache),maxLookahead:e.maxLookahead,tokenTypes:Object(i.U)(e.tokensMap),errMsgProvider:kt,grammarName:r});e.definitionErrors.push.apply(e.definitionErrors,t)}})),Object(i.A)(e.definitionErrors)&&(e.recoveryEnabled&&e.TRACE_INIT("computeAllProdsFollows",(function(){var t,n,r=(t=Object(i.U)(e.gastProductionsCache),n={},Object(i.u)(t,(function(t){var e=new Rt(t).startWalking();Object(i.f)(n,e)})),n);e.resyncFollows=r})),e.TRACE_INIT("ComputeLookaheadFunctions",(function(){e.preComputeLookaheadFunctions(Object(i.U)(e.gastProductionsCache))}))),!t.DEFER_DEFINITION_ERRORS_HANDLING&&!Object(i.A)(e.definitionErrors))throw n=Object(i.I)(e.definitionErrors,(function(t){return t.message})),new Error("Parser Definition Errors detected:\n "+n.join("\n-------------------------------\n"))}))},t.DEFER_DEFINITION_ERRORS_HANDLING=!1,t}();Object(i.e)(nn,[Oe,Se,_e,je,Pe,Me,De,Ue,qe,Ye]);var rn=function(t){function e(e,n){void 0===n&&(n=Ze);var r=Object(i.h)(n);return r.outputCst=!0,t.call(this,e,r)||this}return Xe(e,t),e}(nn),on=function(t){function e(e,n){void 0===n&&(n=Ze);var r=Object(i.h)(n);return r.outputCst=!1,t.call(this,e,r)||this}return Xe(e,t),e}(nn);function an(t,e){var n=void 0===e?{}:e,i=n.resourceBase,o=void 0===i?"https://unpkg.com/chevrotain@"+r+"/diagrams/":i,a=n.css;return'\n\x3c!-- This is a generated file --\x3e\n<!DOCTYPE html>\n<meta charset="utf-8">\n<style>\n body {\n background-color: hsl(30, 20%, 95%)\n }\n</style>\n\n'+("\n<link rel='stylesheet' href='"+(void 0===a?"https://unpkg.com/chevrotain@"+r+"/diagrams/diagrams.css":a)+"'>\n")+("\n<script src='"+o+"vendor/railroad-diagrams.js'><\/script>\n<script src='"+o+"src/diagrams_builder.js'><\/script>\n<script src='"+o+"src/diagrams_behavior.js'><\/script>\n<script src='"+o+"src/main.js'><\/script>\n")+'\n<div id="diagrams" align="center"></div> \n'+("\n<script>\n window.serializedGrammar = "+JSON.stringify(t,null," ")+";\n<\/script>\n")+'\n<script>\n var diagramsDiv = document.getElementById("diagrams");\n main.drawDiagramsFromSerializedGrammar(serializedGrammar, diagramsDiv);\n<\/script>\n'}var sn="\n";function cn(t){var e;return"\nfunction "+t.name+"(tokenVocabulary, config) {\n // invoke super constructor\n // No support for embedded actions currently, so we can 'hardcode'\n // The use of CstParser.\n chevrotain.CstParser.call(this, tokenVocabulary, config)\n\n const $ = this\n\n "+(e=t.rules,Object(i.I)(e,(function(t){return r=dn(n=1,'$.RULE("'+(e=t).name+'", function() {')+sn,r+=hn(e.definition,n+1),r+=dn(n+1,"})")+sn;var e,n,r})).join("\n")+"\n\n // very important to call this after all the rules have been defined.\n // otherwise the parser may not work correctly as it will lack information\n // derived during the self analysis phase.\n this.performSelfAnalysis(this)\n}\n\n// inheritance as implemented in javascript in the previous decade... :(\n")+t.name+".prototype = Object.create(chevrotain.CstParser.prototype)\n"+t.name+".prototype.constructor = "+t.name+" \n "}function un(t,e){var n=dn(e,"$.OR"+t.idx+"([")+sn,r=Object(i.I)(t.definition,(function(t){return function(t,e){var n=dn(e,"{")+sn;return n+=dn(e+1,"ALT: function() {")+sn,n+=hn(t.definition,e+1),n+=dn(e+1,"}")+sn,n+=dn(e,"}")}(t,e+1)}));return n+=r.join(",\n"),n+=sn+dn(e,"])\n")}function ln(t,e){if(t instanceof it)return function(t,e){return dn(e,"$.SUBRULE"+t.idx+"($."+t.nonTerminalName+")"+sn)}(t,e);if(t instanceof st)return fn("OPTION",t,e);if(t instanceof ct)return fn("AT_LEAST_ONE",t,e);if(t instanceof ut)return fn("AT_LEAST_ONE_SEP",t,e);if(t instanceof ft)return fn("MANY_SEP",t,e);if(t instanceof lt)return fn("MANY",t,e);if(t instanceof pt)return un(t,e);if(t instanceof ht)return function(t,e){var n=t.terminalType.name;return dn(e,"$.CONSUME"+t.idx+"(this.tokensMap."+n+")"+sn)}(t,e);if(t instanceof at)return hn(t.definition,e);throw Error("non exhaustive match")}function fn(t,e,n){var r=dn(n,"$."+(t+e.idx)+"(");return e.separator?(r+="{\n",r+=dn(n+1,"SEP: this.tokensMap."+e.separator.name)+","+sn,r+="DEF: "+pn(e.definition,n+2)+sn,r+=dn(n,"}")+sn):r+=pn(e.definition,n+1),r+=dn(n,")")+sn}function pn(t,e){var n="function() {\n";return n+=hn(t,e),n+=dn(e,"}")+sn}function hn(t,e){var n="";return Object(i.u)(t,(function(t){n+=ln(t,e+1)})),n}function dn(t,e){return Array(4*t+1).join(" ")+e}function mn(t){var e=function(t){return" \n"+cn(t)+"\nreturn new "+t.name+"(tokenVocabulary, config) \n"}({name:t.name,rules:t.rules}),r=new Function("tokenVocabulary","config","chevrotain",e);return function(e){return r(t.tokenVocabulary,e,n(3))}}function vn(t){return function(t){return"\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n // AMD. Register as an anonymous module.\n define(['chevrotain'], factory);\n } else if (typeof module === 'object' && module.exports) {\n // Node. Does not work with strict CommonJS, but\n // only CommonJS-like environments that support module.exports,\n // like Node.\n module.exports = factory(require('chevrotain'));\n } else {\n // Browser globals (root is window)\n root.returnExports = factory(root.b);\n }\n}(typeof self !== 'undefined' ? self : this, function (chevrotain) {\n\n"+cn(t)+"\n \nreturn {\n "+t.name+": "+t.name+" \n}\n}));\n"}({name:t.name,rules:t.rules})}function gn(){console.warn("The clearCache function was 'soft' removed from the Chevrotain API.\n\t It performs no action other than printing this message.\n\t Please avoid using it as it will be completely removed in the future")}var yn=function(){throw new Error("The Parser class has been deprecated, use CstParser or EmbeddedActionsParser instead.\t\nSee: https://sap.github.io/chevrotain/docs/changes/BREAKING_CHANGES.html#_7-0-0")}},function(t,e,n){"use strict";
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */Object.defineProperty(e,"__esModule",{value:!0}),e.AllTokens=e.Outdent=e.Indent=e.StringLiteral=e.NumberLiteral=e.Identifier=e.MultilineComment=e.SingleLineComment=e.WS=e.EndOfLine=e.OrMore=e.CaseSensitive=e.CaseInsensitive=e.CarriageReturn=e.Newline=e.Repeat=e.Called=e.Create=e.To=e.From=e.Exclusive=e.Inclusive=e.Exactly=e.Times=e.A=e.Group=e.Linefeed=e.Tab=e.Between=e.Not=e.Matching=e.Exact=e.Multiline=e.Global=e.Using=e.Number=e.Whitespace=e.Character=e.Digit=e.Word=e.And=e.Or=e.Anything=e.Then=e.Match=e.Optional=e.Ten=e.Nine=e.Eight=e.Seven=e.Six=e.Five=e.Four=e.Three=e.Two=e.One=e.Zero=void 0;const r=n(3);e.Zero=r.createToken({name:"Zero",pattern:/zero/i}),e.One=r.createToken({name:"One",pattern:/one/i}),e.Two=r.createToken({name:"Two",pattern:/two/i}),e.Three=r.createToken({name:"Three",pattern:/three/i}),e.Four=r.createToken({name:"Four",pattern:/four/i}),e.Five=r.createToken({name:"Five",pattern:/five/i}),e.Six=r.createToken({name:"Six",pattern:/six/i}),e.Seven=r.createToken({name:"Seven",pattern:/seven/i}),e.Eight=r.createToken({name:"Eight",pattern:/eight/i}),e.Nine=r.createToken({name:"Nine",pattern:/nine/i}),e.Ten=r.createToken({name:"Ten",pattern:/ten/i}),e.Optional=r.createToken({name:"Optional",pattern:/optional(ly)?/i}),e.Match=r.createToken({name:"Match",pattern:/match(es)?/i}),e.Then=r.createToken({name:"Then",pattern:/then/i}),e.Anything=r.createToken({name:"Anything",pattern:/(any thing|any|anything)(s)?/i}),e.Or=r.createToken({name:"Or",pattern:/or/i}),e.And=r.createToken({name:"And",pattern:/and|,/i}),e.Word=r.createToken({name:"WordSpecifier",pattern:/word(s)?/i}),e.Digit=r.createToken({name:"DigitSpecifier",pattern:/digit(s)?/i}),e.Character=r.createToken({name:"CharacterSpecifier",pattern:/character(s)?/i}),e.Whitespace=r.createToken({name:"WhitespaceSpecifier",pattern:/(white space|whitespace)(s)?/i}),e.Number=r.createToken({name:"NumberSpecifier",pattern:/number(s)?/i}),e.Using=r.createToken({name:"Using",pattern:/using/i}),e.Global=r.createToken({name:"Global",pattern:/global/i}),e.Multiline=r.createToken({name:"Multiline",pattern:/(multi line|multiline)/i}),e.Exact=r.createToken({name:"Exact",pattern:/exact/i}),e.Matching=r.createToken({name:"Matching",pattern:/matching/i}),e.Not=r.createToken({name:"Not",pattern:/not/i}),e.Between=r.createToken({name:"Between",pattern:/between/i}),e.Tab=r.createToken({name:"Tab",pattern:/tab/i}),e.Linefeed=r.createToken({name:"Linefeed",pattern:/(line feed|linefeed)/i}),e.Group=r.createToken({name:"Group",pattern:/group/i}),e.A=r.createToken({name:"A",pattern:/a(n)?/i}),e.Times=r.createToken({name:"Times",pattern:/times/i}),e.Exactly=r.createToken({name:"Exactly",pattern:/exact(ly)?/i}),e.Inclusive=r.createToken({name:"Inclusive",pattern:/inclusive(ly)?/i}),e.Exclusive=r.createToken({name:"Exclusive",pattern:/exclusive(ly)?/i}),e.From=r.createToken({name:"From",pattern:/from/i}),e.To=r.createToken({name:"To",pattern:/(to|through|thru|\-|\.\.|\.\.\.)/i}),e.Create=r.createToken({name:"Create",pattern:/create(s)?/i}),e.Called=r.createToken({name:"Called",pattern:/name(d)?|call(ed)?/i}),e.Repeat=r.createToken({name:"Repeat",pattern:/repeat(s|ing)?/i}),e.Newline=r.createToken({name:"Newline",pattern:/(new line|newline)/i}),e.CarriageReturn=r.createToken({name:"CarriageReturn",pattern:/carriage return/i}),e.CaseInsensitive=r.createToken({name:"CaseInsensitive",pattern:/case insensitive/i}),e.CaseSensitive=r.createToken({name:"CaseSensitive",pattern:/case sensitive/i}),e.OrMore=r.createToken({name:"OrMore",pattern:/\+|or more/i}),e.EndOfLine=r.createToken({name:"EOL",pattern:/\n/}),e.WS=r.createToken({name:"Whitespace",pattern:/\s+/,group:r.Lexer.SKIPPED}),e.SingleLineComment=r.createToken({name:"SingleLineComment",pattern:/(#|\/\/).*/,group:r.Lexer.SKIPPED}),e.MultilineComment=r.createToken({name:"MultiLineComment",pattern:/\/\*(.*)\*\//,line_breaks:!0,group:r.Lexer.SKIPPED}),e.Identifier=r.createToken({name:"Identifier",pattern:/[a-z]\w*/i}),e.NumberLiteral=r.createToken({name:"NumberLiteral",pattern:/-?\d+/}),e.StringLiteral=r.createToken({name:"StringLiteral",pattern:/"(?:[^\\"]|\\(?:[bfnrtv"\\/]|u[0-9a-f]{4}|U[0-9a-f]{8}))*"/i}),e.Indent=r.createToken({name:"Indent"}),e.Outdent=r.createToken({name:"Outdent"}),e.AllTokens=[e.Zero,e.One,e.Two,e.Three,e.Four,e.Five,e.Six,e.Seven,e.Eight,e.Nine,e.Ten,e.Optional,e.Matching,e.Match,e.Then,e.Anything,e.And,e.Word,e.Digit,e.Character,e.Whitespace,e.Number,e.Using,e.Global,e.Multiline,e.Exact,e.Not,e.Between,e.Tab,e.Linefeed,e.Group,e.A,e.Times,e.Exactly,e.Inclusive,e.Exclusive,e.From,e.Create,e.Called,e.Repeat,e.Newline,e.CarriageReturn,e.CaseInsensitive,e.CaseSensitive,e.OrMore,e.Or,e.To,e.EndOfLine,e.Indent,e.WS,e.SingleLineComment,e.MultilineComment,e.Identifier,e.NumberLiteral,e.StringLiteral]},function(t,e,n){"use strict";
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */Object.defineProperty(e,"__esModule",{value:!0}),e.RegularExpressionCST=e.GroupStatementCST=e.RepeatStatementCST=e.MatchStatementCST=e.CountSubStatementCST=e.UsingStatementCST=e.MatchSubStatementCST=e.StatementCST=e.MatchStatementValue=e.MatchSubStatementValue=e.MatchSubStatementType=e.UsingFlags=e.H2RCST=e.RobotLanguage=void 0;const r=n(2);var i,o,a;!function(t){t[t.JS=0]="JS",t[t.Perl=1]="Perl",t[t.DotNet=2]="DotNet",t[t.Java=3]="Java"}(i=e.RobotLanguage||(e.RobotLanguage={}));class s{constructor(t){this.tokens=t}error(t){var e,n,i;const o=r.first(this.tokens),a=r.last(this.tokens);return{startLine:null!==(e=o.startLine)&&void 0!==e?e:NaN,startColumn:null!==(n=o.startColumn)&&void 0!==n?n:NaN,length:(null!==(i=a.endOffset)&&void 0!==i?i:a.startOffset)-o.startOffset,message:t}}}e.H2RCST=s,function(t){t[t.Multiline=1]="Multiline",t[t.Global=2]="Global",t[t.Sensitive=4]="Sensitive",t[t.Insensitive=8]="Insensitive",t[t.Exact=16]="Exact"}(o=e.UsingFlags||(e.UsingFlags={})),function(t){t[t.SingleString=0]="SingleString",t[t.Between=1]="Between",t[t.Anything=2]="Anything",t[t.Word=3]="Word",t[t.Digit=4]="Digit",t[t.Character=5]="Character",t[t.Whitespace=6]="Whitespace",t[t.Number=7]="Number",t[t.Tab=8]="Tab",t[t.Linefeed=9]="Linefeed",t[t.Newline=10]="Newline",t[t.CarriageReturn=11]="CarriageReturn"}(a=e.MatchSubStatementType||(e.MatchSubStatementType={}));e.MatchSubStatementValue=class{constructor(t,e=null,n=null){this.type=t,this.from=e,this.to=n}};e.MatchStatementValue=class{constructor(t,e){this.optional=t,this.statement=e}};class c extends s{}e.StatementCST=c;e.MatchSubStatementCST=class extends s{constructor(t,e,n=!1,r){super(t),this.tokens=t,this.count=e,this.invert=n,this.values=r}validate(t){let e=[];this.count&&(e=e.concat(this.count.validate(t)));for(const t of this.values)if(t.type===a.Between){let n=t.from,i=t.to;r.isSingleRegexCharacter(n)?(n.startsWith("\\u")||n.startsWith("\\U")||n.startsWith("\\"))&&(n=JSON.parse(`"${r.regexEscape(n)}"`)):e.push(this.error("Between statement must begin with a single character")),r.isSingleRegexCharacter(i)?(i.startsWith("\\u")||i.startsWith("\\U")||i.startsWith("\\"))&&(i=JSON.parse(`"${r.regexEscape(i)}"`)):e.push(this.error("Between statement must end with a single character")),n.charCodeAt(0)>=i.charCodeAt(0)&&e.push(this.error("Between statement range invalid"))}return e}toRegex(t){const e=[];for(const t of this.values)switch(t.type){case a.SingleString:{const n=r.regexEscape(r.removeQuotes(t.from));e.push(this.invert?`(?:(?!${n}))`:n);break}case a.Between:e.push(this.invert?`[^${t.from}-${t.to}]`:`[${t.from}-${t.to}]`);break;case a.Word:e.push(this.invert?"\\W+":"\\w+");break;case a.Digit:e.push(this.invert?"\\D":"\\d");break;case a.Character:e.push(this.invert?"\\W":"\\w");break;case a.Whitespace:e.push(this.invert?"\\S":"\\s");break;case a.Number:e.push(this.invert?"\\D+":"\\d+");break;case a.Tab:e.push(this.invert?"[^\\t]":"\\t");break;case a.Newline:case a.Linefeed:e.push(this.invert?"[^\\n]":"\\n");break;case a.CarriageReturn:e.push(this.invert?"[^\\r]":"\\r");break;default:e.push(this.invert?"[^.]":".")}let n="";return n=1===e.length?e[0]:e.every(r.isSingleRegexCharacter)?"["+e.join("")+"]":"(?:"+e.join("|")+")",this.count&&(1===this.count.from&&null===this.count.to?"+"===this.count.opt&&(n+="+"):0===this.count.from&&null===this.count.to?"+"===this.count.opt?n+="*":n="":n+=this.count.toRegex(t)),n}};e.UsingStatementCST=class extends s{constructor(t,e){super(t),this.tokens=t,this.flags=e}validate(t){const e=[];let n=this.flags[0];for(let t=1;t<this.flags.length;t++)r.hasFlag(n,this.flags[t])&&e.push(this.error("Duplicate modifier: "+a[this.flags[t]])),n=r.combineFlags(n,this.flags[t]);return r.hasFlag(n,o.Sensitive)&&r.hasFlag(n,o.Insensitive)&&e.push(this.error("Cannot be both case sensitive and insensitive")),e}toRegex(t){let e="",n=!1;for(const t of this.flags)r.hasFlag(t,o.Multiline)?e+="m":r.hasFlag(t,o.Global)?e+="g":r.hasFlag(t,o.Insensitive)?e+="i":r.hasFlag(t,o.Exact)&&(n=!0);return n?"/^{regex}$/"+e:"/{regex}/"+e}};e.CountSubStatementCST=class extends s{constructor(t,e,n=null,r=null){super(t),this.tokens=t,this.from=e,this.to=n,this.opt=r}validate(t){const e=[];return this.from<0?e.push(this.error("Value cannot be negative")):null!==this.to&&("exclusive"===this.opt&&this.to-1<=this.from||this.to<=this.from)&&e.push(this.error("Values must be in range of eachother")),e}toRegex(t){const e=this.from;let n=this.to;return null!==n&&"exclusive"===this.opt&&n--,null!==n?`{${e},${n}}`:"+"===this.opt?`{${e},}`:`{${this.from}}`}};e.MatchStatementCST=class extends c{constructor(t,e){super(t),this.tokens=t,this.matches=e}validate(t){let e=[];for(const n of this.matches)e=e.concat(n.statement.validate(t));return e}toRegex(t){return this.matches.map(e=>e.statement.toRegex(t)+(e.optional?"?":"")).join("")}};e.RepeatStatementCST=class extends c{constructor(t,e,n,r){super(t),this.tokens=t,this.optional=e,this.count=n,this.statements=r}validate(t){let e=[];null!==this.count&&(e=e.concat(this.count.validate(t)));for(const n of this.statements)e=e.concat(n.validate(t));return e}toRegex(t){let e="("+this.statements.map(e=>e.toRegex(t)).join("")+")";return null!==this.count?1===this.count.from&&null===this.count.to?"+"===this.count.opt&&(e+="+"):0===this.count.from&&null===this.count.to?"+"===this.count.opt?e+="*":e="":e+=this.count.toRegex(t):e+="*",e}};e.GroupStatementCST=class extends c{constructor(t,e,n,r){super(t),this.tokens=t,this.optional=e,this.name=n,this.statements=r}validate(t){let e=[];t!==i.DotNet&&t!==i.JS&&e.push(this.error("This language does not support named groups"));for(const n of this.statements)e=e.concat(n.validate(t));return e}toRegex(t){let e="(";return null!==this.name&&(e+=`?<${this.name}>`),e+=this.statements.map(e=>e.toRegex(t)).join(""),e+=")",this.optional&&(e+="?"),e}};e.RegularExpressionCST=class extends s{constructor(t,e,n){super(t),this.tokens=t,this.usings=e,this.statements=n}validate(t){let e=this.usings.validate(t);for(const n of this.statements)e=e.concat(n.validate(t));return e}toRegex(t){const e=this.usings.toRegex(t),n=this.statements.map(e=>e.toRegex(t)).join("");return e.replace("{regex}",n)}}},function(t,e,n){"use strict";
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=n(7),o=n(8),a=n(5),s=n(2),c=r(n(9));n(10),n(11),n(12),c.default((function(){const t=[],e=new i.Human2RegexLexer(new i.Human2RegexLexerOptions(!0)),n=new o.Human2RegexParser(new o.Human2RegexParserOptions(!0)),r=e.tokenize(c.default("#human").text());if(r.errors.map(s.lexErrorToCommonError).forEach(e=>t.push(e)),0===t.length){n.input=r.tokens;const e=n.parse();n.errors.map(s.parseErrorToCommonError).forEach(e=>t.push(e));let i=a.RobotLanguage.JS;switch(c.default("#dialect option:selected").val()){case"dotnet":i=a.RobotLanguage.DotNet;break;case"java":i=a.RobotLanguage.Java;break;case"perl":i=a.RobotLanguage.Perl;break;default:i=a.RobotLanguage.JS}if(e.validate(i).map(s.semanticErrorToCommonError).forEach(e=>t.push(e)),0===t.length){const t=e.toRegex(i);c.default("#regex").attr("value",t)}}console.log("Errors = "+t),c.default("#dialect").on("selectionchanged",()=>{}),c.default("#human").on("input",()=>{})}))},function(t,e,n){"use strict";
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */Object.defineProperty(e,"__esModule",{value:!0}),e.Human2RegexLexer=e.Human2RegexLexerOptions=e.IndentType=void 0;const r=n(3),i=n(2),o=n(4);var a;!function(t){t[t.Tabs=0]="Tabs",t[t.Spaces=1]="Spaces",t[t.Both=2]="Both"}(a=e.IndentType||(e.IndentType={}));class s{constructor(t=!1,e=a.Both,n=4){this.skip_validations=t,this.type=e,this.spaces_per_tab=n}}e.Human2RegexLexerOptions=s;class c{constructor(t=new s){if(c.already_init)throw new Error("Only 1 instance of Human2RegexLexer allowed");c.already_init=!0,this.setOptions(t)}setOptions(t){this.options=t;let e=null;if(this.options.type===a.Tabs)e=/\t/y;else{let t=` {${this.options.spaces_per_tab}}`;this.options.type===a.Both&&(t+="|\\t"),e=new RegExp(t,"y")}o.Indent.PATTERN=e,this.lexer=new r.Lexer(o.AllTokens,{ensureOptimizations:!0,skipValidations:t.skip_validations})}lexError(t){var e,n,r;return{offset:t.startOffset,line:null!==(e=t.startLine)&&void 0!==e?e:NaN,column:null!==(n=t.startColumn)&&void 0!==n?n:NaN,length:null!==(r=t.endOffset)&&void 0!==r?r:NaN-t.startOffset,message:"Unexpected indentation found"}}tokenize(t){var e,n,a,s,c,u,l,f,p,h,d,m,v,g;const y=this.lexer.tokenize(t);if(0===y.tokens.length)return y;const T=[],O=[0];let E=0,b=!0,S=!1;for(let t=0;t<y.tokens.length;t++)if(y.tokens[t].tokenType===o.EndOfLine)0===T.length||T[T.length-1].tokenType===o.EndOfLine||(b=!0,T.push(y.tokens[t]));else if(y.tokens[t].tokenType===o.Indent){S=!0,E=1;const c=y.tokens[t];let u=y.tokens[t].image.length;for(;y.tokens.length>t&&y.tokens[t+1].tokenType===o.Indent;)E++,t++,u+=y.tokens[t].image.length;if(c.endOffset=c.startOffset+u,c.endColumn=y.tokens[t].endColumn,y.tokens.length>t&&y.tokens[t+1].tokenType===o.EndOfLine);else if(!b||E>i.last(O)+1)y.errors.push(this.lexError(c));else if(E>i.last(O))O.push(E),T.push(c);else if(E<i.last(O)){const t=i.findLastIndex(O,E);if(t<0)y.errors.push(this.lexError(c));else{const i=O.length-t-1;for(let t=0;t<i;t++)O.pop(),T.push(r.createTokenInstance(o.Outdent,"",c.startOffset,c.startOffset+u,null!==(e=c.startLine)&&void 0!==e?e:NaN,null!==(n=c.endLine)&&void 0!==n?n:NaN,null!==(a=c.startColumn)&&void 0!==a?a:NaN,(null!==(s=c.startColumn)&&void 0!==s?s:NaN)+u))}}}else{if(b&&!S){const e=y.tokens[t];for(;O.length>1;)O.pop(),T.push(r.createTokenInstance(o.Outdent,"",e.startOffset,e.startOffset,null!==(c=e.startLine)&&void 0!==c?c:NaN,NaN,null!==(u=e.startColumn)&&void 0!==u?u:NaN,NaN))}b=!1,S=!1,T.push(y.tokens[t])}const N=i.last(T);for(N.tokenType!==o.EndOfLine&&T.push(r.createTokenInstance(o.EndOfLine,"\n",null!==(l=N.endOffset)&&void 0!==l?l:NaN,null!==(f=N.endOffset)&&void 0!==f?f:NaN,null!==(p=N.startLine)&&void 0!==p?p:NaN,NaN,null!==(h=N.startColumn)&&void 0!==h?h:NaN,NaN));O.length>1;)O.pop(),T.push(r.createTokenInstance(o.Outdent,"",null!==(d=N.endOffset)&&void 0!==d?d:NaN,null!==(m=N.endOffset)&&void 0!==m?m:NaN,null!==(v=N.startLine)&&void 0!==v?v:NaN,NaN,null!==(g=N.startColumn)&&void 0!==g?g:NaN,NaN));return y.tokens=T,y}}e.Human2RegexLexer=c,c.already_init=!1},function(t,e,n){"use strict";
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),i=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),o=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&r(e,t,n);return i(e,t),e};Object.defineProperty(e,"__esModule",{value:!0}),e.Human2RegexParser=e.Human2RegexParserOptions=void 0;const a=n(3),s=o(n(4)),c=n(5),u=n(2);class l{constructor(t=!1){this.skip_validations=t}}e.Human2RegexParserOptions=l;class f{constructor(t,e){this.token=t,this.value=e}}class p{constructor(t,e){this.tokens=t,this.value=e}}class h extends a.EmbeddedActionsParser{constructor(t=new l){if(super(s.AllTokens,{recoveryEnabled:!1,maxLookahead:2,skipValidations:t.skip_validations}),this.options=t,h.already_init)throw new Error("Only 1 instance of Human2RegexParser allowed");h.already_init=!0;const e=this;let n=null;const r=e.RULE("NumberSubStatement",()=>e.OR(n||(n=[{ALT:()=>new f(e.CONSUME(s.Zero),0)},{ALT:()=>new f(e.CONSUME(s.One),1)},{ALT:()=>new f(e.CONSUME(s.Two),2)},{ALT:()=>new f(e.CONSUME(s.Three),3)},{ALT:()=>new f(e.CONSUME(s.Four),4)},{ALT:()=>new f(e.CONSUME(s.Five),5)},{ALT:()=>new f(e.CONSUME(s.Six),6)},{ALT:()=>new f(e.CONSUME(s.Seven),7)},{ALT:()=>new f(e.CONSUME(s.Eight),8)},{ALT:()=>new f(e.CONSUME(s.Nine),9)},{ALT:()=>new f(e.CONSUME(s.Ten),10)},{ALT:()=>{const t=e.CONSUME(s.NumberLiteral);return new f(t,parseInt(t.image))}}]))),i=e.RULE("CountSubStatement",()=>e.OR([{ALT:()=>{const t=[];t.push(e.CONSUME(s.Between));const n=e.SUBRULE4(r);e.OR3([{ALT:()=>e.CONSUME2(s.To)},{ALT:()=>e.CONSUME(s.And)}]);const i=e.SUBRULE5(r);t.push(i.token),e.OPTION4(()=>t.push(e.CONSUME3(s.Times)));const o=e.OPTION5(()=>e.OR4([{ALT:()=>(t.push(e.CONSUME(s.Inclusive)),"inclusive")},{ALT:()=>(t.push(e.CONSUME(s.Exclusive)),"exclusive")}]));return new c.CountSubStatementCST(t,n.value,i.value,o)}},{ALT:()=>{const t=[];e.OPTION2(()=>t.push(e.CONSUME(s.From)));const n=e.SUBRULE2(r),i=e.OR2([{ALT:()=>new f(e.CONSUME(s.OrMore),[null,"+"])},{ALT:()=>{e.CONSUME(s.To);const t=e.SUBRULE3(r);return new f(t.token,[t.value,null])}}]);return t.push(i.token),e.OPTION3(()=>t.push(e.CONSUME2(s.Times))),new c.CountSubStatementCST(t,n.value,i.value?i.value[0]:null,i.value?i.value[1]:null)}},{ALT:()=>{const t=[];e.OPTION(()=>t.push(e.CONSUME(s.Exactly)));const n=e.SUBRULE(r);return t.push(n.token),e.OPTION6(()=>t.push(e.CONSUME(s.Times))),new c.CountSubStatementCST(t,n.value)}}]));let o=null;const a=e.RULE("MatchSubStatement",()=>{let t=null,n=!1;const r=[];let a=null,l=null,f=c.MatchSubStatementType.Anything;const p=[];return t=e.OPTION(()=>{const t=e.SUBRULE(i);return t.tokens&&p.push(u.first(t.tokens)),t}),n=e.OPTION2(()=>(p.push(e.CONSUME(s.Not)),!0)),e.AT_LEAST_ONE_SEP({SEP:s.Or,DEF:()=>{e.OPTION3(()=>e.CONSUME(s.A)),r.push(e.OR(o||(o=[{ALT:()=>{e.OPTION4(()=>e.CONSUME(s.From)),a=e.CONSUME2(s.StringLiteral).image,e.CONSUME(s.To);const t=e.CONSUME3(s.StringLiteral);return p.push(t),l=t.image,f=c.MatchSubStatementType.Between,new c.MatchSubStatementValue(f,a,l)}},{ALT:()=>{e.CONSUME(s.Between),a=e.CONSUME4(s.StringLiteral).image,e.CONSUME(s.And);const t=e.CONSUME5(s.StringLiteral);return l=t.image,p.push(t),f=c.MatchSubStatementType.Between,new c.MatchSubStatementValue(f,a,l)}},{ALT:()=>{const t=e.CONSUME(s.StringLiteral);return p.push(t),a=t.image,f=c.MatchSubStatementType.SingleString,new c.MatchSubStatementValue(f,a)}},{ALT:()=>(p.push(e.CONSUME(s.Anything)),f=c.MatchSubStatementType.Anything,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Word)),f=c.MatchSubStatementType.Word,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Digit)),f=c.MatchSubStatementType.Digit,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Character)),f=c.MatchSubStatementType.Character,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Whitespace)),f=c.MatchSubStatementType.Whitespace,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Number)),f=c.MatchSubStatementType.Number,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Tab)),f=c.MatchSubStatementType.Tab,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Linefeed)),f=c.MatchSubStatementType.Linefeed,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.Newline)),f=c.MatchSubStatementType.Newline,new c.MatchSubStatementValue(f))},{ALT:()=>(p.push(e.CONSUME(s.CarriageReturn)),f=c.MatchSubStatementType.CarriageReturn,new c.MatchSubStatementValue(f))}])))}}),new c.MatchSubStatementCST(p,t,n,r)}),d=e.RULE("MatchStatement",()=>{let t=!1;const n=[],r=[];return e.OPTION(()=>{r.push(e.CONSUME(s.Optional)),t=!0}),r.push(e.CONSUME(s.Match)),n.push(new c.MatchStatementValue(t,e.SUBRULE(a))),e.MANY(()=>{e.OR([{ALT:()=>{e.OPTION2(()=>e.CONSUME2(s.And)),e.CONSUME(s.Then)}},{ALT:()=>e.CONSUME(s.And)}]),t=!1,e.OPTION3(()=>{e.CONSUME2(s.Optional),t=!0}),n.push(new c.MatchStatementValue(t,e.SUBRULE2(a)))}),r.push(e.CONSUME(s.EndOfLine)),new c.MatchStatementCST(r,n)});let m=null;const v=e.RULE("UsingStatement",()=>{const t=[],n=[e.CONSUME(s.Using)];return e.AT_LEAST_ONE_SEP({SEP:s.And,DEF:()=>{t.push(e.OR(m||(m=[{ALT:()=>(e.CONSUME(s.Multiline),c.UsingFlags.Multiline)},{ALT:()=>(e.CONSUME(s.Global),c.UsingFlags.Global)},{ALT:()=>(e.CONSUME(s.CaseInsensitive),c.UsingFlags.Insensitive)},{ALT:()=>(e.CONSUME(s.CaseSensitive),c.UsingFlags.Sensitive)},{ALT:()=>(e.CONSUME(s.Exact),c.UsingFlags.Exact)}]))),e.OPTION(()=>e.CONSUME(s.Matching))}}),n.push(e.CONSUME(s.EndOfLine)),new p(n,t)}),g=e.RULE("GroupStatement",()=>{const t=[];let n=!1,r=null;const i=[];return t.push(e.OR([{ALT:()=>{n=!0;const t=e.CONSUME(s.Optional);return e.CONSUME(s.Create),e.CONSUME(s.A),t}},{ALT:()=>{const t=e.CONSUME2(s.Create);return e.CONSUME2(s.A),e.OPTION2(()=>{e.CONSUME2(s.Optional),n=!0}),t}}])),e.CONSUME(s.Group),e.OPTION(()=>{e.CONSUME(s.Called),r=e.CONSUME(s.Identifier).image}),t.push(e.CONSUME2(s.EndOfLine)),e.CONSUME(s.Indent),e.AT_LEAST_ONE(()=>{i.push(e.SUBRULE(T))}),e.CONSUME(s.Outdent),new c.GroupStatementCST(t,n,r,i)}),y=e.RULE("RepeatStatement",()=>{const t=[];let n=!1,r=null;const o=[];return e.OPTION3(()=>{t.push(e.CONSUME(s.Optional)),n=!0}),t.push(e.CONSUME(s.Repeat)),e.OPTION(()=>r=e.SUBRULE(i)),e.CONSUME3(s.EndOfLine),e.CONSUME(s.Indent),e.AT_LEAST_ONE(()=>{o.push(e.SUBRULE(T))}),t.push(e.CONSUME(s.Outdent)),new c.RepeatStatementCST(t,n,r,o)}),T=e.RULE("Statement",()=>e.OR([{ALT:()=>e.SUBRULE(d)},{ALT:()=>e.SUBRULE(g)},{ALT:()=>e.SUBRULE(y)}])),O=e.RULE("Regex",()=>{let t=[],n=[];const r=[];return e.MANY(()=>{const r=e.SUBRULE(v);t=t.concat(r.tokens),n=n.concat(r.value)}),e.MANY2(()=>r.push(e.SUBRULE(T))),new c.RegularExpressionCST([],new c.UsingStatementCST(t,n),r)});this.performSelfAnalysis(),this.parse=O}}e.Human2RegexParser=h,h.already_init=!1},function(t,e,n){var r;
/*!
* jQuery JavaScript Library v3.5.1
* https://jquery.com/
*
* Includes Sizzle.js
* https://sizzlejs.com/
*
* Copyright JS Foundation and other contributors
* Released under the MIT license
* https://jquery.org/license
*
* Date: 2020-05-04T22:49Z
*/!function(e,n){"use strict";"object"==typeof t.exports?t.exports=e.document?n(e,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return n(t)}:n(e)}("undefined"!=typeof window?window:this,(function(n,i){"use strict";var o=[],a=Object.getPrototypeOf,s=o.slice,c=o.flat?function(t){return o.flat.call(t)}:function(t){return o.concat.apply([],t)},u=o.push,l=o.indexOf,f={},p=f.toString,h=f.hasOwnProperty,d=h.toString,m=d.call(Object),v={},g=function(t){return"function"==typeof t&&"number"!=typeof t.nodeType},y=function(t){return null!=t&&t===t.window},T=n.document,O={type:!0,src:!0,nonce:!0,noModule:!0};function E(t,e,n){var r,i,o=(n=n||T).createElement("script");if(o.text=t,e)for(r in O)(i=e[r]||e.getAttribute&&e.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function b(t){return null==t?t+"":"object"==typeof t||"function"==typeof t?f[p.call(t)]||"object":typeof t}var S=function(t,e){return new S.fn.init(t,e)};function N(t){var e=!!t&&"length"in t&&t.length,n=b(t);return!g(t)&&!y(t)&&("array"===n||0===e||"number"==typeof e&&e>0&&e-1 in t)}S.fn=S.prototype={jquery:"3.5.1",constructor:S,length:0,toArray:function(){return s.call(this)},get:function(t){return null==t?s.call(this):t<0?this[t+this.length]:this[t]},pushStack:function(t){var e=S.merge(this.constructor(),t);return e.prevObject=this,e},each:function(t){return S.each(this,t)},map:function(t){return this.pushStack(S.map(this,(function(e,n){return t.call(e,n,e)})))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(S.grep(this,(function(t,e){return(e+1)%2})))},odd:function(){return this.pushStack(S.grep(this,(function(t,e){return e%2})))},eq:function(t){var e=this.length,n=+t+(t<0?e:0);return this.pushStack(n>=0&&n<e?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:o.sort,splice:o.splice},S.extend=S.fn.extend=function(){var t,e,n,r,i,o,a=arguments[0]||{},s=1,c=arguments.length,u=!1;for("boolean"==typeof a&&(u=a,a=arguments[s]||{},s++),"object"==typeof a||g(a)||(a={}),s===c&&(a=this,s--);s<c;s++)if(null!=(t=arguments[s]))for(e in t)r=t[e],"__proto__"!==e&&a!==r&&(u&&r&&(S.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[e],o=i&&!Array.isArray(n)?[]:i||S.isPlainObject(n)?n:{},i=!1,a[e]=S.extend(u,o,r)):void 0!==r&&(a[e]=r));return a},S.extend({expando:"jQuery"+("3.5.1"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(t){throw new Error(t)},noop:function(){},isPlainObject:function(t){var e,n;return!(!t||"[object Object]"!==p.call(t))&&(!(e=a(t))||"function"==typeof(n=h.call(e,"constructor")&&e.constructor)&&d.call(n)===m)},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},globalEval:function(t,e,n){E(t,{nonce:e&&e.nonce},n)},each:function(t,e){var n,r=0;if(N(t))for(n=t.length;r<n&&!1!==e.call(t[r],r,t[r]);r++);else for(r in t)if(!1===e.call(t[r],r,t[r]))break;return t},makeArray:function(t,e){var n=e||[];return null!=t&&(N(Object(t))?S.merge(n,"string"==typeof t?[t]:t):u.call(n,t)),n},inArray:function(t,e,n){return null==e?-1:l.call(e,t,n)},merge:function(t,e){for(var n=+e.length,r=0,i=t.length;r<n;r++)t[i++]=e[r];return t.length=i,t},grep:function(t,e,n){for(var r=[],i=0,o=t.length,a=!n;i<o;i++)!e(t[i],i)!==a&&r.push(t[i]);return r},map:function(t,e,n){var r,i,o=0,a=[];if(N(t))for(r=t.length;o<r;o++)null!=(i=e(t[o],o,n))&&a.push(i);else for(o in t)null!=(i=e(t[o],o,n))&&a.push(i);return c(a)},guid:1,support:v}),"function"==typeof Symbol&&(S.fn[Symbol.iterator]=o[Symbol.iterator]),S.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),(function(t,e){f["[object "+e+"]"]=e.toLowerCase()}));var x=
/*!
* Sizzle CSS Selector Engine v2.3.5
* https://sizzlejs.com/
*
* Copyright JS Foundation and other contributors
* Released under the MIT license
* https://js.foundation/
*
* Date: 2020-03-14
*/
function(t){var e,n,r,i,o,a,s,c,u,l,f,p,h,d,m,v,g,y,T,O="sizzle"+1*new Date,E=t.document,b=0,S=0,N=ct(),x=ct(),A=ct(),R=ct(),C=function(t,e){return t===e&&(f=!0),0},I={}.hasOwnProperty,k=[],L=k.pop,w=k.push,_=k.push,j=k.slice,M=function(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n]===e)return n;return-1},P="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",D="[\\x20\\t\\r\\n\\f]",U="(?:\\\\[\\da-fA-F]{1,6}"+D+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",F="\\["+D+"*("+U+")(?:"+D+"*([*^$|!~]?=)"+D+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+U+"))|)"+D+"*\\]",B=":("+U+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+F+")*)|.*)\\)|)",H=new RegExp(D+"+","g"),W=new RegExp("^"+D+"+|((?:^|[^\\\\])(?:\\\\.)*)"+D+"+$","g"),G=new RegExp("^"+D+"*,"+D+"*"),q=new RegExp("^"+D+"*([>+~]|"+D+")"+D+"*"),V=new RegExp(D+"|>"),K=new RegExp(B),z=new RegExp("^"+U+"$"),$={ID:new RegExp("^#("+U+")"),CLASS:new RegExp("^\\.("+U+")"),TAG:new RegExp("^("+U+"|[*])"),ATTR:new RegExp("^"+F),PSEUDO:new RegExp("^"+B),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+D+"*(even|odd|(([+-]|)(\\d*)n|)"+D+"*(?:([+-]|)"+D+"*(\\d+)|))"+D+"*\\)|)","i"),bool:new RegExp("^(?:"+P+")$","i"),needsContext:new RegExp("^"+D+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+D+"*((?:-\\d)?\\d*)"+D+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,X=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,Q=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,tt=/[+~]/,et=new RegExp("\\\\[\\da-fA-F]{1,6}"+D+"?|\\\\([^\\r\\n\\f])","g"),nt=function(t,e){var n="0x"+t.slice(1)-65536;return e||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},rt=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,it=function(t,e){return e?"\0"===t?"<22>":t.slice(0,-1)+"\\"+t.charCodeAt(t.length-1).toString(16)+" ":"\\"+t},ot=function(){p()},at=Ot((function(t){return!0===t.disabled&&"fieldset"===t.nodeName.toLowerCase()}),{dir:"parentNode",next:"legend"});try{_.apply(k=j.call(E.childNodes),E.childNodes),k[E.childNodes.length].nodeType}catch(t){_={apply:k.length?function(t,e){w.apply(t,j.call(e))}:function(t,e){for(var n=t.length,r=0;t[n++]=e[r++];);t.length=n-1}}}function st(t,e,r,i){var o,s,u,l,f,d,g,y=e&&e.ownerDocument,E=e?e.nodeType:9;if(r=r||[],"string"!=typeof t||!t||1!==E&&9!==E&&11!==E)return r;if(!i&&(p(e),e=e||h,m)){if(11!==E&&(f=Z.exec(t)))if(o=f[1]){if(9===E){if(!(u=e.getElementById(o)))return r;if(u.id===o)return r.push(u),r}else if(y&&(u=y.getElementById(o))&&T(e,u)&&u.id===o)return r.push(u),r}else{if(f[2])return _.apply(r,e.getElementsByTagName(t)),r;if((o=f[3])&&n.getElementsByClassName&&e.getElementsByClassName)return _.apply(r,e.getElementsByClassName(o)),r}if(n.qsa&&!R[t+" "]&&(!v||!v.test(t))&&(1!==E||"object"!==e.nodeName.toLowerCase())){if(g=t,y=e,1===E&&(V.test(t)||q.test(t))){for((y=tt.test(t)&&gt(e.parentNode)||e)===e&&n.scope||((l=e.getAttribute("id"))?l=l.replace(rt,it):e.setAttribute("id",l=O)),s=(d=a(t)).length;s--;)d[s]=(l?"#"+l:":scope")+" "+Tt(d[s]);g=d.join(",")}try{return _.apply(r,y.querySelectorAll(g)),r}catch(e){R(t,!0)}finally{l===O&&e.removeAttribute("id")}}}return c(t.replace(W,"$1"),e,r,i)}function ct(){var t=[];return function e(n,i){return t.push(n+" ")>r.cacheLength&&delete e[t.shift()],e[n+" "]=i}}function ut(t){return t[O]=!0,t}function lt(t){var e=h.createElement("fieldset");try{return!!t(e)}catch(t){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function ft(t,e){for(var n=t.split("|"),i=n.length;i--;)r.attrHandle[n[i]]=e}function pt(t,e){var n=e&&t,r=n&&1===t.nodeType&&1===e.nodeType&&t.sourceIndex-e.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function ht(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function dt(t){return function(e){var n=e.nodeName.toLowerCase();return("input"===n||"button"===n)&&e.type===t}}function mt(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&at(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function vt(t){return ut((function(e){return e=+e,ut((function(n,r){for(var i,o=t([],n.length,e),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))}))}))}function gt(t){return t&&void 0!==t.getElementsByTagName&&t}for(e in n=st.support={},o=st.isXML=function(t){var e=t.namespaceURI,n=(t.ownerDocument||t).documentElement;return!Y.test(e||n&&n.nodeName||"HTML")},p=st.setDocument=function(t){var e,i,a=t?t.ownerDocument||t:E;return a!=h&&9===a.nodeType&&a.documentElement?(d=(h=a).documentElement,m=!o(h),E!=h&&(i=h.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",ot,!1):i.attachEvent&&i.attachEvent("onunload",ot)),n.scope=lt((function(t){return d.appendChild(t).appendChild(h.createElement("div")),void 0!==t.querySelectorAll&&!t.querySelectorAll(":scope fieldset div").length})),n.attributes=lt((function(t){return t.className="i",!t.getAttribute("className")})),n.getElementsByTagName=lt((function(t){return t.appendChild(h.createComment("")),!t.getElementsByTagName("*").length})),n.getElementsByClassName=Q.test(h.getElementsByClassName),n.getById=lt((function(t){return d.appendChild(t).id=O,!h.getElementsByName||!h.getElementsByName(O).length})),n.getById?(r.filter.ID=function(t){var e=t.replace(et,nt);return function(t){return t.getAttribute("id")===e}},r.find.ID=function(t,e){if(void 0!==e.getElementById&&m){var n=e.getElementById(t);return n?[n]:[]}}):(r.filter.ID=function(t){var e=t.replace(et,nt);return function(t){var n=void 0!==t.getAttributeNode&&t.getAttributeNode("id");return n&&n.value===e}},r.find.ID=function(t,e){if(void 0!==e.getElementById&&m){var n,r,i,o=e.getElementById(t);if(o){if((n=o.getAttributeNode("id"))&&n.value===t)return[o];for(i=e.getElementsByName(t),r=0;o=i[r++];)if((n=o.getAttributeNode("id"))&&n.value===t)return[o]}return[]}}),r.find.TAG=n.getElementsByTagName?function(t,e){return void 0!==e.getElementsByTagName?e.getElementsByTagName(t):n.qsa?e.querySelectorAll(t):void 0}:function(t,e){var n,r=[],i=0,o=e.getElementsByTagName(t);if("*"===t){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},r.find.CLASS=n.getElementsByClassName&&function(t,e){if(void 0!==e.getElementsByClassName&&m)return e.getElementsByClassName(t)},g=[],v=[],(n.qsa=Q.test(h.querySelectorAll))&&(lt((function(t){var e;d.appendChild(t).innerHTML="<a id='"+O+"'></a><select id='"+O+"-\r\\' msallowcapture=''><option selected=''></option></select>",t.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+D+"*(?:''|\"\")"),t.querySelectorAll("[selected]").length||v.push("\\["+D+"*(?:value|"+P+")"),t.querySelectorAll("[id~="+O+"-]").length||v.push("~="),(e=h.createElement("input")).setAttribute("name",""),t.appendChild(e),t.querySelectorAll("[name='']").length||v.push("\\["+D+"*name"+D+"*="+D+"*(?:''|\"\")"),t.querySelectorAll(":checked").length||v.push(":checked"),t.querySelectorAll("a#"+O+"+*").length||v.push(".#.+[+~]"),t.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")})),lt((function(t){t.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var e=h.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("name","D"),t.querySelectorAll("[name=d]").length&&v.push("name"+D+"*[*^$|!~]?="),2!==t.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),d.appendChild(t).disabled=!0,2!==t.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),v.push(",.*:")}))),(n.matchesSelector=Q.test(y=d.matches||d.webkitMatchesSelector||d.mozMatchesSelector||d.oMatchesSelector||d.msMatchesSelector))&&lt((function(t){n.disconnectedMatch=y.call(t,"*"),y.call(t,"[s!='']:x"),g.push("!=",B)})),v=v.length&&new RegExp(v.join("|")),g=g.length&&new RegExp(g.join("|")),e=Q.test(d.compareDocumentPosition),T=e||Q.test(d.contains)?function(t,e){var n=9===t.nodeType?t.documentElement:t,r=e&&e.parentNode;return t===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):t.compareDocumentPosition&&16&t.compareDocumentPosition(r)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},C=e?function(t,e){if(t===e)return f=!0,0;var r=!t.compareDocumentPosition-!e.compareDocumentPosition;return r||(1&(r=(t.ownerDocument||t)==(e.ownerDocument||e)?t.compareDocumentPosition(e):1)||!n.sortDetached&&e.compareDocumentPosition(t)===r?t==h||t.ownerDocument==E&&T(E,t)?-1:e==h||e.ownerDocument==E&&T(E,e)?1:l?M(l,t)-M(l,e):0:4&r?-1:1)}:function(t,e){if(t===e)return f=!0,0;var n,r=0,i=t.parentNode,o=e.parentNode,a=[t],s=[e];if(!i||!o)return t==h?-1:e==h?1:i?-1:o?1:l?M(l,t)-M(l,e):0;if(i===o)return pt(t,e);for(n=t;n=n.parentNode;)a.unshift(n);for(n=e;n=n.parentNode;)s.unshift(n);for(;a[r]===s[r];)r++;return r?pt(a[r],s[r]):a[r]==E?-1:s[r]==E?1:0},h):h},st.matches=function(t,e){return st(t,null,null,e)},st.matchesSelector=function(t,e){if(p(t),n.matchesSelector&&m&&!R[e+" "]&&(!g||!g.test(e))&&(!v||!v.test(e)))try{var r=y.call(t,e);if(r||n.disconnectedMatch||t.document&&11!==t.document.nodeType)return r}catch(t){R(e,!0)}return st(e,h,null,[t]).length>0},st.contains=function(t,e){return(t.ownerDocument||t)!=h&&p(t),T(t,e)},st.attr=function(t,e){(t.ownerDocument||t)!=h&&p(t);var i=r.attrHandle[e.toLowerCase()],o=i&&I.call(r.attrHandle,e.toLowerCase())?i(t,e,!m):void 0;return void 0!==o?o:n.attributes||!m?t.getAttribute(e):(o=t.getAttributeNode(e))&&o.specified?o.value:null},st.escape=function(t){return(t+"").replace(rt,it)},st.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},st.uniqueSort=function(t){var e,r=[],i=0,o=0;if(f=!n.detectDuplicates,l=!n.sortStable&&t.slice(0),t.sort(C),f){for(;e=t[o++];)e===t[o]&&(i=r.push(o));for(;i--;)t.splice(r[i],1)}return l=null,t},i=st.getText=function(t){var e,n="",r=0,o=t.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)n+=i(t)}else if(3===o||4===o)return t.nodeValue}else for(;e=t[r++];)n+=i(e);return n},(r=st.selectors={cacheLength:50,createPseudo:ut,match:$,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(et,nt),t[3]=(t[3]||t[4]||t[5]||"").replace(et,nt),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||st.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&st.error(t[0]),t},PSEUDO:function(t){var e,n=!t[6]&&t[2];return $.CHILD.test(t[0])?null:(t[3]?t[2]=t[4]||t[5]||"":n&&K.test(n)&&(e=a(n,!0))&&(e=n.indexOf(")",n.length-e)-n.length)&&(t[0]=t[0].slice(0,e),t[2]=n.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(et,nt).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=N[t+" "];return e||(e=new RegExp("(^|"+D+")"+t+"("+D+"|$)"))&&N(t,(function(t){return e.test("string"==typeof t.className&&t.className||void 0!==t.getAttribute&&t.getAttribute("class")||"")}))},ATTR:function(t,e,n){return function(r){var i=st.attr(r,t);return null==i?"!="===e:!e||(i+="","="===e?i===n:"!="===e?i!==n:"^="===e?n&&0===i.indexOf(n):"*="===e?n&&i.indexOf(n)>-1:"$="===e?n&&i.slice(-n.length)===n:"~="===e?(" "+i.replace(H," ")+" ").indexOf(n)>-1:"|="===e&&(i===n||i.slice(0,n.length+1)===n+"-"))}},CHILD:function(t,e,n,r,i){var o="nth"!==t.slice(0,3),a="last"!==t.slice(-4),s="of-type"===e;return 1===r&&0===i?function(t){return!!t.parentNode}:function(e,n,c){var u,l,f,p,h,d,m=o!==a?"nextSibling":"previousSibling",v=e.parentNode,g=s&&e.nodeName.toLowerCase(),y=!c&&!s,T=!1;if(v){if(o){for(;m;){for(p=e;p=p[m];)if(s?p.nodeName.toLowerCase()===g:1===p.nodeType)return!1;d=m="only"===t&&!d&&"nextSibling"}return!0}if(d=[a?v.firstChild:v.lastChild],a&&y){for(T=(h=(u=(l=(f=(p=v)[O]||(p[O]={}))[p.uniqueID]||(f[p.uniqueID]={}))[t]||[])[0]===b&&u[1])&&u[2],p=h&&v.childNodes[h];p=++h&&p&&p[m]||(T=h=0)||d.pop();)if(1===p.nodeType&&++T&&p===e){l[t]=[b,h,T];break}}else if(y&&(T=h=(u=(l=(f=(p=e)[O]||(p[O]={}))[p.uniqueID]||(f[p.uniqueID]={}))[t]||[])[0]===b&&u[1]),!1===T)for(;(p=++h&&p&&p[m]||(T=h=0)||d.pop())&&((s?p.nodeName.toLowerCase()!==g:1!==p.nodeType)||!++T||(y&&((l=(f=p[O]||(p[O]={}))[p.uniqueID]||(f[p.uniqueID]={}))[t]=[b,T]),p!==e)););return(T-=i)===r||T%r==0&&T/r>=0}}},PSEUDO:function(t,e){var n,i=r.pseudos[t]||r.setFilters[t.toLowerCase()]||st.error("unsupported pseudo: "+t);return i[O]?i(e):i.length>1?(n=[t,t,"",e],r.setFilters.hasOwnProperty(t.toLowerCase())?ut((function(t,n){for(var r,o=i(t,e),a=o.length;a--;)t[r=M(t,o[a])]=!(n[r]=o[a])})):function(t){return i(t,0,n)}):i}},pseudos:{not:ut((function(t){var e=[],n=[],r=s(t.replace(W,"$1"));return r[O]?ut((function(t,e,n,i){for(var o,a=r(t,null,i,[]),s=t.length;s--;)(o=a[s])&&(t[s]=!(e[s]=o))})):function(t,i,o){return e[0]=t,r(e,null,o,n),e[0]=null,!n.pop()}})),has:ut((function(t){return function(e){return st(t,e).length>0}})),contains:ut((function(t){return t=t.replace(et,nt),function(e){return(e.textContent||i(e)).indexOf(t)>-1}})),lang:ut((function(t){return z.test(t||"")||st.error("unsupported lang: "+t),t=t.replace(et,nt).toLowerCase(),function(e){var n;do{if(n=m?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(n=n.toLowerCase())===t||0===n.indexOf(t+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}})),target:function(e){var n=t.location&&t.location.hash;return n&&n.slice(1)===e.id},root:function(t){return t===d},focus:function(t){return t===h.activeElement&&(!h.hasFocus||h.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:mt(!1),disabled:mt(!0),checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,!0===t.selected},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeType<6)return!1;return!0},parent:function(t){return!r.pseudos.empty(t)},header:function(t){return J.test(t.nodeName)},input:function(t){return X.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||"text"===e.toLowerCase())},first:vt((function(){return[0]})),last:vt((function(t,e){return[e-1]})),eq:vt((function(t,e,n){return[n<0?n+e:n]})),even:vt((function(t,e){for(var n=0;n<e;n+=2)t.push(n);return t})),odd:vt((function(t,e){for(var n=1;n<e;n+=2)t.push(n);return t})),lt:vt((function(t,e,n){for(var r=n<0?n+e:n>e?e:n;--r>=0;)t.push(r);return t})),gt:vt((function(t,e,n){for(var r=n<0?n+e:n;++r<e;)t.push(r);return t}))}}).pseudos.nth=r.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[e]=ht(e);for(e in{submit:!0,reset:!0})r.pseudos[e]=dt(e);function yt(){}function Tt(t){for(var e=0,n=t.length,r="";e<n;e++)r+=t[e].value;return r}function Ot(t,e,n){var r=e.dir,i=e.next,o=i||r,a=n&&"parentNode"===o,s=S++;return e.first?function(e,n,i){for(;e=e[r];)if(1===e.nodeType||a)return t(e,n,i);return!1}:function(e,n,c){var u,l,f,p=[b,s];if(c){for(;e=e[r];)if((1===e.nodeType||a)&&t(e,n,c))return!0}else for(;e=e[r];)if(1===e.nodeType||a)if(l=(f=e[O]||(e[O]={}))[e.uniqueID]||(f[e.uniqueID]={}),i&&i===e.nodeName.toLowerCase())e=e[r]||e;else{if((u=l[o])&&u[0]===b&&u[1]===s)return p[2]=u[2];if(l[o]=p,p[2]=t(e,n,c))return!0}return!1}}function Et(t){return t.length>1?function(e,n,r){for(var i=t.length;i--;)if(!t[i](e,n,r))return!1;return!0}:t[0]}function bt(t,e,n,r,i){for(var o,a=[],s=0,c=t.length,u=null!=e;s<c;s++)(o=t[s])&&(n&&!n(o,r,i)||(a.push(o),u&&e.push(s)));return a}function St(t,e,n,r,i,o){return r&&!r[O]&&(r=St(r)),i&&!i[O]&&(i=St(i,o)),ut((function(o,a,s,c){var u,l,f,p=[],h=[],d=a.length,m=o||function(t,e,n){for(var r=0,i=e.length;r<i;r++)st(t,e[r],n);return n}(e||"*",s.nodeType?[s]:s,[]),v=!t||!o&&e?m:bt(m,p,t,s,c),g=n?i||(o?t:d||r)?[]:a:v;if(n&&n(v,g,s,c),r)for(u=bt(g,h),r(u,[],s,c),l=u.length;l--;)(f=u[l])&&(g[h[l]]=!(v[h[l]]=f));if(o){if(i||t){if(i){for(u=[],l=g.length;l--;)(f=g[l])&&u.push(v[l]=f);i(null,g=[],u,c)}for(l=g.length;l--;)(f=g[l])&&(u=i?M(o,f):p[l])>-1&&(o[u]=!(a[u]=f))}}else g=bt(g===a?g.splice(d,g.length):g),i?i(null,a,g,c):_.apply(a,g)}))}function Nt(t){for(var e,n,i,o=t.length,a=r.relative[t[0].type],s=a||r.relative[" "],c=a?1:0,l=Ot((function(t){return t===e}),s,!0),f=Ot((function(t){return M(e,t)>-1}),s,!0),p=[function(t,n,r){var i=!a&&(r||n!==u)||((e=n).nodeType?l(t,n,r):f(t,n,r));return e=null,i}];c<o;c++)if(n=r.relative[t[c].type])p=[Ot(Et(p),n)];else{if((n=r.filter[t[c].type].apply(null,t[c].matches))[O]){for(i=++c;i<o&&!r.relative[t[i].type];i++);return St(c>1&&Et(p),c>1&&Tt(t.slice(0,c-1).concat({value:" "===t[c-2].type?"*":""})).replace(W,"$1"),n,c<i&&Nt(t.slice(c,i)),i<o&&Nt(t=t.slice(i)),i<o&&Tt(t))}p.push(n)}return Et(p)}return yt.prototype=r.filters=r.pseudos,r.setFilters=new yt,a=st.tokenize=function(t,e){var n,i,o,a,s,c,u,l=x[t+" "];if(l)return e?0:l.slice(0);for(s=t,c=[],u=r.preFilter;s;){for(a in n&&!(i=G.exec(s))||(i&&(s=s.slice(i[0].length)||s),c.push(o=[])),n=!1,(i=q.exec(s))&&(n=i.shift(),o.push({value:n,type:i[0].replace(W," ")}),s=s.slice(n.length)),r.filter)!(i=$[a].exec(s))||u[a]&&!(i=u[a](i))||(n=i.shift(),o.push({value:n,type:a,matches:i}),s=s.slice(n.length));if(!n)break}return e?s.length:s?st.error(t):x(t,c).slice(0)},s=st.compile=function(t,e){var n,i=[],o=[],s=A[t+" "];if(!s){for(e||(e=a(t)),n=e.length;n--;)(s=Nt(e[n]))[O]?i.push(s):o.push(s);(s=A(t,function(t,e){var n=e.length>0,i=t.length>0,o=function(o,a,s,c,l){var f,d,v,g=0,y="0",T=o&&[],O=[],E=u,S=o||i&&r.find.TAG("*",l),N=b+=null==E?1:Math.random()||.1,x=S.length;for(l&&(u=a==h||a||l);y!==x&&null!=(f=S[y]);y++){if(i&&f){for(d=0,a||f.ownerDocument==h||(p(f),s=!m);v=t[d++];)if(v(f,a||h,s)){c.push(f);break}l&&(b=N)}n&&((f=!v&&f)&&g--,o&&T.push(f))}if(g+=y,n&&y!==g){for(d=0;v=e[d++];)v(T,O,a,s);if(o){if(g>0)for(;y--;)T[y]||O[y]||(O[y]=L.call(c));O=bt(O)}_.apply(c,O),l&&!o&&O.length>0&&g+e.length>1&&st.uniqueSort(c)}return l&&(b=N,u=E),T};return n?ut(o):o}(o,i))).selector=t}return s},c=st.select=function(t,e,n,i){var o,c,u,l,f,p="function"==typeof t&&t,h=!i&&a(t=p.selector||t);if(n=n||[],1===h.length){if((c=h[0]=h[0].slice(0)).length>2&&"ID"===(u=c[0]).type&&9===e.nodeType&&m&&r.relative[c[1].type]){if(!(e=(r.find.ID(u.matches[0].replace(et,nt),e)||[])[0]))return n;p&&(e=e.parentNode),t=t.slice(c.shift().value.length)}for(o=$.needsContext.test(t)?0:c.length;o--&&(u=c[o],!r.relative[l=u.type]);)if((f=r.find[l])&&(i=f(u.matches[0].replace(et,nt),tt.test(c[0].type)&&gt(e.parentNode)||e))){if(c.splice(o,1),!(t=i.length&&Tt(c)))return _.apply(n,i),n;break}}return(p||s(t,h))(i,e,!m,n,!e||tt.test(t)&&gt(e.parentNode)||e),n},n.sortStable=O.split("").sort(C).join("")===O,n.detectDuplicates=!!f,p(),n.sortDetached=lt((function(t){return 1&t.compareDocumentPosition(h.createElement("fieldset"))})),lt((function(t){return t.innerHTML="<a href='#'></a>","#"===t.firstChild.getAttribute("href")}))||ft("type|href|height|width",(function(t,e,n){if(!n)return t.getAttribute(e,"type"===e.toLowerCase()?1:2)})),n.attributes&&lt((function(t){return t.innerHTML="<input/>",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")}))||ft("value",(function(t,e,n){if(!n&&"input"===t.nodeName.toLowerCase())return t.defaultValue})),lt((function(t){return null==t.getAttribute("disabled")}))||ft(P,(function(t,e,n){var r;if(!n)return!0===t[e]?e.toLowerCase():(r=t.getAttributeNode(e))&&r.specified?r.value:null})),st}(n);S.find=x,S.expr=x.selectors,S.expr[":"]=S.expr.pseudos,S.uniqueSort=S.unique=x.uniqueSort,S.text=x.getText,S.isXMLDoc=x.isXML,S.contains=x.contains,S.escapeSelector=x.escape;var A=function(t,e,n){for(var r=[],i=void 0!==n;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(i&&S(t).is(n))break;r.push(t)}return r},R=function(t,e){for(var n=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&n.push(t);return n},C=S.expr.match.needsContext;function I(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()}var k=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function L(t,e,n){return g(e)?S.grep(t,(function(t,r){return!!e.call(t,r,t)!==n})):e.nodeType?S.grep(t,(function(t){return t===e!==n})):"string"!=typeof e?S.grep(t,(function(t){return l.call(e,t)>-1!==n})):S.filter(e,t,n)}S.filter=function(t,e,n){var r=e[0];return n&&(t=":not("+t+")"),1===e.length&&1===r.nodeType?S.find.matchesSelector(r,t)?[r]:[]:S.find.matches(t,S.grep(e,(function(t){return 1===t.nodeType})))},S.fn.extend({find:function(t){var e,n,r=this.length,i=this;if("string"!=typeof t)return this.pushStack(S(t).filter((function(){for(e=0;e<r;e++)if(S.contains(i[e],this))return!0})));for(n=this.pushStack([]),e=0;e<r;e++)S.find(t,i[e],n);return r>1?S.uniqueSort(n):n},filter:function(t){return this.pushStack(L(this,t||[],!1))},not:function(t){return this.pushStack(L(this,t||[],!0))},is:function(t){return!!L(this,"string"==typeof t&&C.test(t)?S(t):t||[],!1).length}});var w,_=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(S.fn.init=function(t,e,n){var r,i;if(!t)return this;if(n=n||w,"string"==typeof t){if(!(r="<"===t[0]&&">"===t[t.length-1]&&t.length>=3?[null,t,null]:_.exec(t))||!r[1]&&e)return!e||e.jquery?(e||n).find(t):this.constructor(e).find(t);if(r[1]){if(e=e instanceof S?e[0]:e,S.merge(this,S.parseHTML(r[1],e&&e.nodeType?e.ownerDocument||e:T,!0)),k.test(r[1])&&S.isPlainObject(e))for(r in e)g(this[r])?this[r](e[r]):this.attr(r,e[r]);return this}return(i=T.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return t.nodeType?(this[0]=t,this.length=1,this):g(t)?void 0!==n.ready?n.ready(t):t(S):S.makeArray(t,this)}).prototype=S.fn,w=S(T);var j=/^(?:parents|prev(?:Until|All))/,M={children:!0,contents:!0,next:!0,prev:!0};function P(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}S.fn.extend({has:function(t){var e=S(t,this),n=e.length;return this.filter((function(){for(var t=0;t<n;t++)if(S.contains(this,e[t]))return!0}))},closest:function(t,e){var n,r=0,i=this.length,o=[],a="string"!=typeof t&&S(t);if(!C.test(t))for(;r<i;r++)for(n=this[r];n&&n!==e;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&S.find.matchesSelector(n,t))){o.push(n);break}return this.pushStack(o.length>1?S.uniqueSort(o):o)},index:function(t){return t?"string"==typeof t?l.call(S(t),this[0]):l.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){return this.pushStack(S.uniqueSort(S.merge(this.get(),S(t,e))))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),S.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return A(t,"parentNode")},parentsUntil:function(t,e,n){return A(t,"parentNode",n)},next:function(t){return P(t,"nextSibling")},prev:function(t){return P(t,"previousSibling")},nextAll:function(t){return A(t,"nextSibling")},prevAll:function(t){return A(t,"previousSibling")},nextUntil:function(t,e,n){return A(t,"nextSibling",n)},prevUntil:function(t,e,n){return A(t,"previousSibling",n)},siblings:function(t){return R((t.parentNode||{}).firstChild,t)},children:function(t){return R(t.firstChild)},contents:function(t){return null!=t.contentDocument&&a(t.contentDocument)?t.contentDocument:(I(t,"template")&&(t=t.content||t),S.merge([],t.childNodes))}},(function(t,e){S.fn[t]=function(n,r){var i=S.map(this,e,n);return"Until"!==t.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=S.filter(r,i)),this.length>1&&(M[t]||S.uniqueSort(i),j.test(t)&&i.reverse()),this.pushStack(i)}}));var D=/[^\x20\t\r\n\f]+/g;function U(t){return t}function F(t){throw t}function B(t,e,n,r){var i;try{t&&g(i=t.promise)?i.call(t).done(e).fail(n):t&&g(i=t.then)?i.call(t,e,n):e.apply(void 0,[t].slice(r))}catch(t){n.apply(void 0,[t])}}S.Callbacks=function(t){t="string"==typeof t?function(t){var e={};return S.each(t.match(D)||[],(function(t,n){e[n]=!0})),e}(t):S.extend({},t);var e,n,r,i,o=[],a=[],s=-1,c=function(){for(i=i||t.once,r=e=!0;a.length;s=-1)for(n=a.shift();++s<o.length;)!1===o[s].apply(n[0],n[1])&&t.stopOnFalse&&(s=o.length,n=!1);t.memory||(n=!1),e=!1,i&&(o=n?[]:"")},u={add:function(){return o&&(n&&!e&&(s=o.length-1,a.push(n)),function e(n){S.each(n,(function(n,r){g(r)?t.unique&&u.has(r)||o.push(r):r&&r.length&&"string"!==b(r)&&e(r)}))}(arguments),n&&!e&&c()),this},remove:function(){return S.each(arguments,(function(t,e){for(var n;(n=S.inArray(e,o,n))>-1;)o.splice(n,1),n<=s&&s--})),this},has:function(t){return t?S.inArray(t,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n="",this},disabled:function(){return!o},lock:function(){return i=a=[],n||e||(o=n=""),this},locked:function(){return!!i},fireWith:function(t,n){return i||(n=[t,(n=n||[]).slice?n.slice():n],a.push(n),e||c()),this},fire:function(){return u.fireWith(this,arguments),this},fired:function(){return!!r}};return u},S.extend({Deferred:function(t){var e=[["notify","progress",S.Callbacks("memory"),S.Callbacks("memory"),2],["resolve","done",S.Callbacks("once memory"),S.Callbacks("once memory"),0,"resolved"],["reject","fail",S.Callbacks("once memory"),S.Callbacks("once memory"),1,"rejected"]],r="pending",i={state:function(){return r},always:function(){return o.done(arguments).fail(arguments),this},catch:function(t){return i.then(null,t)},pipe:function(){var t=arguments;return S.Deferred((function(n){S.each(e,(function(e,r){var i=g(t[r[4]])&&t[r[4]];o[r[1]]((function(){var t=i&&i.apply(this,arguments);t&&g(t.promise)?t.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[r[0]+"With"](this,i?[t]:arguments)}))})),t=null})).promise()},then:function(t,r,i){var o=0;function a(t,e,r,i){return function(){var s=this,c=arguments,u=function(){var n,u;if(!(t<o)){if((n=r.apply(s,c))===e.promise())throw new TypeError("Thenable self-resolution");u=n&&("object"==typeof n||"function"==typeof n)&&n.then,g(u)?i?u.call(n,a(o,e,U,i),a(o,e,F,i)):(o++,u.call(n,a(o,e,U,i),a(o,e,F,i),a(o,e,U,e.notifyWith))):(r!==U&&(s=void 0,c=[n]),(i||e.resolveWith)(s,c))}},l=i?u:function(){try{u()}catch(n){S.Deferred.exceptionHook&&S.Deferred.exceptionHook(n,l.stackTrace),t+1>=o&&(r!==F&&(s=void 0,c=[n]),e.rejectWith(s,c))}};t?l():(S.Deferred.getStackHook&&(l.stackTrace=S.Deferred.getStackHook()),n.setTimeout(l))}}return S.Deferred((function(n){e[0][3].add(a(0,n,g(i)?i:U,n.notifyWith)),e[1][3].add(a(0,n,g(t)?t:U)),e[2][3].add(a(0,n,g(r)?r:F))})).promise()},promise:function(t){return null!=t?S.extend(t,i):i}},o={};return S.each(e,(function(t,n){var a=n[2],s=n[5];i[n[1]]=a.add,s&&a.add((function(){r=s}),e[3-t][2].disable,e[3-t][3].disable,e[0][2].lock,e[0][3].lock),a.add(n[3].fire),o[n[0]]=function(){return o[n[0]+"With"](this===o?void 0:this,arguments),this},o[n[0]+"With"]=a.fireWith})),i.promise(o),t&&t.call(o,o),o},when:function(t){var e=arguments.length,n=e,r=Array(n),i=s.call(arguments),o=S.Deferred(),a=function(t){return function(n){r[t]=this,i[t]=arguments.length>1?s.call(arguments):n,--e||o.resolveWith(r,i)}};if(e<=1&&(B(t,o.done(a(n)).resolve,o.reject,!e),"pending"===o.state()||g(i[n]&&i[n].then)))return o.then();for(;n--;)B(i[n],a(n),o.reject);return o.promise()}});var H=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;S.Deferred.exceptionHook=function(t,e){n.console&&n.console.warn&&t&&H.test(t.name)&&n.console.warn("jQuery.Deferred exception: "+t.message,t.stack,e)},S.readyException=function(t){n.setTimeout((function(){throw t}))};var W=S.Deferred();function G(){T.removeEventListener("DOMContentLoaded",G),n.removeEventListener("load",G),S.ready()}S.fn.ready=function(t){return W.then(t).catch((function(t){S.readyException(t)})),this},S.extend({isReady:!1,readyWait:1,ready:function(t){(!0===t?--S.readyWait:S.isReady)||(S.isReady=!0,!0!==t&&--S.readyWait>0||W.resolveWith(T,[S]))}}),S.ready.then=W.then,"complete"===T.readyState||"loading"!==T.readyState&&!T.documentElement.doScroll?n.setTimeout(S.ready):(T.addEventListener("DOMContentLoaded",G),n.addEventListener("load",G));var q=function(t,e,n,r,i,o,a){var s=0,c=t.length,u=null==n;if("object"===b(n))for(s in i=!0,n)q(t,e,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,g(r)||(a=!0),u&&(a?(e.call(t,r),e=null):(u=e,e=function(t,e,n){return u.call(S(t),n)})),e))for(;s<c;s++)e(t[s],n,a?r:r.call(t[s],s,e(t[s],n)));return i?t:u?e.call(t):c?e(t[0],n):o},V=/^-ms-/,K=/-([a-z])/g;function z(t,e){return e.toUpperCase()}function $(t){return t.replace(V,"ms-").replace(K,z)}var Y=function(t){return 1===t.nodeType||9===t.nodeType||!+t.nodeType};function X(){this.expando=S.expando+X.uid++}X.uid=1,X.prototype={cache:function(t){var e=t[this.expando];return e||(e={},Y(t)&&(t.nodeType?t[this.expando]=e:Object.defineProperty(t,this.expando,{value:e,configurable:!0}))),e},set:function(t,e,n){var r,i=this.cache(t);if("string"==typeof e)i[$(e)]=n;else for(r in e)i[$(r)]=e[r];return i},get:function(t,e){return void 0===e?this.cache(t):t[this.expando]&&t[this.expando][$(e)]},access:function(t,e,n){return void 0===e||e&&"string"==typeof e&&void 0===n?this.get(t,e):(this.set(t,e,n),void 0!==n?n:e)},remove:function(t,e){var n,r=t[this.expando];if(void 0!==r){if(void 0!==e){n=(e=Array.isArray(e)?e.map($):(e=$(e))in r?[e]:e.match(D)||[]).length;for(;n--;)delete r[e[n]]}(void 0===e||S.isEmptyObject(r))&&(t.nodeType?t[this.expando]=void 0:delete t[this.expando])}},hasData:function(t){var e=t[this.expando];return void 0!==e&&!S.isEmptyObject(e)}};var J=new X,Q=new X,Z=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,tt=/[A-Z]/g;function et(t,e,n){var r;if(void 0===n&&1===t.nodeType)if(r="data-"+e.replace(tt,"-$&").toLowerCase(),"string"==typeof(n=t.getAttribute(r))){try{n=function(t){return"true"===t||"false"!==t&&("null"===t?null:t===+t+""?+t:Z.test(t)?JSON.parse(t):t)}(n)}catch(t){}Q.set(t,e,n)}else n=void 0;return n}S.extend({hasData:function(t){return Q.hasData(t)||J.hasData(t)},data:function(t,e,n){return Q.access(t,e,n)},removeData:function(t,e){Q.remove(t,e)},_data:function(t,e,n){return J.access(t,e,n)},_removeData:function(t,e){J.remove(t,e)}}),S.fn.extend({data:function(t,e){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===t){if(this.length&&(i=Q.get(o),1===o.nodeType&&!J.get(o,"hasDataAttrs"))){for(n=a.length;n--;)a[n]&&0===(r=a[n].name).indexOf("data-")&&(r=$(r.slice(5)),et(o,r,i[r]));J.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof t?this.each((function(){Q.set(this,t)})):q(this,(function(e){var n;if(o&&void 0===e)return void 0!==(n=Q.get(o,t))||void 0!==(n=et(o,t))?n:void 0;this.each((function(){Q.set(this,t,e)}))}),null,e,arguments.length>1,null,!0)},removeData:function(t){return this.each((function(){Q.remove(this,t)}))}}),S.extend({queue:function(t,e,n){var r;if(t)return e=(e||"fx")+"queue",r=J.get(t,e),n&&(!r||Array.isArray(n)?r=J.access(t,e,S.makeArray(n)):r.push(n)),r||[]},dequeue:function(t,e){e=e||"fx";var n=S.queue(t,e),r=n.length,i=n.shift(),o=S._queueHooks(t,e);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===e&&n.unshift("inprogress"),delete o.stop,i.call(t,(function(){S.dequeue(t,e)}),o)),!r&&o&&o.empty.fire()},_queueHooks:function(t,e){var n=e+"queueHooks";return J.get(t,n)||J.access(t,n,{empty:S.Callbacks("once memory").add((function(){J.remove(t,[e+"queue",n])}))})}}),S.fn.extend({queue:function(t,e){var n=2;return"string"!=typeof t&&(e=t,t="fx",n--),arguments.length<n?S.queue(this[0],t):void 0===e?this:this.each((function(){var n=S.queue(this,t,e);S._queueHooks(this,t),"fx"===t&&"inprogress"!==n[0]&&S.dequeue(this,t)}))},dequeue:function(t){return this.each((function(){S.dequeue(this,t)}))},clearQueue:function(t){return this.queue(t||"fx",[])},promise:function(t,e){var n,r=1,i=S.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof t&&(e=t,t=void 0),t=t||"fx";a--;)(n=J.get(o[a],t+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(e)}});var nt=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,rt=new RegExp("^(?:([+-])=|)("+nt+")([a-z%]*)$","i"),it=["Top","Right","Bottom","Left"],ot=T.documentElement,at=function(t){return S.contains(t.ownerDocument,t)},st={composed:!0};ot.getRootNode&&(at=function(t){return S.contains(t.ownerDocument,t)||t.getRootNode(st)===t.ownerDocument});var ct=function(t,e){return"none"===(t=e||t).style.display||""===t.style.display&&at(t)&&"none"===S.css(t,"display")};function ut(t,e,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return S.css(t,e,"")},c=s(),u=n&&n[3]||(S.cssNumber[e]?"":"px"),l=t.nodeType&&(S.cssNumber[e]||"px"!==u&&+c)&&rt.exec(S.css(t,e));if(l&&l[3]!==u){for(c/=2,u=u||l[3],l=+c||1;a--;)S.style(t,e,l+u),(1-o)*(1-(o=s()/c||.5))<=0&&(a=0),l/=o;l*=2,S.style(t,e,l+u),n=n||[]}return n&&(l=+l||+c||0,i=n[1]?l+(n[1]+1)*n[2]:+n[2],r&&(r.unit=u,r.start=l,r.end=i)),i}var lt={};function ft(t){var e,n=t.ownerDocument,r=t.nodeName,i=lt[r];return i||(e=n.body.appendChild(n.createElement(r)),i=S.css(e,"display"),e.parentNode.removeChild(e),"none"===i&&(i="block"),lt[r]=i,i)}function pt(t,e){for(var n,r,i=[],o=0,a=t.length;o<a;o++)(r=t[o]).style&&(n=r.style.display,e?("none"===n&&(i[o]=J.get(r,"display")||null,i[o]||(r.style.display="")),""===r.style.display&&ct(r)&&(i[o]=ft(r))):"none"!==n&&(i[o]="none",J.set(r,"display",n)));for(o=0;o<a;o++)null!=i[o]&&(t[o].style.display=i[o]);return t}S.fn.extend({show:function(){return pt(this,!0)},hide:function(){return pt(this)},toggle:function(t){return"boolean"==typeof t?t?this.show():this.hide():this.each((function(){ct(this)?S(this).show():S(this).hide()}))}});var ht,dt,mt=/^(?:checkbox|radio)$/i,vt=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,gt=/^$|^module$|\/(?:java|ecma)script/i;ht=T.createDocumentFragment().appendChild(T.createElement("div")),(dt=T.createElement("input")).setAttribute("type","radio"),dt.setAttribute("checked","checked"),dt.setAttribute("name","t"),ht.appendChild(dt),v.checkClone=ht.cloneNode(!0).cloneNode(!0).lastChild.checked,ht.innerHTML="<textarea>x</textarea>",v.noCloneChecked=!!ht.cloneNode(!0).lastChild.defaultValue,ht.innerHTML="<option></option>",v.option=!!ht.lastChild;var yt={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function Tt(t,e){var n;return n=void 0!==t.getElementsByTagName?t.getElementsByTagName(e||"*"):void 0!==t.querySelectorAll?t.querySelectorAll(e||"*"):[],void 0===e||e&&I(t,e)?S.merge([t],n):n}function Ot(t,e){for(var n=0,r=t.length;n<r;n++)J.set(t[n],"globalEval",!e||J.get(e[n],"globalEval"))}yt.tbody=yt.tfoot=yt.colgroup=yt.caption=yt.thead,yt.th=yt.td,v.option||(yt.optgroup=yt.option=[1,"<select multiple='multiple'>","</select>"]);var Et=/<|&#?\w+;/;function bt(t,e,n,r,i){for(var o,a,s,c,u,l,f=e.createDocumentFragment(),p=[],h=0,d=t.length;h<d;h++)if((o=t[h])||0===o)if("object"===b(o))S.merge(p,o.nodeType?[o]:o);else if(Et.test(o)){for(a=a||f.appendChild(e.createElement("div")),s=(vt.exec(o)||["",""])[1].toLowerCase(),c=yt[s]||yt._default,a.innerHTML=c[1]+S.htmlPrefilter(o)+c[2],l=c[0];l--;)a=a.lastChild;S.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(e.createTextNode(o));for(f.textContent="",h=0;o=p[h++];)if(r&&S.inArray(o,r)>-1)i&&i.push(o);else if(u=at(o),a=Tt(f.appendChild(o),"script"),u&&Ot(a),n)for(l=0;o=a[l++];)gt.test(o.type||"")&&n.push(o);return f}var St=/^key/,Nt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,xt=/^([^.]*)(?:\.(.+)|)/;function At(){return!0}function Rt(){return!1}function Ct(t,e){return t===function(){try{return T.activeElement}catch(t){}}()==("focus"===e)}function It(t,e,n,r,i,o){var a,s;if("object"==typeof e){for(s in"string"!=typeof n&&(r=r||n,n=void 0),e)It(t,s,n,r,e[s],o);return t}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Rt;else if(!i)return t;return 1===o&&(a=i,(i=function(t){return S().off(t),a.apply(this,arguments)}).guid=a.guid||(a.guid=S.guid++)),t.each((function(){S.event.add(this,e,i,r,n)}))}function kt(t,e,n){n?(J.set(t,e,!1),S.event.add(t,e,{namespace:!1,handler:function(t){var r,i,o=J.get(this,e);if(1&t.isTrigger&&this[e]){if(o.length)(S.event.special[e]||{}).delegateType&&t.stopPropagation();else if(o=s.call(arguments),J.set(this,e,o),r=n(this,e),this[e](),o!==(i=J.get(this,e))||r?J.set(this,e,!1):i={},o!==i)return t.stopImmediatePropagation(),t.preventDefault(),i.value}else o.length&&(J.set(this,e,{value:S.event.trigger(S.extend(o[0],S.Event.prototype),o.slice(1),this)}),t.stopImmediatePropagation())}})):void 0===J.get(t,e)&&S.event.add(t,e,At)}S.event={global:{},add:function(t,e,n,r,i){var o,a,s,c,u,l,f,p,h,d,m,v=J.get(t);if(Y(t))for(n.handler&&(n=(o=n).handler,i=o.selector),i&&S.find.matchesSelector(ot,i),n.guid||(n.guid=S.guid++),(c=v.events)||(c=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(e){return void 0!==S&&S.event.triggered!==e.type?S.event.dispatch.apply(t,arguments):void 0}),u=(e=(e||"").match(D)||[""]).length;u--;)h=m=(s=xt.exec(e[u])||[])[1],d=(s[2]||"").split(".").sort(),h&&(f=S.event.special[h]||{},h=(i?f.delegateType:f.bindType)||h,f=S.event.special[h]||{},l=S.extend({type:h,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&S.expr.match.needsContext.test(i),namespace:d.join(".")},o),(p=c[h])||((p=c[h]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,d,a)||t.addEventListener&&t.addEventListener(h,a)),f.add&&(f.add.call(t,l),l.handler.guid||(l.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,l):p.push(l),S.event.global[h]=!0)},remove:function(t,e,n,r,i){var o,a,s,c,u,l,f,p,h,d,m,v=J.hasData(t)&&J.get(t);if(v&&(c=v.events)){for(u=(e=(e||"").match(D)||[""]).length;u--;)if(h=m=(s=xt.exec(e[u])||[])[1],d=(s[2]||"").split(".").sort(),h){for(f=S.event.special[h]||{},p=c[h=(r?f.delegateType:f.bindType)||h]||[],s=s[2]&&new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;o--;)l=p[o],!i&&m!==l.origType||n&&n.guid!==l.guid||s&&!s.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(p.splice(o,1),l.selector&&p.delegateCount--,f.remove&&f.remove.call(t,l));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(t,d,v.handle)||S.removeEvent(t,h,v.handle),delete c[h])}else for(h in c)S.event.remove(t,h+e[u],n,r,!0);S.isEmptyObject(c)&&J.remove(t,"handle events")}},dispatch:function(t){var e,n,r,i,o,a,s=new Array(arguments.length),c=S.event.fix(t),u=(J.get(this,"events")||Object.create(null))[c.type]||[],l=S.event.special[c.type]||{};for(s[0]=c,e=1;e<arguments.length;e++)s[e]=arguments[e];if(c.delegateTarget=this,!l.preDispatch||!1!==l.preDispatch.call(this,c)){for(a=S.event.handlers.call(this,c,u),e=0;(i=a[e++])&&!c.isPropagationStopped();)for(c.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!c.isImmediatePropagationStopped();)c.rnamespace&&!1!==o.namespace&&!c.rnamespace.test(o.namespace)||(c.handleObj=o,c.data=o.data,void 0!==(r=((S.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(c.result=r)&&(c.preventDefault(),c.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,c),c.result}},handlers:function(t,e){var n,r,i,o,a,s=[],c=e.delegateCount,u=t.target;if(c&&u.nodeType&&!("click"===t.type&&t.button>=1))for(;u!==this;u=u.parentNode||this)if(1===u.nodeType&&("click"!==t.type||!0!==u.disabled)){for(o=[],a={},n=0;n<c;n++)void 0===a[i=(r=e[n]).selector+" "]&&(a[i]=r.needsContext?S(i,this).index(u)>-1:S.find(i,this,null,[u]).length),a[i]&&o.push(r);o.length&&s.push({elem:u,handlers:o})}return u=this,c<e.length&&s.push({elem:u,handlers:e.slice(c)}),s},addProp:function(t,e){Object.defineProperty(S.Event.prototype,t,{enumerable:!0,configurable:!0,get:g(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(t){return t[S.expando]?t:new S.Event(t)},special:{load:{noBubble:!0},click:{setup:function(t){var e=this||t;return mt.test(e.type)&&e.click&&I(e,"input")&&kt(e,"click",At),!1},trigger:function(t){var e=this||t;return mt.test(e.type)&&e.click&&I(e,"input")&&kt(e,"click"),!0},_default:function(t){var e=t.target;return mt.test(e.type)&&e.click&&I(e,"input")&&J.get(e,"click")||I(e,"a")}},beforeunload:{postDispatch:function(t){void 0!==t.result&&t.originalEvent&&(t.originalEvent.returnValue=t.result)}}}},S.removeEvent=function(t,e,n){t.removeEventListener&&t.removeEventListener(e,n)},S.Event=function(t,e){if(!(this instanceof S.Event))return new S.Event(t,e);t&&t.type?(this.originalEvent=t,this.type=t.type,this.isDefaultPrevented=t.defaultPrevented||void 0===t.defaultPrevented&&!1===t.returnValue?At:Rt,this.target=t.target&&3===t.target.nodeType?t.target.parentNode:t.target,this.currentTarget=t.currentTarget,this.relatedTarget=t.relatedTarget):this.type=t,e&&S.extend(this,e),this.timeStamp=t&&t.timeStamp||Date.now(),this[S.expando]=!0},S.Event.prototype={constructor:S.Event,isDefaultPrevented:Rt,isPropagationStopped:Rt,isImmediatePropagationStopped:Rt,isSimulated:!1,preventDefault:function(){var t=this.originalEvent;this.isDefaultPrevented=At,t&&!this.isSimulated&&t.preventDefault()},stopPropagation:function(){var t=this.originalEvent;this.isPropagationStopped=At,t&&!this.isSimulated&&t.stopPropagation()},stopImmediatePropagation:function(){var t=this.originalEvent;this.isImmediatePropagationStopped=At,t&&!this.isSimulated&&t.stopImmediatePropagation(),this.stopPropagation()}},S.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(t){var e=t.button;return null==t.which&&St.test(t.type)?null!=t.charCode?t.charCode:t.keyCode:!t.which&&void 0!==e&&Nt.test(t.type)?1&e?1:2&e?3:4&e?2:0:t.which}},S.event.addProp),S.each({focus:"focusin",blur:"focusout"},(function(t,e){S.event.special[t]={setup:function(){return kt(this,t,Ct),!1},trigger:function(){return kt(this,t),!0},delegateType:e}})),S.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},(function(t,e){S.event.special[t]={delegateType:e,bindType:e,handle:function(t){var n,r=this,i=t.relatedTarget,o=t.handleObj;return i&&(i===r||S.contains(r,i))||(t.type=o.origType,n=o.handler.apply(this,arguments),t.type=e),n}}})),S.fn.extend({on:function(t,e,n,r){return It(this,t,e,n,r)},one:function(t,e,n,r){return It(this,t,e,n,r,1)},off:function(t,e,n){var r,i;if(t&&t.preventDefault&&t.handleObj)return r=t.handleObj,S(t.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof t){for(i in t)this.off(i,e,t[i]);return this}return!1!==e&&"function"!=typeof e||(n=e,e=void 0),!1===n&&(n=Rt),this.each((function(){S.event.remove(this,t,n,e)}))}});var Lt=/<script|<style|<link/i,wt=/checked\s*(?:[^=]|=\s*.checked.)/i,_t=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function jt(t,e){return I(t,"table")&&I(11!==e.nodeType?e:e.firstChild,"tr")&&S(t).children("tbody")[0]||t}function Mt(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function Pt(t){return"true/"===(t.type||"").slice(0,5)?t.type=t.type.slice(5):t.removeAttribute("type"),t}function Dt(t,e){var n,r,i,o,a,s;if(1===e.nodeType){if(J.hasData(t)&&(s=J.get(t).events))for(i in J.remove(e,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)S.event.add(e,i,s[i][n]);Q.hasData(t)&&(o=Q.access(t),a=S.extend({},o),Q.set(e,a))}}function Ut(t,e){var n=e.nodeName.toLowerCase();"input"===n&&mt.test(t.type)?e.checked=t.checked:"input"!==n&&"textarea"!==n||(e.defaultValue=t.defaultValue)}function Ft(t,e,n,r){e=c(e);var i,o,a,s,u,l,f=0,p=t.length,h=p-1,d=e[0],m=g(d);if(m||p>1&&"string"==typeof d&&!v.checkClone&&wt.test(d))return t.each((function(i){var o=t.eq(i);m&&(e[0]=d.call(this,i,o.html())),Ft(o,e,n,r)}));if(p&&(o=(i=bt(e,t[0].ownerDocument,!1,t,r)).firstChild,1===i.childNodes.length&&(i=o),o||r)){for(s=(a=S.map(Tt(i,"script"),Mt)).length;f<p;f++)u=i,f!==h&&(u=S.clone(u,!0,!0),s&&S.merge(a,Tt(u,"script"))),n.call(t[f],u,f);if(s)for(l=a[a.length-1].ownerDocument,S.map(a,Pt),f=0;f<s;f++)u=a[f],gt.test(u.type||"")&&!J.access(u,"globalEval")&&S.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?S._evalUrl&&!u.noModule&&S._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")},l):E(u.textContent.replace(_t,""),u,l))}return t}function Bt(t,e,n){for(var r,i=e?S.filter(e,t):t,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||S.cleanData(Tt(r)),r.parentNode&&(n&&at(r)&&Ot(Tt(r,"script")),r.parentNode.removeChild(r));return t}S.extend({htmlPrefilter:function(t){return t},clone:function(t,e,n){var r,i,o,a,s=t.cloneNode(!0),c=at(t);if(!(v.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||S.isXMLDoc(t)))for(a=Tt(s),r=0,i=(o=Tt(t)).length;r<i;r++)Ut(o[r],a[r]);if(e)if(n)for(o=o||Tt(t),a=a||Tt(s),r=0,i=o.length;r<i;r++)Dt(o[r],a[r]);else Dt(t,s);return(a=Tt(s,"script")).length>0&&Ot(a,!c&&Tt(t,"script")),s},cleanData:function(t){for(var e,n,r,i=S.event.special,o=0;void 0!==(n=t[o]);o++)if(Y(n)){if(e=n[J.expando]){if(e.events)for(r in e.events)i[r]?S.event.remove(n,r):S.removeEvent(n,r,e.handle);n[J.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),S.fn.extend({detach:function(t){return Bt(this,t,!0)},remove:function(t){return Bt(this,t)},text:function(t){return q(this,(function(t){return void 0===t?S.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)}))}),null,t,arguments.length)},append:function(){return Ft(this,arguments,(function(t){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||jt(this,t).appendChild(t)}))},prepend:function(){return Ft(this,arguments,(function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=jt(this,t);e.insertBefore(t,e.firstChild)}}))},before:function(){return Ft(this,arguments,(function(t){this.parentNode&&this.parentNode.insertBefore(t,this)}))},after:function(){return Ft(this,arguments,(function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)}))},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(S.cleanData(Tt(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map((function(){return S.clone(this,t,e)}))},html:function(t){return q(this,(function(t){var e=this[0]||{},n=0,r=this.length;if(void 0===t&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!Lt.test(t)&&!yt[(vt.exec(t)||["",""])[1].toLowerCase()]){t=S.htmlPrefilter(t);try{for(;n<r;n++)1===(e=this[n]||{}).nodeType&&(S.cleanData(Tt(e,!1)),e.innerHTML=t);e=0}catch(t){}}e&&this.empty().append(t)}),null,t,arguments.length)},replaceWith:function(){var t=[];return Ft(this,arguments,(function(e){var n=this.parentNode;S.inArray(this,t)<0&&(S.cleanData(Tt(this)),n&&n.replaceChild(e,this))}),t)}}),S.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},(function(t,e){S.fn[t]=function(t){for(var n,r=[],i=S(t),o=i.length-1,a=0;a<=o;a++)n=a===o?this:this.clone(!0),S(i[a])[e](n),u.apply(r,n.get());return this.pushStack(r)}}));var Ht=new RegExp("^("+nt+")(?!px)[a-z%]+$","i"),Wt=function(t){var e=t.ownerDocument.defaultView;return e&&e.opener||(e=n),e.getComputedStyle(t)},Gt=function(t,e,n){var r,i,o={};for(i in e)o[i]=t.style[i],t.style[i]=e[i];for(i in r=n.call(t),e)t.style[i]=o[i];return r},qt=new RegExp(it.join("|"),"i");function Vt(t,e,n){var r,i,o,a,s=t.style;return(n=n||Wt(t))&&(""!==(a=n.getPropertyValue(e)||n[e])||at(t)||(a=S.style(t,e)),!v.pixelBoxStyles()&&Ht.test(a)&&qt.test(e)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function Kt(t,e){return{get:function(){if(!t())return(this.get=e).apply(this,arguments);delete this.get}}}!function(){function t(){if(l){u.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",ot.appendChild(u).appendChild(l);var t=n.getComputedStyle(l);r="1%"!==t.top,c=12===e(t.marginLeft),l.style.right="60%",a=36===e(t.right),i=36===e(t.width),l.style.position="absolute",o=12===e(l.offsetWidth/3),ot.removeChild(u),l=null}}function e(t){return Math.round(parseFloat(t))}var r,i,o,a,s,c,u=T.createElement("div"),l=T.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",v.clearCloneStyle="content-box"===l.style.backgroundClip,S.extend(v,{boxSizingReliable:function(){return t(),i},pixelBoxStyles:function(){return t(),a},pixelPosition:function(){return t(),r},reliableMarginLeft:function(){return t(),c},scrollboxSize:function(){return t(),o},reliableTrDimensions:function(){var t,e,r,i;return null==s&&(t=T.createElement("table"),e=T.createElement("tr"),r=T.createElement("div"),t.style.cssText="position:absolute;left:-11111px",e.style.height="1px",r.style.height="9px",ot.appendChild(t).appendChild(e).appendChild(r),i=n.getComputedStyle(e),s=parseInt(i.height)>3,ot.removeChild(t)),s}}))}();var zt=["Webkit","Moz","ms"],$t=T.createElement("div").style,Yt={};function Xt(t){var e=S.cssProps[t]||Yt[t];return e||(t in $t?t:Yt[t]=function(t){for(var e=t[0].toUpperCase()+t.slice(1),n=zt.length;n--;)if((t=zt[n]+e)in $t)return t}(t)||t)}var Jt=/^(none|table(?!-c[ea]).+)/,Qt=/^--/,Zt={position:"absolute",visibility:"hidden",display:"block"},te={letterSpacing:"0",fontWeight:"400"};function ee(t,e,n){var r=rt.exec(e);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):e}function ne(t,e,n,r,i,o){var a="width"===e?1:0,s=0,c=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(c+=S.css(t,n+it[a],!0,i)),r?("content"===n&&(c-=S.css(t,"padding"+it[a],!0,i)),"margin"!==n&&(c-=S.css(t,"border"+it[a]+"Width",!0,i))):(c+=S.css(t,"padding"+it[a],!0,i),"padding"!==n?c+=S.css(t,"border"+it[a]+"Width",!0,i):s+=S.css(t,"border"+it[a]+"Width",!0,i));return!r&&o>=0&&(c+=Math.max(0,Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-o-c-s-.5))||0),c}function re(t,e,n){var r=Wt(t),i=(!v.boxSizingReliable()||n)&&"border-box"===S.css(t,"boxSizing",!1,r),o=i,a=Vt(t,e,r),s="offset"+e[0].toUpperCase()+e.slice(1);if(Ht.test(a)){if(!n)return a;a="auto"}return(!v.boxSizingReliable()&&i||!v.reliableTrDimensions()&&I(t,"tr")||"auto"===a||!parseFloat(a)&&"inline"===S.css(t,"display",!1,r))&&t.getClientRects().length&&(i="border-box"===S.css(t,"boxSizing",!1,r),(o=s in t)&&(a=t[s])),(a=parseFloat(a)||0)+ne(t,e,n||(i?"border":"content"),o,r,a)+"px"}function ie(t,e,n,r,i){return new ie.prototype.init(t,e,n,r,i)}S.extend({cssHooks:{opacity:{get:function(t,e){if(e){var n=Vt(t,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(t,e,n,r){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var i,o,a,s=$(e),c=Qt.test(e),u=t.style;if(c||(e=Xt(s)),a=S.cssHooks[e]||S.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(t,!1,r))?i:u[e];"string"===(o=typeof n)&&(i=rt.exec(n))&&i[1]&&(n=ut(t,e,i),o="number"),null!=n&&n==n&&("number"!==o||c||(n+=i&&i[3]||(S.cssNumber[s]?"":"px")),v.clearCloneStyle||""!==n||0!==e.indexOf("background")||(u[e]="inherit"),a&&"set"in a&&void 0===(n=a.set(t,n,r))||(c?u.setProperty(e,n):u[e]=n))}},css:function(t,e,n,r){var i,o,a,s=$(e);return Qt.test(e)||(e=Xt(s)),(a=S.cssHooks[e]||S.cssHooks[s])&&"get"in a&&(i=a.get(t,!0,n)),void 0===i&&(i=Vt(t,e,r)),"normal"===i&&e in te&&(i=te[e]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),S.each(["height","width"],(function(t,e){S.cssHooks[e]={get:function(t,n,r){if(n)return!Jt.test(S.css(t,"display"))||t.getClientRects().length&&t.getBoundingClientRect().width?re(t,e,r):Gt(t,Zt,(function(){return re(t,e,r)}))},set:function(t,n,r){var i,o=Wt(t),a=!v.scrollboxSize()&&"absolute"===o.position,s=(a||r)&&"border-box"===S.css(t,"boxSizing",!1,o),c=r?ne(t,e,r,s,o):0;return s&&a&&(c-=Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-parseFloat(o[e])-ne(t,e,"border",!1,o)-.5)),c&&(i=rt.exec(n))&&"px"!==(i[3]||"px")&&(t.style[e]=n,n=S.css(t,e)),ee(0,n,c)}}})),S.cssHooks.marginLeft=Kt(v.reliableMarginLeft,(function(t,e){if(e)return(parseFloat(Vt(t,"marginLeft"))||t.getBoundingClientRect().left-Gt(t,{marginLeft:0},(function(){return t.getBoundingClientRect().left})))+"px"})),S.each({margin:"",padding:"",border:"Width"},(function(t,e){S.cssHooks[t+e]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];r<4;r++)i[t+it[r]+e]=o[r]||o[r-2]||o[0];return i}},"margin"!==t&&(S.cssHooks[t+e].set=ee)})),S.fn.extend({css:function(t,e){return q(this,(function(t,e,n){var r,i,o={},a=0;if(Array.isArray(e)){for(r=Wt(t),i=e.length;a<i;a++)o[e[a]]=S.css(t,e[a],!1,r);return o}return void 0!==n?S.style(t,e,n):S.css(t,e)}),t,e,arguments.length>1)}}),S.Tween=ie,ie.prototype={constructor:ie,init:function(t,e,n,r,i,o){this.elem=t,this.prop=n,this.easing=i||S.easing._default,this.options=e,this.start=this.now=this.cur(),this.end=r,this.unit=o||(S.cssNumber[n]?"":"px")},cur:function(){var t=ie.propHooks[this.prop];return t&&t.get?t.get(this):ie.propHooks._default.get(this)},run:function(t){var e,n=ie.propHooks[this.prop];return this.options.duration?this.pos=e=S.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):ie.propHooks._default.set(this),this}},ie.prototype.init.prototype=ie.prototype,ie.propHooks={_default:{get:function(t){var e;return 1!==t.elem.nodeType||null!=t.elem[t.prop]&&null==t.elem.style[t.prop]?t.elem[t.prop]:(e=S.css(t.elem,t.prop,""))&&"auto"!==e?e:0},set:function(t){S.fx.step[t.prop]?S.fx.step[t.prop](t):1!==t.elem.nodeType||!S.cssHooks[t.prop]&&null==t.elem.style[Xt(t.prop)]?t.elem[t.prop]=t.now:S.style(t.elem,t.prop,t.now+t.unit)}}},ie.propHooks.scrollTop=ie.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},S.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2},_default:"swing"},S.fx=ie.prototype.init,S.fx.step={};var oe,ae,se=/^(?:toggle|show|hide)$/,ce=/queueHooks$/;function ue(){ae&&(!1===T.hidden&&n.requestAnimationFrame?n.requestAnimationFrame(ue):n.setTimeout(ue,S.fx.interval),S.fx.tick())}function le(){return n.setTimeout((function(){oe=void 0})),oe=Date.now()}function fe(t,e){var n,r=0,i={height:t};for(e=e?1:0;r<4;r+=2-e)i["margin"+(n=it[r])]=i["padding"+n]=t;return e&&(i.opacity=i.width=t),i}function pe(t,e,n){for(var r,i=(he.tweeners[e]||[]).concat(he.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,e,t))return r}function he(t,e,n){var r,i,o=0,a=he.prefilters.length,s=S.Deferred().always((function(){delete c.elem})),c=function(){if(i)return!1;for(var e=oe||le(),n=Math.max(0,u.startTime+u.duration-e),r=1-(n/u.duration||0),o=0,a=u.tweens.length;o<a;o++)u.tweens[o].run(r);return s.notifyWith(t,[u,r,n]),r<1&&a?n:(a||s.notifyWith(t,[u,1,0]),s.resolveWith(t,[u]),!1)},u=s.promise({elem:t,props:S.extend({},e),opts:S.extend(!0,{specialEasing:{},easing:S.easing._default},n),originalProperties:e,originalOptions:n,startTime:oe||le(),duration:n.duration,tweens:[],createTween:function(e,n){var r=S.Tween(t,u.opts,e,n,u.opts.specialEasing[e]||u.opts.easing);return u.tweens.push(r),r},stop:function(e){var n=0,r=e?u.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)u.tweens[n].run(1);return e?(s.notifyWith(t,[u,1,0]),s.resolveWith(t,[u,e])):s.rejectWith(t,[u,e]),this}}),l=u.props;for(!function(t,e){var n,r,i,o,a;for(n in t)if(i=e[r=$(n)],o=t[n],Array.isArray(o)&&(i=o[1],o=t[n]=o[0]),n!==r&&(t[r]=o,delete t[n]),(a=S.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete t[r],o)n in t||(t[n]=o[n],e[n]=i);else e[r]=i}(l,u.opts.specialEasing);o<a;o++)if(r=he.prefilters[o].call(u,t,l,u.opts))return g(r.stop)&&(S._queueHooks(u.elem,u.opts.queue).stop=r.stop.bind(r)),r;return S.map(l,pe,u),g(u.opts.start)&&u.opts.start.call(t,u),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always),S.fx.timer(S.extend(c,{elem:t,anim:u,queue:u.opts.queue})),u}S.Animation=S.extend(he,{tweeners:{"*":[function(t,e){var n=this.createTween(t,e);return ut(n.elem,t,rt.exec(e),n),n}]},tweener:function(t,e){g(t)?(e=t,t=["*"]):t=t.match(D);for(var n,r=0,i=t.length;r<i;r++)n=t[r],he.tweeners[n]=he.tweeners[n]||[],he.tweeners[n].unshift(e)},prefilters:[function(t,e,n){var r,i,o,a,s,c,u,l,f="width"in e||"height"in e,p=this,h={},d=t.style,m=t.nodeType&&ct(t),v=J.get(t,"fxshow");for(r in n.queue||(null==(a=S._queueHooks(t,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always((function(){p.always((function(){a.unqueued--,S.queue(t,"fx").length||a.empty.fire()}))}))),e)if(i=e[r],se.test(i)){if(delete e[r],o=o||"toggle"===i,i===(m?"hide":"show")){if("show"!==i||!v||void 0===v[r])continue;m=!0}h[r]=v&&v[r]||S.style(t,r)}if((c=!S.isEmptyObject(e))||!S.isEmptyObject(h))for(r in f&&1===t.nodeType&&(n.overflow=[d.overflow,d.overflowX,d.overflowY],null==(u=v&&v.display)&&(u=J.get(t,"display")),"none"===(l=S.css(t,"display"))&&(u?l=u:(pt([t],!0),u=t.style.display||u,l=S.css(t,"display"),pt([t]))),("inline"===l||"inline-block"===l&&null!=u)&&"none"===S.css(t,"float")&&(c||(p.done((function(){d.display=u})),null==u&&(l=d.display,u="none"===l?"":l)),d.display="inline-block")),n.overflow&&(d.overflow="hidden",p.always((function(){d.overflow=n.overflow[0],d.overflowX=n.overflow[1],d.overflowY=n.overflow[2]}))),c=!1,h)c||(v?"hidden"in v&&(m=v.hidden):v=J.access(t,"fxshow",{display:u}),o&&(v.hidden=!m),m&&pt([t],!0),p.done((function(){for(r in m||pt([t]),J.remove(t,"fxshow"),h)S.style(t,r,h[r])}))),c=pe(m?v[r]:0,r,p),r in v||(v[r]=c.start,m&&(c.end=c.start,c.start=0))}],prefilter:function(t,e){e?he.prefilters.unshift(t):he.prefilters.push(t)}}),S.speed=function(t,e,n){var r=t&&"object"==typeof t?S.extend({},t):{complete:n||!n&&e||g(t)&&t,duration:t,easing:n&&e||e&&!g(e)&&e};return S.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in S.fx.speeds?r.duration=S.fx.speeds[r.duration]:r.duration=S.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){g(r.old)&&r.old.call(this),r.queue&&S.dequeue(this,r.queue)},r},S.fn.extend({fadeTo:function(t,e,n,r){return this.filter(ct).css("opacity",0).show().end().animate({opacity:e},t,n,r)},animate:function(t,e,n,r){var i=S.isEmptyObject(t),o=S.speed(e,n,r),a=function(){var e=he(this,S.extend({},t),o);(i||J.get(this,"finish"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(t,e,n){var r=function(t){var e=t.stop;delete t.stop,e(n)};return"string"!=typeof t&&(n=e,e=t,t=void 0),e&&this.queue(t||"fx",[]),this.each((function(){var e=!0,i=null!=t&&t+"queueHooks",o=S.timers,a=J.get(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&ce.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=t&&o[i].queue!==t||(o[i].anim.stop(n),e=!1,o.splice(i,1));!e&&n||S.dequeue(this,t)}))},finish:function(t){return!1!==t&&(t=t||"fx"),this.each((function(){var e,n=J.get(this),r=n[t+"queue"],i=n[t+"queueHooks"],o=S.timers,a=r?r.length:0;for(n.finish=!0,S.queue(this,t,[]),i&&i.stop&&i.stop.call(this,!0),e=o.length;e--;)o[e].elem===this&&o[e].queue===t&&(o[e].anim.stop(!0),o.splice(e,1));for(e=0;e<a;e++)r[e]&&r[e].finish&&r[e].finish.call(this);delete n.finish}))}}),S.each(["toggle","show","hide"],(function(t,e){var n=S.fn[e];S.fn[e]=function(t,r,i){return null==t||"boolean"==typeof t?n.apply(this,arguments):this.animate(fe(e,!0),t,r,i)}})),S.each({slideDown:fe("show"),slideUp:fe("hide"),slideToggle:fe("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},(function(t,e){S.fn[t]=function(t,n,r){return this.animate(e,t,n,r)}})),S.timers=[],S.fx.tick=function(){var t,e=0,n=S.timers;for(oe=Date.now();e<n.length;e++)(t=n[e])()||n[e]!==t||n.splice(e--,1);n.length||S.fx.stop(),oe=void 0},S.fx.timer=function(t){S.timers.push(t),S.fx.start()},S.fx.interval=13,S.fx.start=function(){ae||(ae=!0,ue())},S.fx.stop=function(){ae=null},S.fx.speeds={slow:600,fast:200,_default:400},S.fn.delay=function(t,e){return t=S.fx&&S.fx.speeds[t]||t,e=e||"fx",this.queue(e,(function(e,r){var i=n.setTimeout(e,t);r.stop=function(){n.clearTimeout(i)}}))},function(){var t=T.createElement("input"),e=T.createElement("select").appendChild(T.createElement("option"));t.type="checkbox",v.checkOn=""!==t.value,v.optSelected=e.selected,(t=T.createElement("input")).value="t",t.type="radio",v.radioValue="t"===t.value}();var de,me=S.expr.attrHandle;S.fn.extend({attr:function(t,e){return q(this,S.attr,t,e,arguments.length>1)},removeAttr:function(t){return this.each((function(){S.removeAttr(this,t)}))}}),S.extend({attr:function(t,e,n){var r,i,o=t.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===t.getAttribute?S.prop(t,e,n):(1===o&&S.isXMLDoc(t)||(i=S.attrHooks[e.toLowerCase()]||(S.expr.match.bool.test(e)?de:void 0)),void 0!==n?null===n?void S.removeAttr(t,e):i&&"set"in i&&void 0!==(r=i.set(t,n,e))?r:(t.setAttribute(e,n+""),n):i&&"get"in i&&null!==(r=i.get(t,e))?r:null==(r=S.find.attr(t,e))?void 0:r)},attrHooks:{type:{set:function(t,e){if(!v.radioValue&&"radio"===e&&I(t,"input")){var n=t.value;return t.setAttribute("type",e),n&&(t.value=n),e}}}},removeAttr:function(t,e){var n,r=0,i=e&&e.match(D);if(i&&1===t.nodeType)for(;n=i[r++];)t.removeAttribute(n)}}),de={set:function(t,e,n){return!1===e?S.removeAttr(t,n):t.setAttribute(n,n),n}},S.each(S.expr.match.bool.source.match(/\w+/g),(function(t,e){var n=me[e]||S.find.attr;me[e]=function(t,e,r){var i,o,a=e.toLowerCase();return r||(o=me[a],me[a]=i,i=null!=n(t,e,r)?a:null,me[a]=o),i}}));var ve=/^(?:input|select|textarea|button)$/i,ge=/^(?:a|area)$/i;function ye(t){return(t.match(D)||[]).join(" ")}function Te(t){return t.getAttribute&&t.getAttribute("class")||""}function Oe(t){return Array.isArray(t)?t:"string"==typeof t&&t.match(D)||[]}S.fn.extend({prop:function(t,e){return q(this,S.prop,t,e,arguments.length>1)},removeProp:function(t){return this.each((function(){delete this[S.propFix[t]||t]}))}}),S.extend({prop:function(t,e,n){var r,i,o=t.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&S.isXMLDoc(t)||(e=S.propFix[e]||e,i=S.propHooks[e]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(t,n,e))?r:t[e]=n:i&&"get"in i&&null!==(r=i.get(t,e))?r:t[e]},propHooks:{tabIndex:{get:function(t){var e=S.find.attr(t,"tabindex");return e?parseInt(e,10):ve.test(t.nodeName)||ge.test(t.nodeName)&&t.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),v.optSelected||(S.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null},set:function(t){var e=t.parentNode;e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex)}}),S.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){S.propFix[this.toLowerCase()]=this})),S.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,c=0;if(g(t))return this.each((function(e){S(this).addClass(t.call(this,e,Te(this)))}));if((e=Oe(t)).length)for(;n=this[c++];)if(i=Te(n),r=1===n.nodeType&&" "+ye(i)+" "){for(a=0;o=e[a++];)r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=ye(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,c=0;if(g(t))return this.each((function(e){S(this).removeClass(t.call(this,e,Te(this)))}));if(!arguments.length)return this.attr("class","");if((e=Oe(t)).length)for(;n=this[c++];)if(i=Te(n),r=1===n.nodeType&&" "+ye(i)+" "){for(a=0;o=e[a++];)for(;r.indexOf(" "+o+" ")>-1;)r=r.replace(" "+o+" "," ");i!==(s=ye(r))&&n.setAttribute("class",s)}return this},toggleClass:function(t,e){var n=typeof t,r="string"===n||Array.isArray(t);return"boolean"==typeof e&&r?e?this.addClass(t):this.removeClass(t):g(t)?this.each((function(n){S(this).toggleClass(t.call(this,n,Te(this),e),e)})):this.each((function(){var e,i,o,a;if(r)for(i=0,o=S(this),a=Oe(t);e=a[i++];)o.hasClass(e)?o.removeClass(e):o.addClass(e);else void 0!==t&&"boolean"!==n||((e=Te(this))&&J.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===t?"":J.get(this,"__className__")||""))}))},hasClass:function(t){var e,n,r=0;for(e=" "+t+" ";n=this[r++];)if(1===n.nodeType&&(" "+ye(Te(n))+" ").indexOf(e)>-1)return!0;return!1}});var Ee=/\r/g;S.fn.extend({val:function(t){var e,n,r,i=this[0];return arguments.length?(r=g(t),this.each((function(n){var i;1===this.nodeType&&(null==(i=r?t.call(this,n,S(this).val()):t)?i="":"number"==typeof i?i+="":Array.isArray(i)&&(i=S.map(i,(function(t){return null==t?"":t+""}))),(e=S.valHooks[this.type]||S.valHooks[this.nodeName.toLowerCase()])&&"set"in e&&void 0!==e.set(this,i,"value")||(this.value=i))}))):i?(e=S.valHooks[i.type]||S.valHooks[i.nodeName.toLowerCase()])&&"get"in e&&void 0!==(n=e.get(i,"value"))?n:"string"==typeof(n=i.value)?n.replace(Ee,""):null==n?"":n:void 0}}),S.extend({valHooks:{option:{get:function(t){var e=S.find.attr(t,"value");return null!=e?e:ye(S.text(t))}},select:{get:function(t){var e,n,r,i=t.options,o=t.selectedIndex,a="select-one"===t.type,s=a?null:[],c=a?o+1:i.length;for(r=o<0?c:a?o:0;r<c;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!I(n.parentNode,"optgroup"))){if(e=S(n).val(),a)return e;s.push(e)}return s},set:function(t,e){for(var n,r,i=t.options,o=S.makeArray(e),a=i.length;a--;)((r=i[a]).selected=S.inArray(S.valHooks.option.get(r),o)>-1)&&(n=!0);return n||(t.selectedIndex=-1),o}}}}),S.each(["radio","checkbox"],(function(){S.valHooks[this]={set:function(t,e){if(Array.isArray(e))return t.checked=S.inArray(S(t).val(),e)>-1}},v.checkOn||(S.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})})),v.focusin="onfocusin"in n;var be=/^(?:focusinfocus|focusoutblur)$/,Se=function(t){t.stopPropagation()};S.extend(S.event,{trigger:function(t,e,r,i){var o,a,s,c,u,l,f,p,d=[r||T],m=h.call(t,"type")?t.type:t,v=h.call(t,"namespace")?t.namespace.split("."):[];if(a=p=s=r=r||T,3!==r.nodeType&&8!==r.nodeType&&!be.test(m+S.event.triggered)&&(m.indexOf(".")>-1&&(v=m.split("."),m=v.shift(),v.sort()),u=m.indexOf(":")<0&&"on"+m,(t=t[S.expando]?t:new S.Event(m,"object"==typeof t&&t)).isTrigger=i?2:3,t.namespace=v.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+v.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),e=null==e?[t]:S.makeArray(e,[t]),f=S.event.special[m]||{},i||!f.trigger||!1!==f.trigger.apply(r,e))){if(!i&&!f.noBubble&&!y(r)){for(c=f.delegateType||m,be.test(c+m)||(a=a.parentNode);a;a=a.parentNode)d.push(a),s=a;s===(r.ownerDocument||T)&&d.push(s.defaultView||s.parentWindow||n)}for(o=0;(a=d[o++])&&!t.isPropagationStopped();)p=a,t.type=o>1?c:f.bindType||m,(l=(J.get(a,"events")||Object.create(null))[t.type]&&J.get(a,"handle"))&&l.apply(a,e),(l=u&&a[u])&&l.apply&&Y(a)&&(t.result=l.apply(a,e),!1===t.result&&t.preventDefault());return t.type=m,i||t.isDefaultPrevented()||f._default&&!1!==f._default.apply(d.pop(),e)||!Y(r)||u&&g(r[m])&&!y(r)&&((s=r[u])&&(r[u]=null),S.event.triggered=m,t.isPropagationStopped()&&p.addEventListener(m,Se),r[m](),t.isPropagationStopped()&&p.removeEventListener(m,Se),S.event.triggered=void 0,s&&(r[u]=s)),t.result}},simulate:function(t,e,n){var r=S.extend(new S.Event,n,{type:t,isSimulated:!0});S.event.trigger(r,null,e)}}),S.fn.extend({trigger:function(t,e){return this.each((function(){S.event.trigger(t,e,this)}))},triggerHandler:function(t,e){var n=this[0];if(n)return S.event.trigger(t,e,n,!0)}}),v.focusin||S.each({focus:"focusin",blur:"focusout"},(function(t,e){var n=function(t){S.event.simulate(e,t.target,S.event.fix(t))};S.event.special[e]={setup:function(){var r=this.ownerDocument||this.document||this,i=J.access(r,e);i||r.addEventListener(t,n,!0),J.access(r,e,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this.document||this,i=J.access(r,e)-1;i?J.access(r,e,i):(r.removeEventListener(t,n,!0),J.remove(r,e))}}}));var Ne=n.location,xe={guid:Date.now()},Ae=/\?/;S.parseXML=function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new n.DOMParser).parseFromString(t,"text/xml")}catch(t){e=void 0}return e&&!e.getElementsByTagName("parsererror").length||S.error("Invalid XML: "+t),e};var Re=/\[\]$/,Ce=/\r?\n/g,Ie=/^(?:submit|button|image|reset|file)$/i,ke=/^(?:input|select|textarea|keygen)/i;function Le(t,e,n,r){var i;if(Array.isArray(e))S.each(e,(function(e,i){n||Re.test(t)?r(t,i):Le(t+"["+("object"==typeof i&&null!=i?e:"")+"]",i,n,r)}));else if(n||"object"!==b(e))r(t,e);else for(i in e)Le(t+"["+i+"]",e[i],n,r)}S.param=function(t,e){var n,r=[],i=function(t,e){var n=g(e)?e():e;r[r.length]=encodeURIComponent(t)+"="+encodeURIComponent(null==n?"":n)};if(null==t)return"";if(Array.isArray(t)||t.jquery&&!S.isPlainObject(t))S.each(t,(function(){i(this.name,this.value)}));else for(n in t)Le(n,t[n],e,i);return r.join("&")},S.fn.extend({serialize:function(){return S.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var t=S.prop(this,"elements");return t?S.makeArray(t):this})).filter((function(){var t=this.type;return this.name&&!S(this).is(":disabled")&&ke.test(this.nodeName)&&!Ie.test(t)&&(this.checked||!mt.test(t))})).map((function(t,e){var n=S(this).val();return null==n?null:Array.isArray(n)?S.map(n,(function(t){return{name:e.name,value:t.replace(Ce,"\r\n")}})):{name:e.name,value:n.replace(Ce,"\r\n")}})).get()}});var we=/%20/g,_e=/#.*$/,je=/([?&])_=[^&]*/,Me=/^(.*?):[ \t]*([^\r\n]*)$/gm,Pe=/^(?:GET|HEAD)$/,De=/^\/\//,Ue={},Fe={},Be="*/".concat("*"),He=T.createElement("a");function We(t){return function(e,n){"string"!=typeof e&&(n=e,e="*");var r,i=0,o=e.toLowerCase().match(D)||[];if(g(n))for(;r=o[i++];)"+"===r[0]?(r=r.slice(1)||"*",(t[r]=t[r]||[]).unshift(n)):(t[r]=t[r]||[]).push(n)}}function Ge(t,e,n,r){var i={},o=t===Fe;function a(s){var c;return i[s]=!0,S.each(t[s]||[],(function(t,s){var u=s(e,n,r);return"string"!=typeof u||o||i[u]?o?!(c=u):void 0:(e.dataTypes.unshift(u),a(u),!1)})),c}return a(e.dataTypes[0])||!i["*"]&&a("*")}function qe(t,e){var n,r,i=S.ajaxSettings.flatOptions||{};for(n in e)void 0!==e[n]&&((i[n]?t:r||(r={}))[n]=e[n]);return r&&S.extend(!0,t,r),t}He.href=Ne.href,S.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ne.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Ne.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Be,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":S.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?qe(qe(t,S.ajaxSettings),e):qe(S.ajaxSettings,t)},ajaxPrefilter:We(Ue),ajaxTransport:We(Fe),ajax:function(t,e){"object"==typeof t&&(e=t,t=void 0),e=e||{};var r,i,o,a,s,c,u,l,f,p,h=S.ajaxSetup({},e),d=h.context||h,m=h.context&&(d.nodeType||d.jquery)?S(d):S.event,v=S.Deferred(),g=S.Callbacks("once memory"),y=h.statusCode||{},O={},E={},b="canceled",N={readyState:0,getResponseHeader:function(t){var e;if(u){if(!a)for(a={};e=Me.exec(o);)a[e[1].toLowerCase()+" "]=(a[e[1].toLowerCase()+" "]||[]).concat(e[2]);e=a[t.toLowerCase()+" "]}return null==e?null:e.join(", ")},getAllResponseHeaders:function(){return u?o:null},setRequestHeader:function(t,e){return null==u&&(t=E[t.toLowerCase()]=E[t.toLowerCase()]||t,O[t]=e),this},overrideMimeType:function(t){return null==u&&(h.mimeType=t),this},statusCode:function(t){var e;if(t)if(u)N.always(t[N.status]);else for(e in t)y[e]=[y[e],t[e]];return this},abort:function(t){var e=t||b;return r&&r.abort(e),x(0,e),this}};if(v.promise(N),h.url=((t||h.url||Ne.href)+"").replace(De,Ne.protocol+"//"),h.type=e.method||e.type||h.method||h.type,h.dataTypes=(h.dataType||"*").toLowerCase().match(D)||[""],null==h.crossDomain){c=T.createElement("a");try{c.href=h.url,c.href=c.href,h.crossDomain=He.protocol+"//"+He.host!=c.protocol+"//"+c.host}catch(t){h.crossDomain=!0}}if(h.data&&h.processData&&"string"!=typeof h.data&&(h.data=S.param(h.data,h.traditional)),Ge(Ue,h,e,N),u)return N;for(f in(l=S.event&&h.global)&&0==S.active++&&S.event.trigger("ajaxStart"),h.type=h.type.toUpperCase(),h.hasContent=!Pe.test(h.type),i=h.url.replace(_e,""),h.hasContent?h.data&&h.processData&&0===(h.contentType||"").indexOf("application/x-www-form-urlencoded")&&(h.data=h.data.replace(we,"+")):(p=h.url.slice(i.length),h.data&&(h.processData||"string"==typeof h.data)&&(i+=(Ae.test(i)?"&":"?")+h.data,delete h.data),!1===h.cache&&(i=i.replace(je,"$1"),p=(Ae.test(i)?"&":"?")+"_="+xe.guid+++p),h.url=i+p),h.ifModified&&(S.lastModified[i]&&N.setRequestHeader("If-Modified-Since",S.lastModified[i]),S.etag[i]&&N.setRequestHeader("If-None-Match",S.etag[i])),(h.data&&h.hasContent&&!1!==h.contentType||e.contentType)&&N.setRequestHeader("Content-Type",h.contentType),N.setRequestHeader("Accept",h.dataTypes[0]&&h.accepts[h.dataTypes[0]]?h.accepts[h.dataTypes[0]]+("*"!==h.dataTypes[0]?", "+Be+"; q=0.01":""):h.accepts["*"]),h.headers)N.setRequestHeader(f,h.headers[f]);if(h.beforeSend&&(!1===h.beforeSend.call(d,N,h)||u))return N.abort();if(b="abort",g.add(h.complete),N.done(h.success),N.fail(h.error),r=Ge(Fe,h,e,N)){if(N.readyState=1,l&&m.trigger("ajaxSend",[N,h]),u)return N;h.async&&h.timeout>0&&(s=n.setTimeout((function(){N.abort("timeout")}),h.timeout));try{u=!1,r.send(O,x)}catch(t){if(u)throw t;x(-1,t)}}else x(-1,"No Transport");function x(t,e,a,c){var f,p,T,O,E,b=e;u||(u=!0,s&&n.clearTimeout(s),r=void 0,o=c||"",N.readyState=t>0?4:0,f=t>=200&&t<300||304===t,a&&(O=function(t,e,n){for(var r,i,o,a,s=t.contents,c=t.dataTypes;"*"===c[0];)c.shift(),void 0===r&&(r=t.mimeType||e.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){c.unshift(i);break}if(c[0]in n)o=c[0];else{for(i in n){if(!c[0]||t.converters[i+" "+c[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==c[0]&&c.unshift(o),n[o]}(h,N,a)),!f&&S.inArray("script",h.dataTypes)>-1&&(h.converters["text script"]=function(){}),O=function(t,e,n,r){var i,o,a,s,c,u={},l=t.dataTypes.slice();if(l[1])for(a in t.converters)u[a.toLowerCase()]=t.converters[a];for(o=l.shift();o;)if(t.responseFields[o]&&(n[t.responseFields[o]]=e),!c&&r&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),c=o,o=l.shift())if("*"===o)o=c;else if("*"!==c&&c!==o){if(!(a=u[c+" "+o]||u["* "+o]))for(i in u)if((s=i.split(" "))[1]===o&&(a=u[c+" "+s[0]]||u["* "+s[0]])){!0===a?a=u[i]:!0!==u[i]&&(o=s[0],l.unshift(s[1]));break}if(!0!==a)if(a&&t.throws)e=a(e);else try{e=a(e)}catch(t){return{state:"parsererror",error:a?t:"No conversion from "+c+" to "+o}}}return{state:"success",data:e}}(h,O,N,f),f?(h.ifModified&&((E=N.getResponseHeader("Last-Modified"))&&(S.lastModified[i]=E),(E=N.getResponseHeader("etag"))&&(S.etag[i]=E)),204===t||"HEAD"===h.type?b="nocontent":304===t?b="notmodified":(b=O.state,p=O.data,f=!(T=O.error))):(T=b,!t&&b||(b="error",t<0&&(t=0))),N.status=t,N.statusText=(e||b)+"",f?v.resolveWith(d,[p,b,N]):v.rejectWith(d,[N,b,T]),N.statusCode(y),y=void 0,l&&m.trigger(f?"ajaxSuccess":"ajaxError",[N,h,f?p:T]),g.fireWith(d,[N,b]),l&&(m.trigger("ajaxComplete",[N,h]),--S.active||S.event.trigger("ajaxStop")))}return N},getJSON:function(t,e,n){return S.get(t,e,n,"json")},getScript:function(t,e){return S.get(t,void 0,e,"script")}}),S.each(["get","post"],(function(t,e){S[e]=function(t,n,r,i){return g(n)&&(i=i||r,r=n,n=void 0),S.ajax(S.extend({url:t,type:e,dataType:i,data:n,success:r},S.isPlainObject(t)&&t))}})),S.ajaxPrefilter((function(t){var e;for(e in t.headers)"content-type"===e.toLowerCase()&&(t.contentType=t.headers[e]||"")})),S._evalUrl=function(t,e,n){return S.ajax({url:t,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(t){S.globalEval(t,e,n)}})},S.fn.extend({wrapAll:function(t){var e;return this[0]&&(g(t)&&(t=t.call(this[0])),e=S(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map((function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t})).append(this)),this},wrapInner:function(t){return g(t)?this.each((function(e){S(this).wrapInner(t.call(this,e))})):this.each((function(){var e=S(this),n=e.contents();n.length?n.wrapAll(t):e.append(t)}))},wrap:function(t){var e=g(t);return this.each((function(n){S(this).wrapAll(e?t.call(this,n):t)}))},unwrap:function(t){return this.parent(t).not("body").each((function(){S(this).replaceWith(this.childNodes)})),this}}),S.expr.pseudos.hidden=function(t){return!S.expr.pseudos.visible(t)},S.expr.pseudos.visible=function(t){return!!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},S.ajaxSettings.xhr=function(){try{return new n.XMLHttpRequest}catch(t){}};var Ve={0:200,1223:204},Ke=S.ajaxSettings.xhr();v.cors=!!Ke&&"withCredentials"in Ke,v.ajax=Ke=!!Ke,S.ajaxTransport((function(t){var e,r;if(v.cors||Ke&&!t.crossDomain)return{send:function(i,o){var a,s=t.xhr();if(s.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)s[a]=t.xhrFields[a];for(a in t.mimeType&&s.overrideMimeType&&s.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest"),i)s.setRequestHeader(a,i[a]);e=function(t){return function(){e&&(e=r=s.onload=s.onerror=s.onabort=s.ontimeout=s.onreadystatechange=null,"abort"===t?s.abort():"error"===t?"number"!=typeof s.status?o(0,"error"):o(s.status,s.statusText):o(Ve[s.status]||s.status,s.statusText,"text"!==(s.responseType||"text")||"string"!=typeof s.responseText?{binary:s.response}:{text:s.responseText},s.getAllResponseHeaders()))}},s.onload=e(),r=s.onerror=s.ontimeout=e("error"),void 0!==s.onabort?s.onabort=r:s.onreadystatechange=function(){4===s.readyState&&n.setTimeout((function(){e&&r()}))},e=e("abort");try{s.send(t.hasContent&&t.data||null)}catch(t){if(e)throw t}},abort:function(){e&&e()}}})),S.ajaxPrefilter((function(t){t.crossDomain&&(t.contents.script=!1)})),S.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(t){return S.globalEval(t),t}}}),S.ajaxPrefilter("script",(function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET")})),S.ajaxTransport("script",(function(t){var e,n;if(t.crossDomain||t.scriptAttrs)return{send:function(r,i){e=S("<script>").attr(t.scriptAttrs||{}).prop({charset:t.scriptCharset,src:t.url}).on("load error",n=function(t){e.remove(),n=null,t&&i("error"===t.type?404:200,t.type)}),T.head.appendChild(e[0])},abort:function(){n&&n()}}}));var ze,$e=[],Ye=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=$e.pop()||S.expando+"_"+xe.guid++;return this[t]=!0,t}}),S.ajaxPrefilter("json jsonp",(function(t,e,r){var i,o,a,s=!1!==t.jsonp&&(Ye.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ye.test(t.data)&&"data");if(s||"jsonp"===t.dataTypes[0])return i=t.jsonpCallback=g(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(Ye,"$1"+i):!1!==t.jsonp&&(t.url+=(Ae.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||S.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=n[i],n[i]=function(){a=arguments},r.always((function(){void 0===o?S(n).removeProp(i):n[i]=o,t[i]&&(t.jsonpCallback=e.jsonpCallback,$e.push(i)),a&&g(o)&&o(a[0]),a=o=void 0})),"script"})),v.createHTMLDocument=((ze=T.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===ze.childNodes.length),S.parseHTML=function(t,e,n){return"string"!=typeof t?[]:("boolean"==typeof e&&(n=e,e=!1),e||(v.createHTMLDocument?((r=(e=T.implementation.createHTMLDocument("")).createElement("base")).href=T.location.href,e.head.appendChild(r)):e=T),o=!n&&[],(i=k.exec(t))?[e.createElement(i[1])]:(i=bt([t],e,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(t,e,n){var r,i,o,a=this,s=t.indexOf(" ");return s>-1&&(r=ye(t.slice(s)),t=t.slice(0,s)),g(e)?(n=e,e=void 0):e&&"object"==typeof e&&(i="POST"),a.length>0&&S.ajax({url:t,type:i||"GET",dataType:"html",data:e}).done((function(t){o=arguments,a.html(r?S("<div>").append(S.parseHTML(t)).find(r):t)})).always(n&&function(t,e){a.each((function(){n.apply(this,o||[t.responseText,e,t])}))}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,(function(e){return t===e.elem})).length},S.offset={setOffset:function(t,e,n){var r,i,o,a,s,c,u=S.css(t,"position"),l=S(t),f={};"static"===u&&(t.style.position="relative"),s=l.offset(),o=S.css(t,"top"),c=S.css(t,"left"),("absolute"===u||"fixed"===u)&&(o+c).indexOf("auto")>-1?(a=(r=l.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(c)||0),g(e)&&(e=e.call(t,n,S.extend({},s))),null!=e.top&&(f.top=e.top-s.top+a),null!=e.left&&(f.left=e.left-s.left+i),"using"in e?e.using.call(t,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),l.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each((function(e){S.offset.setOffset(this,t,e)}));var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var t,e,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))e=r.getBoundingClientRect();else{for(e=this.offset(),n=r.ownerDocument,t=r.offsetParent||n.documentElement;t&&(t===n.body||t===n.documentElement)&&"static"===S.css(t,"position");)t=t.parentNode;t&&t!==r&&1===t.nodeType&&((i=S(t).offset()).top+=S.css(t,"borderTopWidth",!0),i.left+=S.css(t,"borderLeftWidth",!0))}return{top:e.top-i.top-S.css(r,"marginTop",!0),left:e.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map((function(){for(var t=this.offsetParent;t&&"static"===S.css(t,"position");)t=t.offsetParent;return t||ot}))}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},(function(t,e){var n="pageYOffset"===e;S.fn[t]=function(r){return q(this,(function(t,r,i){var o;if(y(t)?o=t:9===t.nodeType&&(o=t.defaultView),void 0===i)return o?o[e]:t[r];o?o.scrollTo(n?o.pageXOffset:i,n?i:o.pageYOffset):t[r]=i}),t,r,arguments.length)}})),S.each(["top","left"],(function(t,e){S.cssHooks[e]=Kt(v.pixelPosition,(function(t,n){if(n)return n=Vt(t,e),Ht.test(n)?S(t).position()[e]+"px":n}))})),S.each({Height:"height",Width:"width"},(function(t,e){S.each({padding:"inner"+t,content:e,"":"outer"+t},(function(n,r){S.fn[r]=function(i,o){var a=arguments.length&&(n||"boolean"!=typeof i),s=n||(!0===i||!0===o?"margin":"border");return q(this,(function(e,n,i){var o;return y(e)?0===r.indexOf("outer")?e["inner"+t]:e.document.documentElement["client"+t]:9===e.nodeType?(o=e.documentElement,Math.max(e.body["scroll"+t],o["scroll"+t],e.body["offset"+t],o["offset"+t],o["client"+t])):void 0===i?S.css(e,n,s):S.style(e,n,i,s)}),e,a?i:void 0,a)}}))})),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],(function(t,e){S.fn[e]=function(t){return this.on(e,t)}})),S.fn.extend({bind:function(t,e,n){return this.on(t,null,e,n)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,n,r){return this.on(e,t,n,r)},undelegate:function(t,e,n){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",n)},hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),(function(t,e){S.fn[e]=function(t,n){return arguments.length>0?this.on(e,null,t,n):this.trigger(e)}}));var Xe=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;S.proxy=function(t,e){var n,r,i;if("string"==typeof e&&(n=t[e],e=t,t=n),g(t))return r=s.call(arguments,2),(i=function(){return t.apply(e||this,r.concat(s.call(arguments)))}).guid=t.guid=t.guid||S.guid++,i},S.holdReady=function(t){t?S.readyWait++:S.ready(!0)},S.isArray=Array.isArray,S.parseJSON=JSON.parse,S.nodeName=I,S.isFunction=g,S.isWindow=y,S.camelCase=$,S.type=b,S.now=Date.now,S.isNumeric=function(t){var e=S.type(t);return("number"===e||"string"===e)&&!isNaN(t-parseFloat(t))},S.trim=function(t){return null==t?"":(t+"").replace(Xe,"")},void 0===(r=function(){return S}.apply(e,[]))||(t.exports=r);var Je=n.jQuery,Qe=n.$;return S.noConflict=function(t){return n.$===S&&(n.$=Qe),t&&n.jQuery===S&&(n.jQuery=Je),S},void 0===i&&(n.jQuery=n.$=S),S}))},function(t,e,n){"use strict";n.r(e)},function(t,e,n){"use strict";n.r(e)},function(t,e,n){"use strict";n.r(e)}]);