/*! Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one or more contributor license agreements. * Licensed under the Elastic License 2.0; you may not use this file except in compliance with the Elastic License 2.0. */ (window.apm_bundle_jsonpfunction=window.apm_bundle_jsonpfunction||[]).push([[12],{1003:function(e,t,n){"use strict";var i=n(1004);e.exports=i},1004:function(e,t,n){"use strict";var i=n(1005),a=n(1025);function r(e){return function(){throw new Error("Function "+e+" is deprecated and cannot be used.")}}e.exports.Type=n(90),e.exports.Schema=n(137),e.exports.FAILSAFE_SCHEMA=n(205),e.exports.JSON_SCHEMA=n(473),e.exports.CORE_SCHEMA=n(472),e.exports.DEFAULT_SAFE_SCHEMA=n(157),e.exports.DEFAULT_FULL_SCHEMA=n(172),e.exports.load=i.load,e.exports.loadAll=i.loadAll,e.exports.safeLoad=i.safeLoad,e.exports.safeLoadAll=i.safeLoadAll,e.exports.dump=a.dump,e.exports.safeDump=a.safeDump,e.exports.YAMLException=n(156),e.exports.MINIMAL_SCHEMA=n(205),e.exports.SAFE_SCHEMA=n(157),e.exports.DEFAULT_SCHEMA=n(172),e.exports.scan=r("scan"),e.exports.parse=r("parse"),e.exports.compose=r("compose"),e.exports.addConstructor=r("addConstructor")},1005:function(e,t,n){"use strict";var i=n(136),a=n(156),r=n(1006),s=n(157),o=n(172),u=Object.prototype.hasOwnProperty,l=1,c=2,h=3,p=4,d=1,m=2,f=3,x=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,g=/[\x85\u2028\u2029]/,E=/[,\[\]\{\}]/,D=/^(?:!|!!|![a-z\-]+!)$/i,y=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function v(e){return Object.prototype.toString.call(e)}function C(e){return 10===e||13===e}function A(e){return 9===e||32===e}function S(e){return 9===e||32===e||10===e||13===e}function k(e){return 44===e||91===e||93===e||123===e||125===e}function F(e){var t;return 48<=e&&e<=57?e-48:97<=(t=32|e)&&t<=102?t-97+10:-1}function b(e){return 48===e?"\0":97===e?"":98===e?"\b":116===e||9===e?"\t":110===e?"\n":118===e?"\v":102===e?"\f":114===e?"\r":101===e?"":32===e?" ":34===e?'"':47===e?"/":92===e?"\\":78===e?"…":95===e?" ":76===e?"\u2028":80===e?"\u2029":""}function w(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10),56320+(e-65536&1023))}for(var T=new Array(256),I=new Array(256),B=0;B<256;B++)T[B]=b(B)?1:0,I[B]=b(B);function M(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||o,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function N(e,t){return new a(t,new r(e.filename,e.input,e.position,e.line,e.position-e.lineStart))}function P(e,t){throw N(e,t)}function L(e,t){e.onWarning&&e.onWarning.call(null,N(e,t))}var O={YAML:function(e,t,n){var i,a,r;null!==e.version&&P(e,"duplication of %YAML directive"),1!==n.length&&P(e,"YAML directive accepts exactly one argument"),null===(i=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&P(e,"ill-formed argument of the YAML directive"),a=parseInt(i[1],10),r=parseInt(i[2],10),1!==a&&P(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=r<2,1!==r&&2!==r&&L(e,"unsupported YAML version of the document")},TAG:function(e,t,n){var i,a;2!==n.length&&P(e,"TAG directive accepts exactly two arguments"),i=n[0],a=n[1],D.test(i)||P(e,"ill-formed tag handle (first argument) of the TAG directive"),u.call(e.tagMap,i)&&P(e,'there is a previously declared suffix for "'+i+'" tag handle'),y.test(a)||P(e,"ill-formed tag prefix (second argument) of the TAG directive"),e.tagMap[i]=a}};function j(e,t,n,i){var a,r,s,o;if(t1&&(e.result+=i.repeat("\n",t-1))}function K(e,t){var n,i,a=e.tag,r=e.anchor,s=[],o=!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=s),i=e.input.charCodeAt(e.position);0!==i&&45===i&&S(e.input.charCodeAt(e.position+1));)if(o=!0,e.position++,X(e,!0,-1)&&e.lineIndent<=t)s.push(null),i=e.input.charCodeAt(e.position);else if(n=e.line,V(e,t,h,!1,!0),s.push(e.result),X(e,!0,-1),i=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==i)P(e,"bad indentation of a sequence entry");else if(e.lineIndentt?b=1:e.lineIndent===t?b=0:e.lineIndentt?b=1:e.lineIndent===t?b=0:e.lineIndentt)&&(V(e,t,p,!0,a)&&(g?f=e.result:x=e.result),g||(U(e,h,d,m,f,x,r,s),m=f=x=null),X(e,!0,-1),o=e.input.charCodeAt(e.position)),e.lineIndent>t&&0!==o)P(e,"bad indentation of a mapping entry");else if(e.lineIndent=0))break;0===r?P(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):c?P(e,"repeat of an indentation width identifier"):(h=t+r-1,c=!0)}if(A(s)){do{s=e.input.charCodeAt(++e.position)}while(A(s));if(35===s)do{s=e.input.charCodeAt(++e.position)}while(!C(s)&&0!==s)}for(;0!==s;){for(_(e),e.lineIndent=0,s=e.input.charCodeAt(e.position);(!c||e.lineIndenth&&(h=e.lineIndent),C(s))p++;else{if(e.lineIndent0){for(a=s,r=0;a>0;a--)(s=F(o=e.input.charCodeAt(++e.position)))>=0?r=(r<<4)+s:P(e,"expected hexadecimal character");e.result+=w(r),e.position++}else P(e,"unknown escape sequence");n=i=e.position}else C(o)?(j(e,n,i,!0),z(e,X(e,!1,t)),n=i=e.position):e.position===e.lineStart&&J(e)?P(e,"unexpected end of the document within a double quoted scalar"):(e.position++,i=e.position)}P(e,"unexpected end of the stream within a double quoted scalar")}(e,y)?M=!0:function(e){var t,n,i;if(42!==(i=e.input.charCodeAt(e.position)))return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!S(i)&&!k(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&P(e,"name of an alias node must contain at least one character"),n=e.input.slice(t,e.position),u.call(e.anchorMap,n)||P(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],X(e,!0,-1),!0}(e)?(M=!0,null===e.tag&&null===e.anchor||P(e,"alias node should not have any properties")):function(e,t,n){var i,a,r,s,o,u,l,c,h=e.kind,p=e.result;if(S(c=e.input.charCodeAt(e.position))||k(c)||35===c||38===c||42===c||33===c||124===c||62===c||39===c||34===c||37===c||64===c||96===c)return!1;if((63===c||45===c)&&(S(i=e.input.charCodeAt(e.position+1))||n&&k(i)))return!1;for(e.kind="scalar",e.result="",a=r=e.position,s=!1;0!==c;){if(58===c){if(S(i=e.input.charCodeAt(e.position+1))||n&&k(i))break}else if(35===c){if(S(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&J(e)||n&&k(c))break;if(C(c)){if(o=e.line,u=e.lineStart,l=e.lineIndent,X(e,!1,-1),e.lineIndent>=t){s=!0,c=e.input.charCodeAt(e.position);continue}e.position=r,e.line=o,e.lineStart=u,e.lineIndent=l;break}}s&&(j(e,a,r,!1),z(e,e.line-o),a=r=e.position,s=!1),A(c)||(r=e.position+1),c=e.input.charCodeAt(++e.position)}return j(e,a,r,!1),!!e.result||(e.kind=h,e.result=p,!1)}(e,y,l===n)&&(M=!0,null===e.tag&&(e.tag="?")),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===b&&(M=x&&K(e,v))),null!==e.tag&&"!"!==e.tag)if("?"===e.tag){for(null!==e.result&&"scalar"!==e.kind&&P(e,'unacceptable node kind for ! tag; it should be "scalar", not "'+e.kind+'"'),g=0,E=e.implicitTypes.length;g tag; it should be "'+D.kind+'", not "'+e.kind+'"'),D.resolve(e.result)?(e.result=D.construct(e.result),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):P(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")):P(e,"unknown tag !<"+e.tag+">");return null!==e.listener&&e.listener("close",e),null!==e.tag||null!==e.anchor||M}function W(e){var t,n,i,a,r=e.position,s=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap={},e.anchorMap={};0!==(a=e.input.charCodeAt(e.position))&&(X(e,!0,-1),a=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==a));){for(s=!0,a=e.input.charCodeAt(++e.position),t=e.position;0!==a&&!S(a);)a=e.input.charCodeAt(++e.position);for(i=[],(n=e.input.slice(t,e.position)).length<1&&P(e,"directive name must not be less than one character in length");0!==a;){for(;A(a);)a=e.input.charCodeAt(++e.position);if(35===a){do{a=e.input.charCodeAt(++e.position)}while(0!==a&&!C(a));break}if(C(a))break;for(t=e.position;0!==a&&!S(a);)a=e.input.charCodeAt(++e.position);i.push(e.input.slice(t,e.position))}0!==a&&_(e),u.call(O,n)?O[n](e,n,i):L(e,'unknown document directive "'+n+'"')}X(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,X(e,!0,-1)):s&&P(e,"directives end mark is expected"),V(e,e.lineIndent-1,p,!1,!0),X(e,!0,-1),e.checkLineBreaks&&g.test(e.input.slice(r,e.position))&&L(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&J(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,X(e,!0,-1)):e.position0&&-1==="\0\r\n…\u2028\u2029".indexOf(this.buffer.charAt(a-1));)if(a-=1,this.position-a>t/2-1){n=" ... ",a+=5;break}for(r="",s=this.position;st/2-1){r=" ... ",s-=5;break}return o=this.buffer.slice(a,s),i.repeat(" ",e)+n+o+r+"\n"+i.repeat(" ",e+this.position-a+n.length)+"^"},a.prototype.toString=function(e){var t,n="";return this.name&&(n+='in "'+this.name+'" '),n+="at line "+(this.line+1)+", column "+(this.column+1),e||(t=this.getSnippet())&&(n+=":\n"+t),n},e.exports=a},1007:function(e,t,n){"use strict";var i=n(90);e.exports=new i("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return null!==e?e:""}})},1008:function(e,t,n){"use strict";var i=n(90);e.exports=new i("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return null!==e?e:[]}})},1009:function(e,t,n){"use strict";var i=n(90);e.exports=new i("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return null!==e?e:{}}})},1010:function(e,t,n){"use strict";var i=n(90);e.exports=new i("tag:yaml.org,2002:null",{kind:"scalar",resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&"~"===e||4===t&&("null"===e||"Null"===e||"NULL"===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})},1011:function(e,t,n){"use strict";var i=n(90);e.exports=new i("tag:yaml.org,2002:bool",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&("true"===e||"True"===e||"TRUE"===e)||5===t&&("false"===e||"False"===e||"FALSE"===e)},construct:function(e){return"true"===e||"True"===e||"TRUE"===e},predicate:function(e){return"[object Boolean]"===Object.prototype.toString.call(e)},represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"})},1012:function(e,t,n){"use strict";var i=n(136),a=n(90);function r(e){return 48<=e&&e<=55}function s(e){return 48<=e&&e<=57}e.exports=new a("tag:yaml.org,2002:int",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,i=e.length,a=0,o=!1;if(!i)return!1;if("-"!==(t=e[a])&&"+"!==t||(t=e[++a]),"0"===t){if(a+1===i)return!0;if("b"===(t=e[++a])){for(a++;a=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0"+e.toString(8):"-0"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})},1013:function(e,t,n){"use strict";var i=n(136),a=n(90),r=new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),s=/^[-+]?[0-9]+e/;e.exports=new a("tag:yaml.org,2002:float",{kind:"scalar",resolve:function(e){return null!==e&&!(!r.test(e)||"_"===e[e.length-1])},construct:function(e){var t,n,i,a;return n="-"===(t=e.replace(/_/g,"").toLowerCase())[0]?-1:1,a=[],"+-".indexOf(t[0])>=0&&(t=t.slice(1)),".inf"===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===t?NaN:t.indexOf(":")>=0?(t.split(":").forEach((function(e){a.unshift(parseFloat(e,10))})),t=0,i=1,a.forEach((function(e){t+=e*i,i*=60})),n*t):n*parseFloat(t,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&(e%1!=0||i.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(i.isNegativeZero(e))return"-0.0";return n=e.toString(10),s.test(n)?n.replace("e",".e"):n},defaultStyle:"lowercase"})},1014:function(e,t,n){"use strict";var i=n(90),a=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),r=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");e.exports=new i("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:function(e){return null!==e&&(null!==a.exec(e)||null!==r.exec(e))},construct:function(e){var t,n,i,s,o,u,l,c,h=0,p=null;if(null===(t=a.exec(e))&&(t=r.exec(e)),null===t)throw new Error("Date resolve error");if(n=+t[1],i=+t[2]-1,s=+t[3],!t[4])return new Date(Date.UTC(n,i,s));if(o=+t[4],u=+t[5],l=+t[6],t[7]){for(h=t[7].slice(0,3);h.length<3;)h+="0";h=+h}return t[9]&&(p=6e4*(60*+t[10]+ +(t[11]||0)),"-"===t[9]&&(p=-p)),c=new Date(Date.UTC(n,i,s,o,u,l,h)),p&&c.setTime(c.getTime()-p),c},instanceOf:Date,represent:function(e){return e.toISOString()}})},1015:function(e,t,n){"use strict";var i=n(90);e.exports=new i("tag:yaml.org,2002:merge",{kind:"scalar",resolve:function(e){return"<<"===e||null===e}})},1016:function(e,t,n){"use strict";var i;try{i=n(1017).Buffer}catch(e){}var a=n(90),r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r";e.exports=new a("tag:yaml.org,2002:binary",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,i=0,a=e.length,s=r;for(n=0;n64)){if(t<0)return!1;i+=6}return i%8==0},construct:function(e){var t,n,a=e.replace(/[\r\n=]/g,""),s=a.length,o=r,u=0,l=[];for(t=0;t>16&255),l.push(u>>8&255),l.push(255&u)),u=u<<6|o.indexOf(a.charAt(t));return 0==(n=s%4*6)?(l.push(u>>16&255),l.push(u>>8&255),l.push(255&u)):18===n?(l.push(u>>10&255),l.push(u>>2&255)):12===n&&l.push(u>>4&255),i?i.from?i.from(l):new i(l):l},predicate:function(e){return i&&i.isBuffer(e)},represent:function(e){var t,n,i="",a=0,s=e.length,o=r;for(t=0;t>18&63],i+=o[a>>12&63],i+=o[a>>6&63],i+=o[63&a]),a=(a<<8)+e[t];return 0==(n=s%3)?(i+=o[a>>18&63],i+=o[a>>12&63],i+=o[a>>6&63],i+=o[63&a]):2===n?(i+=o[a>>10&63],i+=o[a>>4&63],i+=o[a<<2&63],i+=o[64]):1===n&&(i+=o[a>>2&63],i+=o[a<<4&63],i+=o[64],i+=o[64]),i}})},1017:function(e,t,n){e.exports=n(28)(2943)},1018:function(e,t,n){"use strict";var i=n(90),a=Object.prototype.hasOwnProperty,r=Object.prototype.toString;e.exports=new i("tag:yaml.org,2002:omap",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,i,s,o,u=[],l=e;for(t=0,n=l.length;t3)return!1;if("/"!==t[t.length-i.length-1])return!1}return!0},construct:function(e){var t=e,n=/\/([gim]*)$/.exec(e),i="";return"/"===t[0]&&(n&&(i=n[1]),t=t.slice(1,t.length-i.length-1)),new RegExp(t,i)},predicate:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},represent:function(e){var t="/"+e.source+"/";return e.global&&(t+="g"),e.multiline&&(t+="m"),e.ignoreCase&&(t+="i"),t}})},1023:function(e,t,n){"use strict";var i;try{i=n(1024)}catch(e){"undefined"!=typeof window&&(i=window.esprima)}var a=n(90);e.exports=new a("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:function(e){if(null===e)return!1;try{var t="("+e+")",n=i.parse(t,{range:!0});return"Program"===n.type&&1===n.body.length&&"ExpressionStatement"===n.body[0].type&&("ArrowFunctionExpression"===n.body[0].expression.type||"FunctionExpression"===n.body[0].expression.type)}catch(e){return!1}},construct:function(e){var t,n="("+e+")",a=i.parse(n,{range:!0}),r=[];if("Program"!==a.type||1!==a.body.length||"ExpressionStatement"!==a.body[0].type||"ArrowFunctionExpression"!==a.body[0].expression.type&&"FunctionExpression"!==a.body[0].expression.type)throw new Error("Failed to resolve function");return a.body[0].expression.params.forEach((function(e){r.push(e.name)})),t=a.body[0].expression.body.range,"BlockStatement"===a.body[0].expression.body.type?new Function(r,n.slice(t[0]+1,t[1]-1)):new Function(r,"return "+n.slice(t[0],t[1]))},predicate:function(e){return"[object Function]"===Object.prototype.toString.call(e)},represent:function(e){return e.toString()}})},1024:function(e,t,n){var i;i=function(){return function(e){var t={};function n(i){if(t[i])return t[i].exports;var a=t[i]={exports:{},id:i,loaded:!1};return e[i].call(a.exports,a,a.exports,n),a.loaded=!0,a.exports}return n.m=e,n.c=t,n.p="",n(0)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(1),a=n(3),r=n(8),s=n(15);function o(e,t,n){var s=null,o=function(e,t){n&&n(e,t),s&&s.visit(e,t)},u="function"==typeof n?o:null,l=!1;if(t){l="boolean"==typeof t.comment&&t.comment;var c="boolean"==typeof t.attachComment&&t.attachComment;(l||c)&&((s=new i.CommentHandler).attach=c,t.comment=!0,u=o)}var h,p=!1;t&&"string"==typeof t.sourceType&&(p="module"===t.sourceType),h=t&&"boolean"==typeof t.jsx&&t.jsx?new a.JSXParser(e,t,u):new r.Parser(e,t,u);var d=p?h.parseModule():h.parseScript();return l&&s&&(d.comments=s.comments),h.config.tokens&&(d.tokens=h.tokens),h.config.tolerant&&(d.errors=h.errorHandler.errors),d}t.parse=o,t.parseModule=function(e,t,n){var i=t||{};return i.sourceType="module",o(e,i,n)},t.parseScript=function(e,t,n){var i=t||{};return i.sourceType="script",o(e,i,n)},t.tokenize=function(e,t,n){var i,a=new s.Tokenizer(e,t);i=[];try{for(;;){var r=a.getNextToken();if(!r)break;n&&(r=n(r)),i.push(r)}}catch(e){a.errorHandler.tolerate(e)}return a.errorHandler.tolerant&&(i.errors=a.errors()),i};var u=n(2);t.Syntax=u.Syntax,t.version="4.0.1"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(2),a=function(){function e(){this.attach=!1,this.comments=[],this.stack=[],this.leading=[],this.trailing=[]}return e.prototype.insertInnerComments=function(e,t){if(e.type===i.Syntax.BlockStatement&&0===e.body.length){for(var n=[],a=this.leading.length-1;a>=0;--a){var r=this.leading[a];t.end.offset>=r.start&&(n.unshift(r.comment),this.leading.splice(a,1),this.trailing.splice(a,1))}n.length&&(e.innerComments=n)}},e.prototype.findTrailingComments=function(e){var t=[];if(this.trailing.length>0){for(var n=this.trailing.length-1;n>=0;--n){var i=this.trailing[n];i.start>=e.end.offset&&t.unshift(i.comment)}return this.trailing.length=0,t}var a=this.stack[this.stack.length-1];if(a&&a.node.trailingComments){var r=a.node.trailingComments[0];r&&r.range[0]>=e.end.offset&&(t=a.node.trailingComments,delete a.node.trailingComments)}return t},e.prototype.findLeadingComments=function(e){for(var t,n=[];this.stack.length>0&&(r=this.stack[this.stack.length-1])&&r.start>=e.start.offset;)t=r.node,this.stack.pop();if(t){for(var i=(t.leadingComments?t.leadingComments.length:0)-1;i>=0;--i){var a=t.leadingComments[i];a.range[1]<=e.start.offset&&(n.unshift(a),t.leadingComments.splice(i,1))}return t.leadingComments&&0===t.leadingComments.length&&delete t.leadingComments,n}for(i=this.leading.length-1;i>=0;--i){var r;(r=this.leading[i]).start<=e.start.offset&&(n.unshift(r.comment),this.leading.splice(i,1))}return n},e.prototype.visitNode=function(e,t){if(!(e.type===i.Syntax.Program&&e.body.length>0)){this.insertInnerComments(e,t);var n=this.findTrailingComments(t),a=this.findLeadingComments(t);a.length>0&&(e.leadingComments=a),n.length>0&&(e.trailingComments=n),this.stack.push({node:e,start:t.start.offset})}},e.prototype.visitComment=function(e,t){var n="L"===e.type[0]?"Line":"Block",i={type:n,value:e.value};if(e.range&&(i.range=e.range),e.loc&&(i.loc=e.loc),this.comments.push(i),this.attach){var a={comment:{type:n,value:e.value,range:[t.start.offset,t.end.offset]},start:t.start.offset};e.loc&&(a.comment.loc=e.loc),e.type=n,this.leading.push(a),this.trailing.push(a)}},e.prototype.visit=function(e,t){"LineComment"===e.type||"BlockComment"===e.type?this.visitComment(e,t):this.attach&&this.visitNode(e,t)},e}();t.CommentHandler=a},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Syntax={AssignmentExpression:"AssignmentExpression",AssignmentPattern:"AssignmentPattern",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",DebuggerStatement:"DebuggerStatement",EmptyStatement:"EmptyStatement",ExportAllDeclaration:"ExportAllDeclaration",ExportDefaultDeclaration:"ExportDefaultDeclaration",ExportNamedDeclaration:"ExportNamedDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForOfStatement:"ForOfStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MetaProperty:"MetaProperty",MethodDefinition:"MethodDefinition",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",RestElement:"RestElement",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",Super:"Super",SwitchCase:"SwitchCase",SwitchStatement:"SwitchStatement",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"}},function(e,t,n){"use strict";var i,a=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var r=n(4),s=n(5),o=n(6),u=n(7),l=n(8),c=n(13),h=n(14);function p(e){var t;switch(e.type){case o.JSXSyntax.JSXIdentifier:t=e.name;break;case o.JSXSyntax.JSXNamespacedName:var n=e;t=p(n.namespace)+":"+p(n.name);break;case o.JSXSyntax.JSXMemberExpression:var i=e;t=p(i.object)+"."+p(i.property)}return t}c.TokenName[100]="JSXIdentifier",c.TokenName[101]="JSXText";var d=function(e){function t(t,n,i){return e.call(this,t,n,i)||this}return a(t,e),t.prototype.parsePrimaryExpression=function(){return this.match("<")?this.parseJSXRoot():e.prototype.parsePrimaryExpression.call(this)},t.prototype.startJSX=function(){this.scanner.index=this.startMarker.index,this.scanner.lineNumber=this.startMarker.line,this.scanner.lineStart=this.startMarker.index-this.startMarker.column},t.prototype.finishJSX=function(){this.nextToken()},t.prototype.reenterJSX=function(){this.startJSX(),this.expectJSX("}"),this.config.tokens&&this.tokens.pop()},t.prototype.createJSXNode=function(){return this.collectComments(),{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},t.prototype.createJSXChildNode=function(){return{index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}},t.prototype.scanXHTMLEntity=function(e){for(var t="&",n=!0,i=!1,a=!1,s=!1;!this.scanner.eof()&&n&&!i;){var o=this.scanner.source[this.scanner.index];if(o===e)break;if(i=";"===o,t+=o,++this.scanner.index,!i)switch(t.length){case 2:a="#"===o;break;case 3:a&&(n=(s="x"===o)||r.Character.isDecimalDigit(o.charCodeAt(0)),a=a&&!s);break;default:n=(n=n&&!(a&&!r.Character.isDecimalDigit(o.charCodeAt(0))))&&!(s&&!r.Character.isHexDigit(o.charCodeAt(0)))}}if(n&&i&&t.length>2){var u=t.substr(1,t.length-2);a&&u.length>1?t=String.fromCharCode(parseInt(u.substr(1),10)):s&&u.length>2?t=String.fromCharCode(parseInt("0"+u.substr(1),16)):a||s||!h.XHTMLEntities[u]||(t=h.XHTMLEntities[u])}return t},t.prototype.lexJSX=function(){var e=this.scanner.source.charCodeAt(this.scanner.index);if(60===e||62===e||47===e||58===e||61===e||123===e||125===e)return{type:7,value:o=this.scanner.source[this.scanner.index++],lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index-1,end:this.scanner.index};if(34===e||39===e){for(var t=this.scanner.index,n=this.scanner.source[this.scanner.index++],i="";!this.scanner.eof()&&(u=this.scanner.source[this.scanner.index++])!==n;)i+="&"===u?this.scanXHTMLEntity(n):u;return{type:8,value:i,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}if(46===e){var a=this.scanner.source.charCodeAt(this.scanner.index+1),s=this.scanner.source.charCodeAt(this.scanner.index+2),o=46===a&&46===s?"...":".";return t=this.scanner.index,this.scanner.index+=o.length,{type:7,value:o,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}if(96===e)return{type:10,value:"",lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:this.scanner.index,end:this.scanner.index};if(r.Character.isIdentifierStart(e)&&92!==e){for(t=this.scanner.index,++this.scanner.index;!this.scanner.eof();){var u=this.scanner.source.charCodeAt(this.scanner.index);if(r.Character.isIdentifierPart(u)&&92!==u)++this.scanner.index;else{if(45!==u)break;++this.scanner.index}}return{type:100,value:this.scanner.source.slice(t,this.scanner.index),lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:t,end:this.scanner.index}}return this.scanner.lex()},t.prototype.nextJSXToken=function(){this.collectComments(),this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;var e=this.lexJSX();return this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.config.tokens&&this.tokens.push(this.convertToken(e)),e},t.prototype.nextJSXText=function(){this.startMarker.index=this.scanner.index,this.startMarker.line=this.scanner.lineNumber,this.startMarker.column=this.scanner.index-this.scanner.lineStart;for(var e=this.scanner.index,t="";!this.scanner.eof();){var n=this.scanner.source[this.scanner.index];if("{"===n||"<"===n)break;++this.scanner.index,t+=n,r.Character.isLineTerminator(n.charCodeAt(0))&&(++this.scanner.lineNumber,"\r"===n&&"\n"===this.scanner.source[this.scanner.index]&&++this.scanner.index,this.scanner.lineStart=this.scanner.index)}this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart;var i={type:101,value:t,lineNumber:this.scanner.lineNumber,lineStart:this.scanner.lineStart,start:e,end:this.scanner.index};return t.length>0&&this.config.tokens&&this.tokens.push(this.convertToken(i)),i},t.prototype.peekJSXToken=function(){var e=this.scanner.saveState();this.scanner.scanComments();var t=this.lexJSX();return this.scanner.restoreState(e),t},t.prototype.expectJSX=function(e){var t=this.nextJSXToken();7===t.type&&t.value===e||this.throwUnexpectedToken(t)},t.prototype.matchJSX=function(e){var t=this.peekJSXToken();return 7===t.type&&t.value===e},t.prototype.parseJSXIdentifier=function(){var e=this.createJSXNode(),t=this.nextJSXToken();return 100!==t.type&&this.throwUnexpectedToken(t),this.finalize(e,new s.JSXIdentifier(t.value))},t.prototype.parseJSXElementName=function(){var e=this.createJSXNode(),t=this.parseJSXIdentifier();if(this.matchJSX(":")){var n=t;this.expectJSX(":");var i=this.parseJSXIdentifier();t=this.finalize(e,new s.JSXNamespacedName(n,i))}else if(this.matchJSX("."))for(;this.matchJSX(".");){var a=t;this.expectJSX(".");var r=this.parseJSXIdentifier();t=this.finalize(e,new s.JSXMemberExpression(a,r))}return t},t.prototype.parseJSXAttributeName=function(){var e,t=this.createJSXNode(),n=this.parseJSXIdentifier();if(this.matchJSX(":")){var i=n;this.expectJSX(":");var a=this.parseJSXIdentifier();e=this.finalize(t,new s.JSXNamespacedName(i,a))}else e=n;return e},t.prototype.parseJSXStringLiteralAttribute=function(){var e=this.createJSXNode(),t=this.nextJSXToken();8!==t.type&&this.throwUnexpectedToken(t);var n=this.getTokenRaw(t);return this.finalize(e,new u.Literal(t.value,n))},t.prototype.parseJSXExpressionAttribute=function(){var e=this.createJSXNode();this.expectJSX("{"),this.finishJSX(),this.match("}")&&this.tolerateError("JSX attributes must only be assigned a non-empty expression");var t=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(e,new s.JSXExpressionContainer(t))},t.prototype.parseJSXAttributeValue=function(){return this.matchJSX("{")?this.parseJSXExpressionAttribute():this.matchJSX("<")?this.parseJSXElement():this.parseJSXStringLiteralAttribute()},t.prototype.parseJSXNameValueAttribute=function(){var e=this.createJSXNode(),t=this.parseJSXAttributeName(),n=null;return this.matchJSX("=")&&(this.expectJSX("="),n=this.parseJSXAttributeValue()),this.finalize(e,new s.JSXAttribute(t,n))},t.prototype.parseJSXSpreadAttribute=function(){var e=this.createJSXNode();this.expectJSX("{"),this.expectJSX("..."),this.finishJSX();var t=this.parseAssignmentExpression();return this.reenterJSX(),this.finalize(e,new s.JSXSpreadAttribute(t))},t.prototype.parseJSXAttributes=function(){for(var e=[];!this.matchJSX("/")&&!this.matchJSX(">");){var t=this.matchJSX("{")?this.parseJSXSpreadAttribute():this.parseJSXNameValueAttribute();e.push(t)}return e},t.prototype.parseJSXOpeningElement=function(){var e=this.createJSXNode();this.expectJSX("<");var t=this.parseJSXElementName(),n=this.parseJSXAttributes(),i=this.matchJSX("/");return i&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(e,new s.JSXOpeningElement(t,i,n))},t.prototype.parseJSXBoundaryElement=function(){var e=this.createJSXNode();if(this.expectJSX("<"),this.matchJSX("/")){this.expectJSX("/");var t=this.parseJSXElementName();return this.expectJSX(">"),this.finalize(e,new s.JSXClosingElement(t))}var n=this.parseJSXElementName(),i=this.parseJSXAttributes(),a=this.matchJSX("/");return a&&this.expectJSX("/"),this.expectJSX(">"),this.finalize(e,new s.JSXOpeningElement(n,a,i))},t.prototype.parseJSXEmptyExpression=function(){var e=this.createJSXChildNode();return this.collectComments(),this.lastMarker.index=this.scanner.index,this.lastMarker.line=this.scanner.lineNumber,this.lastMarker.column=this.scanner.index-this.scanner.lineStart,this.finalize(e,new s.JSXEmptyExpression)},t.prototype.parseJSXExpressionContainer=function(){var e,t=this.createJSXNode();return this.expectJSX("{"),this.matchJSX("}")?(e=this.parseJSXEmptyExpression(),this.expectJSX("}")):(this.finishJSX(),e=this.parseAssignmentExpression(),this.reenterJSX()),this.finalize(t,new s.JSXExpressionContainer(e))},t.prototype.parseJSXChildren=function(){for(var e=[];!this.scanner.eof();){var t=this.createJSXChildNode(),n=this.nextJSXText();if(n.start0))break;r=this.finalize(e.node,new s.JSXElement(e.opening,e.children,e.closing)),(e=t[t.length-1]).children.push(r),t.pop()}}return e},t.prototype.parseJSXElement=function(){var e=this.createJSXNode(),t=this.parseJSXOpeningElement(),n=[],i=null;if(!t.selfClosing){var a=this.parseComplexJSXElement({node:e,opening:t,closing:i,children:n});n=a.children,i=a.closing}return this.finalize(e,new s.JSXElement(t,n,i))},t.prototype.parseJSXRoot=function(){this.config.tokens&&this.tokens.pop(),this.startJSX();var e=this.parseJSXElement();return this.finishJSX(),e},t.prototype.isStartOfExpression=function(){return e.prototype.isStartOfExpression.call(this)||this.match("<")},t}(l.Parser);t.JSXParser=d},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n={NonAsciiIdentifierStart:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]/,NonAsciiIdentifierPart:/[\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u08A0-\u08B4\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D01-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1CD0-\u1CD2\u1CD4-\u1CF6\u1CF8\u1CF9\u1D00-\u1DF5\u1DFC-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C4\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF30-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDEC0-\uDEF8]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F]|\uD82C[\uDC00\uDC01]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/};t.Character={fromCodePoint:function(e){return e<65536?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10))+String.fromCharCode(56320+(e-65536&1023))},isWhiteSpace:function(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&[5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0},isLineTerminator:function(e){return 10===e||13===e||8232===e||8233===e},isIdentifierStart:function(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||92===e||e>=128&&n.NonAsciiIdentifierStart.test(t.Character.fromCodePoint(e))},isIdentifierPart:function(e){return 36===e||95===e||e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||92===e||e>=128&&n.NonAsciiIdentifierPart.test(t.Character.fromCodePoint(e))},isDecimalDigit:function(e){return e>=48&&e<=57},isHexDigit:function(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102},isOctalDigit:function(e){return e>=48&&e<=55}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(6);t.JSXClosingElement=function(e){this.type=i.JSXSyntax.JSXClosingElement,this.name=e};t.JSXElement=function(e,t,n){this.type=i.JSXSyntax.JSXElement,this.openingElement=e,this.children=t,this.closingElement=n};t.JSXEmptyExpression=function(){this.type=i.JSXSyntax.JSXEmptyExpression};t.JSXExpressionContainer=function(e){this.type=i.JSXSyntax.JSXExpressionContainer,this.expression=e};t.JSXIdentifier=function(e){this.type=i.JSXSyntax.JSXIdentifier,this.name=e};t.JSXMemberExpression=function(e,t){this.type=i.JSXSyntax.JSXMemberExpression,this.object=e,this.property=t};t.JSXAttribute=function(e,t){this.type=i.JSXSyntax.JSXAttribute,this.name=e,this.value=t};t.JSXNamespacedName=function(e,t){this.type=i.JSXSyntax.JSXNamespacedName,this.namespace=e,this.name=t};t.JSXOpeningElement=function(e,t,n){this.type=i.JSXSyntax.JSXOpeningElement,this.name=e,this.selfClosing=t,this.attributes=n};t.JSXSpreadAttribute=function(e){this.type=i.JSXSyntax.JSXSpreadAttribute,this.argument=e};t.JSXText=function(e,t){this.type=i.JSXSyntax.JSXText,this.value=e,this.raw=t}},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JSXSyntax={JSXAttribute:"JSXAttribute",JSXClosingElement:"JSXClosingElement",JSXElement:"JSXElement",JSXEmptyExpression:"JSXEmptyExpression",JSXExpressionContainer:"JSXExpressionContainer",JSXIdentifier:"JSXIdentifier",JSXMemberExpression:"JSXMemberExpression",JSXNamespacedName:"JSXNamespacedName",JSXOpeningElement:"JSXOpeningElement",JSXSpreadAttribute:"JSXSpreadAttribute",JSXText:"JSXText"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(2);t.ArrayExpression=function(e){this.type=i.Syntax.ArrayExpression,this.elements=e};t.ArrayPattern=function(e){this.type=i.Syntax.ArrayPattern,this.elements=e};t.ArrowFunctionExpression=function(e,t,n){this.type=i.Syntax.ArrowFunctionExpression,this.id=null,this.params=e,this.body=t,this.generator=!1,this.expression=n,this.async=!1};t.AssignmentExpression=function(e,t,n){this.type=i.Syntax.AssignmentExpression,this.operator=e,this.left=t,this.right=n};t.AssignmentPattern=function(e,t){this.type=i.Syntax.AssignmentPattern,this.left=e,this.right=t};t.AsyncArrowFunctionExpression=function(e,t,n){this.type=i.Syntax.ArrowFunctionExpression,this.id=null,this.params=e,this.body=t,this.generator=!1,this.expression=n,this.async=!0};t.AsyncFunctionDeclaration=function(e,t,n){this.type=i.Syntax.FunctionDeclaration,this.id=e,this.params=t,this.body=n,this.generator=!1,this.expression=!1,this.async=!0};t.AsyncFunctionExpression=function(e,t,n){this.type=i.Syntax.FunctionExpression,this.id=e,this.params=t,this.body=n,this.generator=!1,this.expression=!1,this.async=!0};t.AwaitExpression=function(e){this.type=i.Syntax.AwaitExpression,this.argument=e};t.BinaryExpression=function(e,t,n){var a="||"===e||"&&"===e;this.type=a?i.Syntax.LogicalExpression:i.Syntax.BinaryExpression,this.operator=e,this.left=t,this.right=n};t.BlockStatement=function(e){this.type=i.Syntax.BlockStatement,this.body=e};t.BreakStatement=function(e){this.type=i.Syntax.BreakStatement,this.label=e};t.CallExpression=function(e,t){this.type=i.Syntax.CallExpression,this.callee=e,this.arguments=t};t.CatchClause=function(e,t){this.type=i.Syntax.CatchClause,this.param=e,this.body=t};t.ClassBody=function(e){this.type=i.Syntax.ClassBody,this.body=e};t.ClassDeclaration=function(e,t,n){this.type=i.Syntax.ClassDeclaration,this.id=e,this.superClass=t,this.body=n};t.ClassExpression=function(e,t,n){this.type=i.Syntax.ClassExpression,this.id=e,this.superClass=t,this.body=n};t.ComputedMemberExpression=function(e,t){this.type=i.Syntax.MemberExpression,this.computed=!0,this.object=e,this.property=t};t.ConditionalExpression=function(e,t,n){this.type=i.Syntax.ConditionalExpression,this.test=e,this.consequent=t,this.alternate=n};t.ContinueStatement=function(e){this.type=i.Syntax.ContinueStatement,this.label=e};t.DebuggerStatement=function(){this.type=i.Syntax.DebuggerStatement};t.Directive=function(e,t){this.type=i.Syntax.ExpressionStatement,this.expression=e,this.directive=t};t.DoWhileStatement=function(e,t){this.type=i.Syntax.DoWhileStatement,this.body=e,this.test=t};t.EmptyStatement=function(){this.type=i.Syntax.EmptyStatement};t.ExportAllDeclaration=function(e){this.type=i.Syntax.ExportAllDeclaration,this.source=e};t.ExportDefaultDeclaration=function(e){this.type=i.Syntax.ExportDefaultDeclaration,this.declaration=e};t.ExportNamedDeclaration=function(e,t,n){this.type=i.Syntax.ExportNamedDeclaration,this.declaration=e,this.specifiers=t,this.source=n};t.ExportSpecifier=function(e,t){this.type=i.Syntax.ExportSpecifier,this.exported=t,this.local=e};t.ExpressionStatement=function(e){this.type=i.Syntax.ExpressionStatement,this.expression=e};t.ForInStatement=function(e,t,n){this.type=i.Syntax.ForInStatement,this.left=e,this.right=t,this.body=n,this.each=!1};t.ForOfStatement=function(e,t,n){this.type=i.Syntax.ForOfStatement,this.left=e,this.right=t,this.body=n};t.ForStatement=function(e,t,n,a){this.type=i.Syntax.ForStatement,this.init=e,this.test=t,this.update=n,this.body=a};t.FunctionDeclaration=function(e,t,n,a){this.type=i.Syntax.FunctionDeclaration,this.id=e,this.params=t,this.body=n,this.generator=a,this.expression=!1,this.async=!1};t.FunctionExpression=function(e,t,n,a){this.type=i.Syntax.FunctionExpression,this.id=e,this.params=t,this.body=n,this.generator=a,this.expression=!1,this.async=!1};t.Identifier=function(e){this.type=i.Syntax.Identifier,this.name=e};t.IfStatement=function(e,t,n){this.type=i.Syntax.IfStatement,this.test=e,this.consequent=t,this.alternate=n};t.ImportDeclaration=function(e,t){this.type=i.Syntax.ImportDeclaration,this.specifiers=e,this.source=t};t.ImportDefaultSpecifier=function(e){this.type=i.Syntax.ImportDefaultSpecifier,this.local=e};t.ImportNamespaceSpecifier=function(e){this.type=i.Syntax.ImportNamespaceSpecifier,this.local=e};t.ImportSpecifier=function(e,t){this.type=i.Syntax.ImportSpecifier,this.local=e,this.imported=t};t.LabeledStatement=function(e,t){this.type=i.Syntax.LabeledStatement,this.label=e,this.body=t};t.Literal=function(e,t){this.type=i.Syntax.Literal,this.value=e,this.raw=t};t.MetaProperty=function(e,t){this.type=i.Syntax.MetaProperty,this.meta=e,this.property=t};t.MethodDefinition=function(e,t,n,a,r){this.type=i.Syntax.MethodDefinition,this.key=e,this.computed=t,this.value=n,this.kind=a,this.static=r};t.Module=function(e){this.type=i.Syntax.Program,this.body=e,this.sourceType="module"};t.NewExpression=function(e,t){this.type=i.Syntax.NewExpression,this.callee=e,this.arguments=t};t.ObjectExpression=function(e){this.type=i.Syntax.ObjectExpression,this.properties=e};t.ObjectPattern=function(e){this.type=i.Syntax.ObjectPattern,this.properties=e};t.Property=function(e,t,n,a,r,s){this.type=i.Syntax.Property,this.key=t,this.computed=n,this.value=a,this.kind=e,this.method=r,this.shorthand=s};t.RegexLiteral=function(e,t,n,a){this.type=i.Syntax.Literal,this.value=e,this.raw=t,this.regex={pattern:n,flags:a}};t.RestElement=function(e){this.type=i.Syntax.RestElement,this.argument=e};t.ReturnStatement=function(e){this.type=i.Syntax.ReturnStatement,this.argument=e};t.Script=function(e){this.type=i.Syntax.Program,this.body=e,this.sourceType="script"};t.SequenceExpression=function(e){this.type=i.Syntax.SequenceExpression,this.expressions=e};t.SpreadElement=function(e){this.type=i.Syntax.SpreadElement,this.argument=e};t.StaticMemberExpression=function(e,t){this.type=i.Syntax.MemberExpression,this.computed=!1,this.object=e,this.property=t};t.Super=function(){this.type=i.Syntax.Super};t.SwitchCase=function(e,t){this.type=i.Syntax.SwitchCase,this.test=e,this.consequent=t};t.SwitchStatement=function(e,t){this.type=i.Syntax.SwitchStatement,this.discriminant=e,this.cases=t};t.TaggedTemplateExpression=function(e,t){this.type=i.Syntax.TaggedTemplateExpression,this.tag=e,this.quasi=t};t.TemplateElement=function(e,t){this.type=i.Syntax.TemplateElement,this.value=e,this.tail=t};t.TemplateLiteral=function(e,t){this.type=i.Syntax.TemplateLiteral,this.quasis=e,this.expressions=t};t.ThisExpression=function(){this.type=i.Syntax.ThisExpression};t.ThrowStatement=function(e){this.type=i.Syntax.ThrowStatement,this.argument=e};t.TryStatement=function(e,t,n){this.type=i.Syntax.TryStatement,this.block=e,this.handler=t,this.finalizer=n};t.UnaryExpression=function(e,t){this.type=i.Syntax.UnaryExpression,this.operator=e,this.argument=t,this.prefix=!0};t.UpdateExpression=function(e,t,n){this.type=i.Syntax.UpdateExpression,this.operator=e,this.argument=t,this.prefix=n};t.VariableDeclaration=function(e,t){this.type=i.Syntax.VariableDeclaration,this.declarations=e,this.kind=t};t.VariableDeclarator=function(e,t){this.type=i.Syntax.VariableDeclarator,this.id=e,this.init=t};t.WhileStatement=function(e,t){this.type=i.Syntax.WhileStatement,this.test=e,this.body=t};t.WithStatement=function(e,t){this.type=i.Syntax.WithStatement,this.object=e,this.body=t};t.YieldExpression=function(e,t){this.type=i.Syntax.YieldExpression,this.argument=e,this.delegate=t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(9),a=n(10),r=n(11),s=n(7),o=n(12),u=n(2),l=n(13),c="ArrowParameterPlaceHolder",h=function(){function e(e,t,n){void 0===t&&(t={}),this.config={range:"boolean"==typeof t.range&&t.range,loc:"boolean"==typeof t.loc&&t.loc,source:null,tokens:"boolean"==typeof t.tokens&&t.tokens,comment:"boolean"==typeof t.comment&&t.comment,tolerant:"boolean"==typeof t.tolerant&&t.tolerant},this.config.loc&&t.source&&null!==t.source&&(this.config.source=String(t.source)),this.delegate=n,this.errorHandler=new a.ErrorHandler,this.errorHandler.tolerant=this.config.tolerant,this.scanner=new o.Scanner(e,this.errorHandler),this.scanner.trackComment=this.config.comment,this.operatorPrecedence={")":0,";":0,",":0,"=":0,"]":0,"||":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":11,"/":11,"%":11},this.lookahead={type:2,value:"",lineNumber:this.scanner.lineNumber,lineStart:0,start:0,end:0},this.hasLineTerminator=!1,this.context={isModule:!1,await:!1,allowIn:!0,allowStrictDirective:!0,allowYield:!0,firstCoverInitializedNameError:null,isAssignmentTarget:!1,isBindingElement:!1,inFunctionBody:!1,inIteration:!1,inSwitch:!1,labelSet:{},strict:!1},this.tokens=[],this.startMarker={index:0,line:this.scanner.lineNumber,column:0},this.lastMarker={index:0,line:this.scanner.lineNumber,column:0},this.nextToken(),this.lastMarker={index:this.scanner.index,line:this.scanner.lineNumber,column:this.scanner.index-this.scanner.lineStart}}return e.prototype.throwError=function(e){for(var t=[],n=1;n0&&this.delegate)for(var t=0;t>="===e||">>>="===e||"&="===e||"^="===e||"|="===e},e.prototype.isolateCoverGrammar=function(e){var t=this.context.isBindingElement,n=this.context.isAssignmentTarget,i=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var a=e.call(this);return null!==this.context.firstCoverInitializedNameError&&this.throwUnexpectedToken(this.context.firstCoverInitializedNameError),this.context.isBindingElement=t,this.context.isAssignmentTarget=n,this.context.firstCoverInitializedNameError=i,a},e.prototype.inheritCoverGrammar=function(e){var t=this.context.isBindingElement,n=this.context.isAssignmentTarget,i=this.context.firstCoverInitializedNameError;this.context.isBindingElement=!0,this.context.isAssignmentTarget=!0,this.context.firstCoverInitializedNameError=null;var a=e.call(this);return this.context.isBindingElement=this.context.isBindingElement&&t,this.context.isAssignmentTarget=this.context.isAssignmentTarget&&n,this.context.firstCoverInitializedNameError=i||this.context.firstCoverInitializedNameError,a},e.prototype.consumeSemicolon=function(){this.match(";")?this.nextToken():this.hasLineTerminator||(2===this.lookahead.type||this.match("}")||this.throwUnexpectedToken(this.lookahead),this.lastMarker.index=this.startMarker.index,this.lastMarker.line=this.startMarker.line,this.lastMarker.column=this.startMarker.column)},e.prototype.parsePrimaryExpression=function(){var e,t,n,i=this.createNode();switch(this.lookahead.type){case 3:(this.context.isModule||this.context.await)&&"await"===this.lookahead.value&&this.tolerateUnexpectedToken(this.lookahead),e=this.matchAsyncFunction()?this.parseFunctionExpression():this.finalize(i,new s.Identifier(this.nextToken().value));break;case 6:case 8:this.context.strict&&this.lookahead.octal&&this.tolerateUnexpectedToken(this.lookahead,r.Messages.StrictOctalLiteral),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new s.Literal(t.value,n));break;case 1:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new s.Literal("true"===t.value,n));break;case 5:this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,t=this.nextToken(),n=this.getTokenRaw(t),e=this.finalize(i,new s.Literal(null,n));break;case 10:e=this.parseTemplateLiteral();break;case 7:switch(this.lookahead.value){case"(":this.context.isBindingElement=!1,e=this.inheritCoverGrammar(this.parseGroupExpression);break;case"[":e=this.inheritCoverGrammar(this.parseArrayInitializer);break;case"{":e=this.inheritCoverGrammar(this.parseObjectInitializer);break;case"/":case"/=":this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.scanner.index=this.startMarker.index,t=this.nextRegexToken(),n=this.getTokenRaw(t),e=this.finalize(i,new s.RegexLiteral(t.regex,n,t.pattern,t.flags));break;default:e=this.throwUnexpectedToken(this.nextToken())}break;case 4:!this.context.strict&&this.context.allowYield&&this.matchKeyword("yield")?e=this.parseIdentifierName():!this.context.strict&&this.matchKeyword("let")?e=this.finalize(i,new s.Identifier(this.nextToken().value)):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.matchKeyword("function")?e=this.parseFunctionExpression():this.matchKeyword("this")?(this.nextToken(),e=this.finalize(i,new s.ThisExpression)):e=this.matchKeyword("class")?this.parseClassExpression():this.throwUnexpectedToken(this.nextToken()));break;default:e=this.throwUnexpectedToken(this.nextToken())}return e},e.prototype.parseSpreadElement=function(){var e=this.createNode();this.expect("...");var t=this.inheritCoverGrammar(this.parseAssignmentExpression);return this.finalize(e,new s.SpreadElement(t))},e.prototype.parseArrayInitializer=function(){var e=this.createNode(),t=[];for(this.expect("[");!this.match("]");)if(this.match(","))this.nextToken(),t.push(null);else if(this.match("...")){var n=this.parseSpreadElement();this.match("]")||(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1,this.expect(",")),t.push(n)}else t.push(this.inheritCoverGrammar(this.parseAssignmentExpression)),this.match("]")||this.expect(",");return this.expect("]"),this.finalize(e,new s.ArrayExpression(t))},e.prototype.parsePropertyMethod=function(e){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var t=this.context.strict,n=this.context.allowStrictDirective;this.context.allowStrictDirective=e.simple;var i=this.isolateCoverGrammar(this.parseFunctionSourceElements);return this.context.strict&&e.firstRestricted&&this.tolerateUnexpectedToken(e.firstRestricted,e.message),this.context.strict&&e.stricted&&this.tolerateUnexpectedToken(e.stricted,e.message),this.context.strict=t,this.context.allowStrictDirective=n,i},e.prototype.parsePropertyMethodFunction=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters(),i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new s.FunctionExpression(null,n.params,i,!1))},e.prototype.parsePropertyMethodAsyncFunction=function(){var e=this.createNode(),t=this.context.allowYield,n=this.context.await;this.context.allowYield=!1,this.context.await=!0;var i=this.parseFormalParameters(),a=this.parsePropertyMethod(i);return this.context.allowYield=t,this.context.await=n,this.finalize(e,new s.AsyncFunctionExpression(null,i.params,a))},e.prototype.parseObjectPropertyKey=function(){var e,t=this.createNode(),n=this.nextToken();switch(n.type){case 8:case 6:this.context.strict&&n.octal&&this.tolerateUnexpectedToken(n,r.Messages.StrictOctalLiteral);var i=this.getTokenRaw(n);e=this.finalize(t,new s.Literal(n.value,i));break;case 3:case 1:case 5:case 4:e=this.finalize(t,new s.Identifier(n.value));break;case 7:"["===n.value?(e=this.isolateCoverGrammar(this.parseAssignmentExpression),this.expect("]")):e=this.throwUnexpectedToken(n);break;default:e=this.throwUnexpectedToken(n)}return e},e.prototype.isPropertyKey=function(e,t){return e.type===u.Syntax.Identifier&&e.name===t||e.type===u.Syntax.Literal&&e.value===t},e.prototype.parseObjectProperty=function(e){var t,n=this.createNode(),i=this.lookahead,a=null,o=null,u=!1,l=!1,c=!1,h=!1;if(3===i.type){var p=i.value;this.nextToken(),u=this.match("["),a=(h=!(this.hasLineTerminator||"async"!==p||this.match(":")||this.match("(")||this.match("*")||this.match(",")))?this.parseObjectPropertyKey():this.finalize(n,new s.Identifier(p))}else this.match("*")?this.nextToken():(u=this.match("["),a=this.parseObjectPropertyKey());var d=this.qualifiedPropertyName(this.lookahead);if(3===i.type&&!h&&"get"===i.value&&d)t="get",u=this.match("["),a=this.parseObjectPropertyKey(),this.context.allowYield=!1,o=this.parseGetterMethod();else if(3===i.type&&!h&&"set"===i.value&&d)t="set",u=this.match("["),a=this.parseObjectPropertyKey(),o=this.parseSetterMethod();else if(7===i.type&&"*"===i.value&&d)t="init",u=this.match("["),a=this.parseObjectPropertyKey(),o=this.parseGeneratorMethod(),l=!0;else if(a||this.throwUnexpectedToken(this.lookahead),t="init",this.match(":")&&!h)!u&&this.isPropertyKey(a,"__proto__")&&(e.value&&this.tolerateError(r.Messages.DuplicateProtoProperty),e.value=!0),this.nextToken(),o=this.inheritCoverGrammar(this.parseAssignmentExpression);else if(this.match("("))o=h?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),l=!0;else if(3===i.type)if(p=this.finalize(n,new s.Identifier(i.value)),this.match("=")){this.context.firstCoverInitializedNameError=this.lookahead,this.nextToken(),c=!0;var m=this.isolateCoverGrammar(this.parseAssignmentExpression);o=this.finalize(n,new s.AssignmentPattern(p,m))}else c=!0,o=p;else this.throwUnexpectedToken(this.nextToken());return this.finalize(n,new s.Property(t,a,u,o,l,c))},e.prototype.parseObjectInitializer=function(){var e=this.createNode();this.expect("{");for(var t=[],n={value:!1};!this.match("}");)t.push(this.parseObjectProperty(n)),this.match("}")||this.expectCommaSeparator();return this.expect("}"),this.finalize(e,new s.ObjectExpression(t))},e.prototype.parseTemplateHead=function(){i.assert(this.lookahead.head,"Template literal must start with a template head");var e=this.createNode(),t=this.nextToken(),n=t.value,a=t.cooked;return this.finalize(e,new s.TemplateElement({raw:n,cooked:a},t.tail))},e.prototype.parseTemplateElement=function(){10!==this.lookahead.type&&this.throwUnexpectedToken();var e=this.createNode(),t=this.nextToken(),n=t.value,i=t.cooked;return this.finalize(e,new s.TemplateElement({raw:n,cooked:i},t.tail))},e.prototype.parseTemplateLiteral=function(){var e=this.createNode(),t=[],n=[],i=this.parseTemplateHead();for(n.push(i);!i.tail;)t.push(this.parseExpression()),i=this.parseTemplateElement(),n.push(i);return this.finalize(e,new s.TemplateLiteral(n,t))},e.prototype.reinterpretExpressionAsPattern=function(e){switch(e.type){case u.Syntax.Identifier:case u.Syntax.MemberExpression:case u.Syntax.RestElement:case u.Syntax.AssignmentPattern:break;case u.Syntax.SpreadElement:e.type=u.Syntax.RestElement,this.reinterpretExpressionAsPattern(e.argument);break;case u.Syntax.ArrayExpression:e.type=u.Syntax.ArrayPattern;for(var t=0;t")||this.expect("=>"),e={type:c,params:[],async:!1};else{var t=this.lookahead,n=[];if(this.match("..."))e=this.parseRestElement(n),this.expect(")"),this.match("=>")||this.expect("=>"),e={type:c,params:[e],async:!1};else{var i=!1;if(this.context.isBindingElement=!0,e=this.inheritCoverGrammar(this.parseAssignmentExpression),this.match(",")){var a=[];for(this.context.isAssignmentTarget=!1,a.push(e);2!==this.lookahead.type&&this.match(",");){if(this.nextToken(),this.match(")")){this.nextToken();for(var r=0;r")||this.expect("=>"),this.context.isBindingElement=!1,r=0;r")&&(e.type===u.Syntax.Identifier&&"yield"===e.name&&(i=!0,e={type:c,params:[e],async:!1}),!i)){if(this.context.isBindingElement||this.throwUnexpectedToken(this.lookahead),e.type===u.Syntax.SequenceExpression)for(r=0;r")){for(var u=0;u0){this.nextToken(),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;for(var a=[e,this.lookahead],r=t,o=this.isolateCoverGrammar(this.parseExponentiationExpression),u=[r,n.value,o],l=[i];!((i=this.binaryPrecedence(this.lookahead))<=0);){for(;u.length>2&&i<=l[l.length-1];){o=u.pop();var c=u.pop();l.pop(),r=u.pop(),a.pop();var h=this.startNode(a[a.length-1]);u.push(this.finalize(h,new s.BinaryExpression(c,r,o)))}u.push(this.nextToken().value),l.push(i),a.push(this.lookahead),u.push(this.isolateCoverGrammar(this.parseExponentiationExpression))}var p=u.length-1;t=u[p];for(var d=a.pop();p>1;){var m=a.pop(),f=d&&d.lineStart;h=this.startNode(m,f),c=u[p-1],t=this.finalize(h,new s.BinaryExpression(c,u[p-2],t)),p-=2,d=m}}return t},e.prototype.parseConditionalExpression=function(){var e=this.lookahead,t=this.inheritCoverGrammar(this.parseBinaryExpression);if(this.match("?")){this.nextToken();var n=this.context.allowIn;this.context.allowIn=!0;var i=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowIn=n,this.expect(":");var a=this.isolateCoverGrammar(this.parseAssignmentExpression);t=this.finalize(this.startNode(e),new s.ConditionalExpression(t,i,a)),this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1}return t},e.prototype.checkPatternParam=function(e,t){switch(t.type){case u.Syntax.Identifier:this.validateParam(e,t,t.name);break;case u.Syntax.RestElement:this.checkPatternParam(e,t.argument);break;case u.Syntax.AssignmentPattern:this.checkPatternParam(e,t.left);break;case u.Syntax.ArrayPattern:for(var n=0;n")){this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1;var a=e.async,o=this.reinterpretAsCoverFormalsList(e);if(o){this.hasLineTerminator&&this.tolerateUnexpectedToken(this.lookahead),this.context.firstCoverInitializedNameError=null;var l=this.context.strict,h=this.context.allowStrictDirective;this.context.allowStrictDirective=o.simple;var p=this.context.allowYield,d=this.context.await;this.context.allowYield=!0,this.context.await=a;var m=this.startNode(t);this.expect("=>");var f=void 0;if(this.match("{")){var x=this.context.allowIn;this.context.allowIn=!0,f=this.parseFunctionSourceElements(),this.context.allowIn=x}else f=this.isolateCoverGrammar(this.parseAssignmentExpression);var g=f.type!==u.Syntax.BlockStatement;this.context.strict&&o.firstRestricted&&this.throwUnexpectedToken(o.firstRestricted,o.message),this.context.strict&&o.stricted&&this.tolerateUnexpectedToken(o.stricted,o.message),e=a?this.finalize(m,new s.AsyncArrowFunctionExpression(o.params,f,g)):this.finalize(m,new s.ArrowFunctionExpression(o.params,f,g)),this.context.strict=l,this.context.allowStrictDirective=h,this.context.allowYield=p,this.context.await=d}}else if(this.matchAssign()){if(this.context.isAssignmentTarget||this.tolerateError(r.Messages.InvalidLHSInAssignment),this.context.strict&&e.type===u.Syntax.Identifier){var E=e;this.scanner.isRestrictedWord(E.name)&&this.tolerateUnexpectedToken(n,r.Messages.StrictLHSAssignment),this.scanner.isStrictModeReservedWord(E.name)&&this.tolerateUnexpectedToken(n,r.Messages.StrictReservedWord)}this.match("=")?this.reinterpretExpressionAsPattern(e):(this.context.isAssignmentTarget=!1,this.context.isBindingElement=!1);var D=(n=this.nextToken()).value,y=this.isolateCoverGrammar(this.parseAssignmentExpression);e=this.finalize(this.startNode(t),new s.AssignmentExpression(D,e,y)),this.context.firstCoverInitializedNameError=null}}return e},e.prototype.parseExpression=function(){var e=this.lookahead,t=this.isolateCoverGrammar(this.parseAssignmentExpression);if(this.match(",")){var n=[];for(n.push(t);2!==this.lookahead.type&&this.match(",");)this.nextToken(),n.push(this.isolateCoverGrammar(this.parseAssignmentExpression));t=this.finalize(this.startNode(e),new s.SequenceExpression(n))}return t},e.prototype.parseStatementListItem=function(){var e;if(this.context.isAssignmentTarget=!0,this.context.isBindingElement=!0,4===this.lookahead.type)switch(this.lookahead.value){case"export":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,r.Messages.IllegalExportDeclaration),e=this.parseExportDeclaration();break;case"import":this.context.isModule||this.tolerateUnexpectedToken(this.lookahead,r.Messages.IllegalImportDeclaration),e=this.parseImportDeclaration();break;case"const":e=this.parseLexicalDeclaration({inFor:!1});break;case"function":e=this.parseFunctionDeclaration();break;case"class":e=this.parseClassDeclaration();break;case"let":e=this.isLexicalDeclaration()?this.parseLexicalDeclaration({inFor:!1}):this.parseStatement();break;default:e=this.parseStatement()}else e=this.parseStatement();return e},e.prototype.parseBlock=function(){var e=this.createNode();this.expect("{");for(var t=[];!this.match("}");)t.push(this.parseStatementListItem());return this.expect("}"),this.finalize(e,new s.BlockStatement(t))},e.prototype.parseLexicalBinding=function(e,t){var n=this.createNode(),i=this.parsePattern([],e);this.context.strict&&i.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(i.name)&&this.tolerateError(r.Messages.StrictVarName);var a=null;return"const"===e?this.matchKeyword("in")||this.matchContextualKeyword("of")||(this.match("=")?(this.nextToken(),a=this.isolateCoverGrammar(this.parseAssignmentExpression)):this.throwError(r.Messages.DeclarationMissingInitializer,"const")):(!t.inFor&&i.type!==u.Syntax.Identifier||this.match("="))&&(this.expect("="),a=this.isolateCoverGrammar(this.parseAssignmentExpression)),this.finalize(n,new s.VariableDeclarator(i,a))},e.prototype.parseBindingList=function(e,t){for(var n=[this.parseLexicalBinding(e,t)];this.match(",");)this.nextToken(),n.push(this.parseLexicalBinding(e,t));return n},e.prototype.isLexicalDeclaration=function(){var e=this.scanner.saveState();this.scanner.scanComments();var t=this.scanner.lex();return this.scanner.restoreState(e),3===t.type||7===t.type&&"["===t.value||7===t.type&&"{"===t.value||4===t.type&&"let"===t.value||4===t.type&&"yield"===t.value},e.prototype.parseLexicalDeclaration=function(e){var t=this.createNode(),n=this.nextToken().value;i.assert("let"===n||"const"===n,"Lexical declaration must be either let or const");var a=this.parseBindingList(n,e);return this.consumeSemicolon(),this.finalize(t,new s.VariableDeclaration(a,n))},e.prototype.parseBindingRestElement=function(e,t){var n=this.createNode();this.expect("...");var i=this.parsePattern(e,t);return this.finalize(n,new s.RestElement(i))},e.prototype.parseArrayPattern=function(e,t){var n=this.createNode();this.expect("[");for(var i=[];!this.match("]");)if(this.match(","))this.nextToken(),i.push(null);else{if(this.match("...")){i.push(this.parseBindingRestElement(e,t));break}i.push(this.parsePatternWithDefault(e,t)),this.match("]")||this.expect(",")}return this.expect("]"),this.finalize(n,new s.ArrayPattern(i))},e.prototype.parsePropertyPattern=function(e,t){var n,i,a=this.createNode(),r=!1,o=!1;if(3===this.lookahead.type){var u=this.lookahead;n=this.parseVariableIdentifier();var l=this.finalize(a,new s.Identifier(u.value));if(this.match("=")){e.push(u),o=!0,this.nextToken();var c=this.parseAssignmentExpression();i=this.finalize(this.startNode(u),new s.AssignmentPattern(l,c))}else this.match(":")?(this.expect(":"),i=this.parsePatternWithDefault(e,t)):(e.push(u),o=!0,i=l)}else r=this.match("["),n=this.parseObjectPropertyKey(),this.expect(":"),i=this.parsePatternWithDefault(e,t);return this.finalize(a,new s.Property("init",n,r,i,!1,o))},e.prototype.parseObjectPattern=function(e,t){var n=this.createNode(),i=[];for(this.expect("{");!this.match("}");)i.push(this.parsePropertyPattern(e,t)),this.match("}")||this.expect(",");return this.expect("}"),this.finalize(n,new s.ObjectPattern(i))},e.prototype.parsePattern=function(e,t){var n;return this.match("[")?n=this.parseArrayPattern(e,t):this.match("{")?n=this.parseObjectPattern(e,t):(!this.matchKeyword("let")||"const"!==t&&"let"!==t||this.tolerateUnexpectedToken(this.lookahead,r.Messages.LetInLexicalBinding),e.push(this.lookahead),n=this.parseVariableIdentifier(t)),n},e.prototype.parsePatternWithDefault=function(e,t){var n=this.lookahead,i=this.parsePattern(e,t);if(this.match("=")){this.nextToken();var a=this.context.allowYield;this.context.allowYield=!0;var r=this.isolateCoverGrammar(this.parseAssignmentExpression);this.context.allowYield=a,i=this.finalize(this.startNode(n),new s.AssignmentPattern(i,r))}return i},e.prototype.parseVariableIdentifier=function(e){var t=this.createNode(),n=this.nextToken();return 4===n.type&&"yield"===n.value?this.context.strict?this.tolerateUnexpectedToken(n,r.Messages.StrictReservedWord):this.context.allowYield||this.throwUnexpectedToken(n):3!==n.type?this.context.strict&&4===n.type&&this.scanner.isStrictModeReservedWord(n.value)?this.tolerateUnexpectedToken(n,r.Messages.StrictReservedWord):(this.context.strict||"let"!==n.value||"var"!==e)&&this.throwUnexpectedToken(n):(this.context.isModule||this.context.await)&&3===n.type&&"await"===n.value&&this.tolerateUnexpectedToken(n),this.finalize(t,new s.Identifier(n.value))},e.prototype.parseVariableDeclaration=function(e){var t=this.createNode(),n=this.parsePattern([],"var");this.context.strict&&n.type===u.Syntax.Identifier&&this.scanner.isRestrictedWord(n.name)&&this.tolerateError(r.Messages.StrictVarName);var i=null;return this.match("=")?(this.nextToken(),i=this.isolateCoverGrammar(this.parseAssignmentExpression)):n.type===u.Syntax.Identifier||e.inFor||this.expect("="),this.finalize(t,new s.VariableDeclarator(n,i))},e.prototype.parseVariableDeclarationList=function(e){var t={inFor:e.inFor},n=[];for(n.push(this.parseVariableDeclaration(t));this.match(",");)this.nextToken(),n.push(this.parseVariableDeclaration(t));return n},e.prototype.parseVariableStatement=function(){var e=this.createNode();this.expectKeyword("var");var t=this.parseVariableDeclarationList({inFor:!1});return this.consumeSemicolon(),this.finalize(e,new s.VariableDeclaration(t,"var"))},e.prototype.parseEmptyStatement=function(){var e=this.createNode();return this.expect(";"),this.finalize(e,new s.EmptyStatement)},e.prototype.parseExpressionStatement=function(){var e=this.createNode(),t=this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new s.ExpressionStatement(t))},e.prototype.parseIfClause=function(){return this.context.strict&&this.matchKeyword("function")&&this.tolerateError(r.Messages.StrictFunction),this.parseStatement()},e.prototype.parseIfStatement=function(){var e,t=this.createNode(),n=null;this.expectKeyword("if"),this.expect("(");var i=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new s.EmptyStatement)):(this.expect(")"),e=this.parseIfClause(),this.matchKeyword("else")&&(this.nextToken(),n=this.parseIfClause())),this.finalize(t,new s.IfStatement(i,e,n))},e.prototype.parseDoWhileStatement=function(){var e=this.createNode();this.expectKeyword("do");var t=this.context.inIteration;this.context.inIteration=!0;var n=this.parseStatement();this.context.inIteration=t,this.expectKeyword("while"),this.expect("(");var i=this.parseExpression();return!this.match(")")&&this.config.tolerant?this.tolerateUnexpectedToken(this.nextToken()):(this.expect(")"),this.match(";")&&this.nextToken()),this.finalize(e,new s.DoWhileStatement(n,i))},e.prototype.parseWhileStatement=function(){var e,t=this.createNode();this.expectKeyword("while"),this.expect("(");var n=this.parseExpression();if(!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new s.EmptyStatement);else{this.expect(")");var i=this.context.inIteration;this.context.inIteration=!0,e=this.parseStatement(),this.context.inIteration=i}return this.finalize(t,new s.WhileStatement(n,e))},e.prototype.parseForStatement=function(){var e,t,n,i=null,a=null,o=null,l=!0,c=this.createNode();if(this.expectKeyword("for"),this.expect("("),this.match(";"))this.nextToken();else if(this.matchKeyword("var")){i=this.createNode(),this.nextToken();var h=this.context.allowIn;this.context.allowIn=!1;var p=this.parseVariableDeclarationList({inFor:!0});if(this.context.allowIn=h,1===p.length&&this.matchKeyword("in")){var d=p[0];d.init&&(d.id.type===u.Syntax.ArrayPattern||d.id.type===u.Syntax.ObjectPattern||this.context.strict)&&this.tolerateError(r.Messages.ForInOfLoopInitializer,"for-in"),i=this.finalize(i,new s.VariableDeclaration(p,"var")),this.nextToken(),e=i,t=this.parseExpression(),i=null}else 1===p.length&&null===p[0].init&&this.matchContextualKeyword("of")?(i=this.finalize(i,new s.VariableDeclaration(p,"var")),this.nextToken(),e=i,t=this.parseAssignmentExpression(),i=null,l=!1):(i=this.finalize(i,new s.VariableDeclaration(p,"var")),this.expect(";"))}else if(this.matchKeyword("const")||this.matchKeyword("let")){i=this.createNode();var m=this.nextToken().value;this.context.strict||"in"!==this.lookahead.value?(h=this.context.allowIn,this.context.allowIn=!1,p=this.parseBindingList(m,{inFor:!0}),this.context.allowIn=h,1===p.length&&null===p[0].init&&this.matchKeyword("in")?(i=this.finalize(i,new s.VariableDeclaration(p,m)),this.nextToken(),e=i,t=this.parseExpression(),i=null):1===p.length&&null===p[0].init&&this.matchContextualKeyword("of")?(i=this.finalize(i,new s.VariableDeclaration(p,m)),this.nextToken(),e=i,t=this.parseAssignmentExpression(),i=null,l=!1):(this.consumeSemicolon(),i=this.finalize(i,new s.VariableDeclaration(p,m)))):(i=this.finalize(i,new s.Identifier(m)),this.nextToken(),e=i,t=this.parseExpression(),i=null)}else{var f=this.lookahead;if(h=this.context.allowIn,this.context.allowIn=!1,i=this.inheritCoverGrammar(this.parseAssignmentExpression),this.context.allowIn=h,this.matchKeyword("in"))this.context.isAssignmentTarget&&i.type!==u.Syntax.AssignmentExpression||this.tolerateError(r.Messages.InvalidLHSInForIn),this.nextToken(),this.reinterpretExpressionAsPattern(i),e=i,t=this.parseExpression(),i=null;else if(this.matchContextualKeyword("of"))this.context.isAssignmentTarget&&i.type!==u.Syntax.AssignmentExpression||this.tolerateError(r.Messages.InvalidLHSInForLoop),this.nextToken(),this.reinterpretExpressionAsPattern(i),e=i,t=this.parseAssignmentExpression(),i=null,l=!1;else{if(this.match(",")){for(var x=[i];this.match(",");)this.nextToken(),x.push(this.isolateCoverGrammar(this.parseAssignmentExpression));i=this.finalize(this.startNode(f),new s.SequenceExpression(x))}this.expect(";")}}if(void 0===e&&(this.match(";")||(a=this.parseExpression()),this.expect(";"),this.match(")")||(o=this.parseExpression())),!this.match(")")&&this.config.tolerant)this.tolerateUnexpectedToken(this.nextToken()),n=this.finalize(this.createNode(),new s.EmptyStatement);else{this.expect(")");var g=this.context.inIteration;this.context.inIteration=!0,n=this.isolateCoverGrammar(this.parseStatement),this.context.inIteration=g}return void 0===e?this.finalize(c,new s.ForStatement(i,a,o,n)):l?this.finalize(c,new s.ForInStatement(e,t,n)):this.finalize(c,new s.ForOfStatement(e,t,n))},e.prototype.parseContinueStatement=function(){var e=this.createNode();this.expectKeyword("continue");var t=null;if(3===this.lookahead.type&&!this.hasLineTerminator){var n=this.parseVariableIdentifier();t=n;var i="$"+n.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,i)||this.throwError(r.Messages.UnknownLabel,n.name)}return this.consumeSemicolon(),null!==t||this.context.inIteration||this.throwError(r.Messages.IllegalContinue),this.finalize(e,new s.ContinueStatement(t))},e.prototype.parseBreakStatement=function(){var e=this.createNode();this.expectKeyword("break");var t=null;if(3===this.lookahead.type&&!this.hasLineTerminator){var n=this.parseVariableIdentifier(),i="$"+n.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,i)||this.throwError(r.Messages.UnknownLabel,n.name),t=n}return this.consumeSemicolon(),null!==t||this.context.inIteration||this.context.inSwitch||this.throwError(r.Messages.IllegalBreak),this.finalize(e,new s.BreakStatement(t))},e.prototype.parseReturnStatement=function(){this.context.inFunctionBody||this.tolerateError(r.Messages.IllegalReturn);var e=this.createNode();this.expectKeyword("return");var t=(this.match(";")||this.match("}")||this.hasLineTerminator||2===this.lookahead.type)&&8!==this.lookahead.type&&10!==this.lookahead.type?null:this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new s.ReturnStatement(t))},e.prototype.parseWithStatement=function(){this.context.strict&&this.tolerateError(r.Messages.StrictModeWith);var e,t=this.createNode();this.expectKeyword("with"),this.expect("(");var n=this.parseExpression();return!this.match(")")&&this.config.tolerant?(this.tolerateUnexpectedToken(this.nextToken()),e=this.finalize(this.createNode(),new s.EmptyStatement)):(this.expect(")"),e=this.parseStatement()),this.finalize(t,new s.WithStatement(n,e))},e.prototype.parseSwitchCase=function(){var e,t=this.createNode();this.matchKeyword("default")?(this.nextToken(),e=null):(this.expectKeyword("case"),e=this.parseExpression()),this.expect(":");for(var n=[];!(this.match("}")||this.matchKeyword("default")||this.matchKeyword("case"));)n.push(this.parseStatementListItem());return this.finalize(t,new s.SwitchCase(e,n))},e.prototype.parseSwitchStatement=function(){var e=this.createNode();this.expectKeyword("switch"),this.expect("(");var t=this.parseExpression();this.expect(")");var n=this.context.inSwitch;this.context.inSwitch=!0;var i=[],a=!1;for(this.expect("{");!this.match("}");){var o=this.parseSwitchCase();null===o.test&&(a&&this.throwError(r.Messages.MultipleDefaultsInSwitch),a=!0),i.push(o)}return this.expect("}"),this.context.inSwitch=n,this.finalize(e,new s.SwitchStatement(t,i))},e.prototype.parseLabelledStatement=function(){var e,t=this.createNode(),n=this.parseExpression();if(n.type===u.Syntax.Identifier&&this.match(":")){this.nextToken();var i=n,a="$"+i.name;Object.prototype.hasOwnProperty.call(this.context.labelSet,a)&&this.throwError(r.Messages.Redeclaration,"Label",i.name),this.context.labelSet[a]=!0;var o=void 0;if(this.matchKeyword("class"))this.tolerateUnexpectedToken(this.lookahead),o=this.parseClassDeclaration();else if(this.matchKeyword("function")){var l=this.lookahead,c=this.parseFunctionDeclaration();this.context.strict?this.tolerateUnexpectedToken(l,r.Messages.StrictFunction):c.generator&&this.tolerateUnexpectedToken(l,r.Messages.GeneratorInLegacyContext),o=c}else o=this.parseStatement();delete this.context.labelSet[a],e=new s.LabeledStatement(i,o)}else this.consumeSemicolon(),e=new s.ExpressionStatement(n);return this.finalize(t,e)},e.prototype.parseThrowStatement=function(){var e=this.createNode();this.expectKeyword("throw"),this.hasLineTerminator&&this.throwError(r.Messages.NewlineAfterThrow);var t=this.parseExpression();return this.consumeSemicolon(),this.finalize(e,new s.ThrowStatement(t))},e.prototype.parseCatchClause=function(){var e=this.createNode();this.expectKeyword("catch"),this.expect("("),this.match(")")&&this.throwUnexpectedToken(this.lookahead);for(var t=[],n=this.parsePattern(t),i={},a=0;a0&&this.tolerateError(r.Messages.BadGetterArity);var i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new s.FunctionExpression(null,n.params,i,!1))},e.prototype.parseSetterMethod=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters();1!==n.params.length?this.tolerateError(r.Messages.BadSetterArity):n.params[0]instanceof s.RestElement&&this.tolerateError(r.Messages.BadSetterRestParameter);var i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new s.FunctionExpression(null,n.params,i,!1))},e.prototype.parseGeneratorMethod=function(){var e=this.createNode(),t=this.context.allowYield;this.context.allowYield=!0;var n=this.parseFormalParameters();this.context.allowYield=!1;var i=this.parsePropertyMethod(n);return this.context.allowYield=t,this.finalize(e,new s.FunctionExpression(null,n.params,i,!0))},e.prototype.isStartOfExpression=function(){var e=!0,t=this.lookahead.value;switch(this.lookahead.type){case 7:e="["===t||"("===t||"{"===t||"+"===t||"-"===t||"!"===t||"~"===t||"++"===t||"--"===t||"/"===t||"/="===t;break;case 4:e="class"===t||"delete"===t||"function"===t||"let"===t||"new"===t||"super"===t||"this"===t||"typeof"===t||"void"===t||"yield"===t}return e},e.prototype.parseYieldExpression=function(){var e=this.createNode();this.expectKeyword("yield");var t=null,n=!1;if(!this.hasLineTerminator){var i=this.context.allowYield;this.context.allowYield=!1,(n=this.match("*"))?(this.nextToken(),t=this.parseAssignmentExpression()):this.isStartOfExpression()&&(t=this.parseAssignmentExpression()),this.context.allowYield=i}return this.finalize(e,new s.YieldExpression(t,n))},e.prototype.parseClassElement=function(e){var t=this.lookahead,n=this.createNode(),i="",a=null,o=null,u=!1,l=!1,c=!1,h=!1;if(this.match("*"))this.nextToken();else if(u=this.match("["),"static"===(a=this.parseObjectPropertyKey()).name&&(this.qualifiedPropertyName(this.lookahead)||this.match("*"))&&(t=this.lookahead,c=!0,u=this.match("["),this.match("*")?this.nextToken():a=this.parseObjectPropertyKey()),3===t.type&&!this.hasLineTerminator&&"async"===t.value){var p=this.lookahead.value;":"!==p&&"("!==p&&"*"!==p&&(h=!0,t=this.lookahead,a=this.parseObjectPropertyKey(),3===t.type&&"constructor"===t.value&&this.tolerateUnexpectedToken(t,r.Messages.ConstructorIsAsync))}var d=this.qualifiedPropertyName(this.lookahead);return 3===t.type?"get"===t.value&&d?(i="get",u=this.match("["),a=this.parseObjectPropertyKey(),this.context.allowYield=!1,o=this.parseGetterMethod()):"set"===t.value&&d&&(i="set",u=this.match("["),a=this.parseObjectPropertyKey(),o=this.parseSetterMethod()):7===t.type&&"*"===t.value&&d&&(i="init",u=this.match("["),a=this.parseObjectPropertyKey(),o=this.parseGeneratorMethod(),l=!0),!i&&a&&this.match("(")&&(i="init",o=h?this.parsePropertyMethodAsyncFunction():this.parsePropertyMethodFunction(),l=!0),i||this.throwUnexpectedToken(this.lookahead),"init"===i&&(i="method"),u||(c&&this.isPropertyKey(a,"prototype")&&this.throwUnexpectedToken(t,r.Messages.StaticPrototype),!c&&this.isPropertyKey(a,"constructor")&&(("method"!==i||!l||o&&o.generator)&&this.throwUnexpectedToken(t,r.Messages.ConstructorSpecialMethod),e.value?this.throwUnexpectedToken(t,r.Messages.DuplicateConstructor):e.value=!0,i="constructor")),this.finalize(n,new s.MethodDefinition(a,u,o,i,c))},e.prototype.parseClassElementList=function(){var e=[],t={value:!1};for(this.expect("{");!this.match("}");)this.match(";")?this.nextToken():e.push(this.parseClassElement(t));return this.expect("}"),e},e.prototype.parseClassBody=function(){var e=this.createNode(),t=this.parseClassElementList();return this.finalize(e,new s.ClassBody(t))},e.prototype.parseClassDeclaration=function(e){var t=this.createNode(),n=this.context.strict;this.context.strict=!0,this.expectKeyword("class");var i=e&&3!==this.lookahead.type?null:this.parseVariableIdentifier(),a=null;this.matchKeyword("extends")&&(this.nextToken(),a=this.isolateCoverGrammar(this.parseLeftHandSideExpressionAllowCall));var r=this.parseClassBody();return this.context.strict=n,this.finalize(t,new s.ClassDeclaration(i,a,r))},e.prototype.parseClassExpression=function(){var e=this.createNode(),t=this.context.strict;this.context.strict=!0,this.expectKeyword("class");var n=3===this.lookahead.type?this.parseVariableIdentifier():null,i=null;this.matchKeyword("extends")&&(this.nextToken(),i=this.isolateCoverGrammar(this.parseLeftHandSideExpressionAllowCall));var a=this.parseClassBody();return this.context.strict=t,this.finalize(e,new s.ClassExpression(n,i,a))},e.prototype.parseModule=function(){this.context.strict=!0,this.context.isModule=!0,this.scanner.isModule=!0;for(var e=this.createNode(),t=this.parseDirectivePrologues();2!==this.lookahead.type;)t.push(this.parseStatementListItem());return this.finalize(e,new s.Module(t))},e.prototype.parseScript=function(){for(var e=this.createNode(),t=this.parseDirectivePrologues();2!==this.lookahead.type;)t.push(this.parseStatementListItem());return this.finalize(e,new s.Script(t))},e.prototype.parseModuleSpecifier=function(){var e=this.createNode();8!==this.lookahead.type&&this.throwError(r.Messages.InvalidModuleSpecifier);var t=this.nextToken(),n=this.getTokenRaw(t);return this.finalize(e,new s.Literal(t.value,n))},e.prototype.parseImportSpecifier=function(){var e,t,n=this.createNode();return 3===this.lookahead.type?(t=e=this.parseVariableIdentifier(),this.matchContextualKeyword("as")&&(this.nextToken(),t=this.parseVariableIdentifier())):(t=e=this.parseIdentifierName(),this.matchContextualKeyword("as")?(this.nextToken(),t=this.parseVariableIdentifier()):this.throwUnexpectedToken(this.nextToken())),this.finalize(n,new s.ImportSpecifier(t,e))},e.prototype.parseNamedImports=function(){this.expect("{");for(var e=[];!this.match("}");)e.push(this.parseImportSpecifier()),this.match("}")||this.expect(",");return this.expect("}"),e},e.prototype.parseImportDefaultSpecifier=function(){var e=this.createNode(),t=this.parseIdentifierName();return this.finalize(e,new s.ImportDefaultSpecifier(t))},e.prototype.parseImportNamespaceSpecifier=function(){var e=this.createNode();this.expect("*"),this.matchContextualKeyword("as")||this.throwError(r.Messages.NoAsAfterImportNamespace),this.nextToken();var t=this.parseIdentifierName();return this.finalize(e,new s.ImportNamespaceSpecifier(t))},e.prototype.parseImportDeclaration=function(){this.context.inFunctionBody&&this.throwError(r.Messages.IllegalImportDeclaration);var e,t=this.createNode();this.expectKeyword("import");var n=[];if(8===this.lookahead.type)e=this.parseModuleSpecifier();else{if(this.match("{")?n=n.concat(this.parseNamedImports()):this.match("*")?n.push(this.parseImportNamespaceSpecifier()):this.isIdentifierName(this.lookahead)&&!this.matchKeyword("default")?(n.push(this.parseImportDefaultSpecifier()),this.match(",")&&(this.nextToken(),this.match("*")?n.push(this.parseImportNamespaceSpecifier()):this.match("{")?n=n.concat(this.parseNamedImports()):this.throwUnexpectedToken(this.lookahead))):this.throwUnexpectedToken(this.nextToken()),!this.matchContextualKeyword("from")){var i=this.lookahead.value?r.Messages.UnexpectedToken:r.Messages.MissingFromClause;this.throwError(i,this.lookahead.value)}this.nextToken(),e=this.parseModuleSpecifier()}return this.consumeSemicolon(),this.finalize(t,new s.ImportDeclaration(n,e))},e.prototype.parseExportSpecifier=function(){var e=this.createNode(),t=this.parseIdentifierName(),n=t;return this.matchContextualKeyword("as")&&(this.nextToken(),n=this.parseIdentifierName()),this.finalize(e,new s.ExportSpecifier(t,n))},e.prototype.parseExportDeclaration=function(){this.context.inFunctionBody&&this.throwError(r.Messages.IllegalExportDeclaration);var e,t=this.createNode();if(this.expectKeyword("export"),this.matchKeyword("default"))if(this.nextToken(),this.matchKeyword("function")){var n=this.parseFunctionDeclaration(!0);e=this.finalize(t,new s.ExportDefaultDeclaration(n))}else this.matchKeyword("class")?(n=this.parseClassDeclaration(!0),e=this.finalize(t,new s.ExportDefaultDeclaration(n))):this.matchContextualKeyword("async")?(n=this.matchAsyncFunction()?this.parseFunctionDeclaration(!0):this.parseAssignmentExpression(),e=this.finalize(t,new s.ExportDefaultDeclaration(n))):(this.matchContextualKeyword("from")&&this.throwError(r.Messages.UnexpectedToken,this.lookahead.value),n=this.match("{")?this.parseObjectInitializer():this.match("[")?this.parseArrayInitializer():this.parseAssignmentExpression(),this.consumeSemicolon(),e=this.finalize(t,new s.ExportDefaultDeclaration(n)));else if(this.match("*")){if(this.nextToken(),!this.matchContextualKeyword("from")){var i=this.lookahead.value?r.Messages.UnexpectedToken:r.Messages.MissingFromClause;this.throwError(i,this.lookahead.value)}this.nextToken();var a=this.parseModuleSpecifier();this.consumeSemicolon(),e=this.finalize(t,new s.ExportAllDeclaration(a))}else if(4===this.lookahead.type){switch(n=void 0,this.lookahead.value){case"let":case"const":n=this.parseLexicalDeclaration({inFor:!1});break;case"var":case"class":case"function":n=this.parseStatementListItem();break;default:this.throwUnexpectedToken(this.lookahead)}e=this.finalize(t,new s.ExportNamedDeclaration(n,[],null))}else if(this.matchAsyncFunction())n=this.parseFunctionDeclaration(),e=this.finalize(t,new s.ExportNamedDeclaration(n,[],null));else{var o=[],u=null,l=!1;for(this.expect("{");!this.match("}");)l=l||this.matchKeyword("default"),o.push(this.parseExportSpecifier()),this.match("}")||this.expect(",");this.expect("}"),this.matchContextualKeyword("from")?(this.nextToken(),u=this.parseModuleSpecifier(),this.consumeSemicolon()):l?(i=this.lookahead.value?r.Messages.UnexpectedToken:r.Messages.MissingFromClause,this.throwError(i,this.lookahead.value)):this.consumeSemicolon(),e=this.finalize(t,new s.ExportNamedDeclaration(null,o,u))}return e},e}();t.Parser=h},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assert=function(e,t){if(!e)throw new Error("ASSERT: "+t)}},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(){this.errors=[],this.tolerant=!1}return e.prototype.recordError=function(e){this.errors.push(e)},e.prototype.tolerate=function(e){if(!this.tolerant)throw e;this.recordError(e)},e.prototype.constructError=function(e,t){var n=new Error(e);try{throw n}catch(e){Object.create&&Object.defineProperty&&(n=Object.create(e),Object.defineProperty(n,"column",{value:t}))}return n},e.prototype.createError=function(e,t,n,i){var a="Line "+t+": "+i,r=this.constructError(a,n);return r.index=e,r.lineNumber=t,r.description=i,r},e.prototype.throwError=function(e,t,n,i){throw this.createError(e,t,n,i)},e.prototype.tolerateError=function(e,t,n,i){var a=this.createError(e,t,n,i);if(!this.tolerant)throw a;this.recordError(a)},e}();t.ErrorHandler=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Messages={BadGetterArity:"Getter must not have any formal parameters",BadSetterArity:"Setter must have exactly one formal parameter",BadSetterRestParameter:"Setter function argument must not be a rest parameter",ConstructorIsAsync:"Class constructor may not be an async method",ConstructorSpecialMethod:"Class constructor may not be an accessor",DeclarationMissingInitializer:"Missing initializer in %0 declaration",DefaultRestParameter:"Unexpected token =",DuplicateBinding:"Duplicate binding %0",DuplicateConstructor:"A class may only have one constructor",DuplicateProtoProperty:"Duplicate __proto__ fields are not allowed in object literals",ForInOfLoopInitializer:"%0 loop variable declaration may not have an initializer",GeneratorInLegacyContext:"Generator declarations are not allowed in legacy contexts",IllegalBreak:"Illegal break statement",IllegalContinue:"Illegal continue statement",IllegalExportDeclaration:"Unexpected token",IllegalImportDeclaration:"Unexpected token",IllegalLanguageModeDirective:"Illegal 'use strict' directive in function with non-simple parameter list",IllegalReturn:"Illegal return statement",InvalidEscapedReservedWord:"Keyword must not contain escaped characters",InvalidHexEscapeSequence:"Invalid hexadecimal escape sequence",InvalidLHSInAssignment:"Invalid left-hand side in assignment",InvalidLHSInForIn:"Invalid left-hand side in for-in",InvalidLHSInForLoop:"Invalid left-hand side in for-loop",InvalidModuleSpecifier:"Unexpected token",InvalidRegExp:"Invalid regular expression",LetInLexicalBinding:"let is disallowed as a lexically bound name",MissingFromClause:"Unexpected token",MultipleDefaultsInSwitch:"More than one default clause in switch statement",NewlineAfterThrow:"Illegal newline after throw",NoAsAfterImportNamespace:"Unexpected token",NoCatchOrFinally:"Missing catch or finally after try",ParameterAfterRestParameter:"Rest parameter must be last formal parameter",Redeclaration:"%0 '%1' has already been declared",StaticPrototype:"Classes may not have static property named prototype",StrictCatchVariable:"Catch variable may not be eval or arguments in strict mode",StrictDelete:"Delete of an unqualified identifier in strict mode.",StrictFunction:"In strict mode code, functions can only be declared at top level or inside a block",StrictFunctionName:"Function name may not be eval or arguments in strict mode",StrictLHSAssignment:"Assignment to eval or arguments is not allowed in strict mode",StrictLHSPostfix:"Postfix increment/decrement may not have eval or arguments operand in strict mode",StrictLHSPrefix:"Prefix increment/decrement may not have eval or arguments operand in strict mode",StrictModeWith:"Strict mode code may not include a with statement",StrictOctalLiteral:"Octal literals are not allowed in strict mode.",StrictParamDupe:"Strict mode function may not have duplicate parameter names",StrictParamName:"Parameter name eval or arguments is not allowed in strict mode",StrictReservedWord:"Use of future reserved word in strict mode",StrictVarName:"Variable name may not be eval or arguments in strict mode",TemplateOctalLiteral:"Octal literals are not allowed in template strings.",UnexpectedEOS:"Unexpected end of input",UnexpectedIdentifier:"Unexpected identifier",UnexpectedNumber:"Unexpected number",UnexpectedReserved:"Unexpected reserved word",UnexpectedString:"Unexpected string",UnexpectedTemplate:"Unexpected quasi %0",UnexpectedToken:"Unexpected token %0",UnexpectedTokenIllegal:"Unexpected token ILLEGAL",UnknownLabel:"Undefined label '%0'",UnterminatedRegExp:"Invalid regular expression: missing /"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(9),a=n(4),r=n(11);function s(e){return"0123456789abcdef".indexOf(e.toLowerCase())}function o(e){return"01234567".indexOf(e)}var u=function(){function e(e,t){this.source=e,this.errorHandler=t,this.trackComment=!1,this.isModule=!1,this.length=e.length,this.index=0,this.lineNumber=e.length>0?1:0,this.lineStart=0,this.curlyStack=[]}return e.prototype.saveState=function(){return{index:this.index,lineNumber:this.lineNumber,lineStart:this.lineStart}},e.prototype.restoreState=function(e){this.index=e.index,this.lineNumber=e.lineNumber,this.lineStart=e.lineStart},e.prototype.eof=function(){return this.index>=this.length},e.prototype.throwUnexpectedToken=function(e){return void 0===e&&(e=r.Messages.UnexpectedTokenIllegal),this.errorHandler.throwError(this.index,this.lineNumber,this.index-this.lineStart+1,e)},e.prototype.tolerateUnexpectedToken=function(e){void 0===e&&(e=r.Messages.UnexpectedTokenIllegal),this.errorHandler.tolerateError(this.index,this.lineNumber,this.index-this.lineStart+1,e)},e.prototype.skipSingleLineComment=function(e){var t,n,i=[];for(this.trackComment&&(i=[],t=this.index-e,n={start:{line:this.lineNumber,column:this.index-this.lineStart-e},end:{}});!this.eof();){var r=this.source.charCodeAt(this.index);if(++this.index,a.Character.isLineTerminator(r)){if(this.trackComment){n.end={line:this.lineNumber,column:this.index-this.lineStart-1};var s={multiLine:!1,slice:[t+e,this.index-1],range:[t,this.index-1],loc:n};i.push(s)}return 13===r&&10===this.source.charCodeAt(this.index)&&++this.index,++this.lineNumber,this.lineStart=this.index,i}}return this.trackComment&&(n.end={line:this.lineNumber,column:this.index-this.lineStart},s={multiLine:!1,slice:[t+e,this.index],range:[t,this.index],loc:n},i.push(s)),i},e.prototype.skipMultiLineComment=function(){var e,t,n=[];for(this.trackComment&&(n=[],e=this.index-2,t={start:{line:this.lineNumber,column:this.index-this.lineStart-2},end:{}});!this.eof();){var i=this.source.charCodeAt(this.index);if(a.Character.isLineTerminator(i))13===i&&10===this.source.charCodeAt(this.index+1)&&++this.index,++this.lineNumber,++this.index,this.lineStart=this.index;else if(42===i){if(47===this.source.charCodeAt(this.index+1)){if(this.index+=2,this.trackComment){t.end={line:this.lineNumber,column:this.index-this.lineStart};var r={multiLine:!0,slice:[e+2,this.index-2],range:[e,this.index],loc:t};n.push(r)}return n}++this.index}else++this.index}return this.trackComment&&(t.end={line:this.lineNumber,column:this.index-this.lineStart},r={multiLine:!0,slice:[e+2,this.index],range:[e,this.index],loc:t},n.push(r)),this.tolerateUnexpectedToken(),n},e.prototype.scanComments=function(){var e;this.trackComment&&(e=[]);for(var t=0===this.index;!this.eof();){var n=this.source.charCodeAt(this.index);if(a.Character.isWhiteSpace(n))++this.index;else if(a.Character.isLineTerminator(n))++this.index,13===n&&10===this.source.charCodeAt(this.index)&&++this.index,++this.lineNumber,this.lineStart=this.index,t=!0;else if(47===n)if(47===(n=this.source.charCodeAt(this.index+1))){this.index+=2;var i=this.skipSingleLineComment(2);this.trackComment&&(e=e.concat(i)),t=!0}else{if(42!==n)break;this.index+=2,i=this.skipMultiLineComment(),this.trackComment&&(e=e.concat(i))}else if(t&&45===n){if(45!==this.source.charCodeAt(this.index+1)||62!==this.source.charCodeAt(this.index+2))break;this.index+=3,i=this.skipSingleLineComment(3),this.trackComment&&(e=e.concat(i))}else{if(60!==n||this.isModule)break;if("!--"!==this.source.slice(this.index+1,this.index+4))break;this.index+=4,i=this.skipSingleLineComment(4),this.trackComment&&(e=e.concat(i))}}return e},e.prototype.isFutureReservedWord=function(e){switch(e){case"enum":case"export":case"import":case"super":return!0;default:return!1}},e.prototype.isStrictModeReservedWord=function(e){switch(e){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"yield":case"let":return!0;default:return!1}},e.prototype.isRestrictedWord=function(e){return"eval"===e||"arguments"===e},e.prototype.isKeyword=function(e){switch(e.length){case 2:return"if"===e||"in"===e||"do"===e;case 3:return"var"===e||"for"===e||"new"===e||"try"===e||"let"===e;case 4:return"this"===e||"else"===e||"case"===e||"void"===e||"with"===e||"enum"===e;case 5:return"while"===e||"break"===e||"catch"===e||"throw"===e||"const"===e||"yield"===e||"class"===e||"super"===e;case 6:return"return"===e||"typeof"===e||"delete"===e||"switch"===e||"export"===e||"import"===e;case 7:return"default"===e||"finally"===e||"extends"===e;case 8:return"function"===e||"continue"===e||"debugger"===e;case 10:return"instanceof"===e;default:return!1}},e.prototype.codePointAt=function(e){var t=this.source.charCodeAt(e);if(t>=55296&&t<=56319){var n=this.source.charCodeAt(e+1);n>=56320&&n<=57343&&(t=1024*(t-55296)+n-56320+65536)}return t},e.prototype.scanHexEscape=function(e){for(var t="u"===e?4:2,n=0,i=0;i1114111||"}"!==e)&&this.throwUnexpectedToken(),a.Character.fromCodePoint(t)},e.prototype.getIdentifier=function(){for(var e=this.index++;!this.eof();){var t=this.source.charCodeAt(this.index);if(92===t)return this.index=e,this.getComplexIdentifier();if(t>=55296&&t<57343)return this.index=e,this.getComplexIdentifier();if(!a.Character.isIdentifierPart(t))break;++this.index}return this.source.slice(e,this.index)},e.prototype.getComplexIdentifier=function(){var e,t=this.codePointAt(this.index),n=a.Character.fromCodePoint(t);for(this.index+=n.length,92===t&&(117!==this.source.charCodeAt(this.index)&&this.throwUnexpectedToken(),++this.index,"{"===this.source[this.index]?(++this.index,e=this.scanUnicodeCodePointEscape()):null!==(e=this.scanHexEscape("u"))&&"\\"!==e&&a.Character.isIdentifierStart(e.charCodeAt(0))||this.throwUnexpectedToken(),n=e);!this.eof()&&(t=this.codePointAt(this.index),a.Character.isIdentifierPart(t));)n+=e=a.Character.fromCodePoint(t),this.index+=e.length,92===t&&(n=n.substr(0,n.length-1),117!==this.source.charCodeAt(this.index)&&this.throwUnexpectedToken(),++this.index,"{"===this.source[this.index]?(++this.index,e=this.scanUnicodeCodePointEscape()):null!==(e=this.scanHexEscape("u"))&&"\\"!==e&&a.Character.isIdentifierPart(e.charCodeAt(0))||this.throwUnexpectedToken(),n+=e);return n},e.prototype.octalToDecimal=function(e){var t="0"!==e,n=o(e);return!this.eof()&&a.Character.isOctalDigit(this.source.charCodeAt(this.index))&&(t=!0,n=8*n+o(this.source[this.index++]),"0123".indexOf(e)>=0&&!this.eof()&&a.Character.isOctalDigit(this.source.charCodeAt(this.index))&&(n=8*n+o(this.source[this.index++]))),{code:n,octal:t}},e.prototype.scanIdentifier=function(){var e,t=this.index,n=92===this.source.charCodeAt(t)?this.getComplexIdentifier():this.getIdentifier();if(3!=(e=1===n.length?3:this.isKeyword(n)?4:"null"===n?5:"true"===n||"false"===n?1:3)&&t+n.length!==this.index){var i=this.index;this.index=t,this.tolerateUnexpectedToken(r.Messages.InvalidEscapedReservedWord),this.index=i}return{type:e,value:n,lineNumber:this.lineNumber,lineStart:this.lineStart,start:t,end:this.index}},e.prototype.scanPunctuator=function(){var e=this.index,t=this.source[this.index];switch(t){case"(":case"{":"{"===t&&this.curlyStack.push("{"),++this.index;break;case".":++this.index,"."===this.source[this.index]&&"."===this.source[this.index+1]&&(this.index+=2,t="...");break;case"}":++this.index,this.curlyStack.pop();break;case")":case";":case",":case"[":case"]":case":":case"?":case"~":++this.index;break;default:">>>="===(t=this.source.substr(this.index,4))?this.index+=4:"==="===(t=t.substr(0,3))||"!=="===t||">>>"===t||"<<="===t||">>="===t||"**="===t?this.index+=3:"&&"===(t=t.substr(0,2))||"||"===t||"=="===t||"!="===t||"+="===t||"-="===t||"*="===t||"/="===t||"++"===t||"--"===t||"<<"===t||">>"===t||"&="===t||"|="===t||"^="===t||"%="===t||"<="===t||">="===t||"=>"===t||"**"===t?this.index+=2:(t=this.source[this.index],"<>=!+-*%&|^/".indexOf(t)>=0&&++this.index)}return this.index===e&&this.throwUnexpectedToken(),{type:7,value:t,lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanHexLiteral=function(e){for(var t="";!this.eof()&&a.Character.isHexDigit(this.source.charCodeAt(this.index));)t+=this.source[this.index++];return 0===t.length&&this.throwUnexpectedToken(),a.Character.isIdentifierStart(this.source.charCodeAt(this.index))&&this.throwUnexpectedToken(),{type:6,value:parseInt("0x"+t,16),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanBinaryLiteral=function(e){for(var t,n="";!this.eof()&&("0"===(t=this.source[this.index])||"1"===t);)n+=this.source[this.index++];return 0===n.length&&this.throwUnexpectedToken(),this.eof()||(t=this.source.charCodeAt(this.index),(a.Character.isIdentifierStart(t)||a.Character.isDecimalDigit(t))&&this.throwUnexpectedToken()),{type:6,value:parseInt(n,2),lineNumber:this.lineNumber,lineStart:this.lineStart,start:e,end:this.index}},e.prototype.scanOctalLiteral=function(e,t){var n="",i=!1;for(a.Character.isOctalDigit(e.charCodeAt(0))?(i=!0,n="0"+this.source[this.index++]):++this.index;!this.eof()&&a.Character.isOctalDigit(this.source.charCodeAt(this.index));)n+=this.source[this.index++];return i||0!==n.length||this.throwUnexpectedToken(),(a.Character.isIdentifierStart(this.source.charCodeAt(this.index))||a.Character.isDecimalDigit(this.source.charCodeAt(this.index)))&&this.throwUnexpectedToken(),{type:6,value:parseInt(n,8),octal:i,lineNumber:this.lineNumber,lineStart:this.lineStart,start:t,end:this.index}},e.prototype.isImplicitOctalLiteral=function(){for(var e=this.index+1;e=0&&(n=n.replace(/\\u\{([0-9a-fA-F]+)\}|\\u([a-fA-F0-9]{4})/g,(function(e,t,n){var a=parseInt(t||n,16);return a>1114111&&i.throwUnexpectedToken(r.Messages.InvalidRegExp),a<=65535?String.fromCharCode(a):"￿"})).replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"￿"));try{RegExp(n)}catch(e){this.throwUnexpectedToken(r.Messages.InvalidRegExp)}try{return new RegExp(e,t)}catch(e){return null}},e.prototype.scanRegExpBody=function(){var e=this.source[this.index];i.assert("/"===e,"Regular expression literal must start with a slash");for(var t=this.source[this.index++],n=!1,s=!1;!this.eof();)if(t+=e=this.source[this.index++],"\\"===e)e=this.source[this.index++],a.Character.isLineTerminator(e.charCodeAt(0))&&this.throwUnexpectedToken(r.Messages.UnterminatedRegExp),t+=e;else if(a.Character.isLineTerminator(e.charCodeAt(0)))this.throwUnexpectedToken(r.Messages.UnterminatedRegExp);else if(n)"]"===e&&(n=!1);else{if("/"===e){s=!0;break}"["===e&&(n=!0)}return s||this.throwUnexpectedToken(r.Messages.UnterminatedRegExp),t.substr(1,t.length-2)},e.prototype.scanRegExpFlags=function(){for(var e="";!this.eof();){var t=this.source[this.index];if(!a.Character.isIdentifierPart(t.charCodeAt(0)))break;if(++this.index,"\\"!==t||this.eof())e+=t;else if("u"===(t=this.source[this.index])){++this.index;var n=this.index,i=this.scanHexEscape("u");if(null!==i)for(e+=i;n=55296&&e<57343&&a.Character.isIdentifierStart(this.codePointAt(this.index))?this.scanIdentifier():this.scanPunctuator()},e}();t.Scanner=u},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TokenName={},t.TokenName[1]="Boolean",t.TokenName[2]="",t.TokenName[3]="Identifier",t.TokenName[4]="Keyword",t.TokenName[5]="Null",t.TokenName[6]="Numeric",t.TokenName[7]="Punctuator",t.TokenName[8]="String",t.TokenName[9]="RegularExpression",t.TokenName[10]="Template"},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.XHTMLEntities={quot:'"',amp:"&",apos:"'",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦",lang:"⟨",rang:"⟩"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=n(10),a=n(12),r=n(13),s=function(){function e(){this.values=[],this.curly=this.paren=-1}return e.prototype.beforeFunctionExpression=function(e){return["(","{","[","in","typeof","instanceof","new","return","case","delete","throw","void","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=",",","+","-","*","**","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","?",":","===","==",">=","<=","<",">","!=","!=="].indexOf(e)>=0},e.prototype.isRegexStart=function(){var e=this.values[this.values.length-1],t=null!==e;switch(e){case"this":case"]":t=!1;break;case")":var n=this.values[this.paren-1];t="if"===n||"while"===n||"for"===n||"with"===n;break;case"}":if(t=!1,"function"===this.values[this.curly-3])t=!!(i=this.values[this.curly-4])&&!this.beforeFunctionExpression(i);else if("function"===this.values[this.curly-4]){var i;t=!(i=this.values[this.curly-5])||!this.beforeFunctionExpression(i)}}return t},e.prototype.push=function(e){7===e.type||4===e.type?("{"===e.value?this.curly=this.values.length:"("===e.value&&(this.paren=this.values.length),this.values.push(e.value)):this.values.push(null)},e}(),o=function(){function e(e,t){this.errorHandler=new i.ErrorHandler,this.errorHandler.tolerant=!!t&&"boolean"==typeof t.tolerant&&t.tolerant,this.scanner=new a.Scanner(e,this.errorHandler),this.scanner.trackComment=!!t&&"boolean"==typeof t.comment&&t.comment,this.trackRange=!!t&&"boolean"==typeof t.range&&t.range,this.trackLoc=!!t&&"boolean"==typeof t.loc&&t.loc,this.buffer=[],this.reader=new s}return e.prototype.errors=function(){return this.errorHandler.errors},e.prototype.getNextToken=function(){if(0===this.buffer.length){var e=this.scanner.scanComments();if(this.scanner.trackComment)for(var t=0;t-1&&n>=e.flowLevel;switch(function(e,t,n,i,a){var r,s,o,u,l=!1,h=!1,p=-1!==i,N=-1,P=_(u=e.charCodeAt(0))&&65279!==u&&!U(u)&&u!==v&&u!==k&&u!==C&&u!==y&&u!==b&&u!==w&&u!==I&&u!==M&&u!==f&&u!==g&&u!==D&&u!==d&&u!==B&&u!==A&&u!==S&&u!==E&&u!==m&&u!==x&&u!==F&&u!==T&&!U(e.charCodeAt(e.length-1));if(t)for(r=0;r0?e.charCodeAt(r-1):null,P=P&&X(s,o)}else{for(r=0;ri&&" "!==e[N+1],N=r);else if(!_(s))return V;o=r>0?e.charCodeAt(r-1):null,P=P&&X(s,o)}h=h||p&&r-N-1>i&&" "!==e[N+1]}return l||h?n>9&&J(e)?V:h?H:G:P&&!a(e)?z:K}(t,o,e.indent,s,(function(t){return function(e,t){var n,i;for(n=0,i=e.implicitTypes.length;n"+$(t,e.indent)+Y(j(function(e,t){for(var n,i,a,r=/(\n+)([^\n]*)/g,s=(a=-1!==(a=e.indexOf("\n"))?a:e.length,r.lastIndex=a,q(e.slice(0,a),t)),o="\n"===e[0]||" "===e[0];i=r.exec(e);){var u=i[1],l=i[2];n=" "===l[0],s+=u+(o||n||""===l?"":"\n")+q(l,t),o=n}return s}(t,s),r));case V:return'"'+function(e){for(var t,n,i,a="",r=0;r=55296&&t<=56319&&(n=e.charCodeAt(r+1))>=56320&&n<=57343?(a+=L(1024*(t-55296)+n-56320+65536),r++):a+=!(i=N[t])&&_(t)?e[r]:i||L(t);return a}(t)+'"';default:throw new a("impossible error: invalid scalar style")}}()}function $(e,t){var n=J(e)?String(t):"",i="\n"===e[e.length-1];return n+(!i||"\n"!==e[e.length-2]&&"\n"!==e?i?"":"-":"+")+"\n"}function Y(e){return"\n"===e[e.length-1]?e.slice(0,-1):e}function q(e,t){if(""===e||" "===e[0])return e;for(var n,i,a=/ [^ ]/g,r=0,s=0,o=0,u="";n=a.exec(e);)(o=n.index)-r>t&&(i=s>r?s:o,u+="\n"+e.slice(r,i),r=i+1),s=o;return u+="\n",e.length-r>t&&s>r?u+=e.slice(r,s)+"\n"+e.slice(s+1):u+=e.slice(r),u.slice(1)}function Z(e,t,n){var i,r,s,l,c,h;for(s=0,l=(r=n?e.explicitTypes:e.implicitTypes).length;s tag resolver accepts not "'+h+'" style');i=c.represent[h](t,h)}e.dump=i}return!0}return!1}function Q(e,t,n,i,r,s){e.tag=null,e.dump=n,Z(e,n,!1)||Z(e,n,!0);var u=o.call(e.dump);i&&(i=e.flowLevel<0||e.flowLevel>t);var l,h,p="[object Object]"===u||"[object Array]"===u;if(p&&(h=-1!==(l=e.duplicates.indexOf(n))),(null!==e.tag&&"?"!==e.tag||h||2!==e.indent&&t>0)&&(r=!1),h&&e.usedDuplicates[l])e.dump="*ref_"+l;else{if(p&&h&&!e.usedDuplicates[l]&&(e.usedDuplicates[l]=!0),"[object Object]"===u)i&&0!==Object.keys(e.dump).length?(function(e,t,n,i){var r,s,o,u,l,h,p="",d=e.tag,m=Object.keys(n);if(!0===e.sortKeys)m.sort();else if("function"==typeof e.sortKeys)m.sort(e.sortKeys);else if(e.sortKeys)throw new a("sortKeys must be a boolean or a function");for(r=0,s=m.length;r1024)&&(e.dump&&c===e.dump.charCodeAt(0)?h+="?":h+="? "),h+=e.dump,l&&(h+=R(e,t)),Q(e,t+1,u,!0,l)&&(e.dump&&c===e.dump.charCodeAt(0)?h+=":":h+=": ",p+=h+=e.dump));e.tag=d,e.dump=p||"{}"}(e,t,e.dump,r),h&&(e.dump="&ref_"+l+e.dump)):(function(e,t,n){var i,a,r,s,o,u="",l=e.tag,c=Object.keys(n);for(i=0,a=c.length;i1024&&(o+="? "),o+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),Q(e,t,s,!1,!1)&&(u+=o+=e.dump));e.tag=l,e.dump="{"+u+"}"}(e,t,e.dump),h&&(e.dump="&ref_"+l+" "+e.dump));else if("[object Array]"===u){var d=e.noArrayIndent&&t>0?t-1:t;i&&0!==e.dump.length?(function(e,t,n,i){var a,r,s="",o=e.tag;for(a=0,r=n.length;a "+e.dump)}return!0}function ee(e,t){var n,i,a=[],r=[];for(te(e,a,r),n=0,i=r.length;n{const u=s?f({text:s,docLinks:y}):"";return r.a.createElement("section",{key:o},r.a.createElement(i.EuiText,null,r.a.createElement("h4",null,e)),r.a.createElement(i.EuiSpacer,{size:"s"}),r.a.createElement(i.EuiText,{color:"subdued",size:"s"},t&&r.a.createElement(E,{markdown:f({text:t,docLinks:y})}),u&&r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiSpacer,{size:"s"}),r.a.createElement(i.EuiCodeBlock,{isCopyable:!0,language:"bash"},u)),"TutorialConfigAgent"===a&&r.a.createElement(h.a,{variantId:c,apmServerUrl:C,secretToken:A}),"TutorialConfigAgentRumScript"===a&&r.a.createElement(h.a,{variantId:"js_script",apmServerUrl:C,secretToken:A}),n&&r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiSpacer,null),r.a.createElement(E,{markdown:f({text:n,docLinks:y})}))),r.a.createElement(i.EuiSpacer,null))})),k=r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiSpacer,null),S);return r.a.createElement(D,{id:a,buttonContent:r.a.createElement(g,{agentName:a,title:o})},p?r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiSpacer,null),r.a.createElement(i.EuiTabbedContent,{tabs:[{id:"manual-instrumentation",name:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.manualInstrumentation",{defaultMessage:"Manual instrumentation"}),content:k},{id:"auto-attachment",name:r.a.createElement(i.EuiFlexGroup,{justifyContent:"flexStart",alignItems:"baseline",gutterSize:"s"},r.a.createElement(i.EuiFlexItem,{grow:!1},s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.autoAttachment",{defaultMessage:"Auto-Attachment"})),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(x.a,null))),content:r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiSpacer,null),r.a.createElement(p,{policy:e,newPolicy:t,onChange:n}))}]})):k)}var v=n(1003),C=n.n(v),A=n(37),S=n(81),k=n.n(S);function F({id:e,order:t,operation:n,type:o,probe:u,providedDragHandleProps:l,onDelete:c,onEdit:h,operationTypes:p}){const d=Object(a.useMemo)((()=>p.reduce(((e,t)=>({...e,[t.operation.value]:{label:t.operation.label,types:t.types.reduce(((e,{value:t,label:n})=>({...e,[t]:n})),{})}})),{})),[p]);return r.a.createElement(i.EuiPanel,{paddingSize:"m",hasBorder:!0},r.a.createElement(i.EuiFlexGroup,{alignItems:"center"},r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement("div",k()({},l,{"aria-label":s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.discoveryRule.DragHandle",{defaultMessage:"Drag Handle"})}),r.a.createElement(i.EuiIcon,{type:"grab"}))),r.a.createElement(i.EuiFlexItem,null,r.a.createElement(i.EuiFlexGroup,{alignItems:"baseline"},r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiBadge,null,t)),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiBadge,{color:"exclude"===n?"danger":"success"},d[n].label)),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiFlexGroup,null,r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiText,null,r.a.createElement("h4",null,d[n].types[o]))),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiText,null,u)))),r.a.createElement(i.EuiFlexItem,{grow:!1,style:{marginLeft:"auto"}},r.a.createElement(i.EuiFlexGroup,null,r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiButtonIcon,{iconType:"pencil",color:"primary",onClick:()=>{h(e)}})),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiButtonIcon,{iconType:"trash",color:"danger",onClick:()=>{c(e)}}))))))))}function b(){return r.a.createElement(i.EuiPanel,{paddingSize:"m",style:{margin:4},hasBorder:!0},r.a.createElement(i.EuiFlexGroup,{alignItems:"center"},r.a.createElement(i.EuiFlexItem,{grow:!1,style:{marginLeft:100}},r.a.createElement(i.EuiBadge,{color:"danger"},"Exclude")),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiText,{size:"s"},"Everything else"))))}function w({id:e,onChangeOperation:t,operation:n,onChangeType:a,type:o,onChangeProbe:u,probe:l,onCancel:c,onSubmit:h,operationTypes:p}){var d,m;return r.a.createElement(i.EuiPanel,{paddingSize:"m",hasBorder:!0},r.a.createElement(i.EuiFlexGroup,null,r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiFormFieldset,{legend:{children:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.editDisacoveryRule.operation",{defaultMessage:"Operation"})}},r.a.createElement(i.EuiSelect,{"data-test-subj":"apmEditDiscoveryRuleSelect",options:p.map((e=>({text:e.operation.label,value:e.operation.value}))),value:n,onChange:e=>{t(e.target.value)}})))),r.a.createElement(i.EuiFlexGroup,null,r.a.createElement(i.EuiFlexItem,null,r.a.createElement(i.EuiFormFieldset,{legend:{children:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.editDisacoveryRule.type",{defaultMessage:"Type"})}},r.a.createElement(i.EuiFormRow,{fullWidth:!0,helpText:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.editRule.helpText",{defaultMessage:"Choose from allowed parameters"})},r.a.createElement(i.EuiSuperSelect,{hasDividers:!0,fullWidth:!0,options:null!==(d=null===(m=p.find((({operation:e})=>e.value===n)))||void 0===m?void 0:m.types.map((e=>({inputDisplay:e.label,value:e.value,dropdownDisplay:r.a.createElement(r.a.Fragment,null,r.a.createElement("strong",null,e.label),r.a.createElement(i.EuiText,{size:"s",color:"subdued"},r.a.createElement("p",null,e.description)))}))))&&void 0!==d?d:[],valueOfSelected:o,onChange:a}))))),o!==L&&r.a.createElement(i.EuiFlexGroup,null,r.a.createElement(i.EuiFlexItem,null,r.a.createElement(i.EuiFormFieldset,{legend:{children:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.editDisacoveryRule.probe",{defaultMessage:"Probe"})}},r.a.createElement(i.EuiFormRow,{fullWidth:!0,helpText:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.editRule.probeValue",{defaultMessage:"Enter the probe value"})},r.a.createElement(i.EuiFieldText,{"data-test-subj":"apmEditDiscoveryRuleFieldText",fullWidth:!0,value:l,onChange:e=>u(e.target.value)}))))),r.a.createElement(i.EuiFlexGroup,{justifyContent:"flexEnd"},r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiButtonEmpty,{"data-test-subj":"apmEditDiscoveryRuleCancelButton",onClick:c},"Cancel")),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiButton,{"data-test-subj":"apmEditDiscoveryRuleButton",onClick:h,fill:!0,disabled:o!==L&&""===l},e===P?s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.editRule.add",{defaultMessage:"Add"}):s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.editRule.save",{defaultMessage:"Save"})))))}var T=n(82),I=n(73);function B({isValid:e,version:t,onChange:n}){var o;const{services:u}=Object(l.useKibana)();Object(a.useEffect)((()=>{Object(T.createCallApmApi)(u)}),[u]);const{data:c,status:h}=Object(I.c)((e=>e("GET /internal/apm/fleet/java_agent_versions")),[]),p=h===I.a.LOADING,d=!p&&null!=c&&c.versions?c.versions.map((e=>({label:e}))):[],m=!!d.length,f=[{label:t}],x=m?{}:{onCreateOption:e=>{n(e)}};return r.a.createElement(i.EuiFlexItem,null,r.a.createElement(i.EuiFormRow,{label:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.version",{defaultMessage:"Version"}),isInvalid:!e,error:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.version.invalid",{defaultMessage:"Invalid version"}),helpText:r.a.createElement(A.FormattedMessage,{id:"xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.version.helpText",defaultMessage:"Enter the {versionLink} of the Elastic APM Java agent that should be attached.",values:{versionLink:r.a.createElement(i.EuiLink,{"data-test-subj":"apmJavaAgentVersionInputVersionLink",href:`${null===(o=u.docLinks)||void 0===o?void 0:o.ELASTIC_WEBSITE_URL}/guide/en/apm/agent/java/current/release-notes.html`,target:"_blank"},s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.version.helpText.version",{defaultMessage:"version"}))}})},r.a.createElement(i.EuiComboBox,k()({placeholder:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.versionSelect.placeHolder",{defaultMessage:"Select a version"}),singleSelection:{asPlainText:!0},isLoading:p,noSuggestions:!m,isClearable:!m,options:d,selectedOptions:f,onChange:e=>{var t;const i=null===(t=e[0])||void 0===t?void 0:t.label;n(i||"")}},x))))}const M="latest";function N({isEnabled:e,onToggleEnable:t,discoveryRuleList:n,setDiscoveryRuleList:a,onDelete:o,editDiscoveryRuleId:u,onEdit:l,onChangeOperation:c,stagedOperationText:h,onChangeType:p,stagedTypeText:d,onChangeProbe:m,stagedProbeText:f,onCancel:x,onSubmit:g,onAddRule:E,operationTypes:D,toggleDescription:y,discoveryRulesDescription:v,showUnsavedWarning:C,onDragEnd:A,version:S,onChangeVersion:k,isValidVersion:T}){return r.a.createElement("div",null,C&&r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiCallOut,{title:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.unsavedRules",{defaultMessage:'You have unsaved changes. Click "Save integration" to sync changes to the integration.'}),color:"warning",iconType:"iInCircle",size:"s"}),r.a.createElement(i.EuiSpacer,null)),r.a.createElement(i.EuiFlexGroup,null,r.a.createElement(i.EuiFlexItem,null,r.a.createElement(i.EuiSwitch,{label:s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.enableRuntimeAttachement",{defaultMessage:"Enable runtime attachment"}),checked:e,onChange:t}),r.a.createElement(i.EuiSpacer,{size:"s"}),r.a.createElement(i.EuiText,{color:"subdued",size:"s"},r.a.createElement("p",null,y))),e&&r.a.createElement(B,{version:S||M,onChange:k,isValid:T})),e&&r.a.createElement(r.a.Fragment,null,r.a.createElement(i.EuiSpacer,{size:"l"}),r.a.createElement(i.EuiText,{size:"s"},r.a.createElement("h3",null,s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.discoveryRules",{defaultMessage:"Discovery rules"}))),r.a.createElement(i.EuiSpacer,{size:"s"}),r.a.createElement(i.EuiFlexGroup,{alignItems:"center",gutterSize:"m"},r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiIcon,{type:"iInCircle"})),r.a.createElement(i.EuiFlexItem,null,r.a.createElement(i.EuiText,{size:"xs"},r.a.createElement("p",null,v))),r.a.createElement(i.EuiFlexItem,{grow:!1},r.a.createElement(i.EuiButton,{"data-test-subj":"apmRuntimeAttachmentAddRuleButton",iconType:"plusInCircle",disabled:null!==u,onClick:E},s.i18n.translate("xpack.apm.fleetIntegration.apmAgent.runtimeAttachment.addRule",{defaultMessage:"Add rule"})))),r.a.createElement(i.EuiSpacer,{size:"s"}),r.a.createElement(i.EuiDragDropContext,{onDragEnd:A},r.a.createElement(i.EuiDroppable,{droppableId:"RUNTIME_ATTACHMENT_DROPPABLE"},n.map((({discoveryRule:e,id:t},n)=>r.a.createElement(i.EuiDraggable,{spacing:"m",key:t,index:n,draggableId:t,customDragHandle:!0},(i=>t===u?r.a.createElement(w,{id:u,onChangeOperation:c,operation:h,onChangeType:p,type:d,onChangeProbe:m,probe:f,onCancel:x,onSubmit:g,operationTypes:D}):r.a.createElement(F,{id:t,order:n+1,operation:e.operation,type:e.type,probe:e.probe,providedDragHandleProps:i.dragHandleProps,onDelete:o,onEdit:l,operationTypes:D}))))))),r.a.createElement(b,null)),r.a.createElement(i.EuiSpacer,{size:"s"}))}const P="STAGED_DISCOVERY_RULE_ID",L="all",O=new RegExp(/latest|^\d+\.\d+\.\d+(\.\w+)?$/);function j(e){return!!e&&O.test(e)}function R(e){const{initialDiscoveryRules:t=[],onChange:n=(()=>{})}=e,[s,o]=Object(a.useState)(Boolean(e.initialIsEnabled)),[u,l]=Object(a.useState)(t.map((e=>({id:U(),discoveryRule:e})))),[c,h]=Object(a.useState)(null),[p,d]=Object(a.useState)(e.version),[m,f]=Object(a.useState)(j(e.version));Object(a.useEffect)((()=>{s&&!m&&e.invalidatePackagePolicy()}),[s,m]);const x=Object(a.useCallback)((()=>{const e=!s;o(e),n({enabled:e,discoveryRules:e?u.map((({discoveryRule:e})=>e)):[],version:e?p:null})}),[s,n,u,p]),g=Object(a.useCallback)((e=>{const t=u.filter((({id:t})=>t!==e));l(t),n({enabled:s,discoveryRules:t.map((({discoveryRule:e})=>e)),version:p})}),[s,u,n,p]),E=Object(a.useCallback)((e=>{const t=u.find((({id:t})=>t===e));if(t){const{discoveryRule:{operation:n,type:i,probe:a}}=t;y(n),C(i),S(a),h(e)}}),[u]),[D,y]=Object(a.useState)(""),[v,C]=Object(a.useState)(""),[A,S]=Object(a.useState)(""),k=Object(a.useCallback)((t=>{y(t);const n=e.operationTypes.find((({operation:e})=>t===e.value));var i;(null==n?void 0:n.types.some((({value:e})=>v===e)))||C(null!==(i=null==n?void 0:n.types[0].value)&&void 0!==i?i:"")}),[e.operationTypes,v]),F=Object(a.useCallback)((e=>{C(e),e===L&&S("")}),[]),b=Object(a.useCallback)((e=>{S(e)}),[]),w=Object(a.useCallback)((()=>{c===P&&g(P),h(null)}),[c,g]),T=Object(a.useCallback)((()=>{const e=u.findIndex((({id:e})=>e===c)),t=u[e],i=[...u.slice(0,e),{id:t.id===P?U():t.id,discoveryRule:{operation:D,type:v,probe:A}},...u.slice(e+1)];l(i),h(null),n({enabled:s,discoveryRules:i.map((({discoveryRule:e})=>e)),version:p})}),[s,c,D,v,A,u,n,p]),I=Object(a.useCallback)((()=>{const t=e.operationTypes[0],n=t.operation.value,i=t.types[0].value;y(n),C(i),S("");const a=[{id:P,discoveryRule:{operation:n,type:i,probe:""}},...u];l(a),h(P)}),[u,e.operationTypes]),B=Object(a.useCallback)((({source:e,destination:t})=>{if(e&&t){const a=Object(i.euiDragDropReorder)(u,e.index,t.index);l(a),n({enabled:s,discoveryRules:a.map((({discoveryRule:e})=>e)),version:p})}}),[s,u,n,p]);return r.a.createElement(N,{isEnabled:s,onToggleEnable:x,discoveryRuleList:u,setDiscoveryRuleList:l,onDelete:g,editDiscoveryRuleId:c,onEdit:E,onChangeOperation:k,stagedOperationText:D,onChangeType:F,stagedTypeText:v,onChangeProbe:b,stagedProbeText:A,onCancel:w,onSubmit:T,onAddRule:I,operationTypes:e.operationTypes,toggleDescription:e.toggleDescription,discoveryRulesDescription:e.discoveryRulesDescription,showUnsavedWarning:e.showUnsavedWarning,onDragEnd:B,version:p,onChangeVersion:function(e){const t=j(e);f(t),d(e),t&&n({enabled:s,discoveryRules:s?u.map((({discoveryRule:e})=>e)):[],version:e})},isValidVersion:m})}const U=Object(i.htmlIdGenerator)(),_=[{value:"main",label:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude.options.main",{defaultMessage:"main"}),description:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude.options.mainDescription",{defaultMessage:"A regular expression of fully qualified main class names or paths to JARs of applications the java agent should be attached to. Performs a partial match so that foo matches /bin/foo.jar."})},{value:"vmarg",label:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude.options.vmarg",{defaultMessage:"vmarg"}),description:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude.options.vmargDescription",{defaultMessage:"A regular expression matched against the arguments passed to the JVM, such as system properties. Performs a partial match so that attach=true matches the system property -Dattach=true."})},{value:"user",label:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude.options.user",{defaultMessage:"user"}),description:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude.options.userDescription",{defaultMessage:"A username that is matched against the operating system user that runs the JVM."})}],X=[{value:"all",label:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.include.options.all",{defaultMessage:"All"}),description:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.include.options.allDescription",{defaultMessage:"Includes all JVMs for attachment."})},..._],J={operation:"include",type:"vmarg",probe:"elastic.apm.attach=true"};function z(e,t=[]){try{var n;const i=null!==(n=C.a.load(e))&&void 0!==n?n:[];return 0===i.length?t:i.map((e=>{const[t,n]=Object.entries(e)[0];return{operation:t.split("-")[0],type:t.split("-")[1],probe:n}}))}catch(e){return t}}function K(e){const t=e.map((({operation:e,type:t,probe:n})=>({[`${e}-${t}`]:n})));return C.a.dump(t)}const G=[{agentName:"java",title:"Java",variantId:"java",createAgentInstructions:(e="",t="")=>[{title:s.i18n.translate("xpack.apm.tutorial.javaClient.download.title",{defaultMessage:"Download the APM agent"}),textPre:s.i18n.translate("xpack.apm.tutorial.javaClient.download.textPre",{defaultMessage:"Download the agent jar from [Maven Central]({mavenCentralLink}). Do **not** add the agent as a dependency to your application.",values:{mavenCentralLink:"https://oss.sonatype.org/service/local/artifact/maven/redirect?r=releases&g=co.elastic.apm&a=elastic-apm-agent&v=LATEST"}})},{title:s.i18n.translate("xpack.apm.tutorial.javaClient.startApplication.title",{defaultMessage:"Start your application with the javaagent flag"}),textPre:s.i18n.translate("xpack.apm.tutorial.javaClient.startApplication.textPre",{defaultMessage:"Add the `-javaagent` flag and configure the agent with system properties.\n\n * Set the required service name (allowed characters: a-z, A-Z, 0-9, -, _, and space)\n * Set the custom APM Server URL (default: {customApmServerUrl})\n * Set the APM Server secret token\n * Set the service environment\n * Set the base package of your application",values:{customApmServerUrl:"http://localhost:8200"}}),customComponentName:"TutorialConfigAgent",textPost:s.i18n.translate("xpack.apm.tutorial.javaClient.startApplication.textPost",{defaultMessage:"See the [documentation]({documentationLink}) for configuration options and advanced usage.",values:{documentationLink:"{config.docs.base_url}guide/en/apm/agent/java/current/index.html"}})}],AgentRuntimeAttachment:function({newPolicy:e,onChange:t}){var n,i,o,u;const[l,c]=Object(a.useState)(!1),h=Object(a.useCallback)((n=>{const i=e.inputs.findIndex((({type:e})=>"apm"===e));t({isValid:!n.enabled||j(n.version),updatedPolicy:{...e,inputs:[...e.inputs.slice(0,i),{...e.inputs[i],vars:{...e.inputs[i].vars,java_attacher_enabled:{value:n.enabled,type:"bool"},java_attacher_discovery_rules:{type:"yaml",value:K(n.discoveryRules)},java_attacher_agent_version:{type:"text",value:n.version}}},...e.inputs.slice(i+1)]}}),c(!0)}),[e,t]),p=Object(a.useMemo)((()=>function(e){var t;return null===(t=e.inputs.find((({type:e})=>"apm"===e)))||void 0===t?void 0:t.vars}(e)),[e]);return r.a.createElement(R,{operationTypes:[{operation:{value:"include",label:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.include",{defaultMessage:"Include"})},types:X},{operation:{value:"exclude",label:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.operationType.exclude",{defaultMessage:"Exclude"})},types:_}],onChange:h,toggleDescription:s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.toggleDescription",{defaultMessage:"Attach the Java agent to running and starting Java applications."}),discoveryRulesDescription:r.a.createElement(A.FormattedMessage,{id:"xpack.apm.fleetIntegration.javaRuntime.discoveryRulesDescription",defaultMessage:"For every running JVM, the discovery rules are evaluated in the order they are provided. The first matching rule determines the outcome. Learn more in the {docLink}.",values:{docLink:r.a.createElement("a",{href:"https://www.elastic.co/guide/en/apm/agent/java/current/setup-attach-cli.html",target:"_blank"},s.i18n.translate("xpack.apm.fleetIntegration.javaRuntime.discoveryRulesDescription.docLink",{defaultMessage:"docs"}))}}),showUnsavedWarning:l,initialIsEnabled:null==p||null===(n=p.java_attacher_enabled)||void 0===n?void 0:n.value,initialDiscoveryRules:z(null!==(i=null==p||null===(o=p.java_attacher_discovery_rules)||void 0===o?void 0:o.value)&&void 0!==i?i:"[]\n",[J]),version:(null==p||null===(u=p.java_attacher_agent_version)||void 0===u?void 0:u.value)||"latest",invalidatePackagePolicy:function(){t({isValid:!1,updatedPolicy:e})}})}},{agentName:"rum-js",title:"JavaScript (Real User Monitoring)",variantId:"js",createAgentInstructions:(e="")=>[{title:s.i18n.translate("xpack.apm.tutorial.jsClient.enableRealUserMonitoring.title",{defaultMessage:"Enable Real User Monitoring support in APM Server"}),textPre:s.i18n.translate("xpack.apm.tutorial.jsClient.enableRealUserMonitoring.textPre",{defaultMessage:"APM Server disables RUM support by default. See the [documentation]({documentationLink}) for details on how to enable RUM support. When using the APM integration with Fleet, RUM support is automatically enabled.",values:{documentationLink:"{config.docs.base_url}guide/en/apm/guide/{config.docs.version}/configuration-rum.html"}})},{title:s.i18n.translate("xpack.apm.tutorial.jsClient.installDependency.title",{defaultMessage:"Set up the Agent as a dependency"}),textPre:s.i18n.translate("xpack.apm.tutorial.jsClient.installDependency.textPre",{defaultMessage:"You can install the Agent as a dependency to your application with `npm install @elastic/apm-rum --save`.\n\nThe Agent can then be initialized and configured in your application like this:"}),customComponentName:"TutorialConfigAgent",textPost:s.i18n.translate("xpack.apm.tutorial.jsClient.installDependency.textPost",{defaultMessage:"Framework integrations, like React or Angular, have custom dependencies. See the [integration documentation]({docLink}) for more information.",values:{docLink:"{config.docs.base_url}guide/en/apm/agent/rum-js/current/framework-integrations.html"}})},{title:s.i18n.translate("xpack.apm.tutorial.jsClient.scriptTags.title",{defaultMessage:"Set up the Agent with Script Tags"}),textPre:s.i18n.translate("xpack.apm.tutorial.jsClient.scriptTags.textPre",{defaultMessage:"Alternatively, you can use Script tags to set up and configure the Agent. Add a `