n8n-editor-ui
Version:
Workflow Editor UI for n8n
2 lines • 202 kB
JavaScript
!function(){try{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{}).SENTRY_RELEASE={id:"n8n@2.13.4"}}catch(e){}}(),function(){System.register(["./chunk-legacy-TXBRODOR.js","./vue.runtime.esm-bundler-legacy-IafOlCW8.js","./_MapCache-legacy-DwgdC8YO.js","./src-legacy-Dwzr7bD0.js","./sanitize-html-legacy-ChR3ikxn.js","./users.store-legacy-OKuN0qAC.js","./constants-legacy-DNCca_FT.js","./merge-legacy-uu1aGqHK.js","./_baseOrderBy-legacy-PsQY_Pvh.js","./dateformat-legacy-BxdD_OP7.js","./useDebounce-legacy-CT3oYGrC.js"],(function(_export,_context){var __toCommonJS,__require,__toESM,__commonJSMin,unref,useI18n,require_get,require_path_browserify,empty_exports,init_empty,useToast,importCurlEventBus,CURL_IMPORT_NOT_SUPPORTED_PROTOCOLS,CURL_IMPORT_NODES_PROTOCOLS,assert,import_get,CCError,UTF8encoder,Word,require_tree_sitter,import_tree_sitter,Bash,parser,webParser_default,BACKSLASHES,DOUBLE_QUOTE_BACKSLASHES,ANSI_BACKSLASHES,CURLAUTH_BASIC,CURLAUTH_DIGEST,CURLAUTH_NEGOTIATE,CURLAUTH_NTLM,CURLAUTH_DIGEST_IE,CURLAUTH_NTLM_WB,CURLAUTH_BEARER,CURLAUTH_AWS_SIGV4,CURLAUTH_ANY,curlLongOpts,curlLongOptsShortened,COMMON_SUPPORTED_ARGS,curlShortOpts,changedShortOpts,canBeList,COMMA_SEPARATED,SEMICOLON_SEPARATED,Headers,MAX_IP6LEN,require_Pattern,require_Utils,require_Unescaper,require_Escaper,require_ParseException,require_ParseMore,require_DumpException,require_Inline,require_Parser,require_Dumper,require_Yaml,import_Yaml,supportedArgs$43,supportedArgs$42,require_jsesc,import_jsesc,javaScriptSupportedArgs,nodeSupportedArgs,FORBIDDEN_HEADERS,supportedArgs$41,supportedArgs$40,supportedArgs$39,supportedArgs$38,supportedArgs$37,supportedArgs$36,supportedArgs$35,supportedArgs$34,supportedArgs$33,supportedArgs$32,supportedArgs$31,supportedArgs$30,supportedArgs$29,supportedArgs$28,supportedArgs$27,supportedArgs$26,supportedArgs$25,supportedArgs$24,supportedArgs$23,supportedArgs$22,supportedArgs$21,supportedArgs$20,supportedArgs$19,supportedArgs$18,supportedArgs$17,supportedArgs$16,supportedArgs$15,supportedArgs$14,supportedArgs$13,reservedHeaders,supportedArgs$12,supportedArgs$11,supportedArgs$10,supportedArgs$9,supportedArgs$8,supportedArgs$7,supportedArgs$6,supportedArgs$5,supportedArgs$4,supportedArgs$3,supportedArgs$2,supportedArgs$1,INDENTATION,supportedArgs,SUPPORTED_CONTENT_TYPES,CONTENT_TYPE_KEY,getContentTypeHeader,isContentType,isJsonRequest,isFormUrlEncodedRequest,isMultipartRequest,isBinaryRequest,toKeyValueArray,extractHeaders,extractQueries,keyValueBodyToNodeParameters,jsonBodyToNodeParameters,multipartToNodeParameters,lowerCaseContentTypeKey,encodeBasicAuthentication,jsonHasNestedObjects,mapCookies,flattenObject,toHttpNodeParameters;function has(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function isInt(e){return/^\s*[+-]?\d+$/.test(e)}function eq(e,t){return null==e||null==t?e===t:"string"==typeof t?1===e.tokens.length&&"string"==typeof e.tokens[0]&&e.tokens[0]===t:e.tokens.length===t.tokens.length&&e.tokens.every(((e,r)=>{const s=t.tokens[r];return"string"==typeof e?e===s:"string"!=typeof s&&e.text===s.text}))}function firstShellToken(e){return"string"==typeof e?null:e.firstShellToken()}function mergeWords(...e){const t=[];for(const r of e)r instanceof Word?t.push(...r.tokens):t.push(r);return new Word(t)}function joinWords(e,t){const r=[];for(const s of e)r.length&&r.push(t),r.push(...s.tokens);return new Word(r)}function warnf(e,t){e.warnings.push(t)}function underline(e,t,r,s){t===r&&r++;let n=t;t>0&&(n=s.lastIndexOf("\n",t-1)+1);let o=r-t,a=s.indexOf("\n",t);-1===a?a=s.length:a<r&&(o=a-t+1);return s.slice(n,a)+"\n"+(" ".repeat(t-n)+"^".repeat(o))}function underlineCursor(e,t){return underline(e,e.startIndex,e.endIndex,t)}function underlineNode(e,t){const r=e.tree.rootNode;let s=e.startIndex,n=e.endIndex;return t||(t=r.text,s-=r.startIndex,n-=r.startIndex),underline(e,s,n,t)}function warnIfPartsIgnored(e,t,r){e.urls.length>1&&!(null==r?void 0:r.multipleUrls)&&t.push(["multiple-urls","found "+e.urls.length+" URLs, only the first one will be used: "+e.urls.map((e=>JSON.stringify(e.originalUrl.toString()))).join(", ")]),e.dataReadsFile&&!(null==r?void 0:r.dataReadsFile)&&t.push(["unsafe-data","the generated data content is wrong, "+JSON.stringify("@"+e.dataReadsFile)+" means read the file "+JSON.stringify(e.dataReadsFile)]),e.urls[0].queryReadsFile&&!(null==r?void 0:r.queryReadsFile)&&t.push(["unsafe-query","the generated URL query string is wrong, "+JSON.stringify("@"+e.urls[0].queryReadsFile)+" means read the file "+JSON.stringify(e.urls[0].queryReadsFile)]),e.cookieFiles&&!(null==r?void 0:r.cookieFiles)&&t.push(["cookie-files","passing a file for --cookie/-b is not supported: "+e.cookieFiles.map((e=>JSON.stringify(e.toString()))).join(", ")])}function removeBackslash(e){return"\n"===e.charAt(1)?"":e.charAt(1)}function removeBackslashes(e){return e.replace(BACKSLASHES,removeBackslash)}function removeDoubleQuoteBackslashes(e){return e.replace(DOUBLE_QUOTE_BACKSLASHES,removeBackslash)}function removeAnsiCBackslashes(e){return e.replace(ANSI_BACKSLASHES,(function(e){switch(e.charAt(1)){case"\\":return"\\";case"a":return"";case"b":return"\b";case"e":case"E":return"";case"f":return"\f";case"n":return"\n";case"r":return"\r";case"t":return"\t";case"v":return"\v";case"'":return"'";case'"':return'"';case"?":return"?";case"c":if(e.codePointAt(2)>127)throw new CCError('non-ASCII control character in ANSI-C quoted string: "\\u{'+e.codePointAt(2).toString(16)+'}"');return"?"===e[2]?"":String.fromCodePoint(31&e[2].toUpperCase().codePointAt(0));case"x":case"u":case"U":return String.fromCodePoint(parseInt(e.slice(2),16));case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":return String.fromCodePoint(parseInt(e.slice(1),8)%256);default:throw new CCError("unhandled character in ANSI-C escape code: "+JSON.stringify(e))}}))}function toTokens(e,t,r){let s=[];switch(e.type){case"$":return["$"];case"word":case"number":return[removeBackslashes(e.text)];case"raw_string":return[e.text.slice(1,-1)];case"ansi_c_string":return[removeAnsiCBackslashes(e.text.slice(2,-1))];case"string":case"translated_string":{let n="";for(const o of e.namedChildren)if("string_content"===o.type)n+=removeDoubleQuoteBackslashes(o.text);else{const e=toTokens(o,t,r);"string"==typeof e?n+=e:(n&&(s.push(n),n=""),s=s.concat(e))}return(n||0===s.length)&&s.push(n),s}case"simple_expansion":return r.push(["expansion","found environment variable\n"+underlineNode(e,t)]),e.firstNamedChild&&"special_variable_name"===e.firstNamedChild.type&&r.push(["special_variable_name",e.text+" is a special Bash variable\n"+underlineNode(e.firstNamedChild,t)]),[{type:"variable",value:e.text.slice(1),text:e.text,syntaxNode:e}];case"expansion":return r.push(["expansion","found expansion expression\n"+underlineNode(e,t)]),[{type:"variable",value:e.text.slice(2,-1),text:e.text,syntaxNode:e}];case"command_substitution":return r.push(["expansion","found command substitution expression\n"+underlineNode(e,t)]),[{type:"command",value:e.text.slice(e.text.startsWith("$(")?2:1,-1),text:e.text,syntaxNode:e}];case"concatenation":{let n=0,o="";for(const a of e.children){o+=e.text.slice(n,a.startIndex-e.startIndex),n=a.endIndex-e.startIndex;const i=toTokens(a,t,r);"string"==typeof i?o+=i:(o&&(s.push(o),o=""),s=s.concat(i))}return o+=e.text.slice(n),(o||0===s.length)&&s.push(o),s}default:throw new CCError("unexpected syntax node type "+JSON.stringify(e.type)+'. Must be one of "word", "number", "string", "raw_string", "ansi_c_string", "expansion", "simple_expansion", "translated_string", "command_substitution" or "concatenation"\n'+underlineNode(e,t))}}function toWord(e,t,r){return new Word(toTokens(e,t,r))}function*traverseLookingForBadNodes(e){const t=e.walk();let r=!1;for(;!r;){if(("ERROR"===t.nodeType||t.nodeIsMissing)&&(yield t),t.gotoFirstChild())continue;if(t.gotoNextSibling())continue;let e=!0;for(;e;)t.gotoParent()||(e=!1,r=!0),t.gotoNextSibling()&&(e=!1)}}function warnAboutBadNodes(e,t,r){let s=0;for(const a of traverseLookingForBadNodes(e)){if(s<3){let e="";try{e=":\n"+underlineCursor(a,t)}catch(o){}const s=a.startPosition.row,n=a.startPosition.column;r.push(["bash",`Bash parsing error on line ${s+1}`+(0!==n?`, column ${n+1}`:"")+e])}s+=1}const n=s-3;n>0&&r.push(["bash",`${n} more Bash parsing error${n>1?"s":""} omitted`])}function warnAboutUselessBackslash(e,t,r){const s=t[e.endPosition.row],n=s.match(/\\\s+$/);n&&t.length>e.endPosition.row+1&&void 0!==n.index&&r.push(["unescaped-newline","The trailling '\\' on line "+(e.endPosition.row+1)+" is followed by whitespace, so it won't escape the newline after it:\n"+s+"\n"+" ".repeat(n.index)+"^".repeat(n[0].length)])}function extractRedirect(e,t,r){if(!e.namedChildCount)throw new CCError('got empty "redirected_statement" AST node');let s,n;const[o,...a]=e.namedChildren;if("command"!==o.type)throw new CCError('got "redirected_statement" AST node whose first child is not a "command", got '+o.type+" instead\n"+underlineNode(o,t));if(e.childCount<2)throw new CCError('got "redirected_statement" AST node with only one child - no redirect');a.length>1&&r.push(["multiple-redirects","found "+a.length+" redirect nodes. Only the first one will be used:\n"+underlineNode(a[1],t)]);const i=a[0];if("file_redirect"===i.type){const e=i.childForFieldName("destination");if(!e)throw new CCError('got "file_redirect" AST node with no "destination" child');n=toWord(e,t,r)}else if("heredoc_redirect"===i.type){const e=i.descendantsOfType("heredoc_body")[0];if(!e)throw new CCError('got "redirected_statement" AST node without heredoc_body');s=new Word(e.text)}else{if("herestring_redirect"!==i.type)throw new CCError('got "redirected_statement" AST node whose second child is not one of "file_redirect", "heredoc_redirect" or "herestring_redirect", got '+o.type+" instead");if(i.namedChildCount<1||!i.firstNamedChild)throw new CCError('got "redirected_statement" AST node with empty herestring');s=toWord(i.firstNamedChild,t,r)}return[o,s,n]}function _findCurlInPipeline(e,t,r){let s,n,o;for(const a of e.namedChildren)if("command"===a.type){const e=a.namedChildren[0];if("command_name"!==e.type)throw new CCError('got "command" AST node whose first child is not a "command_name", got '+e.type+" instead\n"+underlineNode(e,t));const n=e.namedChildren[0];if("word"!==n.type)throw new CCError('got "command_name" AST node whose first child is not a "word", got '+n.type+" instead\n"+underlineNode(n,t));"curl"===n.text&&(s?r.push(["multiple-curl-in-pipeline","found multiple curl commands in pipeline:\n"+underlineNode(a,t)]):s=a)}else if("redirected_statement"===a.type){const[e,i,l]=extractRedirect(a,t,r);"curl"===e.namedChildren[0].text&&(s?r.push(["multiple-curl-in-pipeline","found multiple curl commands in pipeline:\n"+underlineNode(e,t)]):[s,n,o]=[e,i,l])}else if("pipeline"===a.type){const[e,i,l]=_findCurlInPipeline(a,t,r);if(!e)continue;"curl"===e.namedChildren[0].text&&(s?r.push(["multiple-curl-in-pipeline","found multiple curl commands in pipeline:\n"+underlineNode(e,t)]):[s,n,o]=[e,i,l])}return[s,n,o]}function findCurlInPipeline(e,t,r){const[s,n,o]=_findCurlInPipeline(e,t,r);if(!s)throw new CCError("could not find curl command in pipeline\n"+underlineNode(e,t));return[s,n,o]}function extractCommandNodes(e,t,r){if("program"!==e.rootNode.type)throw new CCError('expected a "program" top-level AST node, got '+e.rootNode.type+" instead");if(e.rootNode.namedChildCount<1||!e.rootNode.namedChildren)throw new CCError('empty "program" node');const s=t.split("\n");let n=!1;const o=[];for(const a of e.rootNode.namedChildren)switch(a.type){case"comment":n=!0;continue;case"command":o.push([a,void 0,void 0]),warnAboutUselessBackslash(a,s,r);break;case"redirected_statement":o.push(extractRedirect(a,t,r)),warnAboutUselessBackslash(a,s,r);break;case"pipeline":o.push(findCurlInPipeline(a,t,r)),warnAboutUselessBackslash(a,s,r);break;case"heredoc_body":continue;case"ERROR":throw new CCError(`Bash parsing error on line ${a.startPosition.row+1}:\n`+underlineNode(a,t));default:throw new CCError("found "+JSON.stringify(a.type)+' AST node, only "command", "pipeline" or "redirected_statement" are supported\n'+underlineNode(a,t))}if(!o.length)throw new CCError('expected a "command" or "redirected_statement" AST node'+(n?', only found "comment" nodes':""));return o}function toNameAndArgv(e,t,r){if(e.childCount<1)throw new CCError('empty "command" node\n'+underlineNode(e,t));const s=e.childForFieldName("name"),n=e.childrenForFieldName("argument");if(!s)throw new CCError('found "command" AST node with no "command_name" child\n'+underlineNode(e,t));return[s,n]}function nameToWord(e,t,r){if(e.childCount<1||!e.firstChild)throw new CCError('found empty "command_name" AST node\n'+underlineNode(e,t));e.childCount>1&&r.push(["extra-command_name-children",'expected "command_name" node to only have one child but it has '+e.childCount]);const s=e.firstChild,n=toWord(s,t,r),o=n.toString(),a=firstShellToken(n);if(a){if("$curl"!==o)throw new CCError("expected command name to be a simple value but found a "+a.type+"\n"+underlineNode(a.syntaxNode,t))}else if("curl"!==o.trim()){const e=o.trim();if(!e)throw new CCError("found command without a command_name\n"+underlineNode(s,t));throw new CCError('command should begin with "curl" but instead begins with '+JSON.stringify(clip(e))+"\n"+underlineNode(s,t))}return n}function tokenize(e,t=[]){const r=webParser_default.parse(e);warnAboutBadNodes(r,e,t);const s=extractCommandNodes(r,e,t),n=[];for(const[o,a,i]of s){const[r,s]=toNameAndArgv(o,e,t);n.push([[nameToWord(r,e,t),...s.map((r=>toWord(r,e,t)))],a,i])}return n}function pickAuth(e){if(-17===e)return"basic";const t=[[4,"negotiate"],[64,"bearer"],[2,"digest"],[8,"ntlm"],[32,"ntlm-wb"],[1,"basic"],[128,"aws-sigv4"]];for(const[r,s]of t)if(e&r)return s;return"none"}function toBoolean(e){return!!e.startsWith("no-disable-")||!e.startsWith("disable-")&&!e.startsWith("no-")}function checkSupported(e,t,r,s){s&&!s.has(r.name)&&warnf(e,[r.name,t+" is not a supported option"+(r.removed?", it was removed in curl "+r.removed:"")])}function pushProp(e,t,r){return Object.prototype.hasOwnProperty.call(e,t)||(e[t]=[]),e[t].push(r),e}function pushArgValue(e,t,r,s){switch(r){case"data":case"data-ascii":return pushProp(t,"data",["data",s]);case"data-binary":return pushProp(t,"data",[s.startsWith("@")?"binary":"data",s]);case"data-raw":return pushProp(t,"data",[s.startsWith("@")?"raw":"data",s]);case"data-urlencode":return pushProp(t,"data",["urlencode",s]);case"json":return t.json=!0,pushProp(t,"data",["json",s]);case"url-query":return s.startsWith("+")?pushProp(t,"url-query",["raw",s.slice(1)]):pushProp(t,"url-query",["urlencode",s]);case"form":return pushProp(t,"form",{value:s,type:"form"});case"form-string":return pushProp(t,"form",{value:s,type:"string"});case"aws-sigv4":t.authtype|=128;break;case"oauth2-bearer":t.authtype|=64;break;case"unix-socket":case"abstract-unix-socket":pushProp(t,"unix-socket",s);break;case"trace":case"trace-ascii":case"stderr":case"libcurl":case"config":case"parallel-max":e[r]=s;break;case"language":return void(e[r]=s.toString())}return pushProp(t,r,s)}function setArgValue(e,t,r,s){switch(r){case"digest":s?t.authtype|=2:t.authtype&=-3;break;case"proxy-digest":s?t.proxyauthtype|=2:t.proxyauthtype&=-3;break;case"negotiate":s?t.authtype|=4:t.authtype&=-5;break;case"proxy-negotiate":s?t.proxyauthtype|=4:t.proxyauthtype&=-5;break;case"ntlm":s?t.authtype|=8:t.authtype&=-9;break;case"proxy-ntlm":s?t.proxyauthtype|=8:t.proxyauthtype&=-9;break;case"ntlm-wb":s?t.authtype|=32:t.authtype&=-33;break;case"basic":s?t.authtype|=1:t.authtype&=-2;break;case"proxy-basic":s?t.proxyauthtype|=1:t.proxyauthtype&=-2;break;case"anyauth":s&&(t.authtype=-17);break;case"proxy-anyauth":s&&(t.proxyauthtype=-17);break;case"location":t.location=s;break;case"location-trusted":t.location=s,t["location-trusted"]=s;break;case"http1.0":t.httpVersion="1.0";break;case"http1.1":t.httpVersion="1.1";break;case"http2":t.httpVersion="2";break;case"http2-prior-knowledge":t.httpVersion="2-prior-knowledge";break;case"http3":t.httpVersion="3";break;case"http3-only":t.httpVersion="3-only";break;case"tlsv1":t.tlsVersion="1";break;case"tlsv1.0":t.tlsVersion="1.0";break;case"tlsv1.1":t.tlsVersion="1.1";break;case"tlsv1.2":t.tlsVersion="1.2";break;case"tlsv1.3":t.tlsVersion="1.3";break;case"verbose":case"version":case"trace-time":case"test-event":case"progress-bar":case"progress-meter":case"fail-early":case"styled-output":case"help":case"silent":case"show-error":case"parallel":case"parallel-immediate":case"stdin":e[r]=s;break;case"next":s&&t.url&&t.url.length>0&&t.url.length>=(t["upload-file"]||[]).length&&t.url.length>=(t.output||[]).length&&(t={authtype:1,proxyauthtype:1},e.configs.push(t));break;default:t[r]=s}return t}function parseArgs(e,t=curlLongOpts,r=curlLongOptsShortened,s=curlShortOpts,n,o=[]){let a={authtype:1,proxyauthtype:1};const i={configs:[a],warnings:o},l=[];for(let _=1,u=!0;_<e.length;_++){const p=e[_];if(u&&p.startsWith("-"))if(eq(p,"--"))u=!1;else if(p.startsWith("--")){const s=firstShellToken(p);if(s)throw new CCError("this "+s.type+" could "+("command"===s.type?"return":"be")+" anything\n"+underlineNode(s.syntaxNode));const o=p.toString(),u=o.slice(2);let c=r[u];if(void 0===c&&(c=t[u]),null===c)throw new CCError("option "+o+": is ambiguous");if(void 0===c)throw new CCError("option "+o+": is unknown");if("string"===c.type){if(_++,_>=e.length)throw new CCError("option "+o+": requires parameter");pushArgValue(i,a,c.name,e[_])}else a=setArgValue(i,a,c.name,toBoolean(o.slice(2)));checkSupported(i,o,c,n),l.push([c.name,o])}else{if(1===p.length){if(!Object.prototype.hasOwnProperty.call(s,""))throw new CCError("option -: is unknown");{const e=s[""],r=t[e];if(null===r)throw new CCError("option -: is unknown");a=setArgValue(i,a,r.name,toBoolean(e)),l.push([r.name,"-"])}}for(let r=1;r<p.length;r++){const o=p.get(r);if("string"!=typeof o)throw new CCError("this "+o.type+" could "+("command"===o.type?"return":"be")+" anything\n"+underlineNode(o.syntaxNode));if(!has(s,o)){if(has(changedShortOpts,o))throw new CCError("option "+p+": "+changedShortOpts[o]);throw new CCError("option "+p+": is unknown")}const u=o,c=s[u],d=t[c];if(null===d)throw new CCError("ambiguous short option -"+o);if("string"===d.type){let t;if(r+1<p.length)t=p.slice(r+1),r=p.length;else{if(!(_+1<e.length))throw new CCError("option "+p.toString()+": requires parameter");_++,t=e[_]}pushArgValue(i,a,d.name,t)}else a=setArgValue(i,a,d.name,toBoolean(c));u&&(checkSupported(i,"-"+u,d,n),l.push([d.name,"-"+u]))}}else{if("string"!=typeof p&&p.tokens.length&&"string"!=typeof p.tokens[0]){const e=1===p.tokens.length?"is":"begins with";o.push(["ambiguous argument","argument "+e+" a "+p.tokens[0].type+", assuming it's a URL\n"+underlineNode(p.tokens[0].syntaxNode)])}pushArgValue(i,a,"url",p),l.push(["url","--url"])}}for(const _ of i.configs)for(const[e,t]of Object.entries(_))Array.isArray(t)&&!canBeList.has(e)&&(_[e]=t[t.length-1]);return[i,l]}function parseCookiesStrict(e){const t=[];for(let r of e.split(";")){r=r.replace(/^ /,"");const[e,s]=r.split("=",2);if(void 0===s)return null;t.push([e,s])}return new Set(t.map((e=>e[0]))).size!==t.length?null:t}function parseCookies(e){const t=[];for(let r of e.split(";")){if(r=r.trim(),!r)continue;const[e,s]=r.split("=",2);t.push([e.trim(),(s||"").trim()])}return new Set(t.map((e=>e[0]))).size!==t.length?null:t}function isIpv6(e){return!(e.length>MAX_IP6LEN)&&!e.includes("-")}function warnAboutGlobs(e,t){let r="";for(let s=0;s<t.length;s++){const n=t[s];if("["===n&&"\\"!==r){let n=s+1;for(;n<t.length&&"]"!==t[n];)n++;if(!(n<t.length&&"]"===t[n]))return void warnf(e,["unbalanced-glob",`bracket doesn't have a closing bracket:\n${t}\n${" ".repeat(s)}^`]);{const o=t.slice(s,n+1);isIpv6(o)||warnf(e,["glob-in-url",`globs in the URL are not supported:\n${t}\n`+" ".repeat(s)+"^".repeat(o.length)]),r=""}}else if("{"===n&&"\\"!==r){let n=s+1;for(;n<t.length&&"}"!==t[n];)n++;if(!(n<t.length&&"}"===t[n]))return void warnf(e,["unbalanced-glob",`bracket doesn't have a closing bracket:\n${t}\n${" ".repeat(s)}^`]);{const o=t.slice(s,n+1);warnf(e,["glob-in-url",`globs in the URL are not supported:\n${t}\n`+" ".repeat(s)+"^".repeat(o.length)]),r=""}}r=n}}function parseurl(e,t,r){var s;const n={scheme:new Word,host:new Word,port:new Word,path:new Word,query:new Word,fragment:new Word};t.globoff||(r.isString()&&warnAboutGlobs(e,r.toString()),r=r.replace(/\\([[\]{}])/g,"$1"));let o=null;if(r.tokens.length&&"string"==typeof r.tokens[0]&&(o=r.tokens[0].match(/^([a-zA-Z0-9+-.]*):\/\/*/)),o){const[e,t]=o;n.scheme=new Word(t.toLowerCase()),r=r.slice(e.length)}else n.scheme=null!==(s=t["proto-default"])&&void 0!==s?s:new Word("http");eq(n.scheme,"http")||eq(n.scheme,"https")||warnf(e,["bad-scheme",`Protocol "${n.scheme}" not supported`]);const a=r.indexOfFirstChar("/?#");if(-1!==a){n.host=r.slice(0,a),n.path=r.slice(a);const e=n.path.indexOf("#"),t=n.path.indexOf("?");-1!==e?(n.fragment=n.path.slice(e),-1!==t&&t<e?(n.query=n.path.slice(t,e),n.path=n.path.slice(0,t)):n.path=n.path.slice(0,e)):-1!==t&&(n.query=n.path.slice(t),n.path=n.path.slice(0,t))}else n.host=r;const i=n.host.indexOf("@");if(-1!==i){const r=n.host.slice(0,i);n.host=n.host.slice(i+1),t["disallow-username-in-url"]?warnf(e,["login-denied",`Found auth in URL but --disallow-username-in-url was passed: ${r.toString()}`]):(n.auth=r,r.includes(":")?[n.user,n.password]=r.split(":",2):(n.user=r,n.password=new Word))}return n}function _percentEncode(e){return[...UTF8encoder.encode(e)].map((e=>e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||45===e||46===e||95===e||126===e?String.fromCharCode(e):"%"+e.toString(16).toUpperCase().padStart(2,"0"))).join("")}function percentEncode(e){const t=[];for(const r of e.tokens)"string"==typeof r?t.push(_percentEncode(r)):t.push(r);return new Word(t)}function percentEncodePlus(e){const t=[];for(const r of e.tokens)"string"==typeof r?t.push(_percentEncode(r).replace(/%20/g,"+")):t.push(r);return new Word(t)}function wordDecodeURIComponent(e){const t=[];for(const r of e.tokens)"string"==typeof r?t.push(decodeURIComponent(r)):t.push(r);return new Word(t)}function parseQueryString(e){if(!e||e.isEmpty())return[null,null];const t=[];for(const i of e.split("&")){if(!i.includes("="))return[null,null];const[e,r]=i.split("=",2);let s,n;try{s=wordDecodeURIComponent(e.replace(/\+/g," ")),n=wordDecodeURIComponent(r.replace(/\+/g," "))}catch(a){if(a instanceof URIError)return[null,null];throw a}const o=percentEncode(s),l=percentEncode(n);if(!eq(o,e)&&!eq(o.replace(/%20/g,"+"),e)||!eq(l,r)&&!eq(l.replace(/%20/g,"+"),r))return[null,null];t.push([s,n])}const r={},s={};let n=null;for(const[i,l]of t){const e=i.toString();if(n===e)s[e].push(l);else{if(Object.prototype.hasOwnProperty.call(s,e))return[t,null];s[e]=[l],r[e]=i}n=e}const o=[];for(const[i,l]of Object.entries(s))o.push([r[i],1===l.length?l[0]:l]);return[t,o]}function parseDetails(e,t,r,s,n){for(;r<t.length&&";"===t.charAt(r);){for(r+=1;r<t.length&&isSpace(t.charAt(r));)r+=1;if(r>=t.length)return e;const o=t.slice(r);if(o.startsWith("type="))[e.contentType,r]=getParamWord(t,r+5,n);else if(o.startsWith("filename=")){const[o,a]=getParamWord(t,r+9,n);r=a,s.filename?e.filename=o:n.push(["unsupported-form-detail","Field file name not allowed here: "+o.toString()])}else if(o.startsWith("encoder=")){const[o,a]=getParamWord(t,r+8,n);r=a,s.encoder?e.encoder=o:n.push(["unsupported-form-detail","Field encoder not allowed here: "+o.toString()])}else if(o.startsWith("headers=")){const[o,a]=getParamWord(t,r+8,n);r=a,s.headers?o.startsWith("@")?(void 0===e.headerFiles&&(e.headerFiles=[]),e.headerFiles.push(o.slice(1))):(void 0===e.headers&&(e.headers=[]),e.headers.push(o)):n.push(["unsupported-form-detail","Field headers not allowed here: "+o.toString()])}else r=getParamWord(t,r,n)[1],n.push(["unknown-form-detail","skip unknown form field: "+o.toString()])}return e}function isSpace(e){return"string"==typeof e&&(" "===e||"\t"===e||e>="\n"&&e<="\r")}function getParamWord(e,t,r){let s=t;if('"'===e.charAt(s)){s+=1;const t=[];for(;s<e.length;){let n=e.charAt(s);if("\\"===n){if(s+1<e.length){const t=e.charAt(s+1);'"'!==t&&"\\"!==t||(s+=1,n=e.charAt(s))}}else if('"'===n){s+=1;let n=!1;for(;s<e.length&&";"!==e.charAt(s);)isSpace(e.charAt(s))||(n=!0),s+=1;return n&&r.push(["trailing-form-data","Trailing data after quoted form parameter"]),[new Word(t),s]}t.push(n),s+=1}}let n=e.indexOf(";",t);return-1===n&&(n=e.length),[e.slice(t,n),n]}function getParamPart(e,t,r,s,n){for(;r<t.length&&isSpace(t.charAt(r));)r+=1;const[o,a]=getParamWord(t,r,n);return e.content=o,parseDetails(e,t,a,s,n),e}function parseForm(e,t){const r=[];let s=0;for(const n of e){const e="string"===n.type;if(!n.value.includes("="))throw new CCError('invalid value for --form/-F, missing "=": '+JSON.stringify(n.value.toString()));const[o,a]=n.value.split("=",2),i={name:o};if(e||"("!==a.charAt(0))if(!e&&0===o.length&&eq(a,")")){if(s-=1,s<0)throw new CCError("no multipart to terminate: "+JSON.stringify(n.value.toString()))}else e||"@"!==a.charAt(0)?e||"<"!==a.charAt(0)?e?i.content=a:getParamPart(i,a,0,{filename:!0,encoder:!0,headers:!0},t):(getParamPart(i,a,1,{encoder:!0,headers:!0},t),i.contentFile=i.content,delete i.content,null===i.contentType||i.contentType):(getParamPart(i,a,1,{filename:!0,encoder:!0,headers:!0},t),i.contentFile=i.content,delete i.content,null!==i.filename&&void 0!==i.filename||(i.filename=i.contentFile),null===i.contentType||i.contentType);else s+=1,t.push(["nested-form",'Nested form data with "=(" is not supported, it will be flattened']),getParamPart(i,a,1,{headers:!0},t);r.push(i)}return r}function buildURL(e,t,r,s,n,o,a){const i=r,l=parseurl(e,t,r);s&&(l.path.isEmpty()?l.path=s.prepend("/"):l.path.endsWith("/")&&(l.path=l.path.add(s)),t.get&&warnf(e,["data-ignored","curl doesn't let you pass --get and --upload-file together"]));const _=mergeWords(l.scheme,"://",l.host,l.path,l.query,l.fragment);let u=null,p=null,c=null;if(l.query.toBool()||t["url-query"]&&t["url-query"].length){let e=null,r=[];l.query.toBool()&&(r.push(["raw",l.query.slice(1)]),[p,e,c]=buildData(r,o,a),u=p),t["url-query"]&&(r=r.concat(t["url-query"]),[p,e,c]=buildData(r,o,a)),l.query=new Word,e&&e.toBool()&&(l.query=e.prepend("?"))}const d=mergeWords(l.scheme,"://",l.host,l.path,l.fragment);let m=r=mergeWords(l.scheme,"://",l.host,l.path,l.query,l.fragment),[h,y]=parseQueryString(l.query.toBool()?l.query.slice(1):new Word);h&&h.length?m=mergeWords(l.scheme,"://",l.host,l.path,l.fragment):(h=null,y=null);let g=new Word("GET");t.request&&!eq(t.request,"null")?g=t.request:t.head?g=new Word("HEAD"):s&&s.toBool()?g=new Word("PUT"):t.get||!has(t,"data")&&!has(t,"form")||(g=new Word("POST"));const f={originalUrl:i,urlWithoutQueryList:m,url:r,urlObj:l,urlWithOriginalQuery:_,urlWithoutQueryArray:d,method:g};c&&(f.queryReadsFile=c),h&&(f.queryList=h,y&&(f.queryDict=y)),p&&(f.queryArray=p),u&&(f.urlQueryArray=u),s&&(eq(s,"-")||eq(s,".")?a?f.uploadFile=a:o?(warnf(e,["upload-file-with-stdin-content","--upload-file with stdin content is not supported"]),f.uploadFile=s):f.uploadFile=s:f.uploadFile=s),n&&(f.output=n);const w=t.user||l.auth;if(w){const[e,t]=w.split(":",2);f.auth=[e,t||new Word]}return f}function buildData(e,t,r){const s=[];let n=new Word;for(const[a,i]of e.entries()){const e=i[0];let o=i[1],l=null;if(a>0&&"json"!==e&&(n=n.append("&")),"urlencode"===e){const e=o.includes("=")||!o.includes("@")?"=":"@";if((o.includes("@")||o.includes("="))&&([l,o]=o.split(e,2)),"="===e){l&&l.toBool()&&(n=n.add(l).append("=")),n=n.add(percentEncodePlus(o));continue}l=l&&l.toBool()?l:null,o=o.prepend("@")}let _=null;if("raw"!==e&&o.startsWith("@")&&(_=o.slice(1),eq(_,"-")))if(void 0!==t){switch(e){case"binary":case"json":o=t;break;case"urlencode":o=mergeWords(l&&l.length?l.append("="):new Word,percentEncodePlus(t));break;default:o=t.replace(/[\n\r]/g,"")}_=null}else void 0!==r&&(_=r);if(null!==_){n.toBool()&&(s.push(n),n=new Word);const t={filetype:e,filename:_};l&&(t.name=l),s.push(t)}else n=n.add(o)}n.toBool()&&s.push(n);let o=null;return[s,mergeWords(...s.map((e=>e instanceof Word?e:(o||(o=e.filename.toString()),e.name?mergeWords(e.name,"=@",e.filename):e.filename.prepend("@"))))),o]}function parseContentType(e){if(!e.includes(";"))return[e,[]];const t=e.indexOf(";"),r=e.slice(0,t),s=e.slice(t),n=s.match(/;\s*([^;=]+)=(?:("[^"]*")|([^()<>@,;:\\"/[\]?.=]*))/g);if(s.trim()&&!n)return null;const o=[];for(const a of n||[]){const e=a.match(/;\s*([^;=]+)=(?:("[^"]*")|([^()<>@,;:\\"/[\]?.=]*))/);if(!e)return null;const t=e[1],r=e[3]||e[2].slice(1,-1);o.push([t,r])}return[r,o]}function parseBoundary(e){const t=parseContentType(e);if(!t)return null;for(const[r,s]of t[1])if("boundary"===r)return s;return null}function parseRawForm(e,t){const r="\r\n--"+t+"--\r\n";if(!e.endsWith(r))return null;if(t="--"+t+"\r\n",(e=e.slice(0,-r.length))&&!e.startsWith(t))return null;const s=(e=e.slice(t.length)).split("\r\n"+t),n=[];let o=!0;for(const a of s){const e=a.split("\r\n");if(e.length<2)return null;const t={name:new Word,content:new Word};let r=!1;const s=[];let i=0;for(;i<e.length&&0!==e[i].length;i++){const[n,a]=e[i].split(": ",2);if(void 0===n||void 0===a)return null;if("content-disposition"===n.toLowerCase()){if(r)return null;const e=parseContentType(a);if(!e)return null;const[s,n]=e;if("form-data"!==s)return null;let i=0;for(const[r,o]of n)switch(r){case"name":t.name=new Word(o);break;case"filename":t.filename=new Word(o);break;default:i++}i&&(o=!1),r=!0}else"content-type"===n.toLowerCase()?t.contentType=new Word(a):s.push(new Word(e[i]))}if(s.length&&(t.headers=s),!r)return null;if(i===e.length)return null;if(t.name.isEmpty())return null;t.content=new Word(e.slice(i+1).join("\n")),n.push(t)}return[n,o]}function buildRequest(e,t,r,s){var n,o;if(!t.url||!t.url.length)throw new CCError("no URL specified!");const a=new Headers(t.header,e.warnings),i=new Headers(t["proxy-header"],e.warnings,"--proxy-header");let l;const _=[],u=a.get("cookie");if(u){const e=parseCookiesStrict(u);e&&(l=e)}else if(void 0===u&&t.cookie){const e=[];for(const r of t.cookie)r.includes("=")?e.push(r):_.push(r);if(e.length){const e=joinWords(t.cookie,"; ");a.setIfMissing("Cookie",e);const r=parseCookies(e);r&&(l=r)}}let p,c,d,m,h=!1;if(t["user-agent"]&&a.setIfMissing("User-Agent",t["user-agent"]),t.referer){t.referer.includes(";auto")&&(h=!0);const e=t.referer.replace(/;auto$/,"");e.length&&a.setIfMissing("Referer",e)}if(t.range){let e=t.range.prepend("bytes=");e.includes("-")||(e=e.append("-")),a.setIfMissing("Range",e)}if(t["time-cond"]){let e=t["time-cond"],r="If-Modified-Since";switch(e.charAt(0)){case"+":e=e.slice(1);break;case"-":e=e.slice(1),r="If-Unmodified-Since";break;case"=":e=e.slice(1),r="Last-Modified"}a.setIfMissing(r,e)}t.data&&t.data.length&&(t.get?(t["url-query"]=t.data,delete t.data):[p,c,d]=buildData(t.data,r,s)),t["url-query"]&&([m]=buildData(t["url-query"],r,s));const y=[],g=t["upload-file"]||[],f=t.output||[];for(const[T,S]of t.url.entries())y.push(buildURL(e,t,S,g[T],f[T],r,s));t.get&&t.data&&delete t.data,(t["upload-file"]||[]).length>t.url.length&&warnf(e,["too-many-upload-files","Got more --upload-file/-T options than URLs: "+(null===(n=t["upload-file"])||void 0===n?void 0:n.map((e=>JSON.stringify(e.toString()))).join(", "))]),(t.output||[]).length>t.url.length&&warnf(e,["too-many-output-files","Got more --output/-o options than URLs: "+(null===(o=t.output)||void 0===o?void 0:o.map((e=>JSON.stringify(e.toString()))).join(", "))]);const w={urls:y,authType:pickAuth(t.authtype),proxyAuthType:pickAuth(t.proxyauthtype),headers:a,proxyHeaders:i};r&&(w.stdin=r),s&&(w.stdinFile=s),Object.prototype.hasOwnProperty.call(t,"globoff")&&(w.globoff=t.globoff),Object.prototype.hasOwnProperty.call(t,"disallow-username-in-url")&&(w.disallowUsernameInUrl=t["disallow-username-in-url"]),Object.prototype.hasOwnProperty.call(t,"path-as-is")&&(w.pathAsIs=t["path-as-is"]),h&&(w.refererAuto=!0),l&&(w.cookies=l),_.length&&(w.cookieFiles=_),t["cookie-jar"]&&(w.cookieJar=t["cookie-jar"]),Object.prototype.hasOwnProperty.call(t,"junk-session-cookies")&&(w.junkSessionCookies=t["junk-session-cookies"]),Object.prototype.hasOwnProperty.call(t,"compressed")&&(w.compressed=t.compressed),Object.prototype.hasOwnProperty.call(t,"tr-encoding")&&(w.transferEncoding=t["tr-encoding"]),t.include&&(w.include=!0),t.json?(a.setIfMissing("Content-Type","application/json"),a.setIfMissing("Accept","application/json")):t.data?a.setIfMissing("Content-Type","application/x-www-form-urlencoded"):t.form&&(w.multipartUploads=parseForm(t.form,e.warnings));const b=a.getContentType(),E=a.get("Content-Type");if(t.data&&!d&&c&&c.isString()&&!t.form&&!w.multipartUploads&&"multipart/form-data"===b&&E&&E.isString()){const e=parseBoundary(E.toString());if(e){const t=parseRawForm(c.toString(),e);if(t){const[e,r]=t;w.multipartUploads=e,r||(w.multipartUploadsDoesntRoundtrip=!0)}}}if(Object.prototype.hasOwnProperty.call(t,"form-escape")&&(w.formEscape=t["form-escape"]),t["aws-sigv4"]&&(w.authType="aws-sigv4",w.awsSigV4=t["aws-sigv4"]),"bearer"===w.authType&&t["oauth2-bearer"]){const e=t["oauth2-bearer"].prepend("Bearer ");a.setIfMissing("Authorization",e),w.oauth2Bearer=t["oauth2-bearer"]}if(t.delegation&&(w.delegation=t.delegation),t.krb&&(w.krb=t.krb),t["sasl-authzid"]&&(w.saslAuthzid=t["sasl-authzid"]),Object.prototype.hasOwnProperty.call(t,"sasl-ir")&&(w.saslIr=t["sasl-ir"]),t.negotiate&&(w.authType="negotiate"),t["service-name"]&&(w.serviceName=t["service-name"]),a.clearNulls(),t.data&&t.data.length&&(w.data=c,d&&(w.dataReadsFile=d),w.dataArray=p,w.isDataRaw=!1,w.isDataBinary=(p||[]).some((e=>!(e instanceof Word)&&"binary"===e.filetype))),m&&(w.queryArray=m),Object.prototype.hasOwnProperty.call(t,"ipv4")&&(w.ipv4=t.ipv4),Object.prototype.hasOwnProperty.call(t,"ipv6")&&(w.ipv6=t.ipv6),t.proto&&(w.proto=t.proto),t["proto-redir"]&&(w.protoRedir=t["proto-redir"]),t["proto-default"]&&(w.protoDefault=t["proto-default"]),t["tcp-fastopen"]&&(w.tcpFastopen=t["tcp-fastopen"]),t["local-port"]){const[e,r]=t["local-port"].split("-",1);r&&r.toBool()?w.localPort=[e,r]:w.localPort=[t["local-port"],null]}if(Object.prototype.hasOwnProperty.call(t,"ignore-content-length")&&(w.ignoreContentLength=t["ignore-content-length"]),t.interface&&(w.interface=t.interface),t.ciphers&&(w.ciphers=t.ciphers),t.curves&&(w.curves=t.curves),t.insecure&&(w.insecure=!0),Object.prototype.hasOwnProperty.call(t,"cert-status")&&(w.certStatus=t["cert-status"]),t.cert)if(t.cert.startsWith("pkcs11:")||!t.cert.match(/[:\\]/))w.cert=[t.cert,null];else{let e=-1;try{e=t.cert.search(/(?<!\\)(?:\\\\)*:/)}catch(x){e=t.cert.search(/:/)}if(-1===e)w.cert=[t.cert,null];else{const r=t.cert.slice(0,e),s=t.cert.slice(e+1);s.toBool()?w.cert=[r,s]:w.cert=[r,null]}}if(t["cert-type"]){const r=t["cert-type"];w.certType=r,r.isString()&&!["PEM","DER","ENG","P12"].includes(r.toString().toUpperCase())&&warnf(e,["cert-type-unknown","not supported file type "+JSON.stringify(r.toString())+" for certificate"])}return t.key&&(w.key=t.key),t["key-type"]&&(w.keyType=t["key-type"]),t.pass&&(w.pass=t.pass),t.cacert&&(w.cacert=t.cacert),Object.prototype.hasOwnProperty.call(t,"ca-native")&&(w.caNative=t["ca-native"]),Object.prototype.hasOwnProperty.call(t,"ssl-allow-beast")&&(w.sslAllowBeast=t["ssl-allow-beast"]),t.capath&&(w.capath=t.capath),t.crlfile&&(w.crlfile=t.crlfile),t.pinnedpubkey&&(w.pinnedpubkey=t.pinnedpubkey),t["random-file"]&&(w.randomFile=t["random-file"]),t["egd-file"]&&(w.egdFile=t["egd-file"]),t.hsts&&(w.hsts=t.hsts),Object.prototype.hasOwnProperty.call(t,"alpn")&&(w.alpn=t.alpn),t.tlsVersion&&(w.tlsVersion=t.tlsVersion),t["tls-max"]&&(w.tlsMax=t["tls-max"]),t["tls13-ciphers"]&&(w.tls13Ciphers=t["tls13-ciphers"]),t.tlsauthtype&&(w.tlsauthtype=t.tlsauthtype),t.tlspassword&&(w.tlspassword=t.tlspassword),t.tlsuser&&(w.tlsuser=t.tlsuser),Object.prototype.hasOwnProperty.call(t,"ssl-allow-beast")&&(w.sslAllowBeast=t["ssl-allow-beast"]),Object.prototype.hasOwnProperty.call(t,"ssl-auto-client-cert")&&(w.sslAutoClientCert=t["ssl-auto-client-cert"]),Object.prototype.hasOwnProperty.call(t,"ssl-no-revoke")&&(w.sslNoRevoke=t["ssl-no-revoke"]),Object.prototype.hasOwnProperty.call(t,"ssl-reqd")&&(w.sslReqd=t["ssl-reqd"]),Object.prototype.hasOwnProperty.call(t,"ssl-revoke-best-effort")&&(w.sslRevokeBestEffort=t["ssl-revoke-best-effort"]),Object.prototype.hasOwnProperty.call(t,"ssl")&&(w.ssl=t.ssl),Object.prototype.hasOwnProperty.call(t,"sslv2")&&(w.sslv2=t.sslv2),Object.prototype.hasOwnProperty.call(t,"sslv3")&&(w.sslv3=t.sslv3),t["doh-url"]&&(w.dohUrl=t["doh-url"]),Object.prototype.hasOwnProperty.call(t,"doh-insecure")&&(w.dohInsecure=t["doh-insecure"]),Object.prototype.hasOwnProperty.call(t,"doh-cert-status")&&(w.dohCertStatus=t["doh-cert-status"]),t.proxy&&(w.proxy=t.proxy,w.proxyType&&"http2"!==w.proxyType&&delete w.proxyType,t["proxy-user"]&&(w.proxyAuth=t["proxy-user"])),Object.prototype.hasOwnProperty.call(t,"proxytunnel")&&(w.proxytunnel=t.proxytunnel),t.noproxy&&(w.noproxy=t.noproxy),t.preproxy&&(w.preproxy=t.preproxy),Object.prototype.hasOwnProperty.call(t,"proxy-anyauth")&&(w.proxyAnyauth=t["proxy-anyauth"]),Object.prototype.hasOwnProperty.call(t,"proxy-basic")&&(w.proxyBasic=t["proxy-basic"]),Object.prototype.hasOwnProperty.call(t,"proxy-digest")&&(w.proxyDigest=t["proxy-digest"]),Object.prototype.hasOwnProperty.call(t,"proxy-negotiate")&&(w.proxyNegotiate=t["proxy-negotiate"]),Object.prototype.hasOwnProperty.call(t,"proxy-ntlm")&&(w.proxyNtlm=t["proxy-ntlm"]),Object.prototype.hasOwnProperty.call(t,"proxy-ca-native")&&(w.proxyCaNative=t["proxy-ca-native"]),t["proxy-cacert"]&&(w.proxyCacert=t["proxy-cacert"]),t["proxy-capath"]&&(w.proxyCapath=t["proxy-capath"]),t["proxy-cert-type"]&&(w.proxyCertType=t["proxy-cert-type"]),t["proxy-cert"]&&(w.proxyCert=t["proxy-cert"]),t["proxy-ciphers"]&&(w.proxyCiphers=t["proxy-ciphers"]),t["proxy-crlfile"]&&(w.proxyCrlfile=t["proxy-crlfile"]),t["proxy-http2"]&&(w.proxyType="http2"),t["proxy1.0"]&&(w.proxy=t["proxy1.0"],w.proxyType="http1"),Object.prototype.hasOwnProperty.call(t,"proxy-insecure")&&(w.proxyInsecure=t["proxy-insecure"]),t["proxy-key"]&&(w.proxyKey=t["proxy-key"]),t["proxy-key-type"]&&(w.proxyKeyType=t["proxy-key-type"]),t["proxy-pass"]&&(w.proxyPass=t["proxy-pass"]),t["proxy-pinnedpubkey"]&&(w.proxyPinnedpubkey=t["proxy-pinnedpubkey"]),t["proxy-pinnedpubkey"]&&(w.proxyPinnedpubkey=t["proxy-pinnedpubkey"]),t["proxy-service-name"]&&(w.proxyServiceName=t["proxy-service-name"]),Object.prototype.hasOwnProperty.call(t,"proxy-ssl-allow-beast")&&(w.proxySslAllowBeast=t["proxy-ssl-allow-beast"]),Object.prototype.hasOwnProperty.call(t,"proxy-ssl-auto-client-cert")&&(w.proxySslAutoClientCert=t["proxy-ssl-auto-client-cert"]),t["proxy-tls13-ciphers"]&&(w.proxyTls13Ciphers=t["proxy-tls13-ciphers"]),t["proxy-tlsauthtype"]&&(w.proxyTlsauthtype=t["proxy-tlsauthtype"],w.proxyTlsauthtype.isString()&&!eq(w.proxyTlsauthtype,"SRP")&&warnf(e,["proxy-tlsauthtype","proxy-tlsauthtype is not supported: "+w.proxyTlsauthtype])),t["proxy-tlspassword"]&&(w.proxyTlspassword=t["proxy-tlspassword"]),t["proxy-tlsuser"]&&(w.proxyTlsuser=t["proxy-tlsuser"]),Object.prototype.hasOwnProperty.call(t,"proxy-tlsv1")&&(w.proxyTlsv1=t["proxy-tlsv1"]),t["proxy-user"]&&(w.proxyUser=t["proxy-user"]),Object.prototype.hasOwnProperty.call(t,"proxytunnel")&&(w.proxytunnel=t.proxytunnel),t.socks4&&(w.proxy=t.socks4,w.proxyType="socks4"),t.socks4a&&(w.proxy=t.socks4a,w.proxyType="socks4a"),t.socks5&&(w.proxy=t.socks5,w.proxyType="socks5"),t["socks5-hostname"]&&(w.proxy=t["socks5-hostname"],w.proxyType="socks5-hostname"),Object.prototype.hasOwnProperty.call(t,"socks5-basic")&&(w.socks5Basic=t["socks5-basic"]),Object.prototype.hasOwnProperty.call(t,"socks5-gssapi-nec")&&(w.socks5GssapiNec=t["socks5-gssapi-nec"]),t["socks5-gssapi-service"]&&(w.socks5GssapiService=t["socks5-gssapi-service"]),Object.prototype.hasOwnProperty.call(t,"socks5-gssapi")&&(w.socks5Gssapi=t["socks5-gssapi"]),t["haproxy-clientip"]&&(w.haproxyClientIp=t["haproxy-clientip"]),Object.prototype.hasOwnProperty.call(t,"haproxy-protocol")&&(w.haproxyProtocol=t["haproxy-protocol"]),t["max-time"]&&(w.timeout=t["max-time"],t["max-time"].isString()&&isNaN(parseFloat(t["max-time"].toString()))&&warnf(e,["max-time-not-number","option --max-time: expected a proper numerical parameter: "+JSON.stringify(t["max-time"].toString())])),t["connect-timeout"]&&(w.connectTimeout=t["connect-timeout"],t["connect-timeout"].isString()&&isNaN(parseFloat(t["connect-timeout"].toString()))&&warnf(e,["connect-timeout-not-number","option --connect-timeout: expected a proper numerical parameter: "+JSON.stringify(t["connect-timeout"].toString())])),t["expect100-timeout"]&&(w.expect100Timeout=t["expect100-timeout"],t["expect100-timeout"].isString()&&isNaN(parseFloat(t["expect100-timeout"].toString()))&&warnf(e,["expect100-timeout-not-number","option --expect100-timeout: expected a proper numerical parameter: "+JSON.stringify(t["expect100-timeout"].toString())])),t["happy-eyeballs-timeout-ms"]&&(w.happyEyeballsTimeoutMs=t["happy-eyeballs-timeout-ms"]),t["speed-limit"]&&(w.speedLimit=t["speed-limit"]),t["speed-time"]&&(w.speedTime=t["speed-time"]),t["limit-rate"]&&(w.limitRate=t["limit-rate"]),t["max-filesize"]&&(w.maxFilesize=t["max-filesize"]),Object.prototype.hasOwnProperty.call(t,"keepalive")&&(w.keepAlive=t.keepalive),t["keepalive-time"]&&(w.keepAliveTime=t["keepalive-time"]),t["alt-svc"]&&(w.altSvc=t["alt-svc"]),Object.prototype.hasOwnProperty.call(t,"location")&&(w.followRedirects=t.location),t["location-trusted"]&&(w.followRedirectsTrusted=t["location-trusted"]),t["max-redirs"]&&(w.maxRedirects=t["max-redirs"].trim(),t["max-redirs"].isString()&&!isInt(t["max-redirs"].toString())&&warnf(e,["max-redirs-not-int","option --max-redirs: expected a proper numerical parameter: "+JSON.stringify(t["max-redirs"].toString())])),Object.prototype.hasOwnProperty.call(t,"post301")&&(w.post301=t.post301),Object.prototype.hasOwnProperty.call(t,"post302")&&(w.post302=t.post302),Object.prototype.hasOwnProperty.call(t,"post303")&&(w.post303=t.post303),t.fail&&(w.fail=t.fail),t.retry&&(w.retry=t.retry),t["retry-max-time"]&&(w.retryMaxTime=t["retry-max-time"]),Object.prototype.hasOwnProperty.call(t,"ftp-skip-pasv-ip")&&(w.ftpSkipPasvIp=t["ftp-skip-pasv-ip"]),t.httpVersion&&("2"!==t.httpVersion&&"2-prior-knowledge"!==t.httpVersion||(w.http2=!0),"3"!==t.httpVersion&&"3-only"!==t.httpVersion||(w.http3=!0),w.httpVersion=t.httpVersion),Object.prototype.hasOwnProperty.call(t,"http0.9")&&(w.http0_9=t["http0.9"]),t.resolve&&t.resolve.length&&(w.resolve=t.resolve),t["connect-to"]&&t["connect-to"].length&&(w.connectTo=t["connect-to"]),t["unix-socket"]&&(w.unixSocket=t["unix-socket"]),t["abstract-unix-socket"]&&(w.abstractUnixSocket=t["abstract-unix-socket"]),t["netrc-optional"]?w.netrc="optional":t.netrc||t["netrc-file"]?w.netrc="required":!1===t.netrc&&(w.netrc="ignored"),t["netrc-file"]&&(w.netrcFile=t["netrc-file"]),t["use-ascii"]&&(w.useAscii=t["use-ascii"]),t["continue-at"]&&(w.continueAt=t["continue-at"]),Object.prototype.hasOwnProperty.call(t,"crlf")&&(w.crlf=t.crlf),Object.prototype.hasOwnProperty.call(t,"clobber")&&(w.clobber=t.clobber),Object.prototype.hasOwnProperty.call(t,"remote-time")&&(w.remoteTime=t["remote-time"]),Object.prototype.hasOwnProperty.call(e,"verbose")&&(w.verbose=e.verbose),Object.prototype.hasOwnProperty.call(e,"silent")&&(w.silent=e.silent),w}function buildRequests(e,t,r){return e.configs.length||warnf(e,["no-configs","got empty config object"]),e.configs.map((s=>buildRequest(e,s,t,r)))}function getFirst(e,t,r){e.length>1&&t.push(["next","got "+e.length+" curl requests, only converting the first one"]);const s=e[0];return warnIfPartsIgnored(s,t,r),s}function clip(e,t=30){return e.length>t?e.slice(0,t-3)+"...":e}function findCommands(e,t){if("string"==typeof e)return tokenize(e,t);if(0===e.length)throw new CCError("no arguments provided");if("curl"!==e[0].trim())throw new CCError('command should begin with "curl" but instead begins with '+JSON.stringify(clip(e[0])));return[[e.map((e=>new Word(e))),void 0,void 0]]}function parse(e,t,r=[]){let s=[];const n=findCommands(e,r);for(const[o,a,i]of n){const[e]=parseArgs(o,curlLongOpts,curlLongOptsShortened,curlShortOpts,t,r);s=s.concat(buildRequests(e,a,i))}return s}function getDataString(e){if(!e.data)return{};const t=e.headers.getContentType();if("application/json"===t)try{return JSON.parse(e.data.toString())}catch(r){}if("application/x-www-form-urlencoded"===t){const[t,r]=parseQueryString(e.data);if(r)return Object.fromEntries(r.map((e=>[e[0].toString(),Array.isArray(e[1])?e[1].map((e=>e.toString())):e[1].toString()])));if(t)return Object.fromEntries(t.map((e=>[e[0].toString(),e[1].toString()])))}return e.data.toString()}function getFilesString(e){if(!e.multipartUploads)return;const t={files:{},data:{}};for(const r of e.multipartUploads)"contentFile"in r?t.files[r.name.toString()]=r.contentFile.toString():t.data[r.name.toString()]=r.content.toString();return{files:Object.keys(t.files).length?t.files:void 0,data:Object.keys(t.data).length?t.data:void 0}}function _toJsonObject(e,t=[]){const r=getFirst(e,t),s=r.urls[0],n={url:(s.queryDict?s.urlWithoutQueryList:s.url).toString().replace(/\/$/,""),raw_url:s.url.toString(),method:s.method.toLowerCase().toString()};if(r.cookies&&(n.cookies=Object.fromEntries(r.cookies.map((e=>[e[0].toString(),e[1].toString()])))),r.headers.length){const e=r.headers.headers.filter((e=>null!==e[1])).map((e=>[e[0].toString(),e[1].toString()]));n.headers=Object.fromEntries(e)}if(s.queryDict&&(n.queries=Object.fromEntries(s.queryDict.map((e=>[e[0].toString(),Array.isArray(e[1])?e[1].map((e=>e.toString())):e[1].toString()])))),r.data?n.data=getDataString(r):r.multipartUploads&&Object.assign(n,getFilesString(r)),r.compressed&&(n.compressed=!0),r.insecure&&(n.insecure=!1),r.include&&(n.include=!0),s.auth){const[e,t]=s.auth;n.auth={user:e.toString(),password:t.toString()},r.authType&&(n.auth_type=r.authType)}return r.awsSigV4&&(n.aws_sigv4=r.awsSigV4.toString()),r.delegation&&(n.delegation=r.delegation.toString()),Object.prototype.hasOwnProperty.call(r,"followRedirects")&&(n.follow_redirects=r.followRedirects,r.maxRedirects&&(n.max_redirects=parseInt(r.maxRedirects.toString(),10))),r.proxy&&(n.proxy=r.proxy.toString()),r.timeout&&(n.timeout=parseFloat(r.timeout.toString())),r.connectTimeout&&(n.connect_timeout=parseFloat(r.connectTimeout.toString())),s.output&&(n.output=s.output.toString()),n}function toJsonObjectWarn(e,t=[]){return[_toJsonObject(parse(e,supportedArgs$24,t),t),t]}function toJsonObject(e){return toJsonObjectWarn(e)[0]}function sanitizeCurlUrlPlaceholders(e){const t=e.match(/curl\s+(['"]?)(https?:\/\/[^\s'"]+)\1/);if(!t||!t[2])return e;const r=t[2],s=r.replaceAll(/<([A-Za-z0-9_-]+)>/g,"{$1}");return e.replace(r,s)}function useImportCurlCommand(e){const t=useToast(),r=useI18n(),s={invalidCurCommand:{title:"importCurlParameter.showError.invalidCurlCommand.title",message:"importCurlParameter.showError.invalidCurlCommand.message"},...e?.i18n};return{importCurlCommand:function(n){const o=unref(n);var a,i;if(""!==o)try{const s=flattenObject(toHttpNodeParameters(o),"parameters");assert("string"==typeof s["parameters.url"],"parameters.url has to be string");const n=s["parameters.url"].replaceAll("%7B","{").replaceAll("%7D","}"),l=CURL_IMPORT_NOT_SUPPORTED_PROTOCOLS.find((e=>n.includes(`${e}://`)));if(!l)return s["parameters.url"]=n,importCurlEventBus.emit("setHttpNodeParameters",s),void e?.onImportSuccess?.();if(CURL_IMPORT_NODES_PROTOCOLS[l]){const e=CURL_IMPORT_NODES_PROTOCOLS[l];a=l,i=e,t.showToast({title:r.baseText("importCurlParameter.showError.invalidProtocol1.title",{interpolate:{node:i}}),message:r.baseText("importCurlParameter.showError.invalidProtocol.message",{interpolate:{protocol:a.toUpperCase()}}),type:"error",duration:0})}else!function(e){t.showToast({title:r.baseText("importCurlParameter.showError.invalidProtocol2.title"),message:r.baseText("importCurlParameter.showError.invalidProtocol.message",{interpolate:{protocol:e}}),type:"error",duration:0})}(l);e?.onImportFailure?.({invalidProtocol:!0,protocol:l})}catch(l){t.showToast({title:r.baseText(s.invalidCurCommand.title),message:r.baseText(s.invalidCurCommand.message),type:"error",duration:0}),e?.onImportFailure?.({invalidProtocol:!1})}finally{e?.onAfterImport?.()}}}}return _export("useImportCurlCommand",useImportCurlCommand),{setters:[function(e){__toCommonJS=e.a,__require=e.i,__toESM=e.o,__commonJSMin=e.t},function(e){unref=e.Wt},function(e){useI18n=e.bt},function(e){require_get=e.v},function(e){require_path_browserify=e.S,empty_exports=e.n,init_empty=e.r},function(e){useToast=e.Tr,importCurlEventBus=e.fn},function(e){CURL_IMPORT_NOT_SUPPORTED_PROTOCOLS=e.El,CURL_IMPORT_NODES_PROTOCOLS=e.Tl},function(e){},function(e){assert=e.v},function(e){},function(e){}],execute:async function(){try{e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack,n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="16940c86-e1aa-4d07-bdf3-69055475f209",e._sentryDebugIdIdentifier="sentry-dbid-16940c86-e1aa-4d07-bdf3-69055475f209")}catch(e){}var e,n;import_get=__toESM(require_get(),1),CCError=class extends Error{},UTF8encoder=new TextEncoder,Word=class e{constructor(t){this.valueOf=e.toString,"string"==typeof t&&(t=[t]),void 0!==t&&0!==t.length||(t=[""]),this.tokens=[];for(const e of t)"string"==typeof e?this.tokens.length>0&&"string"==typeof this.tokens[this.tokens.length-1]?this.tokens[this.tokens.length-1]+=e:e&&this.tokens.push(e):this.tokens.push(e);0===this.tokens.length&&this.tokens.push("")}get length(){let e=0;for(const t of this.tokens)e+="string"==typeof t?t.length:1;return e}*[Symbol.iterator](){for(const e of this.tokens)if("string"==typeof e)for(const t of e)yield t;else yield e}get(e){let t=0;for(const r of this.tokens)if("string"==typeof r){if(t+r.length>e)return r[e-t];t+=r.length}else{if(t===e)return r;t+=1}throw new CCError("Index out of bounds")}charAt(e=0){try{return this.get(e)}catch(t){}return""}indexOf(e,t){void 0===t&&(t=0);let r=0;for(const s of this.tokens)if("string"==typeof s){if(r+s.length>t){const n=s.indexOf(e,t-r);if(-1!==n)return r+n}r+=s.length}else r+=1;return-1}indexOfFirstChar(e){let t=0;for(const r of this.tokens)if("string"==typeof r)for(const s of r){if(e.includes(s))return t;t+=1}else t+=1;return-1}removeFirstChar(t){return 0===this.length?new e:this.charAt(0)===t?this.slice(1):this.copy()}copy(){return new e(this.tokens)}slice(t,r){if(void 0===t&&(t=this.length),void 0===r&&(r=this.length),t>=this.length)return new e;if(t<0&&(t=Math.max(t+this.length,0)),r<0&&(r=Math.max(r+this.length,0)),r<=t)return new e;const s=[];let n=0;for(const e of this.tokens)"string"==typeof e?(n+e.length>t&&n<r&&s.push(e.slice(Math.max(t-n,0),r-n)),n+=e.length):(n>=t&&n<r&&s.push(e),n+=1);return new e(s)}includes(e,t){void 0===t&&(t=0);let r=0;for(const s of this.tokens)if("string"==typeof s){if(r+s.length>t&&s.includes(e,t-r))return!0;r+=s.length}else r+=1;return!1}test(e){for(const t of this.tokens)if("string"==typeof t&&e.test(t))return!0;return!1}prepend(e){const t=this.copy();return t.tokens.length&&"string"==typeof t.tokens[0]?t.tokens[0]=e+t.tokens[0]:t.tokens.unshift(e),t}append(e){const t=this.copy();return t.tokens.length&&"string"==typeof t.tokens[t.tokens.length-1]?t.tokens[t.tokens.length-1]+=e:t.tokens.push(e),t}add(t){return new e([...this.tokens,...t.tokens])}match(e){for(const t of this.tokens)if("string"==typeof t){const r=t.match(e);if(r)return r}return null}search(e){let t=0;for(const r of this.tokens)if("string"==typeof r){const s=r.search(e);if(-1!==s)return t+s;t+=r.length}return-1}replace(t,r){const s=[];for(const e of this.tokens)"string"==typeof e?s.push(e.replace(t,r)):s.push(e);return new e(s)}split(e,t){const r=[];let s=0,n=0;for(;s<this.length;){let o=!0;for(let t=0;t<e.length;t++)if(this.get(s+t)!==e.charAt(t)){o=!1;break}if(o){if(r.push(this.slice(n,s)),s+=e.length,n=s,void 0!==t&&r.length===t-1)break}else s+=1}return n<=this.length&&r.push(this.slice(n)),r}toLowerCase(){return new e(this.tokens.map((e=>"string"==typeof e?e.toLowerCase():e)))}toUpperCase(){return new e(this.tokens.map((e=>"string"==typeof e?e.toUpperCase():e)))}trimStart(){const t=[];let r,s;for([r,s]of this.tokens.entries())"string"==typeof s?(0===r&&(s=s.trimStart()),s&&t.push(s)):t.push(s);return 0===t.length?new e:new e(t)}trimEnd(){const t=[];let r,s;for([r,s]of this.tokens.entries())"string"==typeof s?(r===this.tokens.length-1&&(s=s.trimEnd()),s&&t.push(s)):t.push(s);return 0===t.length?new e:new e(t)}trim(){const t=[];let r,s;for([r,s]of this.tokens.entries())"string"==typeof s?(0===r&&(s=s.trimStart()),r===this.tokens.length-1&&(s=s.trimEnd()),s&&t.push(s)):t.push(s);return 0===t.length?new e:new e(t)}isEmpty(){return 0===this.tokens.length||1===this.tokens.length&&"string"==typeof this.tokens[0]&&0===this.tokens[0].length}toBool(){return!this.isEmpty()}isString(){for(const e of this.tokens)if("string"!=typeof e)return!1;return!0}firstShellToken(){for(const e of this.tokens)if("string"!=typeof e)return e;return null}startsWith(e){return 0!==this.tokens.length&&("string"==typeof this.tokens[0]&&this.tokens[0].startsWith(e))}endsWith(e){if(0===this.tokens.length)return!1;const t=this.tokens[this.tokens.length-1];return"string"==typeof t&&t.endsWith(e)}toString(){return this.tokens.map((e=>"string"==typeof e?e:e.text)).join("")}},require_tree_sitter=__commonJSMin(((exports,module)=>{var Module=void 0!==Module?Module:{},ENVIRONMENT_IS_WEB="object"==typeof window,ENVIRONMENT_IS_WORKER="function"==typeof importScripts,ENVIRONMENT_IS_NODE="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node,TreeSitter=function(){var initPromise,document="object"==typeof window?{currentScript:window.document.currentScript}:null;class Parser$3{constructor(){this.initialize()}initialize(){throw new Error("cannot construct a Parser before calling `init()`")}static init(moduleOptions){return initPromise||(Module=Object.assign({},Module,moduleOptions),initPromise=new Promise((resolveInitPromise=>{var moduleOverrides=Object.assign({},Module),arguments_=[],thisProgram="./this.program",quit_=(e,t)=>{throw t},scriptDirectory="",readAsync,readBinary;function locateFile(e){return Module.locateFile?Module.locateFile(e,scriptDirectory):scriptDirectory+e}if(ENVIRONMENT_IS_NODE){var fs=(init_empty(),__toCommonJS(empty_exports)),nodePath=require_path_browserify();scriptDirectory=__dirname+"/",readBinary=e=>(e=isFileURI(e)?new URL(e):nodePath.normalize(e),fs.readFileSync(e)),readAsync=(e,t=!0)=>(e=isFileURI(e)?new URL(e):nodePath.normalize(e),new Promise(((r,s)=>{fs.readFile(e,t?void 0:"utf8",((e,n)=>{e?s(e):r(t?n.buffer:n)}))}))),!Module.thisProgram&&process.argv.length>1&&(thisProgram=process.argv[1].replace(/\\/g,"/")),arguments_=process.argv.slice(2),void 0!==module&&(module.exports=Module),quit_=(e,t)=>{throw process.exitCode=e,t}}else(ENVIRONMENT_IS_WEB||ENVIRONMENT_IS_WORKER)&&(ENVIRONMENT_IS_WORKER?scriptDirectory=self.location.href:void 0!==document&&document.currentScript&&(scriptDirectory=document.currentScript.src),scriptDirectory=scriptDirectory.startsWith("blob:")?"":scriptDirectory.substr(0,scriptDirectory.replace(/[?#].*/,"").lastIndexOf("/")+1),ENVIRONMENT_IS_WORKER&&(readBinary=e=>{var t=new XMLHttpRequest;return t.open("GET",e,!1),t.responseType="arraybuffer",t.send(null),new Uint8Array(t.response)}),readAsync=e=>isFileURI(e)?new Promise(((t,r)=>{var s=new XMLHttpRequest;s.open("GET",e,!0),s.responseType="arraybuffer",s.onload=()=>{(200==s.status||0==s.status&&s.response)&&r(s.response),t(s.status)},s.onerror=t,s.send(null)})):fetch(e,{credentials:"same-origin"}).then((e=>e.ok?e.arrayBuffer():Promise.reject(new Error(e.status+" : "+e.url)))));var out=Module.print||console.log.bind(console),err=Module.printErr||console.error.bind(console);Object.assign(Module,moduleOverrides),moduleOverrides=null,Module.arguments&&(arguments_=Module.arguments),Module.thisProgram&&(thisProgram=Module.thisProgram),Module.quit&&(quit_=Module.quit);var dynamicLibraries=Module.dynamicLibraries||[],wasmBinary,wasmMemory;Module.wasmBinary&&(wasmBinary=Module.wasmBinary);var ABORT=!1,EXITSTATUS,HEAP8,HEAPU8,HEAP16,HEAPU16,HEAP32,HEAPU32,HEAPF32,HEAPF64,HEAP_DATA_VIEW;function updateMemoryViews(){var e=wasmMemory.buffer;Module.HEAP_DATA_VIEW=HEAP_DATA_VIEW=new DataView(e),Module.HEAP8=HEAP8=new Int8Array(e),Module.HEAP16=new Int16Array(e),Module.HEAPU8=HEAPU8=new Uint8Array(e),Module.HEAPU16=new Uint16Array(e),Module.HEAP32=new Int32Array(e),Module.HEAPU32=new Uint32Array(e),Module.HEAPF32=new Float32Array(e),Module.HEAPF64=new Float64Array(e)}if(Module.wasmMemory)wasmMemory=Module.wasmMemory;else{var INITIAL_MEMORY=Module.INITIAL_MEMORY||33554432;wasmMemory=new WebAssembly.Memory({initial:INITIAL_MEMORY/65536,maximum:32768})}updateMemoryViews();var __ATPRERUN__=[],__ATINIT__=[],__ATMAIN__=[],__ATPOSTRUN__=[],__RELOC_FUNCS__=[],runtimeInitialized=!1;function preRun(){if(Module.preRun)for("function"==typeof Module.preRun&&(Module.preRun=[Module.preRun]);Module.preRun.length;)addOnPreRun(Module.preRun.shift());callRuntimeCallbacks(__ATPRERUN__)}function initRuntime(){runtimeInitialized=!0,callRuntimeCallbacks(__RELOC_FUNCS__),callRuntimeCallbacks(__ATINIT__)}function preMain(){callRuntimeCallbacks(__ATMAIN__)}function postRun(){if(Module.postRun)for("function"==typeof Module.postRun&&(Module.postRun=[Module.postRun]);Module.postRun.length;)addOnPostRun(Module.postRun.shift());callRuntimeCallbacks(__ATPOSTRUN__)}function addOnPreRun(e){__ATPRERUN__.unshift(e)}function addOnInit(e){__ATINIT__.unshift(e)}function addOnPostRun(e){__ATPOSTRUN__.unshift(e)}var runDependencies=0,runDependencyWatcher=null,dependenciesFulfilled=null;function getUniqueRunDependency(e){return e}function addRunDependency(e){runDependencies++,Module.monitorRunDependencies?.(runDependencies)}function removeRunDependency(e){if(runDependencies--,Module.monitorRunDependencies?.(runDependencies),0==runDependencies&&(null!==runDependencyWatcher&&(clearInterval(runDependencyWatcher),runDependencyWatcher=null),dependenciesFulfilled)){var t=dependenciesFulfilled;dependenciesFulfilled=null,t()}}function abort(e){throw Module.onAbort?.(e),err(e="Aborted("+e+")"),ABORT=!0,EXITSTATUS=1,e+=". Build with -sASSERTIONS for more info.",new WebAssembly.RuntimeError(e)}var dataURIPrefix="data:application/octet-stream;base64,",isDataURI=e=>e.startsWith(dataURIPrefix),isFileURI=e=>e.startsWith("file://"),wasmBinaryFile;function findWasmBinary(){var e="tree-sitter.wasm";return isDataURI(e)?e:locateFile(e)}function getBinarySync(e){if(e==wasmBinaryFile&&wasmBinary)return new Uint8Array(wasmBinary);if(readBinary)return readBinary(e);throw"both async and sync fetching of the wasm failed"}function getBinaryPromise(e){return wasmBinary?Promise.resolve().then((()=>getBinarySync(e))):readAsync(e).then((e=>new Uint8Array(e)),(()=>getBinarySync(e)))}function instantiateArrayBuffer(e,t,r){return getBinaryPromise(e).then((e=>WebAssembly.instantiate(e,t))).then(r,(e=>{err(`failed to asynchronously prepare wasm: ${e}`),abort(e)}))}function instantiateAsync(e,t,r,s){return e||"function"!=typeof WebAssembly.instantiateStreaming||isDataURI(t)||isFileURI(t)||ENVIRONMENT_IS_NODE||"function"!=typeof fetch?instantiateArrayBuffer(t,r,s):fetch(t,{credentials:"same-origin"}).then((e=>WebAssembly.instantiateStreaming(e,r).then(s,(function(e){return err(`wasm streaming compile failed: ${e}`),err("falling back to ArrayBuffer instantiation"),instantiateArrayBuffer(t,r,s)}))))}function getWasmImports(){return{env:wasmImports,wasi_snapshot_preview1:wasmImports,"GOT.mem":new Proxy(wasmImports,GOTHandler),"GOT.func":new Proxy(wasmImports,GOTHandler)}}function createWasm(){var t=getWasmImports();function r(e,t){wasmExports=e.exports,wasmExports=relocateExports(wasmExports,1024);var r=getDylinkMetadata(t);return r.neededDynlibs&&(dynamicLibraries=r.neededDynlibs.concat(dynamicLibraries)),mergeLibSymbols(wasmExports,"main"),LDSO.init(),loadDylibs(),addOnInit(wasmExports.__wasm_call_ctors),__RELOC_FUNCS__.push(wasmExports.__wasm_apply_data_relocs),removeRunDependency("wasm-instantiate"),wasmExports}if(addRunDependency("wasm-instantiate"),Module.instantiateWasm)try{return Module.instantiateWasm(t,r)}catch(e){return err(`Module.instantiateWasm callback failed with error: ${e}`),!1}return wasmBinaryFile||(wasmBinaryFile=findWasmBinary()),instantiateAsync(wasmBinary,wasmBinaryFile,t,(function(e){r(e.instance,e.module)})),{}}var ASM_CONSTS={};function ExitStatus(e){this.name="ExitStatus",this.message=`Program terminated with exit(${e})`,this.status=e}var GOT={},currentModuleWeakSymbols=new Set([]),GOTHandler={get(e,t){var r=GOT[t];return r||(r=GOT[t]=new WebAssembly.Global({value:"i32",mutable:!0})),currentModuleWeakSymbols.has(t)||(r.required=!0),r}},LE_HEAP_LOAD_F32=e=>HEAP_DATA_VIEW.getFloat32(e,!0),LE_HEAP_LOAD_F64=e=>HEAP_DATA_VIEW.getFloat64(e,!0),LE_HEAP_LOAD_I16=e=>HEAP_DATA_VIEW.getInt16(e,!0),LE_HEAP_LOAD_I32=e=>HEAP_DATA_VIEW.getInt32(e,!0),LE_HEAP_LOAD_U32=e=>HEAP_DATA_VIEW.getUint32(e,!0),LE_HEAP_STORE_F32=(e,t)=>HEAP_DATA_VIEW.setFloat32(e,t,!0),LE_HEAP_STORE_F64=(e,t)=>HEAP_DATA_VIEW.setFloat64(e,t,!0),LE_HEAP_STORE_I16=(e,t)=>HEAP_DATA_VIEW.setInt16(e,t,!0),LE_HEAP_STORE_I32=(e,t)=>HEAP_DATA_VIEW.setInt32(e,t,!0),LE_HEAP_STORE_U32=(e,t)=>HEAP_DATA_VIEW.setUint32(e,t,!0),callRuntimeCallbacks=e=>{for(;e.length>0;)e.shift()(Module)},UTF8Decoder="undefined"!=typeof TextDecoder?new TextDecoder:void 0,UTF8ArrayToString=(e,t,r)=>{for(var s=t+r,n=t;e[n]&&!(n>=s);)++n;if(n-t>16&&e.buffer&&UTF8Decoder)return UTF8Decoder.decode(e.subarray(t,n));for(var o="";t<n;){var a=e[t++];if(128&a){var i=63&e[t++];if(192!=(224&a)){var l=63&e[t++];if((a=224==(240&a)?(15&a)<<12|i<<6|l:(7&a)<<18|i<<12|l<<6|63&e[t++])<65536)o+=String.fromCharCode(a);else{var _=a-65536;o+=String.fromCharCode(55296|_>>10,56320|1023&_)}}else o+=String.fromCharCode((31&a)<<6|i)}else o+=String.fromCharCode(a)}return o},getDylinkMetadata=e=>{var t=0,r=0;function s(){for(var r=0,s=1;;){var n=e[t++];if(r+=(127&n)*s,s*=128,!(128&n))break}return r}function n(){var r=s();return UTF8ArrayToString(e,(t+=r)-r,r)}function o(e,t){if(e)throw new Error(t)}var a="dylink.0";if(e instanceof WebAssembly.Module){var i=WebAssembly.Module.customSections(e,a);0===i.length&&(a="dylink",i=WebAssembly.Module.customSections(e,a)),o(0===i.length,"need dylink section"),r=(e=new Uint8Array(i[0])).length}else{var l=new Uint32Array(new Uint8Array(e.subarray(0,24)).buffer);o(!(1836278016==l[0]||6386541==l[0]),"need to see wasm magic number"),o(0!==e[8],"need the dylink section to be first"),t=9;var _=s();r=t+_,a=n()}var u={neededDynlibs:[],tlsExports:new Set,weakImports:new Set};if("dylink"==a){u.memorySize=s(),u.memoryAlign=s(),u.tableSize=s(),u.tableAlign=s();for(var p=s(),c=0;c<p;++c){var d=n();u.neededDynlibs.push(d)}}else{o("dylink.0"!==a);for(;t<r;){var m=e[t++],h=s();if(1===m)u.memorySize=s(),u.memoryAlign=s(),u.tableSize=s(),u.tableAlign=s();else if(2===m)for(p=s(),c=0;c<p;++c)d=n(),u.neededDynlibs.push(d);else if(3===m)for(var y=s();y--;){var g=n();256&s()&&u.tlsExports.add(g)}else if(4===m)for(y=s();y--;){n(),g=n();1==(3&s())&&u.weakImports.add(g)}else t+=h}}return u};function getValue(e,t="i8"){switch(t.endsWith("*")&&(t="*"),t){case"i1":case"i8":return HEAP8[e];case"i16":return LE_HEAP_LOAD_I16(2*(e>>1));case"i32":return LE_HEAP_LOAD_I32(4*(e>>2));case"i64":abort("to do getValue(i64) use WASM_BIGINT");case"float":return LE_HEAP_LOAD_F32(4*(e>>2));case"double":return LE_HEAP_LOAD_F64(8*(e>>3));case"*":return LE_HEAP_LOAD_U32(4*(e>>2));default:abort(`invalid type for getValue: ${t}`)}}var newDSO=(e,t,r)=>{var s={refcount:1/0,name:e,exports:r,global:!0};return LDSO.loadedLibsByName[e]=s,null!=t&&(LDSO.loadedLibsByHandle[t]=s),s},LDSO={loadedLibsByName:{},loadedLibsByHandle:{},init(){newDSO("__main__",0,wasmImports)}},___heap_base=78112,zeroMemory=(e,t)=>(HEAPU8.fill(0,e,e+t),e),alignMemory=(e,t)=>Math.ceil(e/t)*t,getMemory=e=>{if(runtimeInitialized)return zeroMemory(_malloc(e),e);var t=___heap_base,r=t+alignMemory(e,16);return ___heap_base=r,GOT.__heap_base.value=r,t},isInternalSym=e=>["__cpp_exception","__c_longjmp","__wasm_apply_data_relocs","__dso_handle","__tls_size","__tls_align","__set_stack_limits","_emscripten_tls_init","__wasm_init_tls","__wasm_call_ctors","__start_em_asm","__stop_em_asm","__start_em_js","__stop_em_js"].includes(e)||e.startsWith("__em_js__"),uleb128Encode=(e,t)=>{e<128?t.push(e):t.push(e%128|128,e>>7)},sigToWasmTypes=e=>{for(var t={i:"i32",j:"i64",f:"f32",d:"f64",e:"externref",p:"i32"},r={parameters:[],results:"v"==e[0]?[]:[t[e[0]]]},s=1;s<e.length;++s)r.parameters.push(t[e[s]]);return r},generateFuncType=(e,t)=>{var r=e.slice(0,1),s=e.slice(1),n={i:127,p:127,j:126,f:125,d:124,e:111};t.push(96),uleb128Encode(s.length,t);for(var o=0;o<s.length;++o)t.push(n[s[o]]);"v"==r?t.push(0):t.push(1,n[r])},convertJsFunctionToWasm=(e,t)=>{if("function"==typeof WebAssembly.Function)return new WebAssembly.Function(sigToWasmTypes(t),e);var r=[1];generateFuncType(t,r);var s=[0,97,115,109,1,0,0,0,1];uleb128Encode(r.length,s),s.push(...r),s.push(2,7,1,1,101,1,102,0,0,7,5,1,1,102,0,0);var n=new WebAssembly.Module(new Uint8Array(s));return new WebAssembly.Instance(n,{e:{f:e}}).exports.f},wasmTableMirror=[],wasmTable=new WebAssembly.Table({initial:28,element:"anyfunc"}),getWasmTableEntry=e=>{var t=wasmTableMirror[e];return t||(e>=wasmTableMirror.length&&(wasmTableMirror.length=e+1),wasmTableMirror[e]=t=wasmTable.get(e)),t},updateTableMap=(e,t)=>{if(functionsInTableMap)for(var r=e;r<e+t;r++){var s=getWasmTableEntry(r);s&&functionsInTableMap.set(s,r)}},functionsInTableMap,getFunctionAddress=e=>(functionsInTableMap||(functionsInTableMap=new WeakMap,updateTableMap(0,wasmTable.length)),functionsInTableMap.get(e)||0),freeTableIndexes=[],getEmptyTableSlot=()=>{if(freeTableIndexes.length)return freeTableIndexes.pop();try{wasmTable.grow(1)}catch(e){if(!(e instanceof RangeError))throw e;throw"Unable to grow wasm table. Set ALLOW_TABLE_GROWTH."}return wasmTable.length-1},setWasmTableEntry=(e,t)=>{wasmTable.set(e,t),wasmTableMirror[e]=wasmTable.get(e)},addFunction=(e,t)=>{var r=getFunctionAddress(e);if(r)return r;var s=getEmptyTableSlot();try{setWasmTableEntry(s,e)}catch(n){if(!(n instanceof TypeError))throw n;setWasmTableEntry(s,convertJsFunctionToWasm(e,t))}return functionsInTableMap.set(e,s),s},updateGOT=(e,t)=>{for(var r in e)if(!isInternalSym(r)){var s=e[r];r.startsWith("orig$")&&(r=r.split("$")[1],t=!0),GOT[r]||=new WebAssembly.Global({value:"i32",mutable:!0}),(t||0==GOT[r].value)&&("function"==typeof s?GOT[r].value=addFunction(s):"number"==typeof s?GOT[r].value=s:err(`unhandled export type for '${r}': ${typeof s}`))}},relocateExports=(e,t,r)=>{var s={};for(var n in e){var o=e[n];"object"==typeof o&&(o=o.value),"number"==typeof o&&(o+=t),s[n]=o}return updateGOT(s,r),s},isSymbolDefined=e=>{var t=wasmImports[e];return!(!t||t.stub)},dynCallLegacy=(e,t,r)=>(e=e.replace(/p/g,"i"),(0,Module["dynCall_"+e])(t,...r)),dynCall=(e,t,r=[])=>e.includes("j")?dynCallLegacy(e,t,r):getWasmTableEntry(t)(...r),stackSave=()=>_emscripten_stack_get_current(),stackRestore=e=>__emscripten_stack_restore(e),createInvokeFunction=t=>(r,...s)=>{var n=stackSave();try{return dynCall(t,r,s)}catch(e){if(stackRestore(n),e!==e+0)throw e;_setThrew(1,0)}},resolveGlobalSymbol=(e,t=!1)=>{var r;return t&&"orig$"+e in wasmImports&&(e="orig$"+e),isSymbolDefined(e)?r=wasmImports[e]:e.startsWith("invoke_")&&(r=wasmImports[e]=createInvokeFunction(e.split("_")[1])),{sym:r,name:e}},UTF8ToString=(e,t)=>e?UTF8ArrayToString(HEAPU8,e,t):"",loadWebAssemblyModule=(binary,flags,libName,localScope,handle)=>{var metadata=getDylinkMetadata(binary);function loadModule(){var firstLoad=!handle||!HEAP8[handle+8];if(firstLoad){var memAlign=Math.pow(2,metadata.memoryAlign),memoryBase=metadata.memorySize?alignMemory(getMemory(metadata.memorySize+memAlign),memAlign):0,tableBase=metadata.tableSize?wasmTable.length:0;handle&&(HEAP8[handle+8]=1,LE_HEAP_STORE_U32(4*(handle+12>>2),memoryBase),LE_HEAP_STORE_I32(4*(handle+16>>2),metadata.memorySize),LE_HEAP_STORE_U32(4*(handle+20>>2),tableBase),LE_HEAP_STORE_I32(4*(handle+24>>2),metadata.tableSize))}else memoryBase=LE_HEAP_LOAD_U32(4*(handle+12>>2)),tableBase=LE_HEAP_LOAD_U32(4*(handle+20>>2));var tableGrowthNeeded=tableBase+metadata.tableSize-wasmTable.length,moduleExports;function resolveSymbol(e){var t=resolveGlobalSymbol(e).sym;return!t&&localScope&&(t=localScope[e]),t||(t=moduleExports[e]),t}tableGrowthNeeded>0&&wasmTable.grow(tableGrowthNeeded);var proxyHandler={get(e,t){switch(t){case"__memory_base":return memoryBase;case"__table_base":return tableBase}if(t in wasmImports&&!wasmImports[t].stub)return wasmImports[t];var r;t in e||(e[t]=(...e)=>(r||=resolveSymbol(t),r(...e)));return e[t]}},proxy=new Proxy({},proxyHandler),info={"GOT.mem":new Proxy({},GOTHandler),"GOT.func":new Proxy({},GOTHandler),env:proxy,wasi_snapshot_preview1:proxy};function postInstantiation(module$2,instance$1){function addEmAsm(addr,body){for(var args=[],arity=0;arity<16&&-1!=body.indexOf("$"+arity);arity++)args.push("$"+arity);args=args.join(",");var func=`(${args}) => { ${body} };`;ASM_CONSTS[start]=eval(func)}if(updateTableMap(tableBase,metadata.tableSize),moduleExports=relocateExports(instance$1.exports,memoryBase),flags.allowUndefined||reportUndefinedSymbols(),"__start_em_asm"in moduleExports)for(var start=moduleExports.__start_em_asm,stop=moduleExports.__stop_em_asm;start<stop;){var jsString=UTF8ToString(start);addEmAsm(start,jsString),start=HEAPU8.indexOf(0,start)+1}function addEmJs(name$1,cSig,body){var jsArgs=[];if(cSig=cSig.slice(1,-1),"void"!=cSig)for(var i in cSig=cSig.split(","),cSig){var jsArg=cSig[i].split(" ").pop();jsArgs.push(jsArg.replace("*",""))}var func=`(${jsArgs}) => ${body};`;moduleExports[name$1]=eval(func)}for(var name in moduleExports)if(name.startsWith("__em_js__")){var start=moduleExports[name],jsString=UTF8ToString(start),parts=jsString.split("<::>");addEmJs(name.replace("__em_js__",""),parts[0],parts[1]),delete moduleExports[name]}var applyRelocs=moduleExports.__wasm_apply_data_relocs;applyRelocs&&(runtimeInitialized?applyRelocs():__RELOC_FUNCS__.push(applyRelocs));var init=moduleExports.__wasm_call_ctors;return init&&(runtimeInitialized?init():__ATINIT__.push(init)),moduleExports}if(flags.loadAsync){if(binary instanceof WebAssembly.Module){var instance=new WebAssembly.Instance(binary,info);return Promise.resolve(postInstantiation(binary,instance))}return WebAssembly.instantiate(binary,info).then((e=>postInstantiation(e.module,e.instance)))}var module$1=binary instanceof WebAssembly.Module?binary:new WebAssembly.Module(binary),instance=new WebAssembly.Instance(module$1,info);return postInstantiation(module$1,instance)}return currentModuleWeakSymbols=metadata.weakImports,flags.loadAsync?metadata.neededDynlibs.reduce(((e,t)=>e.then((()=>loadDynamicLibrary(t,flags,localScope)))),Promise.resolve()).then(loadModule):(metadata.neededDynlibs.forEach((e=>loadDynamicLibrary(e,flags,localScope))),loadModule())},mergeLibSymbols=(e,t)=>{for(var[r,s]of Object.entries(e)){const e=e=>{isSymbolDefined(e)||(wasmImports[e]=s)};e(r);const t="__main_argc_argv";"main"==r&&e(t),r==t&&e("main"),r.startsWith("dynCall_")&&!Module.hasOwnProperty(r)&&(Module[r]=s)}},asyncLoad=(e,t,r,s)=>{var n=s?"":getUniqueRunDependency(`al ${e}`);readAsync(e).then((e=>{t(new Uint8Array(e)),n&&removeRunDependency(n)}),(t=>{if(!r)throw`Loading data file "${e}" failed.`;r()})),n&&addRunDependency(n)};function loadDynamicLibrary(e,t={global:!0,nodelete:!0},r,s){var n=LDSO.loadedLibsByName[e];if(n)return t.global?n.global||(n.global=!0,mergeLibSymbols(n.exports,e)):r&&Object.assign(r,n.exports),t.nodelete&&n.refcount!==1/0&&(n.refcount=1/0),n.refcount++,s&&(LDSO.loadedLibsByHandle[s]=n),!t.loadAsync||Promise.resolve(!0);function o(){if(s){var r=LE_HEAP_LOAD_U32(4*(s+28>>2)),n=LE_HEAP_LOAD_U32(4*(s+32>>2));if(r&&n){var o=HEAP8.slice(r,r+n);return t.loadAsync?Promise.resolve(o):o}}var a=locateFile(e);if(t.loadAsync)return new Promise((function(e,t){asyncLoad(a,e,t)}));if(!readBinary)throw new Error(`${a}: file not found, and synchronous loading of external files is not available`);return readBinary(a)}function a(){return t.loadAsync?o().then((n=>loadWebAssemblyModule(n,t,e,r,s))):loadWebAssemblyModule(o(),t,e,r,s)}function i(t){n.global?mergeLibSymbols(t,e):r&&Object.assign(r,t),n.exports=t}return(n=newDSO(e,s,"loading")).refcount=t.nodelete?1/0:1,n.global=t.global,t.loadAsync?a().then((e=>(i(e),!0))):(i(a()),!0)}var reportUndefinedSymbols=()=>{for(var[e,t]of Object.entries(GOT))if(0==t.value){var r=resolveGlobalSymbol(e,!0).sym;if(!r&&!t.required)continue;if("function"==typeof r)t.value=addFunction(r,r.sig);else{if("number"!=typeof r)throw new Error(`bad export type for '${e}': ${typeof r}`);t.value=r}}},loadDylibs=()=>{dynamicLibraries.length?(addRunDependency("loadDylibs"),dynamicLibraries.reduce(((e,t)=>e.then((()=>loadDynamicLibrary(t,{loadAsync:!0,global:!0,nodelete:!0,allowUndefined:!0})))),Promise.resolve()).then((()=>{reportUndefinedSymbols(),removeRunDependency("loadDylibs")}))):reportUndefinedSymbols()},noExitRuntime=Module.noExitRuntime||!0;function setValue(e,t,r="i8"){switch(r.endsWith("*")&&(r="*"),r){case"i1":case"i8":HEAP8[e]=t;break;case"i16":LE_HEAP_STORE_I16(2*(e>>1),t);break;case"i32":LE_HEAP_STORE_I32(4*(e>>2),t);break;case"i64":abort("to do setValue(i64) use WASM_BIGINT");case"float":LE_HEAP_STORE_F32(4*(e>>2),t);break;case"double":LE_HEAP_STORE_F64(8*(e>>3),t);break;case"*":LE_HEAP_STORE_U32(4*(e>>2),t);break;default:abort(`invalid type for setValue: ${r}`)}}var ___memory_base=new WebAssembly.Global({value:"i32",mutable:!1},1024),___stack_pointer=new WebAssembly.Global({value:"i32",mutable:!0},78112),___table_base=new WebAssembly.Global({value:"i32",mutable:!1},1),__abort_js=()=>{abort("")};__abort_js.sig="v";var nowIsMonotonic=1,__emscripten_get_now_is_monotonic=()=>nowIsMonotonic;__emscripten_get_now_is_monotonic.sig="i";var __emscripten_memcpy_js=(e,t,r)=>HEAPU8.copyWithin(e,t,t+r);__emscripten_memcpy_js.sig="vppp";var _emscripten_date_now=()=>Date.now();_emscripten_date_now.sig="d";var _emscripten_get_now=()=>performance.now();_emscripten_get_now.sig="d";var getHeapMax=()=>2147483648,growMemory=t=>{var r=(t-wasmMemory.buffer.byteLength+65535)/65536;try{return wasmMemory.grow(r),updateMemoryViews(),1}catch(e){}},_emscripten_resize_heap=e=>{var t=HEAPU8.length;e>>>=0;var r=getHeapMax();if(e>r)return!1;for(var s,n,o=1;o<=4;o*=2){var a=t*(1+.2/o);if(a=Math.min(a,e+100663296),growMemory(Math.min(r,(s=Math.max(e,a))+((n=65536)-s%n)%n)))return!0}return!1};_emscripten_resize_heap.sig="ip";var _fd_close=e=>52;_fd_close.sig="ii";var convertI32PairToI53Checked=(e,t)=>t+2097152>>>0<4194305-!!e?(e>>>0)+4294967296*t:NaN;function _fd_seek(e,t,r,s,n){convertI32PairToI53Checked(t,r);return 70}_fd_seek.sig="iiiiip";var printCharBuffers=[null,[],[]],printChar=(e,t)=>{var r=printCharBuffers[e];0===t||10===t?((1===e?out:err)(UTF8ArrayToString(r,0)),r.length=0):r.push(t)},_fd_write=(e,t,r,s)=>{for(var n=0,o=0;o<r;o++){var a=LE_HEAP_LOAD_U32(4*(t>>2)),i=LE_HEAP_LOAD_U32(4*(t+4>>2));t+=8;for(var l=0;l<i;l++)printChar(e,HEAPU8[a+l]);n+=i}return LE_HEAP_STORE_U32(4*(s>>2),n),0};function _tree_sitter_log_callback(e,t){if(currentLogCallback){const r=UTF8ToString(t);currentLogCallback(r,0!==e)}}function _tree_sitter_parse_callback(e,t,r,s,n){const o=currentParseCallback(t,{row:r,column:s});"string"==typeof o?(setValue(n,o.length,"i32"),stringToUTF16(o,e,10240)):setValue(n,0,"i32")}_fd_write.sig="iippp";var runtimeKeepaliveCounter=0,keepRuntimeAlive=()=>noExitRuntime||runtimeKeepaliveCounter>0,_proc_exit=e=>{EXITSTATUS=e,keepRuntimeAlive()||(Module.onExit?.(e),ABORT=!0),quit_(e,new ExitStatus(e))};_proc_exit.sig="vi";var exitJS=(e,t)=>{EXITSTATUS=e,_proc_exit(e)},handleException=e=>{if(e instanceof ExitStatus||"unwind"==e)return EXITSTATUS;quit_(1,e)},lengthBytesUTF8=e=>{for(var t=0,r=0;r<e.length;++r){var s=e.charCodeAt(r);s<=127?t++:s<=2047?t+=2:s>=55296&&s<=57343?(t+=4,++r):t+=3}return t},stringToUTF8Array=(e,t,r,s)=>{if(!(s>0))return 0;for(var n=r,o=r+s-1,a=0;a<e.length;++a){var i=e.charCodeAt(a);if(i>=55296&&i<=57343)i=65536+((1023&i)<<10)|1023&e.charCodeAt(++a);if(i<=127){if(r>=o)break;t[r++]=i}else if(i<=2047){if(r+1>=o)break;t[r++]=192|i>>6,t[r++]=128|63&i}else if(i<=65535){if(r+2>=o)break;t[r++]=224|i>>12,t[r++]=128|i>>6&63,t[r++]=128|63&i}else{if(r+3>=o)break;t[r++]=240|i>>18,t[r++]=128|i>>12&63,t[r++]=128|i>>6&63,t[r++]=128|63&i}}return t[r]=0,r-n},stringToUTF8=(e,t,r)=>stringToUTF8Array(e,HEAPU8,t,r),stackAlloc=e=>__emscripten_stack_alloc(e),stringToUTF8OnStack=e=>{var t=lengthBytesUTF8(e)+1,r=stackAlloc(t);return stringToUTF8(e,r,t),r},stringToUTF16=(e,t,r)=>{if(r??=2147483647,r<2)return 0;for(var s=t,n=(r-=2)<2*e.length?r/2:e.length,o=0;o<n;++o){var a=e.charCodeAt(o);LE_HEAP_STORE_I16(2*(t>>1),a),t+=2}return LE_HEAP_STORE_I16(2*(t>>1),0),t-s},AsciiToString=e=>{for(var t="";;){var r=HEAPU8[e++];if(!r)return t;t+=String.fromCharCode(r)}},wasmImports={__heap_base:___heap_base,__indirect_function_table:wasmTable,__memory_base:___memory_base,__stack_pointer:___stack_pointer,__table_base:___table_base,_abort_js:__abort_js,_emscripten_get_now_is_monotonic:__emscripten_get_now_is_monotonic,_emscripten_memcpy_js:__emscripten_memcpy_js,emscripten_get_now:_emscripten_get_now,emscripten_resize_heap:_emscripten_resize_heap,fd_close:_fd_close,fd_seek:_fd_seek,fd_write:_fd_write,memory:wasmMemory,tree_sitter_log_callback:_tree_sitter_log_callback,tree_sitter_parse_callback:_tree_sitter_parse_callback},wasmExports=createWasm(),___wasm_call_ctors=()=>(___wasm_call_ctors=wasmExports.__wasm_call_ctors)(),___wasm_apply_data_relocs=()=>(___wasm_apply_data_relocs=wasmExports.__wasm_apply_data_relocs)(),_malloc=Module._malloc=e=>(_malloc=Module._malloc=wasmExports.malloc)(e),_calloc=Module._calloc=(e,t)=>(_calloc=Module._calloc=wasmExports.calloc)(e,t),_realloc=Module._realloc=(e,t)=>(_realloc=Module._realloc=wasmExports.realloc)(e,t),_free=Module._free=e=>(_free=Module._free=wasmExports.free)(e),_ts_language_symbol_count=Module._ts_language_symbol_count=e=>(_ts_language_symbol_count=Module._ts_language_symbol_count=wasmExports.ts_language_symbol_count)(e),_ts_language_state_count=Module._ts_language_state_count=e=>(_ts_language_state_count=Module._ts_language_state_count=wasmExports.ts_language_state_count)(e),_ts_language_version=Module._ts_language_version=e=>(_ts_language_version=Module._ts_language_version=wasmExports.ts_language_version)(e),_ts_language_field_count=Module._ts_language_field_count=e=>(_ts_language_field_count=Module._ts_language_field_count=wasmExports.ts_language_field_count)(e),_ts_language_next_state=Module._ts_language_next_state=(e,t,r)=>(_ts_language_next_state=Module._ts_language_next_state=wasmExports.ts_language_next_state)(e,t,r),_ts_language_symbol_name=Module._ts_language_symbol_name=(e,t)=>(_ts_language_symbol_name=Module._ts_language_symbol_name=wasmExports.ts_language_symbol_name)(e,t),_ts_language_symbol_for_name=Module._ts_language_symbol_for_name=(e,t,r,s)=>(_ts_language_symbol_for_name=Module._ts_language_symbol_for_name=wasmExports.ts_language_symbol_for_name)(e,t,r,s),_strncmp=Module._strncmp=(e,t,r)=>(_strncmp=Module._strncmp=wasmExports.strncmp)(e,t,r),_ts_language_symbol_type=Module._ts_language_symbol_type=(e,t)=>(_ts_language_symbol_type=Module._ts_language_symbol_type=wasmExports.ts_language_symbol_type)(e,t),_ts_language_field_name_for_id=Module._ts_language_field_name_for_id=(e,t)=>(_ts_language_field_name_for_id=Module._ts_language_field_name_for_id=wasmExports.ts_language_field_name_for_id)(e,t),_ts_lookahead_iterator_new=Module._ts_lookahead_iterator_new=(e,t)=>(_ts_lookahead_iterator_new=Module._ts_lookahead_iterator_new=wasmExports.ts_lookahead_iterator_new)(e,t),_ts_lookahead_iterator_delete=Module._ts_lookahead_iterator_delete=e=>(_ts_lookahead_iterator_delete=Module._ts_lookahead_iterator_delete=wasmExports.ts_lookahead_iterator_delete)(e),_ts_lookahead_iterator_reset_state=Module._ts_lookahead_iterator_reset_state=(e,t)=>(_ts_lookahead_iterator_reset_state=Module._ts_lookahead_iterator_reset_state=wasmExports.ts_lookahead_iterator_reset_state)(e,t),_ts_lookahead_iterator_reset=Module._ts_lookahead_iterator_reset=(e,t,r)=>(_ts_lookahead_iterator_reset=Module._ts_lookahead_iterator_reset=wasmExports.ts_lookahead_iterator_reset)(e,t,r),_ts_lookahead_iterator_next=Module._ts_lookahead_iterator_next=e=>(_ts_lookahead_iterator_next=Module._ts_lookahead_iterator_next=wasmExports.ts_lookahead_iterator_next)(e),_ts_lookahead_iterator_current_symbol=Module._ts_lookahead_iterator_current_symbol=e=>(_ts_lookahead_iterator_current_symbol=Module._ts_lookahead_iterator_current_symbol=wasmExports.ts_lookahead_iterator_current_symbol)(e),_memset=Module._memset=(e,t,r)=>(_memset=Module._memset=wasmExports.memset)(e,t,r),_memcpy=Module._memcpy=(e,t,r)=>(_memcpy=Module._memcpy=wasmExports.memcpy)(e,t,r),_ts_parser_delete=Module._ts_parser_delete=e=>(_ts_parser_delete=Module._ts_parser_delete=wasmExports.ts_parser_delete)(e),_ts_parser_reset=Module._ts_parser_reset=e=>(_ts_parser_reset=Module._ts_parser_reset=wasmExports.ts_parser_reset)(e),_ts_parser_set_language=Module._ts_parser_set_language=(e,t)=>(_ts_parser_set_language=Module._ts_parser_set_language=wasmExports.ts_parser_set_language)(e,t),_ts_parser_timeout_micros=Module._ts_parser_timeout_micros=e=>(_ts_parser_timeout_micros=Module._ts_parser_timeout_micros=wasmExports.ts_parser_timeout_micros)(e),_ts_parser_set_timeout_micros=Module._ts_parser_set_timeout_micros=(e,t,r)=>(_ts_parser_set_timeout_micros=Module._ts_parser_set_timeout_micros=wasmExports.ts_parser_set_timeout_micros)(e,t,r),_ts_parser_set_included_ranges=Module._ts_parser_set_included_ranges=(e,t,r)=>(_ts_parser_set_included_ranges=Module._ts_parser_set_included_ranges=wasmExports.ts_parser_set_included_ranges)(e,t,r),_memmove=Module._memmove=(e,t,r)=>(_memmove=Module._memmove=wasmExports.memmove)(e,t,r),_memcmp=Module._memcmp=(e,t,r)=>(_memcmp=Module._memcmp=wasmExports.memcmp)(e,t,r),_ts_query_new=Module._ts_query_new=(e,t,r,s,n)=>(_ts_query_new=Module._ts_query_new=wasmExports.ts_query_new)(e,t,r,s,n),_ts_query_delete=Module._ts_query_delete=e=>(_ts_query_delete=Module._ts_query_delete=wasmExports.ts_query_delete)(e),_iswspace=Module._iswspace=e=>(_iswspace=Module._iswspace=wasmExports.iswspace)(e),_iswalnum=Module._iswalnum=e=>(_iswalnum=Module._iswalnum=wasmExports.iswalnum)(e),_ts_query_pattern_count=Module._ts_query_pattern_count=e=>(_ts_query_pattern_count=Module._ts_query_pattern_count=wasmExports.ts_query_pattern_count)(e),_ts_query_capture_count=Module._ts_query_capture_count=e=>(_ts_query_capture_count=Module._ts_query_capture_count=wasmExports.ts_query_capture_count)(e),_ts_query_string_count=Module._ts_query_string_count=e=>(_ts_query_string_count=Module._ts_query_string_count=wasmExports.ts_query_string_count)(e),_ts_query_capture_name_for_id=Module._ts_query_capture_name_for_id=(e,t,r)=>(_ts_query_capture_name_for_id=Module._ts_query_capture_name_for_id=wasmExports.ts_query_capture_name_for_id)(e,t,r),_ts_query_string_value_for_id=Module._ts_query_string_value_for_id=(e,t,r)=>(_ts_query_string_value_for_id=Module._ts_query_string_value_for_id=wasmExports.ts_query_string_value_for_id)(e,t,r),_ts_query_predicates_for_pattern=Module._ts_query_predicates_for_pattern=(e,t,r)=>(_ts_query_predicates_for_pattern=Module._ts_query_predicates_for_pattern=wasmExports.ts_query_predicates_for_pattern)(e,t,r),_ts_query_disable_capture=Module._ts_query_disable_capture=(e,t,r)=>(_ts_query_disable_capture=Module._ts_query_disable_capture=wasmExports.ts_query_disable_capture)(e,t,r),_ts_tree_copy=Module._ts_tree_copy=e=>(_ts_tree_copy=Module._ts_tree_copy=wasmExports.ts_tree_copy)(e),_ts_tree_delete=Module._ts_tree_delete=e=>(_ts_tree_delete=Module._ts_tree_delete=wasmExports.ts_tree_delete)(e),_ts_init=Module._ts_init=()=>(_ts_init=Module._ts_init=wasmExports.ts_init)(),_ts_parser_new_wasm=Module._ts_parser_new_wasm=()=>(_ts_parser_new_wasm=Module._ts_parser_new_wasm=wasmExports.ts_parser_new_wasm)(),_ts_parser_enable_logger_wasm=Module._ts_parser_enable_logger_wasm=(e,t)=>(_ts_parser_enable_logger_wasm=Module._ts_parser_enable_logger_wasm=wasmExports.ts_parser_enable_logger_wasm)(e,t),_ts_parser_parse_wasm=Module._ts_parser_parse_wasm=(e,t,r,s,n)=>(_ts_parser_parse_wasm=Module._ts_parser_parse_wasm=wasmExports.ts_parser_parse_wasm)(e,t,r,s,n),_ts_parser_included_ranges_wasm=Module._ts_parser_included_ranges_wasm=e=>(_ts_parser_included_ranges_wasm=Module._ts_parser_included_ranges_wasm=wasmExports.ts_parser_included_ranges_wasm)(e),_ts_language_type_is_named_wasm=Module._ts_language_type_is_named_wasm=(e,t)=>(_ts_language_type_is_named_wasm=Module._ts_language_type_is_named_wasm=wasmExports.ts_language_type_is_named_wasm)(e,t),_ts_language_type_is_visible_wasm=Module._ts_language_type_is_visible_wasm=(e,t)=>(_ts_language_type_is_visible_wasm=Module._ts_language_type_is_visible_wasm=wasmExports.ts_language_type_is_visible_wasm)(e,t),_ts_tree_root_node_wasm=Module._ts_tree_root_node_wasm=e=>(_ts_tree_root_node_wasm=Module._ts_tree_root_node_wasm=wasmExports.ts_tree_root_node_wasm)(e),_ts_tree_root_node_with_offset_wasm=Module._ts_tree_root_node_with_offset_wasm=e=>(_ts_tree_root_node_with_offset_wasm=Module._ts_tree_root_node_with_offset_wasm=wasmExports.ts_tree_root_node_with_offset_wasm)(e),_ts_tree_edit_wasm=Module._ts_tree_edit_wasm=e=>(_ts_tree_edit_wasm=Module._ts_tree_edit_wasm=wasmExports.ts_tree_edit_wasm)(e),_ts_tree_included_ranges_wasm=Module._ts_tree_included_ranges_wasm=e=>(_ts_tree_included_ranges_wasm=Module._ts_tree_included_ranges_wasm=wasmExports.ts_tree_included_ranges_wasm)(e),_ts_tree_get_changed_ranges_wasm=Module._ts_tree_get_changed_ranges_wasm=(e,t)=>(_ts_tree_get_changed_ranges_wasm=Module._ts_tree_get_changed_ranges_wasm=wasmExports.ts_tree_get_changed_ranges_wasm)(e,t),_ts_tree_cursor_new_wasm=Module._ts_tree_cursor_new_wasm=e=>(_ts_tree_cursor_new_wasm=Module._ts_tree_cursor_new_wasm=wasmExports.ts_tree_cursor_new_wasm)(e),_ts_tree_cursor_delete_wasm=Module._ts_tree_cursor_delete_wasm=e=>(_ts_tree_cursor_delete_wasm=Module._ts_tree_cursor_delete_wasm=wasmExports.ts_tree_cursor_delete_wasm)(e),_ts_tree_cursor_reset_wasm=Module._ts_tree_cursor_reset_wasm=e=>(_ts_tree_cursor_reset_wasm=Module._ts_tree_cursor_reset_wasm=wasmExports.ts_tree_cursor_reset_wasm)(e),_ts_tree_cursor_reset_to_wasm=Module._ts_tree_cursor_reset_to_wasm=(e,t)=>(_ts_tree_cursor_reset_to_wasm=Module._ts_tree_cursor_reset_to_wasm=wasmExports.ts_tree_cursor_reset_to_wasm)(e,t),_ts_tree_cursor_goto_first_child_wasm=Module._ts_tree_cursor_goto_first_child_wasm=e=>(_ts_tree_cursor_goto_first_child_wasm=Module._ts_tree_cursor_goto_first_child_wasm=wasmExports.ts_tree_cursor_goto_first_child_wasm)(e),_ts_tree_cursor_goto_last_child_wasm=Module._ts_tree_cursor_goto_last_child_wasm=e=>(_ts_tree_cursor_goto_last_child_wasm=Module._ts_tree_cursor_goto_last_child_wasm=wasmExports.ts_tree_cursor_goto_last_child_wasm)(e),_ts_tree_cursor_goto_first_child_for_index_wasm=Module._ts_tree_cursor_goto_first_child_for_index_wasm=e=>(_ts_tree_cursor_goto_first_child_for_index_wasm=Module._ts_tree_cursor_goto_first_child_for_index_wasm=wasmExports.ts_tree_cursor_goto_first_child_for_index_wasm)(e),_ts_tree_cursor_goto_first_child_for_position_wasm=Module._ts_tree_cursor_goto_first_child_for_position_wasm=e=>(_ts_tree_cursor_goto_first_child_for_position_wasm=Module._ts_tree_cursor_goto_first_child_for_position_wasm=wasmExports.ts_tree_cursor_goto_first_child_for_position_wasm)(e),_ts_tree_cursor_goto_next_sibling_wasm=Module._ts_tree_cursor_goto_next_sibling_wasm=e=>(_ts_tree_cursor_goto_next_sibling_wasm=Module._ts_tree_cursor_goto_next_sibling_wasm=wasmExports.ts_tree_cursor_goto_next_sibling_wasm)(e),_ts_tree_cursor_goto_previous_sibling_wasm=Module._ts_tree_cursor_goto_previous_sibling_wasm=e=>(_ts_tree_cursor_goto_previous_sibling_wasm=Module._ts_tree_cursor_goto_previous_sibling_wasm=wasmExports.ts_tree_cursor_goto_previous_sibling_wasm)(e),_ts_tree_cursor_goto_descendant_wasm=Module._ts_tree_cursor_goto_descendant_wasm=(e,t)=>(_ts_tree_cursor_goto_descendant_wasm=Module._ts_tree_cursor_goto_descendant_wasm=wasmExports.ts_tree_cursor_goto_descendant_wasm)(e,t),_ts_tree_cursor_goto_parent_wasm=Module._ts_tree_cursor_goto_parent_wasm=e=>(_ts_tree_cursor_goto_parent_wasm=Module._ts_tree_cursor_goto_parent_wasm=wasmExports.ts_tree_cursor_goto_parent_wasm)(e),_ts_tree_cursor_current_node_type_id_wasm=Module._ts_tree_cursor_current_node_type_id_wasm=e=>(_ts_tree_cursor_current_node_type_id_wasm=Module._ts_tree_cursor_current_node_type_id_wasm=wasmExports.ts_tree_cursor_current_node_type_id_wasm)(e),_ts_tree_cursor_current_node_state_id_wasm=Module._ts_tree_cursor_current_node_state_id_wasm=e=>(_ts_tree_cursor_current_node_state_id_wasm=Module._ts_tree_cursor_current_node_state_id_wasm=wasmExports.ts_tree_cursor_current_node_state_id_wasm)(e),_ts_tree_cursor_current_node_is_named_wasm=Module._ts_tree_cursor_current_node_is_named_wasm=e=>(_ts_tree_cursor_current_node_is_named_wasm=Module._ts_tree_cursor_current_node_is_named_wasm=wasmExports.ts_tree_cursor_current_node_is_named_wasm)(e),_ts_tree_cursor_current_node_is_missing_wasm=Module._ts_tree_cursor_current_node_is_missing_wasm=e=>(_ts_tree_cursor_current_node_is_missing_wasm=Module._ts_tree_cursor_current_node_is_missing_wasm=wasmExports.ts_tree_cursor_current_node_is_missing_wasm)(e),_ts_tree_cursor_current_node_id_wasm=Module._ts_tree_cursor_current_node_id_wasm=e=>(_ts_tree_cursor_current_node_id_wasm=Module._ts_tree_cursor_current_node_id_wasm=wasmExports.ts_tree_cursor_current_node_id_wasm)(e),_ts_tree_cursor_start_position_wasm=Module._ts_tree_cursor_start_position_wasm=e=>(_ts_tree_cursor_start_position_wasm=Module._ts_tree_cursor_start_position_wasm=wasmExports.ts_tree_cursor_start_position_wasm)(e),_ts_tree_cursor_end_position_wasm=Module._ts_tree_cursor_end_position_wasm=e=>(_ts_tree_cursor_end_position_wasm=Module._ts_tree_cursor_end_position_wasm=wasmExports.ts_tree_cursor_end_position_wasm)(e),_ts_tree_cursor_start_index_wasm=Module._ts_tree_cursor_start_index_wasm=e=>(_ts_tree_cursor_start_index_wasm=Module._ts_tree_cursor_start_index_wasm=wasmExports.ts_tree_cursor_start_index_wasm)(e),_ts_tree_cursor_end_index_wasm=Module._ts_tree_cursor_end_index_wasm=e=>(_ts_tree_cursor_end_index_wasm=Module._ts_tree_cursor_end_index_wasm=wasmExports.ts_tree_cursor_end_index_wasm)(e),_ts_tree_cursor_current_field_id_wasm=Module._ts_tree_cursor_current_field_id_wasm=e=>(_ts_tree_cursor_current_field_id_wasm=Module._ts_tree_cursor_current_field_id_wasm=wasmExports.ts_tree_cursor_current_field_id_wasm)(e),_ts_tree_cursor_current_depth_wasm=Module._ts_tree_cursor_current_depth_wasm=e=>(_ts_tree_cursor_current_depth_wasm=Module._ts_tree_cursor_current_depth_wasm=wasmExports.ts_tree_cursor_current_depth_wasm)(e),_ts_tree_cursor_current_descendant_index_wasm=Module._ts_tree_cursor_current_descendant_index_wasm=e=>(_ts_tree_cursor_current_descendant_index_wasm=Module._ts_tree_cursor_current_descendant_index_wasm=wasmExports.ts_tree_cursor_current_descendant_index_wasm)(e),_ts_tree_cursor_current_node_wasm=Module._ts_tree_cursor_current_node_wasm=e=>(_ts_tree_cursor_current_node_wasm=Module._ts_tree_cursor_current_node_wasm=wasmExports.ts_tree_cursor_current_node_wasm)(e),_ts_node_symbol_wasm=Module._ts_node_symbol_wasm=e=>(_ts_node_symbol_wasm=Module._ts_node_symbol_wasm=wasmExports.ts_node_symbol_wasm)(e),_ts_node_field_name_for_child_wasm=Module._ts_node_field_name_for_child_wasm=(e,t)=>(_ts_node_field_name_for_child_wasm=Module._ts_node_field_name_for_child_wasm=wasmExports.ts_node_field_name_for_child_wasm)(e,t),_ts_node_children_by_field_id_wasm=Module._ts_node_children_by_field_id_wasm=(e,t)=>(_ts_node_children_by_field_id_wasm=Module._ts_node_children_by_field_id_wasm=wasmExports.ts_node_children_by_field_id_wasm)(e,t),_ts_node_first_child_for_byte_wasm=Module._ts_node_first_child_for_byte_wasm=e=>(_ts_node_first_child_for_byte_wasm=Module._ts_node_first_child_for_byte_wasm=wasmExports.ts_node_first_child_for_byte_wasm)(e),_ts_node_first_named_child_for_byte_wasm=Module._ts_node_first_named_child_for_byte_wasm=e=>(_ts_node_first_named_child_for_byte_wasm=Module._ts_node_first_named_child_for_byte_wasm=wasmExports.ts_node_first_named_child_for_byte_wasm)(e),_ts_node_grammar_symbol_wasm=Module._ts_node_grammar_symbol_wasm=e=>(_ts_node_grammar_symbol_wasm=Module._ts_node_grammar_symbol_wasm=wasmExports.ts_node_grammar_symbol_wasm)(e),_ts_node_child_count_wasm=Module._ts_node_child_count_wasm=e=>(_ts_node_child_count_wasm=Module._ts_node_child_count_wasm=wasmExports.ts_node_child_count_wasm)(e),_ts_node_named_child_count_wasm=Module._ts_node_named_child_count_wasm=e=>(_ts_node_named_child_count_wasm=Module._ts_node_named_child_count_wasm=wasmExports.ts_node_named_child_count_wasm)(e),_ts_node_child_wasm=Module._ts_node_child_wasm=(e,t)=>(_ts_node_child_wasm=Module._ts_node_child_wasm=wasmExports.ts_node_child_wasm)(e,t),_ts_node_named_child_wasm=Module._ts_node_named_child_wasm=(e,t)=>(_ts_node_named_child_wasm=Module._ts_node_named_child_wasm=wasmExports.ts_node_named_child_wasm)(e,t),_ts_node_child_by_field_id_wasm=Module._ts_node_child_by_field_id_wasm=(e,t)=>(_ts_node_child_by_field_id_wasm=Module._ts_node_child_by_field_id_wasm=wasmExports.ts_node_child_by_field_id_wasm)(e,t),_ts_node_next_sibling_wasm=Module._ts_node_next_sibling_wasm=e=>(_ts_node_next_sibling_wasm=Module._ts_node_next_sibling_wasm=wasmExports.ts_node_next_sibling_wasm)(e),_ts_node_prev_sibling_wasm=Module._ts_node_prev_sibling_wasm=e=>(_ts_node_prev_sibling_wasm=Module._ts_node_prev_sibling_wasm=wasmExports.ts_node_prev_sibling_wasm)(e),_ts_node_next_named_sibling_wasm=Module._ts_node_next_named_sibling_wasm=e=>(_ts_node_next_named_sibling_wasm=Module._ts_node_next_named_sibling_wasm=wasmExports.ts_node_next_named_sibling_wasm)(e),_ts_node_prev_named_sibling_wasm=Module._ts_node_prev_named_sibling_wasm=e=>(_ts_node_prev_named_sibling_wasm=Module._ts_node_prev_named_sibling_wasm=wasmExports.ts_node_prev_named_sibling_wasm)(e),_ts_node_descendant_count_wasm=Module._ts_node_descendant_count_wasm=e=>(_ts_node_descendant_count_wasm=Module._ts_node_descendant_count_wasm=wasmExports.ts_node_descendant_count_wasm)(e),_ts_node_parent_wasm=Module._ts_node_parent_wasm=e=>(_ts_node_parent_wasm=Module._ts_node_parent_wasm=wasmExports.ts_node_parent_wasm)(e),_ts_node_descendant_for_index_wasm=Module._ts_node_descendant_for_index_wasm=e=>(_ts_node_descendant_for_index_wasm=Module._ts_node_descendant_for_index_wasm=wasmExports.ts_node_descendant_for_index_wasm)(e),_ts_node_named_descendant_for_index_wasm=Module._ts_node_named_descendant_for_index_wasm=e=>(_ts_node_named_descendant_for_index_wasm=Module._ts_node_named_descendant_for_index_wasm=wasmExports.ts_node_named_descendant_for_index_wasm)(e),_ts_node_descendant_for_position_wasm=Module._ts_node_descendant_for_position_wasm=e=>(_ts_node_descendant_for_position_wasm=Module._ts_node_descendant_for_position_wasm=wasmExports.ts_node_descendant_for_position_wasm)(e),_ts_node_named_descendant_for_position_wasm=Module._ts_node_named_descendant_for_position_wasm=e=>(_ts_node_named_descendant_for_position_wasm=Module._ts_node_named_descendant_for_position_wasm=wasmExports.ts_node_named_descendant_for_position_wasm)(e),_ts_node_start_point_wasm=Module._ts_node_start_point_wasm=e=>(_ts_node_start_point_wasm=Module._ts_node_start_point_wasm=wasmExports.ts_node_start_point_wasm)(e),_ts_node_end_point_wasm=Module._ts_node_end_point_wasm=e=>(_ts_node_end_point_wasm=Module._ts_node_end_point_wasm=wasmExports.ts_node_end_point_wasm)(e),_ts_node_start_index_wasm=Module._ts_node_start_index_wasm=e=>(_ts_node_start_index_wasm=Module._ts_node_start_index_wasm=wasmExports.ts_node_start_index_wasm)(e),_ts_node_end_index_wasm=Module._ts_node_end_index_wasm=e=>(_ts_node_end_index_wasm=Module._ts_node_end_index_wasm=wasmExports.ts_node_end_index_wasm)(e),_ts_node_to_string_wasm=Module._ts_node_to_string_wasm=e=>(_ts_node_to_string_wasm=Module._ts_node_to_string_wasm=wasmExports.ts_node_to_string_wasm)(e),_ts_node_children_wasm=Module._ts_node_children_wasm=e=>(_ts_node_children_wasm=Module._ts_node_children_wasm=wasmExports.ts_node_children_wasm)(e),_ts_node_named_children_wasm=Module._ts_node_named_children_wasm=e=>(_ts_node_named_children_wasm=Module._ts_node_named_children_wasm=wasmExports.ts_node_named_children_wasm)(e),_ts_node_descendants_of_type_wasm=Module._ts_node_descendants_of_type_wasm=(e,t,r,s,n,o,a)=>(_ts_node_descendants_of_type_wasm=Module._ts_node_descendants_of_type_wasm=wasmExports.ts_node_descendants_of_type_wasm)(e,t,r,s,n,o,a),_ts_node_is_named_wasm=Module._ts_node_is_named_wasm=e=>(_ts_node_is_named_wasm=Module._ts_node_is_named_wasm=wasmExports.ts_node_is_named_wasm)(e),_ts_node_has_changes_wasm=Module._ts_node_has_changes_wasm=e=>(_ts_node_has_changes_wasm=Module._ts_node_has_changes_wasm=wasmExports.ts_node_has_changes_wasm)(e),_ts_node_has_error_wasm=Module._ts_node_has_error_wasm=e=>(_ts_node_has_error_wasm=Module._ts_node_has_error_wasm=wasmExports.ts_node_has_error_wasm)(e),_ts_node_is_error_wasm=Module._ts_node_is_error_wasm=e=>(_ts_node_is_error_wasm=Module._ts_node_is_error_wasm=wasmExports.ts_node_is_error_wasm)(e),_ts_node_is_missing_wasm=Module._ts_node_is_missing_wasm=e=>(_ts_node_is_missing_wasm=Module._ts_node_is_missing_wasm=wasmExports.ts_node_is_missing_wasm)(e),_ts_node_is_extra_wasm=Module._ts_node_is_extra_wasm=e=>(_ts_node_is_extra_wasm=Module._ts_node_is_extra_wasm=wasmExports.ts_node_is_extra_wasm)(e),_ts_node_parse_state_wasm=Module._ts_node_parse_state_wasm=e=>(_ts_node_parse_state_wasm=Module._ts_node_parse_state_wasm=wasmExports.ts_node_parse_state_wasm)(e),_ts_node_next_parse_state_wasm=Module._ts_node_next_parse_state_wasm=e=>(_ts_node_next_parse_state_wasm=Module._ts_node_next_parse_state_wasm=wasmExports.ts_node_next_parse_state_wasm)(e),_ts_query_matches_wasm=Module._ts_query_matches_wasm=(e,t,r,s,n,o,a,i,l,_,u)=>(_ts_query_matches_wasm=Module._ts_query_matches_wasm=wasmExports.ts_query_matches_wasm)(e,t,r,s,n,o,a,i,l,_,u),_ts_query_captures_wasm=Module._ts_query_captures_wasm=(e,t,r,s,n,o,a,i,l,_,u)=>(_ts_query_captures_wasm=Module._ts_query_captures_wasm=wasmExports.ts_query_captures_wasm)(e,t,r,s,n,o,a,i,l,_,u),_iswalpha=Module._iswalpha=e=>(_iswalpha=Module._iswalpha=wasmExports.iswalpha)(e),_iswblank=Module._iswblank=e=>(_iswblank=Module._iswblank=wasmExports.iswblank)(e),_iswdigit=Module._iswdigit=e=>(_iswdigit=Module._iswdigit=wasmExports.iswdigit)(e),_iswlower=Module._iswlower=e=>(_iswlower=Module._iswlower=wasmExports.iswlower)(e),_iswupper=Module._iswupper=e=>(_iswupper=Module._iswupper=wasmExports.iswupper)(e),_iswxdigit=Module._iswxdigit=e=>(_iswxdigit=Module._iswxdigit=wasmExports.iswxdigit)(e),_memchr=Module._memchr=(e,t,r)=>(_memchr=Module._memchr=wasmExports.memchr)(e,t,r),_strlen=Module._strlen=e=>(_strlen=Module._strlen=wasmExports.strlen)(e),_strcmp=Module._strcmp=(e,t)=>(_strcmp=Module._strcmp=wasmExports.strcmp)(e,t),_strncat=Module._strncat=(e,t,r)=>(_strncat=Module._strncat=wasmExports.strncat)(e,t,r),_strncpy=Module._strncpy=(e,t,r)=>(_strncpy=Module._strncpy=wasmExports.strncpy)(e,t,r),_towlower=Module._towlower=e=>(_towlower=Module._towlower=wasmExports.towlower)(e),_towupper=Module._towupper=e=>(_towupper=Module._towupper=wasmExports.towupper)(e),_setThrew=(e,t)=>(_setThrew=wasmExports.setThrew)(e,t),__emscripten_stack_restore=e=>(__emscripten_stack_restore=wasmExports._emscripten_stack_restore)(e),__emscripten_stack_alloc=e=>(__emscripten_stack_alloc=wasmExports._emscripten_stack_alloc)(e),_emscripten_stack_get_current=()=>(_emscripten_stack_get_current=wasmExports.emscripten_stack_get_current)(),dynCall_jiji=Module.dynCall_jiji=(e,t,r,s,n)=>(dynCall_jiji=Module.dynCall_jiji=wasmExports.dynCall_jiji)(e,t,r,s,n),_orig$ts_parser_timeout_micros=Module._orig$ts_parser_timeout_micros=e=>(_orig$ts_parser_timeout_micros=Module._orig$ts_parser_timeout_micros=wasmExports.orig$ts_parser_timeout_micros)(e),_orig$ts_parser_set_timeout_micros=Module._orig$ts_parser_set_timeout_micros=(e,t)=>(_orig$ts_parser_set_timeout_micros=Module._orig$ts_parser_set_timeout_micros=wasmExports.orig$ts_parser_set_timeout_micros)(e,t),calledRun;function callMain(t=[]){var r=resolveGlobalSymbol("main").sym;if(r){t.unshift(thisProgram);var s=t.length,n=stackAlloc(4*(s+1)),o=n;t.forEach((e=>{LE_HEAP_STORE_U32(4*(o>>2),stringToUTF8OnStack(e)),o+=4})),LE_HEAP_STORE_U32(4*(o>>2),0);try{var a=r(s,n);return exitJS(a,!0),a}catch(e){return handleException(e)}}}function run(e=arguments_){function t(){calledRun||(calledRun=!0,Module.calledRun=!0,ABORT||(initRuntime(),preMain(),Module.onRuntimeInitialized?.(),shouldRunNow&&callMain(e),postRun()))}runDependencies>0||(preRun(),runDependencies>0||(Module.setStatus?(Module.setStatus("Running..."),setTimeout((function(){setTimeout((function(){Module.setStatus("")}),1),t()}),1)):t()))}if(Module.AsciiToString=AsciiToString,Module.stringToUTF16=stringToUTF16,dependenciesFulfilled=function e(){calledRun||run(),calledRun||(dependenciesFulfilled=e)},Module.preInit)for("function"==typeof Module.preInit&&(Module.preInit=[Module.preInit]);Module.preInit.length>0;)Module.preInit.pop()();var shouldRunNow=!0;Module.noInitialRun&&(shouldRunNow=!1),run();const C=Module,INTERNAL={},SIZE_OF_INT=4,SIZE_OF_CURSOR=4*SIZE_OF_INT,SIZE_OF_NODE=5*SIZE_OF_INT,SIZE_OF_POINT=2*SIZE_OF_INT,SIZE_OF_RANGE=2*SIZE_OF_INT+2*SIZE_OF_POINT,ZERO_POINT={row:0,column:0},QUERY_WORD_REGEX=/[\w-.]*/g,PREDICATE_STEP_TYPE_CAPTURE=1,PREDICATE_STEP_TYPE_STRING=2,LANGUAGE_FUNCTION_REGEX=/^_?tree_sitter_\w+/;let VERSION,MIN_COMPATIBLE_VERSION,TRANSFER_BUFFER,currentParseCallback,currentLogCallback;class ParserImpl{static init(){TRANSFER_BUFFER=C._ts_init(),VERSION=getValue(TRANSFER_BUFFER,"i32"),MIN_COMPATIBLE_VERSION=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32")}initialize(){C._ts_parser_new_wasm(),this[0]=getValue(TRANSFER_BUFFER,"i32"),this[1]=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32")}delete(){C._ts_parser_delete(this[0]),C._free(this[1]),this[0]=0,this[1]=0}setLanguage(e){let t;if(e){if(e.constructor!==Language)throw new Error("Argument must be a Language");{t=e[0];const r=C._ts_language_version(t);if(r<MIN_COMPATIBLE_VERSION||VERSION<r)throw new Error(`Incompatible language version ${r}. Compatibility range ${MIN_COMPATIBLE_VERSION} through ${VERSION}.`)}}else t=0,e=null;return this.language=e,C._ts_parser_set_language(this[0],t),this}getLanguage(){return this.language}parse(e,t,r){if("string"==typeof e)currentParseCallback=(t,r)=>e.slice(t);else{if("function"!=typeof e)throw new Error("Argument must be a string or a function");currentParseCallback=e}this.logCallback?(currentLogCallback=this.logCallback,C._ts_parser_enable_logger_wasm(this[0],1)):(currentLogCallback=null,C._ts_parser_enable_logger_wasm(this[0],0));let s=0,n=0;if(r?.includedRanges){s=r.includedRanges.length,n=C._calloc(s,SIZE_OF_RANGE);let e=n;for(let t=0;t<s;t++)marshalRange(e,r.includedRanges[t]),e+=SIZE_OF_RANGE}const o=C._ts_parser_parse_wasm(this[0],this[1],t?t[0]:0,n,s);if(!o)throw currentParseCallback=null,currentLogCallback=null,new Error("Parsing failed");const a=new Tree(INTERNAL,o,this.language,currentParseCallback);return currentParseCallback=null,currentLogCallback=null,a}reset(){C._ts_parser_reset(this[0])}getIncludedRanges(){C._ts_parser_included_ranges_wasm(this[0]);const e=getValue(TRANSFER_BUFFER,"i32"),t=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),r=new Array(e);if(e>0){let s=t;for(let t=0;t<e;t++)r[t]=unmarshalRange(s),s+=SIZE_OF_RANGE;C._free(t)}return r}getTimeoutMicros(){return C._ts_parser_timeout_micros(this[0])}setTimeoutMicros(e){C._ts_parser_set_timeout_micros(this[0],e)}setLogger(e){if(e){if("function"!=typeof e)throw new Error("Logger callback must be a function")}else e=null;return this.logCallback=e,this}getLogger(){return this.logCallback}}class Tree{constructor(e,t,r,s){assertInternal(e),this[0]=t,this.language=r,this.textCallback=s}copy(){return new Tree(INTERNAL,C._ts_tree_copy(this[0]),this.language,this.textCallback)}delete(){C._ts_tree_delete(this[0]),this[0]=0}edit(e){marshalEdit(e),C._ts_tree_edit_wasm(this[0])}get rootNode(){return C._ts_tree_root_node_wasm(this[0]),unmarshalNode(this)}rootNodeWithOffset(e,t){const r=TRANSFER_BUFFER+SIZE_OF_NODE;return setValue(r,e,"i32"),marshalPoint(r+SIZE_OF_INT,t),C._ts_tree_root_node_with_offset_wasm(this[0]),unmarshalNode(this)}getLanguage(){return this.language}walk(){return this.rootNode.walk()}getChangedRanges(e){if(e.constructor!==Tree)throw new TypeError("Argument must be a Tree");C._ts_tree_get_changed_ranges_wasm(this[0],e[0]);const t=getValue(TRANSFER_BUFFER,"i32"),r=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),s=new Array(t);if(t>0){let e=r;for(let r=0;r<t;r++)s[r]=unmarshalRange(e),e+=SIZE_OF_RANGE;C._free(r)}return s}getIncludedRanges(){C._ts_tree_included_ranges_wasm(this[0]);const e=getValue(TRANSFER_BUFFER,"i32"),t=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),r=new Array(e);if(e>0){let s=t;for(let t=0;t<e;t++)r[t]=unmarshalRange(s),s+=SIZE_OF_RANGE;C._free(t)}return r}}class Node{constructor(e,t){assertInternal(e),this.tree=t}get typeId(){return marshalNode(this),C._ts_node_symbol_wasm(this.tree[0])}get grammarId(){return marshalNode(this),C._ts_node_grammar_symbol_wasm(this.tree[0])}get type(){return this.tree.language.types[this.typeId]||"ERROR"}get grammarType(){return this.tree.language.types[this.grammarId]||"ERROR"}get endPosition(){return marshalNode(this),C._ts_node_end_point_wasm(this.tree[0]),unmarshalPoint(TRANSFER_BUFFER)}get endIndex(){return marshalNode(this),C._ts_node_end_index_wasm(this.tree[0])}get text(){return getText(this.tree,this.startIndex,this.endIndex)}get parseState(){return marshalNode(this),C._ts_node_parse_state_wasm(this.tree[0])}get nextParseState(){return marshalNode(this),C._ts_node_next_parse_state_wasm(this.tree[0])}get isNamed(){return marshalNode(this),1===C._ts_node_is_named_wasm(this.tree[0])}get hasError(){return marshalNode(this),1===C._ts_node_has_error_wasm(this.tree[0])}get hasChanges(){return marshalNode(this),1===C._ts_node_has_changes_wasm(this.tree[0])}get isError(){return marshalNode(this),1===C._ts_node_is_error_wasm(this.tree[0])}get isMissing(){return marshalNode(this),1===C._ts_node_is_missing_wasm(this.tree[0])}get isExtra(){return marshalNode(this),1===C._ts_node_is_extra_wasm(this.tree[0])}equals(e){return this.id===e.id}child(e){return marshalNode(this),C._ts_node_child_wasm(this.tree[0],e),unmarshalNode(this.tree)}namedChild(e){return marshalNode(this),C._ts_node_named_child_wasm(this.tree[0],e),unmarshalNode(this.tree)}childForFieldId(e){return marshalNode(this),C._ts_node_child_by_field_id_wasm(this.tree[0],e),unmarshalNode(this.tree)}childForFieldName(e){const t=this.tree.language.fields.indexOf(e);return-1!==t?this.childForFieldId(t):null}fieldNameForChild(e){marshalNode(this);const t=C._ts_node_field_name_for_child_wasm(this.tree[0],e);return t?AsciiToString(t):null}childrenForFieldName(e){const t=this.tree.language.fields.indexOf(e);return-1!==t&&0!==t?this.childrenForFieldId(t):[]}childrenForFieldId(e){marshalNode(this),C._ts_node_children_by_field_id_wasm(this.tree[0],e);const t=getValue(TRANSFER_BUFFER,"i32"),r=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),s=new Array(t);if(t>0){let e=r;for(let r=0;r<t;r++)s[r]=unmarshalNode(this.tree,e),e+=SIZE_OF_NODE;C._free(r)}return s}firstChildForIndex(e){return marshalNode(this),setValue(TRANSFER_BUFFER+SIZE_OF_NODE,e,"i32"),C._ts_node_first_child_for_byte_wasm(this.tree[0]),unmarshalNode(this.tree)}firstNamedChildForIndex(e){return marshalNode(this),setValue(TRANSFER_BUFFER+SIZE_OF_NODE,e,"i32"),C._ts_node_first_named_child_for_byte_wasm(this.tree[0]),unmarshalNode(this.tree)}get childCount(){return marshalNode(this),C._ts_node_child_count_wasm(this.tree[0])}get namedChildCount(){return marshalNode(this),C._ts_node_named_child_count_wasm(this.tree[0])}get firstChild(){return this.child(0)}get firstNamedChild(){return this.namedChild(0)}get lastChild(){return this.child(this.childCount-1)}get lastNamedChild(){return this.namedChild(this.namedChildCount-1)}get children(){if(!this._children){marshalNode(this),C._ts_node_children_wasm(this.tree[0]);const e=getValue(TRANSFER_BUFFER,"i32"),t=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32");if(this._children=new Array(e),e>0){let r=t;for(let t=0;t<e;t++)this._children[t]=unmarshalNode(this.tree,r),r+=SIZE_OF_NODE;C._free(t)}}return this._children}get namedChildren(){if(!this._namedChildren){marshalNode(this),C._ts_node_named_children_wasm(this.tree[0]);const e=getValue(TRANSFER_BUFFER,"i32"),t=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32");if(this._namedChildren=new Array(e),e>0){let r=t;for(let t=0;t<e;t++)this._namedChildren[t]=unmarshalNode(this.tree,r),r+=SIZE_OF_NODE;C._free(t)}}return this._namedChildren}descendantsOfType(e,t,r){Array.isArray(e)||(e=[e]),t||(t=ZERO_POINT),r||(r=ZERO_POINT);const s=[],n=this.tree.language.types;for(let _=0,u=n.length;_<u;_++)e.includes(n[_])&&s.push(_);const o=C._malloc(SIZE_OF_INT*s.length);for(let _=0,u=s.length;_<u;_++)setValue(o+_*SIZE_OF_INT,s[_],"i32");marshalNode(this),C._ts_node_descendants_of_type_wasm(this.tree[0],o,s.length,t.row,t.column,r.row,r.column);const a=getValue(TRANSFER_BUFFER,"i32"),i=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),l=new Array(a);if(a>0){let e=i;for(let t=0;t<a;t++)l[t]=unmarshalNode(this.tree,e),e+=SIZE_OF_NODE}return C._free(i),C._free(o),l}get nextSibling(){return marshalNode(this),C._ts_node_next_sibling_wasm(this.tree[0]),unmarshalNode(this.tree)}get previousSibling(){return marshalNode(this),C._ts_node_prev_sibling_wasm(this.tree[0]),unmarshalNode(this.tree)}get nextNamedSibling(){return marshalNode(this),C._ts_node_next_named_sibling_wasm(this.tree[0]),unmarshalNode(this.tree)}get previousNamedSibling(){return marshalNode(this),C._ts_node_prev_named_sibling_wasm(this.tree[0]),unmarshalNode(this.tree)}get descendantCount(){return marshalNode(this),C._ts_node_descendant_count_wasm(this.tree[0])}get parent(){return marshalNode(this),C._ts_node_parent_wasm(this.tree[0]),unmarshalNode(this.tree)}descendantForIndex(e,t=e){if("number"!=typeof e||"number"!=typeof t)throw new Error("Arguments must be numbers");marshalNode(this);const r=TRANSFER_BUFFER+SIZE_OF_NODE;return setValue(r,e,"i32"),setValue(r+SIZE_OF_INT,t,"i32"),C._ts_node_descendant_for_index_wasm(this.tree[0]),unmarshalNode(this.tree)}namedDescendantForIndex(e,t=e){if("number"!=typeof e||"number"!=typeof t)throw new Error("Arguments must be numbers");marshalNode(this);const r=TRANSFER_BUFFER+SIZE_OF_NODE;return setValue(r,e,"i32"),setValue(r+SIZE_OF_INT,t,"i32"),C._ts_node_named_descendant_for_index_wasm(this.tree[0]),unmarshalNode(this.tree)}descendantForPosition(e,t=e){if(!isPoint(e)||!isPoint(t))throw new Error("Arguments must be {row, column} objects");marshalNode(this);const r=TRANSFER_BUFFER+SIZE_OF_NODE;return marshalPoint(r,e),marshalPoint(r+SIZE_OF_POINT,t),C._ts_node_descendant_for_position_wasm(this.tree[0]),unmarshalNode(this.tree)}namedDescendantForPosition(e,t=e){if(!isPoint(e)||!isPoint(t))throw new Error("Arguments must be {row, column} objects");marshalNode(this);const r=TRANSFER_BUFFER+SIZE_OF_NODE;return marshalPoint(r,e),marshalPoint(r+SIZE_OF_POINT,t),C._ts_node_named_descendant_for_position_wasm(this.tree[0]),unmarshalNode(this.tree)}walk(){return marshalNode(this),C._ts_tree_cursor_new_wasm(this.tree[0]),new TreeCursor(INTERNAL,this.tree)}toString(){marshalNode(this);const e=C._ts_node_to_string_wasm(this.tree[0]),t=AsciiToString(e);return C._free(e),t}}class TreeCursor{constructor(e,t){assertInternal(e),this.tree=t,unmarshalTreeCursor(this)}delete(){marshalTreeCursor(this),C._ts_tree_cursor_delete_wasm(this.tree[0]),this[0]=this[1]=this[2]=0}reset(e){marshalNode(e),marshalTreeCursor(this,TRANSFER_BUFFER+SIZE_OF_NODE),C._ts_tree_cursor_reset_wasm(this.tree[0]),unmarshalTreeCursor(this)}resetTo(e){marshalTreeCursor(this,TRANSFER_BUFFER),marshalTreeCursor(e,TRANSFER_BUFFER+SIZE_OF_CURSOR),C._ts_tree_cursor_reset_to_wasm(this.tree[0],e.tree[0]),unmarshalTreeCursor(this)}get nodeType(){return this.tree.language.types[this.nodeTypeId]||"ERROR"}get nodeTypeId(){return marshalTreeCursor(this),C._ts_tree_cursor_current_node_type_id_wasm(this.tree[0])}get nodeStateId(){return marshalTreeCursor(this),C._ts_tree_cursor_current_node_state_id_wasm(this.tree[0])}get nodeId(){return marshalTreeCursor(this),C._ts_tree_cursor_current_node_id_wasm(this.tree[0])}get nodeIsNamed(){return marshalTreeCursor(this),1===C._ts_tree_cursor_current_node_is_named_wasm(this.tree[0])}get nodeIsMissing(){return marshalTreeCursor(this),1===C._ts_tree_cursor_current_node_is_missing_wasm(this.tree[0])}get nodeText(){marshalTreeCursor(this);const e=C._ts_tree_cursor_start_index_wasm(this.tree[0]),t=C._ts_tree_cursor_end_index_wasm(this.tree[0]);return getText(this.tree,e,t)}get startPosition(){return marshalTreeCursor(this),C._ts_tree_cursor_start_position_wasm(this.tree[0]),unmarshalPoint(TRANSFER_BUFFER)}get endPosition(){return marshalTreeCursor(this),C._ts_tree_cursor_end_position_wasm(this.tree[0]),unmarshalPoint(TRANSFER_BUFFER)}get startIndex(){return marshalTreeCursor(this),C._ts_tree_cursor_start_index_wasm(this.tree[0])}get endIndex(){return marshalTreeCursor(this),C._ts_tree_cursor_end_index_wasm(this.tree[0])}get currentNode(){return marshalTreeCursor(this),C._ts_tree_cursor_current_node_wasm(this.tree[0]),unmarshalNode(this.tree)}get currentFieldId(){return marshalTreeCursor(this),C._ts_tree_cursor_current_field_id_wasm(this.tree[0])}get currentFieldName(){return this.tree.language.fields[this.currentFieldId]}get currentDepth(){return marshalTreeCursor(this),C._ts_tree_cursor_current_depth_wasm(this.tree[0])}get currentDescendantIndex(){return marshalTreeCursor(this),C._ts_tree_cursor_current_descendant_index_wasm(this.tree[0])}gotoFirstChild(){marshalTreeCursor(this);const e=C._ts_tree_cursor_goto_first_child_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===e}gotoLastChild(){marshalTreeCursor(this);const e=C._ts_tree_cursor_goto_last_child_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===e}gotoFirstChildForIndex(e){marshalTreeCursor(this),setValue(TRANSFER_BUFFER+SIZE_OF_CURSOR,e,"i32");const t=C._ts_tree_cursor_goto_first_child_for_index_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===t}gotoFirstChildForPosition(e){marshalTreeCursor(this),marshalPoint(TRANSFER_BUFFER+SIZE_OF_CURSOR,e);const t=C._ts_tree_cursor_goto_first_child_for_position_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===t}gotoNextSibling(){marshalTreeCursor(this);const e=C._ts_tree_cursor_goto_next_sibling_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===e}gotoPreviousSibling(){marshalTreeCursor(this);const e=C._ts_tree_cursor_goto_previous_sibling_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===e}gotoDescendant(e){marshalTreeCursor(this),C._ts_tree_cursor_goto_descendant_wasm(this.tree[0],e),unmarshalTreeCursor(this)}gotoParent(){marshalTreeCursor(this);const e=C._ts_tree_cursor_goto_parent_wasm(this.tree[0]);return unmarshalTreeCursor(this),1===e}}class Language{constructor(e,t){assertInternal(e),this[0]=t,this.types=new Array(C._ts_language_symbol_count(this[0]));for(let r=0,s=this.types.length;r<s;r++)C._ts_language_symbol_type(this[0],r)<2&&(this.types[r]=UTF8ToString(C._ts_language_symbol_name(this[0],r)));this.fields=new Array(C._ts_language_field_count(this[0])+1);for(let r=0,s=this.fields.length;r<s;r++){const e=C._ts_language_field_name_for_id(this[0],r);this.fields[r]=0!==e?UTF8ToString(e):null}}get version(){return C._ts_language_version(this[0])}get fieldCount(){return this.fields.length-1}get stateCount(){return C._ts_language_state_count(this[0])}fieldIdForName(e){const t=this.fields.indexOf(e);return-1!==t?t:null}fieldNameForId(e){return this.fields[e]||null}idForNodeType(e,t){const r=lengthBytesUTF8(e),s=C._malloc(r+1);stringToUTF8(e,s,r+1);const n=C._ts_language_symbol_for_name(this[0],s,r,t);return C._free(s),n||null}get nodeTypeCount(){return C._ts_language_symbol_count(this[0])}nodeTypeForId(e){const t=C._ts_language_symbol_name(this[0],e);return t?UTF8ToString(t):null}nodeTypeIsNamed(e){return!!C._ts_language_type_is_named_wasm(this[0],e)}nodeTypeIsVisible(e){return!!C._ts_language_type_is_visible_wasm(this[0],e)}nextState(e,t){return C._ts_language_next_state(this[0],e,t)}lookaheadIterator(e){const t=C._ts_lookahead_iterator_new(this[0],e);return t?new LookaheadIterable(INTERNAL,t,this):null}query(e){const t=lengthBytesUTF8(e),r=C._malloc(t+1);stringToUTF8(e,r,t+1);const s=C._ts_query_new(this[0],r,t,TRANSFER_BUFFER,TRANSFER_BUFFER+SIZE_OF_INT);if(!s){const t=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),s=UTF8ToString(r,getValue(TRANSFER_BUFFER,"i32")).length,n=e.substr(s,100).split("\n")[0];let o,a=n.match(QUERY_WORD_REGEX)[0];switch(t){case 2:o=new RangeError(`Bad node name '${a}'`);break;case 3:o=new RangeError(`Bad field name '${a}'`);break;case 4:o=new RangeError(`Bad capture name @${a}`);break;case 5:o=new TypeError(`Bad pattern structure at offset ${s}: '${n}'...`),a="";break;default:o=new SyntaxError(`Bad syntax at offset ${s}: '${n}'...`),a=""}throw o.index=s,o.length=a.length,C._free(r),o}const n=C._ts_query_string_count(s),o=C._ts_query_capture_count(s),a=C._ts_query_pattern_count(s),i=new Array(o),l=new Array(n);for(let m=0;m<o;m++)i[m]=UTF8ToString(C._ts_query_capture_name_for_id(s,m,TRANSFER_BUFFER),getValue(TRANSFER_BUFFER,"i32"));for(let m=0;m<n;m++)l[m]=UTF8ToString(C._ts_query_string_value_for_id(s,m,TRANSFER_BUFFER),getValue(TRANSFER_BUFFER,"i32"));const _=new Array(a),u=new Array(a),p=new Array(a),c=new Array(a),d=new Array(a);for(let m=0;m<a;m++){const e=C._ts_query_predicates_for_pattern(s,m,TRANSFER_BUFFER),t=getValue(TRANSFER_BUFFER,"i32");c[m]=[],d[m]=[];const r=[];let n=e;for(let s=0;s<t;s++){const e=getValue(n,"i32");n+=SIZE_OF_INT;const t=getValue(n,"i32");if(n+=SIZE_OF_INT,e===PREDICATE_STEP_TYPE_CAPTURE)r.push({type:"capture",name:i[t]});else if(e===PREDICATE_STEP_TYPE_STRING)r.push({type:"string",value:l[t]});else if(r.length>0){if("string"!==r[0].type)throw new Error("Predicates must begin with a literal value");const e=r[0].value;let t,s=!0,n=!0;switch(e){case"any-not-eq?":case"not-eq?":s=!1;case"any-eq?":case"eq?":if(3!==r.length)throw new Error(`Wrong number of arguments to \`#${e}\` predicate. Expected 2, got ${r.length-1}`);if("capture"!==r[1].type)throw new Error(`First argument of \`#${e}\` predicate must be a capture. Got "${r[1].value}"`);if(n=!e.startsWith("any-"),"capture"===r[2].type){const e=r[1].name,t=r[2].name;d[m].push((r=>{const o=[],a=[];for(const s of r)s.name===e&&o.push(s.node),s.name===t&&a.push(s.node);const i=(e,t,r)=>r?e.text===t.text:e.text!==t.text;return n?o.every((e=>a.some((t=>i(e,t,s))))):o.some((e=>a.some((t=>i(e,t,s)))))}))}else{t=r[1].name;const e=r[2].value,o=t=>t.text===e,a=t=>t.text!==e;d[m].push((e=>{const r=[];for(const s of e)s.name===t&&r.push(s.node);const i=s?o:a;return n?r.every(i):r.some(i)}))}break;case"any-not-match?":case"not-match?":s=!1;case"any-match?":case"match?":if(3!==r.length)throw new Error(`Wrong number of arguments to \`#${e}\` predicate. Expected 2, got ${r.length-1}.`);if("capture"!==r[1].type)throw new Error(`First argument of \`#${e}\` predicate must be a capture. Got "${r[1].value}".`);if("string"!==r[2].type)throw new Error(`Second argument of \`#${e}\` predicate must be a string. Got @${r[2].value}.`);t=r[1].name;const o=new RegExp(r[2].value);n=!e.startsWith("any-"),d[m].push((e=>{const r=[];for(const s of e)s.name===t&&r.push(s.node.text);const a=(e,t)=>t?o.test(e):!o.test(e);return 0===r.length?!s:n?r.every((e=>a(e,s))):r.some((e=>a(e,s)))}));break;case"set!":if(r.length<2||r.length>3)throw new Error(`Wrong number of arguments to \`#set!\` predicate. Expected 1 or 2. Got ${r.length-1}.`);if(r.some((e=>"string"!==e.type)))throw new Error('Arguments to `#set!` predicate must be a strings.".');_[m]||(_[m]={}),_[m][r[1].value]=r[2]?r[2].value:null;break;case"is?":case"is-not?":if(r.length<2||r.length>3)throw new Error(`Wrong number of arguments to \`#${e}\` predicate. Expected 1 or 2. Got ${r.length-1}.`);if(r.some((e=>"string"!==e.type)))throw new Error(`Arguments to \`#${e}\` predicate must be a strings.".`);const a="is?"===e?u:p;a[m]||(a[m]={}),a[m][r[1].value]=r[2]?r[2].value:null;break;case"not-any-of?":s=!1;case"any-of?":if(r.length<2)throw new Error(`Wrong number of arguments to \`#${e}\` predicate. Expected at least 1. Got ${r.length-1}.`);if("capture"!==r[1].type)throw new Error(`First argument of \`#${e}\` predicate must be a capture. Got "${r[1].value}".`);for(let t=2;t<r.length;t++)if("string"!==r[t].type)throw new Error(`Arguments to \`#${e}\` predicate must be a strings.".`);t=r[1].name;const i=r.slice(2).map((e=>e.value));d[m].push((e=>{const r=[];for(const s of e)s.name===t&&r.push(s.node.text);return 0===r.length?!s:r.every((e=>i.includes(e)))===s}));break;default:c[m].push({operator:e,operands:r.slice(1)})}r.length=0}}Object.freeze(_[m]),Object.freeze(u[m]),Object.freeze(p[m])}return C._free(r),new Query(INTERNAL,s,i,d,c,Object.freeze(_),Object.freeze(u),Object.freeze(p))}static load(e){let t;if(e instanceof Uint8Array)t=Promise.resolve(e);else{const r=e;if("undefined"!=typeof process&&process.versions&&process.versions.node){const e=(init_empty(),__toCommonJS(empty_exports));t=Promise.resolve(e.readFileSync(r))}else t=fetch(r).then((e=>e.arrayBuffer().then((t=>{if(e.ok)return new Uint8Array(t);{const r=new TextDecoder("utf-8").decode(t);throw new Error(`Language.load failed with status ${e.status}.\n\n${r}`)}}))))}return t.then((e=>loadWebAssemblyModule(e,{loadAsync:!0}))).then((e=>{const t=Object.keys(e),r=t.find((e=>LANGUAGE_FUNCTION_REGEX.test(e)&&!e.includes("external_scanner_")));return r||console.log(`Couldn't find language function in WASM file. Symbols:\n${JSON.stringify(t,null,2)}`),new Language(INTERNAL,e[r]())}))}}class LookaheadIterable{constructor(e,t,r){assertInternal(e),this[0]=t,this.language=r}get currentTypeId(){return C._ts_lookahead_iterator_current_symbol(this[0])}get currentType(){return this.language.types[this.currentTypeId]||"ERROR"}delete(){C._ts_lookahead_iterator_delete(this[0]),this[0]=0}resetState(e){return C._ts_lookahead_iterator_reset_state(this[0],e)}reset(e,t){return!!C._ts_lookahead_iterator_reset(this[0],e[0],t)&&(this.language=e,!0)}[Symbol.iterator](){const e=this;return{next:()=>C._ts_lookahead_iterator_next(e[0])?{done:!1,value:e.currentType}:{done:!0,value:""}}}}class Query{constructor(e,t,r,s,n,o,a,i){assertInternal(e),this[0]=t,this.captureNames=r,this.textPredicates=s,this.predicates=n,this.setProperties=o,this.assertedProperties=a,this.refutedProperties=i,this.exceededMatchLimit=!1}delete(){C._ts_query_delete(this[0]),this[0]=0}matches(e,{startPosition:t=ZERO_POINT,endPosition:r=ZERO_POINT,startIndex:s=0,endIndex:n=0,matchLimit:o=4294967295,maxStartDepth:a=4294967295,timeoutMicros:i=0}={}){if("number"!=typeof o)throw new Error("Arguments must be numbers");marshalNode(e),C._ts_query_matches_wasm(this[0],e.tree[0],t.row,t.column,r.row,r.column,s,n,o,a,i);const l=getValue(TRANSFER_BUFFER,"i32"),_=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),u=getValue(TRANSFER_BUFFER+2*SIZE_OF_INT,"i32"),p=new Array(l);this.exceededMatchLimit=Boolean(u);let c=0,d=_;for(let m=0;m<l;m++){const t=getValue(d,"i32");d+=SIZE_OF_INT;const r=getValue(d,"i32");d+=SIZE_OF_INT;const s=new Array(r);if(d=unmarshalCaptures(this,e.tree,d,s),this.textPredicates[t].every((e=>e(s)))){p[c]={pattern:t,captures:s};const e=this.setProperties[t];e&&(p[c].setProperties=e);const r=this.assertedProperties[t];r&&(p[c].assertedProperties=r);const n=this.refutedProperties[t];n&&(p[c].refutedProperties=n),c++}}return p.length=c,C._free(_),p}captures(e,{startPosition:t=ZERO_POINT,endPosition:r=ZERO_POINT,startIndex:s=0,endIndex:n=0,matchLimit:o=4294967295,maxStartDepth:a=4294967295,timeoutMicros:i=0}={}){if("number"!=typeof o)throw new Error("Arguments must be numbers");marshalNode(e),C._ts_query_captures_wasm(this[0],e.tree[0],t.row,t.column,r.row,r.column,s,n,o,a,i);const l=getValue(TRANSFER_BUFFER,"i32"),_=getValue(TRANSFER_BUFFER+SIZE_OF_INT,"i32"),u=getValue(TRANSFER_BUFFER+2*SIZE_OF_INT,"i32"),p=[];this.exceededMatchLimit=Boolean(u);const c=[];let d=_;for(let m=0;m<l;m++){const t=getValue(d,"i32");d+=SIZE_OF_INT;const r=getValue(d,"i32");d+=SIZE_OF_INT;const s=getValue(d,"i32");if(d+=SIZE_OF_INT,c.length=r,d=unmarshalCaptures(this,e.tree,d,c),this.textPredicates[t].every((e=>e(c)))){const e=c[s],r=this.setProperties[t];r&&(e.setProperties=r);const n=this.assertedProperties[t];n&&(e.assertedProperties=n);const o=this.refutedProperties[t];o&&(e.refutedProperties=o),p.push(e)}}return C._free(_),p}predicatesForPattern(e){return this.predicates[e]}disableCapture(e){const t=lengthBytesUTF8(e),r=C._malloc(t+1);stringToUTF8(e,r,t+1),C._ts_query_disable_capture(this[0],r,t),C._free(r)}didExceedMatchLimit(){return this.exceededMatchLimit}}function getText(e,t,r){const s=r-t;let n=e.textCallback(t,null,r);for(t+=n.length;t<r;){const s=e.textCallback(t,null,r);if(!(s&&s.length>0))break;t+=s.length,n+=s}return t>r&&(n=n.slice(0,s)),n}function unmarshalCaptures(e,t,r,s){for(let n=0,o=s.length;n<o;n++){const o=getValue(r,"i32"),a=unmarshalNode(t,r+=SIZE_OF_INT);r+=SIZE_OF_NODE,s[n]={name:e.captureNames[o],node:a}}return r}function assertInternal(e){if(e!==INTERNAL)throw new Error("Illegal constructor")}function isPoint(e){return e&&"number"==typeof e.row&&"number"==typeof e.column}function marshalNode(e){let t=TRANSFER_BUFFER;setValue(t,e.id,"i32"),t+=SIZE_OF_INT,setValue(t,e.startIndex,"i32"),t+=SIZE_OF_INT,setValue(t,e.startPosition.row,"i32"),t+=SIZE_OF_INT,setValue(t,e.startPosition.column,"i32"),t+=SIZE_OF_INT,setValue(t,e[0],"i32")}function unmarshalNode(e,t=TRANSFER_BUFFER){const r=getValue(t,"i32");if(0===r)return null;const s=getValue(t+=SIZE_OF_INT,"i32"),n=getValue(t+=SIZE_OF_INT,"i32"),o=getValue(t+=SIZE_OF_INT,"i32"),a=getValue(t+=SIZE_OF_INT,"i32"),i=new Node(INTERNAL,e);return i.id=r,i.startIndex=s,i.startPosition={row:n,column:o},i[0]=a,i}function marshalTreeCursor(e,t=TRANSFER_BUFFER){setValue(t+0*SIZE_OF_INT,e[0],"i32"),setValue(t+1*SIZE_OF_INT,e[1],"i32"),setValue(t+2*SIZE_OF_INT,e[2],"i32"),setValue(t+3*SIZE_OF_INT,e[3],"i32")}function unmarshalTreeCursor(e){e[0]=getValue(TRANSFER_BUFFER+0*SIZE_OF_INT,"i32"),e[1]=getValue(TRANSFER_BUFFER+1*SIZE_OF_INT,"i32"),e[2]=getValue(TRANSFER_BUFFER+2*SIZE_OF_INT,"i32"),e[3]=getValue(TRANSFER_BUFFER+3*SIZE_OF_INT,"i32")}function marshalPoint(e,t){setValue(e,t.row,"i32"),setValue(e+SIZE_OF_INT,t.column,"i32")}function unmarshalPoint(e){return{row:getValue(e,"i32")>>>0,column:getValue(e+SIZE_OF_INT,"i32")>>>0}}function marshalRange(e,t){marshalPoint(e,t.startPosition),marshalPoint(e+=SIZE_OF_POINT,t.endPosition),setValue(e+=SIZE_OF_POINT,t.startIndex,"i32"),setValue(e+=SIZE_OF_INT,t.endIndex,"i32"),e+=SIZE_OF_INT}function unmarshalRange(e){const t={};return t.startPosition=unmarshalPoint(e),e+=SIZE_OF_POINT,t.endPosition=unmarshalPoint(e),e+=SIZE_OF_POINT,t.startIndex=getValue(e,"i32")>>>0,e+=SIZE_OF_INT,t.endIndex=getValue(e,"i32")>>>0,t}function marshalEdit(e){let t=TRANSFER_BUFFER;marshalPoint(t,e.startPosition),t+=SIZE_OF_POINT,marshalPoint(t,e.oldEndPosition),t+=SIZE_OF_POINT,marshalPoint(t,e.newEndPosition),t+=SIZE_OF_POINT,setValue(t,e.startIndex,"i32"),t+=SIZE_OF_INT,setValue(t,e.oldEndIndex,"i32"),t+=SIZE_OF_INT,setValue(t,e.newEndIndex,"i32"),t+=SIZE_OF_INT}for(const e of Object.getOwnPropertyNames(ParserImpl.prototype))Object.defineProperty(Parser$3.prototype,e,{value:ParserImpl.prototype[e],enumerable:!1,writable:!1});Parser$3.Language=Language,Module.onRuntimeInitialized=()=>{ParserImpl.init(),resolveInitPromise()}})))}}return Parser$3}();"object"==typeof exports&&(module.exports=TreeSitter)})),import_tree_sitter=__toESM(require_tree_sitter(),1),await import_tree_sitter.default.init({locateFile:(e,t)=>"/"+e}),Bash=await import_tree_sitter.default.Language.load("/tree-sitter-bash.wasm"),parser=new import_tree_sitter.default,parser.setLanguage(Bash),webParser_default=parser,BACKSLASHES=/\\./gs,DOUBLE_QUOTE_BACKSLASHES=/\\[\\$`"\n]/gs,ANSI_BACKSLASHES=/\\(\\|a|b|e|E|f|n|r|t|v|'|"|\?|[0-7]{1,3}|x[0-9A-Fa-f]{1,2}|u[0-9A-Fa-f]{1,4}|U[0-9A-Fa-f]{1,8}|c.)/gs,CURLAUTH_BASIC=1,CURLAUTH_DIGEST=2,CURLAUTH_NEGOTIATE=4,CURLAUTH_NTLM=8,CURLAUTH_DIGEST_IE=16,CURLAUTH_NTLM_WB=32,CURLAUTH_BEARER=64,CURLAUTH_AWS_SIGV4=128,CURLAUTH_ANY=-17,curlLongOpts={url:{type:"string",name:"url"},"dns-ipv4-addr":{type:"string",name:"dns-ipv4-addr"},"dns-ipv6-addr":{type:"string",name:"dns-ipv6-addr"},"random-file":{type:"string",name:"random-file"},"egd-file":{type:"string",name:"egd-file"},"oauth2-bearer":{type:"string",name:"oauth2-bearer"},"connect-timeout":{type:"string",name:"connect-timeout"},"doh-url":{type:"string",name:"doh-url"},ciphers:{type:"string",name:"ciphers"},"dns-interface":{type:"string",name:"dns-interface"},"disable-epsv":{type:"bool",name:"disable-epsv"},"no-disable-epsv":{type:"bool",name:"disable-epsv",expand:!1},"disallow-username-in-url":{type:"bool",name:"disallow-username-in-url"},"no-disallow-username-in-url":{type:"bool",name:"disallow-username-in-url",expand:!1},epsv:{type:"bool",name:"epsv"},"no-epsv":{type:"bool",name:"epsv",expand:!1},"dns-servers":{type:"string",name:"dns-servers"},trace:{type:"string",name:"trace"},npn:{type:"bool",name:"npn"},"no-npn":{type:"bool",name:"npn",expand:!1},"trace-ascii":{type:"string",name:"trace-ascii"},alpn:{type:"bool",name:"alpn"},"no-alpn":{type:"bool",name:"alpn",expand:!1},"limit-rate":{type:"string",name:"limit-rate"},rate:{type:"string",name:"rate"},compressed:{type:"bool",name:"compressed"},"no-compressed":{type:"bool",name:"compressed",expand:!1},"tr-encoding":{type:"bool",name:"tr-encoding"},"no-tr-encoding":{type:"bool",name:"tr-encoding",expand:!1},digest:{type:"bool",name:"digest"},"no-digest":{type:"bool",name:"digest",expand:!1},negotiate:{type:"bool",name:"negotiate"},"no-negotiate":{type:"bool",name:"negotiate",expand:!1},ntlm:{type:"bool",name:"ntlm"},"no-ntlm":{type:"bool",name:"ntlm",expand:!1},"ntlm-wb":{type:"bool",name:"ntlm-wb"},"no-ntlm-wb":{type:"bool",name:"ntlm-wb",expand:!1},basic:{type:"bool",name:"basic"},"no-basic":{type:"bool",name:"basic",expand:!1},anyauth:{type:"bool",name:"anyauth"},"no-anyauth":{type:"bool",name:"anyauth",expand:!1},wdebug:{type:"bool",name:"wdebug"},"no-wdebug":{type:"bool",name:"wdebug",expand:!1},"ftp-create-dirs":{type:"bool",name:"ftp-create-dirs"},"no-ftp-create-dirs":{type:"bool",name:"ftp-create-dirs",expand:!1},"create-dirs":{type:"bool",name:"create-dirs"},"no-create-dirs":{type:"bool",name:"create-dirs",expand:!1},"create-file-mode":{type:"string",name:"create-file-mode"},"max-redirs":{type:"string",name:"max-redirs"},"proxy-ntlm":{type:"bool",name:"proxy-ntlm"},"no-proxy-ntlm":{type:"bool",name:"proxy-ntlm",expand:!1},crlf:{type:"bool",name:"crlf"},"no-crlf":{type:"bool",name:"crlf",expand:!1},stderr:{type:"string",name:"stderr"},"aws-sigv4":{type:"string",name:"aws-sigv4"},interface:{type:"string",name:"interface"},krb:{type:"string",name:"krb"},krb4:{type:"string",name:"krb"},"haproxy-protocol":{type:"bool",name:"haproxy-protocol"},"no-haproxy-protocol":{type:"bool",name:"haproxy-protocol",expand:!1},"haproxy-clientip":{type:"string",name:"haproxy-clientip"},"max-filesize":{type:"string",name:"max-filesize"},"disable-eprt":{type:"bool",name:"disable-eprt"},"no-disable-eprt":{type:"bool",name:"disable-eprt",expand:!1},eprt:{type:"bool",name:"eprt"},"no-eprt":{type:"bool",name:"eprt",expand:!1},xattr:{type:"bool",name:"xattr"},"no-xattr":{type:"bool",name:"xattr",expand:!1},"ftp-ssl":{type:"bool",name:"ssl"},"no-ftp-ssl":{type:"bool",name:"ssl",expand:!1},ssl:{type:"bool",name:"ssl"},"no-ssl":{type:"bool",name:"ssl",expand:!1},"ftp-pasv":{type:"bool",name:"ftp-pasv"},"no-ftp-pasv":{type:"bool",name:"ftp-pasv",expand:!1},socks5:{type:"string",name:"socks5"},"tcp-nodelay":{type:"bool",name:"tcp-nodelay"},"no-tcp-nodelay":{type:"bool",name:"tcp-nodelay",expand:!1},"proxy-digest":{type:"bool",name:"proxy-digest"},"no-proxy-digest":{type:"bool",name:"proxy-digest",expand:!1},"proxy-basic":{type:"bool",name:"proxy-basic"},"no-proxy-basic":{type:"bool",name:"proxy-basic",expand:!1},retry:{type:"string",name:"retry"},"retry-connrefused":{type:"bool",name:"retry-connrefused"},"no-retry-connrefused":{type:"bool",name:"retry-connrefused",expand:!1},"retry-delay":{type:"string",name:"retry-delay"},"retry-max-time":{type:"string",name:"retry-max-time"},"proxy-negotiate":{type:"bool",name:"proxy-negotiate"},"no-proxy-negotiate":{type:"bool",name:"proxy-negotiate",expand:!1},"form-escape":{type:"bool",name:"form-escape"},"no-form-escape":{type:"bool",name:"form-escape",expand:!1},"ftp-account":{type:"string",name:"ftp-account"},"proxy-anyauth":{type:"bool",name:"proxy-anyauth"},"no-proxy-anyauth":{type:"bool",name:"proxy-anyauth",expand:!1},"trace-time":{type:"bool",name:"trace-time"},"no-trace-time":{type:"bool",name:"trace-time",expand:!1},"ignore-content-length":{type:"bool",name:"ignore-content-length"},"no-ignore-content-length":{type:"bool",name:"ignore-content-length",expand:!1},"ftp-skip-pasv-ip":{type:"bool",name:"ftp-skip-pasv-ip"},"no-ftp-skip-pasv-ip":{type:"bool",name:"ftp-skip-pasv-ip",expand:!1},"ftp-method":{type:"string",name:"ftp-method"},"local-port":{type:"string",name:"local-port"},socks4:{type:"string",name:"socks4"},socks4a:{type:"string",name:"socks4a"},"ftp-alternative-to-user":{type:"string",name:"ftp-alternative-to-user"},"ftp-ssl-reqd":{type:"bool",name:"ssl-reqd"},"no-ftp-ssl-reqd":{type:"bool",name:"ssl-reqd",expand:!1},"ssl-reqd":{type:"bool",name:"ssl-reqd"},"no-ssl-reqd":{type:"bool",name:"ssl-reqd",expand:!1},sessionid:{type:"bool",name:"sessionid"},"no-sessionid":{type:"bool",name:"sessionid",expand:!1},"ftp-ssl-control":{type:"bool",name:"ftp-ssl-control"},"no-ftp-ssl-control":{type:"bool",name:"ftp-ssl-control",expand:!1},"ftp-ssl-ccc":{type:"bool",name:"ftp-ssl-ccc"},"no-ftp-ssl-ccc":{type:"bool",name:"ftp-ssl-ccc",expand:!1},"ftp-ssl-ccc-mode":{type:"string",name:"ftp-ssl-ccc-mode"},libcurl:{type:"string",name:"libcurl"},raw:{type:"bool",name:"raw"},"no-raw":{type:"bool",name:"raw",expand:!1},post301:{type:"bool",name:"post301"},"no-post301":{type:"bool",name:"post301",expand:!1},keepalive:{type:"bool",name:"keepalive"},"no-keepalive":{type:"bool",name:"keepalive",expand:!1},"socks5-hostname":{type:"string",name:"socks5-hostname"},"keepalive-time":{type:"string",name:"keepalive-time"},post302:{type:"bool",name:"post302"},"no-post302":{type:"bool",name:"post302",expand:!1},noproxy:{type:"string",name:"noproxy"},"socks5-gssapi-nec":{type:"bool",name:"socks5-gssapi-nec"},"no-socks5-gssapi-nec":{type:"bool",name:"socks5-gssapi-nec",expand:!1},"proxy1.0":{type:"string",name:"proxy1.0"},"tftp-blksize":{type:"string",name:"tftp-blksize"},"mail-from":{type:"string",name:"mail-from"},"mail-rcpt":{type:"string",name:"mail-rcpt"},"ftp-pret":{type:"bool",name:"ftp-pret"},"no-ftp-pret":{type:"bool",name:"ftp-pret",expand:!1},proto:{type:"string",name:"proto"},"proto-redir":{type:"string",name:"proto-redir"},resolve:{type:"string",name:"resolve"},delegation:{type:"string",name:"delegation"},"mail-auth":{type:"string",name:"mail-auth"},post303:{type:"bool",name:"post303"},"no-post303":{type:"bool",name:"post303",expand:!1},metalink:{type:"bool",name:"metalink"},"no-metalink":{type:"bool",name:"metalink",expand:!1},"sasl-authzid":{type:"string",name:"sasl-authzid"},"sasl-ir":{type:"bool",name:"sasl-ir"},"no-sasl-ir":{type:"bool",name:"sasl-ir",expand:!1},"test-event":{type:"bool",name:"test-event"},"no-test-event":{type:"bool",name:"test-event",expand:!1},"unix-socket":{type:"string",name:"unix-socket"},"path-as-is":{type:"bool",name:"path-as-is"},"no-path-as-is":{type:"bool",name:"path-as-is",expand:!1},"socks5-gssapi-service":{type:"string",name:"proxy-service-name"},"proxy-service-name":{type:"string",name:"proxy-service-name"},"service-name":{type:"string",name:"service-name"},"proto-default":{type:"string",name:"proto-default"},"expect100-timeout":{type:"string",name:"expect100-timeout"},"tftp-no-options":{type:"bool",name:"tftp-no-options"},"no-tftp-no-options":{type:"bool",name:"tftp-no-options",expand:!1},"connect-to":{type:"string",name:"connect-to"},"abstract-unix-socket":{type:"string",name:"abstract-unix-socket"},"tls-max":{type:"string",name:"tls-max"},"suppress-connect-headers":{type:"bool",name:"suppress-connect-headers"},"no-suppress-connect-headers":{type:"bool",name:"suppress-connect-headers",expand:!1},"compressed-ssh":{type:"bool",name:"compressed-ssh"},"no-compressed-ssh":{type:"bool",name:"compressed-ssh",expand:!1},"happy-eyeballs-timeout-ms":{type:"string",name:"happy-eyeballs-timeout-ms"},"retry-all-errors":{type:"bool",name:"retry-all-errors"},"no-retry-all-errors":{type:"bool",name:"retry-all-errors",expand:!1},"trace-ids":{type:"bool",name:"trace-ids"},"no-trace-ids":{type:"bool",name:"trace-ids",expand:!1},"http1.0":{type:"bool",name:"http1.0"},"http1.1":{type:"bool",name:"http1.1"},http2:{type:"bool",name:"http2"},"http2-prior-knowledge":{type:"bool",name:"http2-prior-knowledge"},http3:{type:"bool",name:"http3"},"http3-only":{type:"bool",name:"http3-only"},"http0.9":{type:"bool",name:"http0.9"},"no-http0.9":{type:"bool",name:"http0.9",expand:!1},"proxy-http2":{type:"bool",name:"proxy-http2"},"no-proxy-http2":{type:"bool",name:"proxy-http2",expand:!1},tlsv1:{type:"bool",name:"tlsv1"},"tlsv1.0":{type:"bool",name:"tlsv1.0"},"tlsv1.1":{type:"bool",name:"tlsv1.1"},"tlsv1.2":{type:"bool",name:"tlsv1.2"},"tlsv1.3":{type:"bool",name:"tlsv1.3"},"tls13-ciphers":{type:"string",name:"tls13-ciphers"},"proxy-tls13-ciphers":{type:"string",name:"proxy-tls13-ciphers"},sslv2:{type:"bool",name:"sslv2"},sslv3:{type:"bool",name:"sslv3"},ipv4:{type:"bool",name:"ipv4"},ipv6:{type:"bool",name:"ipv6"},append:{type:"bool",name:"append"},"no-append":{type:"bool",name:"append",expand:!1},"user-agent":{type:"string",name:"user-agent"},cookie:{type:"string",name:"cookie"},"alt-svc":{type:"string",name:"alt-svc"},hsts:{type:"string",name:"hsts"},"use-ascii":{type:"bool",name:"use-ascii"},"no-use-ascii":{type:"bool",name:"use-ascii",expand:!1},"cookie-jar":{type:"string",name:"cookie-jar"},"continue-at":{type:"string",name:"continue-at"},data:{type:"string",name:"data"},"data-raw":{type:"string",name:"data-raw"},"data-ascii":{type:"string",name:"data-ascii"},"data-binary":{type:"string",name:"data-binary"},"data-urlencode":{type:"string",name:"data-urlencode"},json:{type:"string",name:"json"},"url-query":{type:"string",name:"url-query"},"dump-header":{type:"string",name:"dump-header"},referer:{type:"string",name:"referer"},cert:{type:"string",name:"cert"},cacert:{type:"string",name:"cacert"},"cert-type":{type:"string",name:"cert-type"},key:{type:"string",name:"key"},"key-type":{type:"string",name:"key-type"},pass:{type:"string",name:"pass"},engine:{type:"string",name:"engine"},"ca-native":{type:"bool",name:"ca-native"},"no-ca-native":{type:"bool",name:"ca-native",expand:!1},"proxy-ca-native":{type:"bool",name:"proxy-ca-native"},"no-proxy-ca-native":{type:"bool",name:"proxy-ca-native",expand:!1},capath:{type:"string",name:"capath"},pubkey:{type:"string",name:"pubkey"},hostpubmd5:{type:"string",name:"hostpubmd5"},hostpubsha256:{type:"string",name:"hostpubsha256"},crlfile:{type:"string",name:"crlfile"},tlsuser:{type:"string",name:"tlsuser"},tlspassword:{type:"string",name:"tlspassword"},tlsauthtype:{type:"string",name:"tlsauthtype"},"ssl-allow-beast":{type:"bool",name:"ssl-allow-beast"},"no-ssl-allow-beast":{type:"bool",name:"ssl-allow-beast",expand:!1},"ssl-auto-client-cert":{type:"bool",name:"ssl-auto-client-cert"},"no-ssl-auto-client-cert":{type:"bool",name:"ssl-auto-client-cert",expand:!1},"proxy-ssl-auto-client-cert":{type:"bool",name:"proxy-ssl-auto-client-cert"},"no-proxy-ssl-auto-client-cert":{type:"bool",name:"proxy-ssl-auto-client-cert",expand:!1},pinnedpubkey:{type:"string",name:"pinnedpubkey"},"proxy-pinnedpubkey":{type:"string",name:"proxy-pinnedpubkey"},"cert-status":{type:"bool",name:"cert-status"},"no-cert-status":{type:"bool",name:"cert-status",expand:!1},"doh-cert-status":{type:"bool",name:"doh-cert-status"},"no-doh-cert-status":{type:"bool",name:"doh-cert-status",expand:!1},"false-start":{type:"bool",name:"false-start"},"no-false-start":{type:"bool",name:"false-start",expand:!1},"ssl-no-revoke":{type:"bool",name:"ssl-no-revoke"},"no-ssl-no-revoke":{type:"bool",name:"ssl-no-revoke",expand:!1},"ssl-revoke-best-effort":{type:"bool",name:"ssl-revoke-best-effort"},"no-ssl-revoke-best-effort":{type:"bool",name:"ssl-revoke-best-effort",expand:!1},"tcp-fastopen":{type:"bool",name:"tcp-fastopen"},"no-tcp-fastopen":{type:"bool",name:"tcp-fastopen",expand:!1},"proxy-tlsuser":{type:"string",name:"proxy-tlsuser"},"proxy-tlspassword":{type:"string",name:"proxy-tlspassword"},"proxy-tlsauthtype":{type:"string",name:"proxy-tlsauthtype"},"proxy-cert":{type:"string",name:"proxy-cert"},"proxy-cert-type":{type:"string",name:"proxy-cert-type"},"proxy-key":{type:"string",name:"proxy-key"},"proxy-key-type":{type:"string",name:"proxy-key-type"},"proxy-pass":{type:"string",name:"proxy-pass"},"proxy-ciphers":{type:"string",name:"proxy-ciphers"},"proxy-crlfile":{type:"string",name:"proxy-crlfile"},"proxy-ssl-allow-beast":{type:"bool",name:"proxy-ssl-allow-beast"},"no-proxy-ssl-allow-beast":{type:"bool",name:"proxy-ssl-allow-beast",expand:!1},"login-options":{type:"string",name:"login-options"},"proxy-cacert":{type:"string",name:"proxy-cacert"},"proxy-capath":{type:"string",name:"proxy-capath"},"proxy-insecure":{type:"bool",name:"proxy-insecure"},"no-proxy-insecure":{type:"bool",name:"proxy-insecure",expand:!1},"proxy-tlsv1":{type:"bool",name:"proxy-tlsv1"},"socks5-basic":{type:"bool",name:"socks5-basic"},"no-socks5-basic":{type:"bool",name:"socks5-basic",expand:!1},"socks5-gssapi":{type:"bool",name:"socks5-gssapi"},"no-socks5-gssapi":{type:"bool",name:"socks5-gssapi",expand:!1},"etag-save":{type:"string",name:"etag-save"},"etag-compare":{type:"string",name:"etag-compare"},curves:{type:"string",name:"curves"},fail:{type:"bool",name:"fail"},"no-fail":{type:"bool",name:"fail",expand:!1},"fail-early":{type:"bool",name:"fail-early"},"no-fail-early":{type:"bool",name:"fail-early",expand:!1},"styled-output":{type:"bool",name:"styled-output"},"no-styled-output":{type:"bool",name:"styled-output",expand:!1},"mail-rcpt-allowfails":{type:"bool",name:"mail-rcpt-allowfails"},"no-mail-rcpt-allowfails":{type:"bool",name:"mail-rcpt-allowfails",expand:!1},"fail-with-body":{type:"bool",name:"fail-with-body"},"no-fail-with-body":{type:"bool",name:"fail-with-body",expand:!1},"remove-on-error":{type:"bool",name:"remove-on-error"},"no-remove-on-error":{type:"bool",name:"remove-on-error",expand:!1},form:{type:"string",name:"form"},"form-string":{type:"string",name:"form-string"},globoff:{type:"bool",name:"globoff"},"no-globoff":{type:"bool",name:"globoff",expand:!1},get:{type:"bool",name:"get"},"no-get":{type:"bool",name:"get",expand:!1},"request-target":{type:"string",name:"request-target"},help:{type:"bool",name:"help"},"no-help":{type:"bool",name:"help",expand:!1},header:{type:"string",name:"header"},"proxy-header":{type:"string",name:"proxy-header"},include:{type:"bool",name:"include"},"no-include":{type:"bool",name:"include",expand:!1},head:{type:"bool",name:"head"},"no-head":{type:"bool",name:"head",expand:!1},"junk-session-cookies":{type:"bool",name:"junk-session-cookies"},"no-junk-session-cookies":{type:"bool",name:"junk-session-cookies",expand:!1},"remote-header-name":{type:"bool",name:"remote-header-name"},"no-remote-header-name":{type:"bool",name:"remote-header-name",expand:!1},insecure:{type:"bool",name:"insecure"},"no-insecure":{type:"bool",name:"insecure",expand:!1},"doh-insecure":{type:"bool",name:"doh-insecure"},"no-doh-insecure":{type:"bool",name:"doh-insecure",expand:!1},config:{type:"string",name:"config"},"list-only":{type:"bool",name:"list-only"},"no-list-only":{type:"bool",name:"list-only",expand:!1},location:{type:"bool",name:"location"},"no-location":{type:"bool",name:"location",expand:!1},"location-trusted":{type:"bool",name:"location-trusted"},"no-location-trusted":{type:"bool",name:"location-trusted",expand:!1},"max-time":{type:"string",name:"max-time"},manual:{type:"bool",name:"manual"},"no-manual":{type:"bool",name:"manual",expand:!1},netrc:{type:"bool",name:"netrc"},"no-netrc":{type:"bool",name:"netrc",expand:!1},"netrc-optional":{type:"bool",name:"netrc-optional"},"no-netrc-optional":{type:"bool",name:"netrc-optional",expand:!1},"netrc-file":{type:"string",name:"netrc-file"},buffer:{type:"bool",name:"buffer"},"no-buffer":{type:"bool",name:"buffer",expand:!1},output:{type:"string",name:"output"},"remote-name":{type:"bool",name:"remote-name"},"no-remote-name":{type:"bool",name:"remote-name",expand:!1},"remote-name-all":{type:"bool",name:"remote-name-all"},"no-remote-name-all":{type:"bool",name:"remote-name-all",expand:!1},"output-dir":{type:"string",name:"output-dir"},clobber:{type:"bool",name:"clobber"},"no-clobber":{type:"bool",name:"clobber",expand:!1},proxytunnel:{type:"bool",name:"proxytunnel"},"no-proxytunnel":{type:"bool",name:"proxytunnel",expand:!1},"ftp-port":{type:"string",name:"ftp-port"},disable:{type:"bool",name:"disable"},"no-disable":{type:"bool",name:"disable",expand:!1},quote:{type:"string",name:"quote"},range:{type:"string",name:"range"},"remote-time":{type:"bool",name:"remote-time"},"no-remote-time":{type:"bool",name:"remote-time",expand:!1},silent:{type:"bool",name:"silent"},"no-silent":{type:"bool",name:"silent",expand:!1},"show-error":{type:"bool",name:"show-error"},"no-show-error":{type:"bool",name:"show-error",expand:!1},"telnet-option":{type:"string",name:"telnet-option"},"upload-file":{type:"string",name:"upload-file"},user:{type:"string",name:"user"},"proxy-user":{type:"string",name:"proxy-user"},verbose:{type:"bool",name:"verbose"},"no-verbose":{type:"bool",name:"verbose",expand:!1},version:{type:"bool",name:"version"},"no-version":{type:"bool",name:"version",expand:!1},"write-out":{type:"string",name:"write-out"},proxy:{type:"string",name:"proxy"},preproxy:{type:"string",name:"preproxy"},request:{type:"string",name:"request"},"speed-limit":{type:"string",name:"speed-limit"},"speed-time":{type:"string",name:"speed-time"},"time-cond":{type:"string",name:"time-cond"},parallel:{type:"bool",name:"parallel"},"no-parallel":{type:"bool",name:"parallel",expand:!1},"parallel-max":{type:"string",name:"parallel-max"},"parallel-immediate":{type:"bool",name:"parallel-immediate"},"no-parallel-immediate":{type:"bool",name:"parallel-immediate",expand:!1},"progress-bar":{type:"bool",name:"progress-bar"},"no-progress-bar":{type:"bool",name:"progress-bar",expand:!1},"progress-meter":{type:"bool",name:"progress-meter"},"no-progress-meter":{type:"bool",name:"progress-meter",expand:!1},next:{type:"bool",name:"next"},port:{type:"string",name:"port",removed:"7.3"},"ftp-ascii":{type:"bool",name:"use-ascii",removed:"7.10.7"},"3p-url":{type:"string",name:"3p-url",removed:"7.16.0"},"3p-user":{type:"string",name:"3p-user",removed:"7.16.0"},"3p-quote":{type:"string",name:"3p-quote",removed:"7.16.0"},"http2.0":{type:"bool",name:"http2",removed:"7.36.0"},"no-http2.0":{type:"bool",name:"http2",removed:"7.36.0"},"telnet-options":{type:"string",name:"telnet-option",removed:"7.49.0"},"http-request":{type:"string",name:"request",removed:"7.49.0"},"capath ":{type:"string",name:"capath",removed:"7.49.0"},ftpport:{type:"string",name:"ftp-port",removed:"7.49.0"},environment:{type:"bool",name:"environment",removed:"7.54.1"},"no-tlsv1":{type:"bool",name:"tlsv1",removed:"7.54.1"},"no-tlsv1.2":{type:"bool",name:"tlsv1.2",removed:"7.54.1"},"no-http2-prior-knowledge":{type:"bool",name:"http2-prior-knowledge",removed:"7.54.1"},"no-ipv6":{type:"bool",name:"ipv6",removed:"7.54.1"},"no-ipv4":{type:"bool",name:"ipv4",removed:"7.54.1"},"no-sslv2":{type:"bool",name:"sslv2",removed:"7.54.1"},"no-tlsv1.0":{type:"bool",name:"tlsv1.0",removed:"7.54.1"},"no-tlsv1.1":{type:"bool",name:"tlsv1.1",removed:"7.54.1"},"no-sslv3":{type:"bool",name:"sslv3",removed:"7.54.1"},"no-http1.0":{type:"bool",name:"http1.0",removed:"7.54.1"},"no-next":{type:"bool",name:"next",removed:"7.54.1"},"no-tlsv1.3":{type:"bool",name:"tlsv1.3",removed:"7.54.1"},"no-environment":{type:"bool",name:"environment",removed:"7.54.1"},"no-http1.1":{type:"bool",name:"http1.1",removed:"7.54.1"},"no-proxy-tlsv1":{type:"bool",name:"proxy-tlsv1",removed:"7.54.1"},"no-http2":{type:"bool",name:"http2",removed:"7.54.1"}},curlLongOptsShortened={};for(const[t,r]of Object.entries(curlLongOpts)){const e=!("expand"in r)||r.expand,s="removed"in r&&r.removed;if(e&&!s)for(let n=1;n<t.length;n++){const e=t.slice(0,n);Object.prototype.hasOwnProperty.call(curlLongOptsShortened,e)?curlLongOptsShortened[e]=null:Object.prototype.hasOwnProperty.call(curlLongOpts,e)||(curlLongOptsShortened[e]=r)}}COMMON_SUPPORTED_ARGS=["url","proto-default","globoff","disallow-username-in-url","request","get","head","no-head","header","user-agent","referer","range","time-cond","cookie","oauth2-bearer","user","basic","no-basic","data","data-raw","data-ascii","data-binary","data-urlencode","json","url-query"],curlShortOpts={0:"http1.0",1:"tlsv1",2:"sslv2",3:"sslv3",4:"ipv4",6:"ipv6",a:"append",A:"user-agent",b:"cookie",B:"use-ascii",c:"cookie-jar",C:"continue-at",d:"data",D:"dump-header",e:"referer",E:"cert",f:"fail",F:"form",g:"globoff",G:"get",h:"help",H:"header",i:"include",I:"head",j:"junk-session-cookies",J:"remote-header-name",k:"insecure",K:"config",l:"list-only",L:"location",m:"max-time",M:"manual",n:"netrc",N:"no-buffer",o:"output",O:"remote-name",p:"proxytunnel",P:"ftp-port",q:"disable",Q:"quote",r:"range",R:"remote-time",s:"silent",S:"show-error",t:"telnet-option",T:"upload-file",u:"user",U:"proxy-user",v:"verbose",V:"version",w:"write-out",x:"proxy",X:"request",Y:"speed-limit",y:"speed-time",z:"time-cond",Z:"parallel","#":"progress-bar",":":"next"},changedShortOpts={p:"used to be short for --port <port> (a since-deleted flag) until curl 7.3",t:"used to be short for --upload (a since-deleted boolean flag) until curl 7.7",c:"used to be short for --continue (a since-deleted boolean flag) until curl 7.9","@":"used to be short for --create-dirs until curl 7.10.7",Z:"used to be short for --max-redirs <num> until curl 7.10.7",9:"used to be short for --crlf until curl 7.10.8",8:"used to be short for --stderr <file> until curl 7.10.8",7:"used to be short for --interface <name> until curl 7.10.8",6:"used to be short for --krb <level> (which itself used to be --krb4 <level>) until curl 7.10.8",5:"used to be another way to specify the url until curl 7.10.8","*":"used to be another way to specify the url until curl 7.49.0","~":"used to be short for --xattr until curl 7.49.0"},canBeList=new Set(["connect-to","cookie","data","form","header","hsts","mail-rcpt","output","proxy-header","quote","resolve","telnet-option","upload-file","url-query","url"]),COMMA_SEPARATED=new Set(["A-IM","Accept","Accept-Charset","Accept-Encoding","Accept-Language","Access-Control-Request-Headers","Cache-Control","Connection","Content-Encoding","Expect","Forwarded","If-Match","If-None-Match","Range","TE","Trailer","Transfer-Encoding","Upgrade","Via","Warning"].map((e=>e.toLowerCase()))),SEMICOLON_SEPARATED=new Set(["Content-Type","Cookie","Prefer"].map((e=>e.toLowerCase()))),Headers=class{constructor(e,t=[],r="--header/H"){let s=[];if(e)for(const o of e)if(o.startsWith("@"))t.push(["header-file","passing a file for "+r+" is not supported: "+JSON.stringify(o.toString())]);else if(o.includes(":")){const[e,t]=o.split(":",2),r=t&&(eq(e,"Host")?t:t.trim()).toBool()?t.removeFirstChar(" "):null;s.push([e,r])}else if(o.includes(";")){const[e]=o.split(";",2);s.push([e,new Word])}this.lowercase=s.length>0&&s.every((e=>eq(e[0],e[0].toLowerCase())));const n={};for(const[o,a]of s){const e=o.toLowerCase().toString();n[e]||(n[e]=[]),n[e].push([o,a])}s=[];for(const[o,a]of Object.entries(n)){if(1===a.length){s.push(a[0]);continue}if(a.every((e=>null===e[1]))){const e=a[a.length-1];new Set(a.map((e=>e[0]))).size>1&&t.push(["repeated-header",`"${e[0]}" header unset ${a.length} times`]),s.push(e);continue}const e=a.filter((e=>null!==e[1]));if(1===e.length){s.push(e[0]);continue}let r="";if(COMMA_SEPARATED.has(o)?r=", ":SEMICOLON_SEPARATED.has(o)&&(r="; "),r){const n=joinWords(e.map((e=>e[1])),r);t.push(["repeated-header",`merged ${e.length} "${e[e.length-1][0]}" headers together with "${r.trim()}"`]),s.push([e[0][0],n])}else t.push(["repeated-header",`found ${e.length} "${e[e.length-1][0]}" headers, only the last one will be sent`]),s=s.concat(e)}this.headers=s}get length(){return this.headers.length}*[Symbol.iterator](){for(const e of this.headers)yield e}get(e){const t=e.toLowerCase();for(const[r,s]of this.headers)if(r.toLowerCase().toString()===t)return s}getContentType(){const e=this.get("content-type");return e?e.split(";")[0].trim().toString():e}has(e){const t=e.toLowerCase();for(const r of this.headers)if(eq(r[0].toLowerCase(),t))return!0;return!1}setIfMissing(e,t){if(this.has(e))return!1;this.lowercase&&(e=e.toLowerCase());const r="string"==typeof e?new Word(e):e,s="string"==typeof t?new Word(t):t;return this.headers.push([r,s]),!0}prependIfMissing(e,t){if(this.has(e))return!1;this.lowercase&&(e=e.toLowerCase());const r="string"==typeof e?new Word(e):e,s="string"==typeof t?new Word(t):t;return this.headers.unshift([r,s]),!0}set(e,t){this.lowercase&&(e=e.toLowerCase());const r="string"==typeof e?new Word(e):e,s="string"==typeof t?new Word(t):t,n=r.toLowerCase().toString();for(let o=0;o<this.headers.length;o++)if(eq(this.headers[o][0].toLowerCase(),n))return void(this.headers[o][1]=s);this.headers.push([r,s])}delete(e){const t=e.toLowerCase();for(let r=this.headers.length-1;r>=0;r--)this.headers[r][0].toLowerCase().toString()===t&&this.headers.splice(r,1)}clearNulls(){for(let e=this.headers.length-1;e>=0;e--)null===this.headers[e][1]&&this.headers.splice(e,1)}count(e){let t=0;const r=e.toLowerCase();for(const s of this.headers||[])s[0].toLowerCase().toString()===r&&(t+=1);return t}toBool(){return this.headers.length>0&&this.headers.some((e=>null!==e[1]))}},MAX_IP6LEN=128,require_Pattern=__commonJSMin(((e,t)=>{var r=function(){function e(e,t){var r,s,n,o,a,i,l,_,u;for(null==t&&(t=""),n="",a=e.length,i=null,s=0,o=0;o<a;){if("\\"===(r=e.charAt(o)))n+=e.slice(o,+(o+1)+1||9e9),o++;else if("("===r)if(o<a-2)if("(?:"===(_=e.slice(o,+(o+2)+1||9e9)))o+=2,n+=_;else if("(?<"===_)for(s++,o+=2,l="";o+1<a;){if(">"===(u=e.charAt(o+1))){n+="(",o++,l.length>0&&(null==i&&(i={}),i[l]=s);break}l+=u,o++}else n+=r,s++;else n+=r;else n+=r;o++}this.rawRegex=e,this.cleanedRegex=n,this.regex=new RegExp(this.cleanedRegex,"g"+t.replace("g","")),this.mapping=i}return e.prototype.regex=null,e.prototype.rawRegex=null,e.prototype.cleanedRegex=null,e.prototype.mapping=null,e.prototype.exec=function(e){var t,r,s,n;if(this.regex.lastIndex=0,null==(r=this.regex.exec(e)))return null;if(null!=this.mapping)for(s in n=this.mapping)t=n[s],r[s]=r[t];return r},e.prototype.test=function(e){return this.regex.lastIndex=0,this.regex.test(e)},e.prototype.replace=function(e,t){return this.regex.lastIndex=0,e.replace(this.regex,t)},e.prototype.replaceAll=function(e,t,r){var s;for(null==r&&(r=0),this.regex.lastIndex=0,s=0;this.regex.test(e)&&(0===r||s<r);)this.regex.lastIndex=0,e=e.replace(this.regex,t),s++;return[e,s]},e}();t.exports=r})),require_Utils=__commonJSMin(((e,t)=>{var r,s,n={}.hasOwnProperty;r=require_Pattern(),s=function(){function e(){}return e.REGEX_LEFT_TRIM_BY_CHAR={},e.REGEX_RIGHT_TRIM_BY_CHAR={},e.REGEX_SPACES=/\s+/g,e.REGEX_DIGITS=/^\d+$/,e.REGEX_OCTAL=/[^0-7]/gi,e.REGEX_HEXADECIMAL=/[^a-f0-9]/gi,e.PATTERN_DATE=new r("^(?<year>[0-9][0-9][0-9][0-9])-(?<month>[0-9][0-9]?)-(?<day>[0-9][0-9]?)(?:(?:[Tt]|[ \t]+)(?<hour>[0-9][0-9]?):(?<minute>[0-9][0-9]):(?<second>[0-9][0-9])(?:.(?<fraction>[0-9]*))?(?:[ \t]*(?<tz>Z|(?<tz_sign>[-+])(?<tz_hour>[0-9][0-9]?)(?::(?<tz_minute>[0-9][0-9]))?))?)?$","i"),e.LOCAL_TIMEZONE_OFFSET=60*(new Date).getTimezoneOffset()*1e3,e.trim=function(e,t){var r,s;return null==t&&(t="\\s"),null==(r=this.REGEX_LEFT_TRIM_BY_CHAR[t])&&(this.REGEX_LEFT_TRIM_BY_CHAR[t]=r=new RegExp("^"+t+t+"*")),r.lastIndex=0,null==(s=this.REGEX_RIGHT_TRIM_BY_CHAR[t])&&(this.REGEX_RIGHT_TRIM_BY_CHAR[t]=s=new RegExp(t+""+t+"*$")),s.lastIndex=0,e.replace(r,"").replace(s,"")},e.ltrim=function(e,t){var r;return null==t&&(t="\\s"),null==(r=this.REGEX_LEFT_TRIM_BY_CHAR[t])&&(this.REGEX_LEFT_TRIM_BY_CHAR[t]=r=new RegExp("^"+t+t+"*")),r.lastIndex=0,e.replace(r,"")},e.rtrim=function(e,t){var r;return null==t&&(t="\\s"),null==(r=this.REGEX_RIGHT_TRIM_BY_CHAR[t])&&(this.REGEX_RIGHT_TRIM_BY_CHAR[t]=r=new RegExp(t+""+t+"*$")),r.lastIndex=0,e.replace(r,"")},e.isEmpty=function(e){return!e||""===e||"0"===e||e instanceof Array&&0===e.length||this.isEmptyObject(e)},e.isEmptyObject=function(e){var t;return e instanceof Object&&0===function(){var r=[];for(t in e)n.call(e,t)&&r.push(t);return r}().length},e.subStrCount=function(e,t,r,s){var n,o,a,i,l,_=0;for(e=""+e,t=""+t,null!=r&&(e=e.slice(r)),null!=s&&(e=e.slice(0,s)),a=e.length,l=t.length,n=o=0,i=a;0<=i?o<i:o>i;n=0<=i?++o:--o)t===e.slice(n,l)&&(_++,n+=l-1);return _},e.isDigits=function(e){return this.REGEX_DIGITS.lastIndex=0,this.REGEX_DIGITS.test(e)},e.octDec=function(e){return this.REGEX_OCTAL.lastIndex=0,parseInt((e+"").replace(this.REGEX_OCTAL,""),8)},e.hexDec=function(e){return this.REGEX_HEXADECIMAL.lastIndex=0,"0x"===((e=this.trim(e))+"").slice(0,2)&&(e=(e+"").slice(2)),parseInt((e+"").replace(this.REGEX_HEXADECIMAL,""),16)},e.utf8chr=function(e){var t=String.fromCharCode;return 128>(e%=2097152)?t(e):2048>e?t(192|e>>6)+t(128|63&e):65536>e?t(224|e>>12)+t(128|e>>6&63)+t(128|63&e):t(240|e>>18)+t(128|e>>12&63)+t(128|e>>6&63)+t(128|63&e)},e.parseBoolean=function(e,t){var r;return null==t&&(t=!0),"string"==typeof e?(r=e.toLowerCase(),!(!t&&"no"===r)&&("0"!==r&&("false"!==r&&""!==r))):!!e},e.isNumeric=function(e){return this.REGEX_SPACES.lastIndex=0,"number"==typeof e||"string"==typeof e&&!isNaN(e)&&""!==e.replace(this.REGEX_SPACES,"")},e.stringToDate=function(e){var t,r,s,n,o,a,i,l,_,u;if(!(null!=e?e.length:void 0))return null;if(!(o=this.PATTERN_DATE.exec(e)))return null;if(u=parseInt(o.year,10),i=parseInt(o.month,10)-1,r=parseInt(o.day,10),null==o.hour)return t=new Date(Date.UTC(u,i,r));if(n=parseInt(o.hour,10),a=parseInt(o.minute,10),l=parseInt(o.second,10),null!=o.fraction){for(s=o.fraction.slice(0,3);s.length<3;)s+="0";s=parseInt(s,10)}else s=0;return null!=o.tz&&(_=6e4*(60*parseInt(o.tz_hour,10)+(null!=o.tz_minute?parseInt(o.tz_minute,10):0)),"-"===o.tz_sign&&(_*=-1)),t=new Date(Date.UTC(u,i,r,n,a,l,s)),_&&t.setTime(t.getTime()-_),t},e.strRepeat=function(e,t){var r,s="";for(r=0;r<t;)s+=e,r++;return s},e.getStringFromFile=function(e,t){var r,s,n,o,a,i,l;if(null==t&&(t=null),l=null,"undefined"!=typeof window&&null!==window)if(window.XMLHttpRequest)l=new XMLHttpRequest;else if(window.ActiveXObject)for(n=0,o=(i=["Msxml2.XMLHTTP.6.0","Msxml2.XMLHTTP.3.0","Msxml2.XMLHTTP","Microsoft.XMLHTTP"]).length;n<o;n++){a=i[n];try{l=new ActiveXObject(a)}catch(_){}}return null!=l?null!=t?(l.onreadystatechange=function(){if(4===l.readyState)return 200===l.status||0===l.status?t(l.responseText):t(null)},l.open("GET",e,!0),l.send(null)):(l.open("GET",e,!1),l.send(null),200===l.status||0===l.status?l.responseText:null):(s=__require("fs"),null!=t?s.readFile(e,(function(e,r){return t(e?null:String(r))})):null!=(r=s.readFileSync(e))?String(r):null)},e}(),t.exports=s})),require_Unescaper=__commonJSMin(((e,t)=>{var r,s,n=require_Utils();r=require_Pattern(),s=function(){function e(){}return e.PATTERN_ESCAPED_CHARACTER=new r('\\\\([0abt\tnvfre "\\/\\\\N_LP]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|U[0-9a-fA-F]{8})'),e.unescapeSingleQuotedString=function(e){return e.replace(/\'\'/g,"'")},e.unescapeDoubleQuotedString=function(e){var t;return null==this._unescapeCallback&&(this._unescapeCallback=(t=this,function(e){return t.unescapeCharacter(e)})),this.PATTERN_ESCAPED_CHARACTER.replace(e,this._unescapeCallback)},e.unescapeCharacter=function(e){var t=String.fromCharCode;switch(e.charAt(1)){case"0":return t(0);case"a":return t(7);case"b":return t(8);case"t":case"\t":return"\t";case"n":return"\n";case"v":return t(11);case"f":return t(12);case"r":return t(13);case"e":return t(27);case" ":return" ";case'"':return'"';case"/":return"/";case"\\":return"\\";case"N":return t(133);case"_":return t(160);case"L":return t(8232);case"P":return t(8233);case"x":return n.utf8chr(n.hexDec(e.substr(2,2)));case"u":return n.utf8chr(n.hexDec(e.substr(2,4)));case"U":return n.utf8chr(n.hexDec(e.substr(2,8)));default:return""}},e}(),t.exports=s})),require_Escaper=__commonJSMin(((e,t)=>{var r,s=require_Pattern();r=function(){var e;function t(){}return t.LIST_ESCAPEES=["\\","\\\\",'\\"','"',"\0","","","","","","","","\b","\t","\n","\v","\f","\r","","","","","","","","","","","","","","","","","","",(e=String.fromCharCode)(133),e(160),e(8232),e(8233)],t.LIST_ESCAPED=["\\\\",'\\"','\\"','\\"',"\\0","\\x01","\\x02","\\x03","\\x04","\\x05","\\x06","\\a","\\b","\\t","\\n","\\v","\\f","\\r","\\x0e","\\x0f","\\x10","\\x11","\\x12","\\x13","\\x14","\\x15","\\x16","\\x17","\\x18","\\x19","\\x1a","\\e","\\x1c","\\x1d","\\x1e","\\x1f","\\N","\\_","\\L","\\P"],t.MAPPING_ESCAPEES_TO_ESCAPED=function(){var e,r,s,n={};for(e=r=0,s=t.LIST_ESCAPEES.length;0<=s?r<s:r>s;e=0<=s?++r:--r)n[t.LIST_ESCAPEES[e]]=t.LIST_ESCAPED[e];return n}(),t.PATTERN_CHARACTERS_TO_ESCAPE=new s("[\\x00-\\x1f]|Â
| |â¨|â©"),t.PATTERN_MAPPING_ESCAPEES=new s(t.LIST_ESCAPEES.join("|").split("\\").join("\\\\")),t.PATTERN_SINGLE_QUOTING=new s("[\\s'\":{}[\\],&*#?]|^[-?|<>=!%@`]"),t.requiresDoubleQuoting=function(e){return this.PATTERN_CHARACTERS_TO_ESCAPE.test(e)},t.escapeWithDoubleQuotes=function(e){return'"'+this.PATTERN_MAPPING_ESCAPEES.replace(e,(t=this,function(e){return t.MAPPING_ESCAPEES_TO_ESCAPED[e]}))+'"';var t},t.requiresSingleQuoting=function(e){return this.PATTERN_SINGLE_QUOTING.test(e)},t.escapeWithSingleQuotes=function(e){return"'"+e.replace(/'/g,"''")+"'"},t}(),t.exports=r})),require_ParseException=__commonJSMin(((e,t)=>{var r,s={}.hasOwnProperty;r=function(e){function t(e,t,r){this.message=e,this.parsedLine=t,this.snippet=r}return function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function n(){this.constructor=e}n.prototype=t.prototype,e.prototype=new n,e.__super__=t.prototype}(t,Error),t.prototype.toString=function(){return null!=this.parsedLine&&null!=this.snippet?"<ParseException> "+this.message+" (line "+this.parsedLine+": '"+this.snippet+"')":"<ParseException> "+this.message},t}(),t.exports=r})),require_ParseMore=__commonJSMin(((e,t)=>{var r,s={}.hasOwnProperty;r=function(e){function t(e,t,r){this.message=e,this.parsedLine=t,this.snippet=r}return function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function n(){this.constructor=e}n.prototype=t.prototype,e.prototype=new n,e.__super__=t.prototype}(t,Error),t.prototype.toString=function(){return null!=this.parsedLine&&null!=this.snippet?"<ParseMore> "+this.message+" (line "+this.parsedLine+": '"+this.snippet+"')":"<ParseMore> "+this.message},t}(),t.exports=r})),require_DumpException=__commonJSMin(((e,t)=>{var r,s={}.hasOwnProperty;r=function(e){function t(e,t,r){this.message=e,this.parsedLine=t,this.snippet=r}return function(e,t){for(var r in t)s.call(t,r)&&(e[r]=t[r]);function n(){this.constructor=e}n.prototype=t.prototype,e.prototype=new n,e.__super__=t.prototype}(t,Error),t.prototype.toString=function(){return null!=this.parsedLine&&null!=this.snippet?"<DumpException> "+this.message+" (line "+this.parsedLine+": '"+this.snippet+"')":"<DumpException> "+this.message},t}(),t.exports=r})),require_Inline=__commonJSMin(((e,t)=>{var r,s,n,o,a,i,l,_=[].indexOf||function(e){for(var t=0,r=this.length;t<r;t++)if(t in this&&this[t]===e)return t;return-1};a=require_Pattern(),i=require_Unescaper(),r=require_Escaper(),l=require_Utils(),n=require_ParseException(),o=require_ParseMore(),require_DumpException(),s=function(){function e(){}return e.REGEX_QUOTED_STRING="(?:\"(?:[^\"\\\\]*(?:\\\\.[^\"\\\\]*)*)\"|'(?:[^']*(?:''[^']*)*)')",e.PATTERN_TRAILING_COMMENTS=new a("^\\s*#.*$"),e.PATTERN_QUOTED_SCALAR=new a("^"+e.REGEX_QUOTED_STRING),e.PATTERN_THOUSAND_NUMERIC_SCALAR=new a("^(-|\\+)?[0-9,]+(\\.[0-9]+)?$"),e.PATTERN_SCALAR_BY_DELIMITERS={},e.settings={},e.configure=function(e,t){null==e&&(e=null),null==t&&(t=null),this.settings.exceptionOnInvalidType=e,this.settings.objectDecoder=t},e.parse=function(e,t,r){var s,o;if(null==t&&(t=!1),null==r&&(r=null),this.settings.exceptionOnInvalidType=t,this.settings.objectDecoder=r,null==e)return"";if(0===(e=l.trim(e)).length)return"";switch(s={exceptionOnInvalidType:t,objectDecoder:r,i:0},e.charAt(0)){case"[":o=this.parseSequence(e,s),++s.i;break;case"{":o=this.parseMapping(e,s),++s.i;break;default:o=this.parseScalar(e,null,['"',"'"],s)}if(""!==this.PATTERN_TRAILING_COMMENTS.replace(e.slice(s.i),""))throw new n('Unexpected characters near "'+e.slice(s.i)+'".');return o},e.dump=function(e,t,s){var n,o,a;return null==t&&(t=!1),null==s&&(s=null),null==e?"null":"object"===(a=typeof e)?e instanceof Date?e.toISOString():null==s||"string"!=typeof(o=s(e))&&null==o?this.dumpObject(e):o:"boolean"===a?e?"true":"false":l.isDigits(e)?"string"===a?"'"+e+"'":String(parseInt(e)):l.isNumeric(e)?"string"===a?"'"+e+"'":String(parseFloat(e)):"number"===a?e===1/0?".Inf":e===-1/0?"-.Inf":isNaN(e)?".NaN":e:r.requiresDoubleQuoting(e)?r.escapeWithDoubleQuotes(e):r.requiresSingleQuoting(e)?r.escapeWithSingleQuotes(e):""===e?'""':l.PATTERN_DATE.test(e)||"null"===(n=e.toLowerCase())||"~"===n||"true"===n||"false"===n?"'"+e+"'":e},e.dumpObject=function(e,t,r){var s,n,o,a,i;if(null==r&&(r=null),e instanceof Array){for(a=[],s=0,o=e.length;s<o;s++)i=e[s],a.push(this.dump(i));return"["+a.join(", ")+"]"}for(n in a=[],e)i=e[n],a.push(this.dump(n)+": "+this.dump(i));return"{"+a.join(", ")+"}"},e.parseScalar=function(e,t,r,s,o){var i,u,p,c,d,m,h,y;if(null==t&&(t=null),null==r&&(r=['"',"'"]),null==s&&(s=null),null==o&&(o=!0),null==s&&(s={exceptionOnInvalidType:this.settings.exceptionOnInvalidType,objectDecoder:this.settings.objectDecoder,i:0}),i=s.i,m=e.charAt(i),_.call(r,m)>=0){if(c=this.parseQuotedScalar(e,s),i=s.i,null!=t&&(h=l.ltrim(e.slice(i)," ").charAt(0),!(_.call(t,h)>=0)))throw new n("Unexpected characters ("+e.slice(i)+").")}else{if(t){if(u=t.join("|"),null==(d=this.PATTERN_SCALAR_BY_DELIMITERS[u])&&(d=new a("^(.+?)("+u+")"),this.PATTERN_SCALAR_BY_DELIMITERS[u]=d),!(p=d.exec(e.slice(i))))throw new n("Malformed inline YAML string ("+e+").");i+=(c=p[1]).length}else i+=(c=e.slice(i)).length,-1!==(y=c.indexOf(" #"))&&(c=l.rtrim(c.slice(0,y)));o&&(c=this.evaluateScalar(c,s))}return s.i=i,c},e.parseQuotedScalar=function(e,t){var r,s,n=t.i;if(!(r=this.PATTERN_QUOTED_SCALAR.exec(e.slice(n))))throw new o("Malformed inline YAML string ("+e.slice(n)+").");return s=r[0].substr(1,r[0].length-2),s='"'===e.charAt(n)?i.unescapeDoubleQuotedString(s):i.unescapeSingleQuotedString(s),n+=r[0].length,t.i=n,s},e.parseSequence=function(e,t){var r,s,n,a,i,l=[];for(n=e.length,r=t.i,r+=1;r<n;){switch(t.i=r,e.charAt(r)){case"[":l.push(this.parseSequence(e,t)),r=t.i;break;case"{":l.push(this.parseMapping(e,t)),r=t.i;break;case"]":return l;case",":case" ":case"\n":break;default:if(s='"'===(a=e.charAt(r))||"'"===a,i=this.parseScalar(e,[",","]"],['"',"'"],t),r=t.i,!s&&"string"==typeof i&&(-1!==i.indexOf(": ")||-1!==i.indexOf(":\n")))try{i=this.parseMapping("{"+i+"}")}catch(_){}l.push(i),--r}++r}throw new o("Malformed inline YAML string "+e)},e.parseMapping=function(e,t){var r,s,n,a,i,l,_={};for(a=e.length,s=t.i,s+=1,i=!1;s<a;){switch(t.i=s,e.charAt(s)){case" ":case",":case"\n":++s,t.i=s,i=!0;break;case"}":return _}if(i)i=!1;else for(n=this.parseScalar(e,[":"," ","\n"],['"',"'"],t,!1),s=t.i,r=!1;s<a;){switch(t.i=s,e.charAt(s)){case"[":l=this.parseSequence(e,t),s=t.i,void 0===_[n]&&(_[n]=l),r=!0;break;case"{":l=this.parseMapping(e,t),s=t.i,void 0===_[n]&&(_[n]=l),r=!0;break;case":":case" ":case"\n":break;default:l=this.parseScalar(e,[",","}"],['"',"'"],t),s=t.i,void 0===_[n]&&(_[n]=l),r=!0,--s}if(++s,r)break}}throw new o("Malformed inline YAML string "+e)},e.evaluateScalar=function(e,t){var r,s,o,a,i,_,u,p,c;switch(u=(e=l.trim(e)).toLowerCase()){case"null":case"":case"~":return null;case"true":return!0;case"false":return!1;case".inf":case"-.inf":return 1/0;case".nan":return NaN;default:switch(u.charAt(0)){case"!":switch(-1===(a=e.indexOf(" "))?u:u.slice(0,a)){case"!":return-1!==a?parseInt(this.parseScalar(e.slice(2))):null;case"!str":return l.ltrim(e.slice(4));case"!!str":return l.ltrim(e.slice(5));case"!!int":return parseInt(this.parseScalar(e.slice(5)));case"!!bool":return l.parseBoolean(this.parseScalar(e.slice(6)),!1);case"!!float":return parseFloat(this.parseScalar(e.slice(7)));case"!!timestamp":return l.stringToDate(l.ltrim(e.slice(11)));default:if(null==t&&(t={exceptionOnInvalidType:this.settings.exceptionOnInvalidType,objectDecoder:this.settings.objectDecoder,i:0}),i=t.objectDecoder,o=t.exceptionOnInvalidType,i)return-1===(a=(c=l.rtrim(e)).indexOf(" "))?i(c,null):((p=l.ltrim(c.slice(a+1))).length>0||(p=null),i(c.slice(0,a),p));if(o)throw new n("Custom object support when parsing a YAML file has been disabled.");return null}break;case"0":return"0x"===e.slice(0,2)?l.hexDec(e):l.isDigits(e)?l.octDec(e):l.isNumeric(e)?parseFloat(e):e;case"+":return l.isDigits(e)?(_=e,r=parseInt(_),_===String(r)?r:_):l.isNumeric(e)?parseFloat(e):this.PATTERN_THOUSAND_NUMERIC_SCALAR.test(e)?parseFloat(e.replace(",","")):e;case"-":return l.isDigits(e.slice(1))?"0"===e.charAt(1)?-l.octDec(e.slice(1)):(_=e.slice(1),r=parseInt(_),_===String(r)?-r:-_):l.isNumeric(e)?parseFloat(e):this.PATTERN_THOUSAND_NUMERIC_SCALAR.test(e)?parseFloat(e.replace(",","")):e;default:return(s=l.stringToDate(e))?s:l.isNumeric(e)?parseFloat(e):this.PATTERN_THOUSAND_NUMERIC_SCALAR.test(e)?parseFloat(e.replace(",","")):e}}},e}(),t.exports=s})),require_Parser=__commonJSMin(((e,t)=>{var r,s,n,o=require_Inline(),a=require_Pattern(),i=require_Utils();r=require_ParseException(),s=require_ParseMore(),n=function(){function e(e){this.offset=null!=e?e:0,this.lines=[],this.currentLineNb=-1,this.currentLine="",this.refs={}}return e.prototype.PATTERN_FOLDED_SCALAR_ALL=new a("^(?:(?<type>![^\\|>]*)\\s+)?(?<separator>\\||>)(?<modifiers>\\+|\\-|\\d+|\\+\\d+|\\-\\d+|\\d+\\+|\\d+\\-)?(?<comments> +#.*)?$"),e.prototype.PATTERN_FOLDED_SCALAR_END=new a("(?<separator>\\||>)(?<modifiers>\\+|\\-|\\d+|\\+\\d+|\\-\\d+|\\d+\\+|\\d+\\-)?(?<comments> +#.*)?$"),e.prototype.PATTERN_SEQUENCE_ITEM=new a("^\\-((?<leadspaces>\\s+)(?<value>.+?))?\\s*$"),e.prototype.PATTERN_ANCHOR_VALUE=new a("^&(?<ref>[^ ]+) *(?<value>.*)"),e.prototype.PATTERN_COMPACT_NOTATION=new a("^(?<key>"+o.REGEX_QUOTED_STRING+"|[^ '\"\\{\\[].*?) *\\:(\\s+(?<value>.+?))?\\s*$"),e.prototype.PATTERN_MAPPING_ITEM=new a("^(?<key>"+o.REGEX_QUOTED_STRING+"|[^ '\"\\[\\{].*?) *\\:(\\s+(?<value>.+?))?\\s*$"),e.prototype.PATTERN_DECIMAL=new a("\\d+"),e.prototype.PATTERN_INDENT_SPACES=new a("^ +"),e.prototype.PATTERN_TRAILING_LINES=new a("(\n*)$"),e.prototype.PATTERN_YAML_HEADER=new a("^\\%YAML[: ][\\d\\.]+.*\n","m"),e.prototype.PATTERN_LEADING_COMMENTS=new a("^(\\#.*?\n)+","m"),e.prototype.PATTERN_DOCUMENT_MARKER_START=new a("^\\-\\-\\-.*?\n","m"),e.prototype.PATTERN_DOCUMENT_MARKER_END=new a("^\\.\\.\\.\\s*$","m"),e.prototype.PATTERN_FOLDED_SCALAR_BY_INDENTATION={},e.prototype.CONTEXT_NONE=0,e.prototype.CONTEXT_SEQUENCE=1,e.prototype.CONTEXT_MAPPING=2,e.prototype.parse=function(t,s,n){var a,l,_,u,p,c,d,m,h,y,g,f,w,b,E,x,T,S,A,C,O,R,v,N,M,P,I,k,F,L,U,D,j,B,q;for(null==s&&(s=!1),null==n&&(n=null),this.currentLineNb=-1,this.currentLine="",this.lines=this.cleanup(t).split("\n"),p=null,u=this.CONTEXT_NONE,l=!1;this.moveToNextLine();)if(!this.isCurrentLineEmpty()){if("\t"===this.currentLine[0])throw new r("A YAML file cannot contain tabs as indentation.",this.getRealCurrentLineNb()+1,this.currentLine);if(y=v=!1,q=this.PATTERN_SEQUENCE_ITEM.exec(this.currentLine)){if(this.CONTEXT_MAPPING===u)throw new r("You cannot define a sequence item when in a mapping");u=this.CONTEXT_SEQUENCE,null==p&&(p=[]),null!=q.value&&(R=this.PATTERN_ANCHOR_VALUE.exec(q.value))&&(y=R.ref,q.value=R.value),null==q.value||""===i.trim(q.value," ")||0===i.ltrim(q.value," ").indexOf("#")?this.currentLineNb<this.lines.length-1&&!this.isNextLineUnIndentedCollection()?((k=new e(this.getRealCurrentLineNb()+1)).refs=this.refs,p.push(k.parse(this.getNextEmbedBlock(null,!0),s,n))):p.push(null):(null!=(F=q.leadspaces)?F.length:void 0)&&(R=this.PATTERN_COMPACT_NOTATION.exec(q.value))?((k=new e(this.getRealCurrentLineNb())).refs=this.refs,_=q.value,h=this.getCurrentLineIndentation(),this.isNextLineIndented(!1)&&(_+="\n"+this.getNextEmbedBlock(h+q.leadspaces.length+1,!0)),p.push(k.parse(_,s,n))):p.push(this.parseValue(q.value,s,n))}else{if(!(q=this.PATTERN_MAPPING_ITEM.exec(this.currentLine))||-1!==q.key.indexOf(" #")){if(1===(C=this.lines.length)||2===C&&i.isEmpty(this.lines[1])){try{t=o.parse(this.lines[0],s,n)}catch($){throw(c=$).parsedLine=this.getRealCurrentLineNb()+1,c.snippet=this.currentLine,c}if("object"==typeof t){if(t instanceof Array)d=t[0];else for(w in t){d=t[w];break}if("string"==typeof d&&0===d.indexOf("*")){for(p=[],N=0,A=t.length;N<A;N++)a=t[N],p.push(this.refs[a.slice(1)]);t=p}}return t}if("["===(U=i.ltrim(t).charAt(0))||"{"===U)try{return o.parse(t,s,n)}catch($){throw(c=$).parsedLine=this.getRealCurrentLineNb()+1,c.snippet=this.currentLine,c}throw new r("Unable to parse.",this.getRealCurrentLineNb()+1,this.currentLine)}if(this.CONTEXT_SEQUENCE===u)throw new r("You cannot define a mapping item when in a sequence");u=this.CONTEXT_MAPPING,null==p&&(p={}),o.configure(s,n);try{w=o.parseScalar(q.key)}catch($){throw(c=$).parsedLine=this.getRealCurrentLineNb()+1,c.snippet=this.currentLine,c}if("<<"===w)if(v=!0,l=!0,0===(null!=(L=q.value)?L.indexOf("*"):void 0)){if(D=q.value.slice(1),null==this.refs[D])throw new r('Reference "'+D+'" does not exist.',this.getRealCurrentLineNb()+1,this.currentLine);if("object"!=typeof(j=this.refs[D]))throw new r("YAML merge keys used with a scalar value instead of an object.",this.getRealCurrentLineNb()+1,this.currentLine);if(j instanceof Array)for(m=g=0,x=j.length;g<x;m=++g)t=j[m],null==p[M=String(m)]&&(p[M]=t);else for(w in j)t=j[w],null==p[w]&&(p[w]=t)}else{if(t=null!=q.value&&""!==q.value?q.value:this.getNextEmbedBlock(),(k=new e(this.getRealCurrentLineNb()+1)).refs=this.refs,"object"!=typeof(P=k.parse(t,s)))throw new r("YAML merge keys used with a scalar value instead of an object.",this.getRealCurrentLineNb()+1,this.currentLine);if(P instanceof Array)for(b=0,T=P.length;b<T;b++){if("object"!=typeof(I=P[b]))throw new r("Merge items must be objects.",this.getRealCurrentLineNb()+1,I);if(I instanceof Array)for(m=O=0,S=I.length;O<S;m=++O)t=I[m],f=String(m),p.hasOwnProperty(f)||(p[f]=t);else for(w in I)t=I[w],p.hasOwnProperty(w)||(p[w]=t)}else for(w in P)t=P[w],p.hasOwnProperty(w)||(p[w]=t)}else null!=q.value&&(R=this.PATTERN_ANCHOR_VALUE.exec(q.value))&&(y=R.ref,q.value=R.value);v||(null==q.value||""===i.trim(q.value," ")||0===i.ltrim(q.value," ").indexOf("#")?this.isNextLineIndented()||this.isNextLineUnIndentedCollection()?((k=new e(this.getRealCurrentLineNb()+1)).refs=this.refs,B=k.parse(this.getNextEmbedBlock(),s,n),(l||void 0===p[w])&&(p[w]=B)):(l||void 0===p[w])&&(p[w]=null):(B=this.parseValue(q.value,s,n),(l||void 0===p[w])&&(p[w]=B)))}if(y)if(p instanceof Array)this.refs[y]=p[p.length-1];else{for(w in E=null,p)E=w;this.refs[y]=p[E]}}return i.isEmpty(p)?null:p},e.prototype.getRealCurrentLineNb=function(){return this.currentLineNb+this.offset},e.prototype.getCurrentLineIndentation=function(){return this.currentLine.length-i.ltrim(this.currentLine," ").length},e.prototype.getNextEmbedBlock=function(e,t){var s,n,o,a,l,_,u;if(null==e&&(e=null),null==t&&(t=!1),this.moveToNextLine(),null==e){if(a=this.getCurrentLineIndentation(),u=this.isStringUnIndentedCollectionItem(this.currentLine),!this.isCurrentLineEmpty()&&0===a&&!u)throw new r("Indentation problem.",this.getRealCurrentLineNb()+1,this.currentLine)}else a=e;for(s=[this.currentLine.slice(a)],t||(o=this.isStringUnIndentedCollectionItem(this.currentLine)),l=!(_=this.PATTERN_FOLDED_SCALAR_END).test(this.currentLine);this.moveToNextLine();)if((n=this.getCurrentLineIndentation())===a&&(l=!_.test(this.currentLine)),!l||!this.isCurrentLineComment())if(this.isCurrentLineBlank())s.push(this.currentLine.slice(a));else{if(o&&!this.isStringUnIndentedCollectionItem(this.currentLine)&&n===a){this.moveToPreviousLine();break}if(n>=a)s.push(this.currentLine.slice(a));else if("#"!==i.ltrim(this.currentLine).charAt(0)){if(0===n){this.moveToPreviousLine();break}throw new r("Indentation problem.",this.getRealCurrentLineNb()+1,this.currentLine)}}return s.join("\n")},e.prototype.moveToNextLine=function(){return!(this.currentLineNb>=this.lines.length-1)&&(this.currentLine=this.lines[++this.currentLineNb],!0)},e.prototype.moveToPreviousLine=function(){this.currentLine=this.lines[--this.currentLineNb]},e.prototype.parseValue=function(e,t,n){var a,l,_,u,p,c,d,m;if(0===e.indexOf("*")){if(p=e.indexOf("#"),e=-1!==p?e.substr(1,p-2):e.slice(1),void 0===this.refs[e])throw new r('Reference "'+e+'" does not exist.',this.currentLine);return this.refs[e]}if(_=this.PATTERN_FOLDED_SCALAR_ALL.exec(e))return u=null!=(c=_.modifiers)?c:"",l=Math.abs(parseInt(u)),isNaN(l)&&(l=0),m=this.parseFoldedScalar(_.separator,this.PATTERN_DECIMAL.replace(u,""),l),null!=_.type?(o.configure(t,n),o.parseScalar(_.type+" "+m)):m;if("["!==(d=e.charAt(0))&&"{"!==d&&'"'!==d&&"'"!==d)return this.isNextLineIndented()&&(e+="\n"+this.getNextEmbedBlock()),o.parse(e,t,n);for(;;)try{return o.parse(e,t,n)}catch(h){if(!((a=h)instanceof s&&this.moveToNextLine()))throw a.parsedLine=this.getRealCurrentLineNb()+1,a.snippet=this.currentLine,a;e+="\n"+i.trim(this.currentLine," ")}},e.prototype.parseFoldedScalar=function(t,r,s){var n,o,l,_,u,p,c,d,m,h;if(null==r&&(r=""),null==s&&(s=0),!(c=this.moveToNextLine()))return"";for(n=this.isCurrentLineBlank(),h="";c&&n;)(c=this.moveToNextLine())&&(h+="\n",n=this.isCurrentLineBlank());if(0===s&&(u=this.PATTERN_INDENT_SPACES.exec(this.currentLine))&&(s=u[0].length),s>0)for(null==(d=this.PATTERN_FOLDED_SCALAR_BY_INDENTATION[s])&&(d=new a("^ {"+s+"}(.*)$"),e.prototype.PATTERN_FOLDED_SCALAR_BY_INDENTATION[s]=d);c&&(n||(u=d.exec(this.currentLine)));)h+=n?this.currentLine.slice(s):u[1],(c=this.moveToNextLine())&&(h+="\n",n=this.isCurrentLineBlank());else c&&(h+="\n");if(c&&this.moveToPreviousLine(),">"===t){for(p="",o=0,l=(m=h.split("\n")).length;o<l;o++)0===(_=m[o]).length||" "===_.charAt(0)?p=i.rtrim(p," ")+_+"\n":p+=_+" ";h=p}return"+"!==r&&(h=i.rtrim(h)),""===r?h=this.PATTERN_TRAILING_LINES.replace(h,"\n"):"-"===r&&(h=this.PATTERN_TRAILING_LINES.replace(h,"")),h},e.prototype.isNextLineIndented=function(e){var t,r,s;if(null==e&&(e=!0),r=this.getCurrentLineIndentation(),t=!this.moveToNextLine(),e)for(;!t&&this.isCurrentLineEmpty();)t=!this.moveToNextLine();else for(;!t&&this.isCurrentLineBlank();)t=!this.moveToNextLine();return!t&&(s=!1,this.getCurrentLineIndentation()>r&&(s=!0),this.moveToPreviousLine(),s)},e.prototype.isCurrentLineEmpty=function(){var e=i.trim(this.currentLine," ");return 0===e.length||"#"===e.charAt(0)},e.prototype.isCurrentLineBlank=function(){return""===i.trim(this.currentLine," ")},e.prototype.isCurrentLineComment=function(){return"#"===i.ltrim(this.currentLine," ").charAt(0)},e.prototype.cleanup=function(e){var t,r,s,n,o,a,l,_,u,p,c,d,m,h;for(-1!==e.indexOf("\r")&&(e=e.split("\r\n").join("\n").split("\r").join("\n")),t=0,e=(p=this.PATTERN_YAML_HEADER.replaceAll(e,""))[0],t=p[1],this.offset+=t,h=(c=this.PATTERN_LEADING_COMMENTS.replaceAll(e,"",1))[0],1===(t=c[1])&&(this.offset+=i.subStrCount(e,"\n")-i.subStrCount(h,"\n"),e=h),h=(d=this.PATTERN_DOCUMENT_MARKER_START.replaceAll(e,"",1))[0],1===(t=d[1])&&(this.offset+=i.subStrCount(e,"\n")-i.subStrCount(h,"\n"),e=h,e=this.PATTERN_DOCUMENT_MARKER_END.replace(e,"")),m=-1,n=0,a=(u=e.split("\n")).length;n<a;n++)_=u[n],0!==i.trim(_," ").length&&(s=_.length-i.ltrim(_).length,(-1===m||s<m)&&(m=s));if(m>0){for(r=o=0,l=u.length;o<l;r=++o)_=u[r],u[r]=_.slice(m);e=u.join("\n")}return e},e.prototype.isNextLineUnIndentedCollection=function(e){var t,r;for(null==e&&(e=null),null==e&&(e=this.getCurrentLineIndentation()),t=this.moveToNextLine();t&&this.isCurrentLineEmpty();)t=this.moveToNextLine();return!1!==t&&(r=!1,this.getCurrentLineIndentation()===e&&this.isStringUnIndentedCollectionItem(this.currentLine)&&(r=!0),this.moveToPreviousLine(),r)},e.prototype.isStringUnIndentedCollectionItem=function(){return"-"===this.currentLine||"- "===this.currentLine.slice(0,2)},e}(),t.exports=n})),require_Dumper=__commonJSMin(((e,t)=>{var r,s,n=require_Utils();s=require_Inline(),r=function(){function e(){}return e.indentation=4,e.prototype.dump=function(e,t,r,o,a){var i,l,_,u,p,c,d;if(null==t&&(t=0),null==r&&(r=0),null==o&&(o=!1),null==a&&(a=null),u="",p=r?n.strRepeat(" ",r):"",t<=0||"object"!=typeof e||e instanceof Date||n.isEmpty(e))u+=p+s.dump(e,o,a);else if(e instanceof Array)for(i=0,_=e.length;i<_;i++)c=e[i],u+=p+"-"+((d=t-1<=0||"object"!=typeof c||n.isEmpty(c))?" ":"\n")+this.dump(c,t-1,d?0:r+this.indentation,o,a)+(d?"\n":"");else for(l in e)c=e[l],d=t-1<=0||"object"!=typeof c||n.isEmpty(c),u+=p+s.dump(l,o,a)+":"+(d?" ":"\n")+this.dump(c,t-1,d?0:r+this.indentation,o,a)+(d?"\n":"");return u},e}(),t.exports=r})),require_Yaml=__commonJSMin(((e,t)=>{var r,s,n,o=require_Parser();r=require_Dumper(),s=require_Utils(),n=function(){function e(){}return e.parse=function(e,t,r){return null==t&&(t=!1),null==r&&(r=null),(new o).parse(e,t,r)},e.parseFile=function(e,t,r,n){var o,a;return null==t&&(t=null),null==r&&(r=!1),null==n&&(n=null),null!=t?s.getStringFromFile(e,(a=this,function(e){var s=null;null!=e&&(s=a.parse(e,r,n)),t(s)})):null!=(o=s.getStringFromFile(e))?this.parse(o,r,n):null},e.dump=function(e,t,s,n,o){var a;return null==t&&(t=2),null==s&&(s=4),null==n&&(n=!1),null==o&&(o=null),(a=new r).indentation=s,a.dump(e,t,0,n,o)},e.stringify=function(e,t,r,s,n){return this.dump(e,t,r,s,n)},e.load=function(e,t,r,s){return this.parseFile(e,t,r,s)},e}(),"undefined"!=typeof window&&null!==window&&(window.YAML=n),"undefined"!=typeof window&&null!==window||(e.YAML=n),t.exports=n})),import_Yaml=__toESM(require_Yaml(),1),supportedArgs$43=new Set([...COMMON_SUPPORTED_ARGS,"compressed","no-compressed","netrc","netrc-optional","no-netrc","no-netrc-optional","cacert","cert","key","ciphers","insecure","no-insecure","anyauth","no-anyauth","digest","no-digest","aws-sigv4","negotiate","no-negotiate","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb","unix-socket","abstract-unix-socket","max-time","location","no-location","location-trusted","no-location-trusted","upload-file","output","form","form-string"]),supportedArgs$42=new Set([...COMMON_SUPPORTED_ARGS,"disallow-username-in-url","path-as-is","alt-svc","unix-socket","abstract-unix-socket","compressed","no-compressed","verbose","no-verbose","proxy","proxy-user","proxytunnel","noproxy","preproxy","proxy-anyauth","proxy-basic","proxy-digest","proxy-negotiate","proxy-ntlm","proxy-ca-native","proxy-cacert","proxy-capath","proxy-cert-type","proxy-cert","proxy-ciphers","proxy-crlfile","proxy-header","proxy-http2","proxy-insecure","proxy-key","proxy-key-type","proxy-pass","proxy-pinnedpubkey","proxy-service-name","proxy-ssl-allow-beast","proxy-ssl-auto-client-cert","proxy-tls13-ciphers","proxy-tlsuser","proxy-tlspassword","proxy-tlsauthtype","proxy-tlsv1","socks4","socks4a","socks5","socks5-hostname","socks5-basic","socks5-gssapi","socks5-gssapi-nec","socks5-gssapi-service","haproxy-clientip","haproxy-protocol","interface","netrc","netrc-file","netrc-optional","digest","no-digest","negotiate","no-negotiate","service-name","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb","aws-sigv4","delegation","oauth2-bearer","ipv4","ipv6","local-port","ftp-skip-pasv-ip","sasl-authzid","sasl-ir","tr-encoding","tcp-fastopen","proto-default","ignore-content-length","no-ignore-content-length","remote-time","fail","continue-at","speed-limit","speed-time","limit-rate","max-filesize","http0.9","http1.0","http1.1","http2","http2-prior-knowledge","http3","http3-only","cookie-jar","junk-session-cookies","crlf","no-crlf","use-ascii","pass","cacert","capath","crlfile","pinnedpubkey","curves","cert","cert-status","cert-type","key","key-type","ca-native","ssl-allow-beast","ciphers","tls13-ciphers","tlsuser","tlspassword","tlsauthtype","ssl","ssl-auto-client-cert","ssl-no-revoke","ssl-reqd","ssl-revoke-best-effort","tlsv1","tlsv1.0","tlsv1.1","tlsv1.2","tlsv1.3","tls-max","hsts","alpn","no-alpn","form","form-string","form-escape","no-form-escape","doh-url","doh-cert-status","location","no-location","location-trusted","no-location-trusted","max-redirs","post301","post302","post303","max-time","connect-timeout","expect100-timeout","happy-eyeballs-timeout-ms","resolve","connect-to","keepalive","no-keepalive","keepalive-time","insecure","no-insecure"]),require_jsesc=__commonJSMin(((e,t)=>{var r={},s=r.hasOwnProperty,n=(e,t)=>{for(const r in e)s.call(e,r)&&t(r,e[r])},o=e=>"\\u"+("0000"+e).slice(-4),a=(e,t)=>{let r=e.toString(16);return t?r:r.toUpperCase()},i=r.toString,l=Array.isArray,_={"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t"},u=/[\\\b\f\n\r\t]/,p=/[0-9]/,c=/[\xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,d=/([\uD800-\uDBFF][\uDC00-\uDFFF])|([\uD800-\uDFFF])|(['"`])|[^]/g,m=/([\uD800-\uDBFF][\uDC00-\uDFFF])|([\uD800-\uDFFF])|(['"`])|[^ !#-&\(-\[\]-_a-~]/g,h=(e,t)=>{const r=()=>{T=x,++t.indentLevel,x=t.indent.repeat(t.indentLevel)},s={escapeEverything:!1,minimal:!1,isScriptContext:!1,quotes:"single",wrap:!1,es6:!1,json:!1,compact:!0,lowercaseHex:!1,numbers:"decimal",indent:"\t",indentLevel:0,__inline1__:!1,__inline2__:!1},y=t&&t.json;var g,f;y&&(s.quotes="double",s.wrap=!0),g=s,t=(f=t)?(n(f,((e,t)=>{g[e]=t})),g):g,"single"!=t.quotes&&"double"!=t.quotes&&"backtick"!=t.quotes&&(t.quotes="single");const w="double"==t.quotes?'"':"backtick"==t.quotes?"`":"'",b=t.compact,E=t.lowercaseHex;let x=t.indent.repeat(t.indentLevel),T="";const S=t.__inline1__,A=t.__inline2__,C=b?"":"\n";let O,R=!0;const v="binary"==t.numbers,N="octal"==t.numbers,M="decimal"==t.numbers,P="hexadecimal"==t.numbers;if(y&&e&&"function"==typeof e.toJSON&&(e=e.toJSON()),!(e=>"string"==typeof e||"[object String]"==i.call(e))(e)){if((e=>"[object Map]"==i.call(e))(e))return 0==e.size?"new Map()":(b||(t.__inline1__=!0,t.__inline2__=!1),"new Map("+h(Array.from(e),t)+")");if((e=>"[object Set]"==i.call(e))(e))return 0==e.size?"new Set()":"new Set("+h(Array.from(e),t)+")";if((e=>"function"==typeof Buffer&&Buffer.isBuffer(e))(e))return 0==e.length?"Buffer.from([])":"Buffer.from("+h(Array.from(e),t)+")";if(l(e))return O=[],t.wrap=!0,S&&(t.__inline1__=!1,t.__inline2__=!0),A||r(),((e,t)=>{const r=e.length;let s=-1;for(;++s<r;)t(e[s])})(e,(e=>{R=!1,A&&(t.__inline2__=!1),O.push((b||A?"":x)+h(e,t))})),R?"[]":A?"["+O.join(", ")+"]":"["+C+O.join(","+C)+C+(b?"":T)+"]";if(!(e=>"number"==typeof e||"[object Number]"==i.call(e))(e))return(e=>"[object Object]"==i.call(e))(e)?(O=[],t.wrap=!0,r(),n(e,((e,r)=>{R=!1,O.push((b?"":x)+h(e,t)+":"+(b?"":" ")+h(r,t))})),R?"{}":"{"+C+O.join(","+C)+C+(b?"":T)+"}"):y?JSON.stringify(e)||"null":String(e);if(y)return JSON.stringify(e);if(M)return String(e);if(P){let t=e.toString(16);return E||(t=t.toUpperCase()),"0x"+t}if(v)return"0b"+e.toString(2);if(N)return"0o"+e.toString(8)}const I=t.escapeEverything?d:m;return O=e.replace(I,((e,r,s,n,i,l)=>{if(r){if(t.minimal)return r;const e=r.charCodeAt(0),s=r.charCodeAt(1);return t.es6?"\\u{"+a(1024*(e-55296)+s-56320+65536,E)+"}":o(a(e,E))+o(a(s,E))}if(s)return o(a(s.charCodeAt(0),E));if("\0"==e&&!y&&!p.test(l.charAt(i+1)))return"\\0";if(n)return n==w||t.escapeEverything?"\\"+n:n;if(u.test(e))return _[e];if(t.minimal&&!c.test(e))return e;const d=a(e.charCodeAt(0),E);return y||d.length>2?o(d):"\\x"+("00"+d).slice(-2)})),"`"==w&&(O=O.replace(/\$\{/g,"\\${")),t.isScriptContext&&(O=O.replace(/<\/(script|style)/gi,"<\\/$1").replace(/<!--/g,y?"\\u003C!--":"\\x3C!--")),t.wrap&&(O=w+O+w),O};h.version="3.0.2",t.exports=h})),import_jsesc=__toESM(require_jsesc(),1),javaScriptSupportedArgs=new Set([...COMMON_SUPPORTED_ARGS,"upload-file","form","form-string","digest","no-digest","next","compressed"]),nodeSupportedArgs=new Set([...javaScriptSupportedArgs,"proxy"]),FORBIDDEN_HEADERS=["Accept-Charset","Accept-Encoding","Access-Control-Request-Headers","Access-Control-Request-Method","Connection","Content-Length","Cookie","Cookie2","Date","DNT","Expect","Host","Keep-Alive","Origin","Referer","Set-Cookie","TE","Trailer","Transfer-Encoding","Upgrade","Via"].map((e=>e.toLowerCase())),supportedArgs$41=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-time","proxy","proxy-user"]),supportedArgs$40=new Set([...COMMON_SUPPORTED_ARGS,"max-time","connect-timeout","location","upload-file","http2"]),supportedArgs$39=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","insecure","no-insecure","compressed","no-compressed","max-time","connect-timeout","max-redirs","location","no-location","location-trusted","no-location-trusted","digest","no-digest","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb"]),supportedArgs$38=new Set([...COMMON_SUPPORTED_ARGS,"compressed","form","form-string","http0.9","http1.0","http1.1","insecure","no-compressed","no-digest","no-http0.9","no-insecure","proxy","upload-file"]),supportedArgs$37=new Set([...COMMON_SUPPORTED_ARGS,"compressed","form","form-string","no-compressed"]),supportedArgs$36=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","insecure","no-insecure","next"]),supportedArgs$35=new Set([...COMMON_SUPPORTED_ARGS,"compressed","digest","no-digest","aws-sigv4","negotiate","no-negotiate","delegation","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb","http1.1","http2","http2-prior-knowledge","http3","http3-only","cookie-jar","cert","cacert","key","capath","form","form-string","location","no-location","location-trusted","no-location-trusted","max-redirs","max-time","connect-timeout","insecure","no-insecure","output","upload-file","next","proxy","proxy-user"]),supportedArgs$34=new Set([...COMMON_SUPPORTED_ARGS,"insecure","no-insecure","compressed","no-compressed","max-time","form","form-string"]),supportedArgs$33=new Set([...COMMON_SUPPORTED_ARGS,"anyauth","no-anyauth","http1.1","http2","http2-prior-knowledge","http3","http3-only"]),supportedArgs$32=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","http0.9","http1.0","http1.1","http2","http2-prior-knowledge","http3","http3-only","no-http0.9","compressed","no-compressed","upload-file"]),supportedArgs$31=new Set([...COMMON_SUPPORTED_ARGS,"cookie-jar","ipv4","no-ipv4","ipv6","no-ipv6","form","form-string","ciphers","insecure","cert","cert-type","key","key-type","cacert","capath","crlfile","pinnedpubkey","random-file","egd-file","hsts","noproxy","proxy","proxy-user","globoff","no-globoff","netrc","netrc-optional","timeout","connect-timeout","limit-rate","compressed","no-compressed","anyauth","no-anyauth","digest","no-digest","aws-sigv4","negotiate","no-negotiate","delegation","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb","no-digest","output","upload-file","continue-at","clobber","remote-time","keep-alive","silent","verbose","next"]),supportedArgs$30=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","location","no-location","location-trusted","no-location-trusted","max-redirs","ciphers","insecure","cert","key","cacert","capath","proxy","noproxy","timeout","connect-timeout","anyauth","no-anyauth","digest","no-digest","negotiate","no-negotiate","delegation","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb","no-netrc","verbose","silent","upload-file","next"]),supportedArgs$29=new Set([...COMMON_SUPPORTED_ARGS]),supportedArgs$28=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-time"]),supportedArgs$27=new Set([...COMMON_SUPPORTED_ARGS,"max-time","connect-timeout","location","location-trusted","upload-file","form","form-string"]),supportedArgs$26=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-time"]),supportedArgs$25=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-time"]),supportedArgs$24=new Set([...COMMON_SUPPORTED_ARGS,"insecure","no-insecure","form","form-string","compressed","location","no-location","location-trusted","no-location-trusted","max-redirs","output","include","proxy","max-time","connect-timeout","anyauth","no-anyauth","digest","no-digest","aws-sigv4","negotiate","no-negotiate","delegation","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb"]),supportedArgs$23=new Set([...COMMON_SUPPORTED_ARGS,"max-time","no-compressed","insecure","no-insecure","upload-file","connect-timeout","timeout","retry","location","max-redirs","form","form-string"]),supportedArgs$22=new Set([...COMMON_SUPPORTED_ARGS,"max-time","connect-timeout","location","location-trusted","upload-file","form","form-string"]),supportedArgs$21=new Set([...COMMON_SUPPORTED_ARGS]),supportedArgs$20=new Set([...COMMON_SUPPORTED_ARGS,"insecure","no-insecure","form","form-string"]),supportedArgs$19=new Set([...COMMON_SUPPORTED_ARGS,"max-time","form","form-string","proxy","proxy-user"]),supportedArgs$18=new Set([...COMMON_SUPPORTED_ARGS,"max-time","connect-timeout","location","no-location","location-trusted","no-location-trusted","max-redirs","compressed","insecure","http2","http2-prior-knowledge","form","form-string"]),supportedArgs$17=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-time"]),supportedArgs$16=new Set([...COMMON_SUPPORTED_ARGS,"upload-file","form","form-string","next","compressed","upload-file","retry","max-time"]),supportedArgs$15=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-time","connect-timeout","location","max-redirs","retry","insecure","cert","key","cacert","http2"]),supportedArgs$14=new Set([...COMMON_SUPPORTED_ARGS,"next"]),supportedArgs$13=new Set([...COMMON_SUPPORTED_ARGS,"max-time"]),reservedHeaders=["Content-Length","Authorization","Connection","Host","Proxy-Authenticate","Proxy-Authorization","WWW-Authenticate"].map((e=>e.toLowerCase())),supportedArgs$12=new Set([...COMMON_SUPPORTED_ARGS]),supportedArgs$11=new Set([...COMMON_SUPPORTED_ARGS,"max-time","insecure","no-insecure","upload-file","max-redirs","max-time","form","form-string"]),supportedArgs$10=new Set([...COMMON_SUPPORTED_ARGS,"max-time","insecure","no-insecure","compressed","no-compressed","digest","no-digest","location","no-location","form","form-string","proxy","proxy-user","unix-socket"]),supportedArgs$9=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","digest","no-digest","ntlm","no-ntlm","ntlm-wb","no-ntlm-wb","http3","http3-only","http2","http2-prior-knowledge","max-time","connect-timeout","insecure","no-insecure","cacert","capath","cert","key","compressed","no-compressed","location","no-location","proxy","noproxy"]),supportedArgs$8=new Set([...COMMON_SUPPORTED_ARGS]),supportedArgs$7=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","upload-file","output","location","location-trusted","max-redirs","proxy","insecure","max-time","keepalive","http2","http3"]),supportedArgs$6=new Set([...COMMON_SUPPORTED_ARGS,"max-time","insecure","no-insecure","upload-file"]),supportedArgs$5=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","insecure","no-insecure"]),supportedArgs$4=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","insecure","no-insecure","oauth2-bearer","max-redirs","max-time","connect-timeout","retry","retry-max-time"]),supportedArgs$3=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","http0.9","http1.0","http1.1","insecure","no-digest","no-http0.9","no-insecure","output","proxy","proxy-user","upload-file","next"]),supportedArgs$2=new Set([...COMMON_SUPPORTED_ARGS,"digest","no-digest","form","form-string","http0.9","http1.0","http1.1","insecure","output","upload-file","next"]),supportedArgs$1=new Set([...COMMON_SUPPORTED_ARGS,"form","form-string","max-redirs","location","no-location"]),INDENTATION=" ".repeat(4),supportedArgs=new Set([...COMMON_SUPPORTED_ARGS,"max-time"]),SUPPORTED_CONTENT_TYPES=["application/json","application/x-www-form-urlencoded","multipart/form-data"],CONTENT_TYPE_KEY="content-type",getContentTypeHeader=e=>(0,import_get.default)(e,CONTENT_TYPE_KEY)??void 0,isContentType=(e,t)=>getContentTypeHeader(e)===t,isJsonRequest=e=>{if(isContentType(e.headers,"application/json"))return!0;if(e.data&&!getContentTypeHeader(e.headers)){const t=Object.keys(e.data)[0];try{return JSON.parse(t),!0}catch{return!1}}return!1},isFormUrlEncodedRequest=e=>!!isContentType(e.headers,"application/x-www-form-urlencoded")||!(getContentTypeHeader(e.headers)||!e.data||e.files),isMultipartRequest=e=>!!isContentType(e.headers,"multipart/form-data")||!!e.files,isBinaryRequest=e=>{if(e?.headers?.[CONTENT_TYPE_KEY]){const t=e?.headers?.[CONTENT_TYPE_KEY];return["image","video","audio"].some((e=>t.includes(e)))}return!1},toKeyValueArray=([e,t])=>({name:e,value:t?.toString()??""}),extractHeaders=(e={})=>{const t=!Object.keys(e).length,r=1===Object.keys(e).length&&void 0!==e[CONTENT_TYPE_KEY];return t||r?{sendHeaders:!1}:{sendHeaders:!0,headerParameters:{parameters:Object.entries(e).map(toKeyValueArray).filter((e=>e.name!==CONTENT_TYPE_KEY))}}},extractQueries=(e={})=>Object.keys(e).length?{sendQuery:!0,queryParameters:{parameters:Object.entries(e).map(toKeyValueArray)}}:{sendQuery:!1},keyValueBodyToNodeParameters=(e={})=>Object.entries(e).map(toKeyValueArray),jsonBodyToNodeParameters=(e={})=>"string"==typeof e?[...new URLSearchParams(e).entries()].map((e=>toKeyValueArray(e))):keyValueBodyToNodeParameters(e),multipartToNodeParameters=(e={},t={})=>[...Object.entries(e).map(toKeyValueArray).map((e=>({parameterType:"formData",...e}))),...Object.entries(t).map(toKeyValueArray).map((e=>({parameterType:"formBinaryData",...e})))],lowerCaseContentTypeKey=e=>{if(!e)return;const t=new RegExp(CONTENT_TYPE_KEY,"gi"),r=Object.keys(e).find((e=>!!Array.from(e.matchAll(t)).length));if(!r)return;const s=e[r];delete e[r],e[CONTENT_TYPE_KEY]=s},encodeBasicAuthentication=(e,t)=>btoa(`${e}:${t}`),jsonHasNestedObjects=e=>Object.values(e).some((e=>"object"==typeof e)),mapCookies=e=>{if(!e)return{};const t=Object.entries(e).reduce(((e,t)=>e+=`${t[0]}=${t[1]};`),"");return t?{cookie:t}:{}},flattenObject=(e,t="")=>Object.keys(e).reduce(((r,s)=>{const n=t.length?t+".":"";return"object"==typeof e[s]?Object.assign(r,flattenObject(e[s],n+s)):r[n+s]=e[s],r}),{}),toHttpNodeParameters=e=>{const t=toJsonObject(sanitizeCurlUrlPlaceholders(e)),r=t.headers??{};if(lowerCaseContentTypeKey(r),t.auth){const{user:e,password:s}=t.auth;r.authorization=`Basic ${encodeBasicAuthentication(e,s)}`}const s=new URL(t.url),n=t.queries??{};for(const[i,l]of s.searchParams)n[i]=l;s.search="";const o={url:"/"===s.pathname?s.href.slice(0,-1):s.href,authentication:"none",method:t.method.toUpperCase(),...extractHeaders({...r,...mapCookies(t.cookies)}),...extractQueries(n),options:{redirect:{redirect:{}},response:{response:{}}}};t.follow_redirects&&(o.options.redirect.redirect.followRedirects=!0,t.max_redirects&&(o.options.redirect.redirect.maxRedirects=t.max_redirects)),t.proxy&&(o.options.proxy=t.proxy),void 0!==t.connect_timeout&&(o.options.timeout=Math.floor(1e3*t.connect_timeout)),t.output&&(o.options.response.response={responseFormat:"file",outputPropertyName:t.output??"data"}),void 0!==t.insecure&&(o.options.allowUnauthorizedCerts=!0),t.include&&(o.options.response.response.fullResponse=!0,o.options.response.response.responseFormat="autodetect");const a=t?.headers?.[CONTENT_TYPE_KEY];if(isBinaryRequest(t))return Object.assign(o,{contentType:"binaryData",sendBody:!0});if(a&&!SUPPORTED_CONTENT_TYPES.includes(a)){const e=t?.data;return Object.assign(o,{sendBody:!0,contentType:"raw",rawContentType:a,body:e?"string"==typeof e?e:JSON.stringify(e):void 0})}if(isJsonRequest(t)){if(Object.assign(o,{contentType:"json",sendBody:!0}),t.data){const e=t.data;jsonHasNestedObjects(e)?Object.assign(o,{specifyBody:"json",jsonBody:JSON.stringify(e,null,2)}):Object.assign(o,{specifyBody:"keypair",bodyParameters:{parameters:jsonBodyToNodeParameters(t.data)}})}}else isFormUrlEncodedRequest(t)?Object.assign(o,{contentType:"form-urlencoded",sendBody:!0,specifyBody:"keypair",bodyParameters:{parameters:jsonBodyToNodeParameters(t.data)}}):isMultipartRequest(t)?Object.assign(o,{contentType:"multipart-form-data",sendBody:!0,bodyParameters:{parameters:multipartToNodeParameters(t.data,t.files)}}):Object.assign(o,{sendBody:!1});return Object.keys(o.options?.redirect.redirect).length||delete o.options.redirect,Object.keys(o.options.response.response).length||delete o.options.response,o}}}}))}();
//# sourceMappingURL=useImportCurlCommand-legacy-D2iYTNRU.js.map