builder.io 1.9.19 → 1.9.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/cli/index.cjs CHANGED
@@ -1,8 +1,8 @@
1
- var pj=Object.create;var sd=Object.defineProperty;var dj=Object.getOwnPropertyDescriptor;var fj=Object.getOwnPropertyNames;var mj=Object.getPrototypeOf,hj=Object.prototype.hasOwnProperty;var gj=(e,t)=>()=>(e&&(t=e(e=0)),t);var w=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),pS=(e,t)=>{for(var r in t)sd(e,r,{get:t[r],enumerable:!0})},dS=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of fj(t))!hj.call(e,i)&&i!==r&&sd(e,i,{get:()=>t[i],enumerable:!(n=dj(t,i))||n.enumerable});return e};var q=(e,t,r)=>(r=e!=null?pj(mj(e)):{},dS(t||!e||!e.__esModule?sd(r,"default",{value:e,enumerable:!0}):r,e)),yj=e=>dS(sd({},"__esModule",{value:!0}),e);var f=gj(()=>{{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};e.SENTRY_RELEASE={id:"5b46f896c967c5510863614d64aff9d1936c2c57"}}});var mS=w((wxe,fS)=>{f();function Lg(e){return e==null?[]:Array.isArray(e)?e:[e]}function bj(e,t,r,n){var i,s=e[t],o=~n.string.indexOf(t)?r==null||r===!0?"":String(r):typeof r=="boolean"?r:~n.boolean.indexOf(t)?r==="false"?!1:r==="true"||(e._.push((i=+r,i*0===0?i:r)),!!r):(i=+r,i*0===0?i:r);e[t]=s==null?o:Array.isArray(s)?s.concat(o):[s,o]}fS.exports=function(e,t){e=e||[],t=t||{};var r,n,i,s,o,a={_:[]},c=0,u=0,l=0,p=e.length;let d=t.alias!==void 0,h=t.unknown!==void 0,m=t.default!==void 0;if(t.alias=t.alias||{},t.string=Lg(t.string),t.boolean=Lg(t.boolean),d)for(r in t.alias)for(n=t.alias[r]=Lg(t.alias[r]),c=0;c<n.length;c++)(t.alias[n[c]]=n.concat(r)).splice(c,1);for(c=t.boolean.length;c-- >0;)for(n=t.alias[t.boolean[c]]||[],u=n.length;u-- >0;)t.boolean.push(n[u]);for(c=t.string.length;c-- >0;)for(n=t.alias[t.string[c]]||[],u=n.length;u-- >0;)t.string.push(n[u]);if(m){for(r in t.default)if(s=typeof t.default[r],n=t.alias[r]=t.alias[r]||[],t[s]!==void 0)for(t[s].push(r),c=0;c<n.length;c++)t[s].push(n[c])}let g=h?Object.keys(t.alias):[];for(c=0;c<p;c++){if(i=e[c],i==="--"){a._=a._.concat(e.slice(++c));break}for(u=0;u<i.length&&i.charCodeAt(u)===45;u++);if(u===0)a._.push(i);else if(i.substring(u,u+3)==="no-"){if(s=i.substring(u+3),h&&!~g.indexOf(s))return t.unknown(i);a[s]=!1}else{for(l=u+1;l<i.length&&i.charCodeAt(l)!==61;l++);for(s=i.substring(u,l),o=i.substring(++l)||c+1===p||(""+e[c+1]).charCodeAt(0)===45||e[++c],n=u===2?[s]:s,l=0;l<n.length;l++){if(s=n[l],h&&!~g.indexOf(s))return t.unknown("-".repeat(u)+s);bj(a,s,l+1<n.length||o,t)}}}if(m)for(r in t.default)a[r]===void 0&&(a[r]=t.default[r]);if(d)for(r in a)for(n=t.alias[r]||[];n.length>0;)a[n.shift()]=a[r];return a}});var cd=w((_xe,xS)=>{"use strict";f();var Gg="\x1B",Tt=`${Gg}[`,vj="\x07",zg={to(e,t){return t?`${Tt}${t+1};${e+1}H`:`${Tt}${e+1}G`},move(e,t){let r="";return e<0?r+=`${Tt}${-e}D`:e>0&&(r+=`${Tt}${e}C`),t<0?r+=`${Tt}${-t}A`:t>0&&(r+=`${Tt}${t}B`),r},up:(e=1)=>`${Tt}${e}A`,down:(e=1)=>`${Tt}${e}B`,forward:(e=1)=>`${Tt}${e}C`,backward:(e=1)=>`${Tt}${e}D`,nextLine:(e=1)=>`${Tt}E`.repeat(e),prevLine:(e=1)=>`${Tt}F`.repeat(e),left:`${Tt}G`,hide:`${Tt}?25l`,show:`${Tt}?25h`,save:`${Gg}7`,restore:`${Gg}8`},Dj={up:(e=1)=>`${Tt}S`.repeat(e),down:(e=1)=>`${Tt}T`.repeat(e)},Cj={screen:`${Tt}2J`,up:(e=1)=>`${Tt}1J`.repeat(e),down:(e=1)=>`${Tt}J`.repeat(e),line:`${Tt}2K`,lineEnd:`${Tt}K`,lineStart:`${Tt}1K`,lines(e){let t="";for(let r=0;r<e;r++)t+=this.line+(r<e-1?zg.up():"");return e&&(t+=zg.left),t}};xS.exports={cursor:zg,scroll:Dj,erase:Cj,beep:vj}});var vt=w((kxe,Hg)=>{f();var ld=process||{},vS=ld.argv||[],ud=ld.env||{},Ej=!(ud.NO_COLOR||vS.includes("--no-color"))&&(!!ud.FORCE_COLOR||vS.includes("--color")||ld.platform==="win32"||(ld.stdout||{}).isTTY&&ud.TERM!=="dumb"||!!ud.CI),wj=(e,t,r=e)=>n=>{let i=""+n,s=i.indexOf(t,e.length);return~s?e+Sj(i,t,r,s)+t:e+i+t},Sj=(e,t,r,n)=>{let i="",s=0;do i+=e.substring(s,n)+r,s=n+t.length,n=e.indexOf(t,s);while(~n);return i+e.substring(s)},DS=(e=Ej)=>{let t=e?wj:()=>String;return{isColorSupported:e,reset:t("\x1B[0m","\x1B[0m"),bold:t("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:t("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:t("\x1B[3m","\x1B[23m"),underline:t("\x1B[4m","\x1B[24m"),inverse:t("\x1B[7m","\x1B[27m"),hidden:t("\x1B[8m","\x1B[28m"),strikethrough:t("\x1B[9m","\x1B[29m"),black:t("\x1B[30m","\x1B[39m"),red:t("\x1B[31m","\x1B[39m"),green:t("\x1B[32m","\x1B[39m"),yellow:t("\x1B[33m","\x1B[39m"),blue:t("\x1B[34m","\x1B[39m"),magenta:t("\x1B[35m","\x1B[39m"),cyan:t("\x1B[36m","\x1B[39m"),white:t("\x1B[37m","\x1B[39m"),gray:t("\x1B[90m","\x1B[39m"),bgBlack:t("\x1B[40m","\x1B[49m"),bgRed:t("\x1B[41m","\x1B[49m"),bgGreen:t("\x1B[42m","\x1B[49m"),bgYellow:t("\x1B[43m","\x1B[49m"),bgBlue:t("\x1B[44m","\x1B[49m"),bgMagenta:t("\x1B[45m","\x1B[49m"),bgCyan:t("\x1B[46m","\x1B[49m"),bgWhite:t("\x1B[47m","\x1B[49m"),blackBright:t("\x1B[90m","\x1B[39m"),redBright:t("\x1B[91m","\x1B[39m"),greenBright:t("\x1B[92m","\x1B[39m"),yellowBright:t("\x1B[93m","\x1B[39m"),blueBright:t("\x1B[94m","\x1B[39m"),magentaBright:t("\x1B[95m","\x1B[39m"),cyanBright:t("\x1B[96m","\x1B[39m"),whiteBright:t("\x1B[97m","\x1B[39m"),bgBlackBright:t("\x1B[100m","\x1B[49m"),bgRedBright:t("\x1B[101m","\x1B[49m"),bgGreenBright:t("\x1B[102m","\x1B[49m"),bgYellowBright:t("\x1B[103m","\x1B[49m"),bgBlueBright:t("\x1B[104m","\x1B[49m"),bgMagentaBright:t("\x1B[105m","\x1B[49m"),bgCyanBright:t("\x1B[106m","\x1B[49m"),bgWhiteBright:t("\x1B[107m","\x1B[49m")}};Hg.exports=DS();Hg.exports.createColors=DS});var YS=w((Qxe,WS)=>{"use strict";f();WS.exports=function(){if(process.env.npm_config_user_agent)return rq(process.env.npm_config_user_agent)};function rq(e){let t=e.split(" ")[0],r=t.lastIndexOf("/"),n=t.substring(0,r);return{name:n==="npminstall"?"cnpm":n,version:t.substring(r+1)}}});var CT=w((Owe,kd)=>{f();kd.exports.Space_Separator=/[\u1680\u2000-\u200A\u202F\u205F\u3000]/;kd.exports.ID_Start=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/;kd.exports.ID_Continue=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/});var Ty=w((Mwe,ET)=>{f();var Sy=CT();ET.exports={isSpaceSeparator(e){return typeof e=="string"&&Sy.Space_Separator.test(e)},isIdStartChar(e){return typeof e=="string"&&(e>="a"&&e<="z"||e>="A"&&e<="Z"||e==="$"||e==="_"||Sy.ID_Start.test(e))},isIdContinueChar(e){return typeof e=="string"&&(e>="a"&&e<="z"||e>="A"&&e<="Z"||e>="0"&&e<="9"||e==="$"||e==="_"||e==="\u200C"||e==="\u200D"||Sy.ID_Continue.test(e))},isDigit(e){return typeof e=="string"&&/[0-9]/.test(e)},isHexDigit(e){return typeof e=="string"&&/[0-9A-Fa-f]/.test(e)}}});var PT=w(($we,AT)=>{f();var zt=Ty(),Py,wr,zi,Rd,Ps,zn,Ht,Iy,Bu;AT.exports=function(t,r){Py=String(t),wr="start",zi=[],Rd=0,Ps=1,zn=0,Ht=void 0,Iy=void 0,Bu=void 0;do Ht=Cz(),Sz[wr]();while(Ht.type!=="eof");return typeof r=="function"?Fy({"":Bu},"",r):Bu};function Fy(e,t,r){let n=e[t];if(n!=null&&typeof n=="object")if(Array.isArray(n))for(let i=0;i<n.length;i++){let s=String(i),o=Fy(n,s,r);o===void 0?delete n[s]:Object.defineProperty(n,s,{value:o,writable:!0,enumerable:!0,configurable:!0})}else for(let i in n){let s=Fy(n,i,r);s===void 0?delete n[i]:Object.defineProperty(n,i,{value:s,writable:!0,enumerable:!0,configurable:!0})}return r.call(e,t,n)}var Ce,be,Ou,Gi,Pe;function Cz(){for(Ce="default",be="",Ou=!1,Gi=1;;){Pe=Hi();let e=ST[Ce]();if(e)return e}}function Hi(){if(Py[Rd])return String.fromCodePoint(Py.codePointAt(Rd))}function H(){let e=Hi();return e===`
1
+ var pj=Object.create;var sd=Object.defineProperty;var dj=Object.getOwnPropertyDescriptor;var fj=Object.getOwnPropertyNames;var mj=Object.getPrototypeOf,hj=Object.prototype.hasOwnProperty;var gj=(e,t)=>()=>(e&&(t=e(e=0)),t);var w=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),pS=(e,t)=>{for(var r in t)sd(e,r,{get:t[r],enumerable:!0})},dS=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of fj(t))!hj.call(e,i)&&i!==r&&sd(e,i,{get:()=>t[i],enumerable:!(n=dj(t,i))||n.enumerable});return e};var q=(e,t,r)=>(r=e!=null?pj(mj(e)):{},dS(t||!e||!e.__esModule?sd(r,"default",{value:e,enumerable:!0}):r,e)),yj=e=>dS(sd({},"__esModule",{value:!0}),e);var f=gj(()=>{{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};e.SENTRY_RELEASE={id:"500304d43612e14710152d1368379e51840f9242"}}});var mS=w((wxe,fS)=>{f();function Lg(e){return e==null?[]:Array.isArray(e)?e:[e]}function bj(e,t,r,n){var i,s=e[t],o=~n.string.indexOf(t)?r==null||r===!0?"":String(r):typeof r=="boolean"?r:~n.boolean.indexOf(t)?r==="false"?!1:r==="true"||(e._.push((i=+r,i*0===0?i:r)),!!r):(i=+r,i*0===0?i:r);e[t]=s==null?o:Array.isArray(s)?s.concat(o):[s,o]}fS.exports=function(e,t){e=e||[],t=t||{};var r,n,i,s,o,a={_:[]},c=0,u=0,l=0,p=e.length;let d=t.alias!==void 0,h=t.unknown!==void 0,m=t.default!==void 0;if(t.alias=t.alias||{},t.string=Lg(t.string),t.boolean=Lg(t.boolean),d)for(r in t.alias)for(n=t.alias[r]=Lg(t.alias[r]),c=0;c<n.length;c++)(t.alias[n[c]]=n.concat(r)).splice(c,1);for(c=t.boolean.length;c-- >0;)for(n=t.alias[t.boolean[c]]||[],u=n.length;u-- >0;)t.boolean.push(n[u]);for(c=t.string.length;c-- >0;)for(n=t.alias[t.string[c]]||[],u=n.length;u-- >0;)t.string.push(n[u]);if(m){for(r in t.default)if(s=typeof t.default[r],n=t.alias[r]=t.alias[r]||[],t[s]!==void 0)for(t[s].push(r),c=0;c<n.length;c++)t[s].push(n[c])}let g=h?Object.keys(t.alias):[];for(c=0;c<p;c++){if(i=e[c],i==="--"){a._=a._.concat(e.slice(++c));break}for(u=0;u<i.length&&i.charCodeAt(u)===45;u++);if(u===0)a._.push(i);else if(i.substring(u,u+3)==="no-"){if(s=i.substring(u+3),h&&!~g.indexOf(s))return t.unknown(i);a[s]=!1}else{for(l=u+1;l<i.length&&i.charCodeAt(l)!==61;l++);for(s=i.substring(u,l),o=i.substring(++l)||c+1===p||(""+e[c+1]).charCodeAt(0)===45||e[++c],n=u===2?[s]:s,l=0;l<n.length;l++){if(s=n[l],h&&!~g.indexOf(s))return t.unknown("-".repeat(u)+s);bj(a,s,l+1<n.length||o,t)}}}if(m)for(r in t.default)a[r]===void 0&&(a[r]=t.default[r]);if(d)for(r in a)for(n=t.alias[r]||[];n.length>0;)a[n.shift()]=a[r];return a}});var cd=w((_xe,xS)=>{"use strict";f();var Gg="\x1B",Tt=`${Gg}[`,vj="\x07",zg={to(e,t){return t?`${Tt}${t+1};${e+1}H`:`${Tt}${e+1}G`},move(e,t){let r="";return e<0?r+=`${Tt}${-e}D`:e>0&&(r+=`${Tt}${e}C`),t<0?r+=`${Tt}${-t}A`:t>0&&(r+=`${Tt}${t}B`),r},up:(e=1)=>`${Tt}${e}A`,down:(e=1)=>`${Tt}${e}B`,forward:(e=1)=>`${Tt}${e}C`,backward:(e=1)=>`${Tt}${e}D`,nextLine:(e=1)=>`${Tt}E`.repeat(e),prevLine:(e=1)=>`${Tt}F`.repeat(e),left:`${Tt}G`,hide:`${Tt}?25l`,show:`${Tt}?25h`,save:`${Gg}7`,restore:`${Gg}8`},Dj={up:(e=1)=>`${Tt}S`.repeat(e),down:(e=1)=>`${Tt}T`.repeat(e)},Cj={screen:`${Tt}2J`,up:(e=1)=>`${Tt}1J`.repeat(e),down:(e=1)=>`${Tt}J`.repeat(e),line:`${Tt}2K`,lineEnd:`${Tt}K`,lineStart:`${Tt}1K`,lines(e){let t="";for(let r=0;r<e;r++)t+=this.line+(r<e-1?zg.up():"");return e&&(t+=zg.left),t}};xS.exports={cursor:zg,scroll:Dj,erase:Cj,beep:vj}});var vt=w((kxe,Hg)=>{f();var ld=process||{},vS=ld.argv||[],ud=ld.env||{},Ej=!(ud.NO_COLOR||vS.includes("--no-color"))&&(!!ud.FORCE_COLOR||vS.includes("--color")||ld.platform==="win32"||(ld.stdout||{}).isTTY&&ud.TERM!=="dumb"||!!ud.CI),wj=(e,t,r=e)=>n=>{let i=""+n,s=i.indexOf(t,e.length);return~s?e+Sj(i,t,r,s)+t:e+i+t},Sj=(e,t,r,n)=>{let i="",s=0;do i+=e.substring(s,n)+r,s=n+t.length,n=e.indexOf(t,s);while(~n);return i+e.substring(s)},DS=(e=Ej)=>{let t=e?wj:()=>String;return{isColorSupported:e,reset:t("\x1B[0m","\x1B[0m"),bold:t("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:t("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:t("\x1B[3m","\x1B[23m"),underline:t("\x1B[4m","\x1B[24m"),inverse:t("\x1B[7m","\x1B[27m"),hidden:t("\x1B[8m","\x1B[28m"),strikethrough:t("\x1B[9m","\x1B[29m"),black:t("\x1B[30m","\x1B[39m"),red:t("\x1B[31m","\x1B[39m"),green:t("\x1B[32m","\x1B[39m"),yellow:t("\x1B[33m","\x1B[39m"),blue:t("\x1B[34m","\x1B[39m"),magenta:t("\x1B[35m","\x1B[39m"),cyan:t("\x1B[36m","\x1B[39m"),white:t("\x1B[37m","\x1B[39m"),gray:t("\x1B[90m","\x1B[39m"),bgBlack:t("\x1B[40m","\x1B[49m"),bgRed:t("\x1B[41m","\x1B[49m"),bgGreen:t("\x1B[42m","\x1B[49m"),bgYellow:t("\x1B[43m","\x1B[49m"),bgBlue:t("\x1B[44m","\x1B[49m"),bgMagenta:t("\x1B[45m","\x1B[49m"),bgCyan:t("\x1B[46m","\x1B[49m"),bgWhite:t("\x1B[47m","\x1B[49m"),blackBright:t("\x1B[90m","\x1B[39m"),redBright:t("\x1B[91m","\x1B[39m"),greenBright:t("\x1B[92m","\x1B[39m"),yellowBright:t("\x1B[93m","\x1B[39m"),blueBright:t("\x1B[94m","\x1B[39m"),magentaBright:t("\x1B[95m","\x1B[39m"),cyanBright:t("\x1B[96m","\x1B[39m"),whiteBright:t("\x1B[97m","\x1B[39m"),bgBlackBright:t("\x1B[100m","\x1B[49m"),bgRedBright:t("\x1B[101m","\x1B[49m"),bgGreenBright:t("\x1B[102m","\x1B[49m"),bgYellowBright:t("\x1B[103m","\x1B[49m"),bgBlueBright:t("\x1B[104m","\x1B[49m"),bgMagentaBright:t("\x1B[105m","\x1B[49m"),bgCyanBright:t("\x1B[106m","\x1B[49m"),bgWhiteBright:t("\x1B[107m","\x1B[49m")}};Hg.exports=DS();Hg.exports.createColors=DS});var YS=w((Qxe,WS)=>{"use strict";f();WS.exports=function(){if(process.env.npm_config_user_agent)return rq(process.env.npm_config_user_agent)};function rq(e){let t=e.split(" ")[0],r=t.lastIndexOf("/"),n=t.substring(0,r);return{name:n==="npminstall"?"cnpm":n,version:t.substring(r+1)}}});var CT=w((Owe,kd)=>{f();kd.exports.Space_Separator=/[\u1680\u2000-\u200A\u202F\u205F\u3000]/;kd.exports.ID_Start=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/;kd.exports.ID_Continue=/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/});var Ty=w((Mwe,ET)=>{f();var Sy=CT();ET.exports={isSpaceSeparator(e){return typeof e=="string"&&Sy.Space_Separator.test(e)},isIdStartChar(e){return typeof e=="string"&&(e>="a"&&e<="z"||e>="A"&&e<="Z"||e==="$"||e==="_"||Sy.ID_Start.test(e))},isIdContinueChar(e){return typeof e=="string"&&(e>="a"&&e<="z"||e>="A"&&e<="Z"||e>="0"&&e<="9"||e==="$"||e==="_"||e==="\u200C"||e==="\u200D"||Sy.ID_Continue.test(e))},isDigit(e){return typeof e=="string"&&/[0-9]/.test(e)},isHexDigit(e){return typeof e=="string"&&/[0-9A-Fa-f]/.test(e)}}});var PT=w(($we,AT)=>{f();var zt=Ty(),Py,wr,zi,Rd,Ps,zn,Ht,Iy,Bu;AT.exports=function(t,r){Py=String(t),wr="start",zi=[],Rd=0,Ps=1,zn=0,Ht=void 0,Iy=void 0,Bu=void 0;do Ht=Cz(),Sz[wr]();while(Ht.type!=="eof");return typeof r=="function"?Fy({"":Bu},"",r):Bu};function Fy(e,t,r){let n=e[t];if(n!=null&&typeof n=="object")if(Array.isArray(n))for(let i=0;i<n.length;i++){let s=String(i),o=Fy(n,s,r);o===void 0?delete n[s]:Object.defineProperty(n,s,{value:o,writable:!0,enumerable:!0,configurable:!0})}else for(let i in n){let s=Fy(n,i,r);s===void 0?delete n[i]:Object.defineProperty(n,i,{value:s,writable:!0,enumerable:!0,configurable:!0})}return r.call(e,t,n)}var Ee,be,Ou,Gi,Pe;function Cz(){for(Ee="default",be="",Ou=!1,Gi=1;;){Pe=Hi();let e=ST[Ee]();if(e)return e}}function Hi(){if(Py[Rd])return String.fromCodePoint(Py.codePointAt(Rd))}function H(){let e=Hi();return e===`
2
2
  `?(Ps++,zn=0):e?zn+=e.length:zn++,e&&(Rd+=e.length),e}var ST={default(){switch(Pe){case" ":case"\v":case"\f":case" ":case"\xA0":case"\uFEFF":case`
3
- `:case"\r":case"\u2028":case"\u2029":H();return;case"/":H(),Ce="comment";return;case void 0:return H(),ft("eof")}if(zt.isSpaceSeparator(Pe)){H();return}return ST[wr]()},comment(){switch(Pe){case"*":H(),Ce="multiLineComment";return;case"/":H(),Ce="singleLineComment";return}throw mt(H())},multiLineComment(){switch(Pe){case"*":H(),Ce="multiLineCommentAsterisk";return;case void 0:throw mt(H())}H()},multiLineCommentAsterisk(){switch(Pe){case"*":H();return;case"/":H(),Ce="default";return;case void 0:throw mt(H())}H(),Ce="multiLineComment"},singleLineComment(){switch(Pe){case`
4
- `:case"\r":case"\u2028":case"\u2029":H(),Ce="default";return;case void 0:return H(),ft("eof")}H()},value(){switch(Pe){case"{":case"[":return ft("punctuator",H());case"n":return H(),Co("ull"),ft("null",null);case"t":return H(),Co("rue"),ft("boolean",!0);case"f":return H(),Co("alse"),ft("boolean",!1);case"-":case"+":H()==="-"&&(Gi=-1),Ce="sign";return;case".":be=H(),Ce="decimalPointLeading";return;case"0":be=H(),Ce="zero";return;case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":be=H(),Ce="decimalInteger";return;case"I":return H(),Co("nfinity"),ft("numeric",1/0);case"N":return H(),Co("aN"),ft("numeric",NaN);case'"':case"'":Ou=H()==='"',be="",Ce="string";return}throw mt(H())},identifierNameStartEscape(){if(Pe!=="u")throw mt(H());H();let e=_y();switch(e){case"$":case"_":break;default:if(!zt.isIdStartChar(e))throw wT();break}be+=e,Ce="identifierName"},identifierName(){switch(Pe){case"$":case"_":case"\u200C":case"\u200D":be+=H();return;case"\\":H(),Ce="identifierNameEscape";return}if(zt.isIdContinueChar(Pe)){be+=H();return}return ft("identifier",be)},identifierNameEscape(){if(Pe!=="u")throw mt(H());H();let e=_y();switch(e){case"$":case"_":case"\u200C":case"\u200D":break;default:if(!zt.isIdContinueChar(e))throw wT();break}be+=e,Ce="identifierName"},sign(){switch(Pe){case".":be=H(),Ce="decimalPointLeading";return;case"0":be=H(),Ce="zero";return;case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":be=H(),Ce="decimalInteger";return;case"I":return H(),Co("nfinity"),ft("numeric",Gi*(1/0));case"N":return H(),Co("aN"),ft("numeric",NaN)}throw mt(H())},zero(){switch(Pe){case".":be+=H(),Ce="decimalPoint";return;case"e":case"E":be+=H(),Ce="decimalExponent";return;case"x":case"X":be+=H(),Ce="hexadecimal";return}return ft("numeric",Gi*0)},decimalInteger(){switch(Pe){case".":be+=H(),Ce="decimalPoint";return;case"e":case"E":be+=H(),Ce="decimalExponent";return}if(zt.isDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},decimalPointLeading(){if(zt.isDigit(Pe)){be+=H(),Ce="decimalFraction";return}throw mt(H())},decimalPoint(){switch(Pe){case"e":case"E":be+=H(),Ce="decimalExponent";return}if(zt.isDigit(Pe)){be+=H(),Ce="decimalFraction";return}return ft("numeric",Gi*Number(be))},decimalFraction(){switch(Pe){case"e":case"E":be+=H(),Ce="decimalExponent";return}if(zt.isDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},decimalExponent(){switch(Pe){case"+":case"-":be+=H(),Ce="decimalExponentSign";return}if(zt.isDigit(Pe)){be+=H(),Ce="decimalExponentInteger";return}throw mt(H())},decimalExponentSign(){if(zt.isDigit(Pe)){be+=H(),Ce="decimalExponentInteger";return}throw mt(H())},decimalExponentInteger(){if(zt.isDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},hexadecimal(){if(zt.isHexDigit(Pe)){be+=H(),Ce="hexadecimalInteger";return}throw mt(H())},hexadecimalInteger(){if(zt.isHexDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},string(){switch(Pe){case"\\":H(),be+=Ez();return;case'"':if(Ou)return H(),ft("string",be);be+=H();return;case"'":if(!Ou)return H(),ft("string",be);be+=H();return;case`
5
- `:case"\r":throw mt(H());case"\u2028":case"\u2029":Tz(Pe);break;case void 0:throw mt(H())}be+=H()},start(){switch(Pe){case"{":case"[":return ft("punctuator",H())}Ce="value"},beforePropertyName(){switch(Pe){case"$":case"_":be=H(),Ce="identifierName";return;case"\\":H(),Ce="identifierNameStartEscape";return;case"}":return ft("punctuator",H());case'"':case"'":Ou=H()==='"',Ce="string";return}if(zt.isIdStartChar(Pe)){be+=H(),Ce="identifierName";return}throw mt(H())},afterPropertyName(){if(Pe===":")return ft("punctuator",H());throw mt(H())},beforePropertyValue(){Ce="value"},afterPropertyValue(){switch(Pe){case",":case"}":return ft("punctuator",H())}throw mt(H())},beforeArrayValue(){if(Pe==="]")return ft("punctuator",H());Ce="value"},afterArrayValue(){switch(Pe){case",":case"]":return ft("punctuator",H())}throw mt(H())},end(){throw mt(H())}};function ft(e,t){return{type:e,value:t,line:Ps,column:zn}}function Co(e){for(let t of e){if(Hi()!==t)throw mt(H());H()}}function Ez(){switch(Hi()){case"b":return H(),"\b";case"f":return H(),"\f";case"n":return H(),`
3
+ `:case"\r":case"\u2028":case"\u2029":H();return;case"/":H(),Ee="comment";return;case void 0:return H(),ft("eof")}if(zt.isSpaceSeparator(Pe)){H();return}return ST[wr]()},comment(){switch(Pe){case"*":H(),Ee="multiLineComment";return;case"/":H(),Ee="singleLineComment";return}throw mt(H())},multiLineComment(){switch(Pe){case"*":H(),Ee="multiLineCommentAsterisk";return;case void 0:throw mt(H())}H()},multiLineCommentAsterisk(){switch(Pe){case"*":H();return;case"/":H(),Ee="default";return;case void 0:throw mt(H())}H(),Ee="multiLineComment"},singleLineComment(){switch(Pe){case`
4
+ `:case"\r":case"\u2028":case"\u2029":H(),Ee="default";return;case void 0:return H(),ft("eof")}H()},value(){switch(Pe){case"{":case"[":return ft("punctuator",H());case"n":return H(),Co("ull"),ft("null",null);case"t":return H(),Co("rue"),ft("boolean",!0);case"f":return H(),Co("alse"),ft("boolean",!1);case"-":case"+":H()==="-"&&(Gi=-1),Ee="sign";return;case".":be=H(),Ee="decimalPointLeading";return;case"0":be=H(),Ee="zero";return;case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":be=H(),Ee="decimalInteger";return;case"I":return H(),Co("nfinity"),ft("numeric",1/0);case"N":return H(),Co("aN"),ft("numeric",NaN);case'"':case"'":Ou=H()==='"',be="",Ee="string";return}throw mt(H())},identifierNameStartEscape(){if(Pe!=="u")throw mt(H());H();let e=_y();switch(e){case"$":case"_":break;default:if(!zt.isIdStartChar(e))throw wT();break}be+=e,Ee="identifierName"},identifierName(){switch(Pe){case"$":case"_":case"\u200C":case"\u200D":be+=H();return;case"\\":H(),Ee="identifierNameEscape";return}if(zt.isIdContinueChar(Pe)){be+=H();return}return ft("identifier",be)},identifierNameEscape(){if(Pe!=="u")throw mt(H());H();let e=_y();switch(e){case"$":case"_":case"\u200C":case"\u200D":break;default:if(!zt.isIdContinueChar(e))throw wT();break}be+=e,Ee="identifierName"},sign(){switch(Pe){case".":be=H(),Ee="decimalPointLeading";return;case"0":be=H(),Ee="zero";return;case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":be=H(),Ee="decimalInteger";return;case"I":return H(),Co("nfinity"),ft("numeric",Gi*(1/0));case"N":return H(),Co("aN"),ft("numeric",NaN)}throw mt(H())},zero(){switch(Pe){case".":be+=H(),Ee="decimalPoint";return;case"e":case"E":be+=H(),Ee="decimalExponent";return;case"x":case"X":be+=H(),Ee="hexadecimal";return}return ft("numeric",Gi*0)},decimalInteger(){switch(Pe){case".":be+=H(),Ee="decimalPoint";return;case"e":case"E":be+=H(),Ee="decimalExponent";return}if(zt.isDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},decimalPointLeading(){if(zt.isDigit(Pe)){be+=H(),Ee="decimalFraction";return}throw mt(H())},decimalPoint(){switch(Pe){case"e":case"E":be+=H(),Ee="decimalExponent";return}if(zt.isDigit(Pe)){be+=H(),Ee="decimalFraction";return}return ft("numeric",Gi*Number(be))},decimalFraction(){switch(Pe){case"e":case"E":be+=H(),Ee="decimalExponent";return}if(zt.isDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},decimalExponent(){switch(Pe){case"+":case"-":be+=H(),Ee="decimalExponentSign";return}if(zt.isDigit(Pe)){be+=H(),Ee="decimalExponentInteger";return}throw mt(H())},decimalExponentSign(){if(zt.isDigit(Pe)){be+=H(),Ee="decimalExponentInteger";return}throw mt(H())},decimalExponentInteger(){if(zt.isDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},hexadecimal(){if(zt.isHexDigit(Pe)){be+=H(),Ee="hexadecimalInteger";return}throw mt(H())},hexadecimalInteger(){if(zt.isHexDigit(Pe)){be+=H();return}return ft("numeric",Gi*Number(be))},string(){switch(Pe){case"\\":H(),be+=Ez();return;case'"':if(Ou)return H(),ft("string",be);be+=H();return;case"'":if(!Ou)return H(),ft("string",be);be+=H();return;case`
5
+ `:case"\r":throw mt(H());case"\u2028":case"\u2029":Tz(Pe);break;case void 0:throw mt(H())}be+=H()},start(){switch(Pe){case"{":case"[":return ft("punctuator",H())}Ee="value"},beforePropertyName(){switch(Pe){case"$":case"_":be=H(),Ee="identifierName";return;case"\\":H(),Ee="identifierNameStartEscape";return;case"}":return ft("punctuator",H());case'"':case"'":Ou=H()==='"',Ee="string";return}if(zt.isIdStartChar(Pe)){be+=H(),Ee="identifierName";return}throw mt(H())},afterPropertyName(){if(Pe===":")return ft("punctuator",H());throw mt(H())},beforePropertyValue(){Ee="value"},afterPropertyValue(){switch(Pe){case",":case"}":return ft("punctuator",H())}throw mt(H())},beforeArrayValue(){if(Pe==="]")return ft("punctuator",H());Ee="value"},afterArrayValue(){switch(Pe){case",":case"]":return ft("punctuator",H())}throw mt(H())},end(){throw mt(H())}};function ft(e,t){return{type:e,value:t,line:Ps,column:zn}}function Co(e){for(let t of e){if(Hi()!==t)throw mt(H());H()}}function Ez(){switch(Hi()){case"b":return H(),"\b";case"f":return H(),"\f";case"n":return H(),`
6
6
  `;case"r":return H(),"\r";case"t":return H()," ";case"v":return H(),"\v";case"0":if(H(),zt.isDigit(Hi()))throw mt(H());return"\0";case"x":return H(),wz();case"u":return H(),_y();case`
7
7
  `:case"\u2028":case"\u2029":return H(),"";case"\r":return H(),Hi()===`
8
8
  `&&H(),"";case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":throw mt(H());case void 0:throw mt(H())}return H()}function wz(){let e="",t=Hi();if(!zt.isHexDigit(t)||(e+=H(),t=Hi(),!zt.isHexDigit(t)))throw mt(H());return e+=H(),String.fromCodePoint(parseInt(e,16))}function _y(){let e="",t=4;for(;t-- >0;){let r=Hi();if(!zt.isHexDigit(r))throw mt(H());e+=H()}return String.fromCodePoint(parseInt(e,16))}var Sz={start(){if(Ht.type==="eof")throw Eo();Ay()},beforePropertyName(){switch(Ht.type){case"identifier":case"string":Iy=Ht.value,wr="afterPropertyName";return;case"punctuator":Nd();return;case"eof":throw Eo()}},afterPropertyName(){if(Ht.type==="eof")throw Eo();wr="beforePropertyValue"},beforePropertyValue(){if(Ht.type==="eof")throw Eo();Ay()},beforeArrayValue(){if(Ht.type==="eof")throw Eo();if(Ht.type==="punctuator"&&Ht.value==="]"){Nd();return}Ay()},afterPropertyValue(){if(Ht.type==="eof")throw Eo();switch(Ht.value){case",":wr="beforePropertyName";return;case"}":Nd()}},afterArrayValue(){if(Ht.type==="eof")throw Eo();switch(Ht.value){case",":wr="beforeArrayValue";return;case"]":Nd()}},end(){}};function Ay(){let e;switch(Ht.type){case"punctuator":switch(Ht.value){case"{":e={};break;case"[":e=[];break}break;case"null":case"boolean":case"numeric":case"string":e=Ht.value;break}if(Bu===void 0)Bu=e;else{let t=zi[zi.length-1];Array.isArray(t)?t.push(e):Object.defineProperty(t,Iy,{value:e,writable:!0,enumerable:!0,configurable:!0})}if(e!==null&&typeof e=="object")zi.push(e),Array.isArray(e)?wr="beforeArrayValue":wr="beforePropertyName";else{let t=zi[zi.length-1];t==null?wr="end":Array.isArray(t)?wr="afterArrayValue":wr="afterPropertyValue"}}function Nd(){zi.pop();let e=zi[zi.length-1];e==null?wr="end":Array.isArray(e)?wr="afterArrayValue":wr="afterPropertyValue"}function mt(e){return Od(e===void 0?`JSON5: invalid end of input at ${Ps}:${zn}`:`JSON5: invalid character '${TT(e)}' at ${Ps}:${zn}`)}function Eo(){return Od(`JSON5: invalid end of input at ${Ps}:${zn}`)}function wT(){return zn-=5,Od(`JSON5: invalid identifier character at ${Ps}:${zn}`)}function Tz(e){console.warn(`JSON5: '${TT(e)}' in strings is not valid ECMAScript; consider escaping`)}function TT(e){let t={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r"," ":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"};if(t[e])return t[e];if(e<" "){let r=e.charCodeAt(0).toString(16);return"\\x"+("00"+r).substring(r.length)}return e}function Od(e){let t=new SyntaxError(e);return t.lineNumber=Ps,t.columnNumber=zn,t}});var _T=w((jwe,FT)=>{f();var ky=Ty();FT.exports=function(t,r,n){let i=[],s="",o,a,c="",u;if(r!=null&&typeof r=="object"&&!Array.isArray(r)&&(n=r.space,u=r.quote,r=r.replacer),typeof r=="function")a=r;else if(Array.isArray(r)){o=[];for(let g of r){let y;typeof g=="string"?y=g:(typeof g=="number"||g instanceof String||g instanceof Number)&&(y=String(g)),y!==void 0&&o.indexOf(y)<0&&o.push(y)}}return n instanceof Number?n=Number(n):n instanceof String&&(n=String(n)),typeof n=="number"?n>0&&(n=Math.min(10,Math.floor(n)),c=" ".substr(0,n)):typeof n=="string"&&(c=n.substr(0,10)),l("",{"":t});function l(g,y){let b=y[g];switch(b!=null&&(typeof b.toJSON5=="function"?b=b.toJSON5(g):typeof b.toJSON=="function"&&(b=b.toJSON(g))),a&&(b=a.call(y,g,b)),b instanceof Number?b=Number(b):b instanceof String?b=String(b):b instanceof Boolean&&(b=b.valueOf()),b){case null:return"null";case!0:return"true";case!1:return"false"}if(typeof b=="string")return p(b,!1);if(typeof b=="number")return String(b);if(typeof b=="object")return Array.isArray(b)?m(b):d(b)}function p(g){let y={"'":.1,'"':.2},b={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r"," ":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"},v="";for(let x=0;x<g.length;x++){let D=g[x];switch(D){case"'":case'"':y[D]++,v+=D;continue;case"\0":if(ky.isDigit(g[x+1])){v+="\\x00";continue}}if(b[D]){v+=b[D];continue}if(D<" "){let E=D.charCodeAt(0).toString(16);v+="\\x"+("00"+E).substring(E.length);continue}v+=D}let C=u||Object.keys(y).reduce((x,D)=>y[x]<y[D]?x:D);return v=v.replace(new RegExp(C,"g"),b[C]),C+v+C}function d(g){if(i.indexOf(g)>=0)throw TypeError("Converting circular structure to JSON5");i.push(g);let y=s;s=s+c;let b=o||Object.keys(g),v=[];for(let x of b){let D=l(x,g);if(D!==void 0){let E=h(x)+":";c!==""&&(E+=" "),E+=D,v.push(E)}}let C;if(v.length===0)C="{}";else{let x;if(c==="")x=v.join(","),C="{"+x+"}";else{let D=`,
@@ -12,9 +12,9 @@ var pj=Object.create;var sd=Object.defineProperty;var dj=Object.getOwnPropertyDe
12
12
  `+s,x=b.join(C);v=`[
13
13
  `+s+x+`,
14
14
  `+y+"]"}return i.pop(),s=y,v}}});var kT=w((Gwe,IT)=>{f();var Az=PT(),Pz=_T(),Fz={parse:Az,stringify:Pz};IT.exports=Fz});var By=w(Fs=>{"use strict";f();Object.defineProperty(Fs,"__esModule",{value:!0});Fs.throwUnsupportedData=Fs.throwUnknownDataType=Fs.getType=void 0;function WT(e){return Object.prototype.toString.call(e)}Fs.getType=WT;function tH(e){throw new TypeError("unsupported data type: "+WT(e))}Fs.throwUnknownDataType=tH;function rH(e){throw new TypeError("unsupported data type: "+e)}Fs.throwUnsupportedData=rH});var jy=w(mr=>{"use strict";f();Object.defineProperty(mr,"__esModule",{value:!0});mr.s_to_num=mr.int_str_to_s=mr.num_to_s=mr.big_int_to_s=mr.int_to_s=mr.s_to_big_int=mr.s_to_int=void 0;var Ki="";for(let e=0;e<10;e++){let t=String.fromCharCode(48+e);Ki+=t}for(let e=0;e<26;e++){let t=String.fromCharCode(65+e);Ki+=t}for(let e=0;e<26;e++){let t=String.fromCharCode(97+e);Ki+=t}var ka=Ki.length,Ly={};for(let e=0;e<ka;e++){let t=Ki[e];Ly[t]=e}function $y(e){let t=0,r=1;for(let n=e.length-1;n>=0;n--){let i=e[n],s=Ly[i];s*=r,t+=s,r*=ka}return t}mr.s_to_int=$y;function YT(e){let t=BigInt(0),r=BigInt(1),n=BigInt(ka);for(let i=e.length-1;i>=0;i--){let s=e[i],o=BigInt(Ly[s]);o*=r,t+=o,r*=n}return t}mr.s_to_big_int=YT;function Uy(e){if(e===0)return Ki[0];let t=[];for(;e!==0;){let r=e%ka,n=Ki[r];t.push(n),e-=r,e/=ka}return t.reverse().join("")}mr.int_to_s=Uy;function JT(e){let t=BigInt(0),r=BigInt(ka);if(e===t)return Ki[0];let n=[];for(;e!==t;){let i=e%r,s=Ki[Number(i)];n.push(s),e/=r}return n.reverse().join("")}mr.big_int_to_s=JT;function XT(e){return e.split("").reverse().join("")}function QT(e){if(e<0)return"-"+QT(-e);let[t,r]=e.toString().split(".");if(!r)if(t.includes("e")){let[s,o]=t.split("e");t=s,r="0e"+o}else return Uy(e);let n;r&&([r,n]=r.split("e")),t=Md(t),r=XT(r),r=Md(r);let i=t+"."+r;if(n){switch(i+=".",n[0]){case"+":n=n.slice(1);break;case"-":i+="-",n=n.slice(1);break}n=Md(n),i+=n}return i}mr.num_to_s=QT;function Md(e){let t=+e;return t.toString()===e&&t+1!==t&&t-1!==t?Uy(t):":"+JT(BigInt(e))}mr.int_str_to_s=Md;function My(e){return e[0]===":"?YT(e.substring(1)).toString():$y(e).toString()}function ZT(e){if(e[0]==="-")return-ZT(e.substr(1));let[t,r,n]=e.split(".");if(!r)return $y(t);t=My(t),r=My(r),r=XT(r);let i=t+"."+r;if(n){i+="e";let s=!1;n[0]==="-"&&(s=!0,n=n.slice(1)),n=My(n),i+=s?-n:+n}return+i}mr.s_to_num=ZT});var Gy=w(hr=>{"use strict";f();Object.defineProperty(hr,"__esModule",{value:!0});hr.decodeStr=hr.encodeStr=hr.decodeBool=hr.encodeBool=hr.decodeKey=hr.decodeNum=hr.encodeNum=void 0;var qy=jy();function nH(e){return"n|"+(0,qy.num_to_s)(e)}hr.encodeNum=nH;function iH(e){return e=e.replace("n|",""),(0,qy.s_to_num)(e)}hr.decodeNum=iH;function sH(e){return typeof e=="number"?e:(0,qy.s_to_int)(e)}hr.decodeKey=sH;function oH(e){return e?"b|T":"b|F"}hr.encodeBool=oH;function aH(e){switch(e){case"b|T":return!0;case"b|F":return!1}return!!e}hr.decodeBool=aH;function cH(e){switch(e[0]+e[1]){case"b|":case"o|":case"n|":case"a|":case"s|":e="s|"+e}return e}hr.encodeStr=cH;function uH(e){return e[0]+e[1]==="s|"?e.substr(2):e}hr.decodeStr=uH});var zy=w(Ld=>{"use strict";f();Object.defineProperty(Ld,"__esModule",{value:!0});Ld.config=void 0;Ld.config={sort_key:!1,error_on_nan:!1,error_on_infinite:!1}});var Wy=w(Dn=>{"use strict";f();Object.defineProperty(Dn,"__esModule",{value:!0});Dn.addValue=Dn.makeInMemoryMemory=Dn.makeInMemoryCache=Dn.makeInMemoryStore=Dn.memToValues=void 0;var Vy=zy(),Hy=By(),Ky=Gy(),lH=jy();function pH(e){return e.store.toArray()}Dn.memToValues=pH;function eA(){let e=[];return{forEach(t){for(let r=0;r<e.length;r++)if(t(e[r])==="break")return},add(t){e.push(t)},toArray(){return e}}}Dn.makeInMemoryStore=eA;function tA(){let e=Object.create(null),t=Object.create(null);return{getValue(r){return e[r]},getSchema(r){return t[r]},forEachValue(r){for(let[n,i]of Object.entries(e))if(r(n,i)==="break")return},forEachSchema(r){for(let[n,i]of Object.entries(t))if(r(n,i)==="break")return},setValue(r,n){e[r]=n},setSchema(r,n){t[r]=n},hasValue(r){return r in e},hasSchema(r){return r in t}}}Dn.makeInMemoryCache=tA;function dH(){return{store:eA(),cache:tA(),keyCount:0}}Dn.makeInMemoryMemory=dH;function So(e,t){if(e.cache.hasValue(t))return e.cache.getValue(t);let r=e.keyCount++,n=(0,lH.num_to_s)(r);return e.store.add(t),e.cache.setValue(t,n),n}function fH(e,t){Vy.config.sort_key&&t.sort();let r=t.join(",");if(e.cache.hasSchema(r))return e.cache.getSchema(r);let n=Lu(e,t,void 0);return e.cache.setSchema(r,n),n}function Lu(e,t,r){if(t===null)return"";switch(typeof t){case"undefined":if(Array.isArray(r))return Lu(e,null,r);break;case"object":if(t===null)return So(e,null);if(Array.isArray(t)){let n="a";for(let i=0;i<t.length;i++){let s=t[i],o=s===null?"_":Lu(e,s,t);n+="|"+o}return n==="a"&&(n="a|"),So(e,n)}else{let n=Object.keys(t);if(n.length===0)return So(e,"o|");let i="o",s=fH(e,n);i+="|"+s;for(let o of n){let a=t[o],c=Lu(e,a,t);i+="|"+c}return So(e,i)}case"boolean":return So(e,(0,Ky.encodeBool)(t));case"number":return Number.isNaN(t)?(Vy.config.error_on_nan&&(0,Hy.throwUnsupportedData)("[number NaN]"),""):Number.POSITIVE_INFINITY===t||Number.NEGATIVE_INFINITY===t?(Vy.config.error_on_infinite&&(0,Hy.throwUnsupportedData)("[number Infinity]"),""):So(e,(0,Ky.encodeNum)(t));case"string":return So(e,(0,Ky.encodeStr)(t))}return(0,Hy.throwUnknownDataType)(t)}Dn.addValue=Lu});var Jy=w(_s=>{"use strict";f();Object.defineProperty(_s,"__esModule",{value:!0});_s.decompress=_s.decode=_s.compress=void 0;var mH=By(),$d=Gy(),Yy=Wy();function hH(e){let t=(0,Yy.makeInMemoryMemory)(),r=(0,Yy.addValue)(t,e,void 0);return[(0,Yy.memToValues)(t),r]}_s.compress=hH;function gH(e,t){if(t==="o|")return{};let r={},n=t.split("|"),i=n[1],s=$u(e,i),o=n.length;o-2===1&&!Array.isArray(s)&&(s=[s]);for(let a=2;a<o;a++){let c=s[a-2],u=n[a];u=$u(e,u),r[c]=u}return r}function yH(e,t){if(t==="a|")return[];let r=t.split("|"),n=r.length-1,i=new Array(n);for(let s=0;s<n;s++){let o=r[s+1];o=$u(e,o),i[s]=o}return i}function $u(e,t){if(t===""||t==="_")return null;let r=(0,$d.decodeKey)(t),n=e[r];if(n===null)return n;switch(typeof n){case"undefined":return n;case"number":return n;case"string":switch(n[0]+n[1]){case"b|":return(0,$d.decodeBool)(n);case"o|":return gH(e,n);case"n|":return(0,$d.decodeNum)(n);case"a|":return yH(e,n);default:return(0,$d.decodeStr)(n)}}return(0,mH.throwUnknownDataType)(n)}_s.decode=$u;function bH(e){let[t,r]=e;return $u(t,r)}_s.decompress=bH});var nA=w(Na=>{"use strict";f();Object.defineProperty(Na,"__esModule",{value:!0});Na.trimUndefinedRecursively=Na.trimUndefined=void 0;function xH(e){for(let t in e)e[t]===void 0&&delete e[t]}Na.trimUndefined=xH;function vH(e){rA(e,new Set)}Na.trimUndefinedRecursively=vH;function rA(e,t){t.add(e);for(let r in e)if(e[r]===void 0)delete e[r];else{let n=e[r];n&&typeof n=="object"&&!t.has(n)&&rA(n,t)}}});var oA=w(gr=>{"use strict";f();Object.defineProperty(gr,"__esModule",{value:!0});gr.config=gr.trimUndefinedRecursively=gr.trimUndefined=gr.addValue=gr.decode=gr.decompress=gr.compress=void 0;var iA=Jy();Object.defineProperty(gr,"compress",{enumerable:!0,get:function(){return iA.compress}});Object.defineProperty(gr,"decompress",{enumerable:!0,get:function(){return iA.decompress}});var DH=Jy();Object.defineProperty(gr,"decode",{enumerable:!0,get:function(){return DH.decode}});var CH=Wy();Object.defineProperty(gr,"addValue",{enumerable:!0,get:function(){return CH.addValue}});var sA=nA();Object.defineProperty(gr,"trimUndefined",{enumerable:!0,get:function(){return sA.trimUndefined}});Object.defineProperty(gr,"trimUndefinedRecursively",{enumerable:!0,get:function(){return sA.trimUndefinedRecursively}});var EH=zy();Object.defineProperty(gr,"config",{enumerable:!0,get:function(){return EH.config}})});var RP=w((eFe,NP)=>{f();function DP(e){return e instanceof Map?e.clear=e.delete=e.set=function(){throw new Error("map is read-only")}:e instanceof Set&&(e.add=e.clear=e.delete=function(){throw new Error("set is read-only")}),Object.freeze(e),Object.getOwnPropertyNames(e).forEach(t=>{let r=e[t],n=typeof r;(n==="object"||n==="function")&&!Object.isFrozen(r)&&DP(r)}),e}var Yd=class{constructor(t){t.data===void 0&&(t.data={}),this.data=t.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}};function CP(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;")}function ks(e,...t){let r=Object.create(null);for(let n in e)r[n]=e[n];return t.forEach(function(n){for(let i in n)r[i]=n[i]}),r}var nK="</span>",hP=e=>!!e.scope,iK=(e,{prefix:t})=>{if(e.startsWith("language:"))return e.replace("language:","language-");if(e.includes(".")){let r=e.split(".");return[`${t}${r.shift()}`,...r.map((n,i)=>`${n}${"_".repeat(i+1)}`)].join(" ")}return`${t}${e}`},rb=class{constructor(t,r){this.buffer="",this.classPrefix=r.classPrefix,t.walk(this)}addText(t){this.buffer+=CP(t)}openNode(t){if(!hP(t))return;let r=iK(t.scope,{prefix:this.classPrefix});this.span(r)}closeNode(t){hP(t)&&(this.buffer+=nK)}value(){return this.buffer}span(t){this.buffer+=`<span class="${t}">`}},gP=(e={})=>{let t={children:[]};return Object.assign(t,e),t},nb=class e{constructor(){this.rootNode=gP(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(t){this.top.children.push(t)}openNode(t){let r=gP({scope:t});this.add(r),this.stack.push(r)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(t){return this.constructor._walk(t,this.rootNode)}static _walk(t,r){return typeof r=="string"?t.addText(r):r.children&&(t.openNode(r),r.children.forEach(n=>this._walk(t,n)),t.closeNode(r)),t}static _collapse(t){typeof t!="string"&&t.children&&(t.children.every(r=>typeof r=="string")?t.children=[t.children.join("")]:t.children.forEach(r=>{e._collapse(r)}))}},ib=class extends nb{constructor(t){super(),this.options=t}addText(t){t!==""&&this.add(t)}startScope(t){this.openNode(t)}endScope(){this.closeNode()}__addSublanguage(t,r){let n=t.root;r&&(n.scope=`language:${r}`),this.add(n)}toHTML(){return new rb(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}};function Uu(e){return e?typeof e=="string"?e:e.source:null}function EP(e){return Ao("(?=",e,")")}function sK(e){return Ao("(?:",e,")*")}function oK(e){return Ao("(?:",e,")?")}function Ao(...e){return e.map(r=>Uu(r)).join("")}function aK(e){let t=e[e.length-1];return typeof t=="object"&&t.constructor===Object?(e.splice(e.length-1,1),t):{}}function ob(...e){return"("+(aK(e).capture?"":"?:")+e.map(n=>Uu(n)).join("|")+")"}function wP(e){return new RegExp(e.toString()+"|").exec("").length-1}function cK(e,t){let r=e&&e.exec(t);return r&&r.index===0}var uK=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function ab(e,{joinWith:t}){let r=0;return e.map(n=>{r+=1;let i=r,s=Uu(n),o="";for(;s.length>0;){let a=uK.exec(s);if(!a){o+=s;break}o+=s.substring(0,a.index),s=s.substring(a.index+a[0].length),a[0][0]==="\\"&&a[1]?o+="\\"+String(Number(a[1])+i):(o+=a[0],a[0]==="("&&r++)}return o}).map(n=>`(${n})`).join(t)}var lK=/\b\B/,SP="[a-zA-Z]\\w*",cb="[a-zA-Z_]\\w*",TP="\\b\\d+(\\.\\d+)?",AP="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",PP="\\b(0b[01]+)",pK="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",dK=(e={})=>{let t=/^#![ ]*\//;return e.binary&&(e.begin=Ao(t,/.*\b/,e.binary,/\b.*/)),ks({scope:"meta",begin:t,end:/$/,relevance:0,"on:begin":(r,n)=>{r.index!==0&&n.ignoreMatch()}},e)},ju={begin:"\\\\[\\s\\S]",relevance:0},fK={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[ju]},mK={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[ju]},hK={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},Xd=function(e,t,r={}){let n=ks({scope:"comment",begin:e,end:t,contains:[]},r);n.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});let i=ob("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return n.contains.push({begin:Ao(/[ ]+/,"(",i,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),n},gK=Xd("//","$"),yK=Xd("/\\*","\\*/"),bK=Xd("#","$"),xK={scope:"number",begin:TP,relevance:0},vK={scope:"number",begin:AP,relevance:0},DK={scope:"number",begin:PP,relevance:0},CK={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[ju,{begin:/\[/,end:/\]/,relevance:0,contains:[ju]}]},EK={scope:"title",begin:SP,relevance:0},wK={scope:"title",begin:cb,relevance:0},SK={begin:"\\.\\s*"+cb,relevance:0},TK=function(e){return Object.assign(e,{"on:begin":(t,r)=>{r.data._beginMatch=t[1]},"on:end":(t,r)=>{r.data._beginMatch!==t[1]&&r.ignoreMatch()}})},Wd=Object.freeze({__proto__:null,APOS_STRING_MODE:fK,BACKSLASH_ESCAPE:ju,BINARY_NUMBER_MODE:DK,BINARY_NUMBER_RE:PP,COMMENT:Xd,C_BLOCK_COMMENT_MODE:yK,C_LINE_COMMENT_MODE:gK,C_NUMBER_MODE:vK,C_NUMBER_RE:AP,END_SAME_AS_BEGIN:TK,HASH_COMMENT_MODE:bK,IDENT_RE:SP,MATCH_NOTHING_RE:lK,METHOD_GUARD:SK,NUMBER_MODE:xK,NUMBER_RE:TP,PHRASAL_WORDS_MODE:hK,QUOTE_STRING_MODE:mK,REGEXP_MODE:CK,RE_STARTERS_RE:pK,SHEBANG:dK,TITLE_MODE:EK,UNDERSCORE_IDENT_RE:cb,UNDERSCORE_TITLE_MODE:wK});function AK(e,t){e.input[e.index-1]==="."&&t.ignoreMatch()}function PK(e,t){e.className!==void 0&&(e.scope=e.className,delete e.className)}function FK(e,t){t&&e.beginKeywords&&(e.begin="\\b("+e.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",e.__beforeBegin=AK,e.keywords=e.keywords||e.beginKeywords,delete e.beginKeywords,e.relevance===void 0&&(e.relevance=0))}function _K(e,t){Array.isArray(e.illegal)&&(e.illegal=ob(...e.illegal))}function IK(e,t){if(e.match){if(e.begin||e.end)throw new Error("begin & end are not supported with match");e.begin=e.match,delete e.match}}function kK(e,t){e.relevance===void 0&&(e.relevance=1)}var NK=(e,t)=>{if(!e.beforeMatch)return;if(e.starts)throw new Error("beforeMatch cannot be used with starts");let r=Object.assign({},e);Object.keys(e).forEach(n=>{delete e[n]}),e.keywords=r.keywords,e.begin=Ao(r.beforeMatch,EP(r.begin)),e.starts={relevance:0,contains:[Object.assign(r,{endsParent:!0})]},e.relevance=0,delete r.beforeMatch},RK=["of","and","for","in","not","or","if","then","parent","list","value"],OK="keyword";function FP(e,t,r=OK){let n=Object.create(null);return typeof e=="string"?i(r,e.split(" ")):Array.isArray(e)?i(r,e):Object.keys(e).forEach(function(s){Object.assign(n,FP(e[s],t,s))}),n;function i(s,o){t&&(o=o.map(a=>a.toLowerCase())),o.forEach(function(a){let c=a.split("|");n[c[0]]=[s,BK(c[0],c[1])]})}}function BK(e,t){return t?Number(t):MK(e)?0:1}function MK(e){return RK.includes(e.toLowerCase())}var yP={},To=e=>{console.error(e)},bP=(e,...t)=>{console.log(`WARN: ${e}`,...t)},Ma=(e,t)=>{yP[`${e}/${t}`]||(console.log(`Deprecated as of ${e}. ${t}`),yP[`${e}/${t}`]=!0)},Jd=new Error;function _P(e,t,{key:r}){let n=0,i=e[r],s={},o={};for(let a=1;a<=t.length;a++)o[a+n]=i[a],s[a+n]=!0,n+=wP(t[a-1]);e[r]=o,e[r]._emit=s,e[r]._multi=!0}function LK(e){if(Array.isArray(e.begin)){if(e.skip||e.excludeBegin||e.returnBegin)throw To("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Jd;if(typeof e.beginScope!="object"||e.beginScope===null)throw To("beginScope must be object"),Jd;_P(e,e.begin,{key:"beginScope"}),e.begin=ab(e.begin,{joinWith:""})}}function $K(e){if(Array.isArray(e.end)){if(e.skip||e.excludeEnd||e.returnEnd)throw To("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Jd;if(typeof e.endScope!="object"||e.endScope===null)throw To("endScope must be object"),Jd;_P(e,e.end,{key:"endScope"}),e.end=ab(e.end,{joinWith:""})}}function UK(e){e.scope&&typeof e.scope=="object"&&e.scope!==null&&(e.beginScope=e.scope,delete e.scope)}function jK(e){UK(e),typeof e.beginScope=="string"&&(e.beginScope={_wrap:e.beginScope}),typeof e.endScope=="string"&&(e.endScope={_wrap:e.endScope}),LK(e),$K(e)}function qK(e){function t(o,a){return new RegExp(Uu(o),"m"+(e.case_insensitive?"i":"")+(e.unicodeRegex?"u":"")+(a?"g":""))}class r{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(a,c){c.position=this.position++,this.matchIndexes[this.matchAt]=c,this.regexes.push([c,a]),this.matchAt+=wP(a)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);let a=this.regexes.map(c=>c[1]);this.matcherRe=t(ab(a,{joinWith:"|"}),!0),this.lastIndex=0}exec(a){this.matcherRe.lastIndex=this.lastIndex;let c=this.matcherRe.exec(a);if(!c)return null;let u=c.findIndex((p,d)=>d>0&&p!==void 0),l=this.matchIndexes[u];return c.splice(0,u),Object.assign(c,l)}}class n{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(a){if(this.multiRegexes[a])return this.multiRegexes[a];let c=new r;return this.rules.slice(a).forEach(([u,l])=>c.addRule(u,l)),c.compile(),this.multiRegexes[a]=c,c}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(a,c){this.rules.push([a,c]),c.type==="begin"&&this.count++}exec(a){let c=this.getMatcher(this.regexIndex);c.lastIndex=this.lastIndex;let u=c.exec(a);if(this.resumingScanAtSamePosition()&&!(u&&u.index===this.lastIndex)){let l=this.getMatcher(0);l.lastIndex=this.lastIndex+1,u=l.exec(a)}return u&&(this.regexIndex+=u.position+1,this.regexIndex===this.count&&this.considerAll()),u}}function i(o){let a=new n;return o.contains.forEach(c=>a.addRule(c.begin,{rule:c,type:"begin"})),o.terminatorEnd&&a.addRule(o.terminatorEnd,{type:"end"}),o.illegal&&a.addRule(o.illegal,{type:"illegal"}),a}function s(o,a){let c=o;if(o.isCompiled)return c;[PK,IK,jK,NK].forEach(l=>l(o,a)),e.compilerExtensions.forEach(l=>l(o,a)),o.__beforeBegin=null,[FK,_K,kK].forEach(l=>l(o,a)),o.isCompiled=!0;let u=null;return typeof o.keywords=="object"&&o.keywords.$pattern&&(o.keywords=Object.assign({},o.keywords),u=o.keywords.$pattern,delete o.keywords.$pattern),u=u||/\w+/,o.keywords&&(o.keywords=FP(o.keywords,e.case_insensitive)),c.keywordPatternRe=t(u,!0),a&&(o.begin||(o.begin=/\B|\b/),c.beginRe=t(c.begin),!o.end&&!o.endsWithParent&&(o.end=/\B|\b/),o.end&&(c.endRe=t(c.end)),c.terminatorEnd=Uu(c.end)||"",o.endsWithParent&&a.terminatorEnd&&(c.terminatorEnd+=(o.end?"|":"")+a.terminatorEnd)),o.illegal&&(c.illegalRe=t(o.illegal)),o.contains||(o.contains=[]),o.contains=[].concat(...o.contains.map(function(l){return GK(l==="self"?o:l)})),o.contains.forEach(function(l){s(l,c)}),o.starts&&s(o.starts,a),c.matcher=i(c),c}if(e.compilerExtensions||(e.compilerExtensions=[]),e.contains&&e.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return e.classNameAliases=ks(e.classNameAliases||{}),s(e)}function IP(e){return e?e.endsWithParent||IP(e.starts):!1}function GK(e){return e.variants&&!e.cachedVariants&&(e.cachedVariants=e.variants.map(function(t){return ks(e,{variants:null},t)})),e.cachedVariants?e.cachedVariants:IP(e)?ks(e,{starts:e.starts?ks(e.starts):null}):Object.isFrozen(e)?ks(e):e}var zK="11.9.0",sb=class extends Error{constructor(t,r){super(t),this.name="HTMLInjectionError",this.html=r}},tb=CP,xP=ks,vP=Symbol("nomatch"),HK=7,kP=function(e){let t=Object.create(null),r=Object.create(null),n=[],i=!0,s="Could not find the language '{}', did you forget to load/include a language module?",o={disableAutodetect:!0,name:"Plain text",contains:[]},a={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:ib};function c(L){return a.noHighlightRe.test(L)}function u(L){let k=L.className+" ";k+=L.parentNode?L.parentNode.className:"";let $=a.languageDetectRe.exec(k);if($){let R=I($[1]);return R||(bP(s.replace("{}",$[1])),bP("Falling back to no-highlight mode for this block.",L)),R?$[1]:"no-highlight"}return k.split(/\s+/).find(R=>c(R)||I(R))}function l(L,k,$){let R="",M="";typeof k=="object"?(R=L,$=k.ignoreIllegals,M=k.language):(Ma("10.7.0","highlight(lang, code, ...args) has been deprecated."),Ma("10.7.0",`Please use highlight(code, options) instead.
15
- https://github.com/highlightjs/highlight.js/issues/2277`),M=L,R=k),$===void 0&&($=!0);let K={code:R,language:M};P("before:highlight",K);let W=K.result?K.result:p(K.language,K.code,$);return W.code=K.code,P("after:highlight",W),W}function p(L,k,$,R){let M=Object.create(null);function K(ee,oe){return ee.keywords[oe]}function W(){if(!ye.keywords){nr.addText(dt);return}let ee=0;ye.keywordPatternRe.lastIndex=0;let oe=ye.keywordPatternRe.exec(dt),Ee="";for(;oe;){Ee+=dt.substring(ee,oe.index);let Je=ur.case_insensitive?oe[0].toLowerCase():oe[0],lr=K(ye,Je);if(lr){let[ji,uj]=lr;if(nr.addText(Ee),Ee="",M[Je]=(M[Je]||0)+1,M[Je]<=HK&&(id+=uj),ji.startsWith("_"))Ee+=oe[0];else{let lj=ur.classNameAliases[ji]||ji;Z(oe[0],lj)}}else Ee+=oe[0];ee=ye.keywordPatternRe.lastIndex,oe=ye.keywordPatternRe.exec(dt)}Ee+=dt.substring(ee),nr.addText(Ee)}function ce(){if(dt==="")return;let ee=null;if(typeof ye.subLanguage=="string"){if(!t[ye.subLanguage]){nr.addText(dt);return}ee=p(ye.subLanguage,dt,!0,lS[ye.subLanguage]),lS[ye.subLanguage]=ee._top}else ee=h(dt,ye.subLanguage.length?ye.subLanguage:null);ye.relevance>0&&(id+=ee.relevance),nr.__addSublanguage(ee._emitter,ee.language)}function se(){ye.subLanguage!=null?ce():W(),dt=""}function Z(ee,oe){ee!==""&&(nr.startScope(oe),nr.addText(ee),nr.endScope())}function xt(ee,oe){let Ee=1,Je=oe.length-1;for(;Ee<=Je;){if(!ee._emit[Ee]){Ee++;continue}let lr=ur.classNameAliases[ee[Ee]]||ee[Ee],ji=oe[Ee];lr?Z(ji,lr):(dt=ji,W(),dt=""),Ee++}}function Le(ee,oe){return ee.scope&&typeof ee.scope=="string"&&nr.openNode(ur.classNameAliases[ee.scope]||ee.scope),ee.beginScope&&(ee.beginScope._wrap?(Z(dt,ur.classNameAliases[ee.beginScope._wrap]||ee.beginScope._wrap),dt=""):ee.beginScope._multi&&(xt(ee.beginScope,oe),dt="")),ye=Object.create(ee,{parent:{value:ye}}),ye}function J(ee,oe,Ee){let Je=cK(ee.endRe,Ee);if(Je){if(ee["on:end"]){let lr=new Yd(ee);ee["on:end"](oe,lr),lr.isMatchIgnored&&(Je=!1)}if(Je){for(;ee.endsParent&&ee.parent;)ee=ee.parent;return ee}}if(ee.endsWithParent)return J(ee.parent,oe,Ee)}function $e(ee){return ye.matcher.regexIndex===0?(dt+=ee[0],1):(Mg=!0,0)}function X(ee){let oe=ee[0],Ee=ee.rule,Je=new Yd(Ee),lr=[Ee.__beforeBegin,Ee["on:begin"]];for(let ji of lr)if(ji&&(ji(ee,Je),Je.isMatchIgnored))return $e(oe);return Ee.skip?dt+=oe:(Ee.excludeBegin&&(dt+=oe),se(),!Ee.returnBegin&&!Ee.excludeBegin&&(dt=oe)),Le(Ee,ee),Ee.returnBegin?0:oe.length}function me(ee){let oe=ee[0],Ee=k.substring(ee.index),Je=J(ye,ee,Ee);if(!Je)return vP;let lr=ye;ye.endScope&&ye.endScope._wrap?(se(),Z(oe,ye.endScope._wrap)):ye.endScope&&ye.endScope._multi?(se(),xt(ye.endScope,ee)):lr.skip?dt+=oe:(lr.returnEnd||lr.excludeEnd||(dt+=oe),se(),lr.excludeEnd&&(dt=oe));do ye.scope&&nr.closeNode(),!ye.skip&&!ye.subLanguage&&(id+=ye.relevance),ye=ye.parent;while(ye!==Je.parent);return Je.starts&&Le(Je.starts,ee),lr.returnEnd?0:oe.length}function ue(){let ee=[];for(let oe=ye;oe!==ur;oe=oe.parent)oe.scope&&ee.unshift(oe.scope);ee.forEach(oe=>nr.openNode(oe))}let pt={};function Ze(ee,oe){let Ee=oe&&oe[0];if(dt+=ee,Ee==null)return se(),0;if(pt.type==="begin"&&oe.type==="end"&&pt.index===oe.index&&Ee===""){if(dt+=k.slice(oe.index,oe.index+1),!i){let Je=new Error(`0 width match regex (${L})`);throw Je.languageName=L,Je.badRule=pt.rule,Je}return 1}if(pt=oe,oe.type==="begin")return X(oe);if(oe.type==="illegal"&&!$){let Je=new Error('Illegal lexeme "'+Ee+'" for mode "'+(ye.scope||"<unnamed>")+'"');throw Je.mode=ye,Je}else if(oe.type==="end"){let Je=me(oe);if(Je!==vP)return Je}if(oe.type==="illegal"&&Ee==="")return 1;if(Bg>1e5&&Bg>oe.index*3)throw new Error("potential infinite loop, way more iterations than matches");return dt+=Ee,Ee.length}let ur=I(L);if(!ur)throw To(s.replace("{}",L)),new Error('Unknown language: "'+L+'"');let ya=qK(ur),Og="",ye=R||ya,lS={},nr=new a.__emitter(a);ue();let dt="",id=0,mo=0,Bg=0,Mg=!1;try{if(ur.__emitTokens)ur.__emitTokens(k,nr);else{for(ye.matcher.considerAll();;){Bg++,Mg?Mg=!1:ye.matcher.considerAll(),ye.matcher.lastIndex=mo;let ee=ye.matcher.exec(k);if(!ee)break;let oe=k.substring(mo,ee.index),Ee=Ze(oe,ee);mo=ee.index+Ee}Ze(k.substring(mo))}return nr.finalize(),Og=nr.toHTML(),{language:L,value:Og,relevance:id,illegal:!1,_emitter:nr,_top:ye}}catch(ee){if(ee.message&&ee.message.includes("Illegal"))return{language:L,value:tb(k),illegal:!0,relevance:0,_illegalBy:{message:ee.message,index:mo,context:k.slice(mo-100,mo+100),mode:ee.mode,resultSoFar:Og},_emitter:nr};if(i)return{language:L,value:tb(k),illegal:!1,relevance:0,errorRaised:ee,_emitter:nr,_top:ye};throw ee}}function d(L){let k={value:tb(L),illegal:!1,relevance:0,_top:o,_emitter:new a.__emitter(a)};return k._emitter.addText(L),k}function h(L,k){k=k||a.languages||Object.keys(t);let $=d(L),R=k.filter(I).filter(T).map(se=>p(se,L,!1));R.unshift($);let M=R.sort((se,Z)=>{if(se.relevance!==Z.relevance)return Z.relevance-se.relevance;if(se.language&&Z.language){if(I(se.language).supersetOf===Z.language)return 1;if(I(Z.language).supersetOf===se.language)return-1}return 0}),[K,W]=M,ce=K;return ce.secondBest=W,ce}function m(L,k,$){let R=k&&r[k]||$;L.classList.add("hljs"),L.classList.add(`language-${R}`)}function g(L){let k=null,$=u(L);if(c($))return;if(P("before:highlightElement",{el:L,language:$}),L.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",L);return}if(L.children.length>0&&(a.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(L)),a.throwUnescapedHTML))throw new sb("One of your code blocks includes unescaped HTML.",L.innerHTML);k=L;let R=k.textContent,M=$?l(R,{language:$,ignoreIllegals:!0}):h(R);L.innerHTML=M.value,L.dataset.highlighted="yes",m(L,$,M.language),L.result={language:M.language,re:M.relevance,relevance:M.relevance},M.secondBest&&(L.secondBest={language:M.secondBest.language,relevance:M.secondBest.relevance}),P("after:highlightElement",{el:L,result:M,text:R})}function y(L){a=xP(a,L)}let b=()=>{x(),Ma("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function v(){x(),Ma("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let C=!1;function x(){if(document.readyState==="loading"){C=!0;return}document.querySelectorAll(a.cssSelector).forEach(g)}function D(){C&&x()}typeof window<"u"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",D,!1);function E(L,k){let $=null;try{$=k(e)}catch(R){if(To("Language definition for '{}' could not be registered.".replace("{}",L)),i)To(R);else throw R;$=o}$.name||($.name=L),t[L]=$,$.rawDefinition=k.bind(null,e),$.aliases&&A($.aliases,{languageName:L})}function S(L){delete t[L];for(let k of Object.keys(r))r[k]===L&&delete r[k]}function F(){return Object.keys(t)}function I(L){return L=(L||"").toLowerCase(),t[L]||t[r[L]]}function A(L,{languageName:k}){typeof L=="string"&&(L=[L]),L.forEach($=>{r[$.toLowerCase()]=k})}function T(L){let k=I(L);return k&&!k.disableAutodetect}function G(L){L["before:highlightBlock"]&&!L["before:highlightElement"]&&(L["before:highlightElement"]=k=>{L["before:highlightBlock"](Object.assign({block:k.el},k))}),L["after:highlightBlock"]&&!L["after:highlightElement"]&&(L["after:highlightElement"]=k=>{L["after:highlightBlock"](Object.assign({block:k.el},k))})}function V(L){G(L),n.push(L)}function Y(L){let k=n.indexOf(L);k!==-1&&n.splice(k,1)}function P(L,k){let $=L;n.forEach(function(R){R[$]&&R[$](k)})}function N(L){return Ma("10.7.0","highlightBlock will be removed entirely in v12.0"),Ma("10.7.0","Please use highlightElement now."),g(L)}Object.assign(e,{highlight:l,highlightAuto:h,highlightAll:x,highlightElement:g,highlightBlock:N,configure:y,initHighlighting:b,initHighlightingOnLoad:v,registerLanguage:E,unregisterLanguage:S,listLanguages:F,getLanguage:I,registerAliases:A,autoDetection:T,inherit:xP,addPlugin:V,removePlugin:Y}),e.debugMode=function(){i=!1},e.safeMode=function(){i=!0},e.versionString=zK,e.regex={concat:Ao,lookahead:EP,either:ob,optional:oK,anyNumberOfTimes:sK};for(let L in Wd)typeof Wd[L]=="object"&&DP(Wd[L]);return Object.assign(e,Wd),e},La=kP({});La.newInstance=()=>kP({});NP.exports=La;La.HighlightJS=La;La.default=La});var tF=w(gb=>{f();var eF="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");gb.encode=function(e){if(0<=e&&e<eF.length)return eF[e];throw new TypeError("Must be between 0 and 63: "+e)};gb.decode=function(e){var t=65,r=90,n=97,i=122,s=48,o=57,a=43,c=47,u=26,l=52;return t<=e&&e<=r?e-t:n<=e&&e<=i?e-n+u:s<=e&&e<=o?e-s+l:e==a?62:e==c?63:-1}});var xb=w(bb=>{f();var rF=tF(),yb=5,nF=1<<yb,iF=nF-1,sF=nF;function aV(e){return e<0?(-e<<1)+1:(e<<1)+0}function cV(e){var t=(e&1)===1,r=e>>1;return t?-r:r}bb.encode=function(t){var r="",n,i=aV(t);do n=i&iF,i>>>=yb,i>0&&(n|=sF),r+=rF.encode(n);while(i>0);return r};bb.decode=function(t,r,n){var i=t.length,s=0,o=0,a,c;do{if(r>=i)throw new Error("Expected more digits in base 64 VLQ value.");if(c=rF.decode(t.charCodeAt(r++)),c===-1)throw new Error("Invalid base64 digit: "+t.charAt(r-1));a=!!(c&sF),c&=iF,s=s+(c<<o),o+=yb}while(a);n.value=cV(s),n.rest=r}});var qa=w(Kt=>{f();function uV(e,t,r){if(t in e)return e[t];if(arguments.length===3)return r;throw new Error('"'+t+'" is a required argument.')}Kt.getArg=uV;var oF=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,lV=/^data:.+\,.+$/;function Hu(e){var t=e.match(oF);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}Kt.urlParse=Hu;function ja(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}Kt.urlGenerate=ja;var pV=32;function dV(e){var t=[];return function(r){for(var n=0;n<t.length;n++)if(t[n].input===r){var i=t[0];return t[0]=t[n],t[n]=i,t[0].result}var s=e(r);return t.unshift({input:r,result:s}),t.length>pV&&t.pop(),s}}var vb=dV(function(t){var r=t,n=Hu(t);if(n){if(!n.path)return t;r=n.path}for(var i=Kt.isAbsolute(r),s=[],o=0,a=0;;)if(o=a,a=r.indexOf("/",o),a===-1){s.push(r.slice(o));break}else for(s.push(r.slice(o,a));a<r.length&&r[a]==="/";)a++;for(var c,u=0,a=s.length-1;a>=0;a--)c=s[a],c==="."?s.splice(a,1):c===".."?u++:u>0&&(c===""?(s.splice(a+1,u),u=0):(s.splice(a,2),u--));return r=s.join("/"),r===""&&(r=i?"/":"."),n?(n.path=r,ja(n)):r});Kt.normalize=vb;function aF(e,t){e===""&&(e="."),t===""&&(t=".");var r=Hu(t),n=Hu(e);if(n&&(e=n.path||"/"),r&&!r.scheme)return n&&(r.scheme=n.scheme),ja(r);if(r||t.match(lV))return t;if(n&&!n.host&&!n.path)return n.host=t,ja(n);var i=t.charAt(0)==="/"?t:vb(e.replace(/\/+$/,"")+"/"+t);return n?(n.path=i,ja(n)):i}Kt.join=aF;Kt.isAbsolute=function(e){return e.charAt(0)==="/"||oF.test(e)};function fV(e,t){e===""&&(e="."),e=e.replace(/\/$/,"");for(var r=0;t.indexOf(e+"/")!==0;){var n=e.lastIndexOf("/");if(n<0||(e=e.slice(0,n),e.match(/^([^\/]+:\/)?\/*$/)))return t;++r}return Array(r+1).join("../")+t.substr(e.length+1)}Kt.relative=fV;var cF=function(){var e=Object.create(null);return!("__proto__"in e)}();function uF(e){return e}function mV(e){return lF(e)?"$"+e:e}Kt.toSetString=cF?uF:mV;function hV(e){return lF(e)?e.slice(1):e}Kt.fromSetString=cF?uF:hV;function lF(e){if(!e)return!1;var t=e.length;if(t<9||e.charCodeAt(t-1)!==95||e.charCodeAt(t-2)!==95||e.charCodeAt(t-3)!==111||e.charCodeAt(t-4)!==116||e.charCodeAt(t-5)!==111||e.charCodeAt(t-6)!==114||e.charCodeAt(t-7)!==112||e.charCodeAt(t-8)!==95||e.charCodeAt(t-9)!==95)return!1;for(var r=t-10;r>=0;r--)if(e.charCodeAt(r)!==36)return!1;return!0}function gV(e,t,r){var n=Wi(e.source,t.source);return n!==0||(n=e.originalLine-t.originalLine,n!==0)||(n=e.originalColumn-t.originalColumn,n!==0||r)||(n=e.generatedColumn-t.generatedColumn,n!==0)||(n=e.generatedLine-t.generatedLine,n!==0)?n:Wi(e.name,t.name)}Kt.compareByOriginalPositions=gV;function yV(e,t,r){var n;return n=e.originalLine-t.originalLine,n!==0||(n=e.originalColumn-t.originalColumn,n!==0||r)||(n=e.generatedColumn-t.generatedColumn,n!==0)||(n=e.generatedLine-t.generatedLine,n!==0)?n:Wi(e.name,t.name)}Kt.compareByOriginalPositionsNoSource=yV;function bV(e,t,r){var n=e.generatedLine-t.generatedLine;return n!==0||(n=e.generatedColumn-t.generatedColumn,n!==0||r)||(n=Wi(e.source,t.source),n!==0)||(n=e.originalLine-t.originalLine,n!==0)||(n=e.originalColumn-t.originalColumn,n!==0)?n:Wi(e.name,t.name)}Kt.compareByGeneratedPositionsDeflated=bV;function xV(e,t,r){var n=e.generatedColumn-t.generatedColumn;return n!==0||r||(n=Wi(e.source,t.source),n!==0)||(n=e.originalLine-t.originalLine,n!==0)||(n=e.originalColumn-t.originalColumn,n!==0)?n:Wi(e.name,t.name)}Kt.compareByGeneratedPositionsDeflatedNoLine=xV;function Wi(e,t){return e===t?0:e===null?1:t===null?-1:e>t?1:-1}function vV(e,t){var r=e.generatedLine-t.generatedLine;return r!==0||(r=e.generatedColumn-t.generatedColumn,r!==0)||(r=Wi(e.source,t.source),r!==0)||(r=e.originalLine-t.originalLine,r!==0)||(r=e.originalColumn-t.originalColumn,r!==0)?r:Wi(e.name,t.name)}Kt.compareByGeneratedPositionsInflated=vV;function DV(e){return JSON.parse(e.replace(/^\)]}'[^\n]*\n/,""))}Kt.parseSourceMapInput=DV;function CV(e,t,r){if(t=t||"",e&&(e[e.length-1]!=="/"&&t[0]!=="/"&&(e+="/"),t=e+t),r){var n=Hu(r);if(!n)throw new Error("sourceMapURL could not be parsed");if(n.path){var i=n.path.lastIndexOf("/");i>=0&&(n.path=n.path.substring(0,i+1))}t=aF(ja(n),t)}return vb(t)}Kt.computeSourceURL=CV});var Eb=w(pF=>{f();var Db=qa(),Cb=Object.prototype.hasOwnProperty,Po=typeof Map<"u";function Yi(){this._array=[],this._set=Po?new Map:Object.create(null)}Yi.fromArray=function(t,r){for(var n=new Yi,i=0,s=t.length;i<s;i++)n.add(t[i],r);return n};Yi.prototype.size=function(){return Po?this._set.size:Object.getOwnPropertyNames(this._set).length};Yi.prototype.add=function(t,r){var n=Po?t:Db.toSetString(t),i=Po?this.has(t):Cb.call(this._set,n),s=this._array.length;(!i||r)&&this._array.push(t),i||(Po?this._set.set(t,s):this._set[n]=s)};Yi.prototype.has=function(t){if(Po)return this._set.has(t);var r=Db.toSetString(t);return Cb.call(this._set,r)};Yi.prototype.indexOf=function(t){if(Po){var r=this._set.get(t);if(r>=0)return r}else{var n=Db.toSetString(t);if(Cb.call(this._set,n))return this._set[n]}throw new Error('"'+t+'" is not in the set.')};Yi.prototype.at=function(t){if(t>=0&&t<this._array.length)return this._array[t];throw new Error("No element indexed by "+t)};Yi.prototype.toArray=function(){return this._array.slice()};pF.ArraySet=Yi});var mF=w(fF=>{f();var dF=qa();function EV(e,t){var r=e.generatedLine,n=t.generatedLine,i=e.generatedColumn,s=t.generatedColumn;return n>r||n==r&&s>=i||dF.compareByGeneratedPositionsInflated(e,t)<=0}function rf(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}rf.prototype.unsortedForEach=function(t,r){this._array.forEach(t,r)};rf.prototype.add=function(t){EV(this._last,t)?(this._last=t,this._array.push(t)):(this._sorted=!1,this._array.push(t))};rf.prototype.toArray=function(){return this._sorted||(this._array.sort(dF.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};fF.MappingList=rf});var wb=w(hF=>{f();var Ku=xb(),Nt=qa(),nf=Eb().ArraySet,wV=mF().MappingList;function En(e){e||(e={}),this._file=Nt.getArg(e,"file",null),this._sourceRoot=Nt.getArg(e,"sourceRoot",null),this._skipValidation=Nt.getArg(e,"skipValidation",!1),this._ignoreInvalidMapping=Nt.getArg(e,"ignoreInvalidMapping",!1),this._sources=new nf,this._names=new nf,this._mappings=new wV,this._sourcesContents=null}En.prototype._version=3;En.fromSourceMap=function(t,r){var n=t.sourceRoot,i=new En(Object.assign(r||{},{file:t.file,sourceRoot:n}));return t.eachMapping(function(s){var o={generated:{line:s.generatedLine,column:s.generatedColumn}};s.source!=null&&(o.source=s.source,n!=null&&(o.source=Nt.relative(n,o.source)),o.original={line:s.originalLine,column:s.originalColumn},s.name!=null&&(o.name=s.name)),i.addMapping(o)}),t.sources.forEach(function(s){var o=s;n!==null&&(o=Nt.relative(n,s)),i._sources.has(o)||i._sources.add(o);var a=t.sourceContentFor(s);a!=null&&i.setSourceContent(s,a)}),i};En.prototype.addMapping=function(t){var r=Nt.getArg(t,"generated"),n=Nt.getArg(t,"original",null),i=Nt.getArg(t,"source",null),s=Nt.getArg(t,"name",null);!this._skipValidation&&this._validateMapping(r,n,i,s)===!1||(i!=null&&(i=String(i),this._sources.has(i)||this._sources.add(i)),s!=null&&(s=String(s),this._names.has(s)||this._names.add(s)),this._mappings.add({generatedLine:r.line,generatedColumn:r.column,originalLine:n!=null&&n.line,originalColumn:n!=null&&n.column,source:i,name:s}))};En.prototype.setSourceContent=function(t,r){var n=t;this._sourceRoot!=null&&(n=Nt.relative(this._sourceRoot,n)),r!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[Nt.toSetString(n)]=r):this._sourcesContents&&(delete this._sourcesContents[Nt.toSetString(n)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};En.prototype.applySourceMap=function(t,r,n){var i=r;if(r==null){if(t.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);i=t.file}var s=this._sourceRoot;s!=null&&(i=Nt.relative(s,i));var o=new nf,a=new nf;this._mappings.unsortedForEach(function(c){if(c.source===i&&c.originalLine!=null){var u=t.originalPositionFor({line:c.originalLine,column:c.originalColumn});u.source!=null&&(c.source=u.source,n!=null&&(c.source=Nt.join(n,c.source)),s!=null&&(c.source=Nt.relative(s,c.source)),c.originalLine=u.line,c.originalColumn=u.column,u.name!=null&&(c.name=u.name))}var l=c.source;l!=null&&!o.has(l)&&o.add(l);var p=c.name;p!=null&&!a.has(p)&&a.add(p)},this),this._sources=o,this._names=a,t.sources.forEach(function(c){var u=t.sourceContentFor(c);u!=null&&(n!=null&&(c=Nt.join(n,c)),s!=null&&(c=Nt.relative(s,c)),this.setSourceContent(c,u))},this)};En.prototype._validateMapping=function(t,r,n,i){if(r&&typeof r.line!="number"&&typeof r.column!="number"){var s="original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.";if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(s),!1;throw new Error(s)}if(!(t&&"line"in t&&"column"in t&&t.line>0&&t.column>=0&&!r&&!n&&!i)){if(t&&"line"in t&&"column"in t&&r&&"line"in r&&"column"in r&&t.line>0&&t.column>=0&&r.line>0&&r.column>=0&&n)return;var s="Invalid mapping: "+JSON.stringify({generated:t,source:n,original:r,name:i});if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(s),!1;throw new Error(s)}};En.prototype._serializeMappings=function(){for(var t=0,r=1,n=0,i=0,s=0,o=0,a="",c,u,l,p,d=this._mappings.toArray(),h=0,m=d.length;h<m;h++){if(u=d[h],c="",u.generatedLine!==r)for(t=0;u.generatedLine!==r;)c+=";",r++;else if(h>0){if(!Nt.compareByGeneratedPositionsInflated(u,d[h-1]))continue;c+=","}c+=Ku.encode(u.generatedColumn-t),t=u.generatedColumn,u.source!=null&&(p=this._sources.indexOf(u.source),c+=Ku.encode(p-o),o=p,c+=Ku.encode(u.originalLine-1-i),i=u.originalLine-1,c+=Ku.encode(u.originalColumn-n),n=u.originalColumn,u.name!=null&&(l=this._names.indexOf(u.name),c+=Ku.encode(l-s),s=l)),a+=c}return a};En.prototype._generateSourcesContent=function(t,r){return t.map(function(n){if(!this._sourcesContents)return null;r!=null&&(n=Nt.relative(r,n));var i=Nt.toSetString(n);return Object.prototype.hasOwnProperty.call(this._sourcesContents,i)?this._sourcesContents[i]:null},this)};En.prototype.toJSON=function(){var t={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(t.file=this._file),this._sourceRoot!=null&&(t.sourceRoot=this._sourceRoot),this._sourcesContents&&(t.sourcesContent=this._generateSourcesContent(t.sources,t.sourceRoot)),t};En.prototype.toString=function(){return JSON.stringify(this.toJSON())};hF.SourceMapGenerator=En});var gF=w(Fo=>{f();Fo.GREATEST_LOWER_BOUND=1;Fo.LEAST_UPPER_BOUND=2;function Sb(e,t,r,n,i,s){var o=Math.floor((t-e)/2)+e,a=i(r,n[o],!0);return a===0?o:a>0?t-o>1?Sb(o,t,r,n,i,s):s==Fo.LEAST_UPPER_BOUND?t<n.length?t:-1:o:o-e>1?Sb(e,o,r,n,i,s):s==Fo.LEAST_UPPER_BOUND?o:e<0?-1:e}Fo.search=function(t,r,n,i){if(r.length===0)return-1;var s=Sb(-1,r.length,t,r,n,i||Fo.GREATEST_LOWER_BOUND);if(s<0)return-1;for(;s-1>=0&&n(r[s],r[s-1],!0)===0;)--s;return s}});var xF=w(bF=>{f();function SV(e){function t(i,s,o){var a=i[s];i[s]=i[o],i[o]=a}function r(i,s){return Math.round(i+Math.random()*(s-i))}function n(i,s,o,a){if(o<a){var c=r(o,a),u=o-1;t(i,c,a);for(var l=i[a],p=o;p<a;p++)s(i[p],l,!1)<=0&&(u+=1,t(i,u,p));t(i,u+1,p);var d=u+1;n(i,s,o,d-1),n(i,s,d+1,a)}}return n}function TV(e){let t=SV.toString();return new Function(`return ${t}`)()(e)}var yF=new WeakMap;bF.quickSort=function(e,t,r=0){let n=yF.get(t);n===void 0&&(n=TV(t),yF.set(t,n)),n(e,t,r,e.length-1)}});var CF=w(sf=>{f();var ne=qa(),Ab=gF(),Ga=Eb().ArraySet,AV=xb(),Vu=xF().quickSort;function ht(e,t){var r=e;return typeof e=="string"&&(r=ne.parseSourceMapInput(e)),r.sections!=null?new Kn(r,t):new or(r,t)}ht.fromSourceMap=function(e,t){return or.fromSourceMap(e,t)};ht.prototype._version=3;ht.prototype.__generatedMappings=null;Object.defineProperty(ht.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});ht.prototype.__originalMappings=null;Object.defineProperty(ht.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});ht.prototype._charIsMappingSeparator=function(t,r){var n=t.charAt(r);return n===";"||n===","};ht.prototype._parseMappings=function(t,r){throw new Error("Subclasses must implement _parseMappings")};ht.GENERATED_ORDER=1;ht.ORIGINAL_ORDER=2;ht.GREATEST_LOWER_BOUND=1;ht.LEAST_UPPER_BOUND=2;ht.prototype.eachMapping=function(t,r,n){var i=r||null,s=n||ht.GENERATED_ORDER,o;switch(s){case ht.GENERATED_ORDER:o=this._generatedMappings;break;case ht.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}for(var a=this.sourceRoot,c=t.bind(i),u=this._names,l=this._sources,p=this._sourceMapURL,d=0,h=o.length;d<h;d++){var m=o[d],g=m.source===null?null:l.at(m.source);g!==null&&(g=ne.computeSourceURL(a,g,p)),c({source:g,generatedLine:m.generatedLine,generatedColumn:m.generatedColumn,originalLine:m.originalLine,originalColumn:m.originalColumn,name:m.name===null?null:u.at(m.name)})}};ht.prototype.allGeneratedPositionsFor=function(t){var r=ne.getArg(t,"line"),n={source:ne.getArg(t,"source"),originalLine:r,originalColumn:ne.getArg(t,"column",0)};if(n.source=this._findSourceIndex(n.source),n.source<0)return[];var i=[],s=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",ne.compareByOriginalPositions,Ab.LEAST_UPPER_BOUND);if(s>=0){var o=this._originalMappings[s];if(t.column===void 0)for(var a=o.originalLine;o&&o.originalLine===a;)i.push({line:ne.getArg(o,"generatedLine",null),column:ne.getArg(o,"generatedColumn",null),lastColumn:ne.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++s];else for(var c=o.originalColumn;o&&o.originalLine===r&&o.originalColumn==c;)i.push({line:ne.getArg(o,"generatedLine",null),column:ne.getArg(o,"generatedColumn",null),lastColumn:ne.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++s]}return i};sf.SourceMapConsumer=ht;function or(e,t){var r=e;typeof e=="string"&&(r=ne.parseSourceMapInput(e));var n=ne.getArg(r,"version"),i=ne.getArg(r,"sources"),s=ne.getArg(r,"names",[]),o=ne.getArg(r,"sourceRoot",null),a=ne.getArg(r,"sourcesContent",null),c=ne.getArg(r,"mappings"),u=ne.getArg(r,"file",null);if(n!=this._version)throw new Error("Unsupported version: "+n);o&&(o=ne.normalize(o)),i=i.map(String).map(ne.normalize).map(function(l){return o&&ne.isAbsolute(o)&&ne.isAbsolute(l)?ne.relative(o,l):l}),this._names=Ga.fromArray(s.map(String),!0),this._sources=Ga.fromArray(i,!0),this._absoluteSources=this._sources.toArray().map(function(l){return ne.computeSourceURL(o,l,t)}),this.sourceRoot=o,this.sourcesContent=a,this._mappings=c,this._sourceMapURL=t,this.file=u}or.prototype=Object.create(ht.prototype);or.prototype.consumer=ht;or.prototype._findSourceIndex=function(e){var t=e;if(this.sourceRoot!=null&&(t=ne.relative(this.sourceRoot,t)),this._sources.has(t))return this._sources.indexOf(t);var r;for(r=0;r<this._absoluteSources.length;++r)if(this._absoluteSources[r]==e)return r;return-1};or.fromSourceMap=function(t,r){var n=Object.create(or.prototype),i=n._names=Ga.fromArray(t._names.toArray(),!0),s=n._sources=Ga.fromArray(t._sources.toArray(),!0);n.sourceRoot=t._sourceRoot,n.sourcesContent=t._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=t._file,n._sourceMapURL=r,n._absoluteSources=n._sources.toArray().map(function(h){return ne.computeSourceURL(n.sourceRoot,h,r)});for(var o=t._mappings.toArray().slice(),a=n.__generatedMappings=[],c=n.__originalMappings=[],u=0,l=o.length;u<l;u++){var p=o[u],d=new DF;d.generatedLine=p.generatedLine,d.generatedColumn=p.generatedColumn,p.source&&(d.source=s.indexOf(p.source),d.originalLine=p.originalLine,d.originalColumn=p.originalColumn,p.name&&(d.name=i.indexOf(p.name)),c.push(d)),a.push(d)}return Vu(n.__originalMappings,ne.compareByOriginalPositions),n};or.prototype._version=3;Object.defineProperty(or.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function DF(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}var Tb=ne.compareByGeneratedPositionsDeflatedNoLine;function vF(e,t){let r=e.length,n=e.length-t;if(!(n<=1))if(n==2){let i=e[t],s=e[t+1];Tb(i,s)>0&&(e[t]=s,e[t+1]=i)}else if(n<20)for(let i=t;i<r;i++)for(let s=i;s>t;s--){let o=e[s-1],a=e[s];if(Tb(o,a)<=0)break;e[s-1]=a,e[s]=o}else Vu(e,Tb,t)}or.prototype._parseMappings=function(t,r){var n=1,i=0,s=0,o=0,a=0,c=0,u=t.length,l=0,p={},d={},h=[],m=[],g,y,b,v,C;let x=0;for(;l<u;)if(t.charAt(l)===";")n++,l++,i=0,vF(m,x),x=m.length;else if(t.charAt(l)===",")l++;else{for(g=new DF,g.generatedLine=n,v=l;v<u&&!this._charIsMappingSeparator(t,v);v++);for(y=t.slice(l,v),b=[];l<v;)AV.decode(t,l,d),C=d.value,l=d.rest,b.push(C);if(b.length===2)throw new Error("Found a source, but no line and column");if(b.length===3)throw new Error("Found a source and line, but no column");if(g.generatedColumn=i+b[0],i=g.generatedColumn,b.length>1&&(g.source=a+b[1],a+=b[1],g.originalLine=s+b[2],s=g.originalLine,g.originalLine+=1,g.originalColumn=o+b[3],o=g.originalColumn,b.length>4&&(g.name=c+b[4],c+=b[4])),m.push(g),typeof g.originalLine=="number"){let E=g.source;for(;h.length<=E;)h.push(null);h[E]===null&&(h[E]=[]),h[E].push(g)}}vF(m,x),this.__generatedMappings=m;for(var D=0;D<h.length;D++)h[D]!=null&&Vu(h[D],ne.compareByOriginalPositionsNoSource);this.__originalMappings=[].concat(...h)};or.prototype._findMapping=function(t,r,n,i,s,o){if(t[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+t[n]);if(t[i]<0)throw new TypeError("Column must be greater than or equal to 0, got "+t[i]);return Ab.search(t,r,s,o)};or.prototype.computeColumnSpans=function(){for(var t=0;t<this._generatedMappings.length;++t){var r=this._generatedMappings[t];if(t+1<this._generatedMappings.length){var n=this._generatedMappings[t+1];if(r.generatedLine===n.generatedLine){r.lastGeneratedColumn=n.generatedColumn-1;continue}}r.lastGeneratedColumn=1/0}};or.prototype.originalPositionFor=function(t){var r={generatedLine:ne.getArg(t,"line"),generatedColumn:ne.getArg(t,"column")},n=this._findMapping(r,this._generatedMappings,"generatedLine","generatedColumn",ne.compareByGeneratedPositionsDeflated,ne.getArg(t,"bias",ht.GREATEST_LOWER_BOUND));if(n>=0){var i=this._generatedMappings[n];if(i.generatedLine===r.generatedLine){var s=ne.getArg(i,"source",null);s!==null&&(s=this._sources.at(s),s=ne.computeSourceURL(this.sourceRoot,s,this._sourceMapURL));var o=ne.getArg(i,"name",null);return o!==null&&(o=this._names.at(o)),{source:s,line:ne.getArg(i,"originalLine",null),column:ne.getArg(i,"originalColumn",null),name:o}}}return{source:null,line:null,column:null,name:null}};or.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(t){return t==null}):!1};or.prototype.sourceContentFor=function(t,r){if(!this.sourcesContent)return null;var n=this._findSourceIndex(t);if(n>=0)return this.sourcesContent[n];var i=t;this.sourceRoot!=null&&(i=ne.relative(this.sourceRoot,i));var s;if(this.sourceRoot!=null&&(s=ne.urlParse(this.sourceRoot))){var o=i.replace(/^file:\/\//,"");if(s.scheme=="file"&&this._sources.has(o))return this.sourcesContent[this._sources.indexOf(o)];if((!s.path||s.path=="/")&&this._sources.has("/"+i))return this.sourcesContent[this._sources.indexOf("/"+i)]}if(r)return null;throw new Error('"'+i+'" is not in the SourceMap.')};or.prototype.generatedPositionFor=function(t){var r=ne.getArg(t,"source");if(r=this._findSourceIndex(r),r<0)return{line:null,column:null,lastColumn:null};var n={source:r,originalLine:ne.getArg(t,"line"),originalColumn:ne.getArg(t,"column")},i=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",ne.compareByOriginalPositions,ne.getArg(t,"bias",ht.GREATEST_LOWER_BOUND));if(i>=0){var s=this._originalMappings[i];if(s.source===n.source)return{line:ne.getArg(s,"generatedLine",null),column:ne.getArg(s,"generatedColumn",null),lastColumn:ne.getArg(s,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};sf.BasicSourceMapConsumer=or;function Kn(e,t){var r=e;typeof e=="string"&&(r=ne.parseSourceMapInput(e));var n=ne.getArg(r,"version"),i=ne.getArg(r,"sections");if(n!=this._version)throw new Error("Unsupported version: "+n);this._sources=new Ga,this._names=new Ga;var s={line:-1,column:0};this._sections=i.map(function(o){if(o.url)throw new Error("Support for url field in sections not implemented.");var a=ne.getArg(o,"offset"),c=ne.getArg(a,"line"),u=ne.getArg(a,"column");if(c<s.line||c===s.line&&u<s.column)throw new Error("Section offsets must be ordered and non-overlapping.");return s=a,{generatedOffset:{generatedLine:c+1,generatedColumn:u+1},consumer:new ht(ne.getArg(o,"map"),t)}})}Kn.prototype=Object.create(ht.prototype);Kn.prototype.constructor=ht;Kn.prototype._version=3;Object.defineProperty(Kn.prototype,"sources",{get:function(){for(var e=[],t=0;t<this._sections.length;t++)for(var r=0;r<this._sections[t].consumer.sources.length;r++)e.push(this._sections[t].consumer.sources[r]);return e}});Kn.prototype.originalPositionFor=function(t){var r={generatedLine:ne.getArg(t,"line"),generatedColumn:ne.getArg(t,"column")},n=Ab.search(r,this._sections,function(s,o){var a=s.generatedLine-o.generatedOffset.generatedLine;return a||s.generatedColumn-o.generatedOffset.generatedColumn}),i=this._sections[n];return i?i.consumer.originalPositionFor({line:r.generatedLine-(i.generatedOffset.generatedLine-1),column:r.generatedColumn-(i.generatedOffset.generatedLine===r.generatedLine?i.generatedOffset.generatedColumn-1:0),bias:t.bias}):{source:null,line:null,column:null,name:null}};Kn.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(t){return t.consumer.hasContentsOfAllSources()})};Kn.prototype.sourceContentFor=function(t,r){for(var n=0;n<this._sections.length;n++){var i=this._sections[n],s=i.consumer.sourceContentFor(t,!0);if(s||s==="")return s}if(r)return null;throw new Error('"'+t+'" is not in the SourceMap.')};Kn.prototype.generatedPositionFor=function(t){for(var r=0;r<this._sections.length;r++){var n=this._sections[r];if(n.consumer._findSourceIndex(ne.getArg(t,"source"))!==-1){var i=n.consumer.generatedPositionFor(t);if(i){var s={line:i.line+(n.generatedOffset.generatedLine-1),column:i.column+(n.generatedOffset.generatedLine===i.line?n.generatedOffset.generatedColumn-1:0)};return s}}}return{line:null,column:null}};Kn.prototype._parseMappings=function(t,r){this.__generatedMappings=[],this.__originalMappings=[];for(var n=0;n<this._sections.length;n++)for(var i=this._sections[n],s=i.consumer._generatedMappings,o=0;o<s.length;o++){var a=s[o],c=i.consumer._sources.at(a.source);c!==null&&(c=ne.computeSourceURL(i.consumer.sourceRoot,c,this._sourceMapURL)),this._sources.add(c),c=this._sources.indexOf(c);var u=null;a.name&&(u=i.consumer._names.at(a.name),this._names.add(u),u=this._names.indexOf(u));var l={source:c,generatedLine:a.generatedLine+(i.generatedOffset.generatedLine-1),generatedColumn:a.generatedColumn+(i.generatedOffset.generatedLine===a.generatedLine?i.generatedOffset.generatedColumn-1:0),originalLine:a.originalLine,originalColumn:a.originalColumn,name:u};this.__generatedMappings.push(l),typeof l.originalLine=="number"&&this.__originalMappings.push(l)}Vu(this.__generatedMappings,ne.compareByGeneratedPositionsDeflated),Vu(this.__originalMappings,ne.compareByOriginalPositions)};sf.IndexedSourceMapConsumer=Kn});var wF=w(EF=>{f();var PV=wb().SourceMapGenerator,of=qa(),FV=/(\r?\n)/,_V=10,za="$$$isSourceNode$$$";function on(e,t,r,n,i){this.children=[],this.sourceContents={},this.line=e??null,this.column=t??null,this.source=r??null,this.name=i??null,this[za]=!0,n!=null&&this.add(n)}on.fromStringWithSourceMap=function(t,r,n){var i=new on,s=t.split(FV),o=0,a=function(){var d=m(),h=m()||"";return d+h;function m(){return o<s.length?s[o++]:void 0}},c=1,u=0,l=null;return r.eachMapping(function(d){if(l!==null)if(c<d.generatedLine)p(l,a()),c++,u=0;else{var h=s[o]||"",m=h.substr(0,d.generatedColumn-u);s[o]=h.substr(d.generatedColumn-u),u=d.generatedColumn,p(l,m),l=d;return}for(;c<d.generatedLine;)i.add(a()),c++;if(u<d.generatedColumn){var h=s[o]||"";i.add(h.substr(0,d.generatedColumn)),s[o]=h.substr(d.generatedColumn),u=d.generatedColumn}l=d},this),o<s.length&&(l&&p(l,a()),i.add(s.splice(o).join(""))),r.sources.forEach(function(d){var h=r.sourceContentFor(d);h!=null&&(n!=null&&(d=of.join(n,d)),i.setSourceContent(d,h))}),i;function p(d,h){if(d===null||d.source===void 0)i.add(h);else{var m=n?of.join(n,d.source):d.source;i.add(new on(d.originalLine,d.originalColumn,m,h,d.name))}}};on.prototype.add=function(t){if(Array.isArray(t))t.forEach(function(r){this.add(r)},this);else if(t[za]||typeof t=="string")t&&this.children.push(t);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+t);return this};on.prototype.prepend=function(t){if(Array.isArray(t))for(var r=t.length-1;r>=0;r--)this.prepend(t[r]);else if(t[za]||typeof t=="string")this.children.unshift(t);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+t);return this};on.prototype.walk=function(t){for(var r,n=0,i=this.children.length;n<i;n++)r=this.children[n],r[za]?r.walk(t):r!==""&&t(r,{source:this.source,line:this.line,column:this.column,name:this.name})};on.prototype.join=function(t){var r,n,i=this.children.length;if(i>0){for(r=[],n=0;n<i-1;n++)r.push(this.children[n]),r.push(t);r.push(this.children[n]),this.children=r}return this};on.prototype.replaceRight=function(t,r){var n=this.children[this.children.length-1];return n[za]?n.replaceRight(t,r):typeof n=="string"?this.children[this.children.length-1]=n.replace(t,r):this.children.push("".replace(t,r)),this};on.prototype.setSourceContent=function(t,r){this.sourceContents[of.toSetString(t)]=r};on.prototype.walkSourceContents=function(t){for(var r=0,n=this.children.length;r<n;r++)this.children[r][za]&&this.children[r].walkSourceContents(t);for(var i=Object.keys(this.sourceContents),r=0,n=i.length;r<n;r++)t(of.fromSetString(i[r]),this.sourceContents[i[r]])};on.prototype.toString=function(){var t="";return this.walk(function(r){t+=r}),t};on.prototype.toStringWithSourceMap=function(t){var r={code:"",line:1,column:0},n=new PV(t),i=!1,s=null,o=null,a=null,c=null;return this.walk(function(u,l){r.code+=u,l.source!==null&&l.line!==null&&l.column!==null?((s!==l.source||o!==l.line||a!==l.column||c!==l.name)&&n.addMapping({source:l.source,original:{line:l.line,column:l.column},generated:{line:r.line,column:r.column},name:l.name}),s=l.source,o=l.line,a=l.column,c=l.name,i=!0):i&&(n.addMapping({generated:{line:r.line,column:r.column}}),s=null,i=!1);for(var p=0,d=u.length;p<d;p++)u.charCodeAt(p)===_V?(r.line++,r.column=0,p+1===d?(s=null,i=!1):i&&n.addMapping({source:l.source,original:{line:l.line,column:l.column},generated:{line:r.line,column:r.column},name:l.name})):r.column++}),this.walkSourceContents(function(u,l){n.setSourceContent(u,l)}),{code:r.code,map:n}};EF.SourceNode=on});var SF=w(af=>{f();af.SourceMapGenerator=wb().SourceMapGenerator;af.SourceMapConsumer=CF().SourceMapConsumer;af.SourceNode=wF().SourceNode});var r_=w(nl=>{"use strict";f();Object.defineProperty(nl,"__esModule",{value:!0});function IV(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.includes(n))continue;r[n]=e[n]}return r}var vi=class{constructor(t,r,n){this.line=void 0,this.column=void 0,this.index=void 0,this.line=t,this.column=r,this.index=n}},Ya=class{constructor(t,r){this.start=void 0,this.end=void 0,this.filename=void 0,this.identifierName=void 0,this.start=t,this.end=r}};function Tr(e,t){let{line:r,column:n,index:i}=e;return new vi(r,n+t,i+t)}var TF="BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED",kV={ImportMetaOutsideModule:{message:`import.meta may appear only with 'sourceType: "module"'`,code:TF},ImportOutsideModule:{message:`'import' and 'export' may appear only with 'sourceType: "module"'`,code:TF}},AF={ArrayPattern:"array destructuring pattern",AssignmentExpression:"assignment expression",AssignmentPattern:"assignment expression",ArrowFunctionExpression:"arrow function expression",ConditionalExpression:"conditional expression",CatchClause:"catch clause",ForOfStatement:"for-of statement",ForInStatement:"for-in statement",ForStatement:"for-loop",FormalParameters:"function parameter list",Identifier:"identifier",ImportSpecifier:"import specifier",ImportDefaultSpecifier:"import default specifier",ImportNamespaceSpecifier:"import namespace specifier",ObjectPattern:"object destructuring pattern",ParenthesizedExpression:"parenthesized expression",RestElement:"rest element",UpdateExpression:{true:"prefix operation",false:"postfix operation"},VariableDeclarator:"variable declaration",YieldExpression:"yield expression"},lf=e=>e.type==="UpdateExpression"?AF.UpdateExpression[`${e.prefix}`]:AF[e.type],NV={AccessorIsGenerator:({kind:e})=>`A ${e}ter cannot be a generator.`,ArgumentsInClass:"'arguments' is only allowed in functions and class methods.",AsyncFunctionInSingleStatementContext:"Async functions can only be declared at the top level or inside a block.",AwaitBindingIdentifier:"Can not use 'await' as identifier inside an async function.",AwaitBindingIdentifierInStaticBlock:"Can not use 'await' as identifier inside a static block.",AwaitExpressionFormalParameter:"'await' is not allowed in async function parameters.",AwaitUsingNotInAsyncContext:"'await using' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncContext:"'await' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncFunction:"'await' is only allowed within async functions.",BadGetterArity:"A 'get' accessor must not have any formal parameters.",BadSetterArity:"A 'set' accessor must have exactly one formal parameter.",BadSetterRestParameter:"A 'set' accessor function argument must not be a rest parameter.",ConstructorClassField:"Classes may not have a field named 'constructor'.",ConstructorClassPrivateField:"Classes may not have a private field named '#constructor'.",ConstructorIsAccessor:"Class constructor may not be an accessor.",ConstructorIsAsync:"Constructor can't be an async function.",ConstructorIsGenerator:"Constructor can't be a generator.",DeclarationMissingInitializer:({kind:e})=>`Missing initializer in ${e} declaration.`,DecoratorArgumentsOutsideParentheses:"Decorator arguments must be moved inside parentheses: use '@(decorator(args))' instead of '@(decorator)(args)'.",DecoratorBeforeExport:"Decorators must be placed *before* the 'export' keyword. Remove the 'decoratorsBeforeExport: true' option to use the 'export @decorator class {}' syntax.",DecoratorsBeforeAfterExport:"Decorators can be placed *either* before or after the 'export' keyword, but not in both locations at the same time.",DecoratorConstructor:"Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?",DecoratorExportClass:"Decorators must be placed *after* the 'export' keyword. Remove the 'decoratorsBeforeExport: false' option to use the '@decorator export class {}' syntax.",DecoratorSemicolon:"Decorators must not be followed by a semicolon.",DecoratorStaticBlock:"Decorators can't be used with a static block.",DeferImportRequiresNamespace:'Only `import defer * as x from "./module"` is valid.',DeletePrivateField:"Deleting a private field is not allowed.",DestructureNamedImport:"ES2015 named imports do not destructure. Use another statement for destructuring after the import.",DuplicateConstructor:"Duplicate constructor in the same class.",DuplicateDefaultExport:"Only one default export allowed per module.",DuplicateExport:({exportName:e})=>`\`${e}\` has already been exported. Exported identifiers must be unique.`,DuplicateProto:"Redefinition of __proto__ property.",DuplicateRegExpFlags:"Duplicate regular expression flag.",DynamicImportPhaseRequiresImportExpressions:({phase:e})=>`'import.${e}(...)' can only be parsed when using the 'createImportExpressions' option.`,ElementAfterRest:"Rest element must be last element.",EscapedCharNotAnIdentifier:"Invalid Unicode escape.",ExportBindingIsString:({localName:e,exportName:t})=>`A string literal cannot be used as an exported binding without \`from\`.
15
+ https://github.com/highlightjs/highlight.js/issues/2277`),M=L,R=k),$===void 0&&($=!0);let K={code:R,language:M};P("before:highlight",K);let W=K.result?K.result:p(K.language,K.code,$);return W.code=K.code,P("after:highlight",W),W}function p(L,k,$,R){let M=Object.create(null);function K(ee,oe){return ee.keywords[oe]}function W(){if(!ye.keywords){nr.addText(dt);return}let ee=0;ye.keywordPatternRe.lastIndex=0;let oe=ye.keywordPatternRe.exec(dt),we="";for(;oe;){we+=dt.substring(ee,oe.index);let Je=ur.case_insensitive?oe[0].toLowerCase():oe[0],lr=K(ye,Je);if(lr){let[ji,uj]=lr;if(nr.addText(we),we="",M[Je]=(M[Je]||0)+1,M[Je]<=HK&&(id+=uj),ji.startsWith("_"))we+=oe[0];else{let lj=ur.classNameAliases[ji]||ji;Z(oe[0],lj)}}else we+=oe[0];ee=ye.keywordPatternRe.lastIndex,oe=ye.keywordPatternRe.exec(dt)}we+=dt.substring(ee),nr.addText(we)}function ce(){if(dt==="")return;let ee=null;if(typeof ye.subLanguage=="string"){if(!t[ye.subLanguage]){nr.addText(dt);return}ee=p(ye.subLanguage,dt,!0,lS[ye.subLanguage]),lS[ye.subLanguage]=ee._top}else ee=h(dt,ye.subLanguage.length?ye.subLanguage:null);ye.relevance>0&&(id+=ee.relevance),nr.__addSublanguage(ee._emitter,ee.language)}function se(){ye.subLanguage!=null?ce():W(),dt=""}function Z(ee,oe){ee!==""&&(nr.startScope(oe),nr.addText(ee),nr.endScope())}function xt(ee,oe){let we=1,Je=oe.length-1;for(;we<=Je;){if(!ee._emit[we]){we++;continue}let lr=ur.classNameAliases[ee[we]]||ee[we],ji=oe[we];lr?Z(ji,lr):(dt=ji,W(),dt=""),we++}}function Le(ee,oe){return ee.scope&&typeof ee.scope=="string"&&nr.openNode(ur.classNameAliases[ee.scope]||ee.scope),ee.beginScope&&(ee.beginScope._wrap?(Z(dt,ur.classNameAliases[ee.beginScope._wrap]||ee.beginScope._wrap),dt=""):ee.beginScope._multi&&(xt(ee.beginScope,oe),dt="")),ye=Object.create(ee,{parent:{value:ye}}),ye}function J(ee,oe,we){let Je=cK(ee.endRe,we);if(Je){if(ee["on:end"]){let lr=new Yd(ee);ee["on:end"](oe,lr),lr.isMatchIgnored&&(Je=!1)}if(Je){for(;ee.endsParent&&ee.parent;)ee=ee.parent;return ee}}if(ee.endsWithParent)return J(ee.parent,oe,we)}function $e(ee){return ye.matcher.regexIndex===0?(dt+=ee[0],1):(Mg=!0,0)}function X(ee){let oe=ee[0],we=ee.rule,Je=new Yd(we),lr=[we.__beforeBegin,we["on:begin"]];for(let ji of lr)if(ji&&(ji(ee,Je),Je.isMatchIgnored))return $e(oe);return we.skip?dt+=oe:(we.excludeBegin&&(dt+=oe),se(),!we.returnBegin&&!we.excludeBegin&&(dt=oe)),Le(we,ee),we.returnBegin?0:oe.length}function me(ee){let oe=ee[0],we=k.substring(ee.index),Je=J(ye,ee,we);if(!Je)return vP;let lr=ye;ye.endScope&&ye.endScope._wrap?(se(),Z(oe,ye.endScope._wrap)):ye.endScope&&ye.endScope._multi?(se(),xt(ye.endScope,ee)):lr.skip?dt+=oe:(lr.returnEnd||lr.excludeEnd||(dt+=oe),se(),lr.excludeEnd&&(dt=oe));do ye.scope&&nr.closeNode(),!ye.skip&&!ye.subLanguage&&(id+=ye.relevance),ye=ye.parent;while(ye!==Je.parent);return Je.starts&&Le(Je.starts,ee),lr.returnEnd?0:oe.length}function ue(){let ee=[];for(let oe=ye;oe!==ur;oe=oe.parent)oe.scope&&ee.unshift(oe.scope);ee.forEach(oe=>nr.openNode(oe))}let pt={};function Ze(ee,oe){let we=oe&&oe[0];if(dt+=ee,we==null)return se(),0;if(pt.type==="begin"&&oe.type==="end"&&pt.index===oe.index&&we===""){if(dt+=k.slice(oe.index,oe.index+1),!i){let Je=new Error(`0 width match regex (${L})`);throw Je.languageName=L,Je.badRule=pt.rule,Je}return 1}if(pt=oe,oe.type==="begin")return X(oe);if(oe.type==="illegal"&&!$){let Je=new Error('Illegal lexeme "'+we+'" for mode "'+(ye.scope||"<unnamed>")+'"');throw Je.mode=ye,Je}else if(oe.type==="end"){let Je=me(oe);if(Je!==vP)return Je}if(oe.type==="illegal"&&we==="")return 1;if(Bg>1e5&&Bg>oe.index*3)throw new Error("potential infinite loop, way more iterations than matches");return dt+=we,we.length}let ur=I(L);if(!ur)throw To(s.replace("{}",L)),new Error('Unknown language: "'+L+'"');let ya=qK(ur),Og="",ye=R||ya,lS={},nr=new a.__emitter(a);ue();let dt="",id=0,mo=0,Bg=0,Mg=!1;try{if(ur.__emitTokens)ur.__emitTokens(k,nr);else{for(ye.matcher.considerAll();;){Bg++,Mg?Mg=!1:ye.matcher.considerAll(),ye.matcher.lastIndex=mo;let ee=ye.matcher.exec(k);if(!ee)break;let oe=k.substring(mo,ee.index),we=Ze(oe,ee);mo=ee.index+we}Ze(k.substring(mo))}return nr.finalize(),Og=nr.toHTML(),{language:L,value:Og,relevance:id,illegal:!1,_emitter:nr,_top:ye}}catch(ee){if(ee.message&&ee.message.includes("Illegal"))return{language:L,value:tb(k),illegal:!0,relevance:0,_illegalBy:{message:ee.message,index:mo,context:k.slice(mo-100,mo+100),mode:ee.mode,resultSoFar:Og},_emitter:nr};if(i)return{language:L,value:tb(k),illegal:!1,relevance:0,errorRaised:ee,_emitter:nr,_top:ye};throw ee}}function d(L){let k={value:tb(L),illegal:!1,relevance:0,_top:o,_emitter:new a.__emitter(a)};return k._emitter.addText(L),k}function h(L,k){k=k||a.languages||Object.keys(t);let $=d(L),R=k.filter(I).filter(T).map(se=>p(se,L,!1));R.unshift($);let M=R.sort((se,Z)=>{if(se.relevance!==Z.relevance)return Z.relevance-se.relevance;if(se.language&&Z.language){if(I(se.language).supersetOf===Z.language)return 1;if(I(Z.language).supersetOf===se.language)return-1}return 0}),[K,W]=M,ce=K;return ce.secondBest=W,ce}function m(L,k,$){let R=k&&r[k]||$;L.classList.add("hljs"),L.classList.add(`language-${R}`)}function g(L){let k=null,$=u(L);if(c($))return;if(P("before:highlightElement",{el:L,language:$}),L.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",L);return}if(L.children.length>0&&(a.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(L)),a.throwUnescapedHTML))throw new sb("One of your code blocks includes unescaped HTML.",L.innerHTML);k=L;let R=k.textContent,M=$?l(R,{language:$,ignoreIllegals:!0}):h(R);L.innerHTML=M.value,L.dataset.highlighted="yes",m(L,$,M.language),L.result={language:M.language,re:M.relevance,relevance:M.relevance},M.secondBest&&(L.secondBest={language:M.secondBest.language,relevance:M.secondBest.relevance}),P("after:highlightElement",{el:L,result:M,text:R})}function y(L){a=xP(a,L)}let b=()=>{x(),Ma("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function v(){x(),Ma("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let C=!1;function x(){if(document.readyState==="loading"){C=!0;return}document.querySelectorAll(a.cssSelector).forEach(g)}function D(){C&&x()}typeof window<"u"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",D,!1);function E(L,k){let $=null;try{$=k(e)}catch(R){if(To("Language definition for '{}' could not be registered.".replace("{}",L)),i)To(R);else throw R;$=o}$.name||($.name=L),t[L]=$,$.rawDefinition=k.bind(null,e),$.aliases&&A($.aliases,{languageName:L})}function S(L){delete t[L];for(let k of Object.keys(r))r[k]===L&&delete r[k]}function F(){return Object.keys(t)}function I(L){return L=(L||"").toLowerCase(),t[L]||t[r[L]]}function A(L,{languageName:k}){typeof L=="string"&&(L=[L]),L.forEach($=>{r[$.toLowerCase()]=k})}function T(L){let k=I(L);return k&&!k.disableAutodetect}function G(L){L["before:highlightBlock"]&&!L["before:highlightElement"]&&(L["before:highlightElement"]=k=>{L["before:highlightBlock"](Object.assign({block:k.el},k))}),L["after:highlightBlock"]&&!L["after:highlightElement"]&&(L["after:highlightElement"]=k=>{L["after:highlightBlock"](Object.assign({block:k.el},k))})}function V(L){G(L),n.push(L)}function Y(L){let k=n.indexOf(L);k!==-1&&n.splice(k,1)}function P(L,k){let $=L;n.forEach(function(R){R[$]&&R[$](k)})}function N(L){return Ma("10.7.0","highlightBlock will be removed entirely in v12.0"),Ma("10.7.0","Please use highlightElement now."),g(L)}Object.assign(e,{highlight:l,highlightAuto:h,highlightAll:x,highlightElement:g,highlightBlock:N,configure:y,initHighlighting:b,initHighlightingOnLoad:v,registerLanguage:E,unregisterLanguage:S,listLanguages:F,getLanguage:I,registerAliases:A,autoDetection:T,inherit:xP,addPlugin:V,removePlugin:Y}),e.debugMode=function(){i=!1},e.safeMode=function(){i=!0},e.versionString=zK,e.regex={concat:Ao,lookahead:EP,either:ob,optional:oK,anyNumberOfTimes:sK};for(let L in Wd)typeof Wd[L]=="object"&&DP(Wd[L]);return Object.assign(e,Wd),e},La=kP({});La.newInstance=()=>kP({});NP.exports=La;La.HighlightJS=La;La.default=La});var tF=w(gb=>{f();var eF="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");gb.encode=function(e){if(0<=e&&e<eF.length)return eF[e];throw new TypeError("Must be between 0 and 63: "+e)};gb.decode=function(e){var t=65,r=90,n=97,i=122,s=48,o=57,a=43,c=47,u=26,l=52;return t<=e&&e<=r?e-t:n<=e&&e<=i?e-n+u:s<=e&&e<=o?e-s+l:e==a?62:e==c?63:-1}});var xb=w(bb=>{f();var rF=tF(),yb=5,nF=1<<yb,iF=nF-1,sF=nF;function aV(e){return e<0?(-e<<1)+1:(e<<1)+0}function cV(e){var t=(e&1)===1,r=e>>1;return t?-r:r}bb.encode=function(t){var r="",n,i=aV(t);do n=i&iF,i>>>=yb,i>0&&(n|=sF),r+=rF.encode(n);while(i>0);return r};bb.decode=function(t,r,n){var i=t.length,s=0,o=0,a,c;do{if(r>=i)throw new Error("Expected more digits in base 64 VLQ value.");if(c=rF.decode(t.charCodeAt(r++)),c===-1)throw new Error("Invalid base64 digit: "+t.charAt(r-1));a=!!(c&sF),c&=iF,s=s+(c<<o),o+=yb}while(a);n.value=cV(s),n.rest=r}});var qa=w(Kt=>{f();function uV(e,t,r){if(t in e)return e[t];if(arguments.length===3)return r;throw new Error('"'+t+'" is a required argument.')}Kt.getArg=uV;var oF=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,lV=/^data:.+\,.+$/;function Hu(e){var t=e.match(oF);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}Kt.urlParse=Hu;function ja(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}Kt.urlGenerate=ja;var pV=32;function dV(e){var t=[];return function(r){for(var n=0;n<t.length;n++)if(t[n].input===r){var i=t[0];return t[0]=t[n],t[n]=i,t[0].result}var s=e(r);return t.unshift({input:r,result:s}),t.length>pV&&t.pop(),s}}var vb=dV(function(t){var r=t,n=Hu(t);if(n){if(!n.path)return t;r=n.path}for(var i=Kt.isAbsolute(r),s=[],o=0,a=0;;)if(o=a,a=r.indexOf("/",o),a===-1){s.push(r.slice(o));break}else for(s.push(r.slice(o,a));a<r.length&&r[a]==="/";)a++;for(var c,u=0,a=s.length-1;a>=0;a--)c=s[a],c==="."?s.splice(a,1):c===".."?u++:u>0&&(c===""?(s.splice(a+1,u),u=0):(s.splice(a,2),u--));return r=s.join("/"),r===""&&(r=i?"/":"."),n?(n.path=r,ja(n)):r});Kt.normalize=vb;function aF(e,t){e===""&&(e="."),t===""&&(t=".");var r=Hu(t),n=Hu(e);if(n&&(e=n.path||"/"),r&&!r.scheme)return n&&(r.scheme=n.scheme),ja(r);if(r||t.match(lV))return t;if(n&&!n.host&&!n.path)return n.host=t,ja(n);var i=t.charAt(0)==="/"?t:vb(e.replace(/\/+$/,"")+"/"+t);return n?(n.path=i,ja(n)):i}Kt.join=aF;Kt.isAbsolute=function(e){return e.charAt(0)==="/"||oF.test(e)};function fV(e,t){e===""&&(e="."),e=e.replace(/\/$/,"");for(var r=0;t.indexOf(e+"/")!==0;){var n=e.lastIndexOf("/");if(n<0||(e=e.slice(0,n),e.match(/^([^\/]+:\/)?\/*$/)))return t;++r}return Array(r+1).join("../")+t.substr(e.length+1)}Kt.relative=fV;var cF=function(){var e=Object.create(null);return!("__proto__"in e)}();function uF(e){return e}function mV(e){return lF(e)?"$"+e:e}Kt.toSetString=cF?uF:mV;function hV(e){return lF(e)?e.slice(1):e}Kt.fromSetString=cF?uF:hV;function lF(e){if(!e)return!1;var t=e.length;if(t<9||e.charCodeAt(t-1)!==95||e.charCodeAt(t-2)!==95||e.charCodeAt(t-3)!==111||e.charCodeAt(t-4)!==116||e.charCodeAt(t-5)!==111||e.charCodeAt(t-6)!==114||e.charCodeAt(t-7)!==112||e.charCodeAt(t-8)!==95||e.charCodeAt(t-9)!==95)return!1;for(var r=t-10;r>=0;r--)if(e.charCodeAt(r)!==36)return!1;return!0}function gV(e,t,r){var n=Wi(e.source,t.source);return n!==0||(n=e.originalLine-t.originalLine,n!==0)||(n=e.originalColumn-t.originalColumn,n!==0||r)||(n=e.generatedColumn-t.generatedColumn,n!==0)||(n=e.generatedLine-t.generatedLine,n!==0)?n:Wi(e.name,t.name)}Kt.compareByOriginalPositions=gV;function yV(e,t,r){var n;return n=e.originalLine-t.originalLine,n!==0||(n=e.originalColumn-t.originalColumn,n!==0||r)||(n=e.generatedColumn-t.generatedColumn,n!==0)||(n=e.generatedLine-t.generatedLine,n!==0)?n:Wi(e.name,t.name)}Kt.compareByOriginalPositionsNoSource=yV;function bV(e,t,r){var n=e.generatedLine-t.generatedLine;return n!==0||(n=e.generatedColumn-t.generatedColumn,n!==0||r)||(n=Wi(e.source,t.source),n!==0)||(n=e.originalLine-t.originalLine,n!==0)||(n=e.originalColumn-t.originalColumn,n!==0)?n:Wi(e.name,t.name)}Kt.compareByGeneratedPositionsDeflated=bV;function xV(e,t,r){var n=e.generatedColumn-t.generatedColumn;return n!==0||r||(n=Wi(e.source,t.source),n!==0)||(n=e.originalLine-t.originalLine,n!==0)||(n=e.originalColumn-t.originalColumn,n!==0)?n:Wi(e.name,t.name)}Kt.compareByGeneratedPositionsDeflatedNoLine=xV;function Wi(e,t){return e===t?0:e===null?1:t===null?-1:e>t?1:-1}function vV(e,t){var r=e.generatedLine-t.generatedLine;return r!==0||(r=e.generatedColumn-t.generatedColumn,r!==0)||(r=Wi(e.source,t.source),r!==0)||(r=e.originalLine-t.originalLine,r!==0)||(r=e.originalColumn-t.originalColumn,r!==0)?r:Wi(e.name,t.name)}Kt.compareByGeneratedPositionsInflated=vV;function DV(e){return JSON.parse(e.replace(/^\)]}'[^\n]*\n/,""))}Kt.parseSourceMapInput=DV;function CV(e,t,r){if(t=t||"",e&&(e[e.length-1]!=="/"&&t[0]!=="/"&&(e+="/"),t=e+t),r){var n=Hu(r);if(!n)throw new Error("sourceMapURL could not be parsed");if(n.path){var i=n.path.lastIndexOf("/");i>=0&&(n.path=n.path.substring(0,i+1))}t=aF(ja(n),t)}return vb(t)}Kt.computeSourceURL=CV});var Eb=w(pF=>{f();var Db=qa(),Cb=Object.prototype.hasOwnProperty,Po=typeof Map<"u";function Yi(){this._array=[],this._set=Po?new Map:Object.create(null)}Yi.fromArray=function(t,r){for(var n=new Yi,i=0,s=t.length;i<s;i++)n.add(t[i],r);return n};Yi.prototype.size=function(){return Po?this._set.size:Object.getOwnPropertyNames(this._set).length};Yi.prototype.add=function(t,r){var n=Po?t:Db.toSetString(t),i=Po?this.has(t):Cb.call(this._set,n),s=this._array.length;(!i||r)&&this._array.push(t),i||(Po?this._set.set(t,s):this._set[n]=s)};Yi.prototype.has=function(t){if(Po)return this._set.has(t);var r=Db.toSetString(t);return Cb.call(this._set,r)};Yi.prototype.indexOf=function(t){if(Po){var r=this._set.get(t);if(r>=0)return r}else{var n=Db.toSetString(t);if(Cb.call(this._set,n))return this._set[n]}throw new Error('"'+t+'" is not in the set.')};Yi.prototype.at=function(t){if(t>=0&&t<this._array.length)return this._array[t];throw new Error("No element indexed by "+t)};Yi.prototype.toArray=function(){return this._array.slice()};pF.ArraySet=Yi});var mF=w(fF=>{f();var dF=qa();function EV(e,t){var r=e.generatedLine,n=t.generatedLine,i=e.generatedColumn,s=t.generatedColumn;return n>r||n==r&&s>=i||dF.compareByGeneratedPositionsInflated(e,t)<=0}function rf(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}rf.prototype.unsortedForEach=function(t,r){this._array.forEach(t,r)};rf.prototype.add=function(t){EV(this._last,t)?(this._last=t,this._array.push(t)):(this._sorted=!1,this._array.push(t))};rf.prototype.toArray=function(){return this._sorted||(this._array.sort(dF.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};fF.MappingList=rf});var wb=w(hF=>{f();var Ku=xb(),Nt=qa(),nf=Eb().ArraySet,wV=mF().MappingList;function En(e){e||(e={}),this._file=Nt.getArg(e,"file",null),this._sourceRoot=Nt.getArg(e,"sourceRoot",null),this._skipValidation=Nt.getArg(e,"skipValidation",!1),this._ignoreInvalidMapping=Nt.getArg(e,"ignoreInvalidMapping",!1),this._sources=new nf,this._names=new nf,this._mappings=new wV,this._sourcesContents=null}En.prototype._version=3;En.fromSourceMap=function(t,r){var n=t.sourceRoot,i=new En(Object.assign(r||{},{file:t.file,sourceRoot:n}));return t.eachMapping(function(s){var o={generated:{line:s.generatedLine,column:s.generatedColumn}};s.source!=null&&(o.source=s.source,n!=null&&(o.source=Nt.relative(n,o.source)),o.original={line:s.originalLine,column:s.originalColumn},s.name!=null&&(o.name=s.name)),i.addMapping(o)}),t.sources.forEach(function(s){var o=s;n!==null&&(o=Nt.relative(n,s)),i._sources.has(o)||i._sources.add(o);var a=t.sourceContentFor(s);a!=null&&i.setSourceContent(s,a)}),i};En.prototype.addMapping=function(t){var r=Nt.getArg(t,"generated"),n=Nt.getArg(t,"original",null),i=Nt.getArg(t,"source",null),s=Nt.getArg(t,"name",null);!this._skipValidation&&this._validateMapping(r,n,i,s)===!1||(i!=null&&(i=String(i),this._sources.has(i)||this._sources.add(i)),s!=null&&(s=String(s),this._names.has(s)||this._names.add(s)),this._mappings.add({generatedLine:r.line,generatedColumn:r.column,originalLine:n!=null&&n.line,originalColumn:n!=null&&n.column,source:i,name:s}))};En.prototype.setSourceContent=function(t,r){var n=t;this._sourceRoot!=null&&(n=Nt.relative(this._sourceRoot,n)),r!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[Nt.toSetString(n)]=r):this._sourcesContents&&(delete this._sourcesContents[Nt.toSetString(n)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};En.prototype.applySourceMap=function(t,r,n){var i=r;if(r==null){if(t.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);i=t.file}var s=this._sourceRoot;s!=null&&(i=Nt.relative(s,i));var o=new nf,a=new nf;this._mappings.unsortedForEach(function(c){if(c.source===i&&c.originalLine!=null){var u=t.originalPositionFor({line:c.originalLine,column:c.originalColumn});u.source!=null&&(c.source=u.source,n!=null&&(c.source=Nt.join(n,c.source)),s!=null&&(c.source=Nt.relative(s,c.source)),c.originalLine=u.line,c.originalColumn=u.column,u.name!=null&&(c.name=u.name))}var l=c.source;l!=null&&!o.has(l)&&o.add(l);var p=c.name;p!=null&&!a.has(p)&&a.add(p)},this),this._sources=o,this._names=a,t.sources.forEach(function(c){var u=t.sourceContentFor(c);u!=null&&(n!=null&&(c=Nt.join(n,c)),s!=null&&(c=Nt.relative(s,c)),this.setSourceContent(c,u))},this)};En.prototype._validateMapping=function(t,r,n,i){if(r&&typeof r.line!="number"&&typeof r.column!="number"){var s="original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.";if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(s),!1;throw new Error(s)}if(!(t&&"line"in t&&"column"in t&&t.line>0&&t.column>=0&&!r&&!n&&!i)){if(t&&"line"in t&&"column"in t&&r&&"line"in r&&"column"in r&&t.line>0&&t.column>=0&&r.line>0&&r.column>=0&&n)return;var s="Invalid mapping: "+JSON.stringify({generated:t,source:n,original:r,name:i});if(this._ignoreInvalidMapping)return typeof console<"u"&&console.warn&&console.warn(s),!1;throw new Error(s)}};En.prototype._serializeMappings=function(){for(var t=0,r=1,n=0,i=0,s=0,o=0,a="",c,u,l,p,d=this._mappings.toArray(),h=0,m=d.length;h<m;h++){if(u=d[h],c="",u.generatedLine!==r)for(t=0;u.generatedLine!==r;)c+=";",r++;else if(h>0){if(!Nt.compareByGeneratedPositionsInflated(u,d[h-1]))continue;c+=","}c+=Ku.encode(u.generatedColumn-t),t=u.generatedColumn,u.source!=null&&(p=this._sources.indexOf(u.source),c+=Ku.encode(p-o),o=p,c+=Ku.encode(u.originalLine-1-i),i=u.originalLine-1,c+=Ku.encode(u.originalColumn-n),n=u.originalColumn,u.name!=null&&(l=this._names.indexOf(u.name),c+=Ku.encode(l-s),s=l)),a+=c}return a};En.prototype._generateSourcesContent=function(t,r){return t.map(function(n){if(!this._sourcesContents)return null;r!=null&&(n=Nt.relative(r,n));var i=Nt.toSetString(n);return Object.prototype.hasOwnProperty.call(this._sourcesContents,i)?this._sourcesContents[i]:null},this)};En.prototype.toJSON=function(){var t={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(t.file=this._file),this._sourceRoot!=null&&(t.sourceRoot=this._sourceRoot),this._sourcesContents&&(t.sourcesContent=this._generateSourcesContent(t.sources,t.sourceRoot)),t};En.prototype.toString=function(){return JSON.stringify(this.toJSON())};hF.SourceMapGenerator=En});var gF=w(Fo=>{f();Fo.GREATEST_LOWER_BOUND=1;Fo.LEAST_UPPER_BOUND=2;function Sb(e,t,r,n,i,s){var o=Math.floor((t-e)/2)+e,a=i(r,n[o],!0);return a===0?o:a>0?t-o>1?Sb(o,t,r,n,i,s):s==Fo.LEAST_UPPER_BOUND?t<n.length?t:-1:o:o-e>1?Sb(e,o,r,n,i,s):s==Fo.LEAST_UPPER_BOUND?o:e<0?-1:e}Fo.search=function(t,r,n,i){if(r.length===0)return-1;var s=Sb(-1,r.length,t,r,n,i||Fo.GREATEST_LOWER_BOUND);if(s<0)return-1;for(;s-1>=0&&n(r[s],r[s-1],!0)===0;)--s;return s}});var xF=w(bF=>{f();function SV(e){function t(i,s,o){var a=i[s];i[s]=i[o],i[o]=a}function r(i,s){return Math.round(i+Math.random()*(s-i))}function n(i,s,o,a){if(o<a){var c=r(o,a),u=o-1;t(i,c,a);for(var l=i[a],p=o;p<a;p++)s(i[p],l,!1)<=0&&(u+=1,t(i,u,p));t(i,u+1,p);var d=u+1;n(i,s,o,d-1),n(i,s,d+1,a)}}return n}function TV(e){let t=SV.toString();return new Function(`return ${t}`)()(e)}var yF=new WeakMap;bF.quickSort=function(e,t,r=0){let n=yF.get(t);n===void 0&&(n=TV(t),yF.set(t,n)),n(e,t,r,e.length-1)}});var CF=w(sf=>{f();var ne=qa(),Ab=gF(),Ga=Eb().ArraySet,AV=xb(),Vu=xF().quickSort;function ht(e,t){var r=e;return typeof e=="string"&&(r=ne.parseSourceMapInput(e)),r.sections!=null?new Kn(r,t):new or(r,t)}ht.fromSourceMap=function(e,t){return or.fromSourceMap(e,t)};ht.prototype._version=3;ht.prototype.__generatedMappings=null;Object.defineProperty(ht.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});ht.prototype.__originalMappings=null;Object.defineProperty(ht.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});ht.prototype._charIsMappingSeparator=function(t,r){var n=t.charAt(r);return n===";"||n===","};ht.prototype._parseMappings=function(t,r){throw new Error("Subclasses must implement _parseMappings")};ht.GENERATED_ORDER=1;ht.ORIGINAL_ORDER=2;ht.GREATEST_LOWER_BOUND=1;ht.LEAST_UPPER_BOUND=2;ht.prototype.eachMapping=function(t,r,n){var i=r||null,s=n||ht.GENERATED_ORDER,o;switch(s){case ht.GENERATED_ORDER:o=this._generatedMappings;break;case ht.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}for(var a=this.sourceRoot,c=t.bind(i),u=this._names,l=this._sources,p=this._sourceMapURL,d=0,h=o.length;d<h;d++){var m=o[d],g=m.source===null?null:l.at(m.source);g!==null&&(g=ne.computeSourceURL(a,g,p)),c({source:g,generatedLine:m.generatedLine,generatedColumn:m.generatedColumn,originalLine:m.originalLine,originalColumn:m.originalColumn,name:m.name===null?null:u.at(m.name)})}};ht.prototype.allGeneratedPositionsFor=function(t){var r=ne.getArg(t,"line"),n={source:ne.getArg(t,"source"),originalLine:r,originalColumn:ne.getArg(t,"column",0)};if(n.source=this._findSourceIndex(n.source),n.source<0)return[];var i=[],s=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",ne.compareByOriginalPositions,Ab.LEAST_UPPER_BOUND);if(s>=0){var o=this._originalMappings[s];if(t.column===void 0)for(var a=o.originalLine;o&&o.originalLine===a;)i.push({line:ne.getArg(o,"generatedLine",null),column:ne.getArg(o,"generatedColumn",null),lastColumn:ne.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++s];else for(var c=o.originalColumn;o&&o.originalLine===r&&o.originalColumn==c;)i.push({line:ne.getArg(o,"generatedLine",null),column:ne.getArg(o,"generatedColumn",null),lastColumn:ne.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++s]}return i};sf.SourceMapConsumer=ht;function or(e,t){var r=e;typeof e=="string"&&(r=ne.parseSourceMapInput(e));var n=ne.getArg(r,"version"),i=ne.getArg(r,"sources"),s=ne.getArg(r,"names",[]),o=ne.getArg(r,"sourceRoot",null),a=ne.getArg(r,"sourcesContent",null),c=ne.getArg(r,"mappings"),u=ne.getArg(r,"file",null);if(n!=this._version)throw new Error("Unsupported version: "+n);o&&(o=ne.normalize(o)),i=i.map(String).map(ne.normalize).map(function(l){return o&&ne.isAbsolute(o)&&ne.isAbsolute(l)?ne.relative(o,l):l}),this._names=Ga.fromArray(s.map(String),!0),this._sources=Ga.fromArray(i,!0),this._absoluteSources=this._sources.toArray().map(function(l){return ne.computeSourceURL(o,l,t)}),this.sourceRoot=o,this.sourcesContent=a,this._mappings=c,this._sourceMapURL=t,this.file=u}or.prototype=Object.create(ht.prototype);or.prototype.consumer=ht;or.prototype._findSourceIndex=function(e){var t=e;if(this.sourceRoot!=null&&(t=ne.relative(this.sourceRoot,t)),this._sources.has(t))return this._sources.indexOf(t);var r;for(r=0;r<this._absoluteSources.length;++r)if(this._absoluteSources[r]==e)return r;return-1};or.fromSourceMap=function(t,r){var n=Object.create(or.prototype),i=n._names=Ga.fromArray(t._names.toArray(),!0),s=n._sources=Ga.fromArray(t._sources.toArray(),!0);n.sourceRoot=t._sourceRoot,n.sourcesContent=t._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=t._file,n._sourceMapURL=r,n._absoluteSources=n._sources.toArray().map(function(h){return ne.computeSourceURL(n.sourceRoot,h,r)});for(var o=t._mappings.toArray().slice(),a=n.__generatedMappings=[],c=n.__originalMappings=[],u=0,l=o.length;u<l;u++){var p=o[u],d=new DF;d.generatedLine=p.generatedLine,d.generatedColumn=p.generatedColumn,p.source&&(d.source=s.indexOf(p.source),d.originalLine=p.originalLine,d.originalColumn=p.originalColumn,p.name&&(d.name=i.indexOf(p.name)),c.push(d)),a.push(d)}return Vu(n.__originalMappings,ne.compareByOriginalPositions),n};or.prototype._version=3;Object.defineProperty(or.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function DF(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}var Tb=ne.compareByGeneratedPositionsDeflatedNoLine;function vF(e,t){let r=e.length,n=e.length-t;if(!(n<=1))if(n==2){let i=e[t],s=e[t+1];Tb(i,s)>0&&(e[t]=s,e[t+1]=i)}else if(n<20)for(let i=t;i<r;i++)for(let s=i;s>t;s--){let o=e[s-1],a=e[s];if(Tb(o,a)<=0)break;e[s-1]=a,e[s]=o}else Vu(e,Tb,t)}or.prototype._parseMappings=function(t,r){var n=1,i=0,s=0,o=0,a=0,c=0,u=t.length,l=0,p={},d={},h=[],m=[],g,y,b,v,C;let x=0;for(;l<u;)if(t.charAt(l)===";")n++,l++,i=0,vF(m,x),x=m.length;else if(t.charAt(l)===",")l++;else{for(g=new DF,g.generatedLine=n,v=l;v<u&&!this._charIsMappingSeparator(t,v);v++);for(y=t.slice(l,v),b=[];l<v;)AV.decode(t,l,d),C=d.value,l=d.rest,b.push(C);if(b.length===2)throw new Error("Found a source, but no line and column");if(b.length===3)throw new Error("Found a source and line, but no column");if(g.generatedColumn=i+b[0],i=g.generatedColumn,b.length>1&&(g.source=a+b[1],a+=b[1],g.originalLine=s+b[2],s=g.originalLine,g.originalLine+=1,g.originalColumn=o+b[3],o=g.originalColumn,b.length>4&&(g.name=c+b[4],c+=b[4])),m.push(g),typeof g.originalLine=="number"){let E=g.source;for(;h.length<=E;)h.push(null);h[E]===null&&(h[E]=[]),h[E].push(g)}}vF(m,x),this.__generatedMappings=m;for(var D=0;D<h.length;D++)h[D]!=null&&Vu(h[D],ne.compareByOriginalPositionsNoSource);this.__originalMappings=[].concat(...h)};or.prototype._findMapping=function(t,r,n,i,s,o){if(t[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+t[n]);if(t[i]<0)throw new TypeError("Column must be greater than or equal to 0, got "+t[i]);return Ab.search(t,r,s,o)};or.prototype.computeColumnSpans=function(){for(var t=0;t<this._generatedMappings.length;++t){var r=this._generatedMappings[t];if(t+1<this._generatedMappings.length){var n=this._generatedMappings[t+1];if(r.generatedLine===n.generatedLine){r.lastGeneratedColumn=n.generatedColumn-1;continue}}r.lastGeneratedColumn=1/0}};or.prototype.originalPositionFor=function(t){var r={generatedLine:ne.getArg(t,"line"),generatedColumn:ne.getArg(t,"column")},n=this._findMapping(r,this._generatedMappings,"generatedLine","generatedColumn",ne.compareByGeneratedPositionsDeflated,ne.getArg(t,"bias",ht.GREATEST_LOWER_BOUND));if(n>=0){var i=this._generatedMappings[n];if(i.generatedLine===r.generatedLine){var s=ne.getArg(i,"source",null);s!==null&&(s=this._sources.at(s),s=ne.computeSourceURL(this.sourceRoot,s,this._sourceMapURL));var o=ne.getArg(i,"name",null);return o!==null&&(o=this._names.at(o)),{source:s,line:ne.getArg(i,"originalLine",null),column:ne.getArg(i,"originalColumn",null),name:o}}}return{source:null,line:null,column:null,name:null}};or.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(t){return t==null}):!1};or.prototype.sourceContentFor=function(t,r){if(!this.sourcesContent)return null;var n=this._findSourceIndex(t);if(n>=0)return this.sourcesContent[n];var i=t;this.sourceRoot!=null&&(i=ne.relative(this.sourceRoot,i));var s;if(this.sourceRoot!=null&&(s=ne.urlParse(this.sourceRoot))){var o=i.replace(/^file:\/\//,"");if(s.scheme=="file"&&this._sources.has(o))return this.sourcesContent[this._sources.indexOf(o)];if((!s.path||s.path=="/")&&this._sources.has("/"+i))return this.sourcesContent[this._sources.indexOf("/"+i)]}if(r)return null;throw new Error('"'+i+'" is not in the SourceMap.')};or.prototype.generatedPositionFor=function(t){var r=ne.getArg(t,"source");if(r=this._findSourceIndex(r),r<0)return{line:null,column:null,lastColumn:null};var n={source:r,originalLine:ne.getArg(t,"line"),originalColumn:ne.getArg(t,"column")},i=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",ne.compareByOriginalPositions,ne.getArg(t,"bias",ht.GREATEST_LOWER_BOUND));if(i>=0){var s=this._originalMappings[i];if(s.source===n.source)return{line:ne.getArg(s,"generatedLine",null),column:ne.getArg(s,"generatedColumn",null),lastColumn:ne.getArg(s,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};sf.BasicSourceMapConsumer=or;function Kn(e,t){var r=e;typeof e=="string"&&(r=ne.parseSourceMapInput(e));var n=ne.getArg(r,"version"),i=ne.getArg(r,"sections");if(n!=this._version)throw new Error("Unsupported version: "+n);this._sources=new Ga,this._names=new Ga;var s={line:-1,column:0};this._sections=i.map(function(o){if(o.url)throw new Error("Support for url field in sections not implemented.");var a=ne.getArg(o,"offset"),c=ne.getArg(a,"line"),u=ne.getArg(a,"column");if(c<s.line||c===s.line&&u<s.column)throw new Error("Section offsets must be ordered and non-overlapping.");return s=a,{generatedOffset:{generatedLine:c+1,generatedColumn:u+1},consumer:new ht(ne.getArg(o,"map"),t)}})}Kn.prototype=Object.create(ht.prototype);Kn.prototype.constructor=ht;Kn.prototype._version=3;Object.defineProperty(Kn.prototype,"sources",{get:function(){for(var e=[],t=0;t<this._sections.length;t++)for(var r=0;r<this._sections[t].consumer.sources.length;r++)e.push(this._sections[t].consumer.sources[r]);return e}});Kn.prototype.originalPositionFor=function(t){var r={generatedLine:ne.getArg(t,"line"),generatedColumn:ne.getArg(t,"column")},n=Ab.search(r,this._sections,function(s,o){var a=s.generatedLine-o.generatedOffset.generatedLine;return a||s.generatedColumn-o.generatedOffset.generatedColumn}),i=this._sections[n];return i?i.consumer.originalPositionFor({line:r.generatedLine-(i.generatedOffset.generatedLine-1),column:r.generatedColumn-(i.generatedOffset.generatedLine===r.generatedLine?i.generatedOffset.generatedColumn-1:0),bias:t.bias}):{source:null,line:null,column:null,name:null}};Kn.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(t){return t.consumer.hasContentsOfAllSources()})};Kn.prototype.sourceContentFor=function(t,r){for(var n=0;n<this._sections.length;n++){var i=this._sections[n],s=i.consumer.sourceContentFor(t,!0);if(s||s==="")return s}if(r)return null;throw new Error('"'+t+'" is not in the SourceMap.')};Kn.prototype.generatedPositionFor=function(t){for(var r=0;r<this._sections.length;r++){var n=this._sections[r];if(n.consumer._findSourceIndex(ne.getArg(t,"source"))!==-1){var i=n.consumer.generatedPositionFor(t);if(i){var s={line:i.line+(n.generatedOffset.generatedLine-1),column:i.column+(n.generatedOffset.generatedLine===i.line?n.generatedOffset.generatedColumn-1:0)};return s}}}return{line:null,column:null}};Kn.prototype._parseMappings=function(t,r){this.__generatedMappings=[],this.__originalMappings=[];for(var n=0;n<this._sections.length;n++)for(var i=this._sections[n],s=i.consumer._generatedMappings,o=0;o<s.length;o++){var a=s[o],c=i.consumer._sources.at(a.source);c!==null&&(c=ne.computeSourceURL(i.consumer.sourceRoot,c,this._sourceMapURL)),this._sources.add(c),c=this._sources.indexOf(c);var u=null;a.name&&(u=i.consumer._names.at(a.name),this._names.add(u),u=this._names.indexOf(u));var l={source:c,generatedLine:a.generatedLine+(i.generatedOffset.generatedLine-1),generatedColumn:a.generatedColumn+(i.generatedOffset.generatedLine===a.generatedLine?i.generatedOffset.generatedColumn-1:0),originalLine:a.originalLine,originalColumn:a.originalColumn,name:u};this.__generatedMappings.push(l),typeof l.originalLine=="number"&&this.__originalMappings.push(l)}Vu(this.__generatedMappings,ne.compareByGeneratedPositionsDeflated),Vu(this.__originalMappings,ne.compareByOriginalPositions)};sf.IndexedSourceMapConsumer=Kn});var wF=w(EF=>{f();var PV=wb().SourceMapGenerator,of=qa(),FV=/(\r?\n)/,_V=10,za="$$$isSourceNode$$$";function on(e,t,r,n,i){this.children=[],this.sourceContents={},this.line=e??null,this.column=t??null,this.source=r??null,this.name=i??null,this[za]=!0,n!=null&&this.add(n)}on.fromStringWithSourceMap=function(t,r,n){var i=new on,s=t.split(FV),o=0,a=function(){var d=m(),h=m()||"";return d+h;function m(){return o<s.length?s[o++]:void 0}},c=1,u=0,l=null;return r.eachMapping(function(d){if(l!==null)if(c<d.generatedLine)p(l,a()),c++,u=0;else{var h=s[o]||"",m=h.substr(0,d.generatedColumn-u);s[o]=h.substr(d.generatedColumn-u),u=d.generatedColumn,p(l,m),l=d;return}for(;c<d.generatedLine;)i.add(a()),c++;if(u<d.generatedColumn){var h=s[o]||"";i.add(h.substr(0,d.generatedColumn)),s[o]=h.substr(d.generatedColumn),u=d.generatedColumn}l=d},this),o<s.length&&(l&&p(l,a()),i.add(s.splice(o).join(""))),r.sources.forEach(function(d){var h=r.sourceContentFor(d);h!=null&&(n!=null&&(d=of.join(n,d)),i.setSourceContent(d,h))}),i;function p(d,h){if(d===null||d.source===void 0)i.add(h);else{var m=n?of.join(n,d.source):d.source;i.add(new on(d.originalLine,d.originalColumn,m,h,d.name))}}};on.prototype.add=function(t){if(Array.isArray(t))t.forEach(function(r){this.add(r)},this);else if(t[za]||typeof t=="string")t&&this.children.push(t);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+t);return this};on.prototype.prepend=function(t){if(Array.isArray(t))for(var r=t.length-1;r>=0;r--)this.prepend(t[r]);else if(t[za]||typeof t=="string")this.children.unshift(t);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+t);return this};on.prototype.walk=function(t){for(var r,n=0,i=this.children.length;n<i;n++)r=this.children[n],r[za]?r.walk(t):r!==""&&t(r,{source:this.source,line:this.line,column:this.column,name:this.name})};on.prototype.join=function(t){var r,n,i=this.children.length;if(i>0){for(r=[],n=0;n<i-1;n++)r.push(this.children[n]),r.push(t);r.push(this.children[n]),this.children=r}return this};on.prototype.replaceRight=function(t,r){var n=this.children[this.children.length-1];return n[za]?n.replaceRight(t,r):typeof n=="string"?this.children[this.children.length-1]=n.replace(t,r):this.children.push("".replace(t,r)),this};on.prototype.setSourceContent=function(t,r){this.sourceContents[of.toSetString(t)]=r};on.prototype.walkSourceContents=function(t){for(var r=0,n=this.children.length;r<n;r++)this.children[r][za]&&this.children[r].walkSourceContents(t);for(var i=Object.keys(this.sourceContents),r=0,n=i.length;r<n;r++)t(of.fromSetString(i[r]),this.sourceContents[i[r]])};on.prototype.toString=function(){var t="";return this.walk(function(r){t+=r}),t};on.prototype.toStringWithSourceMap=function(t){var r={code:"",line:1,column:0},n=new PV(t),i=!1,s=null,o=null,a=null,c=null;return this.walk(function(u,l){r.code+=u,l.source!==null&&l.line!==null&&l.column!==null?((s!==l.source||o!==l.line||a!==l.column||c!==l.name)&&n.addMapping({source:l.source,original:{line:l.line,column:l.column},generated:{line:r.line,column:r.column},name:l.name}),s=l.source,o=l.line,a=l.column,c=l.name,i=!0):i&&(n.addMapping({generated:{line:r.line,column:r.column}}),s=null,i=!1);for(var p=0,d=u.length;p<d;p++)u.charCodeAt(p)===_V?(r.line++,r.column=0,p+1===d?(s=null,i=!1):i&&n.addMapping({source:l.source,original:{line:l.line,column:l.column},generated:{line:r.line,column:r.column},name:l.name})):r.column++}),this.walkSourceContents(function(u,l){n.setSourceContent(u,l)}),{code:r.code,map:n}};EF.SourceNode=on});var SF=w(af=>{f();af.SourceMapGenerator=wb().SourceMapGenerator;af.SourceMapConsumer=CF().SourceMapConsumer;af.SourceNode=wF().SourceNode});var r_=w(nl=>{"use strict";f();Object.defineProperty(nl,"__esModule",{value:!0});function IV(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.includes(n))continue;r[n]=e[n]}return r}var vi=class{constructor(t,r,n){this.line=void 0,this.column=void 0,this.index=void 0,this.line=t,this.column=r,this.index=n}},Ya=class{constructor(t,r){this.start=void 0,this.end=void 0,this.filename=void 0,this.identifierName=void 0,this.start=t,this.end=r}};function Tr(e,t){let{line:r,column:n,index:i}=e;return new vi(r,n+t,i+t)}var TF="BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED",kV={ImportMetaOutsideModule:{message:`import.meta may appear only with 'sourceType: "module"'`,code:TF},ImportOutsideModule:{message:`'import' and 'export' may appear only with 'sourceType: "module"'`,code:TF}},AF={ArrayPattern:"array destructuring pattern",AssignmentExpression:"assignment expression",AssignmentPattern:"assignment expression",ArrowFunctionExpression:"arrow function expression",ConditionalExpression:"conditional expression",CatchClause:"catch clause",ForOfStatement:"for-of statement",ForInStatement:"for-in statement",ForStatement:"for-loop",FormalParameters:"function parameter list",Identifier:"identifier",ImportSpecifier:"import specifier",ImportDefaultSpecifier:"import default specifier",ImportNamespaceSpecifier:"import namespace specifier",ObjectPattern:"object destructuring pattern",ParenthesizedExpression:"parenthesized expression",RestElement:"rest element",UpdateExpression:{true:"prefix operation",false:"postfix operation"},VariableDeclarator:"variable declaration",YieldExpression:"yield expression"},lf=e=>e.type==="UpdateExpression"?AF.UpdateExpression[`${e.prefix}`]:AF[e.type],NV={AccessorIsGenerator:({kind:e})=>`A ${e}ter cannot be a generator.`,ArgumentsInClass:"'arguments' is only allowed in functions and class methods.",AsyncFunctionInSingleStatementContext:"Async functions can only be declared at the top level or inside a block.",AwaitBindingIdentifier:"Can not use 'await' as identifier inside an async function.",AwaitBindingIdentifierInStaticBlock:"Can not use 'await' as identifier inside a static block.",AwaitExpressionFormalParameter:"'await' is not allowed in async function parameters.",AwaitUsingNotInAsyncContext:"'await using' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncContext:"'await' is only allowed within async functions and at the top levels of modules.",AwaitNotInAsyncFunction:"'await' is only allowed within async functions.",BadGetterArity:"A 'get' accessor must not have any formal parameters.",BadSetterArity:"A 'set' accessor must have exactly one formal parameter.",BadSetterRestParameter:"A 'set' accessor function argument must not be a rest parameter.",ConstructorClassField:"Classes may not have a field named 'constructor'.",ConstructorClassPrivateField:"Classes may not have a private field named '#constructor'.",ConstructorIsAccessor:"Class constructor may not be an accessor.",ConstructorIsAsync:"Constructor can't be an async function.",ConstructorIsGenerator:"Constructor can't be a generator.",DeclarationMissingInitializer:({kind:e})=>`Missing initializer in ${e} declaration.`,DecoratorArgumentsOutsideParentheses:"Decorator arguments must be moved inside parentheses: use '@(decorator(args))' instead of '@(decorator)(args)'.",DecoratorBeforeExport:"Decorators must be placed *before* the 'export' keyword. Remove the 'decoratorsBeforeExport: true' option to use the 'export @decorator class {}' syntax.",DecoratorsBeforeAfterExport:"Decorators can be placed *either* before or after the 'export' keyword, but not in both locations at the same time.",DecoratorConstructor:"Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?",DecoratorExportClass:"Decorators must be placed *after* the 'export' keyword. Remove the 'decoratorsBeforeExport: false' option to use the '@decorator export class {}' syntax.",DecoratorSemicolon:"Decorators must not be followed by a semicolon.",DecoratorStaticBlock:"Decorators can't be used with a static block.",DeferImportRequiresNamespace:'Only `import defer * as x from "./module"` is valid.',DeletePrivateField:"Deleting a private field is not allowed.",DestructureNamedImport:"ES2015 named imports do not destructure. Use another statement for destructuring after the import.",DuplicateConstructor:"Duplicate constructor in the same class.",DuplicateDefaultExport:"Only one default export allowed per module.",DuplicateExport:({exportName:e})=>`\`${e}\` has already been exported. Exported identifiers must be unique.`,DuplicateProto:"Redefinition of __proto__ property.",DuplicateRegExpFlags:"Duplicate regular expression flag.",DynamicImportPhaseRequiresImportExpressions:({phase:e})=>`'import.${e}(...)' can only be parsed when using the 'createImportExpressions' option.`,ElementAfterRest:"Rest element must be last element.",EscapedCharNotAnIdentifier:"Invalid Unicode escape.",ExportBindingIsString:({localName:e,exportName:t})=>`A string literal cannot be used as an exported binding without \`from\`.
16
16
  - Did you mean \`export { '${e}' as '${t}' } from 'some-module'\`?`,ExportDefaultFromAsIdentifier:"'from' is not allowed as an identifier after 'export default'.",ForInOfLoopInitializer:({type:e})=>`'${e==="ForInStatement"?"for-in":"for-of"}' loop variable declaration may not have an initializer.`,ForInUsing:"For-in loop may not start with 'using' declaration.",ForOfAsync:"The left-hand side of a for-of loop may not be 'async'.",ForOfLet:"The left-hand side of a for-of loop may not start with 'let'.",GeneratorInSingleStatementContext:"Generators can only be declared at the top level or inside a block.",IllegalBreakContinue:({type:e})=>`Unsyntactic ${e==="BreakStatement"?"break":"continue"}.`,IllegalLanguageModeDirective:"Illegal 'use strict' directive in function with non-simple parameter list.",IllegalReturn:"'return' outside of function.",ImportAttributesUseAssert:"The `assert` keyword in import attributes is deprecated and it has been replaced by the `with` keyword. You can enable the `deprecatedAssertSyntax: true` option in the import attributes plugin to suppress this error.",ImportBindingIsString:({importName:e})=>`A string literal cannot be used as an imported binding.
17
- - Did you mean \`import { "${e}" as foo }\`?`,ImportCallArgumentTrailingComma:"Trailing comma is disallowed inside import(...) arguments.",ImportCallArity:({maxArgumentCount:e})=>`\`import()\` requires exactly ${e===1?"one argument":"one or two arguments"}.`,ImportCallNotNewExpression:"Cannot use new with import(...).",ImportCallSpreadArgument:"`...` is not allowed in `import()`.",ImportJSONBindingNotDefault:"A JSON module can only be imported with `default`.",ImportReflectionHasAssertion:"`import module x` cannot have assertions.",ImportReflectionNotBinding:'Only `import module x from "./module"` is valid.',IncompatibleRegExpUVFlags:"The 'u' and 'v' regular expression flags cannot be enabled at the same time.",InvalidBigIntLiteral:"Invalid BigIntLiteral.",InvalidCodePoint:"Code point out of bounds.",InvalidCoverInitializedName:"Invalid shorthand property initializer.",InvalidDecimal:"Invalid decimal.",InvalidDigit:({radix:e})=>`Expected number in radix ${e}.`,InvalidEscapeSequence:"Bad character escape sequence.",InvalidEscapeSequenceTemplate:"Invalid escape sequence in template.",InvalidEscapedReservedWord:({reservedWord:e})=>`Escape sequence in keyword ${e}.`,InvalidIdentifier:({identifierName:e})=>`Invalid identifier ${e}.`,InvalidLhs:({ancestor:e})=>`Invalid left-hand side in ${lf(e)}.`,InvalidLhsBinding:({ancestor:e})=>`Binding invalid left-hand side in ${lf(e)}.`,InvalidLhsOptionalChaining:({ancestor:e})=>`Invalid optional chaining in the left-hand side of ${lf(e)}.`,InvalidNumber:"Invalid number.",InvalidOrMissingExponent:"Floating-point numbers require a valid exponent after the 'e'.",InvalidOrUnexpectedToken:({unexpected:e})=>`Unexpected character '${e}'.`,InvalidParenthesizedAssignment:"Invalid parenthesized assignment pattern.",InvalidPrivateFieldResolution:({identifierName:e})=>`Private name #${e} is not defined.`,InvalidPropertyBindingPattern:"Binding member expression.",InvalidRecordProperty:"Only properties and spread elements are allowed in record definitions.",InvalidRestAssignmentPattern:"Invalid rest operator's argument.",LabelRedeclaration:({labelName:e})=>`Label '${e}' is already declared.`,LetInLexicalBinding:"'let' is disallowed as a lexically bound name.",LineTerminatorBeforeArrow:"No line break is allowed before '=>'.",MalformedRegExpFlags:"Invalid regular expression flag.",MissingClassName:"A class name is required.",MissingEqInAssignment:"Only '=' operator can be used for specifying default value.",MissingSemicolon:"Missing semicolon.",MissingPlugin:({missingPlugin:e})=>`This experimental syntax requires enabling the parser plugin: ${e.map(t=>JSON.stringify(t)).join(", ")}.`,MissingOneOfPlugins:({missingPlugin:e})=>`This experimental syntax requires enabling one of the following parser plugin(s): ${e.map(t=>JSON.stringify(t)).join(", ")}.`,MissingUnicodeEscape:"Expecting Unicode escape sequence \\uXXXX.",MixingCoalesceWithLogical:"Nullish coalescing operator(??) requires parens when mixing with logical operators.",ModuleAttributeDifferentFromType:"The only accepted module attribute is `type`.",ModuleAttributeInvalidValue:"Only string literals are allowed as module attribute values.",ModuleAttributesWithDuplicateKeys:({key:e})=>`Duplicate key "${e}" is not allowed in module attributes.`,ModuleExportNameHasLoneSurrogate:({surrogateCharCode:e})=>`An export name cannot include a lone surrogate, found '\\u${e.toString(16)}'.`,ModuleExportUndefined:({localName:e})=>`Export '${e}' is not defined.`,MultipleDefaultsInSwitch:"Multiple default clauses.",NewlineAfterThrow:"Illegal newline after throw.",NoCatchOrFinally:"Missing catch or finally clause.",NumberIdentifier:"Identifier directly after number.",NumericSeparatorInEscapeSequence:"Numeric separators are not allowed inside unicode escape sequences or hex escape sequences.",ObsoleteAwaitStar:"'await*' has been removed from the async functions proposal. Use Promise.all() instead.",OptionalChainingNoNew:"Constructors in/after an Optional Chain are not allowed.",OptionalChainingNoTemplate:"Tagged Template Literals are not allowed in optionalChain.",OverrideOnConstructor:"'override' modifier cannot appear on a constructor declaration.",ParamDupe:"Argument name clash.",PatternHasAccessor:"Object pattern can't contain getter or setter.",PatternHasMethod:"Object pattern can't contain methods.",PrivateInExpectedIn:({identifierName:e})=>`Private names are only allowed in property accesses (\`obj.#${e}\`) or in \`in\` expressions (\`#${e} in obj\`).`,PrivateNameRedeclaration:({identifierName:e})=>`Duplicate private name #${e}.`,RecordExpressionBarIncorrectEndSyntaxType:"Record expressions ending with '|}' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",RecordExpressionBarIncorrectStartSyntaxType:"Record expressions starting with '{|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",RecordExpressionHashIncorrectStartSyntaxType:"Record expressions starting with '#{' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.",RecordNoProto:"'__proto__' is not allowed in Record expressions.",RestTrailingComma:"Unexpected trailing comma after rest element.",SloppyFunction:"In non-strict mode code, functions can only be declared at top level or inside a block.",SloppyFunctionAnnexB:"In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement.",SourcePhaseImportRequiresDefault:'Only `import source x from "./module"` is valid.',StaticPrototype:"Classes may not have static property named prototype.",SuperNotAllowed:"`super()` is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?",SuperPrivateField:"Private fields can't be accessed on super.",TrailingDecorator:"Decorators must be attached to a class element.",TupleExpressionBarIncorrectEndSyntaxType:"Tuple expressions ending with '|]' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",TupleExpressionBarIncorrectStartSyntaxType:"Tuple expressions starting with '[|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",TupleExpressionHashIncorrectStartSyntaxType:"Tuple expressions starting with '#[' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.",UnexpectedArgumentPlaceholder:"Unexpected argument placeholder.",UnexpectedAwaitAfterPipelineBody:'Unexpected "await" after pipeline body; await must have parentheses in minimal proposal.',UnexpectedDigitAfterHash:"Unexpected digit after hash token.",UnexpectedImportExport:"'import' and 'export' may only appear at the top level.",UnexpectedKeyword:({keyword:e})=>`Unexpected keyword '${e}'.`,UnexpectedLeadingDecorator:"Leading decorators must be attached to a class declaration.",UnexpectedLexicalDeclaration:"Lexical declaration cannot appear in a single-statement context.",UnexpectedNewTarget:"`new.target` can only be used in functions or class properties.",UnexpectedNumericSeparator:"A numeric separator is only allowed between two digits.",UnexpectedPrivateField:"Unexpected private name.",UnexpectedReservedWord:({reservedWord:e})=>`Unexpected reserved word '${e}'.`,UnexpectedSuper:"'super' is only allowed in object methods and classes.",UnexpectedToken:({expected:e,unexpected:t})=>`Unexpected token${t?` '${t}'.`:""}${e?`, expected "${e}"`:""}`,UnexpectedTokenUnaryExponentiation:"Illegal expression. Wrap left hand side or entire exponentiation in parentheses.",UnexpectedUsingDeclaration:"Using declaration cannot appear in the top level when source type is `script`.",UnsupportedBind:"Binding should be performed on object property.",UnsupportedDecoratorExport:"A decorated export must export a class declaration.",UnsupportedDefaultExport:"Only expressions, functions or classes are allowed as the `default` export.",UnsupportedImport:"`import` can only be used in `import()` or `import.meta`.",UnsupportedMetaProperty:({target:e,onlyValidPropertyName:t})=>`The only valid meta property for ${e} is ${e}.${t}.`,UnsupportedParameterDecorator:"Decorators cannot be used to decorate parameters.",UnsupportedPropertyDecorator:"Decorators cannot be used to decorate object literal properties.",UnsupportedSuper:"'super' can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop]).",UnterminatedComment:"Unterminated comment.",UnterminatedRegExp:"Unterminated regular expression.",UnterminatedString:"Unterminated string constant.",UnterminatedTemplate:"Unterminated template.",UsingDeclarationExport:"Using declaration cannot be exported.",UsingDeclarationHasBindingPattern:"Using declaration cannot have destructuring patterns.",VarRedeclaration:({identifierName:e})=>`Identifier '${e}' has already been declared.`,YieldBindingIdentifier:"Can not use 'yield' as identifier inside a generator.",YieldInParameter:"Yield expression is not allowed in formal parameters.",ZeroDigitNumericSeparator:"Numeric separator can not be used after leading 0."},RV={StrictDelete:"Deleting local variable in strict mode.",StrictEvalArguments:({referenceName:e})=>`Assigning to '${e}' in strict mode.`,StrictEvalArgumentsBinding:({bindingName:e})=>`Binding '${e}' in strict mode.`,StrictFunction:"In strict mode code, functions can only be declared at top level or inside a block.",StrictNumericEscape:"The only valid numeric escape in strict mode is '\\0'.",StrictOctalLiteral:"Legacy octal literals are not allowed in strict mode.",StrictWith:"'with' in strict mode."},OV=new Set(["ArrowFunctionExpression","AssignmentExpression","ConditionalExpression","YieldExpression"]),BV={PipeBodyIsTighter:"Unexpected yield after pipeline body; any yield expression acting as Hack-style pipe body must be parenthesized due to its loose operator precedence.",PipeTopicRequiresHackPipes:'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.',PipeTopicUnbound:"Topic reference is unbound; it must be inside a pipe body.",PipeTopicUnconfiguredToken:({token:e})=>`Invalid topic token ${e}. In order to use ${e} as a topic reference, the pipelineOperator plugin must be configured with { "proposal": "hack", "topicToken": "${e}" }.`,PipeTopicUnused:"Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once.",PipeUnparenthesizedBody:({type:e})=>`Hack-style pipe body cannot be an unparenthesized ${lf({type:e})}; please wrap it in parentheses.`,PipelineBodyNoArrow:'Unexpected arrow "=>" after pipeline body; arrow function in pipeline body must be parenthesized.',PipelineBodySequenceExpression:"Pipeline body may not be a comma-separated sequence expression.",PipelineHeadSequenceExpression:"Pipeline head should not be a comma-separated sequence expression.",PipelineTopicUnused:"Pipeline is in topic style but does not use topic reference.",PrimaryTopicNotAllowed:"Topic reference was used in a lexical context without topic binding.",PrimaryTopicRequiresSmartPipeline:'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.'},MV=["message"];function PF(e,t,r){Object.defineProperty(e,t,{enumerable:!1,configurable:!0,value:r})}function LV({toMessage:e,code:t,reasonCode:r,syntaxPlugin:n}){let i=r==="MissingPlugin"||r==="MissingOneOfPlugins";{let s={AccessorCannotDeclareThisParameter:"AccesorCannotDeclareThisParameter",AccessorCannotHaveTypeParameters:"AccesorCannotHaveTypeParameters",ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference:"ConstInitiailizerMustBeStringOrNumericLiteralOrLiteralEnumReference",SetAccessorCannotHaveOptionalParameter:"SetAccesorCannotHaveOptionalParameter",SetAccessorCannotHaveRestParameter:"SetAccesorCannotHaveRestParameter",SetAccessorCannotHaveReturnType:"SetAccesorCannotHaveReturnType"};s[r]&&(r=s[r])}return function s(o,a){let c=new SyntaxError;return c.code=t,c.reasonCode=r,c.loc=o,c.pos=o.index,c.syntaxPlugin=n,i&&(c.missingPlugin=a.missingPlugin),PF(c,"clone",function(l={}){var p;let{line:d,column:h,index:m}=(p=l.loc)!=null?p:o;return s(new vi(d,h,m),Object.assign({},a,l.details))}),PF(c,"details",a),Object.defineProperty(c,"message",{configurable:!0,get(){let u=`${e(a)} (${o.line}:${o.column})`;return this.message=u,u},set(u){Object.defineProperty(this,"message",{value:u,writable:!0})}}),c}}function Zi(e,t){if(Array.isArray(e))return n=>Zi(n,e[0]);let r={};for(let n of Object.keys(e)){let i=e[n],s=typeof i=="string"?{message:()=>i}:typeof i=="function"?{message:i}:i,{message:o}=s,a=IV(s,MV),c=typeof o=="string"?()=>o:o;r[n]=LV(Object.assign({code:"BABEL_PARSER_SYNTAX_ERROR",reasonCode:n,toMessage:c},t?{syntaxPlugin:t}:{},a))}return r}var _=Object.assign({},Zi(kV),Zi(NV),Zi(RV),Zi`pipelineOperator`(BV)),{defineProperty:$V}=Object,FF=(e,t)=>{e&&$V(e,t,{enumerable:!1,value:e[t]})};function Wu(e){return FF(e.loc.start,"index"),FF(e.loc.end,"index"),e}var UV=e=>class extends e{parse(){let r=Wu(super.parse());return this.options.tokens&&(r.tokens=r.tokens.map(Wu)),r}parseRegExpLiteral({pattern:r,flags:n}){let i=null;try{i=new RegExp(r,n)}catch{}let s=this.estreeParseLiteral(i);return s.regex={pattern:r,flags:n},s}parseBigIntLiteral(r){let n;try{n=BigInt(r)}catch{n=null}let i=this.estreeParseLiteral(n);return i.bigint=String(i.value||r),i}parseDecimalLiteral(r){let i=this.estreeParseLiteral(null);return i.decimal=String(i.value||r),i}estreeParseLiteral(r){return this.parseLiteral(r,"Literal")}parseStringLiteral(r){return this.estreeParseLiteral(r)}parseNumericLiteral(r){return this.estreeParseLiteral(r)}parseNullLiteral(){return this.estreeParseLiteral(null)}parseBooleanLiteral(r){return this.estreeParseLiteral(r)}directiveToStmt(r){let n=r.value;delete r.value,n.type="Literal",n.raw=n.extra.raw,n.value=n.extra.expressionValue;let i=r;return i.type="ExpressionStatement",i.expression=n,i.directive=n.extra.rawValue,delete n.extra,i}initFunction(r,n){super.initFunction(r,n),r.expression=!1}checkDeclaration(r){r!=null&&this.isObjectProperty(r)?this.checkDeclaration(r.value):super.checkDeclaration(r)}getObjectOrClassMethodParams(r){return r.value.params}isValidDirective(r){var n;return r.type==="ExpressionStatement"&&r.expression.type==="Literal"&&typeof r.expression.value=="string"&&!((n=r.expression.extra)!=null&&n.parenthesized)}parseBlockBody(r,n,i,s,o){super.parseBlockBody(r,n,i,s,o);let a=r.directives.map(c=>this.directiveToStmt(c));r.body=a.concat(r.body),delete r.directives}pushClassMethod(r,n,i,s,o,a){this.parseMethod(n,i,s,o,a,"ClassMethod",!0),n.typeParameters&&(n.value.typeParameters=n.typeParameters,delete n.typeParameters),r.body.push(n)}parsePrivateName(){let r=super.parsePrivateName();return this.getPluginOption("estree","classFeatures")?this.convertPrivateNameToPrivateIdentifier(r):r}convertPrivateNameToPrivateIdentifier(r){let n=super.getPrivateNameSV(r);return r=r,delete r.id,r.name=n,r.type="PrivateIdentifier",r}isPrivateName(r){return this.getPluginOption("estree","classFeatures")?r.type==="PrivateIdentifier":super.isPrivateName(r)}getPrivateNameSV(r){return this.getPluginOption("estree","classFeatures")?r.name:super.getPrivateNameSV(r)}parseLiteral(r,n){let i=super.parseLiteral(r,n);return i.raw=i.extra.raw,delete i.extra,i}parseFunctionBody(r,n,i=!1){super.parseFunctionBody(r,n,i),r.expression=r.body.type!=="BlockStatement"}parseMethod(r,n,i,s,o,a,c=!1){let u=this.startNode();return u.kind=r.kind,u=super.parseMethod(u,n,i,s,o,a,c),u.type="FunctionExpression",delete u.kind,r.value=u,a==="ClassPrivateMethod"&&(r.computed=!1),this.finishNode(r,"MethodDefinition")}nameIsConstructor(r){return r.type==="Literal"?r.value==="constructor":super.nameIsConstructor(r)}parseClassProperty(...r){let n=super.parseClassProperty(...r);return this.getPluginOption("estree","classFeatures")&&(n.type="PropertyDefinition"),n}parseClassPrivateProperty(...r){let n=super.parseClassPrivateProperty(...r);return this.getPluginOption("estree","classFeatures")&&(n.type="PropertyDefinition",n.computed=!1),n}parseObjectMethod(r,n,i,s,o){let a=super.parseObjectMethod(r,n,i,s,o);return a&&(a.type="Property",a.kind==="method"&&(a.kind="init"),a.shorthand=!1),a}parseObjectProperty(r,n,i,s){let o=super.parseObjectProperty(r,n,i,s);return o&&(o.kind="init",o.type="Property"),o}isValidLVal(r,n,i){return r==="Property"?"value":super.isValidLVal(r,n,i)}isAssignable(r,n){return r!=null&&this.isObjectProperty(r)?this.isAssignable(r.value,n):super.isAssignable(r,n)}toAssignable(r,n=!1){if(r!=null&&this.isObjectProperty(r)){let{key:i,value:s}=r;this.isPrivateName(i)&&this.classScope.usePrivateName(this.getPrivateNameSV(i),i.loc.start),this.toAssignable(s,n)}else super.toAssignable(r,n)}toAssignableObjectExpressionProp(r,n,i){r.type==="Property"&&(r.kind==="get"||r.kind==="set")?this.raise(_.PatternHasAccessor,r.key):r.type==="Property"&&r.method?this.raise(_.PatternHasMethod,r.key):super.toAssignableObjectExpressionProp(r,n,i)}finishCallExpression(r,n){let i=super.finishCallExpression(r,n);if(i.callee.type==="Import"){if(i.type="ImportExpression",i.source=i.arguments[0],this.hasPlugin("importAttributes")||this.hasPlugin("importAssertions")){var s,o;i.options=(s=i.arguments[1])!=null?s:null,i.attributes=(o=i.arguments[1])!=null?o:null}delete i.arguments,delete i.callee}return i}toReferencedArguments(r){r.type!=="ImportExpression"&&super.toReferencedArguments(r)}parseExport(r,n){let i=this.state.lastTokStartLoc,s=super.parseExport(r,n);switch(s.type){case"ExportAllDeclaration":s.exported=null;break;case"ExportNamedDeclaration":s.specifiers.length===1&&s.specifiers[0].type==="ExportNamespaceSpecifier"&&(s.type="ExportAllDeclaration",s.exported=s.specifiers[0].exported,delete s.specifiers);case"ExportDefaultDeclaration":{var o;let{declaration:a}=s;a?.type==="ClassDeclaration"&&((o=a.decorators)==null?void 0:o.length)>0&&a.start===s.start&&this.resetStartLocation(s,i)}break}return s}parseSubscript(r,n,i,s){let o=super.parseSubscript(r,n,i,s);if(s.optionalChainMember){if((o.type==="OptionalMemberExpression"||o.type==="OptionalCallExpression")&&(o.type=o.type.substring(8)),s.stop){let a=this.startNodeAtNode(o);return a.expression=o,this.finishNode(a,"ChainExpression")}}else(o.type==="MemberExpression"||o.type==="CallExpression")&&(o.optional=!1);return o}isOptionalMemberExpression(r){return r.type==="ChainExpression"?r.expression.type==="MemberExpression":super.isOptionalMemberExpression(r)}hasPropertyAsPrivateName(r){return r.type==="ChainExpression"&&(r=r.expression),super.hasPropertyAsPrivateName(r)}isObjectProperty(r){return r.type==="Property"&&r.kind==="init"&&!r.method}isObjectMethod(r){return r.type==="Property"&&(r.method||r.kind==="get"||r.kind==="set")}finishNodeAt(r,n,i){return Wu(super.finishNodeAt(r,n,i))}resetStartLocation(r,n){super.resetStartLocation(r,n),Wu(r)}resetEndLocation(r,n=this.state.lastTokEndLoc){super.resetEndLocation(r,n),Wu(r)}},Io=class{constructor(t,r){this.token=void 0,this.preserveSpace=void 0,this.token=t,this.preserveSpace=!!r}},Qe={brace:new Io("{"),j_oTag:new Io("<tag"),j_cTag:new Io("</tag"),j_expr:new Io("<tag>...</tag>",!0)};Qe.template=new Io("`",!0);var Se=!0,Q=!0,Pb=!0,Yu=!0,Ns=!0,jV=!0,ff=class{constructor(t,r={}){this.label=void 0,this.keyword=void 0,this.beforeExpr=void 0,this.startsExpr=void 0,this.rightAssociative=void 0,this.isLoop=void 0,this.isAssign=void 0,this.prefix=void 0,this.postfix=void 0,this.binop=void 0,this.label=t,this.keyword=r.keyword,this.beforeExpr=!!r.beforeExpr,this.startsExpr=!!r.startsExpr,this.rightAssociative=!!r.rightAssociative,this.isLoop=!!r.isLoop,this.isAssign=!!r.isAssign,this.prefix=!!r.prefix,this.postfix=!!r.postfix,this.binop=r.binop!=null?r.binop:null,this.updateContext=null}},ex=new Map;function ke(e,t={}){t.keyword=e;let r=ie(e,t);return ex.set(e,r),r}function Sr(e,t){return ie(e,{beforeExpr:Se,binop:t})}var Zu=-1,Xi=[],tx=[],rx=[],nx=[],ix=[],sx=[];function ie(e,t={}){var r,n,i,s;return++Zu,tx.push(e),rx.push((r=t.binop)!=null?r:-1),nx.push((n=t.beforeExpr)!=null?n:!1),ix.push((i=t.startsExpr)!=null?i:!1),sx.push((s=t.prefix)!=null?s:!1),Xi.push(new ff(e,t)),Zu}function we(e,t={}){var r,n,i,s;return++Zu,ex.set(e,Zu),tx.push(e),rx.push((r=t.binop)!=null?r:-1),nx.push((n=t.beforeExpr)!=null?n:!1),ix.push((i=t.startsExpr)!=null?i:!1),sx.push((s=t.prefix)!=null?s:!1),Xi.push(new ff("name",t)),Zu}var qV={bracketL:ie("[",{beforeExpr:Se,startsExpr:Q}),bracketHashL:ie("#[",{beforeExpr:Se,startsExpr:Q}),bracketBarL:ie("[|",{beforeExpr:Se,startsExpr:Q}),bracketR:ie("]"),bracketBarR:ie("|]"),braceL:ie("{",{beforeExpr:Se,startsExpr:Q}),braceBarL:ie("{|",{beforeExpr:Se,startsExpr:Q}),braceHashL:ie("#{",{beforeExpr:Se,startsExpr:Q}),braceR:ie("}"),braceBarR:ie("|}"),parenL:ie("(",{beforeExpr:Se,startsExpr:Q}),parenR:ie(")"),comma:ie(",",{beforeExpr:Se}),semi:ie(";",{beforeExpr:Se}),colon:ie(":",{beforeExpr:Se}),doubleColon:ie("::",{beforeExpr:Se}),dot:ie("."),question:ie("?",{beforeExpr:Se}),questionDot:ie("?."),arrow:ie("=>",{beforeExpr:Se}),template:ie("template"),ellipsis:ie("...",{beforeExpr:Se}),backQuote:ie("`",{startsExpr:Q}),dollarBraceL:ie("${",{beforeExpr:Se,startsExpr:Q}),templateTail:ie("...`",{startsExpr:Q}),templateNonTail:ie("...${",{beforeExpr:Se,startsExpr:Q}),at:ie("@"),hash:ie("#",{startsExpr:Q}),interpreterDirective:ie("#!..."),eq:ie("=",{beforeExpr:Se,isAssign:Yu}),assign:ie("_=",{beforeExpr:Se,isAssign:Yu}),slashAssign:ie("_=",{beforeExpr:Se,isAssign:Yu}),xorAssign:ie("_=",{beforeExpr:Se,isAssign:Yu}),moduloAssign:ie("_=",{beforeExpr:Se,isAssign:Yu}),incDec:ie("++/--",{prefix:Ns,postfix:jV,startsExpr:Q}),bang:ie("!",{beforeExpr:Se,prefix:Ns,startsExpr:Q}),tilde:ie("~",{beforeExpr:Se,prefix:Ns,startsExpr:Q}),doubleCaret:ie("^^",{startsExpr:Q}),doubleAt:ie("@@",{startsExpr:Q}),pipeline:Sr("|>",0),nullishCoalescing:Sr("??",1),logicalOR:Sr("||",1),logicalAND:Sr("&&",2),bitwiseOR:Sr("|",3),bitwiseXOR:Sr("^",4),bitwiseAND:Sr("&",5),equality:Sr("==/!=/===/!==",6),lt:Sr("</>/<=/>=",7),gt:Sr("</>/<=/>=",7),relational:Sr("</>/<=/>=",7),bitShift:Sr("<</>>/>>>",8),bitShiftL:Sr("<</>>/>>>",8),bitShiftR:Sr("<</>>/>>>",8),plusMin:ie("+/-",{beforeExpr:Se,binop:9,prefix:Ns,startsExpr:Q}),modulo:ie("%",{binop:10,startsExpr:Q}),star:ie("*",{binop:10}),slash:Sr("/",10),exponent:ie("**",{beforeExpr:Se,binop:11,rightAssociative:!0}),_in:ke("in",{beforeExpr:Se,binop:7}),_instanceof:ke("instanceof",{beforeExpr:Se,binop:7}),_break:ke("break"),_case:ke("case",{beforeExpr:Se}),_catch:ke("catch"),_continue:ke("continue"),_debugger:ke("debugger"),_default:ke("default",{beforeExpr:Se}),_else:ke("else",{beforeExpr:Se}),_finally:ke("finally"),_function:ke("function",{startsExpr:Q}),_if:ke("if"),_return:ke("return",{beforeExpr:Se}),_switch:ke("switch"),_throw:ke("throw",{beforeExpr:Se,prefix:Ns,startsExpr:Q}),_try:ke("try"),_var:ke("var"),_const:ke("const"),_with:ke("with"),_new:ke("new",{beforeExpr:Se,startsExpr:Q}),_this:ke("this",{startsExpr:Q}),_super:ke("super",{startsExpr:Q}),_class:ke("class",{startsExpr:Q}),_extends:ke("extends",{beforeExpr:Se}),_export:ke("export"),_import:ke("import",{startsExpr:Q}),_null:ke("null",{startsExpr:Q}),_true:ke("true",{startsExpr:Q}),_false:ke("false",{startsExpr:Q}),_typeof:ke("typeof",{beforeExpr:Se,prefix:Ns,startsExpr:Q}),_void:ke("void",{beforeExpr:Se,prefix:Ns,startsExpr:Q}),_delete:ke("delete",{beforeExpr:Se,prefix:Ns,startsExpr:Q}),_do:ke("do",{isLoop:Pb,beforeExpr:Se}),_for:ke("for",{isLoop:Pb}),_while:ke("while",{isLoop:Pb}),_as:we("as",{startsExpr:Q}),_assert:we("assert",{startsExpr:Q}),_async:we("async",{startsExpr:Q}),_await:we("await",{startsExpr:Q}),_defer:we("defer",{startsExpr:Q}),_from:we("from",{startsExpr:Q}),_get:we("get",{startsExpr:Q}),_let:we("let",{startsExpr:Q}),_meta:we("meta",{startsExpr:Q}),_of:we("of",{startsExpr:Q}),_sent:we("sent",{startsExpr:Q}),_set:we("set",{startsExpr:Q}),_source:we("source",{startsExpr:Q}),_static:we("static",{startsExpr:Q}),_using:we("using",{startsExpr:Q}),_yield:we("yield",{startsExpr:Q}),_asserts:we("asserts",{startsExpr:Q}),_checks:we("checks",{startsExpr:Q}),_exports:we("exports",{startsExpr:Q}),_global:we("global",{startsExpr:Q}),_implements:we("implements",{startsExpr:Q}),_intrinsic:we("intrinsic",{startsExpr:Q}),_infer:we("infer",{startsExpr:Q}),_is:we("is",{startsExpr:Q}),_mixins:we("mixins",{startsExpr:Q}),_proto:we("proto",{startsExpr:Q}),_require:we("require",{startsExpr:Q}),_satisfies:we("satisfies",{startsExpr:Q}),_keyof:we("keyof",{startsExpr:Q}),_readonly:we("readonly",{startsExpr:Q}),_unique:we("unique",{startsExpr:Q}),_abstract:we("abstract",{startsExpr:Q}),_declare:we("declare",{startsExpr:Q}),_enum:we("enum",{startsExpr:Q}),_module:we("module",{startsExpr:Q}),_namespace:we("namespace",{startsExpr:Q}),_interface:we("interface",{startsExpr:Q}),_type:we("type",{startsExpr:Q}),_opaque:we("opaque",{startsExpr:Q}),name:ie("name",{startsExpr:Q}),string:ie("string",{startsExpr:Q}),num:ie("num",{startsExpr:Q}),bigint:ie("bigint",{startsExpr:Q}),decimal:ie("decimal",{startsExpr:Q}),regexp:ie("regexp",{startsExpr:Q}),privateName:ie("#name",{startsExpr:Q}),eof:ie("eof"),jsxName:ie("jsxName"),jsxText:ie("jsxText",{beforeExpr:!0}),jsxTagStart:ie("jsxTagStart",{startsExpr:!0}),jsxTagEnd:ie("jsxTagEnd"),placeholder:ie("%%",{startsExpr:!0})};function Ue(e){return e>=93&&e<=132}function GV(e){return e<=92}function Vn(e){return e>=58&&e<=132}function jF(e){return e>=58&&e<=136}function zV(e){return nx[e]}function Rb(e){return ix[e]}function HV(e){return e>=29&&e<=33}function _F(e){return e>=129&&e<=131}function KV(e){return e>=90&&e<=92}function ox(e){return e>=58&&e<=92}function VV(e){return e>=39&&e<=59}function WV(e){return e===34}function YV(e){return sx[e]}function JV(e){return e>=121&&e<=123}function XV(e){return e>=124&&e<=130}function Os(e){return tx[e]}function pf(e){return rx[e]}function QV(e){return e===57}function mf(e){return e>=24&&e<=25}function Ji(e){return Xi[e]}Xi[8].updateContext=e=>{e.pop()},Xi[5].updateContext=Xi[7].updateContext=Xi[23].updateContext=e=>{e.push(Qe.brace)},Xi[22].updateContext=e=>{e[e.length-1]===Qe.template?e.pop():e.push(Qe.template)},Xi[142].updateContext=e=>{e.push(Qe.j_expr,Qe.j_oTag)};var ax="\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC",qF="\u200C\u200D\xB7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0CF3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u200C\u200D\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\u30FB\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA8FF-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F\uFF65",ZV=new RegExp("["+ax+"]"),eW=new RegExp("["+ax+qF+"]");ax=qF=null;var GF=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,4026,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,757,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],tW=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,81,2,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,9,5351,0,7,14,13835,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,983,6,110,6,6,9,4759,9,787719,239];function Ob(e,t){let r=65536;for(let n=0,i=t.length;n<i;n+=2){if(r+=t[n],r>e)return!1;if(r+=t[n+1],r>=e)return!0}return!1}function Qi(e){return e<65?e===36:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&ZV.test(String.fromCharCode(e)):Ob(e,GF)}function Ka(e){return e<48?e===36:e<58?!0:e<65?!1:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&eW.test(String.fromCharCode(e)):Ob(e,GF)||Ob(e,tW)}var cx={keyword:["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete"],strict:["implements","interface","let","package","private","protected","public","static","yield"],strictBind:["eval","arguments"]},rW=new Set(cx.keyword),nW=new Set(cx.strict),iW=new Set(cx.strictBind);function zF(e,t){return t&&e==="await"||e==="enum"}function HF(e,t){return zF(e,t)||nW.has(e)}function KF(e){return iW.has(e)}function VF(e,t){return HF(e,t)||KF(e)}function sW(e){return rW.has(e)}function oW(e,t,r){return e===64&&t===64&&Qi(r)}var aW=new Set(["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete","implements","interface","let","package","private","protected","public","static","yield","eval","arguments","enum","await"]);function cW(e){return aW.has(e)}var el=class{constructor(t){this.flags=0,this.names=new Map,this.firstLexicalName="",this.flags=t}},tl=class{constructor(t,r){this.parser=void 0,this.scopeStack=[],this.inModule=void 0,this.undefinedExports=new Map,this.parser=t,this.inModule=r}get inTopLevel(){return(this.currentScope().flags&1)>0}get inFunction(){return(this.currentVarScopeFlags()&2)>0}get allowSuper(){return(this.currentThisScopeFlags()&16)>0}get allowDirectSuper(){return(this.currentThisScopeFlags()&32)>0}get inClass(){return(this.currentThisScopeFlags()&64)>0}get inClassAndNotInNonArrowFunction(){let t=this.currentThisScopeFlags();return(t&64)>0&&(t&2)===0}get inStaticBlock(){for(let t=this.scopeStack.length-1;;t--){let{flags:r}=this.scopeStack[t];if(r&128)return!0;if(r&451)return!1}}get inNonArrowFunction(){return(this.currentThisScopeFlags()&2)>0}get treatFunctionsAsVar(){return this.treatFunctionsAsVarInScope(this.currentScope())}createScope(t){return new el(t)}enter(t){this.scopeStack.push(this.createScope(t))}exit(){return this.scopeStack.pop().flags}treatFunctionsAsVarInScope(t){return!!(t.flags&130||!this.parser.inModule&&t.flags&1)}declareName(t,r,n){let i=this.currentScope();if(r&8||r&16){this.checkRedeclarationInScope(i,t,r,n);let s=i.names.get(t)||0;r&16?s=s|4:(i.firstLexicalName||(i.firstLexicalName=t),s=s|2),i.names.set(t,s),r&8&&this.maybeExportDefined(i,t)}else if(r&4)for(let s=this.scopeStack.length-1;s>=0&&(i=this.scopeStack[s],this.checkRedeclarationInScope(i,t,r,n),i.names.set(t,(i.names.get(t)||0)|1),this.maybeExportDefined(i,t),!(i.flags&387));--s);this.parser.inModule&&i.flags&1&&this.undefinedExports.delete(t)}maybeExportDefined(t,r){this.parser.inModule&&t.flags&1&&this.undefinedExports.delete(r)}checkRedeclarationInScope(t,r,n,i){this.isRedeclaredInScope(t,r,n)&&this.parser.raise(_.VarRedeclaration,i,{identifierName:r})}isRedeclaredInScope(t,r,n){if(!(n&1))return!1;if(n&8)return t.names.has(r);let i=t.names.get(r);return n&16?(i&2)>0||!this.treatFunctionsAsVarInScope(t)&&(i&1)>0:(i&2)>0&&!(t.flags&8&&t.firstLexicalName===r)||!this.treatFunctionsAsVarInScope(t)&&(i&4)>0}checkLocalExport(t){let{name:r}=t;this.scopeStack[0].names.has(r)||this.undefinedExports.set(r,t.loc.start)}currentScope(){return this.scopeStack[this.scopeStack.length-1]}currentVarScopeFlags(){for(let t=this.scopeStack.length-1;;t--){let{flags:r}=this.scopeStack[t];if(r&387)return r}}currentThisScopeFlags(){for(let t=this.scopeStack.length-1;;t--){let{flags:r}=this.scopeStack[t];if(r&451&&!(r&4))return r}}},Bb=class extends el{constructor(...t){super(...t),this.declareFunctions=new Set}},Mb=class extends tl{createScope(t){return new Bb(t)}declareName(t,r,n){let i=this.currentScope();if(r&2048){this.checkRedeclarationInScope(i,t,r,n),this.maybeExportDefined(i,t),i.declareFunctions.add(t);return}super.declareName(t,r,n)}isRedeclaredInScope(t,r,n){if(super.isRedeclaredInScope(t,r,n))return!0;if(n&2048&&!t.declareFunctions.has(r)){let i=t.names.get(r);return(i&4)>0||(i&2)>0}return!1}checkLocalExport(t){this.scopeStack[0].declareFunctions.has(t.name)||super.checkLocalExport(t)}},Lb=class{constructor(){this.sawUnambiguousESM=!1,this.ambiguousScriptDifferentAst=!1}hasPlugin(t){if(typeof t=="string")return this.plugins.has(t);{let[r,n]=t;if(!this.hasPlugin(r))return!1;let i=this.plugins.get(r);for(let s of Object.keys(n))if(i?.[s]!==n[s])return!1;return!0}}getPluginOption(t,r){var n;return(n=this.plugins.get(t))==null?void 0:n[r]}};function WF(e,t){e.trailingComments===void 0?e.trailingComments=t:e.trailingComments.unshift(...t)}function uW(e,t){e.leadingComments===void 0?e.leadingComments=t:e.leadingComments.unshift(...t)}function rl(e,t){e.innerComments===void 0?e.innerComments=t:e.innerComments.unshift(...t)}function Ju(e,t,r){let n=null,i=t.length;for(;n===null&&i>0;)n=t[--i];n===null||n.start>r.start?rl(e,r.comments):WF(n,r.comments)}var $b=class extends Lb{addComment(t){this.filename&&(t.loc.filename=this.filename);let{commentsLen:r}=this.state;this.comments.length!==r&&(this.comments.length=r),this.comments.push(t),this.state.commentsLen++}processComment(t){let{commentStack:r}=this.state,n=r.length;if(n===0)return;let i=n-1,s=r[i];s.start===t.end&&(s.leadingNode=t,i--);let{start:o}=t;for(;i>=0;i--){let a=r[i],c=a.end;if(c>o)a.containingNode=t,this.finalizeComment(a),r.splice(i,1);else{c===o&&(a.trailingNode=t);break}}}finalizeComment(t){let{comments:r}=t;if(t.leadingNode!==null||t.trailingNode!==null)t.leadingNode!==null&&WF(t.leadingNode,r),t.trailingNode!==null&&uW(t.trailingNode,r);else{let{containingNode:n,start:i}=t;if(this.input.charCodeAt(i-1)===44)switch(n.type){case"ObjectExpression":case"ObjectPattern":case"RecordExpression":Ju(n,n.properties,t);break;case"CallExpression":case"OptionalCallExpression":Ju(n,n.arguments,t);break;case"FunctionDeclaration":case"FunctionExpression":case"ArrowFunctionExpression":case"ObjectMethod":case"ClassMethod":case"ClassPrivateMethod":Ju(n,n.params,t);break;case"ArrayExpression":case"ArrayPattern":case"TupleExpression":Ju(n,n.elements,t);break;case"ExportNamedDeclaration":case"ImportDeclaration":Ju(n,n.specifiers,t);break;default:rl(n,r)}else rl(n,r)}}finalizeRemainingComments(){let{commentStack:t}=this.state;for(let r=t.length-1;r>=0;r--)this.finalizeComment(t[r]);this.state.commentStack=[]}resetPreviousNodeTrailingComments(t){let{commentStack:r}=this.state,{length:n}=r;if(n===0)return;let i=r[n-1];i.leadingNode===t&&(i.leadingNode=null)}resetPreviousIdentifierLeadingComments(t){let{commentStack:r}=this.state,{length:n}=r;n!==0&&(r[n-1].trailingNode===t?r[n-1].trailingNode=null:n>=2&&r[n-2].trailingNode===t&&(r[n-2].trailingNode=null))}takeSurroundingComments(t,r,n){let{commentStack:i}=this.state,s=i.length;if(s===0)return;let o=s-1;for(;o>=0;o--){let a=i[o],c=a.end;if(a.start===n)a.leadingNode=t;else if(c===r)a.trailingNode=t;else if(c<r)break}}},lW=/\r\n|[\r\n\u2028\u2029]/,cf=new RegExp(lW.source,"g");function Va(e){switch(e){case 10:case 13:case 8232:case 8233:return!0;default:return!1}}function IF(e,t,r){for(let n=t;n<r;n++)if(Va(e.charCodeAt(n)))return!0;return!1}var Fb=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,_b=/(?:[^\S\n\r\u2028\u2029]|\/\/.*|\/\*.*?\*\/)*/g;function pW(e){switch(e){case 9:case 11:case 12:case 32:case 160:case 5760:case 8192:case 8193:case 8194:case 8195:case 8196:case 8197:case 8198:case 8199:case 8200:case 8201:case 8202:case 8239:case 8287:case 12288:case 65279:return!0;default:return!1}}var Ub=class e{constructor(){this.flags=1024,this.curLine=void 0,this.lineStart=void 0,this.startLoc=void 0,this.endLoc=void 0,this.errors=[],this.potentialArrowAt=-1,this.noArrowAt=[],this.noArrowParamsConversionAt=[],this.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null},this.labels=[],this.commentsLen=0,this.commentStack=[],this.pos=0,this.type=139,this.value=null,this.start=0,this.end=0,this.lastTokEndLoc=null,this.lastTokStartLoc=null,this.context=[Qe.brace],this.firstInvalidTemplateEscapePos=null,this.strictErrors=new Map,this.tokensLength=0}get strict(){return(this.flags&1)>0}set strict(t){t?this.flags|=1:this.flags&=-2}init({strictMode:t,sourceType:r,startLine:n,startColumn:i}){this.strict=t===!1?!1:t===!0?!0:r==="module",this.curLine=n,this.lineStart=-i,this.startLoc=this.endLoc=new vi(n,i,0)}get maybeInArrowParameters(){return(this.flags&2)>0}set maybeInArrowParameters(t){t?this.flags|=2:this.flags&=-3}get inType(){return(this.flags&4)>0}set inType(t){t?this.flags|=4:this.flags&=-5}get noAnonFunctionType(){return(this.flags&8)>0}set noAnonFunctionType(t){t?this.flags|=8:this.flags&=-9}get hasFlowComment(){return(this.flags&16)>0}set hasFlowComment(t){t?this.flags|=16:this.flags&=-17}get isAmbientContext(){return(this.flags&32)>0}set isAmbientContext(t){t?this.flags|=32:this.flags&=-33}get inAbstractClass(){return(this.flags&64)>0}set inAbstractClass(t){t?this.flags|=64:this.flags&=-65}get inDisallowConditionalTypesContext(){return(this.flags&128)>0}set inDisallowConditionalTypesContext(t){t?this.flags|=128:this.flags&=-129}get soloAwait(){return(this.flags&256)>0}set soloAwait(t){t?this.flags|=256:this.flags&=-257}get inFSharpPipelineDirectBody(){return(this.flags&512)>0}set inFSharpPipelineDirectBody(t){t?this.flags|=512:this.flags&=-513}get canStartJSXElement(){return(this.flags&1024)>0}set canStartJSXElement(t){t?this.flags|=1024:this.flags&=-1025}get containsEsc(){return(this.flags&2048)>0}set containsEsc(t){t?this.flags|=2048:this.flags&=-2049}get hasTopLevelAwait(){return(this.flags&4096)>0}set hasTopLevelAwait(t){t?this.flags|=4096:this.flags&=-4097}curPosition(){return new vi(this.curLine,this.pos-this.lineStart,this.pos)}clone(){let t=new e;return t.flags=this.flags,t.curLine=this.curLine,t.lineStart=this.lineStart,t.startLoc=this.startLoc,t.endLoc=this.endLoc,t.errors=this.errors.slice(),t.potentialArrowAt=this.potentialArrowAt,t.noArrowAt=this.noArrowAt.slice(),t.noArrowParamsConversionAt=this.noArrowParamsConversionAt.slice(),t.topicContext=this.topicContext,t.labels=this.labels.slice(),t.commentsLen=this.commentsLen,t.commentStack=this.commentStack.slice(),t.pos=this.pos,t.type=this.type,t.value=this.value,t.start=this.start,t.end=this.end,t.lastTokEndLoc=this.lastTokEndLoc,t.lastTokStartLoc=this.lastTokStartLoc,t.context=this.context.slice(),t.firstInvalidTemplateEscapePos=this.firstInvalidTemplateEscapePos,t.strictErrors=this.strictErrors,t.tokensLength=this.tokensLength,t}},dW=function(t){return t>=48&&t<=57},kF={decBinOct:new Set([46,66,69,79,95,98,101,111]),hex:new Set([46,88,95,120])},uf={bin:e=>e===48||e===49,oct:e=>e>=48&&e<=55,dec:e=>e>=48&&e<=57,hex:e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102};function NF(e,t,r,n,i,s){let o=r,a=n,c=i,u="",l=null,p=r,{length:d}=t;for(;;){if(r>=d){s.unterminated(o,a,c),u+=t.slice(p,r);break}let h=t.charCodeAt(r);if(fW(e,h,t,r)){u+=t.slice(p,r);break}if(h===92){u+=t.slice(p,r);let m=mW(t,r,n,i,e==="template",s);m.ch===null&&!l?l={pos:r,lineStart:n,curLine:i}:u+=m.ch,{pos:r,lineStart:n,curLine:i}=m,p=r}else h===8232||h===8233?(++r,++i,n=r):h===10||h===13?e==="template"?(u+=t.slice(p,r)+`
17
+ - Did you mean \`import { "${e}" as foo }\`?`,ImportCallArgumentTrailingComma:"Trailing comma is disallowed inside import(...) arguments.",ImportCallArity:({maxArgumentCount:e})=>`\`import()\` requires exactly ${e===1?"one argument":"one or two arguments"}.`,ImportCallNotNewExpression:"Cannot use new with import(...).",ImportCallSpreadArgument:"`...` is not allowed in `import()`.",ImportJSONBindingNotDefault:"A JSON module can only be imported with `default`.",ImportReflectionHasAssertion:"`import module x` cannot have assertions.",ImportReflectionNotBinding:'Only `import module x from "./module"` is valid.',IncompatibleRegExpUVFlags:"The 'u' and 'v' regular expression flags cannot be enabled at the same time.",InvalidBigIntLiteral:"Invalid BigIntLiteral.",InvalidCodePoint:"Code point out of bounds.",InvalidCoverInitializedName:"Invalid shorthand property initializer.",InvalidDecimal:"Invalid decimal.",InvalidDigit:({radix:e})=>`Expected number in radix ${e}.`,InvalidEscapeSequence:"Bad character escape sequence.",InvalidEscapeSequenceTemplate:"Invalid escape sequence in template.",InvalidEscapedReservedWord:({reservedWord:e})=>`Escape sequence in keyword ${e}.`,InvalidIdentifier:({identifierName:e})=>`Invalid identifier ${e}.`,InvalidLhs:({ancestor:e})=>`Invalid left-hand side in ${lf(e)}.`,InvalidLhsBinding:({ancestor:e})=>`Binding invalid left-hand side in ${lf(e)}.`,InvalidLhsOptionalChaining:({ancestor:e})=>`Invalid optional chaining in the left-hand side of ${lf(e)}.`,InvalidNumber:"Invalid number.",InvalidOrMissingExponent:"Floating-point numbers require a valid exponent after the 'e'.",InvalidOrUnexpectedToken:({unexpected:e})=>`Unexpected character '${e}'.`,InvalidParenthesizedAssignment:"Invalid parenthesized assignment pattern.",InvalidPrivateFieldResolution:({identifierName:e})=>`Private name #${e} is not defined.`,InvalidPropertyBindingPattern:"Binding member expression.",InvalidRecordProperty:"Only properties and spread elements are allowed in record definitions.",InvalidRestAssignmentPattern:"Invalid rest operator's argument.",LabelRedeclaration:({labelName:e})=>`Label '${e}' is already declared.`,LetInLexicalBinding:"'let' is disallowed as a lexically bound name.",LineTerminatorBeforeArrow:"No line break is allowed before '=>'.",MalformedRegExpFlags:"Invalid regular expression flag.",MissingClassName:"A class name is required.",MissingEqInAssignment:"Only '=' operator can be used for specifying default value.",MissingSemicolon:"Missing semicolon.",MissingPlugin:({missingPlugin:e})=>`This experimental syntax requires enabling the parser plugin: ${e.map(t=>JSON.stringify(t)).join(", ")}.`,MissingOneOfPlugins:({missingPlugin:e})=>`This experimental syntax requires enabling one of the following parser plugin(s): ${e.map(t=>JSON.stringify(t)).join(", ")}.`,MissingUnicodeEscape:"Expecting Unicode escape sequence \\uXXXX.",MixingCoalesceWithLogical:"Nullish coalescing operator(??) requires parens when mixing with logical operators.",ModuleAttributeDifferentFromType:"The only accepted module attribute is `type`.",ModuleAttributeInvalidValue:"Only string literals are allowed as module attribute values.",ModuleAttributesWithDuplicateKeys:({key:e})=>`Duplicate key "${e}" is not allowed in module attributes.`,ModuleExportNameHasLoneSurrogate:({surrogateCharCode:e})=>`An export name cannot include a lone surrogate, found '\\u${e.toString(16)}'.`,ModuleExportUndefined:({localName:e})=>`Export '${e}' is not defined.`,MultipleDefaultsInSwitch:"Multiple default clauses.",NewlineAfterThrow:"Illegal newline after throw.",NoCatchOrFinally:"Missing catch or finally clause.",NumberIdentifier:"Identifier directly after number.",NumericSeparatorInEscapeSequence:"Numeric separators are not allowed inside unicode escape sequences or hex escape sequences.",ObsoleteAwaitStar:"'await*' has been removed from the async functions proposal. Use Promise.all() instead.",OptionalChainingNoNew:"Constructors in/after an Optional Chain are not allowed.",OptionalChainingNoTemplate:"Tagged Template Literals are not allowed in optionalChain.",OverrideOnConstructor:"'override' modifier cannot appear on a constructor declaration.",ParamDupe:"Argument name clash.",PatternHasAccessor:"Object pattern can't contain getter or setter.",PatternHasMethod:"Object pattern can't contain methods.",PrivateInExpectedIn:({identifierName:e})=>`Private names are only allowed in property accesses (\`obj.#${e}\`) or in \`in\` expressions (\`#${e} in obj\`).`,PrivateNameRedeclaration:({identifierName:e})=>`Duplicate private name #${e}.`,RecordExpressionBarIncorrectEndSyntaxType:"Record expressions ending with '|}' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",RecordExpressionBarIncorrectStartSyntaxType:"Record expressions starting with '{|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",RecordExpressionHashIncorrectStartSyntaxType:"Record expressions starting with '#{' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.",RecordNoProto:"'__proto__' is not allowed in Record expressions.",RestTrailingComma:"Unexpected trailing comma after rest element.",SloppyFunction:"In non-strict mode code, functions can only be declared at top level or inside a block.",SloppyFunctionAnnexB:"In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement.",SourcePhaseImportRequiresDefault:'Only `import source x from "./module"` is valid.',StaticPrototype:"Classes may not have static property named prototype.",SuperNotAllowed:"`super()` is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?",SuperPrivateField:"Private fields can't be accessed on super.",TrailingDecorator:"Decorators must be attached to a class element.",TupleExpressionBarIncorrectEndSyntaxType:"Tuple expressions ending with '|]' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",TupleExpressionBarIncorrectStartSyntaxType:"Tuple expressions starting with '[|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.",TupleExpressionHashIncorrectStartSyntaxType:"Tuple expressions starting with '#[' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.",UnexpectedArgumentPlaceholder:"Unexpected argument placeholder.",UnexpectedAwaitAfterPipelineBody:'Unexpected "await" after pipeline body; await must have parentheses in minimal proposal.',UnexpectedDigitAfterHash:"Unexpected digit after hash token.",UnexpectedImportExport:"'import' and 'export' may only appear at the top level.",UnexpectedKeyword:({keyword:e})=>`Unexpected keyword '${e}'.`,UnexpectedLeadingDecorator:"Leading decorators must be attached to a class declaration.",UnexpectedLexicalDeclaration:"Lexical declaration cannot appear in a single-statement context.",UnexpectedNewTarget:"`new.target` can only be used in functions or class properties.",UnexpectedNumericSeparator:"A numeric separator is only allowed between two digits.",UnexpectedPrivateField:"Unexpected private name.",UnexpectedReservedWord:({reservedWord:e})=>`Unexpected reserved word '${e}'.`,UnexpectedSuper:"'super' is only allowed in object methods and classes.",UnexpectedToken:({expected:e,unexpected:t})=>`Unexpected token${t?` '${t}'.`:""}${e?`, expected "${e}"`:""}`,UnexpectedTokenUnaryExponentiation:"Illegal expression. Wrap left hand side or entire exponentiation in parentheses.",UnexpectedUsingDeclaration:"Using declaration cannot appear in the top level when source type is `script`.",UnsupportedBind:"Binding should be performed on object property.",UnsupportedDecoratorExport:"A decorated export must export a class declaration.",UnsupportedDefaultExport:"Only expressions, functions or classes are allowed as the `default` export.",UnsupportedImport:"`import` can only be used in `import()` or `import.meta`.",UnsupportedMetaProperty:({target:e,onlyValidPropertyName:t})=>`The only valid meta property for ${e} is ${e}.${t}.`,UnsupportedParameterDecorator:"Decorators cannot be used to decorate parameters.",UnsupportedPropertyDecorator:"Decorators cannot be used to decorate object literal properties.",UnsupportedSuper:"'super' can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop]).",UnterminatedComment:"Unterminated comment.",UnterminatedRegExp:"Unterminated regular expression.",UnterminatedString:"Unterminated string constant.",UnterminatedTemplate:"Unterminated template.",UsingDeclarationExport:"Using declaration cannot be exported.",UsingDeclarationHasBindingPattern:"Using declaration cannot have destructuring patterns.",VarRedeclaration:({identifierName:e})=>`Identifier '${e}' has already been declared.`,YieldBindingIdentifier:"Can not use 'yield' as identifier inside a generator.",YieldInParameter:"Yield expression is not allowed in formal parameters.",ZeroDigitNumericSeparator:"Numeric separator can not be used after leading 0."},RV={StrictDelete:"Deleting local variable in strict mode.",StrictEvalArguments:({referenceName:e})=>`Assigning to '${e}' in strict mode.`,StrictEvalArgumentsBinding:({bindingName:e})=>`Binding '${e}' in strict mode.`,StrictFunction:"In strict mode code, functions can only be declared at top level or inside a block.",StrictNumericEscape:"The only valid numeric escape in strict mode is '\\0'.",StrictOctalLiteral:"Legacy octal literals are not allowed in strict mode.",StrictWith:"'with' in strict mode."},OV=new Set(["ArrowFunctionExpression","AssignmentExpression","ConditionalExpression","YieldExpression"]),BV={PipeBodyIsTighter:"Unexpected yield after pipeline body; any yield expression acting as Hack-style pipe body must be parenthesized due to its loose operator precedence.",PipeTopicRequiresHackPipes:'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.',PipeTopicUnbound:"Topic reference is unbound; it must be inside a pipe body.",PipeTopicUnconfiguredToken:({token:e})=>`Invalid topic token ${e}. In order to use ${e} as a topic reference, the pipelineOperator plugin must be configured with { "proposal": "hack", "topicToken": "${e}" }.`,PipeTopicUnused:"Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once.",PipeUnparenthesizedBody:({type:e})=>`Hack-style pipe body cannot be an unparenthesized ${lf({type:e})}; please wrap it in parentheses.`,PipelineBodyNoArrow:'Unexpected arrow "=>" after pipeline body; arrow function in pipeline body must be parenthesized.',PipelineBodySequenceExpression:"Pipeline body may not be a comma-separated sequence expression.",PipelineHeadSequenceExpression:"Pipeline head should not be a comma-separated sequence expression.",PipelineTopicUnused:"Pipeline is in topic style but does not use topic reference.",PrimaryTopicNotAllowed:"Topic reference was used in a lexical context without topic binding.",PrimaryTopicRequiresSmartPipeline:'Topic reference is used, but the pipelineOperator plugin was not passed a "proposal": "hack" or "smart" option.'},MV=["message"];function PF(e,t,r){Object.defineProperty(e,t,{enumerable:!1,configurable:!0,value:r})}function LV({toMessage:e,code:t,reasonCode:r,syntaxPlugin:n}){let i=r==="MissingPlugin"||r==="MissingOneOfPlugins";{let s={AccessorCannotDeclareThisParameter:"AccesorCannotDeclareThisParameter",AccessorCannotHaveTypeParameters:"AccesorCannotHaveTypeParameters",ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference:"ConstInitiailizerMustBeStringOrNumericLiteralOrLiteralEnumReference",SetAccessorCannotHaveOptionalParameter:"SetAccesorCannotHaveOptionalParameter",SetAccessorCannotHaveRestParameter:"SetAccesorCannotHaveRestParameter",SetAccessorCannotHaveReturnType:"SetAccesorCannotHaveReturnType"};s[r]&&(r=s[r])}return function s(o,a){let c=new SyntaxError;return c.code=t,c.reasonCode=r,c.loc=o,c.pos=o.index,c.syntaxPlugin=n,i&&(c.missingPlugin=a.missingPlugin),PF(c,"clone",function(l={}){var p;let{line:d,column:h,index:m}=(p=l.loc)!=null?p:o;return s(new vi(d,h,m),Object.assign({},a,l.details))}),PF(c,"details",a),Object.defineProperty(c,"message",{configurable:!0,get(){let u=`${e(a)} (${o.line}:${o.column})`;return this.message=u,u},set(u){Object.defineProperty(this,"message",{value:u,writable:!0})}}),c}}function Zi(e,t){if(Array.isArray(e))return n=>Zi(n,e[0]);let r={};for(let n of Object.keys(e)){let i=e[n],s=typeof i=="string"?{message:()=>i}:typeof i=="function"?{message:i}:i,{message:o}=s,a=IV(s,MV),c=typeof o=="string"?()=>o:o;r[n]=LV(Object.assign({code:"BABEL_PARSER_SYNTAX_ERROR",reasonCode:n,toMessage:c},t?{syntaxPlugin:t}:{},a))}return r}var _=Object.assign({},Zi(kV),Zi(NV),Zi(RV),Zi`pipelineOperator`(BV)),{defineProperty:$V}=Object,FF=(e,t)=>{e&&$V(e,t,{enumerable:!1,value:e[t]})};function Wu(e){return FF(e.loc.start,"index"),FF(e.loc.end,"index"),e}var UV=e=>class extends e{parse(){let r=Wu(super.parse());return this.options.tokens&&(r.tokens=r.tokens.map(Wu)),r}parseRegExpLiteral({pattern:r,flags:n}){let i=null;try{i=new RegExp(r,n)}catch{}let s=this.estreeParseLiteral(i);return s.regex={pattern:r,flags:n},s}parseBigIntLiteral(r){let n;try{n=BigInt(r)}catch{n=null}let i=this.estreeParseLiteral(n);return i.bigint=String(i.value||r),i}parseDecimalLiteral(r){let i=this.estreeParseLiteral(null);return i.decimal=String(i.value||r),i}estreeParseLiteral(r){return this.parseLiteral(r,"Literal")}parseStringLiteral(r){return this.estreeParseLiteral(r)}parseNumericLiteral(r){return this.estreeParseLiteral(r)}parseNullLiteral(){return this.estreeParseLiteral(null)}parseBooleanLiteral(r){return this.estreeParseLiteral(r)}directiveToStmt(r){let n=r.value;delete r.value,n.type="Literal",n.raw=n.extra.raw,n.value=n.extra.expressionValue;let i=r;return i.type="ExpressionStatement",i.expression=n,i.directive=n.extra.rawValue,delete n.extra,i}initFunction(r,n){super.initFunction(r,n),r.expression=!1}checkDeclaration(r){r!=null&&this.isObjectProperty(r)?this.checkDeclaration(r.value):super.checkDeclaration(r)}getObjectOrClassMethodParams(r){return r.value.params}isValidDirective(r){var n;return r.type==="ExpressionStatement"&&r.expression.type==="Literal"&&typeof r.expression.value=="string"&&!((n=r.expression.extra)!=null&&n.parenthesized)}parseBlockBody(r,n,i,s,o){super.parseBlockBody(r,n,i,s,o);let a=r.directives.map(c=>this.directiveToStmt(c));r.body=a.concat(r.body),delete r.directives}pushClassMethod(r,n,i,s,o,a){this.parseMethod(n,i,s,o,a,"ClassMethod",!0),n.typeParameters&&(n.value.typeParameters=n.typeParameters,delete n.typeParameters),r.body.push(n)}parsePrivateName(){let r=super.parsePrivateName();return this.getPluginOption("estree","classFeatures")?this.convertPrivateNameToPrivateIdentifier(r):r}convertPrivateNameToPrivateIdentifier(r){let n=super.getPrivateNameSV(r);return r=r,delete r.id,r.name=n,r.type="PrivateIdentifier",r}isPrivateName(r){return this.getPluginOption("estree","classFeatures")?r.type==="PrivateIdentifier":super.isPrivateName(r)}getPrivateNameSV(r){return this.getPluginOption("estree","classFeatures")?r.name:super.getPrivateNameSV(r)}parseLiteral(r,n){let i=super.parseLiteral(r,n);return i.raw=i.extra.raw,delete i.extra,i}parseFunctionBody(r,n,i=!1){super.parseFunctionBody(r,n,i),r.expression=r.body.type!=="BlockStatement"}parseMethod(r,n,i,s,o,a,c=!1){let u=this.startNode();return u.kind=r.kind,u=super.parseMethod(u,n,i,s,o,a,c),u.type="FunctionExpression",delete u.kind,r.value=u,a==="ClassPrivateMethod"&&(r.computed=!1),this.finishNode(r,"MethodDefinition")}nameIsConstructor(r){return r.type==="Literal"?r.value==="constructor":super.nameIsConstructor(r)}parseClassProperty(...r){let n=super.parseClassProperty(...r);return this.getPluginOption("estree","classFeatures")&&(n.type="PropertyDefinition"),n}parseClassPrivateProperty(...r){let n=super.parseClassPrivateProperty(...r);return this.getPluginOption("estree","classFeatures")&&(n.type="PropertyDefinition",n.computed=!1),n}parseObjectMethod(r,n,i,s,o){let a=super.parseObjectMethod(r,n,i,s,o);return a&&(a.type="Property",a.kind==="method"&&(a.kind="init"),a.shorthand=!1),a}parseObjectProperty(r,n,i,s){let o=super.parseObjectProperty(r,n,i,s);return o&&(o.kind="init",o.type="Property"),o}isValidLVal(r,n,i){return r==="Property"?"value":super.isValidLVal(r,n,i)}isAssignable(r,n){return r!=null&&this.isObjectProperty(r)?this.isAssignable(r.value,n):super.isAssignable(r,n)}toAssignable(r,n=!1){if(r!=null&&this.isObjectProperty(r)){let{key:i,value:s}=r;this.isPrivateName(i)&&this.classScope.usePrivateName(this.getPrivateNameSV(i),i.loc.start),this.toAssignable(s,n)}else super.toAssignable(r,n)}toAssignableObjectExpressionProp(r,n,i){r.type==="Property"&&(r.kind==="get"||r.kind==="set")?this.raise(_.PatternHasAccessor,r.key):r.type==="Property"&&r.method?this.raise(_.PatternHasMethod,r.key):super.toAssignableObjectExpressionProp(r,n,i)}finishCallExpression(r,n){let i=super.finishCallExpression(r,n);if(i.callee.type==="Import"){if(i.type="ImportExpression",i.source=i.arguments[0],this.hasPlugin("importAttributes")||this.hasPlugin("importAssertions")){var s,o;i.options=(s=i.arguments[1])!=null?s:null,i.attributes=(o=i.arguments[1])!=null?o:null}delete i.arguments,delete i.callee}return i}toReferencedArguments(r){r.type!=="ImportExpression"&&super.toReferencedArguments(r)}parseExport(r,n){let i=this.state.lastTokStartLoc,s=super.parseExport(r,n);switch(s.type){case"ExportAllDeclaration":s.exported=null;break;case"ExportNamedDeclaration":s.specifiers.length===1&&s.specifiers[0].type==="ExportNamespaceSpecifier"&&(s.type="ExportAllDeclaration",s.exported=s.specifiers[0].exported,delete s.specifiers);case"ExportDefaultDeclaration":{var o;let{declaration:a}=s;a?.type==="ClassDeclaration"&&((o=a.decorators)==null?void 0:o.length)>0&&a.start===s.start&&this.resetStartLocation(s,i)}break}return s}parseSubscript(r,n,i,s){let o=super.parseSubscript(r,n,i,s);if(s.optionalChainMember){if((o.type==="OptionalMemberExpression"||o.type==="OptionalCallExpression")&&(o.type=o.type.substring(8)),s.stop){let a=this.startNodeAtNode(o);return a.expression=o,this.finishNode(a,"ChainExpression")}}else(o.type==="MemberExpression"||o.type==="CallExpression")&&(o.optional=!1);return o}isOptionalMemberExpression(r){return r.type==="ChainExpression"?r.expression.type==="MemberExpression":super.isOptionalMemberExpression(r)}hasPropertyAsPrivateName(r){return r.type==="ChainExpression"&&(r=r.expression),super.hasPropertyAsPrivateName(r)}isObjectProperty(r){return r.type==="Property"&&r.kind==="init"&&!r.method}isObjectMethod(r){return r.type==="Property"&&(r.method||r.kind==="get"||r.kind==="set")}finishNodeAt(r,n,i){return Wu(super.finishNodeAt(r,n,i))}resetStartLocation(r,n){super.resetStartLocation(r,n),Wu(r)}resetEndLocation(r,n=this.state.lastTokEndLoc){super.resetEndLocation(r,n),Wu(r)}},Io=class{constructor(t,r){this.token=void 0,this.preserveSpace=void 0,this.token=t,this.preserveSpace=!!r}},Qe={brace:new Io("{"),j_oTag:new Io("<tag"),j_cTag:new Io("</tag"),j_expr:new Io("<tag>...</tag>",!0)};Qe.template=new Io("`",!0);var Te=!0,Q=!0,Pb=!0,Yu=!0,Ns=!0,jV=!0,ff=class{constructor(t,r={}){this.label=void 0,this.keyword=void 0,this.beforeExpr=void 0,this.startsExpr=void 0,this.rightAssociative=void 0,this.isLoop=void 0,this.isAssign=void 0,this.prefix=void 0,this.postfix=void 0,this.binop=void 0,this.label=t,this.keyword=r.keyword,this.beforeExpr=!!r.beforeExpr,this.startsExpr=!!r.startsExpr,this.rightAssociative=!!r.rightAssociative,this.isLoop=!!r.isLoop,this.isAssign=!!r.isAssign,this.prefix=!!r.prefix,this.postfix=!!r.postfix,this.binop=r.binop!=null?r.binop:null,this.updateContext=null}},ex=new Map;function ke(e,t={}){t.keyword=e;let r=ie(e,t);return ex.set(e,r),r}function Sr(e,t){return ie(e,{beforeExpr:Te,binop:t})}var Zu=-1,Xi=[],tx=[],rx=[],nx=[],ix=[],sx=[];function ie(e,t={}){var r,n,i,s;return++Zu,tx.push(e),rx.push((r=t.binop)!=null?r:-1),nx.push((n=t.beforeExpr)!=null?n:!1),ix.push((i=t.startsExpr)!=null?i:!1),sx.push((s=t.prefix)!=null?s:!1),Xi.push(new ff(e,t)),Zu}function Se(e,t={}){var r,n,i,s;return++Zu,ex.set(e,Zu),tx.push(e),rx.push((r=t.binop)!=null?r:-1),nx.push((n=t.beforeExpr)!=null?n:!1),ix.push((i=t.startsExpr)!=null?i:!1),sx.push((s=t.prefix)!=null?s:!1),Xi.push(new ff("name",t)),Zu}var qV={bracketL:ie("[",{beforeExpr:Te,startsExpr:Q}),bracketHashL:ie("#[",{beforeExpr:Te,startsExpr:Q}),bracketBarL:ie("[|",{beforeExpr:Te,startsExpr:Q}),bracketR:ie("]"),bracketBarR:ie("|]"),braceL:ie("{",{beforeExpr:Te,startsExpr:Q}),braceBarL:ie("{|",{beforeExpr:Te,startsExpr:Q}),braceHashL:ie("#{",{beforeExpr:Te,startsExpr:Q}),braceR:ie("}"),braceBarR:ie("|}"),parenL:ie("(",{beforeExpr:Te,startsExpr:Q}),parenR:ie(")"),comma:ie(",",{beforeExpr:Te}),semi:ie(";",{beforeExpr:Te}),colon:ie(":",{beforeExpr:Te}),doubleColon:ie("::",{beforeExpr:Te}),dot:ie("."),question:ie("?",{beforeExpr:Te}),questionDot:ie("?."),arrow:ie("=>",{beforeExpr:Te}),template:ie("template"),ellipsis:ie("...",{beforeExpr:Te}),backQuote:ie("`",{startsExpr:Q}),dollarBraceL:ie("${",{beforeExpr:Te,startsExpr:Q}),templateTail:ie("...`",{startsExpr:Q}),templateNonTail:ie("...${",{beforeExpr:Te,startsExpr:Q}),at:ie("@"),hash:ie("#",{startsExpr:Q}),interpreterDirective:ie("#!..."),eq:ie("=",{beforeExpr:Te,isAssign:Yu}),assign:ie("_=",{beforeExpr:Te,isAssign:Yu}),slashAssign:ie("_=",{beforeExpr:Te,isAssign:Yu}),xorAssign:ie("_=",{beforeExpr:Te,isAssign:Yu}),moduloAssign:ie("_=",{beforeExpr:Te,isAssign:Yu}),incDec:ie("++/--",{prefix:Ns,postfix:jV,startsExpr:Q}),bang:ie("!",{beforeExpr:Te,prefix:Ns,startsExpr:Q}),tilde:ie("~",{beforeExpr:Te,prefix:Ns,startsExpr:Q}),doubleCaret:ie("^^",{startsExpr:Q}),doubleAt:ie("@@",{startsExpr:Q}),pipeline:Sr("|>",0),nullishCoalescing:Sr("??",1),logicalOR:Sr("||",1),logicalAND:Sr("&&",2),bitwiseOR:Sr("|",3),bitwiseXOR:Sr("^",4),bitwiseAND:Sr("&",5),equality:Sr("==/!=/===/!==",6),lt:Sr("</>/<=/>=",7),gt:Sr("</>/<=/>=",7),relational:Sr("</>/<=/>=",7),bitShift:Sr("<</>>/>>>",8),bitShiftL:Sr("<</>>/>>>",8),bitShiftR:Sr("<</>>/>>>",8),plusMin:ie("+/-",{beforeExpr:Te,binop:9,prefix:Ns,startsExpr:Q}),modulo:ie("%",{binop:10,startsExpr:Q}),star:ie("*",{binop:10}),slash:Sr("/",10),exponent:ie("**",{beforeExpr:Te,binop:11,rightAssociative:!0}),_in:ke("in",{beforeExpr:Te,binop:7}),_instanceof:ke("instanceof",{beforeExpr:Te,binop:7}),_break:ke("break"),_case:ke("case",{beforeExpr:Te}),_catch:ke("catch"),_continue:ke("continue"),_debugger:ke("debugger"),_default:ke("default",{beforeExpr:Te}),_else:ke("else",{beforeExpr:Te}),_finally:ke("finally"),_function:ke("function",{startsExpr:Q}),_if:ke("if"),_return:ke("return",{beforeExpr:Te}),_switch:ke("switch"),_throw:ke("throw",{beforeExpr:Te,prefix:Ns,startsExpr:Q}),_try:ke("try"),_var:ke("var"),_const:ke("const"),_with:ke("with"),_new:ke("new",{beforeExpr:Te,startsExpr:Q}),_this:ke("this",{startsExpr:Q}),_super:ke("super",{startsExpr:Q}),_class:ke("class",{startsExpr:Q}),_extends:ke("extends",{beforeExpr:Te}),_export:ke("export"),_import:ke("import",{startsExpr:Q}),_null:ke("null",{startsExpr:Q}),_true:ke("true",{startsExpr:Q}),_false:ke("false",{startsExpr:Q}),_typeof:ke("typeof",{beforeExpr:Te,prefix:Ns,startsExpr:Q}),_void:ke("void",{beforeExpr:Te,prefix:Ns,startsExpr:Q}),_delete:ke("delete",{beforeExpr:Te,prefix:Ns,startsExpr:Q}),_do:ke("do",{isLoop:Pb,beforeExpr:Te}),_for:ke("for",{isLoop:Pb}),_while:ke("while",{isLoop:Pb}),_as:Se("as",{startsExpr:Q}),_assert:Se("assert",{startsExpr:Q}),_async:Se("async",{startsExpr:Q}),_await:Se("await",{startsExpr:Q}),_defer:Se("defer",{startsExpr:Q}),_from:Se("from",{startsExpr:Q}),_get:Se("get",{startsExpr:Q}),_let:Se("let",{startsExpr:Q}),_meta:Se("meta",{startsExpr:Q}),_of:Se("of",{startsExpr:Q}),_sent:Se("sent",{startsExpr:Q}),_set:Se("set",{startsExpr:Q}),_source:Se("source",{startsExpr:Q}),_static:Se("static",{startsExpr:Q}),_using:Se("using",{startsExpr:Q}),_yield:Se("yield",{startsExpr:Q}),_asserts:Se("asserts",{startsExpr:Q}),_checks:Se("checks",{startsExpr:Q}),_exports:Se("exports",{startsExpr:Q}),_global:Se("global",{startsExpr:Q}),_implements:Se("implements",{startsExpr:Q}),_intrinsic:Se("intrinsic",{startsExpr:Q}),_infer:Se("infer",{startsExpr:Q}),_is:Se("is",{startsExpr:Q}),_mixins:Se("mixins",{startsExpr:Q}),_proto:Se("proto",{startsExpr:Q}),_require:Se("require",{startsExpr:Q}),_satisfies:Se("satisfies",{startsExpr:Q}),_keyof:Se("keyof",{startsExpr:Q}),_readonly:Se("readonly",{startsExpr:Q}),_unique:Se("unique",{startsExpr:Q}),_abstract:Se("abstract",{startsExpr:Q}),_declare:Se("declare",{startsExpr:Q}),_enum:Se("enum",{startsExpr:Q}),_module:Se("module",{startsExpr:Q}),_namespace:Se("namespace",{startsExpr:Q}),_interface:Se("interface",{startsExpr:Q}),_type:Se("type",{startsExpr:Q}),_opaque:Se("opaque",{startsExpr:Q}),name:ie("name",{startsExpr:Q}),string:ie("string",{startsExpr:Q}),num:ie("num",{startsExpr:Q}),bigint:ie("bigint",{startsExpr:Q}),decimal:ie("decimal",{startsExpr:Q}),regexp:ie("regexp",{startsExpr:Q}),privateName:ie("#name",{startsExpr:Q}),eof:ie("eof"),jsxName:ie("jsxName"),jsxText:ie("jsxText",{beforeExpr:!0}),jsxTagStart:ie("jsxTagStart",{startsExpr:!0}),jsxTagEnd:ie("jsxTagEnd"),placeholder:ie("%%",{startsExpr:!0})};function Ue(e){return e>=93&&e<=132}function GV(e){return e<=92}function Vn(e){return e>=58&&e<=132}function jF(e){return e>=58&&e<=136}function zV(e){return nx[e]}function Rb(e){return ix[e]}function HV(e){return e>=29&&e<=33}function _F(e){return e>=129&&e<=131}function KV(e){return e>=90&&e<=92}function ox(e){return e>=58&&e<=92}function VV(e){return e>=39&&e<=59}function WV(e){return e===34}function YV(e){return sx[e]}function JV(e){return e>=121&&e<=123}function XV(e){return e>=124&&e<=130}function Os(e){return tx[e]}function pf(e){return rx[e]}function QV(e){return e===57}function mf(e){return e>=24&&e<=25}function Ji(e){return Xi[e]}Xi[8].updateContext=e=>{e.pop()},Xi[5].updateContext=Xi[7].updateContext=Xi[23].updateContext=e=>{e.push(Qe.brace)},Xi[22].updateContext=e=>{e[e.length-1]===Qe.template?e.pop():e.push(Qe.template)},Xi[142].updateContext=e=>{e.push(Qe.j_expr,Qe.j_oTag)};var ax="\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC",qF="\u200C\u200D\xB7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0898-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0CF3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u200C\u200D\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\u30FB\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA8FF-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F\uFF65",ZV=new RegExp("["+ax+"]"),eW=new RegExp("["+ax+qF+"]");ax=qF=null;var GF=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,68,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,349,41,7,1,79,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,159,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,264,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,4026,582,8634,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,689,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,43,8,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,757,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],tW=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,370,1,81,2,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,193,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,84,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,406,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,9,5351,0,7,14,13835,9,87,9,39,4,60,6,26,9,1014,0,2,54,8,3,82,0,12,1,19628,1,4706,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,983,6,110,6,6,9,4759,9,787719,239];function Ob(e,t){let r=65536;for(let n=0,i=t.length;n<i;n+=2){if(r+=t[n],r>e)return!1;if(r+=t[n+1],r>=e)return!0}return!1}function Qi(e){return e<65?e===36:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&ZV.test(String.fromCharCode(e)):Ob(e,GF)}function Ka(e){return e<48?e===36:e<58?!0:e<65?!1:e<=90?!0:e<97?e===95:e<=122?!0:e<=65535?e>=170&&eW.test(String.fromCharCode(e)):Ob(e,GF)||Ob(e,tW)}var cx={keyword:["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete"],strict:["implements","interface","let","package","private","protected","public","static","yield"],strictBind:["eval","arguments"]},rW=new Set(cx.keyword),nW=new Set(cx.strict),iW=new Set(cx.strictBind);function zF(e,t){return t&&e==="await"||e==="enum"}function HF(e,t){return zF(e,t)||nW.has(e)}function KF(e){return iW.has(e)}function VF(e,t){return HF(e,t)||KF(e)}function sW(e){return rW.has(e)}function oW(e,t,r){return e===64&&t===64&&Qi(r)}var aW=new Set(["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete","implements","interface","let","package","private","protected","public","static","yield","eval","arguments","enum","await"]);function cW(e){return aW.has(e)}var el=class{constructor(t){this.flags=0,this.names=new Map,this.firstLexicalName="",this.flags=t}},tl=class{constructor(t,r){this.parser=void 0,this.scopeStack=[],this.inModule=void 0,this.undefinedExports=new Map,this.parser=t,this.inModule=r}get inTopLevel(){return(this.currentScope().flags&1)>0}get inFunction(){return(this.currentVarScopeFlags()&2)>0}get allowSuper(){return(this.currentThisScopeFlags()&16)>0}get allowDirectSuper(){return(this.currentThisScopeFlags()&32)>0}get inClass(){return(this.currentThisScopeFlags()&64)>0}get inClassAndNotInNonArrowFunction(){let t=this.currentThisScopeFlags();return(t&64)>0&&(t&2)===0}get inStaticBlock(){for(let t=this.scopeStack.length-1;;t--){let{flags:r}=this.scopeStack[t];if(r&128)return!0;if(r&451)return!1}}get inNonArrowFunction(){return(this.currentThisScopeFlags()&2)>0}get treatFunctionsAsVar(){return this.treatFunctionsAsVarInScope(this.currentScope())}createScope(t){return new el(t)}enter(t){this.scopeStack.push(this.createScope(t))}exit(){return this.scopeStack.pop().flags}treatFunctionsAsVarInScope(t){return!!(t.flags&130||!this.parser.inModule&&t.flags&1)}declareName(t,r,n){let i=this.currentScope();if(r&8||r&16){this.checkRedeclarationInScope(i,t,r,n);let s=i.names.get(t)||0;r&16?s=s|4:(i.firstLexicalName||(i.firstLexicalName=t),s=s|2),i.names.set(t,s),r&8&&this.maybeExportDefined(i,t)}else if(r&4)for(let s=this.scopeStack.length-1;s>=0&&(i=this.scopeStack[s],this.checkRedeclarationInScope(i,t,r,n),i.names.set(t,(i.names.get(t)||0)|1),this.maybeExportDefined(i,t),!(i.flags&387));--s);this.parser.inModule&&i.flags&1&&this.undefinedExports.delete(t)}maybeExportDefined(t,r){this.parser.inModule&&t.flags&1&&this.undefinedExports.delete(r)}checkRedeclarationInScope(t,r,n,i){this.isRedeclaredInScope(t,r,n)&&this.parser.raise(_.VarRedeclaration,i,{identifierName:r})}isRedeclaredInScope(t,r,n){if(!(n&1))return!1;if(n&8)return t.names.has(r);let i=t.names.get(r);return n&16?(i&2)>0||!this.treatFunctionsAsVarInScope(t)&&(i&1)>0:(i&2)>0&&!(t.flags&8&&t.firstLexicalName===r)||!this.treatFunctionsAsVarInScope(t)&&(i&4)>0}checkLocalExport(t){let{name:r}=t;this.scopeStack[0].names.has(r)||this.undefinedExports.set(r,t.loc.start)}currentScope(){return this.scopeStack[this.scopeStack.length-1]}currentVarScopeFlags(){for(let t=this.scopeStack.length-1;;t--){let{flags:r}=this.scopeStack[t];if(r&387)return r}}currentThisScopeFlags(){for(let t=this.scopeStack.length-1;;t--){let{flags:r}=this.scopeStack[t];if(r&451&&!(r&4))return r}}},Bb=class extends el{constructor(...t){super(...t),this.declareFunctions=new Set}},Mb=class extends tl{createScope(t){return new Bb(t)}declareName(t,r,n){let i=this.currentScope();if(r&2048){this.checkRedeclarationInScope(i,t,r,n),this.maybeExportDefined(i,t),i.declareFunctions.add(t);return}super.declareName(t,r,n)}isRedeclaredInScope(t,r,n){if(super.isRedeclaredInScope(t,r,n))return!0;if(n&2048&&!t.declareFunctions.has(r)){let i=t.names.get(r);return(i&4)>0||(i&2)>0}return!1}checkLocalExport(t){this.scopeStack[0].declareFunctions.has(t.name)||super.checkLocalExport(t)}},Lb=class{constructor(){this.sawUnambiguousESM=!1,this.ambiguousScriptDifferentAst=!1}hasPlugin(t){if(typeof t=="string")return this.plugins.has(t);{let[r,n]=t;if(!this.hasPlugin(r))return!1;let i=this.plugins.get(r);for(let s of Object.keys(n))if(i?.[s]!==n[s])return!1;return!0}}getPluginOption(t,r){var n;return(n=this.plugins.get(t))==null?void 0:n[r]}};function WF(e,t){e.trailingComments===void 0?e.trailingComments=t:e.trailingComments.unshift(...t)}function uW(e,t){e.leadingComments===void 0?e.leadingComments=t:e.leadingComments.unshift(...t)}function rl(e,t){e.innerComments===void 0?e.innerComments=t:e.innerComments.unshift(...t)}function Ju(e,t,r){let n=null,i=t.length;for(;n===null&&i>0;)n=t[--i];n===null||n.start>r.start?rl(e,r.comments):WF(n,r.comments)}var $b=class extends Lb{addComment(t){this.filename&&(t.loc.filename=this.filename);let{commentsLen:r}=this.state;this.comments.length!==r&&(this.comments.length=r),this.comments.push(t),this.state.commentsLen++}processComment(t){let{commentStack:r}=this.state,n=r.length;if(n===0)return;let i=n-1,s=r[i];s.start===t.end&&(s.leadingNode=t,i--);let{start:o}=t;for(;i>=0;i--){let a=r[i],c=a.end;if(c>o)a.containingNode=t,this.finalizeComment(a),r.splice(i,1);else{c===o&&(a.trailingNode=t);break}}}finalizeComment(t){let{comments:r}=t;if(t.leadingNode!==null||t.trailingNode!==null)t.leadingNode!==null&&WF(t.leadingNode,r),t.trailingNode!==null&&uW(t.trailingNode,r);else{let{containingNode:n,start:i}=t;if(this.input.charCodeAt(i-1)===44)switch(n.type){case"ObjectExpression":case"ObjectPattern":case"RecordExpression":Ju(n,n.properties,t);break;case"CallExpression":case"OptionalCallExpression":Ju(n,n.arguments,t);break;case"FunctionDeclaration":case"FunctionExpression":case"ArrowFunctionExpression":case"ObjectMethod":case"ClassMethod":case"ClassPrivateMethod":Ju(n,n.params,t);break;case"ArrayExpression":case"ArrayPattern":case"TupleExpression":Ju(n,n.elements,t);break;case"ExportNamedDeclaration":case"ImportDeclaration":Ju(n,n.specifiers,t);break;default:rl(n,r)}else rl(n,r)}}finalizeRemainingComments(){let{commentStack:t}=this.state;for(let r=t.length-1;r>=0;r--)this.finalizeComment(t[r]);this.state.commentStack=[]}resetPreviousNodeTrailingComments(t){let{commentStack:r}=this.state,{length:n}=r;if(n===0)return;let i=r[n-1];i.leadingNode===t&&(i.leadingNode=null)}resetPreviousIdentifierLeadingComments(t){let{commentStack:r}=this.state,{length:n}=r;n!==0&&(r[n-1].trailingNode===t?r[n-1].trailingNode=null:n>=2&&r[n-2].trailingNode===t&&(r[n-2].trailingNode=null))}takeSurroundingComments(t,r,n){let{commentStack:i}=this.state,s=i.length;if(s===0)return;let o=s-1;for(;o>=0;o--){let a=i[o],c=a.end;if(a.start===n)a.leadingNode=t;else if(c===r)a.trailingNode=t;else if(c<r)break}}},lW=/\r\n|[\r\n\u2028\u2029]/,cf=new RegExp(lW.source,"g");function Va(e){switch(e){case 10:case 13:case 8232:case 8233:return!0;default:return!1}}function IF(e,t,r){for(let n=t;n<r;n++)if(Va(e.charCodeAt(n)))return!0;return!1}var Fb=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,_b=/(?:[^\S\n\r\u2028\u2029]|\/\/.*|\/\*.*?\*\/)*/g;function pW(e){switch(e){case 9:case 11:case 12:case 32:case 160:case 5760:case 8192:case 8193:case 8194:case 8195:case 8196:case 8197:case 8198:case 8199:case 8200:case 8201:case 8202:case 8239:case 8287:case 12288:case 65279:return!0;default:return!1}}var Ub=class e{constructor(){this.flags=1024,this.curLine=void 0,this.lineStart=void 0,this.startLoc=void 0,this.endLoc=void 0,this.errors=[],this.potentialArrowAt=-1,this.noArrowAt=[],this.noArrowParamsConversionAt=[],this.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null},this.labels=[],this.commentsLen=0,this.commentStack=[],this.pos=0,this.type=139,this.value=null,this.start=0,this.end=0,this.lastTokEndLoc=null,this.lastTokStartLoc=null,this.context=[Qe.brace],this.firstInvalidTemplateEscapePos=null,this.strictErrors=new Map,this.tokensLength=0}get strict(){return(this.flags&1)>0}set strict(t){t?this.flags|=1:this.flags&=-2}init({strictMode:t,sourceType:r,startLine:n,startColumn:i}){this.strict=t===!1?!1:t===!0?!0:r==="module",this.curLine=n,this.lineStart=-i,this.startLoc=this.endLoc=new vi(n,i,0)}get maybeInArrowParameters(){return(this.flags&2)>0}set maybeInArrowParameters(t){t?this.flags|=2:this.flags&=-3}get inType(){return(this.flags&4)>0}set inType(t){t?this.flags|=4:this.flags&=-5}get noAnonFunctionType(){return(this.flags&8)>0}set noAnonFunctionType(t){t?this.flags|=8:this.flags&=-9}get hasFlowComment(){return(this.flags&16)>0}set hasFlowComment(t){t?this.flags|=16:this.flags&=-17}get isAmbientContext(){return(this.flags&32)>0}set isAmbientContext(t){t?this.flags|=32:this.flags&=-33}get inAbstractClass(){return(this.flags&64)>0}set inAbstractClass(t){t?this.flags|=64:this.flags&=-65}get inDisallowConditionalTypesContext(){return(this.flags&128)>0}set inDisallowConditionalTypesContext(t){t?this.flags|=128:this.flags&=-129}get soloAwait(){return(this.flags&256)>0}set soloAwait(t){t?this.flags|=256:this.flags&=-257}get inFSharpPipelineDirectBody(){return(this.flags&512)>0}set inFSharpPipelineDirectBody(t){t?this.flags|=512:this.flags&=-513}get canStartJSXElement(){return(this.flags&1024)>0}set canStartJSXElement(t){t?this.flags|=1024:this.flags&=-1025}get containsEsc(){return(this.flags&2048)>0}set containsEsc(t){t?this.flags|=2048:this.flags&=-2049}get hasTopLevelAwait(){return(this.flags&4096)>0}set hasTopLevelAwait(t){t?this.flags|=4096:this.flags&=-4097}curPosition(){return new vi(this.curLine,this.pos-this.lineStart,this.pos)}clone(){let t=new e;return t.flags=this.flags,t.curLine=this.curLine,t.lineStart=this.lineStart,t.startLoc=this.startLoc,t.endLoc=this.endLoc,t.errors=this.errors.slice(),t.potentialArrowAt=this.potentialArrowAt,t.noArrowAt=this.noArrowAt.slice(),t.noArrowParamsConversionAt=this.noArrowParamsConversionAt.slice(),t.topicContext=this.topicContext,t.labels=this.labels.slice(),t.commentsLen=this.commentsLen,t.commentStack=this.commentStack.slice(),t.pos=this.pos,t.type=this.type,t.value=this.value,t.start=this.start,t.end=this.end,t.lastTokEndLoc=this.lastTokEndLoc,t.lastTokStartLoc=this.lastTokStartLoc,t.context=this.context.slice(),t.firstInvalidTemplateEscapePos=this.firstInvalidTemplateEscapePos,t.strictErrors=this.strictErrors,t.tokensLength=this.tokensLength,t}},dW=function(t){return t>=48&&t<=57},kF={decBinOct:new Set([46,66,69,79,95,98,101,111]),hex:new Set([46,88,95,120])},uf={bin:e=>e===48||e===49,oct:e=>e>=48&&e<=55,dec:e=>e>=48&&e<=57,hex:e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102};function NF(e,t,r,n,i,s){let o=r,a=n,c=i,u="",l=null,p=r,{length:d}=t;for(;;){if(r>=d){s.unterminated(o,a,c),u+=t.slice(p,r);break}let h=t.charCodeAt(r);if(fW(e,h,t,r)){u+=t.slice(p,r);break}if(h===92){u+=t.slice(p,r);let m=mW(t,r,n,i,e==="template",s);m.ch===null&&!l?l={pos:r,lineStart:n,curLine:i}:u+=m.ch,{pos:r,lineStart:n,curLine:i}=m,p=r}else h===8232||h===8233?(++r,++i,n=r):h===10||h===13?e==="template"?(u+=t.slice(p,r)+`
18
18
  `,++r,h===13&&t.charCodeAt(r)===10&&++r,++i,p=n=r):s.unterminated(o,a,c):++r}return{pos:r,str:u,firstInvalidLoc:l,lineStart:n,curLine:i,containsInvalid:!!l}}function fW(e,t,r,n){return e==="template"?t===96||t===36&&r.charCodeAt(n+1)===123:t===(e==="double"?34:39)}function mW(e,t,r,n,i,s){let o=!i;t++;let a=u=>({pos:t,ch:u,lineStart:r,curLine:n}),c=e.charCodeAt(t++);switch(c){case 110:return a(`
19
19
  `);case 114:return a("\r");case 120:{let u;return{code:u,pos:t}=jb(e,t,r,n,2,!1,o,s),a(u===null?null:String.fromCharCode(u))}case 117:{let u;return{code:u,pos:t}=JF(e,t,r,n,o,s),a(u===null?null:String.fromCodePoint(u))}case 116:return a(" ");case 98:return a("\b");case 118:return a("\v");case 102:return a("\f");case 13:e.charCodeAt(t)===10&&++t;case 10:r=t,++n;case 8232:case 8233:return a("");case 56:case 57:if(i)return a(null);s.strictNumericEscape(t-1,r,n);default:if(c>=48&&c<=55){let u=t-1,p=/^[0-7]+/.exec(e.slice(u,t+2))[0],d=parseInt(p,8);d>255&&(p=p.slice(0,-1),d=parseInt(p,8)),t+=p.length-1;let h=e.charCodeAt(t);if(p!=="0"||h===56||h===57){if(i)return a(null);s.strictNumericEscape(u,r,n)}return a(String.fromCharCode(d))}return a(String.fromCharCode(c))}}function jb(e,t,r,n,i,s,o,a){let c=t,u;return{n:u,pos:t}=YF(e,t,r,n,16,i,s,!1,a,!o),u===null&&(o?a.invalidEscapeSequence(c,r,n):t=c-1),{code:u,pos:t}}function YF(e,t,r,n,i,s,o,a,c,u){let l=t,p=i===16?kF.hex:kF.decBinOct,d=i===16?uf.hex:i===10?uf.dec:i===8?uf.oct:uf.bin,h=!1,m=0;for(let g=0,y=s??1/0;g<y;++g){let b=e.charCodeAt(t),v;if(b===95&&a!=="bail"){let C=e.charCodeAt(t-1),x=e.charCodeAt(t+1);if(a){if(Number.isNaN(x)||!d(x)||p.has(C)||p.has(x)){if(u)return{n:null,pos:t};c.unexpectedNumericSeparator(t,r,n)}}else{if(u)return{n:null,pos:t};c.numericSeparatorInEscapeSequence(t,r,n)}++t;continue}if(b>=97?v=b-97+10:b>=65?v=b-65+10:dW(b)?v=b-48:v=1/0,v>=i){if(v<=9&&u)return{n:null,pos:t};if(v<=9&&c.invalidDigit(t,r,n,i))v=0;else if(o)v=0,h=!0;else break}++t,m=m*i+v}return t===l||s!=null&&t-l!==s||h?{n:null,pos:t}:{n:m,pos:t}}function JF(e,t,r,n,i,s){let o=e.charCodeAt(t),a;if(o===123){if(++t,{code:a,pos:t}=jb(e,t,r,n,e.indexOf("}",t)-t,!0,i,s),++t,a!==null&&a>1114111)if(i)s.invalidCodePoint(t,r,n);else return{code:null,pos:t}}else({code:a,pos:t}=jb(e,t,r,n,4,!1,i,s));return{code:a,pos:t}}function Xu(e,t,r){return new vi(r,e-t,e)}var hW=new Set([103,109,115,105,121,117,100,118]),xi=class{constructor(t){this.type=t.type,this.value=t.value,this.start=t.start,this.end=t.end,this.loc=new Ya(t.startLoc,t.endLoc)}},qb=class extends $b{constructor(t,r){super(),this.isLookahead=void 0,this.tokens=[],this.errorHandlers_readInt={invalidDigit:(n,i,s,o)=>this.options.errorRecovery?(this.raise(_.InvalidDigit,Xu(n,i,s),{radix:o}),!0):!1,numericSeparatorInEscapeSequence:this.errorBuilder(_.NumericSeparatorInEscapeSequence),unexpectedNumericSeparator:this.errorBuilder(_.UnexpectedNumericSeparator)},this.errorHandlers_readCodePoint=Object.assign({},this.errorHandlers_readInt,{invalidEscapeSequence:this.errorBuilder(_.InvalidEscapeSequence),invalidCodePoint:this.errorBuilder(_.InvalidCodePoint)}),this.errorHandlers_readStringContents_string=Object.assign({},this.errorHandlers_readCodePoint,{strictNumericEscape:(n,i,s)=>{this.recordStrictModeErrors(_.StrictNumericEscape,Xu(n,i,s))},unterminated:(n,i,s)=>{throw this.raise(_.UnterminatedString,Xu(n-1,i,s))}}),this.errorHandlers_readStringContents_template=Object.assign({},this.errorHandlers_readCodePoint,{strictNumericEscape:this.errorBuilder(_.StrictNumericEscape),unterminated:(n,i,s)=>{throw this.raise(_.UnterminatedTemplate,Xu(n,i,s))}}),this.state=new Ub,this.state.init(t),this.input=r,this.length=r.length,this.comments=[],this.isLookahead=!1}pushToken(t){this.tokens.length=this.state.tokensLength,this.tokens.push(t),++this.state.tokensLength}next(){this.checkKeywordEscapes(),this.options.tokens&&this.pushToken(new xi(this.state)),this.state.lastTokEndLoc=this.state.endLoc,this.state.lastTokStartLoc=this.state.startLoc,this.nextToken()}eat(t){return this.match(t)?(this.next(),!0):!1}match(t){return this.state.type===t}createLookaheadState(t){return{pos:t.pos,value:null,type:t.type,start:t.start,end:t.end,context:[this.curContext()],inType:t.inType,startLoc:t.startLoc,lastTokEndLoc:t.lastTokEndLoc,curLine:t.curLine,lineStart:t.lineStart,curPosition:t.curPosition}}lookahead(){let t=this.state;this.state=this.createLookaheadState(t),this.isLookahead=!0,this.nextToken(),this.isLookahead=!1;let r=this.state;return this.state=t,r}nextTokenStart(){return this.nextTokenStartSince(this.state.pos)}nextTokenStartSince(t){return Fb.lastIndex=t,Fb.test(this.input)?Fb.lastIndex:t}lookaheadCharCode(){return this.input.charCodeAt(this.nextTokenStart())}nextTokenInLineStart(){return this.nextTokenInLineStartSince(this.state.pos)}nextTokenInLineStartSince(t){return _b.lastIndex=t,_b.test(this.input)?_b.lastIndex:t}lookaheadInLineCharCode(){return this.input.charCodeAt(this.nextTokenInLineStart())}codePointAtPos(t){let r=this.input.charCodeAt(t);if((r&64512)===55296&&++t<this.input.length){let n=this.input.charCodeAt(t);(n&64512)===56320&&(r=65536+((r&1023)<<10)+(n&1023))}return r}setStrict(t){this.state.strict=t,t&&(this.state.strictErrors.forEach(([r,n])=>this.raise(r,n)),this.state.strictErrors.clear())}curContext(){return this.state.context[this.state.context.length-1]}nextToken(){if(this.skipSpace(),this.state.start=this.state.pos,this.isLookahead||(this.state.startLoc=this.state.curPosition()),this.state.pos>=this.length){this.finishToken(139);return}this.getTokenFromCode(this.codePointAtPos(this.state.pos))}skipBlockComment(t){let r;this.isLookahead||(r=this.state.curPosition());let n=this.state.pos,i=this.input.indexOf(t,n+2);if(i===-1)throw this.raise(_.UnterminatedComment,this.state.curPosition());for(this.state.pos=i+t.length,cf.lastIndex=n+2;cf.test(this.input)&&cf.lastIndex<=i;)++this.state.curLine,this.state.lineStart=cf.lastIndex;if(this.isLookahead)return;let s={type:"CommentBlock",value:this.input.slice(n+2,i),start:n,end:i+t.length,loc:new Ya(r,this.state.curPosition())};return this.options.tokens&&this.pushToken(s),s}skipLineComment(t){let r=this.state.pos,n;this.isLookahead||(n=this.state.curPosition());let i=this.input.charCodeAt(this.state.pos+=t);if(this.state.pos<this.length)for(;!Va(i)&&++this.state.pos<this.length;)i=this.input.charCodeAt(this.state.pos);if(this.isLookahead)return;let s=this.state.pos,a={type:"CommentLine",value:this.input.slice(r+t,s),start:r,end:s,loc:new Ya(n,this.state.curPosition())};return this.options.tokens&&this.pushToken(a),a}skipSpace(){let t=this.state.pos,r=[];e:for(;this.state.pos<this.length;){let n=this.input.charCodeAt(this.state.pos);switch(n){case 32:case 160:case 9:++this.state.pos;break;case 13:this.input.charCodeAt(this.state.pos+1)===10&&++this.state.pos;case 10:case 8232:case 8233:++this.state.pos,++this.state.curLine,this.state.lineStart=this.state.pos;break;case 47:switch(this.input.charCodeAt(this.state.pos+1)){case 42:{let i=this.skipBlockComment("*/");i!==void 0&&(this.addComment(i),this.options.attachComment&&r.push(i));break}case 47:{let i=this.skipLineComment(2);i!==void 0&&(this.addComment(i),this.options.attachComment&&r.push(i));break}default:break e}break;default:if(pW(n))++this.state.pos;else if(n===45&&!this.inModule&&this.options.annexB){let i=this.state.pos;if(this.input.charCodeAt(i+1)===45&&this.input.charCodeAt(i+2)===62&&(t===0||this.state.lineStart>t)){let s=this.skipLineComment(3);s!==void 0&&(this.addComment(s),this.options.attachComment&&r.push(s))}else break e}else if(n===60&&!this.inModule&&this.options.annexB){let i=this.state.pos;if(this.input.charCodeAt(i+1)===33&&this.input.charCodeAt(i+2)===45&&this.input.charCodeAt(i+3)===45){let s=this.skipLineComment(4);s!==void 0&&(this.addComment(s),this.options.attachComment&&r.push(s))}else break e}else break e}}if(r.length>0){let n=this.state.pos,i={start:t,end:n,comments:r,leadingNode:null,trailingNode:null,containingNode:null};this.state.commentStack.push(i)}}finishToken(t,r){this.state.end=this.state.pos,this.state.endLoc=this.state.curPosition();let n=this.state.type;this.state.type=t,this.state.value=r,this.isLookahead||this.updateContext(n)}replaceToken(t){this.state.type=t,this.updateContext()}readToken_numberSign(){if(this.state.pos===0&&this.readToken_interpreter())return;let t=this.state.pos+1,r=this.codePointAtPos(t);if(r>=48&&r<=57)throw this.raise(_.UnexpectedDigitAfterHash,this.state.curPosition());if(r===123||r===91&&this.hasPlugin("recordAndTuple")){if(this.expectPlugin("recordAndTuple"),this.getPluginOption("recordAndTuple","syntaxType")==="bar")throw this.raise(r===123?_.RecordExpressionHashIncorrectStartSyntaxType:_.TupleExpressionHashIncorrectStartSyntaxType,this.state.curPosition());this.state.pos+=2,r===123?this.finishToken(7):this.finishToken(1)}else Qi(r)?(++this.state.pos,this.finishToken(138,this.readWord1(r))):r===92?(++this.state.pos,this.finishToken(138,this.readWord1())):this.finishOp(27,1)}readToken_dot(){let t=this.input.charCodeAt(this.state.pos+1);if(t>=48&&t<=57){this.readNumber(!0);return}t===46&&this.input.charCodeAt(this.state.pos+2)===46?(this.state.pos+=3,this.finishToken(21)):(++this.state.pos,this.finishToken(16))}readToken_slash(){this.input.charCodeAt(this.state.pos+1)===61?this.finishOp(31,2):this.finishOp(56,1)}readToken_interpreter(){if(this.state.pos!==0||this.length<2)return!1;let t=this.input.charCodeAt(this.state.pos+1);if(t!==33)return!1;let r=this.state.pos;for(this.state.pos+=1;!Va(t)&&++this.state.pos<this.length;)t=this.input.charCodeAt(this.state.pos);let n=this.input.slice(r+2,this.state.pos);return this.finishToken(28,n),!0}readToken_mult_modulo(t){let r=t===42?55:54,n=1,i=this.input.charCodeAt(this.state.pos+1);t===42&&i===42&&(n++,i=this.input.charCodeAt(this.state.pos+2),r=57),i===61&&!this.state.inType&&(n++,r=t===37?33:30),this.finishOp(r,n)}readToken_pipe_amp(t){let r=this.input.charCodeAt(this.state.pos+1);if(r===t){this.input.charCodeAt(this.state.pos+2)===61?this.finishOp(30,3):this.finishOp(t===124?41:42,2);return}if(t===124){if(r===62){this.finishOp(39,2);return}if(this.hasPlugin("recordAndTuple")&&r===125){if(this.getPluginOption("recordAndTuple","syntaxType")!=="bar")throw this.raise(_.RecordExpressionBarIncorrectEndSyntaxType,this.state.curPosition());this.state.pos+=2,this.finishToken(9);return}if(this.hasPlugin("recordAndTuple")&&r===93){if(this.getPluginOption("recordAndTuple","syntaxType")!=="bar")throw this.raise(_.TupleExpressionBarIncorrectEndSyntaxType,this.state.curPosition());this.state.pos+=2,this.finishToken(4);return}}if(r===61){this.finishOp(30,2);return}this.finishOp(t===124?43:45,1)}readToken_caret(){let t=this.input.charCodeAt(this.state.pos+1);t===61&&!this.state.inType?this.finishOp(32,2):t===94&&this.hasPlugin(["pipelineOperator",{proposal:"hack",topicToken:"^^"}])?(this.finishOp(37,2),this.input.codePointAt(this.state.pos)===94&&this.unexpected()):this.finishOp(44,1)}readToken_atSign(){this.input.charCodeAt(this.state.pos+1)===64&&this.hasPlugin(["pipelineOperator",{proposal:"hack",topicToken:"@@"}])?this.finishOp(38,2):this.finishOp(26,1)}readToken_plus_min(t){let r=this.input.charCodeAt(this.state.pos+1);if(r===t){this.finishOp(34,2);return}r===61?this.finishOp(30,2):this.finishOp(53,1)}readToken_lt(){let{pos:t}=this.state,r=this.input.charCodeAt(t+1);if(r===60){if(this.input.charCodeAt(t+2)===61){this.finishOp(30,3);return}this.finishOp(51,2);return}if(r===61){this.finishOp(49,2);return}this.finishOp(47,1)}readToken_gt(){let{pos:t}=this.state,r=this.input.charCodeAt(t+1);if(r===62){let n=this.input.charCodeAt(t+2)===62?3:2;if(this.input.charCodeAt(t+n)===61){this.finishOp(30,n+1);return}this.finishOp(52,n);return}if(r===61){this.finishOp(49,2);return}this.finishOp(48,1)}readToken_eq_excl(t){let r=this.input.charCodeAt(this.state.pos+1);if(r===61){this.finishOp(46,this.input.charCodeAt(this.state.pos+2)===61?3:2);return}if(t===61&&r===62){this.state.pos+=2,this.finishToken(19);return}this.finishOp(t===61?29:35,1)}readToken_question(){let t=this.input.charCodeAt(this.state.pos+1),r=this.input.charCodeAt(this.state.pos+2);t===63?r===61?this.finishOp(30,3):this.finishOp(40,2):t===46&&!(r>=48&&r<=57)?(this.state.pos+=2,this.finishToken(18)):(++this.state.pos,this.finishToken(17))}getTokenFromCode(t){switch(t){case 46:this.readToken_dot();return;case 40:++this.state.pos,this.finishToken(10);return;case 41:++this.state.pos,this.finishToken(11);return;case 59:++this.state.pos,this.finishToken(13);return;case 44:++this.state.pos,this.finishToken(12);return;case 91:if(this.hasPlugin("recordAndTuple")&&this.input.charCodeAt(this.state.pos+1)===124){if(this.getPluginOption("recordAndTuple","syntaxType")!=="bar")throw this.raise(_.TupleExpressionBarIncorrectStartSyntaxType,this.state.curPosition());this.state.pos+=2,this.finishToken(2)}else++this.state.pos,this.finishToken(0);return;case 93:++this.state.pos,this.finishToken(3);return;case 123:if(this.hasPlugin("recordAndTuple")&&this.input.charCodeAt(this.state.pos+1)===124){if(this.getPluginOption("recordAndTuple","syntaxType")!=="bar")throw this.raise(_.RecordExpressionBarIncorrectStartSyntaxType,this.state.curPosition());this.state.pos+=2,this.finishToken(6)}else++this.state.pos,this.finishToken(5);return;case 125:++this.state.pos,this.finishToken(8);return;case 58:this.hasPlugin("functionBind")&&this.input.charCodeAt(this.state.pos+1)===58?this.finishOp(15,2):(++this.state.pos,this.finishToken(14));return;case 63:this.readToken_question();return;case 96:this.readTemplateToken();return;case 48:{let r=this.input.charCodeAt(this.state.pos+1);if(r===120||r===88){this.readRadixNumber(16);return}if(r===111||r===79){this.readRadixNumber(8);return}if(r===98||r===66){this.readRadixNumber(2);return}}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:this.readNumber(!1);return;case 34:case 39:this.readString(t);return;case 47:this.readToken_slash();return;case 37:case 42:this.readToken_mult_modulo(t);return;case 124:case 38:this.readToken_pipe_amp(t);return;case 94:this.readToken_caret();return;case 43:case 45:this.readToken_plus_min(t);return;case 60:this.readToken_lt();return;case 62:this.readToken_gt();return;case 61:case 33:this.readToken_eq_excl(t);return;case 126:this.finishOp(36,1);return;case 64:this.readToken_atSign();return;case 35:this.readToken_numberSign();return;case 92:this.readWord();return;default:if(Qi(t)){this.readWord(t);return}}throw this.raise(_.InvalidOrUnexpectedToken,this.state.curPosition(),{unexpected:String.fromCodePoint(t)})}finishOp(t,r){let n=this.input.slice(this.state.pos,this.state.pos+r);this.state.pos+=r,this.finishToken(t,n)}readRegexp(){let t=this.state.startLoc,r=this.state.start+1,n,i,{pos:s}=this.state;for(;;++s){if(s>=this.length)throw this.raise(_.UnterminatedRegExp,Tr(t,1));let u=this.input.charCodeAt(s);if(Va(u))throw this.raise(_.UnterminatedRegExp,Tr(t,1));if(n)n=!1;else{if(u===91)i=!0;else if(u===93&&i)i=!1;else if(u===47&&!i)break;n=u===92}}let o=this.input.slice(r,s);++s;let a="",c=()=>Tr(t,s+2-r);for(;s<this.length;){let u=this.codePointAtPos(s),l=String.fromCharCode(u);if(hW.has(u))u===118?a.includes("u")&&this.raise(_.IncompatibleRegExpUVFlags,c()):u===117&&a.includes("v")&&this.raise(_.IncompatibleRegExpUVFlags,c()),a.includes(l)&&this.raise(_.DuplicateRegExpFlags,c());else if(Ka(u)||u===92)this.raise(_.MalformedRegExpFlags,c());else break;++s,a+=l}this.state.pos=s,this.finishToken(137,{pattern:o,flags:a})}readInt(t,r,n=!1,i=!0){let{n:s,pos:o}=YF(this.input,this.state.pos,this.state.lineStart,this.state.curLine,t,r,n,i,this.errorHandlers_readInt,!1);return this.state.pos=o,s}readRadixNumber(t){let r=this.state.curPosition(),n=!1;this.state.pos+=2;let i=this.readInt(t);i==null&&this.raise(_.InvalidDigit,Tr(r,2),{radix:t});let s=this.input.charCodeAt(this.state.pos);if(s===110)++this.state.pos,n=!0;else if(s===109)throw this.raise(_.InvalidDecimal,r);if(Qi(this.codePointAtPos(this.state.pos)))throw this.raise(_.NumberIdentifier,this.state.curPosition());if(n){let o=this.input.slice(r.index,this.state.pos).replace(/[_n]/g,"");this.finishToken(135,o);return}this.finishToken(134,i)}readNumber(t){let r=this.state.pos,n=this.state.curPosition(),i=!1,s=!1,o=!1,a=!1,c=!1;!t&&this.readInt(10)===null&&this.raise(_.InvalidNumber,this.state.curPosition());let u=this.state.pos-r>=2&&this.input.charCodeAt(r)===48;if(u){let h=this.input.slice(r,this.state.pos);if(this.recordStrictModeErrors(_.StrictOctalLiteral,n),!this.state.strict){let m=h.indexOf("_");m>0&&this.raise(_.ZeroDigitNumericSeparator,Tr(n,m))}c=u&&!/[89]/.test(h)}let l=this.input.charCodeAt(this.state.pos);if(l===46&&!c&&(++this.state.pos,this.readInt(10),i=!0,l=this.input.charCodeAt(this.state.pos)),(l===69||l===101)&&!c&&(l=this.input.charCodeAt(++this.state.pos),(l===43||l===45)&&++this.state.pos,this.readInt(10)===null&&this.raise(_.InvalidOrMissingExponent,n),i=!0,a=!0,l=this.input.charCodeAt(this.state.pos)),l===110&&((i||u)&&this.raise(_.InvalidBigIntLiteral,n),++this.state.pos,s=!0),l===109&&(this.expectPlugin("decimal",this.state.curPosition()),(a||u)&&this.raise(_.InvalidDecimal,n),++this.state.pos,o=!0),Qi(this.codePointAtPos(this.state.pos)))throw this.raise(_.NumberIdentifier,this.state.curPosition());let p=this.input.slice(r,this.state.pos).replace(/[_mn]/g,"");if(s){this.finishToken(135,p);return}if(o){this.finishToken(136,p);return}let d=c?parseInt(p,8):parseFloat(p);this.finishToken(134,d)}readCodePoint(t){let{code:r,pos:n}=JF(this.input,this.state.pos,this.state.lineStart,this.state.curLine,t,this.errorHandlers_readCodePoint);return this.state.pos=n,r}readString(t){let{str:r,pos:n,curLine:i,lineStart:s}=NF(t===34?"double":"single",this.input,this.state.pos+1,this.state.lineStart,this.state.curLine,this.errorHandlers_readStringContents_string);this.state.pos=n+1,this.state.lineStart=s,this.state.curLine=i,this.finishToken(133,r)}readTemplateContinuation(){this.match(8)||this.unexpected(null,8),this.state.pos--,this.readTemplateToken()}readTemplateToken(){let t=this.input[this.state.pos],{str:r,firstInvalidLoc:n,pos:i,curLine:s,lineStart:o}=NF("template",this.input,this.state.pos+1,this.state.lineStart,this.state.curLine,this.errorHandlers_readStringContents_template);this.state.pos=i+1,this.state.lineStart=o,this.state.curLine=s,n&&(this.state.firstInvalidTemplateEscapePos=new vi(n.curLine,n.pos-n.lineStart,n.pos)),this.input.codePointAt(i)===96?this.finishToken(24,n?null:t+r+"`"):(this.state.pos++,this.finishToken(25,n?null:t+r+"${"))}recordStrictModeErrors(t,r){let n=r.index;this.state.strict&&!this.state.strictErrors.has(n)?this.raise(t,r):this.state.strictErrors.set(n,[t,r])}readWord1(t){this.state.containsEsc=!1;let r="",n=this.state.pos,i=this.state.pos;for(t!==void 0&&(this.state.pos+=t<=65535?1:2);this.state.pos<this.length;){let s=this.codePointAtPos(this.state.pos);if(Ka(s))this.state.pos+=s<=65535?1:2;else if(s===92){this.state.containsEsc=!0,r+=this.input.slice(i,this.state.pos);let o=this.state.curPosition(),a=this.state.pos===n?Qi:Ka;if(this.input.charCodeAt(++this.state.pos)!==117){this.raise(_.MissingUnicodeEscape,this.state.curPosition()),i=this.state.pos-1;continue}++this.state.pos;let c=this.readCodePoint(!0);c!==null&&(a(c)||this.raise(_.EscapedCharNotAnIdentifier,o),r+=String.fromCodePoint(c)),i=this.state.pos}else break}return r+this.input.slice(i,this.state.pos)}readWord(t){let r=this.readWord1(t),n=ex.get(r);n!==void 0?this.finishToken(n,Os(n)):this.finishToken(132,r)}checkKeywordEscapes(){let{type:t}=this.state;ox(t)&&this.state.containsEsc&&this.raise(_.InvalidEscapedReservedWord,this.state.startLoc,{reservedWord:Os(t)})}raise(t,r,n={}){let i=r instanceof vi?r:r.loc.start,s=t(i,n);if(!this.options.errorRecovery)throw s;return this.isLookahead||this.state.errors.push(s),s}raiseOverwrite(t,r,n={}){let i=r instanceof vi?r:r.loc.start,s=i.index,o=this.state.errors;for(let a=o.length-1;a>=0;a--){let c=o[a];if(c.loc.index===s)return o[a]=t(i,n);if(c.loc.index<s)break}return this.raise(t,r,n)}updateContext(t){}unexpected(t,r){throw this.raise(_.UnexpectedToken,t??this.state.startLoc,{expected:r?Os(r):null})}expectPlugin(t,r){if(this.hasPlugin(t))return!0;throw this.raise(_.MissingPlugin,r??this.state.startLoc,{missingPlugin:[t]})}expectOnePlugin(t){if(!t.some(r=>this.hasPlugin(r)))throw this.raise(_.MissingOneOfPlugins,this.state.startLoc,{missingPlugin:t})}errorBuilder(t){return(r,n,i)=>{this.raise(t,Xu(r,n,i))}}},Gb=class{constructor(){this.privateNames=new Set,this.loneAccessors=new Map,this.undefinedPrivateNames=new Map}},zb=class{constructor(t){this.parser=void 0,this.stack=[],this.undefinedPrivateNames=new Map,this.parser=t}current(){return this.stack[this.stack.length-1]}enter(){this.stack.push(new Gb)}exit(){let t=this.stack.pop(),r=this.current();for(let[n,i]of Array.from(t.undefinedPrivateNames))r?r.undefinedPrivateNames.has(n)||r.undefinedPrivateNames.set(n,i):this.parser.raise(_.InvalidPrivateFieldResolution,i,{identifierName:n})}declarePrivateName(t,r,n){let{privateNames:i,loneAccessors:s,undefinedPrivateNames:o}=this.current(),a=i.has(t);if(r&3){let c=a&&s.get(t);if(c){let u=c&4,l=r&4,p=c&3,d=r&3;a=p===d||u!==l,a||s.delete(t)}else a||s.set(t,r)}a&&this.parser.raise(_.PrivateNameRedeclaration,n,{identifierName:t}),i.add(t),o.delete(t)}usePrivateName(t,r){let n;for(n of this.stack)if(n.privateNames.has(t))return;n?n.undefinedPrivateNames.set(t,r):this.parser.raise(_.InvalidPrivateFieldResolution,r,{identifierName:t})}},Ja=class{constructor(t=0){this.type=t}canBeArrowParameterDeclaration(){return this.type===2||this.type===1}isCertainlyParameterDeclaration(){return this.type===3}},hf=class extends Ja{constructor(t){super(t),this.declarationErrors=new Map}recordDeclarationError(t,r){let n=r.index;this.declarationErrors.set(n,[t,r])}clearDeclarationError(t){this.declarationErrors.delete(t)}iterateErrors(t){this.declarationErrors.forEach(t)}},Hb=class{constructor(t){this.parser=void 0,this.stack=[new Ja],this.parser=t}enter(t){this.stack.push(t)}exit(){this.stack.pop()}recordParameterInitializerError(t,r){let n=r.loc.start,{stack:i}=this,s=i.length-1,o=i[s];for(;!o.isCertainlyParameterDeclaration();){if(o.canBeArrowParameterDeclaration())o.recordDeclarationError(t,n);else return;o=i[--s]}this.parser.raise(t,n)}recordArrowParameterBindingError(t,r){let{stack:n}=this,i=n[n.length-1],s=r.loc.start;if(i.isCertainlyParameterDeclaration())this.parser.raise(t,s);else if(i.canBeArrowParameterDeclaration())i.recordDeclarationError(t,s);else return}recordAsyncArrowParametersError(t){let{stack:r}=this,n=r.length-1,i=r[n];for(;i.canBeArrowParameterDeclaration();)i.type===2&&i.recordDeclarationError(_.AwaitBindingIdentifier,t),i=r[--n]}validateAsPattern(){let{stack:t}=this,r=t[t.length-1];r.canBeArrowParameterDeclaration()&&r.iterateErrors(([n,i])=>{this.parser.raise(n,i);let s=t.length-2,o=t[s];for(;o.canBeArrowParameterDeclaration();)o.clearDeclarationError(i.index),o=t[--s]})}};function gW(){return new Ja(3)}function yW(){return new hf(1)}function bW(){return new hf(2)}function XF(){return new Ja}var Kb=class{constructor(){this.stacks=[]}enter(t){this.stacks.push(t)}exit(){this.stacks.pop()}currentFlags(){return this.stacks[this.stacks.length-1]}get hasAwait(){return(this.currentFlags()&2)>0}get hasYield(){return(this.currentFlags()&1)>0}get hasReturn(){return(this.currentFlags()&4)>0}get hasIn(){return(this.currentFlags()&8)>0}};function df(e,t){return(e?2:0)|(t?1:0)}var Vb=class extends qb{addExtra(t,r,n,i=!0){if(!t)return;let{extra:s}=t;s==null&&(s={},t.extra=s),i?s[r]=n:Object.defineProperty(s,r,{enumerable:i,value:n})}isContextual(t){return this.state.type===t&&!this.state.containsEsc}isUnparsedContextual(t,r){let n=t+r.length;if(this.input.slice(t,n)===r){let i=this.input.charCodeAt(n);return!(Ka(i)||(i&64512)===55296)}return!1}isLookaheadContextual(t){let r=this.nextTokenStart();return this.isUnparsedContextual(r,t)}eatContextual(t){return this.isContextual(t)?(this.next(),!0):!1}expectContextual(t,r){if(!this.eatContextual(t)){if(r!=null)throw this.raise(r,this.state.startLoc);this.unexpected(null,t)}}canInsertSemicolon(){return this.match(139)||this.match(8)||this.hasPrecedingLineBreak()}hasPrecedingLineBreak(){return IF(this.input,this.state.lastTokEndLoc.index,this.state.start)}hasFollowingLineBreak(){return IF(this.input,this.state.end,this.nextTokenStart())}isLineTerminator(){return this.eat(13)||this.canInsertSemicolon()}semicolon(t=!0){(t?this.isLineTerminator():this.eat(13))||this.raise(_.MissingSemicolon,this.state.lastTokEndLoc)}expect(t,r){this.eat(t)||this.unexpected(r,t)}tryParse(t,r=this.state.clone()){let n={node:null};try{let i=t((s=null)=>{throw n.node=s,n});if(this.state.errors.length>r.errors.length){let s=this.state;return this.state=r,this.state.tokensLength=s.tokensLength,{node:i,error:s.errors[r.errors.length],thrown:!1,aborted:!1,failState:s}}return{node:i,error:null,thrown:!1,aborted:!1,failState:null}}catch(i){let s=this.state;if(this.state=r,i instanceof SyntaxError)return{node:null,error:i,thrown:!0,aborted:!1,failState:s};if(i===n)return{node:n.node,error:null,thrown:!1,aborted:!0,failState:s};throw i}}checkExpressionErrors(t,r){if(!t)return!1;let{shorthandAssignLoc:n,doubleProtoLoc:i,privateKeyLoc:s,optionalParametersLoc:o}=t,a=!!n||!!i||!!o||!!s;if(!r)return a;n!=null&&this.raise(_.InvalidCoverInitializedName,n),i!=null&&this.raise(_.DuplicateProto,i),s!=null&&this.raise(_.UnexpectedPrivateField,s),o!=null&&this.unexpected(o)}isLiteralPropertyName(){return jF(this.state.type)}isPrivateName(t){return t.type==="PrivateName"}getPrivateNameSV(t){return t.id.name}hasPropertyAsPrivateName(t){return(t.type==="MemberExpression"||t.type==="OptionalMemberExpression")&&this.isPrivateName(t.property)}isObjectProperty(t){return t.type==="ObjectProperty"}isObjectMethod(t){return t.type==="ObjectMethod"}initializeScopes(t=this.options.sourceType==="module"){let r=this.state.labels;this.state.labels=[];let n=this.exportedIdentifiers;this.exportedIdentifiers=new Set;let i=this.inModule;this.inModule=t;let s=this.scope,o=this.getScopeHandler();this.scope=new o(this,t);let a=this.prodParam;this.prodParam=new Kb;let c=this.classScope;this.classScope=new zb(this);let u=this.expressionScope;return this.expressionScope=new Hb(this),()=>{this.state.labels=r,this.exportedIdentifiers=n,this.inModule=i,this.scope=s,this.prodParam=a,this.classScope=c,this.expressionScope=u}}enterInitialScopes(){let t=0;this.inModule&&(t|=2),this.scope.enter(1),this.prodParam.enter(t)}checkDestructuringPrivate(t){let{privateKeyLoc:r}=t;r!==null&&this.expectPlugin("destructuringPrivate",r)}},Wa=class{constructor(){this.shorthandAssignLoc=null,this.doubleProtoLoc=null,this.privateKeyLoc=null,this.optionalParametersLoc=null}},Xa=class{constructor(t,r,n){this.type="",this.start=r,this.end=0,this.loc=new Ya(n),t!=null&&t.options.ranges&&(this.range=[r,0]),t!=null&&t.filename&&(this.loc.filename=t.filename)}},ux=Xa.prototype;ux.__clone=function(){let e=new Xa(void 0,this.start,this.loc.start),t=Object.keys(this);for(let r=0,n=t.length;r<n;r++){let i=t[r];i!=="leadingComments"&&i!=="trailingComments"&&i!=="innerComments"&&(e[i]=this[i])}return e};function xW(e){return es(e)}function es(e){let{type:t,start:r,end:n,loc:i,range:s,extra:o,name:a}=e,c=Object.create(ux);return c.type=t,c.start=r,c.end=n,c.loc=i,c.range=s,c.extra=o,c.name=a,t==="Placeholder"&&(c.expectedNode=e.expectedNode),c}function vW(e){let{type:t,start:r,end:n,loc:i,range:s,extra:o}=e;if(t==="Placeholder")return xW(e);let a=Object.create(ux);return a.type=t,a.start=r,a.end=n,a.loc=i,a.range=s,e.raw!==void 0?a.raw=e.raw:a.extra=o,a.value=e.value,a}var Wb=class extends Vb{startNode(){let t=this.state.startLoc;return new Xa(this,t.index,t)}startNodeAt(t){return new Xa(this,t.index,t)}startNodeAtNode(t){return this.startNodeAt(t.loc.start)}finishNode(t,r){return this.finishNodeAt(t,r,this.state.lastTokEndLoc)}finishNodeAt(t,r,n){return t.type=r,t.end=n.index,t.loc.end=n,this.options.ranges&&(t.range[1]=n.index),this.options.attachComment&&this.processComment(t),t}resetStartLocation(t,r){t.start=r.index,t.loc.start=r,this.options.ranges&&(t.range[0]=r.index)}resetEndLocation(t,r=this.state.lastTokEndLoc){t.end=r.index,t.loc.end=r,this.options.ranges&&(t.range[1]=r.index)}resetStartLocationFromNode(t,r){this.resetStartLocation(t,r.loc.start)}},DW=new Set(["_","any","bool","boolean","empty","extends","false","interface","mixed","null","number","static","string","true","typeof","void"]),ae=Zi`flow`({AmbiguousConditionalArrow:"Ambiguous expression: wrap the arrow functions in parentheses to disambiguate.",AmbiguousDeclareModuleKind:"Found both `declare module.exports` and `declare export` in the same module. Modules can only have 1 since they are either an ES module or they are a CommonJS module.",AssignReservedType:({reservedType:e})=>`Cannot overwrite reserved type ${e}.`,DeclareClassElement:"The `declare` modifier can only appear on class fields.",DeclareClassFieldInitializer:"Initializers are not allowed in fields with the `declare` modifier.",DuplicateDeclareModuleExports:"Duplicate `declare module.exports` statement.",EnumBooleanMemberNotInitialized:({memberName:e,enumName:t})=>`Boolean enum members need to be initialized. Use either \`${e} = true,\` or \`${e} = false,\` in enum \`${t}\`.`,EnumDuplicateMemberName:({memberName:e,enumName:t})=>`Enum member names need to be unique, but the name \`${e}\` has already been used before in enum \`${t}\`.`,EnumInconsistentMemberValues:({enumName:e})=>`Enum \`${e}\` has inconsistent member initializers. Either use no initializers, or consistently use literals (either booleans, numbers, or strings) for all member initializers.`,EnumInvalidExplicitType:({invalidEnumType:e,enumName:t})=>`Enum type \`${e}\` is not valid. Use one of \`boolean\`, \`number\`, \`string\`, or \`symbol\` in enum \`${t}\`.`,EnumInvalidExplicitTypeUnknownSupplied:({enumName:e})=>`Supplied enum type is not valid. Use one of \`boolean\`, \`number\`, \`string\`, or \`symbol\` in enum \`${e}\`.`,EnumInvalidMemberInitializerPrimaryType:({enumName:e,memberName:t,explicitType:r})=>`Enum \`${e}\` has type \`${r}\`, so the initializer of \`${t}\` needs to be a ${r} literal.`,EnumInvalidMemberInitializerSymbolType:({enumName:e,memberName:t})=>`Symbol enum members cannot be initialized. Use \`${t},\` in enum \`${e}\`.`,EnumInvalidMemberInitializerUnknownType:({enumName:e,memberName:t})=>`The enum member initializer for \`${t}\` needs to be a literal (either a boolean, number, or string) in enum \`${e}\`.`,EnumInvalidMemberName:({enumName:e,memberName:t,suggestion:r})=>`Enum member names cannot start with lowercase 'a' through 'z'. Instead of using \`${t}\`, consider using \`${r}\`, in enum \`${e}\`.`,EnumNumberMemberNotInitialized:({enumName:e,memberName:t})=>`Number enum members need to be initialized, e.g. \`${t} = 1\` in enum \`${e}\`.`,EnumStringMemberInconsistentlyInitialized:({enumName:e})=>`String enum members need to consistently either all use initializers, or use no initializers, in enum \`${e}\`.`,GetterMayNotHaveThisParam:"A getter cannot have a `this` parameter.",ImportReflectionHasImportType:"An `import module` declaration can not use `type` or `typeof` keyword.",ImportTypeShorthandOnlyInPureImport:"The `type` and `typeof` keywords on named imports can only be used on regular `import` statements. It cannot be used with `import type` or `import typeof` statements.",InexactInsideExact:"Explicit inexact syntax cannot appear inside an explicit exact object type.",InexactInsideNonObject:"Explicit inexact syntax cannot appear in class or interface definitions.",InexactVariance:"Explicit inexact syntax cannot have variance.",InvalidNonTypeImportInDeclareModule:"Imports within a `declare module` body must always be `import type` or `import typeof`.",MissingTypeParamDefault:"Type parameter declaration needs a default, since a preceding type parameter declaration has a default.",NestedDeclareModule:"`declare module` cannot be used inside another `declare module`.",NestedFlowComment:"Cannot have a flow comment inside another flow comment.",PatternIsOptional:Object.assign({message:"A binding pattern parameter cannot be optional in an implementation signature."},{reasonCode:"OptionalBindingPattern"}),SetterMayNotHaveThisParam:"A setter cannot have a `this` parameter.",SpreadVariance:"Spread properties cannot have variance.",ThisParamAnnotationRequired:"A type annotation is required for the `this` parameter.",ThisParamBannedInConstructor:"Constructors cannot have a `this` parameter; constructors don't bind `this` like other functions.",ThisParamMayNotBeOptional:"The `this` parameter cannot be optional.",ThisParamMustBeFirst:"The `this` parameter must be the first function parameter.",ThisParamNoDefault:"The `this` parameter may not have a default value.",TypeBeforeInitializer:"Type annotations must come before default assignments, e.g. instead of `age = 25: number` use `age: number = 25`.",TypeCastInPattern:"The type cast expression is expected to be wrapped with parenthesis.",UnexpectedExplicitInexactInObject:"Explicit inexact syntax must appear at the end of an inexact object.",UnexpectedReservedType:({reservedType:e})=>`Unexpected reserved type ${e}.`,UnexpectedReservedUnderscore:"`_` is only allowed as a type argument to call or new.",UnexpectedSpaceBetweenModuloChecks:"Spaces between `%` and `checks` are not allowed here.",UnexpectedSpreadType:"Spread operator cannot appear in class or interface definitions.",UnexpectedSubtractionOperand:'Unexpected token, expected "number" or "bigint".',UnexpectedTokenAfterTypeParameter:"Expected an arrow function after this type parameter declaration.",UnexpectedTypeParameterBeforeAsyncArrowFunction:"Type parameters must come after the async keyword, e.g. instead of `<T> async () => {}`, use `async <T>() => {}`.",UnsupportedDeclareExportKind:({unsupportedExportKind:e,suggestion:t})=>`\`declare export ${e}\` is not supported. Use \`${t}\` instead.`,UnsupportedStatementInDeclareModule:"Only declares and type imports are allowed inside declare module.",UnterminatedFlowComment:"Unterminated flow-comment."});function CW(e){return e.type==="DeclareExportAllDeclaration"||e.type==="DeclareExportDeclaration"&&(!e.declaration||e.declaration.type!=="TypeAlias"&&e.declaration.type!=="InterfaceDeclaration")}function RF(e){return e.importKind==="type"||e.importKind==="typeof"}var EW={const:"declare export var",let:"declare export var",type:"export type",interface:"export interface"};function wW(e,t){let r=[],n=[];for(let i=0;i<e.length;i++)(t(e[i],i,e)?r:n).push(e[i]);return[r,n]}var SW=/\*?\s*@((?:no)?flow)\b/,TW=e=>class extends e{constructor(...r){super(...r),this.flowPragma=void 0}getScopeHandler(){return Mb}shouldParseTypes(){return this.getPluginOption("flow","all")||this.flowPragma==="flow"}shouldParseEnums(){return!!this.getPluginOption("flow","enums")}finishToken(r,n){r!==133&&r!==13&&r!==28&&this.flowPragma===void 0&&(this.flowPragma=null),super.finishToken(r,n)}addComment(r){if(this.flowPragma===void 0){let n=SW.exec(r.value);if(n)if(n[1]==="flow")this.flowPragma="flow";else if(n[1]==="noflow")this.flowPragma="noflow";else throw new Error("Unexpected flow pragma")}super.addComment(r)}flowParseTypeInitialiser(r){let n=this.state.inType;this.state.inType=!0,this.expect(r||14);let i=this.flowParseType();return this.state.inType=n,i}flowParsePredicate(){let r=this.startNode(),n=this.state.startLoc;return this.next(),this.expectContextual(110),this.state.lastTokStartLoc.index>n.index+1&&this.raise(ae.UnexpectedSpaceBetweenModuloChecks,n),this.eat(10)?(r.value=super.parseExpression(),this.expect(11),this.finishNode(r,"DeclaredPredicate")):this.finishNode(r,"InferredPredicate")}flowParseTypeAndPredicateInitialiser(){let r=this.state.inType;this.state.inType=!0,this.expect(14);let n=null,i=null;return this.match(54)?(this.state.inType=r,i=this.flowParsePredicate()):(n=this.flowParseType(),this.state.inType=r,this.match(54)&&(i=this.flowParsePredicate())),[n,i]}flowParseDeclareClass(r){return this.next(),this.flowParseInterfaceish(r,!0),this.finishNode(r,"DeclareClass")}flowParseDeclareFunction(r){this.next();let n=r.id=this.parseIdentifier(),i=this.startNode(),s=this.startNode();this.match(47)?i.typeParameters=this.flowParseTypeParameterDeclaration():i.typeParameters=null,this.expect(10);let o=this.flowParseFunctionTypeParams();return i.params=o.params,i.rest=o.rest,i.this=o._this,this.expect(11),[i.returnType,r.predicate]=this.flowParseTypeAndPredicateInitialiser(),s.typeAnnotation=this.finishNode(i,"FunctionTypeAnnotation"),n.typeAnnotation=this.finishNode(s,"TypeAnnotation"),this.resetEndLocation(n),this.semicolon(),this.scope.declareName(r.id.name,2048,r.id.loc.start),this.finishNode(r,"DeclareFunction")}flowParseDeclare(r,n){if(this.match(80))return this.flowParseDeclareClass(r);if(this.match(68))return this.flowParseDeclareFunction(r);if(this.match(74))return this.flowParseDeclareVariable(r);if(this.eatContextual(127))return this.match(16)?this.flowParseDeclareModuleExports(r):(n&&this.raise(ae.NestedDeclareModule,this.state.lastTokStartLoc),this.flowParseDeclareModule(r));if(this.isContextual(130))return this.flowParseDeclareTypeAlias(r);if(this.isContextual(131))return this.flowParseDeclareOpaqueType(r);if(this.isContextual(129))return this.flowParseDeclareInterface(r);if(this.match(82))return this.flowParseDeclareExportDeclaration(r,n);this.unexpected()}flowParseDeclareVariable(r){return this.next(),r.id=this.flowParseTypeAnnotatableIdentifier(!0),this.scope.declareName(r.id.name,5,r.id.loc.start),this.semicolon(),this.finishNode(r,"DeclareVariable")}flowParseDeclareModule(r){this.scope.enter(0),this.match(133)?r.id=super.parseExprAtom():r.id=this.parseIdentifier();let n=r.body=this.startNode(),i=n.body=[];for(this.expect(5);!this.match(8);){let a=this.startNode();this.match(83)?(this.next(),!this.isContextual(130)&&!this.match(87)&&this.raise(ae.InvalidNonTypeImportInDeclareModule,this.state.lastTokStartLoc),super.parseImport(a)):(this.expectContextual(125,ae.UnsupportedStatementInDeclareModule),a=this.flowParseDeclare(a,!0)),i.push(a)}this.scope.exit(),this.expect(8),this.finishNode(n,"BlockStatement");let s=null,o=!1;return i.forEach(a=>{CW(a)?(s==="CommonJS"&&this.raise(ae.AmbiguousDeclareModuleKind,a),s="ES"):a.type==="DeclareModuleExports"&&(o&&this.raise(ae.DuplicateDeclareModuleExports,a),s==="ES"&&this.raise(ae.AmbiguousDeclareModuleKind,a),s="CommonJS",o=!0)}),r.kind=s||"CommonJS",this.finishNode(r,"DeclareModule")}flowParseDeclareExportDeclaration(r,n){if(this.expect(82),this.eat(65))return this.match(68)||this.match(80)?r.declaration=this.flowParseDeclare(this.startNode()):(r.declaration=this.flowParseType(),this.semicolon()),r.default=!0,this.finishNode(r,"DeclareExportDeclaration");if(this.match(75)||this.isLet()||(this.isContextual(130)||this.isContextual(129))&&!n){let i=this.state.value;throw this.raise(ae.UnsupportedDeclareExportKind,this.state.startLoc,{unsupportedExportKind:i,suggestion:EW[i]})}if(this.match(74)||this.match(68)||this.match(80)||this.isContextual(131))return r.declaration=this.flowParseDeclare(this.startNode()),r.default=!1,this.finishNode(r,"DeclareExportDeclaration");if(this.match(55)||this.match(5)||this.isContextual(129)||this.isContextual(130)||this.isContextual(131))return r=this.parseExport(r,null),r.type==="ExportNamedDeclaration"&&(r.type="ExportDeclaration",r.default=!1,delete r.exportKind),r.type="Declare"+r.type,r;this.unexpected()}flowParseDeclareModuleExports(r){return this.next(),this.expectContextual(111),r.typeAnnotation=this.flowParseTypeAnnotation(),this.semicolon(),this.finishNode(r,"DeclareModuleExports")}flowParseDeclareTypeAlias(r){this.next();let n=this.flowParseTypeAlias(r);return n.type="DeclareTypeAlias",n}flowParseDeclareOpaqueType(r){this.next();let n=this.flowParseOpaqueType(r,!0);return n.type="DeclareOpaqueType",n}flowParseDeclareInterface(r){return this.next(),this.flowParseInterfaceish(r,!1),this.finishNode(r,"DeclareInterface")}flowParseInterfaceish(r,n){if(r.id=this.flowParseRestrictedIdentifier(!n,!0),this.scope.declareName(r.id.name,n?17:8201,r.id.loc.start),this.match(47)?r.typeParameters=this.flowParseTypeParameterDeclaration():r.typeParameters=null,r.extends=[],this.eat(81))do r.extends.push(this.flowParseInterfaceExtends());while(!n&&this.eat(12));if(n){if(r.implements=[],r.mixins=[],this.eatContextual(117))do r.mixins.push(this.flowParseInterfaceExtends());while(this.eat(12));if(this.eatContextual(113))do r.implements.push(this.flowParseInterfaceExtends());while(this.eat(12))}r.body=this.flowParseObjectType({allowStatic:n,allowExact:!1,allowSpread:!1,allowProto:n,allowInexact:!1})}flowParseInterfaceExtends(){let r=this.startNode();return r.id=this.flowParseQualifiedTypeIdentifier(),this.match(47)?r.typeParameters=this.flowParseTypeParameterInstantiation():r.typeParameters=null,this.finishNode(r,"InterfaceExtends")}flowParseInterface(r){return this.flowParseInterfaceish(r,!1),this.finishNode(r,"InterfaceDeclaration")}checkNotUnderscore(r){r==="_"&&this.raise(ae.UnexpectedReservedUnderscore,this.state.startLoc)}checkReservedType(r,n,i){DW.has(r)&&this.raise(i?ae.AssignReservedType:ae.UnexpectedReservedType,n,{reservedType:r})}flowParseRestrictedIdentifier(r,n){return this.checkReservedType(this.state.value,this.state.startLoc,n),this.parseIdentifier(r)}flowParseTypeAlias(r){return r.id=this.flowParseRestrictedIdentifier(!1,!0),this.scope.declareName(r.id.name,8201,r.id.loc.start),this.match(47)?r.typeParameters=this.flowParseTypeParameterDeclaration():r.typeParameters=null,r.right=this.flowParseTypeInitialiser(29),this.semicolon(),this.finishNode(r,"TypeAlias")}flowParseOpaqueType(r,n){return this.expectContextual(130),r.id=this.flowParseRestrictedIdentifier(!0,!0),this.scope.declareName(r.id.name,8201,r.id.loc.start),this.match(47)?r.typeParameters=this.flowParseTypeParameterDeclaration():r.typeParameters=null,r.supertype=null,this.match(14)&&(r.supertype=this.flowParseTypeInitialiser(14)),r.impltype=null,n||(r.impltype=this.flowParseTypeInitialiser(29)),this.semicolon(),this.finishNode(r,"OpaqueType")}flowParseTypeParameter(r=!1){let n=this.state.startLoc,i=this.startNode(),s=this.flowParseVariance(),o=this.flowParseTypeAnnotatableIdentifier();return i.name=o.name,i.variance=s,i.bound=o.typeAnnotation,this.match(29)?(this.eat(29),i.default=this.flowParseType()):r&&this.raise(ae.MissingTypeParamDefault,n),this.finishNode(i,"TypeParameter")}flowParseTypeParameterDeclaration(){let r=this.state.inType,n=this.startNode();n.params=[],this.state.inType=!0,this.match(47)||this.match(142)?this.next():this.unexpected();let i=!1;do{let s=this.flowParseTypeParameter(i);n.params.push(s),s.default&&(i=!0),this.match(48)||this.expect(12)}while(!this.match(48));return this.expect(48),this.state.inType=r,this.finishNode(n,"TypeParameterDeclaration")}flowParseTypeParameterInstantiation(){let r=this.startNode(),n=this.state.inType;r.params=[],this.state.inType=!0,this.expect(47);let i=this.state.noAnonFunctionType;for(this.state.noAnonFunctionType=!1;!this.match(48);)r.params.push(this.flowParseType()),this.match(48)||this.expect(12);return this.state.noAnonFunctionType=i,this.expect(48),this.state.inType=n,this.finishNode(r,"TypeParameterInstantiation")}flowParseTypeParameterInstantiationCallOrNew(){let r=this.startNode(),n=this.state.inType;for(r.params=[],this.state.inType=!0,this.expect(47);!this.match(48);)r.params.push(this.flowParseTypeOrImplicitInstantiation()),this.match(48)||this.expect(12);return this.expect(48),this.state.inType=n,this.finishNode(r,"TypeParameterInstantiation")}flowParseInterfaceType(){let r=this.startNode();if(this.expectContextual(129),r.extends=[],this.eat(81))do r.extends.push(this.flowParseInterfaceExtends());while(this.eat(12));return r.body=this.flowParseObjectType({allowStatic:!1,allowExact:!1,allowSpread:!1,allowProto:!1,allowInexact:!1}),this.finishNode(r,"InterfaceTypeAnnotation")}flowParseObjectPropertyKey(){return this.match(134)||this.match(133)?super.parseExprAtom():this.parseIdentifier(!0)}flowParseObjectTypeIndexer(r,n,i){return r.static=n,this.lookahead().type===14?(r.id=this.flowParseObjectPropertyKey(),r.key=this.flowParseTypeInitialiser()):(r.id=null,r.key=this.flowParseType()),this.expect(3),r.value=this.flowParseTypeInitialiser(),r.variance=i,this.finishNode(r,"ObjectTypeIndexer")}flowParseObjectTypeInternalSlot(r,n){return r.static=n,r.id=this.flowParseObjectPropertyKey(),this.expect(3),this.expect(3),this.match(47)||this.match(10)?(r.method=!0,r.optional=!1,r.value=this.flowParseObjectTypeMethodish(this.startNodeAt(r.loc.start))):(r.method=!1,this.eat(17)&&(r.optional=!0),r.value=this.flowParseTypeInitialiser()),this.finishNode(r,"ObjectTypeInternalSlot")}flowParseObjectTypeMethodish(r){for(r.params=[],r.rest=null,r.typeParameters=null,r.this=null,this.match(47)&&(r.typeParameters=this.flowParseTypeParameterDeclaration()),this.expect(10),this.match(78)&&(r.this=this.flowParseFunctionTypeParam(!0),r.this.name=null,this.match(11)||this.expect(12));!this.match(11)&&!this.match(21);)r.params.push(this.flowParseFunctionTypeParam(!1)),this.match(11)||this.expect(12);return this.eat(21)&&(r.rest=this.flowParseFunctionTypeParam(!1)),this.expect(11),r.returnType=this.flowParseTypeInitialiser(),this.finishNode(r,"FunctionTypeAnnotation")}flowParseObjectTypeCallProperty(r,n){let i=this.startNode();return r.static=n,r.value=this.flowParseObjectTypeMethodish(i),this.finishNode(r,"ObjectTypeCallProperty")}flowParseObjectType({allowStatic:r,allowExact:n,allowSpread:i,allowProto:s,allowInexact:o}){let a=this.state.inType;this.state.inType=!0;let c=this.startNode();c.callProperties=[],c.properties=[],c.indexers=[],c.internalSlots=[];let u,l,p=!1;for(n&&this.match(6)?(this.expect(6),u=9,l=!0):(this.expect(5),u=8,l=!1),c.exact=l;!this.match(u);){let h=!1,m=null,g=null,y=this.startNode();if(s&&this.isContextual(118)){let v=this.lookahead();v.type!==14&&v.type!==17&&(this.next(),m=this.state.startLoc,r=!1)}if(r&&this.isContextual(106)){let v=this.lookahead();v.type!==14&&v.type!==17&&(this.next(),h=!0)}let b=this.flowParseVariance();if(this.eat(0))m!=null&&this.unexpected(m),this.eat(0)?(b&&this.unexpected(b.loc.start),c.internalSlots.push(this.flowParseObjectTypeInternalSlot(y,h))):c.indexers.push(this.flowParseObjectTypeIndexer(y,h,b));else if(this.match(10)||this.match(47))m!=null&&this.unexpected(m),b&&this.unexpected(b.loc.start),c.callProperties.push(this.flowParseObjectTypeCallProperty(y,h));else{let v="init";if(this.isContextual(99)||this.isContextual(104)){let x=this.lookahead();jF(x.type)&&(v=this.state.value,this.next())}let C=this.flowParseObjectTypeProperty(y,h,m,b,v,i,o??!l);C===null?(p=!0,g=this.state.lastTokStartLoc):c.properties.push(C)}this.flowObjectTypeSemicolon(),g&&!this.match(8)&&!this.match(9)&&this.raise(ae.UnexpectedExplicitInexactInObject,g)}this.expect(u),i&&(c.inexact=p);let d=this.finishNode(c,"ObjectTypeAnnotation");return this.state.inType=a,d}flowParseObjectTypeProperty(r,n,i,s,o,a,c){if(this.eat(21))return this.match(12)||this.match(13)||this.match(8)||this.match(9)?(a?c||this.raise(ae.InexactInsideExact,this.state.lastTokStartLoc):this.raise(ae.InexactInsideNonObject,this.state.lastTokStartLoc),s&&this.raise(ae.InexactVariance,s),null):(a||this.raise(ae.UnexpectedSpreadType,this.state.lastTokStartLoc),i!=null&&this.unexpected(i),s&&this.raise(ae.SpreadVariance,s),r.argument=this.flowParseType(),this.finishNode(r,"ObjectTypeSpreadProperty"));{r.key=this.flowParseObjectPropertyKey(),r.static=n,r.proto=i!=null,r.kind=o;let u=!1;return this.match(47)||this.match(10)?(r.method=!0,i!=null&&this.unexpected(i),s&&this.unexpected(s.loc.start),r.value=this.flowParseObjectTypeMethodish(this.startNodeAt(r.loc.start)),(o==="get"||o==="set")&&this.flowCheckGetterSetterParams(r),!a&&r.key.name==="constructor"&&r.value.this&&this.raise(ae.ThisParamBannedInConstructor,r.value.this)):(o!=="init"&&this.unexpected(),r.method=!1,this.eat(17)&&(u=!0),r.value=this.flowParseTypeInitialiser(),r.variance=s),r.optional=u,this.finishNode(r,"ObjectTypeProperty")}}flowCheckGetterSetterParams(r){let n=r.kind==="get"?0:1,i=r.value.params.length+(r.value.rest?1:0);r.value.this&&this.raise(r.kind==="get"?ae.GetterMayNotHaveThisParam:ae.SetterMayNotHaveThisParam,r.value.this),i!==n&&this.raise(r.kind==="get"?_.BadGetterArity:_.BadSetterArity,r),r.kind==="set"&&r.value.rest&&this.raise(_.BadSetterRestParameter,r)}flowObjectTypeSemicolon(){!this.eat(13)&&!this.eat(12)&&!this.match(8)&&!this.match(9)&&this.unexpected()}flowParseQualifiedTypeIdentifier(r,n){var i;(i=r)!=null||(r=this.state.startLoc);let s=n||this.flowParseRestrictedIdentifier(!0);for(;this.eat(16);){let o=this.startNodeAt(r);o.qualification=s,o.id=this.flowParseRestrictedIdentifier(!0),s=this.finishNode(o,"QualifiedTypeIdentifier")}return s}flowParseGenericType(r,n){let i=this.startNodeAt(r);return i.typeParameters=null,i.id=this.flowParseQualifiedTypeIdentifier(r,n),this.match(47)&&(i.typeParameters=this.flowParseTypeParameterInstantiation()),this.finishNode(i,"GenericTypeAnnotation")}flowParseTypeofType(){let r=this.startNode();return this.expect(87),r.argument=this.flowParsePrimaryType(),this.finishNode(r,"TypeofTypeAnnotation")}flowParseTupleType(){let r=this.startNode();for(r.types=[],this.expect(0);this.state.pos<this.length&&!this.match(3)&&(r.types.push(this.flowParseType()),!this.match(3));)this.expect(12);return this.expect(3),this.finishNode(r,"TupleTypeAnnotation")}flowParseFunctionTypeParam(r){let n=null,i=!1,s=null,o=this.startNode(),a=this.lookahead(),c=this.state.type===78;return a.type===14||a.type===17?(c&&!r&&this.raise(ae.ThisParamMustBeFirst,o),n=this.parseIdentifier(c),this.eat(17)&&(i=!0,c&&this.raise(ae.ThisParamMayNotBeOptional,o)),s=this.flowParseTypeInitialiser()):s=this.flowParseType(),o.name=n,o.optional=i,o.typeAnnotation=s,this.finishNode(o,"FunctionTypeParam")}reinterpretTypeAsFunctionTypeParam(r){let n=this.startNodeAt(r.loc.start);return n.name=null,n.optional=!1,n.typeAnnotation=r,this.finishNode(n,"FunctionTypeParam")}flowParseFunctionTypeParams(r=[]){let n=null,i=null;for(this.match(78)&&(i=this.flowParseFunctionTypeParam(!0),i.name=null,this.match(11)||this.expect(12));!this.match(11)&&!this.match(21);)r.push(this.flowParseFunctionTypeParam(!1)),this.match(11)||this.expect(12);return this.eat(21)&&(n=this.flowParseFunctionTypeParam(!1)),{params:r,rest:n,_this:i}}flowIdentToTypeAnnotation(r,n,i){switch(i.name){case"any":return this.finishNode(n,"AnyTypeAnnotation");case"bool":case"boolean":return this.finishNode(n,"BooleanTypeAnnotation");case"mixed":return this.finishNode(n,"MixedTypeAnnotation");case"empty":return this.finishNode(n,"EmptyTypeAnnotation");case"number":return this.finishNode(n,"NumberTypeAnnotation");case"string":return this.finishNode(n,"StringTypeAnnotation");case"symbol":return this.finishNode(n,"SymbolTypeAnnotation");default:return this.checkNotUnderscore(i.name),this.flowParseGenericType(r,i)}}flowParsePrimaryType(){let r=this.state.startLoc,n=this.startNode(),i,s,o=!1,a=this.state.noAnonFunctionType;switch(this.state.type){case 5:return this.flowParseObjectType({allowStatic:!1,allowExact:!1,allowSpread:!0,allowProto:!1,allowInexact:!0});case 6:return this.flowParseObjectType({allowStatic:!1,allowExact:!0,allowSpread:!0,allowProto:!1,allowInexact:!1});case 0:return this.state.noAnonFunctionType=!1,s=this.flowParseTupleType(),this.state.noAnonFunctionType=a,s;case 47:{let c=this.startNode();return c.typeParameters=this.flowParseTypeParameterDeclaration(),this.expect(10),i=this.flowParseFunctionTypeParams(),c.params=i.params,c.rest=i.rest,c.this=i._this,this.expect(11),this.expect(19),c.returnType=this.flowParseType(),this.finishNode(c,"FunctionTypeAnnotation")}case 10:{let c=this.startNode();if(this.next(),!this.match(11)&&!this.match(21))if(Ue(this.state.type)||this.match(78)){let u=this.lookahead().type;o=u!==17&&u!==14}else o=!0;if(o){if(this.state.noAnonFunctionType=!1,s=this.flowParseType(),this.state.noAnonFunctionType=a,this.state.noAnonFunctionType||!(this.match(12)||this.match(11)&&this.lookahead().type===19))return this.expect(11),s;this.eat(12)}return s?i=this.flowParseFunctionTypeParams([this.reinterpretTypeAsFunctionTypeParam(s)]):i=this.flowParseFunctionTypeParams(),c.params=i.params,c.rest=i.rest,c.this=i._this,this.expect(11),this.expect(19),c.returnType=this.flowParseType(),c.typeParameters=null,this.finishNode(c,"FunctionTypeAnnotation")}case 133:return this.parseLiteral(this.state.value,"StringLiteralTypeAnnotation");case 85:case 86:return n.value=this.match(85),this.next(),this.finishNode(n,"BooleanLiteralTypeAnnotation");case 53:if(this.state.value==="-"){if(this.next(),this.match(134))return this.parseLiteralAtNode(-this.state.value,"NumberLiteralTypeAnnotation",n);if(this.match(135))return this.parseLiteralAtNode(-this.state.value,"BigIntLiteralTypeAnnotation",n);throw this.raise(ae.UnexpectedSubtractionOperand,this.state.startLoc)}this.unexpected();return;case 134:return this.parseLiteral(this.state.value,"NumberLiteralTypeAnnotation");case 135:return this.parseLiteral(this.state.value,"BigIntLiteralTypeAnnotation");case 88:return this.next(),this.finishNode(n,"VoidTypeAnnotation");case 84:return this.next(),this.finishNode(n,"NullLiteralTypeAnnotation");case 78:return this.next(),this.finishNode(n,"ThisTypeAnnotation");case 55:return this.next(),this.finishNode(n,"ExistsTypeAnnotation");case 87:return this.flowParseTypeofType();default:if(ox(this.state.type)){let c=Os(this.state.type);return this.next(),super.createIdentifier(n,c)}else if(Ue(this.state.type))return this.isContextual(129)?this.flowParseInterfaceType():this.flowIdentToTypeAnnotation(r,n,this.parseIdentifier())}this.unexpected()}flowParsePostfixType(){let r=this.state.startLoc,n=this.flowParsePrimaryType(),i=!1;for(;(this.match(0)||this.match(18))&&!this.canInsertSemicolon();){let s=this.startNodeAt(r),o=this.eat(18);i=i||o,this.expect(0),!o&&this.match(3)?(s.elementType=n,this.next(),n=this.finishNode(s,"ArrayTypeAnnotation")):(s.objectType=n,s.indexType=this.flowParseType(),this.expect(3),i?(s.optional=o,n=this.finishNode(s,"OptionalIndexedAccessType")):n=this.finishNode(s,"IndexedAccessType"))}return n}flowParsePrefixType(){let r=this.startNode();return this.eat(17)?(r.typeAnnotation=this.flowParsePrefixType(),this.finishNode(r,"NullableTypeAnnotation")):this.flowParsePostfixType()}flowParseAnonFunctionWithoutParens(){let r=this.flowParsePrefixType();if(!this.state.noAnonFunctionType&&this.eat(19)){let n=this.startNodeAt(r.loc.start);return n.params=[this.reinterpretTypeAsFunctionTypeParam(r)],n.rest=null,n.this=null,n.returnType=this.flowParseType(),n.typeParameters=null,this.finishNode(n,"FunctionTypeAnnotation")}return r}flowParseIntersectionType(){let r=this.startNode();this.eat(45);let n=this.flowParseAnonFunctionWithoutParens();for(r.types=[n];this.eat(45);)r.types.push(this.flowParseAnonFunctionWithoutParens());return r.types.length===1?n:this.finishNode(r,"IntersectionTypeAnnotation")}flowParseUnionType(){let r=this.startNode();this.eat(43);let n=this.flowParseIntersectionType();for(r.types=[n];this.eat(43);)r.types.push(this.flowParseIntersectionType());return r.types.length===1?n:this.finishNode(r,"UnionTypeAnnotation")}flowParseType(){let r=this.state.inType;this.state.inType=!0;let n=this.flowParseUnionType();return this.state.inType=r,n}flowParseTypeOrImplicitInstantiation(){if(this.state.type===132&&this.state.value==="_"){let r=this.state.startLoc,n=this.parseIdentifier();return this.flowParseGenericType(r,n)}else return this.flowParseType()}flowParseTypeAnnotation(){let r=this.startNode();return r.typeAnnotation=this.flowParseTypeInitialiser(),this.finishNode(r,"TypeAnnotation")}flowParseTypeAnnotatableIdentifier(r){let n=r?this.parseIdentifier():this.flowParseRestrictedIdentifier();return this.match(14)&&(n.typeAnnotation=this.flowParseTypeAnnotation(),this.resetEndLocation(n)),n}typeCastToParameter(r){return r.expression.typeAnnotation=r.typeAnnotation,this.resetEndLocation(r.expression,r.typeAnnotation.loc.end),r.expression}flowParseVariance(){let r=null;return this.match(53)?(r=this.startNode(),this.state.value==="+"?r.kind="plus":r.kind="minus",this.next(),this.finishNode(r,"Variance")):r}parseFunctionBody(r,n,i=!1){if(n){this.forwardNoArrowParamsConversionAt(r,()=>super.parseFunctionBody(r,!0,i));return}super.parseFunctionBody(r,!1,i)}parseFunctionBodyAndFinish(r,n,i=!1){if(this.match(14)){let s=this.startNode();[s.typeAnnotation,r.predicate]=this.flowParseTypeAndPredicateInitialiser(),r.returnType=s.typeAnnotation?this.finishNode(s,"TypeAnnotation"):null}return super.parseFunctionBodyAndFinish(r,n,i)}parseStatementLike(r){if(this.state.strict&&this.isContextual(129)){let i=this.lookahead();if(Vn(i.type)){let s=this.startNode();return this.next(),this.flowParseInterface(s)}}else if(this.shouldParseEnums()&&this.isContextual(126)){let i=this.startNode();return this.next(),this.flowParseEnumDeclaration(i)}let n=super.parseStatementLike(r);return this.flowPragma===void 0&&!this.isValidDirective(n)&&(this.flowPragma=null),n}parseExpressionStatement(r,n,i){if(n.type==="Identifier"){if(n.name==="declare"){if(this.match(80)||Ue(this.state.type)||this.match(68)||this.match(74)||this.match(82))return this.flowParseDeclare(r)}else if(Ue(this.state.type)){if(n.name==="interface")return this.flowParseInterface(r);if(n.name==="type")return this.flowParseTypeAlias(r);if(n.name==="opaque")return this.flowParseOpaqueType(r,!1)}}return super.parseExpressionStatement(r,n,i)}shouldParseExportDeclaration(){let{type:r}=this.state;return _F(r)||this.shouldParseEnums()&&r===126?!this.state.containsEsc:super.shouldParseExportDeclaration()}isExportDefaultSpecifier(){let{type:r}=this.state;return _F(r)||this.shouldParseEnums()&&r===126?this.state.containsEsc:super.isExportDefaultSpecifier()}parseExportDefaultExpression(){if(this.shouldParseEnums()&&this.isContextual(126)){let r=this.startNode();return this.next(),this.flowParseEnumDeclaration(r)}return super.parseExportDefaultExpression()}parseConditional(r,n,i){if(!this.match(17))return r;if(this.state.maybeInArrowParameters){let d=this.lookaheadCharCode();if(d===44||d===61||d===58||d===41)return this.setOptionalParametersError(i),r}this.expect(17);let s=this.state.clone(),o=this.state.noArrowAt,a=this.startNodeAt(n),{consequent:c,failed:u}=this.tryParseConditionalConsequent(),[l,p]=this.getArrowLikeExpressions(c);if(u||p.length>0){let d=[...o];if(p.length>0){this.state=s,this.state.noArrowAt=d;for(let h=0;h<p.length;h++)d.push(p[h].start);({consequent:c,failed:u}=this.tryParseConditionalConsequent()),[l,p]=this.getArrowLikeExpressions(c)}u&&l.length>1&&this.raise(ae.AmbiguousConditionalArrow,s.startLoc),u&&l.length===1&&(this.state=s,d.push(l[0].start),this.state.noArrowAt=d,{consequent:c,failed:u}=this.tryParseConditionalConsequent())}return this.getArrowLikeExpressions(c,!0),this.state.noArrowAt=o,this.expect(14),a.test=r,a.consequent=c,a.alternate=this.forwardNoArrowParamsConversionAt(a,()=>this.parseMaybeAssign(void 0,void 0)),this.finishNode(a,"ConditionalExpression")}tryParseConditionalConsequent(){this.state.noArrowParamsConversionAt.push(this.state.start);let r=this.parseMaybeAssignAllowIn(),n=!this.match(14);return this.state.noArrowParamsConversionAt.pop(),{consequent:r,failed:n}}getArrowLikeExpressions(r,n){let i=[r],s=[];for(;i.length!==0;){let o=i.pop();o.type==="ArrowFunctionExpression"&&o.body.type!=="BlockStatement"?(o.typeParameters||!o.returnType?this.finishArrowValidation(o):s.push(o),i.push(o.body)):o.type==="ConditionalExpression"&&(i.push(o.consequent),i.push(o.alternate))}return n?(s.forEach(o=>this.finishArrowValidation(o)),[s,[]]):wW(s,o=>o.params.every(a=>this.isAssignable(a,!0)))}finishArrowValidation(r){var n;this.toAssignableList(r.params,(n=r.extra)==null?void 0:n.trailingCommaLoc,!1),this.scope.enter(6),super.checkParams(r,!1,!0),this.scope.exit()}forwardNoArrowParamsConversionAt(r,n){let i;return this.state.noArrowParamsConversionAt.includes(r.start)?(this.state.noArrowParamsConversionAt.push(this.state.start),i=n(),this.state.noArrowParamsConversionAt.pop()):i=n(),i}parseParenItem(r,n){let i=super.parseParenItem(r,n);if(this.eat(17)&&(i.optional=!0,this.resetEndLocation(r)),this.match(14)){let s=this.startNodeAt(n);return s.expression=i,s.typeAnnotation=this.flowParseTypeAnnotation(),this.finishNode(s,"TypeCastExpression")}return i}assertModuleNodeAllowed(r){r.type==="ImportDeclaration"&&(r.importKind==="type"||r.importKind==="typeof")||r.type==="ExportNamedDeclaration"&&r.exportKind==="type"||r.type==="ExportAllDeclaration"&&r.exportKind==="type"||super.assertModuleNodeAllowed(r)}parseExportDeclaration(r){if(this.isContextual(130)){r.exportKind="type";let n=this.startNode();return this.next(),this.match(5)?(r.specifiers=this.parseExportSpecifiers(!0),super.parseExportFrom(r),null):this.flowParseTypeAlias(n)}else if(this.isContextual(131)){r.exportKind="type";let n=this.startNode();return this.next(),this.flowParseOpaqueType(n,!1)}else if(this.isContextual(129)){r.exportKind="type";let n=this.startNode();return this.next(),this.flowParseInterface(n)}else if(this.shouldParseEnums()&&this.isContextual(126)){r.exportKind="value";let n=this.startNode();return this.next(),this.flowParseEnumDeclaration(n)}else return super.parseExportDeclaration(r)}eatExportStar(r){return super.eatExportStar(r)?!0:this.isContextual(130)&&this.lookahead().type===55?(r.exportKind="type",this.next(),this.next(),!0):!1}maybeParseExportNamespaceSpecifier(r){let{startLoc:n}=this.state,i=super.maybeParseExportNamespaceSpecifier(r);return i&&r.exportKind==="type"&&this.unexpected(n),i}parseClassId(r,n,i){super.parseClassId(r,n,i),this.match(47)&&(r.typeParameters=this.flowParseTypeParameterDeclaration())}parseClassMember(r,n,i){let{startLoc:s}=this.state;if(this.isContextual(125)){if(super.parseClassMemberFromModifier(r,n))return;n.declare=!0}super.parseClassMember(r,n,i),n.declare&&(n.type!=="ClassProperty"&&n.type!=="ClassPrivateProperty"&&n.type!=="PropertyDefinition"?this.raise(ae.DeclareClassElement,s):n.value&&this.raise(ae.DeclareClassFieldInitializer,n.value))}isIterator(r){return r==="iterator"||r==="asyncIterator"}readIterator(){let r=super.readWord1(),n="@@"+r;(!this.isIterator(r)||!this.state.inType)&&this.raise(_.InvalidIdentifier,this.state.curPosition(),{identifierName:n}),this.finishToken(132,n)}getTokenFromCode(r){let n=this.input.charCodeAt(this.state.pos+1);r===123&&n===124?this.finishOp(6,2):this.state.inType&&(r===62||r===60)?this.finishOp(r===62?48:47,1):this.state.inType&&r===63?n===46?this.finishOp(18,2):this.finishOp(17,1):oW(r,n,this.input.charCodeAt(this.state.pos+2))?(this.state.pos+=2,this.readIterator()):super.getTokenFromCode(r)}isAssignable(r,n){return r.type==="TypeCastExpression"?this.isAssignable(r.expression,n):super.isAssignable(r,n)}toAssignable(r,n=!1){!n&&r.type==="AssignmentExpression"&&r.left.type==="TypeCastExpression"&&(r.left=this.typeCastToParameter(r.left)),super.toAssignable(r,n)}toAssignableList(r,n,i){for(let s=0;s<r.length;s++){let o=r[s];o?.type==="TypeCastExpression"&&(r[s]=this.typeCastToParameter(o))}super.toAssignableList(r,n,i)}toReferencedList(r,n){for(let s=0;s<r.length;s++){var i;let o=r[s];o&&o.type==="TypeCastExpression"&&!((i=o.extra)!=null&&i.parenthesized)&&(r.length>1||!n)&&this.raise(ae.TypeCastInPattern,o.typeAnnotation)}return r}parseArrayLike(r,n,i,s){let o=super.parseArrayLike(r,n,i,s);return n&&!this.state.maybeInArrowParameters&&this.toReferencedList(o.elements),o}isValidLVal(r,n,i){return r==="TypeCastExpression"||super.isValidLVal(r,n,i)}parseClassProperty(r){return this.match(14)&&(r.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassProperty(r)}parseClassPrivateProperty(r){return this.match(14)&&(r.typeAnnotation=this.flowParseTypeAnnotation()),super.parseClassPrivateProperty(r)}isClassMethod(){return this.match(47)||super.isClassMethod()}isClassProperty(){return this.match(14)||super.isClassProperty()}isNonstaticConstructor(r){return!this.match(14)&&super.isNonstaticConstructor(r)}pushClassMethod(r,n,i,s,o,a){if(n.variance&&this.unexpected(n.variance.loc.start),delete n.variance,this.match(47)&&(n.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassMethod(r,n,i,s,o,a),n.params&&o){let c=n.params;c.length>0&&this.isThisParam(c[0])&&this.raise(ae.ThisParamBannedInConstructor,n)}else if(n.type==="MethodDefinition"&&o&&n.value.params){let c=n.value.params;c.length>0&&this.isThisParam(c[0])&&this.raise(ae.ThisParamBannedInConstructor,n)}}pushClassPrivateMethod(r,n,i,s){n.variance&&this.unexpected(n.variance.loc.start),delete n.variance,this.match(47)&&(n.typeParameters=this.flowParseTypeParameterDeclaration()),super.pushClassPrivateMethod(r,n,i,s)}parseClassSuper(r){if(super.parseClassSuper(r),r.superClass&&this.match(47)&&(r.superTypeParameters=this.flowParseTypeParameterInstantiation()),this.isContextual(113)){this.next();let n=r.implements=[];do{let i=this.startNode();i.id=this.flowParseRestrictedIdentifier(!0),this.match(47)?i.typeParameters=this.flowParseTypeParameterInstantiation():i.typeParameters=null,n.push(this.finishNode(i,"ClassImplements"))}while(this.eat(12))}}checkGetterSetterParams(r){super.checkGetterSetterParams(r);let n=this.getObjectOrClassMethodParams(r);if(n.length>0){let i=n[0];this.isThisParam(i)&&r.kind==="get"?this.raise(ae.GetterMayNotHaveThisParam,i):this.isThisParam(i)&&this.raise(ae.SetterMayNotHaveThisParam,i)}}parsePropertyNamePrefixOperator(r){r.variance=this.flowParseVariance()}parseObjPropValue(r,n,i,s,o,a,c){r.variance&&this.unexpected(r.variance.loc.start),delete r.variance;let u;this.match(47)&&!a&&(u=this.flowParseTypeParameterDeclaration(),this.match(10)||this.unexpected());let l=super.parseObjPropValue(r,n,i,s,o,a,c);return u&&((l.value||l).typeParameters=u),l}parseAssignableListItemTypes(r){return this.eat(17)&&(r.type!=="Identifier"&&this.raise(ae.PatternIsOptional,r),this.isThisParam(r)&&this.raise(ae.ThisParamMayNotBeOptional,r),r.optional=!0),this.match(14)?r.typeAnnotation=this.flowParseTypeAnnotation():this.isThisParam(r)&&this.raise(ae.ThisParamAnnotationRequired,r),this.match(29)&&this.isThisParam(r)&&this.raise(ae.ThisParamNoDefault,r),this.resetEndLocation(r),r}parseMaybeDefault(r,n){let i=super.parseMaybeDefault(r,n);return i.type==="AssignmentPattern"&&i.typeAnnotation&&i.right.start<i.typeAnnotation.start&&this.raise(ae.TypeBeforeInitializer,i.typeAnnotation),i}checkImportReflection(r){super.checkImportReflection(r),r.module&&r.importKind!=="value"&&this.raise(ae.ImportReflectionHasImportType,r.specifiers[0].loc.start)}parseImportSpecifierLocal(r,n,i){n.local=RF(r)?this.flowParseRestrictedIdentifier(!0,!0):this.parseIdentifier(),r.specifiers.push(this.finishImportSpecifier(n,i))}isPotentialImportPhase(r){if(super.isPotentialImportPhase(r))return!0;if(this.isContextual(130)){if(!r)return!0;let n=this.lookaheadCharCode();return n===123||n===42}return!r&&this.isContextual(87)}applyImportPhase(r,n,i,s){if(super.applyImportPhase(r,n,i,s),n){if(!i&&this.match(65))return;r.exportKind=i==="type"?i:"value"}else i==="type"&&this.match(55)&&this.unexpected(),r.importKind=i==="type"||i==="typeof"?i:"value"}parseImportSpecifier(r,n,i,s,o){let a=r.imported,c=null;a.type==="Identifier"&&(a.name==="type"?c="type":a.name==="typeof"&&(c="typeof"));let u=!1;if(this.isContextual(93)&&!this.isLookaheadContextual("as")){let p=this.parseIdentifier(!0);c!==null&&!Vn(this.state.type)?(r.imported=p,r.importKind=c,r.local=es(p)):(r.imported=a,r.importKind=null,r.local=this.parseIdentifier())}else{if(c!==null&&Vn(this.state.type))r.imported=this.parseIdentifier(!0),r.importKind=c;else{if(n)throw this.raise(_.ImportBindingIsString,r,{importName:a.value});r.imported=a,r.importKind=null}this.eatContextual(93)?r.local=this.parseIdentifier():(u=!0,r.local=es(r.imported))}let l=RF(r);return i&&l&&this.raise(ae.ImportTypeShorthandOnlyInPureImport,r),(i||l)&&this.checkReservedType(r.local.name,r.local.loc.start,!0),u&&!i&&!l&&this.checkReservedWord(r.local.name,r.loc.start,!0,!0),this.finishImportSpecifier(r,"ImportSpecifier")}parseBindingAtom(){switch(this.state.type){case 78:return this.parseIdentifier(!0);default:return super.parseBindingAtom()}}parseFunctionParams(r,n){let i=r.kind;i!=="get"&&i!=="set"&&this.match(47)&&(r.typeParameters=this.flowParseTypeParameterDeclaration()),super.parseFunctionParams(r,n)}parseVarId(r,n){super.parseVarId(r,n),this.match(14)&&(r.id.typeAnnotation=this.flowParseTypeAnnotation(),this.resetEndLocation(r.id))}parseAsyncArrowFromCallExpression(r,n){if(this.match(14)){let i=this.state.noAnonFunctionType;this.state.noAnonFunctionType=!0,r.returnType=this.flowParseTypeAnnotation(),this.state.noAnonFunctionType=i}return super.parseAsyncArrowFromCallExpression(r,n)}shouldParseAsyncArrow(){return this.match(14)||super.shouldParseAsyncArrow()}parseMaybeAssign(r,n){var i;let s=null,o;if(this.hasPlugin("jsx")&&(this.match(142)||this.match(47))){if(s=this.state.clone(),o=this.tryParse(()=>super.parseMaybeAssign(r,n),s),!o.error)return o.node;let{context:u}=this.state,l=u[u.length-1];(l===Qe.j_oTag||l===Qe.j_expr)&&u.pop()}if((i=o)!=null&&i.error||this.match(47)){var a,c;s=s||this.state.clone();let u,l=this.tryParse(d=>{var h;u=this.flowParseTypeParameterDeclaration();let m=this.forwardNoArrowParamsConversionAt(u,()=>{let y=super.parseMaybeAssign(r,n);return this.resetStartLocationFromNode(y,u),y});(h=m.extra)!=null&&h.parenthesized&&d();let g=this.maybeUnwrapTypeCastExpression(m);return g.type!=="ArrowFunctionExpression"&&d(),g.typeParameters=u,this.resetStartLocationFromNode(g,u),m},s),p=null;if(l.node&&this.maybeUnwrapTypeCastExpression(l.node).type==="ArrowFunctionExpression"){if(!l.error&&!l.aborted)return l.node.async&&this.raise(ae.UnexpectedTypeParameterBeforeAsyncArrowFunction,u),l.node;p=l.node}if((a=o)!=null&&a.node)return this.state=o.failState,o.node;if(p)return this.state=l.failState,p;throw(c=o)!=null&&c.thrown?o.error:l.thrown?l.error:this.raise(ae.UnexpectedTokenAfterTypeParameter,u)}return super.parseMaybeAssign(r,n)}parseArrow(r){if(this.match(14)){let n=this.tryParse(()=>{let i=this.state.noAnonFunctionType;this.state.noAnonFunctionType=!0;let s=this.startNode();return[s.typeAnnotation,r.predicate]=this.flowParseTypeAndPredicateInitialiser(),this.state.noAnonFunctionType=i,this.canInsertSemicolon()&&this.unexpected(),this.match(19)||this.unexpected(),s});if(n.thrown)return null;n.error&&(this.state=n.failState),r.returnType=n.node.typeAnnotation?this.finishNode(n.node,"TypeAnnotation"):null}return super.parseArrow(r)}shouldParseArrow(r){return this.match(14)||super.shouldParseArrow(r)}setArrowFunctionParameters(r,n){this.state.noArrowParamsConversionAt.includes(r.start)?r.params=n:super.setArrowFunctionParameters(r,n)}checkParams(r,n,i,s=!0){if(!(i&&this.state.noArrowParamsConversionAt.includes(r.start))){for(let o=0;o<r.params.length;o++)this.isThisParam(r.params[o])&&o>0&&this.raise(ae.ThisParamMustBeFirst,r.params[o]);super.checkParams(r,n,i,s)}}parseParenAndDistinguishExpression(r){return super.parseParenAndDistinguishExpression(r&&!this.state.noArrowAt.includes(this.state.start))}parseSubscripts(r,n,i){if(r.type==="Identifier"&&r.name==="async"&&this.state.noArrowAt.includes(n.index)){this.next();let s=this.startNodeAt(n);s.callee=r,s.arguments=super.parseCallExpressionArguments(11,!1),r=this.finishNode(s,"CallExpression")}else if(r.type==="Identifier"&&r.name==="async"&&this.match(47)){let s=this.state.clone(),o=this.tryParse(c=>this.parseAsyncArrowWithTypeParameters(n)||c(),s);if(!o.error&&!o.aborted)return o.node;let a=this.tryParse(()=>super.parseSubscripts(r,n,i),s);if(a.node&&!a.error)return a.node;if(o.node)return this.state=o.failState,o.node;if(a.node)return this.state=a.failState,a.node;throw o.error||a.error}return super.parseSubscripts(r,n,i)}parseSubscript(r,n,i,s){if(this.match(18)&&this.isLookaheadToken_lt()){if(s.optionalChainMember=!0,i)return s.stop=!0,r;this.next();let o=this.startNodeAt(n);return o.callee=r,o.typeArguments=this.flowParseTypeParameterInstantiation(),this.expect(10),o.arguments=this.parseCallExpressionArguments(11,!1),o.optional=!0,this.finishCallExpression(o,!0)}else if(!i&&this.shouldParseTypes()&&this.match(47)){let o=this.startNodeAt(n);o.callee=r;let a=this.tryParse(()=>(o.typeArguments=this.flowParseTypeParameterInstantiationCallOrNew(),this.expect(10),o.arguments=super.parseCallExpressionArguments(11,!1),s.optionalChainMember&&(o.optional=!1),this.finishCallExpression(o,s.optionalChainMember)));if(a.node)return a.error&&(this.state=a.failState),a.node}return super.parseSubscript(r,n,i,s)}parseNewCallee(r){super.parseNewCallee(r);let n=null;this.shouldParseTypes()&&this.match(47)&&(n=this.tryParse(()=>this.flowParseTypeParameterInstantiationCallOrNew()).node),r.typeArguments=n}parseAsyncArrowWithTypeParameters(r){let n=this.startNodeAt(r);if(this.parseFunctionParams(n,!1),!!this.parseArrow(n))return super.parseArrowExpression(n,void 0,!0)}readToken_mult_modulo(r){let n=this.input.charCodeAt(this.state.pos+1);if(r===42&&n===47&&this.state.hasFlowComment){this.state.hasFlowComment=!1,this.state.pos+=2,this.nextToken();return}super.readToken_mult_modulo(r)}readToken_pipe_amp(r){let n=this.input.charCodeAt(this.state.pos+1);if(r===124&&n===125){this.finishOp(9,2);return}super.readToken_pipe_amp(r)}parseTopLevel(r,n){let i=super.parseTopLevel(r,n);return this.state.hasFlowComment&&this.raise(ae.UnterminatedFlowComment,this.state.curPosition()),i}skipBlockComment(){if(this.hasPlugin("flowComments")&&this.skipFlowComment()){if(this.state.hasFlowComment)throw this.raise(ae.NestedFlowComment,this.state.startLoc);this.hasFlowCommentCompletion();let r=this.skipFlowComment();r&&(this.state.pos+=r,this.state.hasFlowComment=!0);return}return super.skipBlockComment(this.state.hasFlowComment?"*-/":"*/")}skipFlowComment(){let{pos:r}=this.state,n=2;for(;[32,9].includes(this.input.charCodeAt(r+n));)n++;let i=this.input.charCodeAt(n+r),s=this.input.charCodeAt(n+r+1);return i===58&&s===58?n+2:this.input.slice(n+r,n+r+12)==="flow-include"?n+12:i===58&&s!==58?n:!1}hasFlowCommentCompletion(){if(this.input.indexOf("*/",this.state.pos)===-1)throw this.raise(_.UnterminatedComment,this.state.curPosition())}flowEnumErrorBooleanMemberNotInitialized(r,{enumName:n,memberName:i}){this.raise(ae.EnumBooleanMemberNotInitialized,r,{memberName:i,enumName:n})}flowEnumErrorInvalidMemberInitializer(r,n){return this.raise(n.explicitType?n.explicitType==="symbol"?ae.EnumInvalidMemberInitializerSymbolType:ae.EnumInvalidMemberInitializerPrimaryType:ae.EnumInvalidMemberInitializerUnknownType,r,n)}flowEnumErrorNumberMemberNotInitialized(r,n){this.raise(ae.EnumNumberMemberNotInitialized,r,n)}flowEnumErrorStringMemberInconsistentlyInitialized(r,n){this.raise(ae.EnumStringMemberInconsistentlyInitialized,r,n)}flowEnumMemberInit(){let r=this.state.startLoc,n=()=>this.match(12)||this.match(8);switch(this.state.type){case 134:{let i=this.parseNumericLiteral(this.state.value);return n()?{type:"number",loc:i.loc.start,value:i}:{type:"invalid",loc:r}}case 133:{let i=this.parseStringLiteral(this.state.value);return n()?{type:"string",loc:i.loc.start,value:i}:{type:"invalid",loc:r}}case 85:case 86:{let i=this.parseBooleanLiteral(this.match(85));return n()?{type:"boolean",loc:i.loc.start,value:i}:{type:"invalid",loc:r}}default:return{type:"invalid",loc:r}}}flowEnumMemberRaw(){let r=this.state.startLoc,n=this.parseIdentifier(!0),i=this.eat(29)?this.flowEnumMemberInit():{type:"none",loc:r};return{id:n,init:i}}flowEnumCheckExplicitTypeMismatch(r,n,i){let{explicitType:s}=n;s!==null&&s!==i&&this.flowEnumErrorInvalidMemberInitializer(r,n)}flowEnumMembers({enumName:r,explicitType:n}){let i=new Set,s={booleanMembers:[],numberMembers:[],stringMembers:[],defaultedMembers:[]},o=!1;for(;!this.match(8);){if(this.eat(21)){o=!0;break}let a=this.startNode(),{id:c,init:u}=this.flowEnumMemberRaw(),l=c.name;if(l==="")continue;/^[a-z]/.test(l)&&this.raise(ae.EnumInvalidMemberName,c,{memberName:l,suggestion:l[0].toUpperCase()+l.slice(1),enumName:r}),i.has(l)&&this.raise(ae.EnumDuplicateMemberName,c,{memberName:l,enumName:r}),i.add(l);let p={enumName:r,explicitType:n,memberName:l};switch(a.id=c,u.type){case"boolean":{this.flowEnumCheckExplicitTypeMismatch(u.loc,p,"boolean"),a.init=u.value,s.booleanMembers.push(this.finishNode(a,"EnumBooleanMember"));break}case"number":{this.flowEnumCheckExplicitTypeMismatch(u.loc,p,"number"),a.init=u.value,s.numberMembers.push(this.finishNode(a,"EnumNumberMember"));break}case"string":{this.flowEnumCheckExplicitTypeMismatch(u.loc,p,"string"),a.init=u.value,s.stringMembers.push(this.finishNode(a,"EnumStringMember"));break}case"invalid":throw this.flowEnumErrorInvalidMemberInitializer(u.loc,p);case"none":switch(n){case"boolean":this.flowEnumErrorBooleanMemberNotInitialized(u.loc,p);break;case"number":this.flowEnumErrorNumberMemberNotInitialized(u.loc,p);break;default:s.defaultedMembers.push(this.finishNode(a,"EnumDefaultedMember"))}}this.match(8)||this.expect(12)}return{members:s,hasUnknownMembers:o}}flowEnumStringMembers(r,n,{enumName:i}){if(r.length===0)return n;if(n.length===0)return r;if(n.length>r.length){for(let s of r)this.flowEnumErrorStringMemberInconsistentlyInitialized(s,{enumName:i});return n}else{for(let s of n)this.flowEnumErrorStringMemberInconsistentlyInitialized(s,{enumName:i});return r}}flowEnumParseExplicitType({enumName:r}){if(!this.eatContextual(102))return null;if(!Ue(this.state.type))throw this.raise(ae.EnumInvalidExplicitTypeUnknownSupplied,this.state.startLoc,{enumName:r});let{value:n}=this.state;return this.next(),n!=="boolean"&&n!=="number"&&n!=="string"&&n!=="symbol"&&this.raise(ae.EnumInvalidExplicitType,this.state.startLoc,{enumName:r,invalidEnumType:n}),n}flowEnumBody(r,n){let i=n.name,s=n.loc.start,o=this.flowEnumParseExplicitType({enumName:i});this.expect(5);let{members:a,hasUnknownMembers:c}=this.flowEnumMembers({enumName:i,explicitType:o});switch(r.hasUnknownMembers=c,o){case"boolean":return r.explicitType=!0,r.members=a.booleanMembers,this.expect(8),this.finishNode(r,"EnumBooleanBody");case"number":return r.explicitType=!0,r.members=a.numberMembers,this.expect(8),this.finishNode(r,"EnumNumberBody");case"string":return r.explicitType=!0,r.members=this.flowEnumStringMembers(a.stringMembers,a.defaultedMembers,{enumName:i}),this.expect(8),this.finishNode(r,"EnumStringBody");case"symbol":return r.members=a.defaultedMembers,this.expect(8),this.finishNode(r,"EnumSymbolBody");default:{let u=()=>(r.members=[],this.expect(8),this.finishNode(r,"EnumStringBody"));r.explicitType=!1;let l=a.booleanMembers.length,p=a.numberMembers.length,d=a.stringMembers.length,h=a.defaultedMembers.length;if(!l&&!p&&!d&&!h)return u();if(!l&&!p)return r.members=this.flowEnumStringMembers(a.stringMembers,a.defaultedMembers,{enumName:i}),this.expect(8),this.finishNode(r,"EnumStringBody");if(!p&&!d&&l>=h){for(let m of a.defaultedMembers)this.flowEnumErrorBooleanMemberNotInitialized(m.loc.start,{enumName:i,memberName:m.id.name});return r.members=a.booleanMembers,this.expect(8),this.finishNode(r,"EnumBooleanBody")}else if(!l&&!d&&p>=h){for(let m of a.defaultedMembers)this.flowEnumErrorNumberMemberNotInitialized(m.loc.start,{enumName:i,memberName:m.id.name});return r.members=a.numberMembers,this.expect(8),this.finishNode(r,"EnumNumberBody")}else return this.raise(ae.EnumInconsistentMemberValues,s,{enumName:i}),u()}}}flowParseEnumDeclaration(r){let n=this.parseIdentifier();return r.id=n,r.body=this.flowEnumBody(this.startNode(),n),this.finishNode(r,"EnumDeclaration")}isLookaheadToken_lt(){let r=this.nextTokenStart();if(this.input.charCodeAt(r)===60){let n=this.input.charCodeAt(r+1);return n!==60&&n!==61}return!1}maybeUnwrapTypeCastExpression(r){return r.type==="TypeCastExpression"?r.expression:r}},AW={__proto__:null,quot:'"',amp:"&",apos:"'",lt:"<",gt:">",nbsp:"\xA0",iexcl:"\xA1",cent:"\xA2",pound:"\xA3",curren:"\xA4",yen:"\xA5",brvbar:"\xA6",sect:"\xA7",uml:"\xA8",copy:"\xA9",ordf:"\xAA",laquo:"\xAB",not:"\xAC",shy:"\xAD",reg:"\xAE",macr:"\xAF",deg:"\xB0",plusmn:"\xB1",sup2:"\xB2",sup3:"\xB3",acute:"\xB4",micro:"\xB5",para:"\xB6",middot:"\xB7",cedil:"\xB8",sup1:"\xB9",ordm:"\xBA",raquo:"\xBB",frac14:"\xBC",frac12:"\xBD",frac34:"\xBE",iquest:"\xBF",Agrave:"\xC0",Aacute:"\xC1",Acirc:"\xC2",Atilde:"\xC3",Auml:"\xC4",Aring:"\xC5",AElig:"\xC6",Ccedil:"\xC7",Egrave:"\xC8",Eacute:"\xC9",Ecirc:"\xCA",Euml:"\xCB",Igrave:"\xCC",Iacute:"\xCD",Icirc:"\xCE",Iuml:"\xCF",ETH:"\xD0",Ntilde:"\xD1",Ograve:"\xD2",Oacute:"\xD3",Ocirc:"\xD4",Otilde:"\xD5",Ouml:"\xD6",times:"\xD7",Oslash:"\xD8",Ugrave:"\xD9",Uacute:"\xDA",Ucirc:"\xDB",Uuml:"\xDC",Yacute:"\xDD",THORN:"\xDE",szlig:"\xDF",agrave:"\xE0",aacute:"\xE1",acirc:"\xE2",atilde:"\xE3",auml:"\xE4",aring:"\xE5",aelig:"\xE6",ccedil:"\xE7",egrave:"\xE8",eacute:"\xE9",ecirc:"\xEA",euml:"\xEB",igrave:"\xEC",iacute:"\xED",icirc:"\xEE",iuml:"\xEF",eth:"\xF0",ntilde:"\xF1",ograve:"\xF2",oacute:"\xF3",ocirc:"\xF4",otilde:"\xF5",ouml:"\xF6",divide:"\xF7",oslash:"\xF8",ugrave:"\xF9",uacute:"\xFA",ucirc:"\xFB",uuml:"\xFC",yacute:"\xFD",thorn:"\xFE",yuml:"\xFF",OElig:"\u0152",oelig:"\u0153",Scaron:"\u0160",scaron:"\u0161",Yuml:"\u0178",fnof:"\u0192",circ:"\u02C6",tilde:"\u02DC",Alpha:"\u0391",Beta:"\u0392",Gamma:"\u0393",Delta:"\u0394",Epsilon:"\u0395",Zeta:"\u0396",Eta:"\u0397",Theta:"\u0398",Iota:"\u0399",Kappa:"\u039A",Lambda:"\u039B",Mu:"\u039C",Nu:"\u039D",Xi:"\u039E",Omicron:"\u039F",Pi:"\u03A0",Rho:"\u03A1",Sigma:"\u03A3",Tau:"\u03A4",Upsilon:"\u03A5",Phi:"\u03A6",Chi:"\u03A7",Psi:"\u03A8",Omega:"\u03A9",alpha:"\u03B1",beta:"\u03B2",gamma:"\u03B3",delta:"\u03B4",epsilon:"\u03B5",zeta:"\u03B6",eta:"\u03B7",theta:"\u03B8",iota:"\u03B9",kappa:"\u03BA",lambda:"\u03BB",mu:"\u03BC",nu:"\u03BD",xi:"\u03BE",omicron:"\u03BF",pi:"\u03C0",rho:"\u03C1",sigmaf:"\u03C2",sigma:"\u03C3",tau:"\u03C4",upsilon:"\u03C5",phi:"\u03C6",chi:"\u03C7",psi:"\u03C8",omega:"\u03C9",thetasym:"\u03D1",upsih:"\u03D2",piv:"\u03D6",ensp:"\u2002",emsp:"\u2003",thinsp:"\u2009",zwnj:"\u200C",zwj:"\u200D",lrm:"\u200E",rlm:"\u200F",ndash:"\u2013",mdash:"\u2014",lsquo:"\u2018",rsquo:"\u2019",sbquo:"\u201A",ldquo:"\u201C",rdquo:"\u201D",bdquo:"\u201E",dagger:"\u2020",Dagger:"\u2021",bull:"\u2022",hellip:"\u2026",permil:"\u2030",prime:"\u2032",Prime:"\u2033",lsaquo:"\u2039",rsaquo:"\u203A",oline:"\u203E",frasl:"\u2044",euro:"\u20AC",image:"\u2111",weierp:"\u2118",real:"\u211C",trade:"\u2122",alefsym:"\u2135",larr:"\u2190",uarr:"\u2191",rarr:"\u2192",darr:"\u2193",harr:"\u2194",crarr:"\u21B5",lArr:"\u21D0",uArr:"\u21D1",rArr:"\u21D2",dArr:"\u21D3",hArr:"\u21D4",forall:"\u2200",part:"\u2202",exist:"\u2203",empty:"\u2205",nabla:"\u2207",isin:"\u2208",notin:"\u2209",ni:"\u220B",prod:"\u220F",sum:"\u2211",minus:"\u2212",lowast:"\u2217",radic:"\u221A",prop:"\u221D",infin:"\u221E",ang:"\u2220",and:"\u2227",or:"\u2228",cap:"\u2229",cup:"\u222A",int:"\u222B",there4:"\u2234",sim:"\u223C",cong:"\u2245",asymp:"\u2248",ne:"\u2260",equiv:"\u2261",le:"\u2264",ge:"\u2265",sub:"\u2282",sup:"\u2283",nsub:"\u2284",sube:"\u2286",supe:"\u2287",oplus:"\u2295",otimes:"\u2297",perp:"\u22A5",sdot:"\u22C5",lceil:"\u2308",rceil:"\u2309",lfloor:"\u230A",rfloor:"\u230B",lang:"\u2329",rang:"\u232A",loz:"\u25CA",spades:"\u2660",clubs:"\u2663",hearts:"\u2665",diams:"\u2666"},_o=Zi`jsx`({AttributeIsEmpty:"JSX attributes must only be assigned a non-empty expression.",MissingClosingTagElement:({openingTagName:e})=>`Expected corresponding JSX closing tag for <${e}>.`,MissingClosingTagFragment:"Expected corresponding JSX closing tag for <>.",UnexpectedSequenceExpression:"Sequence expressions cannot be directly nested inside JSX. Did you mean to wrap it in parentheses (...)?",UnexpectedToken:({unexpected:e,HTMLEntity:t})=>`Unexpected token \`${e}\`. Did you mean \`${t}\` or \`{'${e}'}\`?`,UnsupportedJsxValue:"JSX value should be either an expression or a quoted JSX text.",UnterminatedJsxContent:"Unterminated JSX contents.",UnwrappedAdjacentJSXElements:"Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...</>?"});function Rs(e){return e?e.type==="JSXOpeningFragment"||e.type==="JSXClosingFragment":!1}function Ha(e){if(e.type==="JSXIdentifier")return e.name;if(e.type==="JSXNamespacedName")return e.namespace.name+":"+e.name.name;if(e.type==="JSXMemberExpression")return Ha(e.object)+"."+Ha(e.property);throw new Error("Node had unexpected type: "+e.type)}var PW=e=>class extends e{jsxReadToken(){let r="",n=this.state.pos;for(;;){if(this.state.pos>=this.length)throw this.raise(_o.UnterminatedJsxContent,this.state.startLoc);let i=this.input.charCodeAt(this.state.pos);switch(i){case 60:case 123:if(this.state.pos===this.state.start){i===60&&this.state.canStartJSXElement?(++this.state.pos,this.finishToken(142)):super.getTokenFromCode(i);return}r+=this.input.slice(n,this.state.pos),this.finishToken(141,r);return;case 38:r+=this.input.slice(n,this.state.pos),r+=this.jsxReadEntity(),n=this.state.pos;break;case 62:case 125:default:Va(i)?(r+=this.input.slice(n,this.state.pos),r+=this.jsxReadNewLine(!0),n=this.state.pos):++this.state.pos}}}jsxReadNewLine(r){let n=this.input.charCodeAt(this.state.pos),i;return++this.state.pos,n===13&&this.input.charCodeAt(this.state.pos)===10?(++this.state.pos,i=r?`
20
20
  `:`\r
@@ -98,7 +98,7 @@ Please see the 3.x to 4.x migration guide for details on how to update your app.
98
98
  `)+`\r
99
99
  \r
100
100
  `+r)}function ma(e,t,r,n,i){if(e.listenerCount("wsClientError")){let s=new Error(i);Error.captureStackTrace(s,ma),e.emit("wsClientError",s,r,t)}else Zp(r,n,i)}});var W7=w((XUe,V7)=>{f();var Vw=class{constructor(t,r,n){this.etaBufferLength=t||100,this.valueBuffer=[n],this.timeBuffer=[r],this.eta="0"}update(t,r,n){this.valueBuffer.push(r),this.timeBuffer.push(t),this.calculate(n-r)}getTime(){return this.eta}calculate(t){let r=this.valueBuffer.length,n=Math.min(this.etaBufferLength,r),i=this.valueBuffer[r-1]-this.valueBuffer[r-n],s=this.timeBuffer[r-1]-this.timeBuffer[r-n],o=i/s;this.valueBuffer=this.valueBuffer.slice(-this.etaBufferLength),this.timeBuffer=this.timeBuffer.slice(-this.etaBufferLength);let a=Math.ceil(t/o/1e3);isNaN(a)?this.eta="NULL":isFinite(a)?a>1e7?this.eta="INF":a<0?this.eta=0:this.eta=a:this.eta="INF"}};V7.exports=Vw});var Yw=w((ZUe,Y7)=>{f();var ha=require("readline"),Ww=class{constructor(t){this.stream=t,this.linewrap=!0,this.dy=0}cursorSave(){this.stream.isTTY&&this.stream.write("\x1B7")}cursorRestore(){this.stream.isTTY&&this.stream.write("\x1B8")}cursor(t){this.stream.isTTY&&(t?this.stream.write("\x1B[?25h"):this.stream.write("\x1B[?25l"))}cursorTo(t=null,r=null){this.stream.isTTY&&ha.cursorTo(this.stream,t,r)}cursorRelative(t=null,r=null){this.stream.isTTY&&(this.dy=this.dy+r,ha.moveCursor(this.stream,t,r))}cursorRelativeReset(){this.stream.isTTY&&(ha.moveCursor(this.stream,0,-this.dy),ha.cursorTo(this.stream,0,null),this.dy=0)}clearRight(){this.stream.isTTY&&ha.clearLine(this.stream,1)}clearLine(){this.stream.isTTY&&ha.clearLine(this.stream,0)}clearBottom(){this.stream.isTTY&&ha.clearScreenDown(this.stream)}newline(){this.stream.write(`
101
- `),this.dy++}write(t,r=!1){this.linewrap===!0&&r===!1?this.stream.write(t.substr(0,this.getWidth())):this.stream.write(t)}lineWrapping(t){this.stream.isTTY&&(this.linewrap=t,t?this.stream.write("\x1B[?7h"):this.stream.write("\x1B[?7l"))}isTTY(){return this.stream.isTTY===!0}getWidth(){return this.stream.columns||(this.stream.isTTY?80:200)}};Y7.exports=Ww});var X7=w((tje,J7)=>{"use strict";f();J7.exports=({onlyFirst:e=!1}={})=>{let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,e?void 0:"g")}});var Z7=w((nje,Q7)=>{"use strict";f();var Sbe=X7();Q7.exports=e=>typeof e=="string"?e.replace(Sbe(),""):e});var tU=w((sje,Jw)=>{"use strict";f();var eU=e=>Number.isNaN(e)?!1:e>=4352&&(e<=4447||e===9001||e===9002||11904<=e&&e<=12871&&e!==12351||12880<=e&&e<=19903||19968<=e&&e<=42182||43360<=e&&e<=43388||44032<=e&&e<=55203||63744<=e&&e<=64255||65040<=e&&e<=65049||65072<=e&&e<=65131||65281<=e&&e<=65376||65504<=e&&e<=65510||110592<=e&&e<=110593||127488<=e&&e<=127569||131072<=e&&e<=262141);Jw.exports=eU;Jw.exports.default=eU});var nU=w((aje,rU)=>{"use strict";f();rU.exports=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF4\uD83C\uDDF2|\uD83C\uDDF6\uD83C\uDDE6|[#\*0-9]\uFE0F\u20E3|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83D\uDC69(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270A-\u270D]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC70\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDCAA\uDD74\uDD7A\uDD90\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD36\uDDB5\uDDB6\uDDBB\uDDD2-\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5\uDEEB\uDEEC\uDEF4-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g}});var sU=w((uje,Xw)=>{"use strict";f();var Tbe=Z7(),Abe=tU(),Pbe=nU(),iU=e=>{if(typeof e!="string"||e.length===0||(e=Tbe(e),e.length===0))return 0;e=e.replace(Pbe()," ");let t=0;for(let r=0;r<e.length;r++){let n=e.codePointAt(r);n<=31||n>=127&&n<=159||n>=768&&n<=879||(n>65535&&r++,t+=Abe(n)?2:1)}return t};Xw.exports=iU;Xw.exports.default=iU});var Qw=w((pje,oU)=>{f();oU.exports=function(t,r,n){if(r.autopadding!==!0)return t;function i(s,o){return(r.autopaddingChar+s).slice(-o)}switch(n){case"percentage":return i(t,3);default:return t}}});var Zw=w((fje,aU)=>{f();aU.exports=function(t,r){let n=Math.round(t*r.barsize),i=r.barsize-n;return r.barCompleteString.substr(0,n)+r.barGlue+r.barIncompleteString.substr(0,i)}});var eS=w((hje,cU)=>{f();cU.exports=function(t,r,n){function i(o){return n?n*Math.round(o/n):o}function s(o){return(r.autopaddingChar+o).slice(-2)}return t>3600?s(Math.floor(t/3600))+"h"+s(i(t%3600/60))+"m":t>60?s(Math.floor(t/60))+"m"+s(i(t%60))+"s":t>10?s(i(t))+"s":s(t)+"s"}});var tS=w((yje,uU)=>{f();var Fbe=sU(),_be=Qw(),Ibe=Zw(),kbe=eS();uU.exports=function(t,r,n){let i=t.format,s=t.formatTime||kbe,o=t.formatValue||_be,a=t.formatBar||Ibe,c=Math.floor(r.progress*100)+"",u=r.stopTime||Date.now(),l=Math.round((u-r.startTime)/1e3),p=Object.assign({},n,{bar:a(r.progress,t),percentage:o(c,t,"percentage"),total:o(r.total,t,"total"),value:o(r.value,t,"value"),eta:o(r.eta,t,"eta"),eta_formatted:s(r.eta,t,5),duration:o(l,t,"duration"),duration_formatted:s(l,t,1)});i=i.replace(/\{(\w+)\}/g,function(m,g){return typeof p[g]<"u"?p[g]:m});let d=Math.max(0,r.maxWidth-Fbe(i)-2),h=Math.floor(d/2);switch(t.align){case"right":i=d>0?" ".repeat(d)+i:i;break;case"center":i=h>0?" ".repeat(h)+i:i;break;case"left":default:break}return i}});var Tg=w((xje,lU)=>{f();function ot(e,t){return typeof e>"u"||e===null?t:e}lU.exports={parse:function(t,r){let n={},i=Object.assign({},r,t);return n.throttleTime=1e3/ot(i.fps,10),n.stream=ot(i.stream,process.stderr),n.terminal=ot(i.terminal,null),n.clearOnComplete=ot(i.clearOnComplete,!1),n.stopOnComplete=ot(i.stopOnComplete,!1),n.barsize=ot(i.barsize,40),n.align=ot(i.align,"left"),n.hideCursor=ot(i.hideCursor,!1),n.linewrap=ot(i.linewrap,!1),n.barGlue=ot(i.barGlue,""),n.barCompleteChar=ot(i.barCompleteChar,"="),n.barIncompleteChar=ot(i.barIncompleteChar,"-"),n.format=ot(i.format,"progress [{bar}] {percentage}% | ETA: {eta}s | {value}/{total}"),n.formatTime=ot(i.formatTime,null),n.formatValue=ot(i.formatValue,null),n.formatBar=ot(i.formatBar,null),n.etaBufferLength=ot(i.etaBuffer,10),n.etaAsynchronousUpdate=ot(i.etaAsynchronousUpdate,!1),n.progressCalculationRelative=ot(i.progressCalculationRelative,!1),n.synchronousUpdate=ot(i.synchronousUpdate,!0),n.noTTYOutput=ot(i.noTTYOutput,!1),n.notTTYSchedule=ot(i.notTTYSchedule,2e3),n.emptyOnZero=ot(i.emptyOnZero,!1),n.forceRedraw=ot(i.forceRedraw,!1),n.autopadding=ot(i.autopadding,!1),n.gracefulExit=ot(i.gracefulExit,!1),n},assignDerivedOptions:function(t){return t.barCompleteString=t.barCompleteChar.repeat(t.barsize+1),t.barIncompleteString=t.barIncompleteChar.repeat(t.barsize+1),t.autopaddingChar=t.autopadding?ot(t.autopaddingChar," "):"",t}}});var rS=w((Cje,dU)=>{f();var pU=W7(),Nbe=Yw(),Rbe=tS(),Obe=Tg(),Bbe=require("events");dU.exports=class extends Bbe{constructor(t){super(),this.options=Obe.assignDerivedOptions(t),this.terminal=this.options.terminal?this.options.terminal:new Nbe(this.options.stream),this.value=0,this.startValue=0,this.total=100,this.lastDrawnString=null,this.startTime=null,this.stopTime=null,this.lastRedraw=Date.now(),this.eta=new pU(this.options.etaBufferLength,0,0),this.payload={},this.isActive=!1,this.formatter=typeof this.options.format=="function"?this.options.format:Rbe}render(t=!1){let r={progress:this.getProgress(),eta:this.eta.getTime(),startTime:this.startTime,stopTime:this.stopTime,total:this.total,value:this.value,maxWidth:this.terminal.getWidth()};this.options.etaAsynchronousUpdate&&this.updateETA();let n=this.formatter(this.options,r,this.payload);(t||this.options.forceRedraw||this.options.noTTYOutput&&!this.terminal.isTTY()||this.lastDrawnString!=n)&&(this.emit("redraw-pre"),this.terminal.cursorTo(0,null),this.terminal.write(n),this.terminal.clearRight(),this.lastDrawnString=n,this.lastRedraw=Date.now(),this.emit("redraw-post"))}start(t,r,n){this.value=r||0,this.total=typeof t<"u"&&t>=0?t:100,this.startValue=r||0,this.payload=n||{},this.startTime=Date.now(),this.stopTime=null,this.lastDrawnString="",this.eta=new pU(this.options.etaBufferLength,this.startTime,this.value),this.isActive=!0,this.emit("start",t,r)}stop(){this.isActive=!1,this.stopTime=Date.now(),this.emit("stop",this.total,this.value)}update(t,r={}){typeof t=="number"&&(this.value=t,this.eta.update(Date.now(),t,this.total));let n=(typeof t=="object"?t:r)||{};this.emit("update",this.total,this.value);for(let i in n)this.payload[i]=n[i];this.value>=this.getTotal()&&this.options.stopOnComplete&&this.stop()}getProgress(){let t=this.value/this.total;return this.options.progressCalculationRelative&&(t=(this.value-this.startValue)/(this.total-this.startValue)),isNaN(t)&&(t=this.options&&this.options.emptyOnZero?0:1),t=Math.min(Math.max(t,0),1),t}increment(t=1,r={}){typeof t=="object"?this.update(this.value+1,t):this.update(this.value+t,r)}getTotal(){return this.total}setTotal(t){typeof t<"u"&&t>=0&&(this.total=t)}updateETA(){this.eta.update(Date.now(),this.value,this.total)}}});var mU=w((Sje,fU)=>{f();var Mbe=rS(),Lbe=Tg();fU.exports=class extends Mbe{constructor(t,r){super(Lbe.parse(t,r)),this.timer=null,this.options.noTTYOutput&&this.terminal.isTTY()===!1&&(this.options.synchronousUpdate=!1),this.schedulingRate=this.terminal.isTTY()?this.options.throttleTime:this.options.notTTYSchedule,this.sigintCallback=null}render(){this.timer&&(clearTimeout(this.timer),this.timer=null),super.render(),this.options.noTTYOutput&&this.terminal.isTTY()===!1&&this.terminal.newline(),this.timer=setTimeout(this.render.bind(this),this.schedulingRate)}update(t,r){this.timer&&(super.update(t,r),this.options.synchronousUpdate&&this.lastRedraw+this.options.throttleTime*2<Date.now()&&this.render())}start(t,r,n){this.options.noTTYOutput===!1&&this.terminal.isTTY()===!1||(this.sigintCallback===null&&this.options.gracefulExit&&(this.sigintCallback=this.stop.bind(this),process.once("SIGINT",this.sigintCallback),process.once("SIGTERM",this.sigintCallback)),this.terminal.cursorSave(),this.options.hideCursor===!0&&this.terminal.cursor(!1),this.options.linewrap===!1&&this.terminal.lineWrapping(!1),super.start(t,r,n),this.render())}stop(){this.timer&&(this.sigintCallback&&(process.removeListener("SIGINT",this.sigintCallback),process.removeListener("SIGTERM",this.sigintCallback),this.sigintCallback=null),this.render(),super.stop(),clearTimeout(this.timer),this.timer=null,this.options.hideCursor===!0&&this.terminal.cursor(!0),this.options.linewrap===!1&&this.terminal.lineWrapping(!0),this.terminal.cursorRestore(),this.options.clearOnComplete?(this.terminal.cursorTo(0,null),this.terminal.clearLine()):this.terminal.newline())}}});var gU=w((Pje,hU)=>{f();var $be=Yw(),Ube=rS(),jbe=Tg(),qbe=require("events");hU.exports=class extends qbe{constructor(t,r){super(),this.bars=[],this.options=jbe.parse(t,r),this.options.synchronousUpdate=!1,this.terminal=this.options.terminal?this.options.terminal:new $be(this.options.stream),this.timer=null,this.isActive=!1,this.schedulingRate=this.terminal.isTTY()?this.options.throttleTime:this.options.notTTYSchedule,this.loggingBuffer=[],this.sigintCallback=null}create(t,r,n,i={}){let s=new Ube(Object.assign({},this.options,{terminal:this.terminal},i));return this.bars.push(s),this.options.noTTYOutput===!1&&this.terminal.isTTY()===!1||(this.sigintCallback===null&&this.options.gracefulExit&&(this.sigintCallback=this.stop.bind(this),process.once("SIGINT",this.sigintCallback),process.once("SIGTERM",this.sigintCallback)),this.isActive||(this.options.hideCursor===!0&&this.terminal.cursor(!1),this.options.linewrap===!1&&this.terminal.lineWrapping(!1),this.timer=setTimeout(this.update.bind(this),this.schedulingRate)),this.isActive=!0,s.start(t,r,n),this.emit("start")),s}remove(t){let r=this.bars.indexOf(t);return r<0?!1:(this.bars.splice(r,1),this.update(),this.terminal.newline(),this.terminal.clearBottom(),!0)}update(){if(this.timer&&(clearTimeout(this.timer),this.timer=null),this.emit("update-pre"),this.terminal.cursorRelativeReset(),this.emit("redraw-pre"),this.loggingBuffer.length>0)for(this.terminal.clearLine();this.loggingBuffer.length>0;)this.terminal.write(this.loggingBuffer.shift(),!0);for(let t=0;t<this.bars.length;t++)t>0&&this.terminal.newline(),this.bars[t].render();this.emit("redraw-post"),this.options.noTTYOutput&&this.terminal.isTTY()===!1&&(this.terminal.newline(),this.terminal.newline()),this.timer=setTimeout(this.update.bind(this),this.schedulingRate),this.emit("update-post"),this.options.stopOnComplete&&!this.bars.find(t=>t.isActive)&&this.stop()}stop(){if(clearTimeout(this.timer),this.timer=null,this.sigintCallback&&(process.removeListener("SIGINT",this.sigintCallback),process.removeListener("SIGTERM",this.sigintCallback),this.sigintCallback=null),this.isActive=!1,this.options.hideCursor===!0&&this.terminal.cursor(!0),this.options.linewrap===!1&&this.terminal.lineWrapping(!0),this.terminal.cursorRelativeReset(),this.emit("stop-pre-clear"),this.options.clearOnComplete)this.terminal.clearBottom();else{for(let t=0;t<this.bars.length;t++)t>0&&this.terminal.newline(),this.bars[t].render(),this.bars[t].stop();this.terminal.newline()}this.emit("stop")}log(t){this.loggingBuffer.push(t)}}});var bU=w((_je,yU)=>{f();yU.exports={format:"progress [{bar}] {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"=",barIncompleteChar:"-"}});var vU=w((kje,xU)=>{f();xU.exports={format:" {bar} {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"\u2588",barIncompleteChar:"\u2591"}});var CU=w((Rje,DU)=>{f();DU.exports={format:" \x1B[90m{bar}\x1B[0m {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"\u2588",barIncompleteChar:"\u2591"}});var wU=w((Bje,EU)=>{f();EU.exports={format:" {bar}\u25A0 {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"\u25A0",barIncompleteChar:" "}});var TU=w((Lje,SU)=>{f();var Gbe=bU(),zbe=vU(),Hbe=CU(),Kbe=wU();SU.exports={legacy:Gbe,shades_classic:zbe,shades_grey:Hbe,rect:Kbe}});var FU=w((Uje,PU)=>{f();var AU=mU(),Vbe=gU(),Wbe=TU(),Ybe=tS(),Jbe=Qw(),Xbe=Zw(),Qbe=eS();PU.exports={Bar:AU,SingleBar:AU,MultiBar:Vbe,Presets:Wbe,Format:{Formatter:Ybe,BarFormat:Xbe,ValueFormat:Jbe,TimeFormat:Qbe}}});var OU=w((Zje,RU)=>{f();RU.exports=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE])))?))?|\uDC6F(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE89\uDE8F-\uDEC2\uDEC6\uDECE-\uDEDC\uDEDF-\uDEE9]|\uDD3C(?:\u200D[\u2640\u2642]\uFE0F?|\uD83C[\uDFFB-\uDFFF])?|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g});var Dxe={};pS(Dxe,{default:()=>vxe});module.exports=yj(Dxe);f();f();try{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="ca491b7a-198e-4d39-be08-7ac1084ca22a",e._sentryDebugIdIdentifier="sentry-dbid-ca491b7a-198e-4d39-be08-7ac1084ca22a")}catch{}f();var ij=require("../core/index.cjs"),sj=require("../node/index.cjs"),oj=require("../server/index.cjs"),aj=q(mS(),1);f();f();var th=require("fs/promises");f();var $g=q(require("prettier"),1),hS=require("module"),gS=q(require("path"),1);function xj(e){if(!e)return $g.default;try{let r=(0,hS.createRequire)(e)("prettier");if(!r)throw new Error("Prettier not found");return r}catch{return $g.default}}async function Zr(e,t,r,n){try{let i=gS.default.resolve(e,n??"file.tsx"),s=xj(i),o=await s.resolveConfig(i);return o?await s.format(t,{...o,filepath:n,parser:r}):await s.format(t,{filepath:n,parser:r})}catch{return t}}f();var o3=require("http");f();var Ug="preview-url";var ba="framework",od="platform",ad="node",yS="/~builder-connect",ho="/~builder-connected",jg="/~builder-dev-tools",qg="/~builder-dev-tools.js",go="/~builder-dev-tools-close",bS="/mappings";var a3=require("os"),fn=require("path"),kr=require("fs");f();var yd=require("util");f();var pr=q(cd(),1),va=require("process"),Ds=q(require("readline"),1),Wg=q(require("readline"),1),_S=require("stream"),IS=q(vt(),1);function Tj({onlyFirst:e=!1}={}){let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?(?:\\u0007|\\u001B\\u005C|\\u009C))","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");return new RegExp(t,e?void 0:"g")}var Aj=Tj();function kS(e){if(typeof e!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof e}\``);return e.replace(Aj,"")}function NS(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var RS={exports:{}};(function(e){var t={};e.exports=t,t.eastAsianWidth=function(n){var i=n.charCodeAt(0),s=n.length==2?n.charCodeAt(1):0,o=i;return 55296<=i&&i<=56319&&56320<=s&&s<=57343&&(i&=1023,s&=1023,o=i<<10|s,o+=65536),o==12288||65281<=o&&o<=65376||65504<=o&&o<=65510?"F":o==8361||65377<=o&&o<=65470||65474<=o&&o<=65479||65482<=o&&o<=65487||65490<=o&&o<=65495||65498<=o&&o<=65500||65512<=o&&o<=65518?"H":4352<=o&&o<=4447||4515<=o&&o<=4519||4602<=o&&o<=4607||9001<=o&&o<=9002||11904<=o&&o<=11929||11931<=o&&o<=12019||12032<=o&&o<=12245||12272<=o&&o<=12283||12289<=o&&o<=12350||12353<=o&&o<=12438||12441<=o&&o<=12543||12549<=o&&o<=12589||12593<=o&&o<=12686||12688<=o&&o<=12730||12736<=o&&o<=12771||12784<=o&&o<=12830||12832<=o&&o<=12871||12880<=o&&o<=13054||13056<=o&&o<=19903||19968<=o&&o<=42124||42128<=o&&o<=42182||43360<=o&&o<=43388||44032<=o&&o<=55203||55216<=o&&o<=55238||55243<=o&&o<=55291||63744<=o&&o<=64255||65040<=o&&o<=65049||65072<=o&&o<=65106||65108<=o&&o<=65126||65128<=o&&o<=65131||110592<=o&&o<=110593||127488<=o&&o<=127490||127504<=o&&o<=127546||127552<=o&&o<=127560||127568<=o&&o<=127569||131072<=o&&o<=194367||177984<=o&&o<=196605||196608<=o&&o<=262141?"W":32<=o&&o<=126||162<=o&&o<=163||165<=o&&o<=166||o==172||o==175||10214<=o&&o<=10221||10629<=o&&o<=10630?"Na":o==161||o==164||167<=o&&o<=168||o==170||173<=o&&o<=174||176<=o&&o<=180||182<=o&&o<=186||188<=o&&o<=191||o==198||o==208||215<=o&&o<=216||222<=o&&o<=225||o==230||232<=o&&o<=234||236<=o&&o<=237||o==240||242<=o&&o<=243||247<=o&&o<=250||o==252||o==254||o==257||o==273||o==275||o==283||294<=o&&o<=295||o==299||305<=o&&o<=307||o==312||319<=o&&o<=322||o==324||328<=o&&o<=331||o==333||338<=o&&o<=339||358<=o&&o<=359||o==363||o==462||o==464||o==466||o==468||o==470||o==472||o==474||o==476||o==593||o==609||o==708||o==711||713<=o&&o<=715||o==717||o==720||728<=o&&o<=731||o==733||o==735||768<=o&&o<=879||913<=o&&o<=929||931<=o&&o<=937||945<=o&&o<=961||963<=o&&o<=969||o==1025||1040<=o&&o<=1103||o==1105||o==8208||8211<=o&&o<=8214||8216<=o&&o<=8217||8220<=o&&o<=8221||8224<=o&&o<=8226||8228<=o&&o<=8231||o==8240||8242<=o&&o<=8243||o==8245||o==8251||o==8254||o==8308||o==8319||8321<=o&&o<=8324||o==8364||o==8451||o==8453||o==8457||o==8467||o==8470||8481<=o&&o<=8482||o==8486||o==8491||8531<=o&&o<=8532||8539<=o&&o<=8542||8544<=o&&o<=8555||8560<=o&&o<=8569||o==8585||8592<=o&&o<=8601||8632<=o&&o<=8633||o==8658||o==8660||o==8679||o==8704||8706<=o&&o<=8707||8711<=o&&o<=8712||o==8715||o==8719||o==8721||o==8725||o==8730||8733<=o&&o<=8736||o==8739||o==8741||8743<=o&&o<=8748||o==8750||8756<=o&&o<=8759||8764<=o&&o<=8765||o==8776||o==8780||o==8786||8800<=o&&o<=8801||8804<=o&&o<=8807||8810<=o&&o<=8811||8814<=o&&o<=8815||8834<=o&&o<=8835||8838<=o&&o<=8839||o==8853||o==8857||o==8869||o==8895||o==8978||9312<=o&&o<=9449||9451<=o&&o<=9547||9552<=o&&o<=9587||9600<=o&&o<=9615||9618<=o&&o<=9621||9632<=o&&o<=9633||9635<=o&&o<=9641||9650<=o&&o<=9651||9654<=o&&o<=9655||9660<=o&&o<=9661||9664<=o&&o<=9665||9670<=o&&o<=9672||o==9675||9678<=o&&o<=9681||9698<=o&&o<=9701||o==9711||9733<=o&&o<=9734||o==9737||9742<=o&&o<=9743||9748<=o&&o<=9749||o==9756||o==9758||o==9792||o==9794||9824<=o&&o<=9825||9827<=o&&o<=9829||9831<=o&&o<=9834||9836<=o&&o<=9837||o==9839||9886<=o&&o<=9887||9918<=o&&o<=9919||9924<=o&&o<=9933||9935<=o&&o<=9953||o==9955||9960<=o&&o<=9983||o==10045||o==10071||10102<=o&&o<=10111||11093<=o&&o<=11097||12872<=o&&o<=12879||57344<=o&&o<=63743||65024<=o&&o<=65039||o==65533||127232<=o&&o<=127242||127248<=o&&o<=127277||127280<=o&&o<=127337||127344<=o&&o<=127386||917760<=o&&o<=917999||983040<=o&&o<=1048573||1048576<=o&&o<=1114109?"A":"N"},t.characterLength=function(n){var i=this.eastAsianWidth(n);return i=="F"||i=="W"||i=="A"?2:1};function r(n){return n.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g)||[]}t.length=function(n){for(var i=r(n),s=0,o=0;o<i.length;o++)s=s+this.characterLength(i[o]);return s},t.slice=function(n,i,s){textLen=t.length(n),i=i||0,s=s||1,i<0&&(i=textLen+i),s<0&&(s=textLen+s);for(var o="",a=0,c=r(n),u=0;u<c.length;u++){var l=c[u],p=t.length(l);if(a>=i-(p==2?1:0))if(a+p<=s)o+=l;else break;a+=p}return o}})(RS);var Pj=RS.exports,Fj=NS(Pj),_j=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67)\uDB40\uDC7F|(?:\uD83E\uDDD1\uD83C\uDFFF\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFC-\uDFFF])|\uD83D\uDC68(?:\uD83C\uDFFB(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|[\u2695\u2696\u2708]\uFE0F|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))?|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])\uFE0F|\u200D(?:(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D[\uDC66\uDC67])|\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC)?|(?:\uD83D\uDC69(?:\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69]))|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC69(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDE36\u200D\uD83C\uDF2B|\uD83C\uDFF3\uFE0F\u200D\u26A7|\uD83D\uDC3B\u200D\u2744|(?:(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\uD83C\uDFF4\u200D\u2620|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])\u200D[\u2640\u2642]|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u3030\u303D\u3297\u3299]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]|\uD83D[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])\uFE0F|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDE35\u200D\uD83D\uDCAB|\uD83D\uDE2E\u200D\uD83D\uDCA8|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83E\uDDD1(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83D\uDC69(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF6\uD83C\uDDE6|\uD83C\uDDF4\uD83C\uDDF2|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270C\u270D]|\uD83D[\uDD74\uDD90])(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC08\uDC15\uDC3B\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE2E\uDE35\uDE36\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5]|\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD]|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF]|[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0D\uDD0E\uDD10-\uDD17\uDD1D\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78\uDD7A-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCB\uDDD0\uDDE0-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6]|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26A7\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5-\uDED7\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDD77\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g},Ij=NS(_j);function vu(e,t={}){if(typeof e!="string"||e.length===0||(t={ambiguousIsNarrow:!0,...t},e=kS(e),e.length===0))return 0;e=e.replace(Ij()," ");let r=t.ambiguousIsNarrow?1:2,n=0;for(let i of e){let s=i.codePointAt(0);if(!(s<=31||s>=127&&s<=159||s>=768&&s<=879))switch(Fj.eastAsianWidth(i)){case"F":case"W":n+=2;break;case"A":n+=r;break;default:n+=1}}return n}var Kg=10,CS=(e=0)=>t=>`\x1B[${t+e}m`,ES=(e=0)=>t=>`\x1B[${38+e};5;${t}m`,wS=(e=0)=>(t,r,n)=>`\x1B[${38+e};2;${t};${r};${n}m`,Dt={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};Object.keys(Dt.modifier);var kj=Object.keys(Dt.color),Nj=Object.keys(Dt.bgColor);[...kj,...Nj];function Rj(){let e=new Map;for(let[t,r]of Object.entries(Dt)){for(let[n,i]of Object.entries(r))Dt[n]={open:`\x1B[${i[0]}m`,close:`\x1B[${i[1]}m`},r[n]=Dt[n],e.set(i[0],i[1]);Object.defineProperty(Dt,t,{value:r,enumerable:!1})}return Object.defineProperty(Dt,"codes",{value:e,enumerable:!1}),Dt.color.close="\x1B[39m",Dt.bgColor.close="\x1B[49m",Dt.color.ansi=CS(),Dt.color.ansi256=ES(),Dt.color.ansi16m=wS(),Dt.bgColor.ansi=CS(Kg),Dt.bgColor.ansi256=ES(Kg),Dt.bgColor.ansi16m=wS(Kg),Object.defineProperties(Dt,{rgbToAnsi256:{value:(t,r,n)=>t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5),enumerable:!1},hexToRgb:{value:t=>{let r=/[a-f\d]{6}|[a-f\d]{3}/i.exec(t.toString(16));if(!r)return[0,0,0];let[n]=r;n.length===3&&(n=[...n].map(s=>s+s).join(""));let i=Number.parseInt(n,16);return[i>>16&255,i>>8&255,i&255]},enumerable:!1},hexToAnsi256:{value:t=>Dt.rgbToAnsi256(...Dt.hexToRgb(t)),enumerable:!1},ansi256ToAnsi:{value:t=>{if(t<8)return 30+t;if(t<16)return 90+(t-8);let r,n,i;if(t>=232)r=((t-232)*10+8)/255,n=r,i=r;else{t-=16;let a=t%36;r=Math.floor(t/36)/5,n=Math.floor(a/6)/5,i=a%6/5}let s=Math.max(r,n,i)*2;if(s===0)return 30;let o=30+(Math.round(i)<<2|Math.round(n)<<1|Math.round(r));return s===2&&(o+=60),o},enumerable:!1},rgbToAnsi:{value:(t,r,n)=>Dt.ansi256ToAnsi(Dt.rgbToAnsi256(t,r,n)),enumerable:!1},hexToAnsi:{value:t=>Dt.ansi256ToAnsi(Dt.hexToAnsi256(t)),enumerable:!1}}),Dt}var Oj=Rj(),gd=new Set(["\x1B","\x9B"]),Bj=39,Jg="\x07",OS="[",Mj="]",BS="m",Xg=`${Mj}8;;`,SS=e=>`${gd.values().next().value}${OS}${e}${BS}`,TS=e=>`${gd.values().next().value}${Xg}${e}${Jg}`,Lj=e=>e.split(" ").map(t=>vu(t)),Vg=(e,t,r)=>{let n=[...t],i=!1,s=!1,o=vu(kS(e[e.length-1]));for(let[a,c]of n.entries()){let u=vu(c);if(o+u<=r?e[e.length-1]+=c:(e.push(c),o=0),gd.has(c)&&(i=!0,s=n.slice(a+1).join("").startsWith(Xg)),i){s?c===Jg&&(i=!1,s=!1):c===BS&&(i=!1);continue}o+=u,o===r&&a<n.length-1&&(e.push(""),o=0)}!o&&e[e.length-1].length>0&&e.length>1&&(e[e.length-2]+=e.pop())},$j=e=>{let t=e.split(" "),r=t.length;for(;r>0&&!(vu(t[r-1])>0);)r--;return r===t.length?e:t.slice(0,r).join(" ")+t.slice(r).join("")},Uj=(e,t,r={})=>{if(r.trim!==!1&&e.trim()==="")return"";let n="",i,s,o=Lj(e),a=[""];for(let[u,l]of e.split(" ").entries()){r.trim!==!1&&(a[a.length-1]=a[a.length-1].trimStart());let p=vu(a[a.length-1]);if(u!==0&&(p>=t&&(r.wordWrap===!1||r.trim===!1)&&(a.push(""),p=0),(p>0||r.trim===!1)&&(a[a.length-1]+=" ",p++)),r.hard&&o[u]>t){let d=t-p,h=1+Math.floor((o[u]-d-1)/t);Math.floor((o[u]-1)/t)<h&&a.push(""),Vg(a,l,t);continue}if(p+o[u]>t&&p>0&&o[u]>0){if(r.wordWrap===!1&&p<t){Vg(a,l,t);continue}a.push("")}if(p+o[u]>t&&r.wordWrap===!1){Vg(a,l,t);continue}a[a.length-1]+=l}r.trim!==!1&&(a=a.map(u=>$j(u)));let c=[...a.join(`
101
+ `),this.dy++}write(t,r=!1){this.linewrap===!0&&r===!1?this.stream.write(t.substr(0,this.getWidth())):this.stream.write(t)}lineWrapping(t){this.stream.isTTY&&(this.linewrap=t,t?this.stream.write("\x1B[?7h"):this.stream.write("\x1B[?7l"))}isTTY(){return this.stream.isTTY===!0}getWidth(){return this.stream.columns||(this.stream.isTTY?80:200)}};Y7.exports=Ww});var X7=w((tje,J7)=>{"use strict";f();J7.exports=({onlyFirst:e=!1}={})=>{let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(t,e?void 0:"g")}});var Z7=w((nje,Q7)=>{"use strict";f();var Sbe=X7();Q7.exports=e=>typeof e=="string"?e.replace(Sbe(),""):e});var tU=w((sje,Jw)=>{"use strict";f();var eU=e=>Number.isNaN(e)?!1:e>=4352&&(e<=4447||e===9001||e===9002||11904<=e&&e<=12871&&e!==12351||12880<=e&&e<=19903||19968<=e&&e<=42182||43360<=e&&e<=43388||44032<=e&&e<=55203||63744<=e&&e<=64255||65040<=e&&e<=65049||65072<=e&&e<=65131||65281<=e&&e<=65376||65504<=e&&e<=65510||110592<=e&&e<=110593||127488<=e&&e<=127569||131072<=e&&e<=262141);Jw.exports=eU;Jw.exports.default=eU});var nU=w((aje,rU)=>{"use strict";f();rU.exports=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF4\uD83C\uDDF2|\uD83C\uDDF6\uD83C\uDDE6|[#\*0-9]\uFE0F\u20E3|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83D\uDC69(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270A-\u270D]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC70\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDCAA\uDD74\uDD7A\uDD90\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD36\uDDB5\uDDB6\uDDBB\uDDD2-\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5\uDEEB\uDEEC\uDEF4-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g}});var sU=w((uje,Xw)=>{"use strict";f();var Tbe=Z7(),Abe=tU(),Pbe=nU(),iU=e=>{if(typeof e!="string"||e.length===0||(e=Tbe(e),e.length===0))return 0;e=e.replace(Pbe()," ");let t=0;for(let r=0;r<e.length;r++){let n=e.codePointAt(r);n<=31||n>=127&&n<=159||n>=768&&n<=879||(n>65535&&r++,t+=Abe(n)?2:1)}return t};Xw.exports=iU;Xw.exports.default=iU});var Qw=w((pje,oU)=>{f();oU.exports=function(t,r,n){if(r.autopadding!==!0)return t;function i(s,o){return(r.autopaddingChar+s).slice(-o)}switch(n){case"percentage":return i(t,3);default:return t}}});var Zw=w((fje,aU)=>{f();aU.exports=function(t,r){let n=Math.round(t*r.barsize),i=r.barsize-n;return r.barCompleteString.substr(0,n)+r.barGlue+r.barIncompleteString.substr(0,i)}});var eS=w((hje,cU)=>{f();cU.exports=function(t,r,n){function i(o){return n?n*Math.round(o/n):o}function s(o){return(r.autopaddingChar+o).slice(-2)}return t>3600?s(Math.floor(t/3600))+"h"+s(i(t%3600/60))+"m":t>60?s(Math.floor(t/60))+"m"+s(i(t%60))+"s":t>10?s(i(t))+"s":s(t)+"s"}});var tS=w((yje,uU)=>{f();var Fbe=sU(),_be=Qw(),Ibe=Zw(),kbe=eS();uU.exports=function(t,r,n){let i=t.format,s=t.formatTime||kbe,o=t.formatValue||_be,a=t.formatBar||Ibe,c=Math.floor(r.progress*100)+"",u=r.stopTime||Date.now(),l=Math.round((u-r.startTime)/1e3),p=Object.assign({},n,{bar:a(r.progress,t),percentage:o(c,t,"percentage"),total:o(r.total,t,"total"),value:o(r.value,t,"value"),eta:o(r.eta,t,"eta"),eta_formatted:s(r.eta,t,5),duration:o(l,t,"duration"),duration_formatted:s(l,t,1)});i=i.replace(/\{(\w+)\}/g,function(m,g){return typeof p[g]<"u"?p[g]:m});let d=Math.max(0,r.maxWidth-Fbe(i)-2),h=Math.floor(d/2);switch(t.align){case"right":i=d>0?" ".repeat(d)+i:i;break;case"center":i=h>0?" ".repeat(h)+i:i;break;case"left":default:break}return i}});var Tg=w((xje,lU)=>{f();function ot(e,t){return typeof e>"u"||e===null?t:e}lU.exports={parse:function(t,r){let n={},i=Object.assign({},r,t);return n.throttleTime=1e3/ot(i.fps,10),n.stream=ot(i.stream,process.stderr),n.terminal=ot(i.terminal,null),n.clearOnComplete=ot(i.clearOnComplete,!1),n.stopOnComplete=ot(i.stopOnComplete,!1),n.barsize=ot(i.barsize,40),n.align=ot(i.align,"left"),n.hideCursor=ot(i.hideCursor,!1),n.linewrap=ot(i.linewrap,!1),n.barGlue=ot(i.barGlue,""),n.barCompleteChar=ot(i.barCompleteChar,"="),n.barIncompleteChar=ot(i.barIncompleteChar,"-"),n.format=ot(i.format,"progress [{bar}] {percentage}% | ETA: {eta}s | {value}/{total}"),n.formatTime=ot(i.formatTime,null),n.formatValue=ot(i.formatValue,null),n.formatBar=ot(i.formatBar,null),n.etaBufferLength=ot(i.etaBuffer,10),n.etaAsynchronousUpdate=ot(i.etaAsynchronousUpdate,!1),n.progressCalculationRelative=ot(i.progressCalculationRelative,!1),n.synchronousUpdate=ot(i.synchronousUpdate,!0),n.noTTYOutput=ot(i.noTTYOutput,!1),n.notTTYSchedule=ot(i.notTTYSchedule,2e3),n.emptyOnZero=ot(i.emptyOnZero,!1),n.forceRedraw=ot(i.forceRedraw,!1),n.autopadding=ot(i.autopadding,!1),n.gracefulExit=ot(i.gracefulExit,!1),n},assignDerivedOptions:function(t){return t.barCompleteString=t.barCompleteChar.repeat(t.barsize+1),t.barIncompleteString=t.barIncompleteChar.repeat(t.barsize+1),t.autopaddingChar=t.autopadding?ot(t.autopaddingChar," "):"",t}}});var rS=w((Cje,dU)=>{f();var pU=W7(),Nbe=Yw(),Rbe=tS(),Obe=Tg(),Bbe=require("events");dU.exports=class extends Bbe{constructor(t){super(),this.options=Obe.assignDerivedOptions(t),this.terminal=this.options.terminal?this.options.terminal:new Nbe(this.options.stream),this.value=0,this.startValue=0,this.total=100,this.lastDrawnString=null,this.startTime=null,this.stopTime=null,this.lastRedraw=Date.now(),this.eta=new pU(this.options.etaBufferLength,0,0),this.payload={},this.isActive=!1,this.formatter=typeof this.options.format=="function"?this.options.format:Rbe}render(t=!1){let r={progress:this.getProgress(),eta:this.eta.getTime(),startTime:this.startTime,stopTime:this.stopTime,total:this.total,value:this.value,maxWidth:this.terminal.getWidth()};this.options.etaAsynchronousUpdate&&this.updateETA();let n=this.formatter(this.options,r,this.payload);(t||this.options.forceRedraw||this.options.noTTYOutput&&!this.terminal.isTTY()||this.lastDrawnString!=n)&&(this.emit("redraw-pre"),this.terminal.cursorTo(0,null),this.terminal.write(n),this.terminal.clearRight(),this.lastDrawnString=n,this.lastRedraw=Date.now(),this.emit("redraw-post"))}start(t,r,n){this.value=r||0,this.total=typeof t<"u"&&t>=0?t:100,this.startValue=r||0,this.payload=n||{},this.startTime=Date.now(),this.stopTime=null,this.lastDrawnString="",this.eta=new pU(this.options.etaBufferLength,this.startTime,this.value),this.isActive=!0,this.emit("start",t,r)}stop(){this.isActive=!1,this.stopTime=Date.now(),this.emit("stop",this.total,this.value)}update(t,r={}){typeof t=="number"&&(this.value=t,this.eta.update(Date.now(),t,this.total));let n=(typeof t=="object"?t:r)||{};this.emit("update",this.total,this.value);for(let i in n)this.payload[i]=n[i];this.value>=this.getTotal()&&this.options.stopOnComplete&&this.stop()}getProgress(){let t=this.value/this.total;return this.options.progressCalculationRelative&&(t=(this.value-this.startValue)/(this.total-this.startValue)),isNaN(t)&&(t=this.options&&this.options.emptyOnZero?0:1),t=Math.min(Math.max(t,0),1),t}increment(t=1,r={}){typeof t=="object"?this.update(this.value+1,t):this.update(this.value+t,r)}getTotal(){return this.total}setTotal(t){typeof t<"u"&&t>=0&&(this.total=t)}updateETA(){this.eta.update(Date.now(),this.value,this.total)}}});var mU=w((Sje,fU)=>{f();var Mbe=rS(),Lbe=Tg();fU.exports=class extends Mbe{constructor(t,r){super(Lbe.parse(t,r)),this.timer=null,this.options.noTTYOutput&&this.terminal.isTTY()===!1&&(this.options.synchronousUpdate=!1),this.schedulingRate=this.terminal.isTTY()?this.options.throttleTime:this.options.notTTYSchedule,this.sigintCallback=null}render(){this.timer&&(clearTimeout(this.timer),this.timer=null),super.render(),this.options.noTTYOutput&&this.terminal.isTTY()===!1&&this.terminal.newline(),this.timer=setTimeout(this.render.bind(this),this.schedulingRate)}update(t,r){this.timer&&(super.update(t,r),this.options.synchronousUpdate&&this.lastRedraw+this.options.throttleTime*2<Date.now()&&this.render())}start(t,r,n){this.options.noTTYOutput===!1&&this.terminal.isTTY()===!1||(this.sigintCallback===null&&this.options.gracefulExit&&(this.sigintCallback=this.stop.bind(this),process.once("SIGINT",this.sigintCallback),process.once("SIGTERM",this.sigintCallback)),this.terminal.cursorSave(),this.options.hideCursor===!0&&this.terminal.cursor(!1),this.options.linewrap===!1&&this.terminal.lineWrapping(!1),super.start(t,r,n),this.render())}stop(){this.timer&&(this.sigintCallback&&(process.removeListener("SIGINT",this.sigintCallback),process.removeListener("SIGTERM",this.sigintCallback),this.sigintCallback=null),this.render(),super.stop(),clearTimeout(this.timer),this.timer=null,this.options.hideCursor===!0&&this.terminal.cursor(!0),this.options.linewrap===!1&&this.terminal.lineWrapping(!0),this.terminal.cursorRestore(),this.options.clearOnComplete?(this.terminal.cursorTo(0,null),this.terminal.clearLine()):this.terminal.newline())}}});var gU=w((Pje,hU)=>{f();var $be=Yw(),Ube=rS(),jbe=Tg(),qbe=require("events");hU.exports=class extends qbe{constructor(t,r){super(),this.bars=[],this.options=jbe.parse(t,r),this.options.synchronousUpdate=!1,this.terminal=this.options.terminal?this.options.terminal:new $be(this.options.stream),this.timer=null,this.isActive=!1,this.schedulingRate=this.terminal.isTTY()?this.options.throttleTime:this.options.notTTYSchedule,this.loggingBuffer=[],this.sigintCallback=null}create(t,r,n,i={}){let s=new Ube(Object.assign({},this.options,{terminal:this.terminal},i));return this.bars.push(s),this.options.noTTYOutput===!1&&this.terminal.isTTY()===!1||(this.sigintCallback===null&&this.options.gracefulExit&&(this.sigintCallback=this.stop.bind(this),process.once("SIGINT",this.sigintCallback),process.once("SIGTERM",this.sigintCallback)),this.isActive||(this.options.hideCursor===!0&&this.terminal.cursor(!1),this.options.linewrap===!1&&this.terminal.lineWrapping(!1),this.timer=setTimeout(this.update.bind(this),this.schedulingRate)),this.isActive=!0,s.start(t,r,n),this.emit("start")),s}remove(t){let r=this.bars.indexOf(t);return r<0?!1:(this.bars.splice(r,1),this.update(),this.terminal.newline(),this.terminal.clearBottom(),!0)}update(){if(this.timer&&(clearTimeout(this.timer),this.timer=null),this.emit("update-pre"),this.terminal.cursorRelativeReset(),this.emit("redraw-pre"),this.loggingBuffer.length>0)for(this.terminal.clearLine();this.loggingBuffer.length>0;)this.terminal.write(this.loggingBuffer.shift(),!0);for(let t=0;t<this.bars.length;t++)t>0&&this.terminal.newline(),this.bars[t].render();this.emit("redraw-post"),this.options.noTTYOutput&&this.terminal.isTTY()===!1&&(this.terminal.newline(),this.terminal.newline()),this.timer=setTimeout(this.update.bind(this),this.schedulingRate),this.emit("update-post"),this.options.stopOnComplete&&!this.bars.find(t=>t.isActive)&&this.stop()}stop(){if(clearTimeout(this.timer),this.timer=null,this.sigintCallback&&(process.removeListener("SIGINT",this.sigintCallback),process.removeListener("SIGTERM",this.sigintCallback),this.sigintCallback=null),this.isActive=!1,this.options.hideCursor===!0&&this.terminal.cursor(!0),this.options.linewrap===!1&&this.terminal.lineWrapping(!0),this.terminal.cursorRelativeReset(),this.emit("stop-pre-clear"),this.options.clearOnComplete)this.terminal.clearBottom();else{for(let t=0;t<this.bars.length;t++)t>0&&this.terminal.newline(),this.bars[t].render(),this.bars[t].stop();this.terminal.newline()}this.emit("stop")}log(t){this.loggingBuffer.push(t)}}});var bU=w((_je,yU)=>{f();yU.exports={format:"progress [{bar}] {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"=",barIncompleteChar:"-"}});var vU=w((kje,xU)=>{f();xU.exports={format:" {bar} {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"\u2588",barIncompleteChar:"\u2591"}});var CU=w((Rje,DU)=>{f();DU.exports={format:" \x1B[90m{bar}\x1B[0m {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"\u2588",barIncompleteChar:"\u2591"}});var wU=w((Bje,EU)=>{f();EU.exports={format:" {bar}\u25A0 {percentage}% | ETA: {eta}s | {value}/{total}",barCompleteChar:"\u25A0",barIncompleteChar:" "}});var TU=w((Lje,SU)=>{f();var Gbe=bU(),zbe=vU(),Hbe=CU(),Kbe=wU();SU.exports={legacy:Gbe,shades_classic:zbe,shades_grey:Hbe,rect:Kbe}});var FU=w((Uje,PU)=>{f();var AU=mU(),Vbe=gU(),Wbe=TU(),Ybe=tS(),Jbe=Qw(),Xbe=Zw(),Qbe=eS();PU.exports={Bar:AU,SingleBar:AU,MultiBar:Vbe,Presets:Wbe,Format:{Formatter:Ybe,BarFormat:Xbe,ValueFormat:Jbe,TimeFormat:Qbe}}});var OU=w((Zje,RU)=>{f();RU.exports=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE])))?))?|\uDC6F(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE89\uDE8F-\uDEC2\uDEC6\uDECE-\uDEDC\uDEDF-\uDEE9]|\uDD3C(?:\u200D[\u2640\u2642]\uFE0F?|\uD83C[\uDFFB-\uDFFF])?|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g});var Dxe={};pS(Dxe,{default:()=>vxe});module.exports=yj(Dxe);f();f();try{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="7fc89324-ce2f-403d-8fe2-525bf6bad154",e._sentryDebugIdIdentifier="sentry-dbid-7fc89324-ce2f-403d-8fe2-525bf6bad154")}catch{}f();var ij=require("../core/index.cjs"),sj=require("../node/index.cjs"),oj=require("../server/index.cjs"),aj=q(mS(),1);f();f();var th=require("fs/promises");f();var $g=q(require("prettier"),1),hS=require("module"),gS=q(require("path"),1);function xj(e){if(!e)return $g.default;try{let r=(0,hS.createRequire)(e)("prettier");if(!r)throw new Error("Prettier not found");return r}catch{return $g.default}}async function Zr(e,t,r,n){try{let i=gS.default.resolve(e,n??"file.tsx"),s=xj(i),o=await s.resolveConfig(i);return o?await s.format(t,{...o,filepath:n,parser:r}):await s.format(t,{filepath:n,parser:r})}catch{return t}}f();var o3=require("http");f();var Ug="preview-url";var ba="framework",od="platform",ad="node",yS="/~builder-connect",ho="/~builder-connected",jg="/~builder-dev-tools",qg="/~builder-dev-tools.js",go="/~builder-dev-tools-close",bS="/mappings";var a3=require("os"),fn=require("path"),kr=require("fs");f();var yd=require("util");f();var pr=q(cd(),1),va=require("process"),Ds=q(require("readline"),1),Wg=q(require("readline"),1),_S=require("stream"),IS=q(vt(),1);function Tj({onlyFirst:e=!1}={}){let t=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?(?:\\u0007|\\u001B\\u005C|\\u009C))","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");return new RegExp(t,e?void 0:"g")}var Aj=Tj();function kS(e){if(typeof e!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof e}\``);return e.replace(Aj,"")}function NS(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var RS={exports:{}};(function(e){var t={};e.exports=t,t.eastAsianWidth=function(n){var i=n.charCodeAt(0),s=n.length==2?n.charCodeAt(1):0,o=i;return 55296<=i&&i<=56319&&56320<=s&&s<=57343&&(i&=1023,s&=1023,o=i<<10|s,o+=65536),o==12288||65281<=o&&o<=65376||65504<=o&&o<=65510?"F":o==8361||65377<=o&&o<=65470||65474<=o&&o<=65479||65482<=o&&o<=65487||65490<=o&&o<=65495||65498<=o&&o<=65500||65512<=o&&o<=65518?"H":4352<=o&&o<=4447||4515<=o&&o<=4519||4602<=o&&o<=4607||9001<=o&&o<=9002||11904<=o&&o<=11929||11931<=o&&o<=12019||12032<=o&&o<=12245||12272<=o&&o<=12283||12289<=o&&o<=12350||12353<=o&&o<=12438||12441<=o&&o<=12543||12549<=o&&o<=12589||12593<=o&&o<=12686||12688<=o&&o<=12730||12736<=o&&o<=12771||12784<=o&&o<=12830||12832<=o&&o<=12871||12880<=o&&o<=13054||13056<=o&&o<=19903||19968<=o&&o<=42124||42128<=o&&o<=42182||43360<=o&&o<=43388||44032<=o&&o<=55203||55216<=o&&o<=55238||55243<=o&&o<=55291||63744<=o&&o<=64255||65040<=o&&o<=65049||65072<=o&&o<=65106||65108<=o&&o<=65126||65128<=o&&o<=65131||110592<=o&&o<=110593||127488<=o&&o<=127490||127504<=o&&o<=127546||127552<=o&&o<=127560||127568<=o&&o<=127569||131072<=o&&o<=194367||177984<=o&&o<=196605||196608<=o&&o<=262141?"W":32<=o&&o<=126||162<=o&&o<=163||165<=o&&o<=166||o==172||o==175||10214<=o&&o<=10221||10629<=o&&o<=10630?"Na":o==161||o==164||167<=o&&o<=168||o==170||173<=o&&o<=174||176<=o&&o<=180||182<=o&&o<=186||188<=o&&o<=191||o==198||o==208||215<=o&&o<=216||222<=o&&o<=225||o==230||232<=o&&o<=234||236<=o&&o<=237||o==240||242<=o&&o<=243||247<=o&&o<=250||o==252||o==254||o==257||o==273||o==275||o==283||294<=o&&o<=295||o==299||305<=o&&o<=307||o==312||319<=o&&o<=322||o==324||328<=o&&o<=331||o==333||338<=o&&o<=339||358<=o&&o<=359||o==363||o==462||o==464||o==466||o==468||o==470||o==472||o==474||o==476||o==593||o==609||o==708||o==711||713<=o&&o<=715||o==717||o==720||728<=o&&o<=731||o==733||o==735||768<=o&&o<=879||913<=o&&o<=929||931<=o&&o<=937||945<=o&&o<=961||963<=o&&o<=969||o==1025||1040<=o&&o<=1103||o==1105||o==8208||8211<=o&&o<=8214||8216<=o&&o<=8217||8220<=o&&o<=8221||8224<=o&&o<=8226||8228<=o&&o<=8231||o==8240||8242<=o&&o<=8243||o==8245||o==8251||o==8254||o==8308||o==8319||8321<=o&&o<=8324||o==8364||o==8451||o==8453||o==8457||o==8467||o==8470||8481<=o&&o<=8482||o==8486||o==8491||8531<=o&&o<=8532||8539<=o&&o<=8542||8544<=o&&o<=8555||8560<=o&&o<=8569||o==8585||8592<=o&&o<=8601||8632<=o&&o<=8633||o==8658||o==8660||o==8679||o==8704||8706<=o&&o<=8707||8711<=o&&o<=8712||o==8715||o==8719||o==8721||o==8725||o==8730||8733<=o&&o<=8736||o==8739||o==8741||8743<=o&&o<=8748||o==8750||8756<=o&&o<=8759||8764<=o&&o<=8765||o==8776||o==8780||o==8786||8800<=o&&o<=8801||8804<=o&&o<=8807||8810<=o&&o<=8811||8814<=o&&o<=8815||8834<=o&&o<=8835||8838<=o&&o<=8839||o==8853||o==8857||o==8869||o==8895||o==8978||9312<=o&&o<=9449||9451<=o&&o<=9547||9552<=o&&o<=9587||9600<=o&&o<=9615||9618<=o&&o<=9621||9632<=o&&o<=9633||9635<=o&&o<=9641||9650<=o&&o<=9651||9654<=o&&o<=9655||9660<=o&&o<=9661||9664<=o&&o<=9665||9670<=o&&o<=9672||o==9675||9678<=o&&o<=9681||9698<=o&&o<=9701||o==9711||9733<=o&&o<=9734||o==9737||9742<=o&&o<=9743||9748<=o&&o<=9749||o==9756||o==9758||o==9792||o==9794||9824<=o&&o<=9825||9827<=o&&o<=9829||9831<=o&&o<=9834||9836<=o&&o<=9837||o==9839||9886<=o&&o<=9887||9918<=o&&o<=9919||9924<=o&&o<=9933||9935<=o&&o<=9953||o==9955||9960<=o&&o<=9983||o==10045||o==10071||10102<=o&&o<=10111||11093<=o&&o<=11097||12872<=o&&o<=12879||57344<=o&&o<=63743||65024<=o&&o<=65039||o==65533||127232<=o&&o<=127242||127248<=o&&o<=127277||127280<=o&&o<=127337||127344<=o&&o<=127386||917760<=o&&o<=917999||983040<=o&&o<=1048573||1048576<=o&&o<=1114109?"A":"N"},t.characterLength=function(n){var i=this.eastAsianWidth(n);return i=="F"||i=="W"||i=="A"?2:1};function r(n){return n.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g)||[]}t.length=function(n){for(var i=r(n),s=0,o=0;o<i.length;o++)s=s+this.characterLength(i[o]);return s},t.slice=function(n,i,s){textLen=t.length(n),i=i||0,s=s||1,i<0&&(i=textLen+i),s<0&&(s=textLen+s);for(var o="",a=0,c=r(n),u=0;u<c.length;u++){var l=c[u],p=t.length(l);if(a>=i-(p==2?1:0))if(a+p<=s)o+=l;else break;a+=p}return o}})(RS);var Pj=RS.exports,Fj=NS(Pj),_j=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67)\uDB40\uDC7F|(?:\uD83E\uDDD1\uD83C\uDFFF\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFC-\uDFFF])|\uD83D\uDC68(?:\uD83C\uDFFB(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|[\u2695\u2696\u2708]\uFE0F|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))?|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])\uFE0F|\u200D(?:(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D[\uDC66\uDC67])|\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC)?|(?:\uD83D\uDC69(?:\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69]))|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC69(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDE36\u200D\uD83C\uDF2B|\uD83C\uDFF3\uFE0F\u200D\u26A7|\uD83D\uDC3B\u200D\u2744|(?:(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\uD83C\uDFF4\u200D\u2620|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])\u200D[\u2640\u2642]|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u3030\u303D\u3297\u3299]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]|\uD83D[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])\uFE0F|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDE35\u200D\uD83D\uDCAB|\uD83D\uDE2E\u200D\uD83D\uDCA8|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83E\uDDD1(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83D\uDC69(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF6\uD83C\uDDE6|\uD83C\uDDF4\uD83C\uDDF2|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270C\u270D]|\uD83D[\uDD74\uDD90])(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC08\uDC15\uDC3B\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE2E\uDE35\uDE36\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5]|\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD]|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF]|[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0D\uDD0E\uDD10-\uDD17\uDD1D\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78\uDD7A-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCB\uDDD0\uDDE0-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6]|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26A7\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5-\uDED7\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDD77\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g},Ij=NS(_j);function vu(e,t={}){if(typeof e!="string"||e.length===0||(t={ambiguousIsNarrow:!0,...t},e=kS(e),e.length===0))return 0;e=e.replace(Ij()," ");let r=t.ambiguousIsNarrow?1:2,n=0;for(let i of e){let s=i.codePointAt(0);if(!(s<=31||s>=127&&s<=159||s>=768&&s<=879))switch(Fj.eastAsianWidth(i)){case"F":case"W":n+=2;break;case"A":n+=r;break;default:n+=1}}return n}var Kg=10,CS=(e=0)=>t=>`\x1B[${t+e}m`,ES=(e=0)=>t=>`\x1B[${38+e};5;${t}m`,wS=(e=0)=>(t,r,n)=>`\x1B[${38+e};2;${t};${r};${n}m`,Dt={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};Object.keys(Dt.modifier);var kj=Object.keys(Dt.color),Nj=Object.keys(Dt.bgColor);[...kj,...Nj];function Rj(){let e=new Map;for(let[t,r]of Object.entries(Dt)){for(let[n,i]of Object.entries(r))Dt[n]={open:`\x1B[${i[0]}m`,close:`\x1B[${i[1]}m`},r[n]=Dt[n],e.set(i[0],i[1]);Object.defineProperty(Dt,t,{value:r,enumerable:!1})}return Object.defineProperty(Dt,"codes",{value:e,enumerable:!1}),Dt.color.close="\x1B[39m",Dt.bgColor.close="\x1B[49m",Dt.color.ansi=CS(),Dt.color.ansi256=ES(),Dt.color.ansi16m=wS(),Dt.bgColor.ansi=CS(Kg),Dt.bgColor.ansi256=ES(Kg),Dt.bgColor.ansi16m=wS(Kg),Object.defineProperties(Dt,{rgbToAnsi256:{value:(t,r,n)=>t===r&&r===n?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(n/255*5),enumerable:!1},hexToRgb:{value:t=>{let r=/[a-f\d]{6}|[a-f\d]{3}/i.exec(t.toString(16));if(!r)return[0,0,0];let[n]=r;n.length===3&&(n=[...n].map(s=>s+s).join(""));let i=Number.parseInt(n,16);return[i>>16&255,i>>8&255,i&255]},enumerable:!1},hexToAnsi256:{value:t=>Dt.rgbToAnsi256(...Dt.hexToRgb(t)),enumerable:!1},ansi256ToAnsi:{value:t=>{if(t<8)return 30+t;if(t<16)return 90+(t-8);let r,n,i;if(t>=232)r=((t-232)*10+8)/255,n=r,i=r;else{t-=16;let a=t%36;r=Math.floor(t/36)/5,n=Math.floor(a/6)/5,i=a%6/5}let s=Math.max(r,n,i)*2;if(s===0)return 30;let o=30+(Math.round(i)<<2|Math.round(n)<<1|Math.round(r));return s===2&&(o+=60),o},enumerable:!1},rgbToAnsi:{value:(t,r,n)=>Dt.ansi256ToAnsi(Dt.rgbToAnsi256(t,r,n)),enumerable:!1},hexToAnsi:{value:t=>Dt.ansi256ToAnsi(Dt.hexToAnsi256(t)),enumerable:!1}}),Dt}var Oj=Rj(),gd=new Set(["\x1B","\x9B"]),Bj=39,Jg="\x07",OS="[",Mj="]",BS="m",Xg=`${Mj}8;;`,SS=e=>`${gd.values().next().value}${OS}${e}${BS}`,TS=e=>`${gd.values().next().value}${Xg}${e}${Jg}`,Lj=e=>e.split(" ").map(t=>vu(t)),Vg=(e,t,r)=>{let n=[...t],i=!1,s=!1,o=vu(kS(e[e.length-1]));for(let[a,c]of n.entries()){let u=vu(c);if(o+u<=r?e[e.length-1]+=c:(e.push(c),o=0),gd.has(c)&&(i=!0,s=n.slice(a+1).join("").startsWith(Xg)),i){s?c===Jg&&(i=!1,s=!1):c===BS&&(i=!1);continue}o+=u,o===r&&a<n.length-1&&(e.push(""),o=0)}!o&&e[e.length-1].length>0&&e.length>1&&(e[e.length-2]+=e.pop())},$j=e=>{let t=e.split(" "),r=t.length;for(;r>0&&!(vu(t[r-1])>0);)r--;return r===t.length?e:t.slice(0,r).join(" ")+t.slice(r).join("")},Uj=(e,t,r={})=>{if(r.trim!==!1&&e.trim()==="")return"";let n="",i,s,o=Lj(e),a=[""];for(let[u,l]of e.split(" ").entries()){r.trim!==!1&&(a[a.length-1]=a[a.length-1].trimStart());let p=vu(a[a.length-1]);if(u!==0&&(p>=t&&(r.wordWrap===!1||r.trim===!1)&&(a.push(""),p=0),(p>0||r.trim===!1)&&(a[a.length-1]+=" ",p++)),r.hard&&o[u]>t){let d=t-p,h=1+Math.floor((o[u]-d-1)/t);Math.floor((o[u]-1)/t)<h&&a.push(""),Vg(a,l,t);continue}if(p+o[u]>t&&p>0&&o[u]>0){if(r.wordWrap===!1&&p<t){Vg(a,l,t);continue}a.push("")}if(p+o[u]>t&&r.wordWrap===!1){Vg(a,l,t);continue}a[a.length-1]+=l}r.trim!==!1&&(a=a.map(u=>$j(u)));let c=[...a.join(`
102
102
  `)];for(let[u,l]of c.entries()){if(n+=l,gd.has(l)){let{groups:d}=new RegExp(`(?:\\${OS}(?<code>\\d+)m|\\${Xg}(?<uri>.*)${Jg})`).exec(c.slice(u).join(""))||{groups:{}};if(d.code!==void 0){let h=Number.parseFloat(d.code);i=h===Bj?void 0:h}else d.uri!==void 0&&(s=d.uri.length===0?void 0:d.uri)}let p=Oj.codes.get(Number(i));c[u+1]===`
103
103
  `?(s&&(n+=TS("")),i&&p&&(n+=SS(p))):l===`
104
104
  `&&(i&&p&&(n+=SS(i)),s&&(n+=TS(s)))}return n};function AS(e,t,r){return String(e).normalize().replace(/\r\n/g,`
@@ -165,7 +165,7 @@ ${US}${n.trimStart()}`),r=3+(0,yd.stripVTControlCharacters)(n.trimStart()).lengt
165
165
  `),m(),i()};return{start:v,stop:C,message:(x="")=>{a=y(x??a)}}};var Zs=q(vt(),1);f();var xe=q(require("typescript"),1);var ge=q(vt(),1);f();f();function Re(e,t=""){return e.ts.createSourceFile("module.tsx",typeof t=="string"?t:"",e.ts.ScriptTarget.Latest,void 0)}function Dd(e,t=""){let r=Re(e,t?.trim());if(r.statements.length===0)throw new Error(`No statements found in code: ${t}`);return r.statements[0]}function Gt(e,t,r){if(t){let n=e.ts.createPrinter({newLine:e.ts.NewLineKind.LineFeed,removeComments:r});return e.ts.isSourceFile(t)?n.printFile(t).trim()+`
166
166
  `:n.printNode(e.ts.EmitHint.Unspecified,t,e.ts.createSourceFile("module.tsx","",e.ts.ScriptTarget.Latest)).trim()+`
167
167
  `}return""}f();var XS=q(YS(),1);function dr(e){return e.endsWith(".mapper.tsx")||e.endsWith(".mapper.jsx")||e.endsWith(".mapper.ts")||e.endsWith(".mapper.js")||e.endsWith(".mapper.mjs")}function Oe(e,t,r){t=jn(t),r=jn(r),t=e.dirname(t);let n=e.basename(r,e.extname(r));r=e.dirname(r);let i;return n==="index"?i=e.relative(t,r):i=e.relative(t,e.join(r,n)),i=jn(e.normalize(i)),i.startsWith(".")||(i="./"+i),i}function jn(e){return e.startsWith("\\\\?\\")?e:e.replace(/\\/g,"/")}function yo(e,t){let r=e.extname(t),n=e.basename(t,r).split(/[\/\\]/),i=n[n.length-1];return JS(i==="index"?e.basename(e.dirname(t)):i)}function JS(e){return at(e).replace(/ /g,"")}function yn(e,t){let r=e.extname(t),n=jn(e.basename(t,r)).split("/").pop();return at(n==="index"?e.basename(e.dirname(t)):n)}function ct(e,t){let r=jn(e.relative(e.getAppRootDir(),t));r=r.split("/").filter(i=>i!=="."&&i!==".."&&i!=="").join("/"),r.endsWith(".tsx")||r.endsWith(".jsx")?r=r.slice(0,-4):(r.endsWith(".ts")||r.endsWith(".js"))&&(r=r.slice(0,-3));let n=e.getFrameworks();return r.startsWith("src/")&&(r=r.slice(4)),n.some(i=>i.name.includes("next"))?"@/"+r:"~/"+r}function qe(e,t){let r=t,n=[];for(let i=0;i<2;i++){let s=e.basename(r);if(!s||s==="components")break;n.unshift(s),r=e.dirname(r)}return n.join("/")}function at(e){for(e=e.replace(/([A-Z])/g," $1").replace(/\./g," ").replace(/_/g," ").replace(/-/g," ").replace(/\s/g," ").trim();e.includes(" ");)e=e.replace(/ /g," ");return e.split(" ").map(t=>t.length>2?t[0].toUpperCase()+t.slice(1):t).join("").trim()}function Ur(e){return e.sort((t,r)=>t.name.toLocaleLowerCase().localeCompare(r.name.toLocaleLowerCase()))}async function it(e,t,r,n){if(typeof r!="string"||r==="")throw new Error(`getComponentId(), exportName must be a non-empty string, received: ${r}, ${t}`);return n&&(t=n),t=e.normalize(t),(await e.hash(t+"#"+r)).substring(0,8)}async function QS(e){return(await e.hash(e.getAppRootDir())).substring(0,8)}function Du(e){return typeof e=="number"}function Da(e){return typeof e=="boolean"}function Cr(e){return typeof e=="string"}function Ca(e){return typeof e=="string"?/^[A-Z][A-Za-z0-9]*$/.test(e):!1}function tn(e){return JSON.parse(JSON.stringify(e))}function Cd(e,t,r){for(let n of t)if(e.dirname(r).includes(n))return!0;return!1}function ZS(){try{let e=(0,XS.default)();if(e?.name)return e.name}catch{}return"npm"}function nq(){return process.platform.startsWith("win")}function fr(){return nq()?'"@builder.io/dev-tools"':"builder.io"}function ny(e){return e.replace(/[^a-zA-Z0-9-_]/g,"_")}f();function Er(e){let t=e.join(e.getAppRootDir(),"tsconfig.json");return e.exists(t)}var iq=["node_modules","dist","build","public"];async function jr(e,t){async function r(i,s){if(s>10)return;let o=await e.readdir(i);for(let a of o){if(iq.includes(a))continue;let c=e.join(i,a),u=await e.stat(c);if(u){if(u.isFile()&&a.startsWith("builder-registry."))return c;if(u.isDirectory()){let l=await r(c,s+1);if(l)return l}}}}let n=await r(e.getAppRootDir(),0);if(!n){let s=`builder-registry.${await Er(e)?"ts":"js"}`;return e.join(t,s)}return n}async function rn(e,t){let r=e.resolve("/");for(let n=0;n<20;n++){let i=e.join(t,"package.json"),s=await e.readFile(i);if(s)return JSON.parse(s);if(t===r)break;t=e.dirname(t)}return null}async function e1(e,t){for(let r=0;r<20;r++){let n=e.dirname(t),i=e.join(n,"node_modules");if(await e.exists(i))return i;if(t===e.getAppRootDir())break;t=e.dirname(t)}return e.join(e.getAppRootDir(),"node_modules")}async function Cu(e,t,r){let n=await e.readdir(t);return n.includes(r)?e.join(t,r):(await Promise.all(n.map(async s=>{if(s.startsWith(".")||s==="node_modules")return;let o=e.join(t,s);if((await e.stat(o)).isDirectory()){let c=await Cu(e,o,r);if(c)return c}}))).find(s=>typeof s=="string")}async function Ut(e,t,r){if(!Array.isArray(t)||t.length===0)throw new Error(`createTsProgram() Invalid filePaths: ${t}`);let n=await e1(e,t[0]),i=e.join(n,"typescript","lib"),s=new Map,o={fileExists:a=>{if(a=e.normalize(a),a.includes("node_modules")){let c=Eu.get(a);if(!c){try{e.statSync(a).isFile()?c={exists:!0,content:e.readFileSync(a)}:c={exists:!1}}catch{c={exists:!1}}Eu.set(a,c)}return c.exists}if(!s.has(a))if(e.existsSync(a)){let u=e.statSync(a);s.set(a,u.isFile())}else s.set(a,!1);return s.get(a)},getCanonicalFileName:a=>e.normalize(a),getCurrentDirectory:()=>e.cwd(),getDefaultLibFileName:()=>e.join(i,"lib.d.ts"),getDefaultLibLocation:()=>i,getNewLine:()=>`
168
- `,getSourceFile:a=>{if(a=e.normalize(a),a.includes("node_modules")){let u=Eu.get(a);if(u)return Re(e,u.content)}let c;try{c=e.readFileSync(a)}catch{console.error(`Could not read: ${a}`),c==null}if(c==null){let u=e.basename(a),l=e.extname(u).toLowerCase();if(a.startsWith(i)&&l===".ts"&&(c=r1.get(u),c==null&&typeof self<"u"&&typeof fetch=="function"))throw new wd(u)}return a.includes("node_modules")&&(c?Eu.set(a,{exists:!0,content:c}):Eu.set(a,{exists:!1})),Re(e,c)},readFile:a=>{let c=e.readFileSync(a);return typeof c=="string"?c:void 0},useCaseSensitiveFileNames:()=>!1,writeFile:()=>{}};for(;;)try{return sq(e,o,t,r)}catch(a){if(a instanceof wd){await oq(e,a.libName);continue}throw e.Sentry?.captureException(a),new Error(`createTsProgram() Could not create program for: ${t[0]}`,{cause:a})}}function sq(e,t,r,n){let i={rootNames:[...r],host:t,options:{}},s=e.ts.findConfigFile(e.dirname(r[0]),o=>e.existsSync(o));if(s){let o=t1.get(s);if(!o){let a=e.ts.readConfigFile(s,c=>{let u=e.readFileSync(c);return typeof u=="string"?u:void 0});a.error?e.Sentry?.captureException(new Error("Error reading tsconfig for createTsProgram"),{extra:{error:a.error,tsConfigPath:s}}):(o=e.ts.parseJsonConfigFileContent(a.config,e.ts.sys||{useCaseSensitiveFileNames:!1,readDirectory:(u,l)=>e.readdirSync(u),fileExists:u=>e.existsSync(u),readFile:u=>e.readFileSync(u)||void 0},e.dirname(s),void 0,s).options,t1.set(s,o))}o&&(i.options=tn(o))}return i.options.noEmit=!0,i.options.isolatedModules=!1,i.options.strict=!1,i.options.jsx=e.ts.JsxEmit.Preserve,i.options.allowJs=!0,Object.assign(i.options,n),e.ts.createProgram(i)}async function Ea(e,t,r){r||(r=await Ut(e,[t]));let n=r.getSourceFile(t);if(!n)throw new Error(`getTypeChecker() Could not find source file: ${t}`);return{typeChecker:r.getTypeChecker(),sourceFile:n}}var wd=class{constructor(t){this.libName=t}};async function oq(e,t){let r=`https://cdn.jsdelivr.net/npm/typescript@${e.ts.version}/lib/${t}`;Ed.has(t)||Ed.set(t,fetch(r).then(n=>n.text()).then(n=>{r1.set(t,n)})),await Ed.get(t),Ed.delete(t)}var r1=new Map,Ed=new Map,Eu=new Map,t1=new Map;async function n1(e,t){let r=await e.readFile(t.filePath);return r==null?{diagnostics:[{messageText:`Error reading: ${t.filePath}`}],code:null,output:null}:iy(e,{code:r,filePath:t.filePath,compilerOptions:t.compilerOptions})}function iy(e,t){let r={diagnostics:[],code:t.code,output:null};try{let n=e.ts.transpileModule(t.code,{compilerOptions:t.compilerOptions,fileName:t.filePath??"module.tsx",reportDiagnostics:!0});n.diagnostics?.forEach(i=>{r.diagnostics.push({messageText:String(i.messageText)})}),r.output=n.outputText}catch(n){console.error("transpileModule",n),r.diagnostics.push({messageText:String(n)})}return r}f();f();var aq="1.9.19",Te=process.env.OVERRIDE_VERSION??aq;f();f();async function bo(e){let t=[],r=await rn(e,e.getRepoRootDir());if(r){let n=await s1(r,e);t.push(...n)}return t}async function s1(e,t){let r=[];if(e&&typeof e=="object"){let n=new Set(Object.keys({...e.dependencies,...e.devDependencies}));for(let i of cq)if(n.has(i)&&!r.some(s=>s.name===i)){let s={name:i};i1.has(i)&&(s.version=await i1.get(i)(t)),r.push(s)}}return r}function sy(e){let t=parseInt(e);return Number.isNaN(t)?void 0:t}var i1=new Map([["next",async e=>{if(!e.spawnSync)return;let t=ZS(),r=t==="npm"?"npx":t,{stdout:n}=e.spawnSync(r,["next","-v"],{encoding:"utf8"});if(!n)return;let i=n.match(/(Next.js v)([\d.]+)/g);if(!i)return;let s=i[0].split("Next.js v")[1],[o,a,c]=s.split(".");return{major:sy(o),minor:sy(a),patch:sy(c)}}]]),cq=["@shopify/remix-oxygen","@shopify/hydrogen","@builder.io/qwik-city","@remix-run/react","@sveltejs/kit","astro","gatsby","next","nuxt","@builder.io/qwik","@angular/core","react","solid-js","svelte","vue"];f();f();async function bn(e){let t=o1(e),r=await e.readFile(t);return typeof r=="string"?JSON.parse(r):{}}async function xn(e,t){t=typeof t=="object"&&t!=null?t:{};let r=o1(e);await e.writeFile(r,JSON.stringify(t??{},null,2))}function o1(e){let t=e.getAppRootDir();return e.join(t,"node_modules",".builder","builder-cache.json")}f();f();async function oi(e,t,r){let n={envKey:r,envValue:null,file:""};for(let i of t){let s=e.join(e.getAppRootDir(),i),o=await uq(e,s);if(o){let a=o[r];if(typeof a=="string"&&a.length>0&&a!=="YOUR_API_KEY")return n.envValue=a,n.file=s,n}}return n.file=e.join(e.getAppRootDir(),t[t.length-1]),n}async function uq(e,t){let r=await e.readFile(t);return typeof r=="string"?a1(r):null}function a1(e){let t={},r=e.replace(/\r\n?/gm,`
168
+ `,getSourceFile:a=>{if(a=e.normalize(a),a.includes("node_modules")){let u=Eu.get(a);if(u)return Re(e,u.content)}let c;try{c=e.readFileSync(a)}catch{console.error(`Could not read: ${a}`),c==null}if(c==null){let u=e.basename(a),l=e.extname(u).toLowerCase();if(a.startsWith(i)&&l===".ts"&&(c=r1.get(u),c==null&&typeof self<"u"&&typeof fetch=="function"))throw new wd(u)}return a.includes("node_modules")&&(c?Eu.set(a,{exists:!0,content:c}):Eu.set(a,{exists:!1})),Re(e,c)},readFile:a=>{let c=e.readFileSync(a);return typeof c=="string"?c:void 0},useCaseSensitiveFileNames:()=>!1,writeFile:()=>{}};for(;;)try{return sq(e,o,t,r)}catch(a){if(a instanceof wd){await oq(e,a.libName);continue}throw e.Sentry?.captureException(a),new Error(`createTsProgram() Could not create program for: ${t[0]}`,{cause:a})}}function sq(e,t,r,n){let i={rootNames:[...r],host:t,options:{}},s=e.ts.findConfigFile(e.dirname(r[0]),o=>e.existsSync(o));if(s){let o=t1.get(s);if(!o){let a=e.ts.readConfigFile(s,c=>{let u=e.readFileSync(c);return typeof u=="string"?u:void 0});a.error?e.Sentry?.captureException(new Error("Error reading tsconfig for createTsProgram"),{extra:{error:a.error,tsConfigPath:s}}):(o=e.ts.parseJsonConfigFileContent(a.config,e.ts.sys||{useCaseSensitiveFileNames:!1,readDirectory:(u,l)=>e.readdirSync(u),fileExists:u=>e.existsSync(u),readFile:u=>e.readFileSync(u)||void 0},e.dirname(s),void 0,s).options,t1.set(s,o))}o&&(i.options=tn(o))}return i.options.noEmit=!0,i.options.isolatedModules=!1,i.options.strict=!1,i.options.jsx=e.ts.JsxEmit.Preserve,i.options.allowJs=!0,Object.assign(i.options,n),e.ts.createProgram(i)}async function Ea(e,t,r){r||(r=await Ut(e,[t]));let n=r.getSourceFile(t);if(!n)throw new Error(`getTypeChecker() Could not find source file: ${t}`);return{typeChecker:r.getTypeChecker(),sourceFile:n}}var wd=class{libName;constructor(t){this.libName=t}};async function oq(e,t){let r=`https://cdn.jsdelivr.net/npm/typescript@${e.ts.version}/lib/${t}`;Ed.has(t)||Ed.set(t,fetch(r).then(n=>n.text()).then(n=>{r1.set(t,n)})),await Ed.get(t),Ed.delete(t)}var r1=new Map,Ed=new Map,Eu=new Map,t1=new Map;async function n1(e,t){let r=await e.readFile(t.filePath);return r==null?{diagnostics:[{messageText:`Error reading: ${t.filePath}`}],code:null,output:null}:iy(e,{code:r,filePath:t.filePath,compilerOptions:t.compilerOptions})}function iy(e,t){let r={diagnostics:[],code:t.code,output:null};try{let n=e.ts.transpileModule(t.code,{compilerOptions:t.compilerOptions,fileName:t.filePath??"module.tsx",reportDiagnostics:!0});n.diagnostics?.forEach(i=>{r.diagnostics.push({messageText:String(i.messageText)})}),r.output=n.outputText}catch(n){console.error("transpileModule",n),r.diagnostics.push({messageText:String(n)})}return r}f();f();var aq="1.9.20",Ce=process.env.OVERRIDE_VERSION??aq;f();f();async function bo(e){let t=[],r=await rn(e,e.getRepoRootDir());if(r){let n=await s1(r,e);t.push(...n)}return t}async function s1(e,t){let r=[];if(e&&typeof e=="object"){let n=new Set(Object.keys({...e.dependencies,...e.devDependencies}));for(let i of cq)if(n.has(i)&&!r.some(s=>s.name===i)){let s={name:i};i1.has(i)&&(s.version=await i1.get(i)(t)),r.push(s)}}return r}function sy(e){let t=parseInt(e);return Number.isNaN(t)?void 0:t}var i1=new Map([["next",async e=>{if(!e.spawnSync)return;let t=ZS(),r=t==="npm"?"npx":t,{stdout:n}=e.spawnSync(r,["next","-v"],{encoding:"utf8"});if(!n)return;let i=n.match(/(Next.js v)([\d.]+)/g);if(!i)return;let s=i[0].split("Next.js v")[1],[o,a,c]=s.split(".");return{major:sy(o),minor:sy(a),patch:sy(c)}}]]),cq=["@shopify/remix-oxygen","@shopify/hydrogen","@builder.io/qwik-city","@remix-run/react","@sveltejs/kit","astro","gatsby","next","nuxt","@builder.io/qwik","@angular/core","react","solid-js","svelte","vue"];f();f();async function bn(e){let t=o1(e),r=await e.readFile(t);return typeof r=="string"?JSON.parse(r):{}}async function xn(e,t){t=typeof t=="object"&&t!=null?t:{};let r=o1(e);await e.writeFile(r,JSON.stringify(t??{},null,2))}function o1(e){let t=e.getAppRootDir();return e.join(t,"node_modules",".builder","builder-cache.json")}f();f();async function oi(e,t,r){let n={envKey:r,envValue:null,file:""};for(let i of t){let s=e.join(e.getAppRootDir(),i),o=await uq(e,s);if(o){let a=o[r];if(typeof a=="string"&&a.length>0&&a!=="YOUR_API_KEY")return n.envValue=a,n.file=s,n}}return n.file=e.join(e.getAppRootDir(),t[t.length-1]),n}async function uq(e,t){let r=await e.readFile(t);return typeof r=="string"?a1(r):null}function a1(e){let t={},r=e.replace(/\r\n?/gm,`
169
169
  `),n;for(;(n=lq.exec(r))!=null;){let i=n[1],s=n[2]||"";s=s.trim();let o=s[0];s=s.replace(/^(['"`])([\s\S]*)\1$/gm,"$2"),o==='"'&&(s=s.replace(/\\n/g,`
170
170
  `),s=s.replace(/\\r/g,"\r")),t[i]=s}return t}var lq=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/gm;async function ai(e,t,r,n){let i="# https://www.builder.io/c/docs/using-your-api-key",s=await e.readFile(t);try{if(s)if(s.includes(r))if(s.includes(n))e.debug(`"${r}" with "${n}" already set in ${t}`);else return e.debug(`Replace "${r}" in ${t}`),s=s.replace(new RegExp(`${r}=.*`),`${r}=${n}`),await e.writeFile(t,s),"update";else return e.debug(`Append "${r}" to ${t}`),s+=`
171
171
 
@@ -1182,7 +1182,7 @@ module.exports = nextConfig
1182
1182
  `:`
1183
1183
  `)+r,i=n+1,n=e.indexOf(`
1184
1184
  `,i)}while(n!==-1);return s+=e.slice(i),s}var{stdout:KP,stderr:VP}=GP,db=Symbol("GENERATOR"),$a=Symbol("STYLER"),qu=Symbol("IS_EMPTY"),WP=["ansi","ansi","ansi256","ansi16m"],Ua=Object.create(null),tV=(e,t={})=>{if(t.level&&!(Number.isInteger(t.level)&&t.level>=0&&t.level<=3))throw new Error("The `level` option should be an integer from 0 to 3");let r=KP?KP.level:0;e.level=t.level===void 0?r:t.level},ef=class{constructor(t){return YP(t)}},YP=e=>{let t=(...r)=>r.join(" ");return tV(t,e),Object.setPrototypeOf(t,Gu.prototype),t};function Gu(e){return YP(e)}Object.setPrototypeOf(Gu.prototype,Function.prototype);for(let[e,t]of Object.entries(Hn))Ua[e]={get(){let r=tf(this,mb(t.open,t.close,this[$a]),this[qu]);return Object.defineProperty(this,e,{value:r}),r}};Ua.visible={get(){let e=tf(this,this[$a],!0);return Object.defineProperty(this,"visible",{value:e}),e}};var fb=(e,t,r,...n)=>e==="rgb"?t==="ansi16m"?Hn[r].ansi16m(...n):t==="ansi256"?Hn[r].ansi256(Hn.rgbToAnsi256(...n)):Hn[r].ansi(Hn.rgbToAnsi(...n)):e==="hex"?fb("rgb",t,r,...Hn.hexToRgb(...n)):Hn[r][e](...n),rV=["rgb","hex","ansi256"];for(let e of rV){Ua[e]={get(){let{level:r}=this;return function(...n){let i=mb(fb(e,WP[r],"color",...n),Hn.color.close,this[$a]);return tf(this,i,this[qu])}}};let t="bg"+e[0].toUpperCase()+e.slice(1);Ua[t]={get(){let{level:r}=this;return function(...n){let i=mb(fb(e,WP[r],"bgColor",...n),Hn.bgColor.close,this[$a]);return tf(this,i,this[qu])}}}}var nV=Object.defineProperties(()=>{},{...Ua,level:{enumerable:!0,get(){return this[db].level},set(e){this[db].level=e}}}),mb=(e,t,r)=>{let n,i;return r===void 0?(n=e,i=t):(n=r.openAll+e,i=t+r.closeAll),{open:e,close:t,openAll:n,closeAll:i,parent:r}},tf=(e,t,r)=>{let n=(...i)=>iV(n,i.length===1?""+i[0]:i.join(" "));return Object.setPrototypeOf(n,nV),n[db]=e,n[$a]=t,n[qu]=r,n},iV=(e,t)=>{if(e.level<=0||!t)return e[qu]?"":t;let r=e[$a];if(r===void 0)return t;let{openAll:n,closeAll:i}=r;if(t.includes("\x1B"))for(;r!==void 0;)t=zP(t,r.close,r.open),r=r.parent;let s=t.indexOf(`
1185
- `);return s!==-1&&(t=HP(t,i,n,s)),n+t+i};Object.defineProperties(Gu.prototype,Ua);var CFe=Gu(),EFe=Gu({level:VP?VP.level:0});var Ie=new ef({level:2}),JP={comment:Ie.gray,quote:Ie.gray,keyword:Ie.green,"selector-tag":Ie.green,addition:Ie.green,number:Ie.cyan,string:Ie.cyan,"meta meta-string":Ie.cyan,literal:Ie.cyan,doctag:Ie.cyan,regexp:Ie.cyan,title:Ie.blue,section:Ie.blue,name:Ie.blue,"selector-id":Ie.blue,"selector-class":Ie.blue,attribute:Ie.yellow,attr:Ie.yellow,variable:Ie.yellow,"template-variable":Ie.yellow,"class title":Ie.yellow,type:Ie.yellow,symbol:Ie.magenta,bullet:Ie.magenta,subst:Ie.magenta,meta:Ie.magenta,"meta keyword":Ie.magenta,"selector-attr":Ie.magenta,"selector-pseudo":Ie.magenta,link:Ie.magenta,built_in:Ie.red,deletion:Ie.red,emphasis:Ie.italic,strong:Ie.bold,formula:Ie.inverse};function zu(e){let t=lb(e);return{highlight:r,highlightAuto:n,listLanguages:t.listLanguages,register:t.register,registerAlias:t.registerAlias,registered:t.registered};function r(i,s,o){let a=t.highlight(i,s),c=a.data;return{language:c.language,relevance:c.relevance,value:hb(o||JP,a)}}function n(i,s){let o,a;if(s&&("subset"in s||"sheet"in s)){let l=s;a={subset:l.subset},o=l.sheet}else o=s;let c=t.highlightAuto(i,a),u=c.data;return{language:u.language,relevance:u.relevance,value:hb(o||JP,c)}}}function hb(e,t){let r=new Set(t.type==="element"&&Array.isArray(t.properties.className)?t.properties.className.map(function(a){return String(a).replace(/^hljs-/,"")}):[]),n={},i,s="",o;for(o in e)if(Object.hasOwn(e,o)){let a=o.split(" "),c=e[o];r.has(a[0])?a.length===1?i=c:n[a.slice(1).join(" ")]=c:n[o]=c}return"value"in t?s=t.value:"children"in t&&(s=sV(n,t.children)),i&&(s=i(s)),s}function sV(e,t){let r=[],n=-1;for(;++n<t.length;)r.push(hb(e,t[n]));return r.join("")}f();var XP=q(require("@sentry/node"),1),QP=q(require("@amplitude/analytics-node"),1);async function te(e){if(process.env.NODE_ENV!=="test")try{await Promise.allSettled([XP.flush(2e3),QP.flush().promise])}catch(t){console.error(t)}process.exit(e)}f();var Fe=process.env.AIR_HOST||"https://api.builder.io";f();var Ci=q(require("@amplitude/analytics-node"),1),Xn=q(require("@sentry/node"),1);var ZP="1.9.19";f();var Vt=require("fs/promises"),e2=require("crypto"),ut=require("fs"),yl=require("os"),Ne=q(require("path"),1),t2=q(require("typescript"),1),r2=q(require("launch-editor"),1);var Bo=require("child_process");var Px={};pS(Px,{MagicastError:()=>yr,builders:()=>wJ,detectCodeFormat:()=>X_,generateCode:()=>Ax,loadFile:()=>CJ,parseExpression:()=>Z_,parseModule:()=>Q_,writeFile:()=>EJ});f();var Tf=require("fs");var Rf=q(SF(),1),y_=q(r_(),1);function cn(e){var t=e.use(Ft),r=t.Type,n=t.builtInTypes,i=n.number;function s(u){return r.from(l=>i.check(l)&&l>=u,i+" >= "+u)}let o={null:function(){return null},emptyArray:function(){return[]},false:function(){return!1},true:function(){return!0},undefined:function(){},"use strict":function(){return"use strict"}};var a=r.or(n.string,n.number,n.boolean,n.null,n.undefined);let c=r.from(u=>{if(u===null)return!0;var l=typeof u;return!(l==="object"||l==="function")},a.toString());return{geq:s,defaults:o,isPrimitive:c}}function tt(e){try{var t=e(),r=t.exports,n=r.default}catch{return}n&&n!==r&&typeof r=="object"&&(Object.assign(n,r,{default:n}),r.__esModule&&Object.defineProperty(n,"__esModule",{value:!0}),t.exports=n)}var YW=Object.defineProperty,JW=(e,t,r)=>t in e?YW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Ar=(e,t,r)=>(JW(e,typeof t!="symbol"?t+"":t,r),r),b_=Object.prototype,Af=b_.toString,wn=b_.hasOwnProperty,Oo=class{assert(t,r){if(!this.check(t,r)){var n=Cx(t);throw new Error(n+" does not match type "+this)}return!0}arrayOf(){let t=this;return new dl(t)}},dl=class extends Oo{constructor(t){super(),this.elemType=t,Ar(this,"kind","ArrayType")}toString(){return"["+this.elemType+"]"}check(t,r){return Array.isArray(t)&&t.every(n=>this.elemType.check(n,r))}},Pf=class extends Oo{constructor(t){super(),this.value=t,Ar(this,"kind","IdentityType")}toString(){return String(this.value)}check(t,r){let n=t===this.value;return!n&&typeof r=="function"&&r(this,t),n}},Ff=class extends Oo{constructor(t){super(),this.fields=t,Ar(this,"kind","ObjectType")}toString(){return"{ "+this.fields.join(", ")+" }"}check(t,r){return Af.call(t)===Af.call({})&&this.fields.every(n=>n.type.check(t[n.name],r))}},_f=class extends Oo{constructor(t){super(),this.types=t,Ar(this,"kind","OrType")}toString(){return this.types.join(" | ")}check(t,r){return this.types.some(n=>n.check(t,!!r))?!0:(typeof r=="function"&&r(this,t),!1)}},Ro=class extends Oo{constructor(t,r){super(),this.name=t,this.predicate=r,Ar(this,"kind","PredicateType")}toString(){return this.name}check(t,r){let n=this.predicate(t,r);return!n&&typeof r=="function"&&r(this,t),n}},ll=class e{constructor(t,r){this.type=t,this.typeName=r,Ar(this,"baseNames",[]),Ar(this,"ownFields",Object.create(null)),Ar(this,"allSupertypes",Object.create(null)),Ar(this,"supertypeList",[]),Ar(this,"allFields",Object.create(null)),Ar(this,"fieldNames",[]),Ar(this,"finalized",!1),Ar(this,"buildable",!1),Ar(this,"buildParams",[])}isSupertypeOf(t){if(t instanceof e){if(this.finalized!==!0||t.finalized!==!0)throw new Error("");return wn.call(t.allSupertypes,this.typeName)}else throw new Error(t+" is not a Def")}checkAllFields(t,r){var n=this.allFields;if(this.finalized!==!0)throw new Error(""+this.typeName);function i(s){var o=n[s],a=o.type,c=o.getValue(t);return a.check(c,r)}return t!==null&&typeof t=="object"&&Object.keys(n).every(i)}bases(...t){var r=this.baseNames;if(this.finalized){if(t.length!==r.length)throw new Error("");for(var n=0;n<t.length;n++)if(t[n]!==r[n])throw new Error("");return this}return t.forEach(i=>{r.indexOf(i)<0&&r.push(i)}),this}},If=class{constructor(t,r,n,i){this.name=t,this.type=r,this.defaultFn=n,Ar(this,"hidden"),this.hidden=!!i}toString(){return JSON.stringify(this.name)+": "+this.type}getValue(t){var r=t[this.name];return typeof r<"u"||typeof this.defaultFn=="function"&&(r=this.defaultFn.call(t)),r}};function Cx(e){return Array.isArray(e)?"["+e.map(Cx).join(", ")+"]":e&&typeof e=="object"?"{ "+Object.keys(e).map(function(t){return t+": "+e[t]}).join(", ")+" }":JSON.stringify(e)}function Ft(e){let t={or(...R){return new _f(R.map(M=>t.from(M)))},from(R,M){if(R instanceof dl||R instanceof Pf||R instanceof Ff||R instanceof _f||R instanceof Ro)return R;if(R instanceof ll)return R.type;if(a.check(R)){if(R.length!==1)throw new Error("only one element type is permitted for typed arrays");return new dl(t.from(R[0]))}if(c.check(R))return new Ff(Object.keys(R).map(W=>new If(W,t.from(R[W],W))));if(typeof R=="function"){var K=r.indexOf(R);if(K>=0)return n[K];if(typeof M!="string")throw new Error("missing name");return new Ro(M,R)}return new Pf(R)},def(R){return wn.call(b,R)?b[R]:b[R]=new C(R)},hasDef(R){return wn.call(b,R)}};var r=[],n=[];function i(R,M){let K=Af.call(M),W=new Ro(R,ce=>Af.call(ce)===K);return M&&typeof M.constructor=="function"&&(r.push(M.constructor),n.push(W)),W}let s=i("string","truthy"),o=i("function",function(){}),a=i("array",[]),c=i("object",{}),u=i("RegExp",/./),l=i("Date",new Date),p=i("number",3),d=i("boolean",!0),h=i("null",null),m=i("undefined",void 0),g=typeof BigInt=="function"?i("BigInt",BigInt(1234)):new Ro("BigInt",()=>!1),y={string:s,function:o,array:a,object:c,RegExp:u,Date:l,number:p,boolean:d,null:h,undefined:m,BigInt:g};var b=Object.create(null);function v(R){if(R&&typeof R=="object"){var M=R.type;if(typeof M=="string"&&wn.call(b,M)){var K=b[M];if(K.finalized)return K}}return null}class C extends ll{constructor(M){super(new Ro(M,(K,W)=>this.check(K,W)),M)}check(M,K){if(this.finalized!==!0)throw new Error("prematurely checking unfinalized type "+this.typeName);if(M===null||typeof M!="object")return!1;var W=v(M);return W?K&&W===this?this.checkAllFields(M,K):this.isSupertypeOf(W)?K?W.checkAllFields(M,K)&&this.checkAllFields(M,!1):!0:!1:this.typeName==="SourceLocation"||this.typeName==="Position"?this.checkAllFields(M,K):!1}build(...M){if(this.buildParams=M,this.buildable)return this;this.field("type",String,()=>this.typeName),this.buildable=!0;let K=(ce,se,Z,xt)=>{if(!wn.call(ce,se)){var Le=this.allFields;if(!wn.call(Le,se))throw new Error(""+se);var J=Le[se],$e=J.type,X;if(xt)X=Z;else if(J.defaultFn)X=J.defaultFn.call(ce);else{var me="no value or default function given for field "+JSON.stringify(se)+" of "+this.typeName+"("+this.buildParams.map(function(ue){return Le[ue]}).join(", ")+")";throw new Error(me)}if(!$e.check(X))throw new Error(Cx(X)+" does not match field "+J+" of type "+this.typeName);ce[se]=X}},W=(...ce)=>{var se=ce.length;if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var Z=Object.create(S);if(this.buildParams.forEach(function(xt,Le){Le<se?K(Z,xt,ce[Le],!0):K(Z,xt,null,!1)}),Object.keys(this.allFields).forEach(function(xt){K(Z,xt,null,!1)}),Z.type!==this.typeName)throw new Error("");return Z};return W.from=ce=>{if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var se=Object.create(S);if(Object.keys(this.allFields).forEach(function(Z){wn.call(ce,Z)?K(se,Z,ce[Z],!0):K(se,Z,null,!1)}),se.type!==this.typeName)throw new Error("");return se},Object.defineProperty(E,I(this.typeName),{enumerable:!0,value:W}),this}field(M,K,W,ce){return this.finalized?(console.error("Ignoring attempt to redefine field "+JSON.stringify(M)+" of finalized type "+JSON.stringify(this.typeName)),this):(this.ownFields[M]=new If(M,t.from(K),W,ce),this)}finalize(){if(!this.finalized){var M=this.allFields,K=this.allSupertypes;this.baseNames.forEach(ce=>{var se=b[ce];if(se instanceof ll)se.finalize(),k(M,se.allFields),k(K,se.allSupertypes);else{var Z="unknown supertype name "+JSON.stringify(ce)+" for subtype "+JSON.stringify(this.typeName);throw new Error(Z)}}),k(M,this.ownFields),K[this.typeName]=this,this.fieldNames.length=0;for(var W in M)wn.call(M,W)&&!M[W].hidden&&this.fieldNames.push(W);Object.defineProperty(T,this.typeName,{enumerable:!0,value:this.type}),this.finalized=!0,L(this.typeName,this.supertypeList),this.buildable&&this.supertypeList.lastIndexOf("Expression")>=0&&N(this.typeName)}}}function x(R){if(!wn.call(b,R))throw new Error("");var M=b[R];if(M.finalized!==!0)throw new Error("");return M.supertypeList.slice(1)}function D(R){for(var M={},K=Object.keys(b),W=K.length,ce=0;ce<W;++ce){var se=K[ce],Z=b[se];if(Z.finalized!==!0)throw new Error(""+se);for(var xt=0;xt<Z.supertypeList.length;++xt){var Le=Z.supertypeList[xt];if(wn.call(R,Le)){M[se]=Le;break}}}return M}var E=Object.create(null),S={};function F(R,M){var K=S[R];return m.check(M)?delete S[R]:(o.assert(M),Object.defineProperty(S,R,{enumerable:!0,configurable:!0,value:M})),K}function I(R){return R.replace(/^[A-Z]+/,function(M){var K=M.length;switch(K){case 0:return"";case 1:return M.toLowerCase();default:return M.slice(0,K-1).toLowerCase()+M.charAt(K-1)}})}function A(R){return R=I(R),R.replace(/(Expression)?$/,"Statement")}var T={};function G(R){var M=v(R);if(M)return M.fieldNames.slice(0);if("type"in R)throw new Error("did not recognize object of type "+JSON.stringify(R.type));return Object.keys(R)}function V(R,M){var K=v(R);if(K){var W=K.allFields[M];if(W)return W.getValue(R)}return R&&R[M]}function Y(R,M,K){G(R).forEach(function(W){M.call(this,W,V(R,W))},K)}function P(R,M,K){return G(R).some(function(W){return M.call(this,W,V(R,W))},K)}function N(R){var M=A(R);if(E[M])return;var K=E[I(R)];if(!K)return;let W=function(...ce){return E.expressionStatement(K.apply(E,ce))};W.from=function(...ce){return E.expressionStatement(K.from.apply(E,ce))},E[M]=W}function L(R,M){M.length=0,M.push(R);for(var K=Object.create(null),W=0;W<M.length;++W){R=M[W];var ce=b[R];if(ce.finalized!==!0)throw new Error("");wn.call(K,R)&&delete M[K[R]],K[R]=W,M.push.apply(M,ce.baseNames)}for(var se=0,Z=se,xt=M.length;Z<xt;++Z)wn.call(M,Z)&&(M[se++]=M[Z]);M.length=se}function k(R,M){return Object.keys(M).forEach(function(K){R[K]=M[K]}),R}function $(){Object.keys(b).forEach(function(R){b[R].finalize()})}return{Type:t,builtInTypes:y,getSupertypeNames:x,computeSupertypeLookupTable:D,builders:E,defineMethod:F,getBuilderName:I,getStatementBuilderName:A,namedTypes:T,getFieldNames:G,getFieldValue:V,eachField:Y,someField:P,finalize:$}}tt(()=>module);var XW=Object.prototype,yf=XW.hasOwnProperty;function x_(e){var t=e.use(Ft),r=t.builtInTypes.array,n=t.builtInTypes.number;let i=function p(d,h,m){if(!(this instanceof p))throw new Error("Path constructor cannot be invoked without 'new'");if(h){if(!(h instanceof p))throw new Error("")}else h=null,m=null;this.value=d,this.parentPath=h,this.name=m,this.__childCache=null};var s=i.prototype;function o(p){return p.__childCache||(p.__childCache=Object.create(null))}function a(p,d){var h=o(p),m=p.getValueProperty(d),g=h[d];return(!yf.call(h,d)||g.value!==m)&&(g=h[d]=new p.constructor(m,p,d)),g}s.getValueProperty=function(d){return this.value[d]},s.get=function(...d){for(var h=this,m=d.length,g=0;g<m;++g)h=a(h,d[g]);return h},s.each=function(d,h){for(var m=[],g=this.value.length,y=0,y=0;y<g;++y)yf.call(this.value,y)&&(m[y]=this.get(y));for(h=h||this,y=0;y<g;++y)yf.call(m,y)&&d.call(h,m[y])},s.map=function(d,h){var m=[];return this.each(function(g){m.push(d.call(this,g))},h),m},s.filter=function(d,h){var m=[];return this.each(function(g){d.call(this,g)&&m.push(g)},h),m};function c(){}function u(p,d,h,m){if(r.assert(p.value),d===0)return c;var g=p.value.length;if(g<1)return c;var y=arguments.length;y===2?(h=0,m=g):y===3?(h=Math.max(h,0),m=g):(h=Math.max(h,0),m=Math.min(m,g)),n.assert(h),n.assert(m);for(var b=Object.create(null),v=o(p),C=h;C<m;++C)if(yf.call(p.value,C)){var x=p.get(C);if(x.name!==C)throw new Error("");var D=C+d;x.name=D,b[D]=x,delete v[C]}return delete v.length,function(){for(var E in b){var S=b[E];if(S.name!==+E)throw new Error("");v[E]=S,p.value[E]=S.value}}}s.shift=function(){var d=u(this,-1),h=this.value.shift();return d(),h},s.unshift=function(...d){var h=u(this,d.length),m=this.value.unshift.apply(this.value,d);return h(),m},s.push=function(...d){return r.assert(this.value),delete o(this).length,this.value.push.apply(this.value,d)},s.pop=function(){r.assert(this.value);var d=o(this);return delete d[this.value.length-1],delete d.length,this.value.pop()},s.insertAt=function(d){var h=arguments.length,m=u(this,h-1,d);if(m===c&&h<=1)return this;d=Math.max(d,0);for(var g=1;g<h;++g)this.value[d+g-1]=arguments[g];return m(),this},s.insertBefore=function(...d){for(var h=this.parentPath,m=d.length,g=[this.name],y=0;y<m;++y)g.push(d[y]);return h.insertAt.apply(h,g)},s.insertAfter=function(...d){for(var h=this.parentPath,m=d.length,g=[this.name+1],y=0;y<m;++y)g.push(d[y]);return h.insertAt.apply(h,g)};function l(p){if(!(p instanceof i))throw new Error("");var d=p.parentPath;if(!d)return p;var h=d.value,m=o(d);if(h[p.name]===p.value)m[p.name]=p;else if(r.check(h)){var g=h.indexOf(p.value);g>=0&&(m[p.name=g]=p)}else h[p.name]=p.value,m[p.name]=p;if(h[p.name]!==p.value)throw new Error("");if(p.parentPath.get(p.name)!==p)throw new Error("");return p}return s.replace=function(d){var h=[],m=this.parentPath.value,g=o(this.parentPath),y=arguments.length;if(l(this),r.check(m)){for(var b=m.length,v=u(this.parentPath,y-1,this.name+1),C=[this.name,1],x=0;x<y;++x)C.push(arguments[x]);var D=m.splice.apply(m,C);if(D[0]!==this.value)throw new Error("");if(m.length!==b-1+y)throw new Error("");if(v(),y===0)delete this.value,delete g[this.name],this.__childCache=null;else{if(m[this.name]!==d)throw new Error("");for(this.value!==d&&(this.value=d,this.__childCache=null),x=0;x<y;++x)h.push(this.parentPath.get(this.name+x));if(h[0]!==this)throw new Error("")}}else if(y===1)this.value!==d&&(this.__childCache=null),this.value=m[this.name]=d,h.push(this);else if(y===0)delete m[this.name],delete this.value,this.__childCache=null;else throw new Error("Could not replace path");return h},i}tt(()=>module);var Qa=Object.prototype.hasOwnProperty;function QW(e){var t=e.use(Ft),r=t.Type,n=t.namedTypes,i=n.Node,s=n.Expression,o=t.builtInTypes.array,a=t.builders;let c=function x(D,E){if(!(this instanceof x))throw new Error("Scope constructor cannot be invoked without 'new'");l.check(D.value)||u.assert(D.value);var S;if(E){if(!(E instanceof x))throw new Error("");S=E.depth+1}else E=null,S=0;Object.defineProperties(this,{path:{value:D},node:{value:D.value},isGlobal:{value:!E,enumerable:!0},depth:{value:S},parent:{value:E},bindings:{value:{}},types:{value:{}}})};var u=r.or(n.Program,n.Function,n.CatchClause),l=r.or(n.Function,n.ClassDeclaration,n.ClassExpression,n.InterfaceDeclaration,n.TSInterfaceDeclaration,n.TypeAlias,n.TSTypeAliasDeclaration),p=r.or(n.TypeParameter,n.TSTypeParameter);c.isEstablishedBy=function(x){return u.check(x)||l.check(x)};var d=c.prototype;d.didScan=!1,d.declares=function(x){return this.scan(),Qa.call(this.bindings,x)},d.declaresType=function(x){return this.scan(),Qa.call(this.types,x)},d.declareTemporary=function(x){if(x){if(!/^[a-z$_]/i.test(x))throw new Error("")}else x="t$";x+=this.depth.toString(36)+"$",this.scan();for(var D=0;this.declares(x+D);)++D;var E=x+D;return this.bindings[E]=t.builders.identifier(E)},d.injectTemporary=function(x,D){x||(x=this.declareTemporary());var E=this.path.get("body");return n.BlockStatement.check(E.value)&&(E=E.get("body")),E.unshift(a.variableDeclaration("var",[a.variableDeclarator(x,D||null)])),x},d.scan=function(x){if(x||!this.didScan){for(var D in this.bindings)delete this.bindings[D];for(var D in this.types)delete this.types[D];h(this.path,this.bindings,this.types),this.didScan=!0}},d.getBindings=function(){return this.scan(),this.bindings},d.getTypes=function(){return this.scan(),this.types};function h(x,D,E){var S=x.value;if(l.check(S)){let F=x.get("typeParameters","params");o.check(F.value)&&F.each(I=>{C(I,E)})}u.check(S)&&(n.CatchClause.check(S)?b(x.get("param"),D):m(x,D,E))}function m(x,D,E){var S=x.value;x.parent&&n.FunctionExpression.check(x.parent.node)&&x.parent.node.id&&b(x.parent.get("id"),D),S&&(o.check(S)?x.each(F=>{y(F,D,E)}):n.Function.check(S)?(x.get("params").each(F=>{b(F,D)}),y(x.get("body"),D,E),m(x.get("typeParameters"),D,E)):n.TypeAlias&&n.TypeAlias.check(S)||n.InterfaceDeclaration&&n.InterfaceDeclaration.check(S)||n.TSTypeAliasDeclaration&&n.TSTypeAliasDeclaration.check(S)||n.TSInterfaceDeclaration&&n.TSInterfaceDeclaration.check(S)?v(x.get("id"),E):n.VariableDeclarator.check(S)?(b(x.get("id"),D),y(x.get("init"),D,E)):S.type==="ImportSpecifier"||S.type==="ImportNamespaceSpecifier"||S.type==="ImportDefaultSpecifier"?b(x.get(S.local?"local":S.name?"name":"id"),D):i.check(S)&&!s.check(S)&&t.eachField(S,function(F,I){var A=x.get(F);if(!g(A,I))throw new Error("");y(A,D,E)}))}function g(x,D){return!!(x.value===D||Array.isArray(x.value)&&x.value.length===0&&Array.isArray(D)&&D.length===0)}function y(x,D,E){var S=x.value;if(!(!S||s.check(S)))if(n.FunctionDeclaration.check(S)&&S.id!==null)b(x.get("id"),D);else if(n.ClassDeclaration&&n.ClassDeclaration.check(S)&&S.id!==null)b(x.get("id"),D),m(x.get("typeParameters"),D,E);else if(n.InterfaceDeclaration&&n.InterfaceDeclaration.check(S)||n.TSInterfaceDeclaration&&n.TSInterfaceDeclaration.check(S))v(x.get("id"),E);else if(u.check(S)){if(n.CatchClause.check(S)&&n.Identifier.check(S.param)){var F=S.param.name,I=Qa.call(D,F);m(x.get("body"),D,E),I||delete D[F]}}else m(x,D,E)}function b(x,D){var E=x.value;n.Pattern.assert(E),n.Identifier.check(E)?Qa.call(D,E.name)?D[E.name].push(x):D[E.name]=[x]:n.AssignmentPattern&&n.AssignmentPattern.check(E)?b(x.get("left"),D):n.ObjectPattern&&n.ObjectPattern.check(E)?x.get("properties").each(function(S){var F=S.value;n.Pattern.check(F)?b(S,D):n.Property.check(F)||n.ObjectProperty&&n.ObjectProperty.check(F)?b(S.get("value"),D):n.SpreadProperty&&n.SpreadProperty.check(F)&&b(S.get("argument"),D)}):n.ArrayPattern&&n.ArrayPattern.check(E)?x.get("elements").each(function(S){var F=S.value;n.Pattern.check(F)?b(S,D):n.SpreadElement&&n.SpreadElement.check(F)&&b(S.get("argument"),D)}):n.PropertyPattern&&n.PropertyPattern.check(E)?b(x.get("pattern"),D):(n.SpreadElementPattern&&n.SpreadElementPattern.check(E)||n.RestElement&&n.RestElement.check(E)||n.SpreadPropertyPattern&&n.SpreadPropertyPattern.check(E))&&b(x.get("argument"),D)}function v(x,D){var E=x.value;n.Pattern.assert(E),n.Identifier.check(E)&&(Qa.call(D,E.name)?D[E.name].push(x):D[E.name]=[x])}function C(x,D){var E=x.value;p.assert(E),Qa.call(D,E.name)?D[E.name].push(x):D[E.name]=[x]}return d.lookup=function(x){for(var D=this;D&&!D.declares(x);D=D.parent);return D},d.lookupType=function(x){for(var D=this;D&&!D.declaresType(x);D=D.parent);return D},d.getGlobalScope=function(){for(var x=this;!x.isGlobal;)x=x.parent;return x},c}tt(()=>module);function v_(e){var t=e.use(Ft),r=t.namedTypes,n=t.builders,i=t.builtInTypes.number,s=t.builtInTypes.array,o=e.use(x_),a=e.use(QW);let c=function y(b,v,C){if(!(this instanceof y))throw new Error("NodePath constructor cannot be invoked without 'new'");o.call(this,b,v,C)};var u=c.prototype=Object.create(o.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}});Object.defineProperties(u,{node:{get:function(){return Object.defineProperty(this,"node",{configurable:!0,value:this._computeNode()}),this.node}},parent:{get:function(){return Object.defineProperty(this,"parent",{configurable:!0,value:this._computeParent()}),this.parent}},scope:{get:function(){return Object.defineProperty(this,"scope",{configurable:!0,value:this._computeScope()}),this.scope}}}),u.replace=function(){return delete this.node,delete this.parent,delete this.scope,o.prototype.replace.apply(this,arguments)},u.prune=function(){var y=this.parent;return this.replace(),m(y)},u._computeNode=function(){var y=this.value;if(r.Node.check(y))return y;var b=this.parentPath;return b&&b.node||null},u._computeParent=function(){var y=this.value,b=this.parentPath;if(!r.Node.check(y)){for(;b&&!r.Node.check(b.value);)b=b.parentPath;b&&(b=b.parentPath)}for(;b&&!r.Node.check(b.value);)b=b.parentPath;return b||null},u._computeScope=function(){var y=this.value,b=this.parentPath,v=b&&b.scope;return r.Node.check(y)&&a.isEstablishedBy(y)&&(v=new a(this,v)),v||null},u.getValueProperty=function(y){return t.getFieldValue(this.value,y)},u.needsParens=function(y){var b=this.parentPath;if(!b)return!1;var v=this.value;if(!r.Expression.check(v)||v.type==="Identifier")return!1;for(;!r.Node.check(b.value);)if(b=b.parentPath,!b)return!1;var C=b.value;switch(v.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return C.type==="MemberExpression"&&this.name==="object"&&C.object===v;case"BinaryExpression":case"LogicalExpression":switch(C.type){case"CallExpression":return this.name==="callee"&&C.callee===v;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return!0;case"MemberExpression":return this.name==="object"&&C.object===v;case"BinaryExpression":case"LogicalExpression":{let x=v,D=C.operator,E=p[D],S=x.operator,F=p[S];if(E>F)return!0;if(E===F&&this.name==="right"){if(C.right!==x)throw new Error("Nodes must be equal");return!0}}default:return!1}case"SequenceExpression":switch(C.type){case"ForStatement":return!1;case"ExpressionStatement":return this.name!=="expression";default:return!0}case"YieldExpression":switch(C.type){case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"CallExpression":case"MemberExpression":case"NewExpression":case"ConditionalExpression":case"YieldExpression":return!0;default:return!1}case"Literal":return C.type==="MemberExpression"&&i.check(v.value)&&this.name==="object"&&C.object===v;case"AssignmentExpression":case"ConditionalExpression":switch(C.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return!0;case"CallExpression":return this.name==="callee"&&C.callee===v;case"ConditionalExpression":return this.name==="test"&&C.test===v;case"MemberExpression":return this.name==="object"&&C.object===v;default:return!1}default:if(C.type==="NewExpression"&&this.name==="callee"&&C.callee===v)return d(v)}return!!(y!==!0&&!this.canBeFirstInStatement()&&this.firstInStatement())};function l(y){return r.BinaryExpression.check(y)||r.LogicalExpression.check(y)}var p={};[["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]].forEach(function(y,b){y.forEach(function(v){p[v]=b})});function d(y){return r.CallExpression.check(y)?!0:s.check(y)?y.some(d):r.Node.check(y)?t.someField(y,function(b,v){return d(v)}):!1}u.canBeFirstInStatement=function(){var y=this.node;return!r.FunctionExpression.check(y)&&!r.ObjectExpression.check(y)},u.firstInStatement=function(){return h(this)};function h(y){for(var b,v;y.parent;y=y.parent){if(b=y.node,v=y.parent.node,r.BlockStatement.check(v)&&y.parent.name==="body"&&y.name===0){if(v.body[0]!==b)throw new Error("Nodes must be equal");return!0}if(r.ExpressionStatement.check(v)&&y.name==="expression"){if(v.expression!==b)throw new Error("Nodes must be equal");return!0}if(r.SequenceExpression.check(v)&&y.parent.name==="expressions"&&y.name===0){if(v.expressions[0]!==b)throw new Error("Nodes must be equal");continue}if(r.CallExpression.check(v)&&y.name==="callee"){if(v.callee!==b)throw new Error("Nodes must be equal");continue}if(r.MemberExpression.check(v)&&y.name==="object"){if(v.object!==b)throw new Error("Nodes must be equal");continue}if(r.ConditionalExpression.check(v)&&y.name==="test"){if(v.test!==b)throw new Error("Nodes must be equal");continue}if(l(v)&&y.name==="left"){if(v.left!==b)throw new Error("Nodes must be equal");continue}if(r.UnaryExpression.check(v)&&!v.prefix&&y.name==="argument"){if(v.argument!==b)throw new Error("Nodes must be equal");continue}return!1}return!0}function m(y){if(r.VariableDeclaration.check(y.node)){var b=y.get("declarations").value;if(!b||b.length===0)return y.prune()}else if(r.ExpressionStatement.check(y.node)){if(!y.get("expression").value)return y.prune()}else r.IfStatement.check(y.node)&&g(y);return y}function g(y){var b=y.get("test").value,v=y.get("alternate").value,C=y.get("consequent").value;if(!C&&!v){var x=n.expressionStatement(b);y.replace(x)}else if(!C&&v){var D=n.unaryExpression("!",b,!0);r.UnaryExpression.check(b)&&b.operator==="!"&&(D=b.argument),y.get("test").replace(D),y.get("consequent").replace(v),y.get("alternate").replace()}}return c}tt(()=>module);var bf=Object.prototype.hasOwnProperty;function ZW(e){var t=e.use(Ft),r=e.use(v_),n=t.builtInTypes.array,i=t.builtInTypes.object,s=t.builtInTypes.function,o;let a=function m(){if(!(this instanceof m))throw new Error("PathVisitor constructor cannot be invoked without 'new'");this._reusableContextStack=[],this._methodNameTable=c(this),this._shouldVisitComments=bf.call(this._methodNameTable,"Block")||bf.call(this._methodNameTable,"Line"),this.Context=d(this),this._visiting=!1,this._changeReported=!1};function c(m){var g=Object.create(null);for(var y in m)/^visit[A-Z]/.test(y)&&(g[y.slice(5)]=!0);for(var b=t.computeSupertypeLookupTable(g),v=Object.create(null),C=Object.keys(b),x=C.length,D=0;D<x;++D){var E=C[D];y="visit"+b[E],s.check(m[y])&&(v[E]=y)}return v}a.fromMethodsObject=function(g){if(g instanceof a)return g;if(!i.check(g))return new a;let y=function v(){if(!(this instanceof v))throw new Error("Visitor constructor cannot be invoked without 'new'");a.call(this)};var b=y.prototype=Object.create(l);return b.constructor=y,u(b,g),u(y,a),s.assert(y.fromMethodsObject),s.assert(y.visit),new y};function u(m,g){for(var y in g)bf.call(g,y)&&(m[y]=g[y]);return m}a.visit=function(g,y){return a.fromMethodsObject(y).visit(g)};var l=a.prototype;l.visit=function(){if(this._visiting)throw new Error("Recursively calling visitor.visit(path) resets visitor state. Try this.visit(path) or this.traverse(path) instead.");this._visiting=!0,this._changeReported=!1,this._abortRequested=!1;for(var m=arguments.length,g=new Array(m),y=0;y<m;++y)g[y]=arguments[y];g[0]instanceof r||(g[0]=new r({root:g[0]}).get("root")),this.reset.apply(this,g);var b;try{var v=this.visitWithoutReset(g[0]);b=!0}finally{if(this._visiting=!1,!b&&this._abortRequested)return g[0].value}return v},l.AbortRequest=function(){},l.abort=function(){var m=this;m._abortRequested=!0;var g=new m.AbortRequest;throw g.cancel=function(){m._abortRequested=!1},g},l.reset=function(m){},l.visitWithoutReset=function(m){if(this instanceof this.Context)return this.visitor.visitWithoutReset(m);if(!(m instanceof r))throw new Error("");var g=m.value,y=g&&typeof g=="object"&&typeof g.type=="string"&&this._methodNameTable[g.type];if(y){var b=this.acquireContext(m);try{return b.invokeVisitorMethod(y)}finally{this.releaseContext(b)}}else return p(m,this)};function p(m,g){if(!(m instanceof r))throw new Error("");if(!(g instanceof a))throw new Error("");var y=m.value;if(n.check(y))m.each(g.visitWithoutReset,g);else if(i.check(y)){var b=t.getFieldNames(y);g._shouldVisitComments&&y.comments&&b.indexOf("comments")<0&&b.push("comments");for(var v=b.length,C=[],x=0;x<v;++x){var D=b[x];bf.call(y,D)||(y[D]=t.getFieldValue(y,D)),C.push(m.get(D))}for(var x=0;x<v;++x)g.visitWithoutReset(C[x])}return m.value}l.acquireContext=function(m){return this._reusableContextStack.length===0?new this.Context(m):this._reusableContextStack.pop().reset(m)},l.releaseContext=function(m){if(!(m instanceof this.Context))throw new Error("");this._reusableContextStack.push(m),m.currentPath=null},l.reportChanged=function(){this._changeReported=!0},l.wasChangeReported=function(){return this._changeReported};function d(m){function g(b){if(!(this instanceof g))throw new Error("");if(!(this instanceof a))throw new Error("");if(!(b instanceof r))throw new Error("");Object.defineProperty(this,"visitor",{value:m,writable:!1,enumerable:!0,configurable:!1}),this.currentPath=b,this.needToCallTraverse=!0,Object.seal(this)}if(!(m instanceof a))throw new Error("");var y=g.prototype=Object.create(m);return y.constructor=g,u(y,h),g}var h=Object.create(null);return h.reset=function(g){if(!(this instanceof this.Context))throw new Error("");if(!(g instanceof r))throw new Error("");return this.currentPath=g,this.needToCallTraverse=!0,this},h.invokeVisitorMethod=function(g){if(!(this instanceof this.Context))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");var y=this.visitor[g].call(this,this.currentPath);if(y===!1?this.needToCallTraverse=!1:y!==o&&(this.currentPath=this.currentPath.replace(y)[0],this.needToCallTraverse&&this.traverse(this.currentPath)),this.needToCallTraverse!==!1)throw new Error("Must either call this.traverse or return false in "+g);var b=this.currentPath;return b&&b.value},h.traverse=function(g,y){if(!(this instanceof this.Context))throw new Error("");if(!(g instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,p(g,a.fromMethodsObject(y||this.visitor))},h.visit=function(g,y){if(!(this instanceof this.Context))throw new Error("");if(!(g instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,a.fromMethodsObject(y||this.visitor).visitWithoutReset(g)},h.reportChanged=function(){this.visitor.reportChanged()},h.abort=function(){this.needToCallTraverse=!1,this.visitor.abort()},a}tt(()=>module);function eY(e){var t=e.use(Ft),r=t.getFieldNames,n=t.getFieldValue,i=t.builtInTypes.array,s=t.builtInTypes.object,o=t.builtInTypes.Date,a=t.builtInTypes.RegExp,c=Object.prototype.hasOwnProperty;function u(m,g,y){return i.check(y)?y.length=0:y=null,p(m,g,y)}u.assert=function(m,g){var y=[];if(!u(m,g,y))if(y.length===0){if(m!==g)throw new Error("Nodes must be equal")}else throw new Error("Nodes differ in the following path: "+y.map(l).join(""))};function l(m){return/[_$a-z][_$a-z0-9]*/i.test(m)?"."+m:"["+JSON.stringify(m)+"]"}function p(m,g,y){return m===g?!0:i.check(m)?d(m,g,y):s.check(m)?h(m,g,y):o.check(m)?o.check(g)&&+m==+g:a.check(m)?a.check(g)&&m.source===g.source&&m.global===g.global&&m.multiline===g.multiline&&m.ignoreCase===g.ignoreCase:m==g}function d(m,g,y){i.assert(m);var b=m.length;if(!i.check(g)||g.length!==b)return y&&y.push("length"),!1;for(var v=0;v<b;++v){if(y&&y.push(v),v in m!=v in g||!p(m[v],g[v],y))return!1;if(y){var C=y.pop();if(C!==v)throw new Error(""+C)}}return!0}function h(m,g,y){if(s.assert(m),!s.check(g))return!1;if(m.type!==g.type)return y&&y.push("type"),!1;var b=r(m),v=b.length,C=r(g),x=C.length;if(v===x){for(var D=0;D<v;++D){var E=b[D],S=n(m,E),F=n(g,E);if(y&&y.push(E),!p(S,F,y))return!1;if(y){var I=y.pop();if(I!==E)throw new Error(""+I)}}return!0}if(!y)return!1;var A=Object.create(null);for(D=0;D<v;++D)A[b[D]]=!0;for(D=0;D<x;++D){if(E=C[D],!c.call(A,E))return y.push(E),!1;delete A[E]}for(E in A){y.push(E);break}return!1}return u}tt(()=>module);function tY(e){let t=rY(),r=t.use(Ft);e.forEach(t.use),r.finalize();let n=t.use(ZW);return{Type:r.Type,builtInTypes:r.builtInTypes,namedTypes:r.namedTypes,builders:r.builders,defineMethod:r.defineMethod,getFieldNames:r.getFieldNames,getFieldValue:r.getFieldValue,eachField:r.eachField,someField:r.someField,getSupertypeNames:r.getSupertypeNames,getBuilderName:r.getBuilderName,astNodesAreEquivalent:t.use(eY),finalize:r.finalize,Path:t.use(x_),NodePath:t.use(v_),PathVisitor:n,use:t.use,visit:n.visit}}function rY(){let e=[],t=[];function r(i){var s=e.indexOf(i);return s===-1&&(s=e.length,e.push(i),t[s]=i(n)),t[s]}var n={use:r};return n}tt(()=>module);function D_(){return{BinaryOperators:["==","!=","===","!==","<","<=",">",">=","<<",">>",">>>","+","-","*","/","%","&","|","^","in","instanceof"],AssignmentOperators:["=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","|=","^=","&="],LogicalOperators:["||","&&"]}}tt(()=>module);function C_(e){let t=e.use(D_);return t.BinaryOperators.indexOf("**")<0&&t.BinaryOperators.push("**"),t.AssignmentOperators.indexOf("**=")<0&&t.AssignmentOperators.push("**="),t}tt(()=>module);function E_(e){let t=e.use(C_);return t.LogicalOperators.indexOf("??")<0&&t.LogicalOperators.push("??"),t}tt(()=>module);function nY(e){let t=e.use(E_);return t.LogicalOperators.forEach(r=>{let n=r+"=";t.AssignmentOperators.indexOf(n)<0&&t.AssignmentOperators.push(n)}),t}tt(()=>module);function iY(e){var t=e.use(Ft),r=t.Type,n=r.def,i=r.or,s=e.use(cn),o=s.defaults,a=s.geq;let{BinaryOperators:c,AssignmentOperators:u,LogicalOperators:l}=e.use(D_);n("Printable").field("loc",i(n("SourceLocation"),null),o.null,!0),n("Node").bases("Printable").field("type",String).field("comments",i([n("Comment")],null),o.null,!0),n("SourceLocation").field("start",n("Position")).field("end",n("Position")).field("source",i(String,null),o.null),n("Position").field("line",a(1)).field("column",a(0)),n("File").bases("Node").build("program","name").field("program",n("Program")).field("name",i(String,null),o.null),n("Program").bases("Node").build("body").field("body",[n("Statement")]),n("Function").bases("Node").field("id",i(n("Identifier"),null),o.null).field("params",[n("Pattern")]).field("body",n("BlockStatement")).field("generator",Boolean,o.false).field("async",Boolean,o.false),n("Statement").bases("Node"),n("EmptyStatement").bases("Statement").build(),n("BlockStatement").bases("Statement").build("body").field("body",[n("Statement")]),n("ExpressionStatement").bases("Statement").build("expression").field("expression",n("Expression")),n("IfStatement").bases("Statement").build("test","consequent","alternate").field("test",n("Expression")).field("consequent",n("Statement")).field("alternate",i(n("Statement"),null),o.null),n("LabeledStatement").bases("Statement").build("label","body").field("label",n("Identifier")).field("body",n("Statement")),n("BreakStatement").bases("Statement").build("label").field("label",i(n("Identifier"),null),o.null),n("ContinueStatement").bases("Statement").build("label").field("label",i(n("Identifier"),null),o.null),n("WithStatement").bases("Statement").build("object","body").field("object",n("Expression")).field("body",n("Statement")),n("SwitchStatement").bases("Statement").build("discriminant","cases","lexical").field("discriminant",n("Expression")).field("cases",[n("SwitchCase")]).field("lexical",Boolean,o.false),n("ReturnStatement").bases("Statement").build("argument").field("argument",i(n("Expression"),null)),n("ThrowStatement").bases("Statement").build("argument").field("argument",n("Expression")),n("TryStatement").bases("Statement").build("block","handler","finalizer").field("block",n("BlockStatement")).field("handler",i(n("CatchClause"),null),function(){return this.handlers&&this.handlers[0]||null}).field("handlers",[n("CatchClause")],function(){return this.handler?[this.handler]:[]},!0).field("guardedHandlers",[n("CatchClause")],o.emptyArray).field("finalizer",i(n("BlockStatement"),null),o.null),n("CatchClause").bases("Node").build("param","guard","body").field("param",n("Pattern")).field("guard",i(n("Expression"),null),o.null).field("body",n("BlockStatement")),n("WhileStatement").bases("Statement").build("test","body").field("test",n("Expression")).field("body",n("Statement")),n("DoWhileStatement").bases("Statement").build("body","test").field("body",n("Statement")).field("test",n("Expression")),n("ForStatement").bases("Statement").build("init","test","update","body").field("init",i(n("VariableDeclaration"),n("Expression"),null)).field("test",i(n("Expression"),null)).field("update",i(n("Expression"),null)).field("body",n("Statement")),n("ForInStatement").bases("Statement").build("left","right","body").field("left",i(n("VariableDeclaration"),n("Expression"))).field("right",n("Expression")).field("body",n("Statement")),n("DebuggerStatement").bases("Statement").build(),n("Declaration").bases("Statement"),n("FunctionDeclaration").bases("Function","Declaration").build("id","params","body").field("id",n("Identifier")),n("FunctionExpression").bases("Function","Expression").build("id","params","body"),n("VariableDeclaration").bases("Declaration").build("kind","declarations").field("kind",i("var","let","const")).field("declarations",[n("VariableDeclarator")]),n("VariableDeclarator").bases("Node").build("id","init").field("id",n("Pattern")).field("init",i(n("Expression"),null),o.null),n("Expression").bases("Node"),n("ThisExpression").bases("Expression").build(),n("ArrayExpression").bases("Expression").build("elements").field("elements",[i(n("Expression"),null)]),n("ObjectExpression").bases("Expression").build("properties").field("properties",[n("Property")]),n("Property").bases("Node").build("kind","key","value").field("kind",i("init","get","set")).field("key",i(n("Literal"),n("Identifier"))).field("value",n("Expression")),n("SequenceExpression").bases("Expression").build("expressions").field("expressions",[n("Expression")]);var p=i("-","+","!","~","typeof","void","delete");n("UnaryExpression").bases("Expression").build("operator","argument","prefix").field("operator",p).field("argument",n("Expression")).field("prefix",Boolean,o.true);let d=i(...c);n("BinaryExpression").bases("Expression").build("operator","left","right").field("operator",d).field("left",n("Expression")).field("right",n("Expression"));let h=i(...u);n("AssignmentExpression").bases("Expression").build("operator","left","right").field("operator",h).field("left",i(n("Pattern"),n("MemberExpression"))).field("right",n("Expression"));var m=i("++","--");n("UpdateExpression").bases("Expression").build("operator","argument","prefix").field("operator",m).field("argument",n("Expression")).field("prefix",Boolean);var g=i(...l);n("LogicalExpression").bases("Expression").build("operator","left","right").field("operator",g).field("left",n("Expression")).field("right",n("Expression")),n("ConditionalExpression").bases("Expression").build("test","consequent","alternate").field("test",n("Expression")).field("consequent",n("Expression")).field("alternate",n("Expression")),n("NewExpression").bases("Expression").build("callee","arguments").field("callee",n("Expression")).field("arguments",[n("Expression")]),n("CallExpression").bases("Expression").build("callee","arguments").field("callee",n("Expression")).field("arguments",[n("Expression")]),n("MemberExpression").bases("Expression").build("object","property","computed").field("object",n("Expression")).field("property",i(n("Identifier"),n("Expression"))).field("computed",Boolean,function(){var y=this.property.type;return y==="Literal"||y==="MemberExpression"||y==="BinaryExpression"}),n("Pattern").bases("Node"),n("SwitchCase").bases("Node").build("test","consequent").field("test",i(n("Expression"),null)).field("consequent",[n("Statement")]),n("Identifier").bases("Expression","Pattern").build("name").field("name",String).field("optional",Boolean,o.false),n("Literal").bases("Expression").build("value").field("value",i(String,Boolean,null,Number,RegExp,BigInt)),n("Comment").bases("Printable").field("value",String).field("leading",Boolean,o.true).field("trailing",Boolean,o.false)}tt(()=>module);function sY(e){e.use(iY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("Function").field("generator",Boolean,i.false).field("expression",Boolean,i.false).field("defaults",[n(r("Expression"),null)],i.emptyArray).field("rest",n(r("Identifier"),null),i.null),r("RestElement").bases("Pattern").build("argument").field("argument",r("Pattern")).field("typeAnnotation",n(r("TypeAnnotation"),r("TSTypeAnnotation"),null),i.null),r("SpreadElementPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("FunctionDeclaration").build("id","params","body","generator","expression").field("id",n(r("Identifier"),null)),r("FunctionExpression").build("id","params","body","generator","expression"),r("ArrowFunctionExpression").bases("Function","Expression").build("params","body","expression").field("id",null,i.null).field("body",n(r("BlockStatement"),r("Expression"))).field("generator",!1,i.false),r("ForOfStatement").bases("Statement").build("left","right","body").field("left",n(r("VariableDeclaration"),r("Pattern"))).field("right",r("Expression")).field("body",r("Statement")),r("YieldExpression").bases("Expression").build("argument","delegate").field("argument",n(r("Expression"),null)).field("delegate",Boolean,i.false),r("GeneratorExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",n(r("Expression"),null)),r("ComprehensionExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",n(r("Expression"),null)),r("ComprehensionBlock").bases("Node").build("left","right","each").field("left",r("Pattern")).field("right",r("Expression")).field("each",Boolean),r("Property").field("key",n(r("Literal"),r("Identifier"),r("Expression"))).field("value",n(r("Expression"),r("Pattern"))).field("method",Boolean,i.false).field("shorthand",Boolean,i.false).field("computed",Boolean,i.false),r("ObjectProperty").field("shorthand",Boolean,i.false),r("PropertyPattern").bases("Pattern").build("key","pattern").field("key",n(r("Literal"),r("Identifier"),r("Expression"))).field("pattern",r("Pattern")).field("computed",Boolean,i.false),r("ObjectPattern").bases("Pattern").build("properties").field("properties",[n(r("PropertyPattern"),r("Property"))]),r("ArrayPattern").bases("Pattern").build("elements").field("elements",[n(r("Pattern"),null)]),r("SpreadElement").bases("Node").build("argument").field("argument",r("Expression")),r("ArrayExpression").field("elements",[n(r("Expression"),r("SpreadElement"),r("RestElement"),null)]),r("NewExpression").field("arguments",[n(r("Expression"),r("SpreadElement"))]),r("CallExpression").field("arguments",[n(r("Expression"),r("SpreadElement"))]),r("AssignmentPattern").bases("Pattern").build("left","right").field("left",r("Pattern")).field("right",r("Expression")),r("MethodDefinition").bases("Declaration").build("kind","key","value","static").field("kind",n("constructor","method","get","set")).field("key",r("Expression")).field("value",r("Function")).field("computed",Boolean,i.false).field("static",Boolean,i.false);let s=n(r("MethodDefinition"),r("VariableDeclarator"),r("ClassPropertyDefinition"),r("ClassProperty"),r("StaticBlock"));r("ClassProperty").bases("Declaration").build("key").field("key",n(r("Literal"),r("Identifier"),r("Expression"))).field("computed",Boolean,i.false),r("ClassPropertyDefinition").bases("Declaration").build("definition").field("definition",s),r("ClassBody").bases("Declaration").build("body").field("body",[s]),r("ClassDeclaration").bases("Declaration").build("id","body","superClass").field("id",n(r("Identifier"),null)).field("body",r("ClassBody")).field("superClass",n(r("Expression"),null),i.null),r("ClassExpression").bases("Expression").build("id","body","superClass").field("id",n(r("Identifier"),null),i.null).field("body",r("ClassBody")).field("superClass",n(r("Expression"),null),i.null),r("Super").bases("Expression").build(),r("Specifier").bases("Node"),r("ModuleSpecifier").bases("Specifier").field("local",n(r("Identifier"),null),i.null).field("id",n(r("Identifier"),null),i.null).field("name",n(r("Identifier"),null),i.null),r("ImportSpecifier").bases("ModuleSpecifier").build("imported","local").field("imported",r("Identifier")),r("ImportDefaultSpecifier").bases("ModuleSpecifier").build("local"),r("ImportNamespaceSpecifier").bases("ModuleSpecifier").build("local"),r("ImportDeclaration").bases("Declaration").build("specifiers","source","importKind").field("specifiers",[n(r("ImportSpecifier"),r("ImportNamespaceSpecifier"),r("ImportDefaultSpecifier"))],i.emptyArray).field("source",r("Literal")).field("importKind",n("value","type"),function(){return"value"}),r("ExportNamedDeclaration").bases("Declaration").build("declaration","specifiers","source").field("declaration",n(r("Declaration"),null)).field("specifiers",[r("ExportSpecifier")],i.emptyArray).field("source",n(r("Literal"),null),i.null),r("ExportSpecifier").bases("ModuleSpecifier").build("local","exported").field("exported",r("Identifier")),r("ExportDefaultDeclaration").bases("Declaration").build("declaration").field("declaration",n(r("Declaration"),r("Expression"))),r("ExportAllDeclaration").bases("Declaration").build("source").field("source",r("Literal")),r("TaggedTemplateExpression").bases("Expression").build("tag","quasi").field("tag",r("Expression")).field("quasi",r("TemplateLiteral")),r("TemplateLiteral").bases("Expression").build("quasis","expressions").field("quasis",[r("TemplateElement")]).field("expressions",[r("Expression")]),r("TemplateElement").bases("Node").build("value","tail").field("value",{cooked:String,raw:String}).field("tail",Boolean),r("MetaProperty").bases("Expression").build("meta","property").field("meta",r("Identifier")).field("property",r("Identifier"))}tt(()=>module);function oY(e){e.use(C_),e.use(sY)}tt(()=>module);function aY(e){e.use(oY);let r=e.use(Ft).Type.def,n=e.use(cn).defaults;r("Function").field("async",Boolean,n.false),r("AwaitExpression").bases("Expression").build("argument").field("argument",r("Expression"))}tt(()=>module);function cY(e){e.use(aY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("ForOfStatement").field("await",Boolean,i.false),r("SpreadProperty").bases("Node").build("argument").field("argument",r("Expression")),r("ObjectExpression").field("properties",[n(r("Property"),r("SpreadProperty"),r("SpreadElement"))]),r("TemplateElement").field("value",{cooked:n(String,null),raw:String}),r("SpreadPropertyPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("ObjectPattern").field("properties",[n(r("PropertyPattern"),r("Property"),r("RestElement"),r("SpreadPropertyPattern"))])}tt(()=>module);function uY(e){e.use(cY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("CatchClause").field("param",n(r("Pattern"),null),i.null)}tt(()=>module);function lY(e){e.use(E_),e.use(uY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,s=e.use(cn).defaults;r("ImportExpression").bases("Expression").build("source").field("source",r("Expression")),r("ExportAllDeclaration").bases("Declaration").build("source","exported").field("source",r("Literal")).field("exported",n(r("Identifier"),null,void 0),s.null),r("ChainElement").bases("Node").field("optional",Boolean,s.false),r("CallExpression").bases("Expression","ChainElement"),r("MemberExpression").bases("Expression","ChainElement"),r("ChainExpression").bases("Expression").build("expression").field("expression",r("ChainElement")),r("OptionalCallExpression").bases("CallExpression").build("callee","arguments","optional").field("optional",Boolean,s.true),r("OptionalMemberExpression").bases("MemberExpression").build("object","property","computed","optional").field("optional",Boolean,s.true)}tt(()=>module);function pY(e){e.use(nY),e.use(lY)}tt(()=>module);function dY(e){e.use(pY);let r=e.use(Ft).Type.def;r("StaticBlock").bases("Declaration").build("body").field("body",[r("Statement")])}tt(()=>module);function gl(e){e.use(dY);let t=e.use(Ft),r=t.Type,n=t.Type.def,i=r.or,o=e.use(cn).defaults;n("AwaitExpression").build("argument","all").field("argument",i(n("Expression"),null)).field("all",Boolean,o.false),n("Decorator").bases("Node").build("expression").field("expression",n("Expression")),n("Property").field("decorators",i([n("Decorator")],null),o.null),n("MethodDefinition").field("decorators",i([n("Decorator")],null),o.null),n("PrivateName").bases("Expression","Pattern").build("id").field("id",n("Identifier")),n("ClassPrivateProperty").bases("ClassProperty").build("key","value").field("key",n("PrivateName")).field("value",i(n("Expression"),null),o.null),n("ImportAttribute").bases("Node").build("key","value").field("key",i(n("Identifier"),n("Literal"))).field("value",n("Expression")),["ImportDeclaration","ExportAllDeclaration","ExportNamedDeclaration"].forEach(a=>{n(a).field("assertions",[n("ImportAttribute")],o.emptyArray)}),n("RecordExpression").bases("Expression").build("properties").field("properties",[i(n("ObjectProperty"),n("ObjectMethod"),n("SpreadElement"))]),n("TupleExpression").bases("Expression").build("elements").field("elements",[i(n("Expression"),n("SpreadElement"),null)]),n("ModuleExpression").bases("Node").build("body").field("body",n("Program"))}tt(()=>module);function fY(e){e.use(gl);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("JSXAttribute").bases("Node").build("name","value").field("name",n(r("JSXIdentifier"),r("JSXNamespacedName"))).field("value",n(r("Literal"),r("JSXExpressionContainer"),r("JSXElement"),r("JSXFragment"),null),i.null),r("JSXIdentifier").bases("Identifier").build("name").field("name",String),r("JSXNamespacedName").bases("Node").build("namespace","name").field("namespace",r("JSXIdentifier")).field("name",r("JSXIdentifier")),r("JSXMemberExpression").bases("MemberExpression").build("object","property").field("object",n(r("JSXIdentifier"),r("JSXMemberExpression"))).field("property",r("JSXIdentifier")).field("computed",Boolean,i.false);let s=n(r("JSXIdentifier"),r("JSXNamespacedName"),r("JSXMemberExpression"));r("JSXSpreadAttribute").bases("Node").build("argument").field("argument",r("Expression"));let o=[n(r("JSXAttribute"),r("JSXSpreadAttribute"))];r("JSXExpressionContainer").bases("Expression").build("expression").field("expression",n(r("Expression"),r("JSXEmptyExpression")));let a=[n(r("JSXText"),r("JSXExpressionContainer"),r("JSXSpreadChild"),r("JSXElement"),r("JSXFragment"),r("Literal"))];r("JSXElement").bases("Expression").build("openingElement","closingElement","children").field("openingElement",r("JSXOpeningElement")).field("closingElement",n(r("JSXClosingElement"),null),i.null).field("children",a,i.emptyArray).field("name",s,function(){return this.openingElement.name},!0).field("selfClosing",Boolean,function(){return this.openingElement.selfClosing},!0).field("attributes",o,function(){return this.openingElement.attributes},!0),r("JSXOpeningElement").bases("Node").build("name","attributes","selfClosing").field("name",s).field("attributes",o,i.emptyArray).field("selfClosing",Boolean,i.false),r("JSXClosingElement").bases("Node").build("name").field("name",s),r("JSXFragment").bases("Expression").build("openingFragment","closingFragment","children").field("openingFragment",r("JSXOpeningFragment")).field("closingFragment",r("JSXClosingFragment")).field("children",a,i.emptyArray),r("JSXOpeningFragment").bases("Node").build(),r("JSXClosingFragment").bases("Node").build(),r("JSXText").bases("Literal").build("value","raw").field("value",String).field("raw",String,function(){return this.value}),r("JSXEmptyExpression").bases("Node").build(),r("JSXSpreadChild").bases("Node").build("expression").field("expression",r("Expression"))}tt(()=>module);function w_(e){var t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults,s=n(r("TypeAnnotation"),r("TSTypeAnnotation"),null),o=n(r("TypeParameterDeclaration"),r("TSTypeParameterDeclaration"),null);r("Identifier").field("typeAnnotation",s,i.null),r("ObjectPattern").field("typeAnnotation",s,i.null),r("Function").field("returnType",s,i.null).field("typeParameters",o,i.null),r("ClassProperty").build("key","value","typeAnnotation","static").field("value",n(r("Expression"),null)).field("static",Boolean,i.false).field("typeAnnotation",s,i.null),["ClassDeclaration","ClassExpression"].forEach(a=>{r(a).field("typeParameters",o,i.null).field("superTypeParameters",n(r("TypeParameterInstantiation"),r("TSTypeParameterInstantiation"),null),i.null).field("implements",n([r("ClassImplements")],[r("TSExpressionWithTypeArguments")]),i.emptyArray)})}tt(()=>module);function S_(e){e.use(gl),e.use(w_);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("Flow").bases("Node"),r("FlowType").bases("Flow"),r("AnyTypeAnnotation").bases("FlowType").build(),r("EmptyTypeAnnotation").bases("FlowType").build(),r("MixedTypeAnnotation").bases("FlowType").build(),r("VoidTypeAnnotation").bases("FlowType").build(),r("SymbolTypeAnnotation").bases("FlowType").build(),r("NumberTypeAnnotation").bases("FlowType").build(),r("BigIntTypeAnnotation").bases("FlowType").build(),r("NumberLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("NumericLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("BigIntLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",null).field("raw",String),r("StringTypeAnnotation").bases("FlowType").build(),r("StringLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",String).field("raw",String),r("BooleanTypeAnnotation").bases("FlowType").build(),r("BooleanLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Boolean).field("raw",String),r("TypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullableTypeAnnotation").bases("FlowType").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullLiteralTypeAnnotation").bases("FlowType").build(),r("NullTypeAnnotation").bases("FlowType").build(),r("ThisTypeAnnotation").bases("FlowType").build(),r("ExistsTypeAnnotation").bases("FlowType").build(),r("ExistentialTypeParam").bases("FlowType").build(),r("FunctionTypeAnnotation").bases("FlowType").build("params","returnType","rest","typeParameters").field("params",[r("FunctionTypeParam")]).field("returnType",r("FlowType")).field("rest",n(r("FunctionTypeParam"),null)).field("typeParameters",n(r("TypeParameterDeclaration"),null)),r("FunctionTypeParam").bases("Node").build("name","typeAnnotation","optional").field("name",n(r("Identifier"),null)).field("typeAnnotation",r("FlowType")).field("optional",Boolean),r("ArrayTypeAnnotation").bases("FlowType").build("elementType").field("elementType",r("FlowType")),r("ObjectTypeAnnotation").bases("FlowType").build("properties","indexers","callProperties").field("properties",[n(r("ObjectTypeProperty"),r("ObjectTypeSpreadProperty"))]).field("indexers",[r("ObjectTypeIndexer")],i.emptyArray).field("callProperties",[r("ObjectTypeCallProperty")],i.emptyArray).field("inexact",n(Boolean,void 0),i.undefined).field("exact",Boolean,i.false).field("internalSlots",[r("ObjectTypeInternalSlot")],i.emptyArray),r("Variance").bases("Node").build("kind").field("kind",n("plus","minus"));let s=n(r("Variance"),"plus","minus",null);r("ObjectTypeProperty").bases("Node").build("key","value","optional").field("key",n(r("Literal"),r("Identifier"))).field("value",r("FlowType")).field("optional",Boolean).field("variance",s,i.null),r("ObjectTypeIndexer").bases("Node").build("id","key","value").field("id",r("Identifier")).field("key",r("FlowType")).field("value",r("FlowType")).field("variance",s,i.null).field("static",Boolean,i.false),r("ObjectTypeCallProperty").bases("Node").build("value").field("value",r("FunctionTypeAnnotation")).field("static",Boolean,i.false),r("QualifiedTypeIdentifier").bases("Node").build("qualification","id").field("qualification",n(r("Identifier"),r("QualifiedTypeIdentifier"))).field("id",r("Identifier")),r("GenericTypeAnnotation").bases("FlowType").build("id","typeParameters").field("id",n(r("Identifier"),r("QualifiedTypeIdentifier"))).field("typeParameters",n(r("TypeParameterInstantiation"),null)),r("MemberTypeAnnotation").bases("FlowType").build("object","property").field("object",r("Identifier")).field("property",n(r("MemberTypeAnnotation"),r("GenericTypeAnnotation"))),r("IndexedAccessType").bases("FlowType").build("objectType","indexType").field("objectType",r("FlowType")).field("indexType",r("FlowType")),r("OptionalIndexedAccessType").bases("FlowType").build("objectType","indexType","optional").field("objectType",r("FlowType")).field("indexType",r("FlowType")).field("optional",Boolean),r("UnionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("IntersectionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("TypeofTypeAnnotation").bases("FlowType").build("argument").field("argument",r("FlowType")),r("ObjectTypeSpreadProperty").bases("Node").build("argument").field("argument",r("FlowType")),r("ObjectTypeInternalSlot").bases("Node").build("id","value","optional","static","method").field("id",r("Identifier")).field("value",r("FlowType")).field("optional",Boolean).field("static",Boolean).field("method",Boolean),r("TypeParameterDeclaration").bases("Node").build("params").field("params",[r("TypeParameter")]),r("TypeParameterInstantiation").bases("Node").build("params").field("params",[r("FlowType")]),r("TypeParameter").bases("FlowType").build("name","variance","bound","default").field("name",String).field("variance",s,i.null).field("bound",n(r("TypeAnnotation"),null),i.null).field("default",n(r("FlowType"),null),i.null),r("ClassProperty").field("variance",s,i.null),r("ClassImplements").bases("Node").build("id").field("id",r("Identifier")).field("superClass",n(r("Expression"),null),i.null).field("typeParameters",n(r("TypeParameterInstantiation"),null),i.null),r("InterfaceTypeAnnotation").bases("FlowType").build("body","extends").field("body",r("ObjectTypeAnnotation")).field("extends",n([r("InterfaceExtends")],null),i.null),r("InterfaceDeclaration").bases("Declaration").build("id","body","extends").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterDeclaration"),null),i.null).field("body",r("ObjectTypeAnnotation")).field("extends",[r("InterfaceExtends")]),r("DeclareInterface").bases("InterfaceDeclaration").build("id","body","extends"),r("InterfaceExtends").bases("Node").build("id").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterInstantiation"),null),i.null),r("TypeAlias").bases("Declaration").build("id","typeParameters","right").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterDeclaration"),null)).field("right",r("FlowType")),r("DeclareTypeAlias").bases("TypeAlias").build("id","typeParameters","right"),r("OpaqueType").bases("Declaration").build("id","typeParameters","impltype","supertype").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterDeclaration"),null)).field("impltype",r("FlowType")).field("supertype",n(r("FlowType"),null)),r("DeclareOpaqueType").bases("OpaqueType").build("id","typeParameters","supertype").field("impltype",n(r("FlowType"),null)),r("TypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",r("Expression")).field("typeAnnotation",r("TypeAnnotation")),r("TupleTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("DeclareVariable").bases("Statement").build("id").field("id",r("Identifier")),r("DeclareFunction").bases("Statement").build("id").field("id",r("Identifier")).field("predicate",n(r("FlowPredicate"),null),i.null),r("DeclareClass").bases("InterfaceDeclaration").build("id"),r("DeclareModule").bases("Statement").build("id","body").field("id",n(r("Identifier"),r("Literal"))).field("body",r("BlockStatement")),r("DeclareModuleExports").bases("Statement").build("typeAnnotation").field("typeAnnotation",r("TypeAnnotation")),r("DeclareExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",n(r("DeclareVariable"),r("DeclareFunction"),r("DeclareClass"),r("FlowType"),r("TypeAlias"),r("DeclareOpaqueType"),r("InterfaceDeclaration"),null)).field("specifiers",[n(r("ExportSpecifier"),r("ExportBatchSpecifier"))],i.emptyArray).field("source",n(r("Literal"),null),i.null),r("DeclareExportAllDeclaration").bases("Declaration").build("source").field("source",n(r("Literal"),null),i.null),r("ImportDeclaration").field("importKind",n("value","type","typeof"),()=>"value"),r("FlowPredicate").bases("Flow"),r("InferredPredicate").bases("FlowPredicate").build(),r("DeclaredPredicate").bases("FlowPredicate").build("value").field("value",r("Expression")),r("Function").field("predicate",n(r("FlowPredicate"),null),i.null),r("CallExpression").field("typeArguments",n(null,r("TypeParameterInstantiation")),i.null),r("NewExpression").field("typeArguments",n(null,r("TypeParameterInstantiation")),i.null),r("EnumDeclaration").bases("Declaration").build("id","body").field("id",r("Identifier")).field("body",n(r("EnumBooleanBody"),r("EnumNumberBody"),r("EnumStringBody"),r("EnumSymbolBody"))),r("EnumBooleanBody").build("members","explicitType").field("members",[r("EnumBooleanMember")]).field("explicitType",Boolean),r("EnumNumberBody").build("members","explicitType").field("members",[r("EnumNumberMember")]).field("explicitType",Boolean),r("EnumStringBody").build("members","explicitType").field("members",n([r("EnumStringMember")],[r("EnumDefaultedMember")])).field("explicitType",Boolean),r("EnumSymbolBody").build("members").field("members",[r("EnumDefaultedMember")]),r("EnumBooleanMember").build("id","init").field("id",r("Identifier")).field("init",n(r("Literal"),Boolean)),r("EnumNumberMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumStringMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumDefaultedMember").build("id").field("id",r("Identifier"))}tt(()=>module);function mY(e){e.use(gl);var t=e.use(Ft),r=e.use(cn).defaults,n=t.Type.def,i=t.Type.or;n("VariableDeclaration").field("declarations",[i(n("VariableDeclarator"),n("Identifier"))]),n("Property").field("value",i(n("Expression"),n("Pattern"))),n("ArrayPattern").field("elements",[i(n("Pattern"),n("SpreadElement"),null)]),n("ObjectPattern").field("properties",[i(n("Property"),n("PropertyPattern"),n("SpreadPropertyPattern"),n("SpreadProperty"))]),n("ExportSpecifier").bases("ModuleSpecifier").build("id","name"),n("ExportBatchSpecifier").bases("Specifier").build(),n("ExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",i(n("Declaration"),n("Expression"),null)).field("specifiers",[i(n("ExportSpecifier"),n("ExportBatchSpecifier"))],r.emptyArray).field("source",i(n("Literal"),null),r.null),n("Block").bases("Comment").build("value","leading","trailing"),n("Line").bases("Comment").build("value","leading","trailing")}tt(()=>module);function T_(e){e.use(gl);let t=e.use(Ft),r=e.use(cn).defaults,n=t.Type.def,i=t.Type.or,{undefined:s}=t.builtInTypes;n("Noop").bases("Statement").build(),n("DoExpression").bases("Expression").build("body").field("body",[n("Statement")]),n("BindExpression").bases("Expression").build("object","callee").field("object",i(n("Expression"),null)).field("callee",n("Expression")),n("ParenthesizedExpression").bases("Expression").build("expression").field("expression",n("Expression")),n("ExportNamespaceSpecifier").bases("Specifier").build("exported").field("exported",n("Identifier")),n("ExportDefaultSpecifier").bases("Specifier").build("exported").field("exported",n("Identifier")),n("CommentBlock").bases("Comment").build("value","leading","trailing"),n("CommentLine").bases("Comment").build("value","leading","trailing"),n("Directive").bases("Node").build("value").field("value",n("DirectiveLiteral")),n("DirectiveLiteral").bases("Node","Expression").build("value").field("value",String,r["use strict"]),n("InterpreterDirective").bases("Node").build("value").field("value",String),n("BlockStatement").bases("Statement").build("body").field("body",[n("Statement")]).field("directives",[n("Directive")],r.emptyArray),n("Program").bases("Node").build("body").field("body",[n("Statement")]).field("directives",[n("Directive")],r.emptyArray).field("interpreter",i(n("InterpreterDirective"),null),r.null);function o(l=String,p){return["extra",{rawValue:l,raw:String},function(){let h=t.getFieldValue(this,"value");return{rawValue:h,raw:p?p(h):String(h)}}]}n("StringLiteral").bases("Literal").build("value").field("value",String).field(...o(String,l=>JSON.stringify(l))),n("NumericLiteral").bases("Literal").build("value").field("value",Number).field("raw",i(String,null),r.null).field(...o(Number)),n("BigIntLiteral").bases("Literal").build("value").field("value",i(String,Number)).field(...o(String,l=>l+"n")),n("DecimalLiteral").bases("Literal").build("value").field("value",String).field(...o(String,l=>l+"m")),n("NullLiteral").bases("Literal").build().field("value",null,r.null),n("BooleanLiteral").bases("Literal").build("value").field("value",Boolean),n("RegExpLiteral").bases("Literal").build("pattern","flags").field("pattern",String).field("flags",String).field("value",RegExp,function(){return new RegExp(this.pattern,this.flags)}).field(...o(i(RegExp,s),l=>`/${l.pattern}/${l.flags||""}`)).field("regex",{pattern:String,flags:String},function(){return{pattern:this.pattern,flags:this.flags}});var a=i(n("Property"),n("ObjectMethod"),n("ObjectProperty"),n("SpreadProperty"),n("SpreadElement"));n("ObjectExpression").bases("Expression").build("properties").field("properties",[a]),n("ObjectMethod").bases("Node","Function").build("kind","key","params","body","computed").field("kind",i("method","get","set")).field("key",i(n("Literal"),n("Identifier"),n("Expression"))).field("params",[n("Pattern")]).field("body",n("BlockStatement")).field("computed",Boolean,r.false).field("generator",Boolean,r.false).field("async",Boolean,r.false).field("accessibility",i(n("Literal"),null),r.null).field("decorators",i([n("Decorator")],null),r.null),n("ObjectProperty").bases("Node").build("key","value").field("key",i(n("Literal"),n("Identifier"),n("Expression"))).field("value",i(n("Expression"),n("Pattern"))).field("accessibility",i(n("Literal"),null),r.null).field("computed",Boolean,r.false);var c=i(n("MethodDefinition"),n("VariableDeclarator"),n("ClassPropertyDefinition"),n("ClassProperty"),n("ClassPrivateProperty"),n("ClassMethod"),n("ClassPrivateMethod"),n("ClassAccessorProperty"),n("StaticBlock"));n("ClassBody").bases("Declaration").build("body").field("body",[c]),n("ClassMethod").bases("Declaration","Function").build("kind","key","params","body","computed","static").field("key",i(n("Literal"),n("Identifier"),n("Expression"))),n("ClassPrivateMethod").bases("Declaration","Function").build("key","params","body","kind","computed","static").field("key",n("PrivateName")),n("ClassAccessorProperty").bases("Declaration").build("key","value","decorators","computed","static").field("key",i(n("Literal"),n("Identifier"),n("PrivateName"),n("Expression"))).field("value",i(n("Expression"),null),r.null),["ClassMethod","ClassPrivateMethod"].forEach(l=>{n(l).field("kind",i("get","set","method","constructor"),()=>"method").field("body",n("BlockStatement")).field("access",i("public","private","protected",null),r.null)}),["ClassMethod","ClassPrivateMethod","ClassAccessorProperty"].forEach(l=>{n(l).field("computed",Boolean,r.false).field("static",Boolean,r.false).field("abstract",Boolean,r.false).field("accessibility",i("public","private","protected",null),r.null).field("decorators",i([n("Decorator")],null),r.null).field("definite",Boolean,r.false).field("optional",Boolean,r.false).field("override",Boolean,r.false).field("readonly",Boolean,r.false)});var u=i(n("Property"),n("PropertyPattern"),n("SpreadPropertyPattern"),n("SpreadProperty"),n("ObjectProperty"),n("RestProperty"),n("RestElement"));n("ObjectPattern").bases("Pattern").build("properties").field("properties",[u]).field("decorators",i([n("Decorator")],null),r.null),n("SpreadProperty").bases("Node").build("argument").field("argument",n("Expression")),n("RestProperty").bases("Node").build("argument").field("argument",n("Expression")),n("ForAwaitStatement").bases("Statement").build("left","right","body").field("left",i(n("VariableDeclaration"),n("Expression"))).field("right",n("Expression")).field("body",n("Statement")),n("Import").bases("Expression").build()}tt(()=>module);function hY(e){let r=e.use(Ft).Type.def;e.use(T_),e.use(S_),r("V8IntrinsicIdentifier").bases("Expression").build("name").field("name",String),r("TopicReference").bases("Expression").build()}tt(()=>module);function gY(e){e.use(T_),e.use(w_);var t=e.use(Ft),r=t.namedTypes,n=t.Type.def,i=t.Type.or,s=e.use(cn).defaults,o=t.Type.from(function(l,p){return!!(r.StringLiteral&&r.StringLiteral.check(l,p)||r.Literal&&r.Literal.check(l,p)&&typeof l.value=="string")},"StringLiteral");n("TSType").bases("Node");var a=i(n("Identifier"),n("TSQualifiedName"));n("TSTypeReference").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("typeName","typeParameters").field("typeName",a),n("TSHasOptionalTypeParameterInstantiation").field("typeParameters",i(n("TSTypeParameterInstantiation"),null),s.null),n("TSHasOptionalTypeParameters").field("typeParameters",i(n("TSTypeParameterDeclaration"),null,void 0),s.null),n("TSHasOptionalTypeAnnotation").field("typeAnnotation",i(n("TSTypeAnnotation"),null),s.null),n("TSQualifiedName").bases("Node").build("left","right").field("left",a).field("right",a),n("TSAsExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TSType")).field("extra",i({parenthesized:Boolean},null),s.null),n("TSTypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TSType")),n("TSSatisfiesExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TSType")),n("TSNonNullExpression").bases("Expression","Pattern").build("expression").field("expression",n("Expression")),["TSAnyKeyword","TSBigIntKeyword","TSBooleanKeyword","TSNeverKeyword","TSNullKeyword","TSNumberKeyword","TSObjectKeyword","TSStringKeyword","TSSymbolKeyword","TSUndefinedKeyword","TSUnknownKeyword","TSVoidKeyword","TSIntrinsicKeyword","TSThisType"].forEach(l=>{n(l).bases("TSType").build()}),n("TSArrayType").bases("TSType").build("elementType").field("elementType",n("TSType")),n("TSLiteralType").bases("TSType").build("literal").field("literal",i(n("NumericLiteral"),n("StringLiteral"),n("BooleanLiteral"),n("TemplateLiteral"),n("UnaryExpression"),n("BigIntLiteral"))),n("TemplateLiteral").field("expressions",i([n("Expression")],[n("TSType")])),["TSUnionType","TSIntersectionType"].forEach(l=>{n(l).bases("TSType").build("types").field("types",[n("TSType")])}),n("TSConditionalType").bases("TSType").build("checkType","extendsType","trueType","falseType").field("checkType",n("TSType")).field("extendsType",n("TSType")).field("trueType",n("TSType")).field("falseType",n("TSType")),n("TSInferType").bases("TSType").build("typeParameter").field("typeParameter",n("TSTypeParameter")),n("TSParenthesizedType").bases("TSType").build("typeAnnotation").field("typeAnnotation",n("TSType"));var c=[i(n("Identifier"),n("RestElement"),n("ArrayPattern"),n("ObjectPattern"))];["TSFunctionType","TSConstructorType"].forEach(l=>{n(l).bases("TSType","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters").field("parameters",c)}),n("TSDeclareFunction").bases("Declaration","TSHasOptionalTypeParameters").build("id","params","returnType").field("declare",Boolean,s.false).field("async",Boolean,s.false).field("generator",Boolean,s.false).field("id",i(n("Identifier"),null),s.null).field("params",[n("Pattern")]).field("returnType",i(n("TSTypeAnnotation"),n("Noop"),null),s.null),n("TSDeclareMethod").bases("Declaration","TSHasOptionalTypeParameters").build("key","params","returnType").field("async",Boolean,s.false).field("generator",Boolean,s.false).field("params",[n("Pattern")]).field("abstract",Boolean,s.false).field("accessibility",i("public","private","protected",void 0),s.undefined).field("static",Boolean,s.false).field("computed",Boolean,s.false).field("optional",Boolean,s.false).field("key",i(n("Identifier"),n("StringLiteral"),n("NumericLiteral"),n("Expression"))).field("kind",i("get","set","method","constructor"),function(){return"method"}).field("access",i("public","private","protected",void 0),s.undefined).field("decorators",i([n("Decorator")],null),s.null).field("returnType",i(n("TSTypeAnnotation"),n("Noop"),null),s.null),n("TSMappedType").bases("TSType").build("typeParameter","typeAnnotation").field("readonly",i(Boolean,"+","-"),s.false).field("typeParameter",n("TSTypeParameter")).field("optional",i(Boolean,"+","-"),s.false).field("typeAnnotation",i(n("TSType"),null),s.null),n("TSTupleType").bases("TSType").build("elementTypes").field("elementTypes",[i(n("TSType"),n("TSNamedTupleMember"))]),n("TSNamedTupleMember").bases("TSType").build("label","elementType","optional").field("label",n("Identifier")).field("optional",Boolean,s.false).field("elementType",n("TSType")),n("TSRestType").bases("TSType").build("typeAnnotation").field("typeAnnotation",n("TSType")),n("TSOptionalType").bases("TSType").build("typeAnnotation").field("typeAnnotation",n("TSType")),n("TSIndexedAccessType").bases("TSType").build("objectType","indexType").field("objectType",n("TSType")).field("indexType",n("TSType")),n("TSTypeOperator").bases("TSType").build("operator").field("operator",String).field("typeAnnotation",n("TSType")),n("TSTypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",i(n("TSType"),n("TSTypeAnnotation"))),n("TSIndexSignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",[n("Identifier")]).field("readonly",Boolean,s.false),n("TSPropertySignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("key","typeAnnotation","optional").field("key",n("Expression")).field("computed",Boolean,s.false).field("readonly",Boolean,s.false).field("optional",Boolean,s.false).field("initializer",i(n("Expression"),null),s.null),n("TSMethodSignature").bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("key","parameters","typeAnnotation").field("key",n("Expression")).field("computed",Boolean,s.false).field("optional",Boolean,s.false).field("parameters",c),n("TSTypePredicate").bases("TSTypeAnnotation","TSType").build("parameterName","typeAnnotation","asserts").field("parameterName",i(n("Identifier"),n("TSThisType"))).field("typeAnnotation",i(n("TSTypeAnnotation"),null),s.null).field("asserts",Boolean,s.false),["TSCallSignatureDeclaration","TSConstructSignatureDeclaration"].forEach(l=>{n(l).bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",c)}),n("TSEnumMember").bases("Node").build("id","initializer").field("id",i(n("Identifier"),o)).field("initializer",i(n("Expression"),null),s.null),n("TSTypeQuery").bases("TSType").build("exprName").field("exprName",i(a,n("TSImportType")));var u=i(n("TSCallSignatureDeclaration"),n("TSConstructSignatureDeclaration"),n("TSIndexSignature"),n("TSMethodSignature"),n("TSPropertySignature"));n("TSTypeLiteral").bases("TSType").build("members").field("members",[u]),n("TSTypeParameter").bases("Identifier").build("name","constraint","default").field("name",i(n("Identifier"),String)).field("constraint",i(n("TSType"),void 0),s.undefined).field("default",i(n("TSType"),void 0),s.undefined),n("TSTypeAssertion").bases("Expression","Pattern").build("typeAnnotation","expression").field("typeAnnotation",n("TSType")).field("expression",n("Expression")).field("extra",i({parenthesized:Boolean},null),s.null),n("TSTypeParameterDeclaration").bases("Declaration").build("params").field("params",[n("TSTypeParameter")]),n("TSInstantiationExpression").bases("Expression","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",n("Expression")),n("TSTypeParameterInstantiation").bases("Node").build("params").field("params",[n("TSType")]),n("TSEnumDeclaration").bases("Declaration").build("id","members").field("id",n("Identifier")).field("const",Boolean,s.false).field("declare",Boolean,s.false).field("members",[n("TSEnumMember")]).field("initializer",i(n("Expression"),null),s.null),n("TSTypeAliasDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","typeAnnotation").field("id",n("Identifier")).field("declare",Boolean,s.false).field("typeAnnotation",n("TSType")),n("TSModuleBlock").bases("Node").build("body").field("body",[n("Statement")]),n("TSModuleDeclaration").bases("Declaration").build("id","body").field("id",i(o,a)).field("declare",Boolean,s.false).field("global",Boolean,s.false).field("body",i(n("TSModuleBlock"),n("TSModuleDeclaration"),null),s.null),n("TSImportType").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("argument","qualifier","typeParameters").field("argument",o).field("qualifier",i(a,void 0),s.undefined),n("TSImportEqualsDeclaration").bases("Declaration").build("id","moduleReference").field("id",n("Identifier")).field("isExport",Boolean,s.false).field("moduleReference",i(a,n("TSExternalModuleReference"))),n("TSExternalModuleReference").bases("Declaration").build("expression").field("expression",o),n("TSExportAssignment").bases("Statement").build("expression").field("expression",n("Expression")),n("TSNamespaceExportDeclaration").bases("Declaration").build("id").field("id",n("Identifier")),n("TSInterfaceBody").bases("Node").build("body").field("body",[u]),n("TSExpressionWithTypeArguments").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",a),n("TSInterfaceDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","body").field("id",a).field("declare",Boolean,s.false).field("extends",i([n("TSExpressionWithTypeArguments")],null),s.null).field("body",n("TSInterfaceBody")),n("TSParameterProperty").bases("Pattern").build("parameter").field("accessibility",i("public","private","protected",void 0),s.undefined).field("readonly",Boolean,s.false).field("parameter",i(n("Identifier"),n("AssignmentPattern"))),n("ClassProperty").field("access",i("public","private","protected",void 0),s.undefined),n("ClassAccessorProperty").bases("Declaration","TSHasOptionalTypeAnnotation"),n("ClassBody").field("body",[i(n("MethodDefinition"),n("VariableDeclarator"),n("ClassPropertyDefinition"),n("ClassProperty"),n("ClassPrivateProperty"),n("ClassAccessorProperty"),n("ClassMethod"),n("ClassPrivateMethod"),n("StaticBlock"),n("TSDeclareMethod"),u)])}tt(()=>module);var Yn;Yn||(Yn={});var{astNodesAreEquivalent:g_e,builders:sc,builtInTypes:Jn,defineMethod:y_e,eachField:b_e,finalize:x_e,getBuilderName:v_e,getFieldNames:yY,getFieldValue:ts,getSupertypeNames:D_e,namedTypes:bY,NodePath:xY,Path:C_e,PathVisitor:E_e,someField:vY,Type:w_e,use:S_e,visit:T_e}=tY([gl,fY,S_,mY,hY,gY]);Object.assign(Yn,bY);var xf=Yn,n_=Rf.default.SourceMapConsumer,DY=Rf.default.SourceMapGenerator,A_=Object.prototype.hasOwnProperty;function CY(){return`
1185
+ `);return s!==-1&&(t=HP(t,i,n,s)),n+t+i};Object.defineProperties(Gu.prototype,Ua);var CFe=Gu(),EFe=Gu({level:VP?VP.level:0});var Ie=new ef({level:2}),JP={comment:Ie.gray,quote:Ie.gray,keyword:Ie.green,"selector-tag":Ie.green,addition:Ie.green,number:Ie.cyan,string:Ie.cyan,"meta meta-string":Ie.cyan,literal:Ie.cyan,doctag:Ie.cyan,regexp:Ie.cyan,title:Ie.blue,section:Ie.blue,name:Ie.blue,"selector-id":Ie.blue,"selector-class":Ie.blue,attribute:Ie.yellow,attr:Ie.yellow,variable:Ie.yellow,"template-variable":Ie.yellow,"class title":Ie.yellow,type:Ie.yellow,symbol:Ie.magenta,bullet:Ie.magenta,subst:Ie.magenta,meta:Ie.magenta,"meta keyword":Ie.magenta,"selector-attr":Ie.magenta,"selector-pseudo":Ie.magenta,link:Ie.magenta,built_in:Ie.red,deletion:Ie.red,emphasis:Ie.italic,strong:Ie.bold,formula:Ie.inverse};function zu(e){let t=lb(e);return{highlight:r,highlightAuto:n,listLanguages:t.listLanguages,register:t.register,registerAlias:t.registerAlias,registered:t.registered};function r(i,s,o){let a=t.highlight(i,s),c=a.data;return{language:c.language,relevance:c.relevance,value:hb(o||JP,a)}}function n(i,s){let o,a;if(s&&("subset"in s||"sheet"in s)){let l=s;a={subset:l.subset},o=l.sheet}else o=s;let c=t.highlightAuto(i,a),u=c.data;return{language:u.language,relevance:u.relevance,value:hb(o||JP,c)}}}function hb(e,t){let r=new Set(t.type==="element"&&Array.isArray(t.properties.className)?t.properties.className.map(function(a){return String(a).replace(/^hljs-/,"")}):[]),n={},i,s="",o;for(o in e)if(Object.hasOwn(e,o)){let a=o.split(" "),c=e[o];r.has(a[0])?a.length===1?i=c:n[a.slice(1).join(" ")]=c:n[o]=c}return"value"in t?s=t.value:"children"in t&&(s=sV(n,t.children)),i&&(s=i(s)),s}function sV(e,t){let r=[],n=-1;for(;++n<t.length;)r.push(hb(e,t[n]));return r.join("")}f();var XP=q(require("@sentry/node"),1),QP=q(require("@amplitude/analytics-node"),1);async function te(e){if(process.env.NODE_ENV!=="test")try{await Promise.allSettled([XP.flush(2e3),QP.flush().promise])}catch(t){console.error(t)}process.exit(e)}f();var Fe=process.env.AIR_HOST||"https://api.builder.io";f();var Ci=q(require("@amplitude/analytics-node"),1),Xn=q(require("@sentry/node"),1);var ZP="1.9.20";f();var Vt=require("fs/promises"),e2=require("crypto"),ut=require("fs"),yl=require("os"),Ne=q(require("path"),1),t2=q(require("typescript"),1),r2=q(require("launch-editor"),1);var Bo=require("child_process");var Px={};pS(Px,{MagicastError:()=>yr,builders:()=>wJ,detectCodeFormat:()=>X_,generateCode:()=>Ax,loadFile:()=>CJ,parseExpression:()=>Z_,parseModule:()=>Q_,writeFile:()=>EJ});f();var Tf=require("fs");var Rf=q(SF(),1),y_=q(r_(),1);function cn(e){var t=e.use(Ft),r=t.Type,n=t.builtInTypes,i=n.number;function s(u){return r.from(l=>i.check(l)&&l>=u,i+" >= "+u)}let o={null:function(){return null},emptyArray:function(){return[]},false:function(){return!1},true:function(){return!0},undefined:function(){},"use strict":function(){return"use strict"}};var a=r.or(n.string,n.number,n.boolean,n.null,n.undefined);let c=r.from(u=>{if(u===null)return!0;var l=typeof u;return!(l==="object"||l==="function")},a.toString());return{geq:s,defaults:o,isPrimitive:c}}function tt(e){try{var t=e(),r=t.exports,n=r.default}catch{return}n&&n!==r&&typeof r=="object"&&(Object.assign(n,r,{default:n}),r.__esModule&&Object.defineProperty(n,"__esModule",{value:!0}),t.exports=n)}var YW=Object.defineProperty,JW=(e,t,r)=>t in e?YW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Ar=(e,t,r)=>(JW(e,typeof t!="symbol"?t+"":t,r),r),b_=Object.prototype,Af=b_.toString,wn=b_.hasOwnProperty,Oo=class{assert(t,r){if(!this.check(t,r)){var n=Cx(t);throw new Error(n+" does not match type "+this)}return!0}arrayOf(){let t=this;return new dl(t)}},dl=class extends Oo{constructor(t){super(),this.elemType=t,Ar(this,"kind","ArrayType")}toString(){return"["+this.elemType+"]"}check(t,r){return Array.isArray(t)&&t.every(n=>this.elemType.check(n,r))}},Pf=class extends Oo{constructor(t){super(),this.value=t,Ar(this,"kind","IdentityType")}toString(){return String(this.value)}check(t,r){let n=t===this.value;return!n&&typeof r=="function"&&r(this,t),n}},Ff=class extends Oo{constructor(t){super(),this.fields=t,Ar(this,"kind","ObjectType")}toString(){return"{ "+this.fields.join(", ")+" }"}check(t,r){return Af.call(t)===Af.call({})&&this.fields.every(n=>n.type.check(t[n.name],r))}},_f=class extends Oo{constructor(t){super(),this.types=t,Ar(this,"kind","OrType")}toString(){return this.types.join(" | ")}check(t,r){return this.types.some(n=>n.check(t,!!r))?!0:(typeof r=="function"&&r(this,t),!1)}},Ro=class extends Oo{constructor(t,r){super(),this.name=t,this.predicate=r,Ar(this,"kind","PredicateType")}toString(){return this.name}check(t,r){let n=this.predicate(t,r);return!n&&typeof r=="function"&&r(this,t),n}},ll=class e{constructor(t,r){this.type=t,this.typeName=r,Ar(this,"baseNames",[]),Ar(this,"ownFields",Object.create(null)),Ar(this,"allSupertypes",Object.create(null)),Ar(this,"supertypeList",[]),Ar(this,"allFields",Object.create(null)),Ar(this,"fieldNames",[]),Ar(this,"finalized",!1),Ar(this,"buildable",!1),Ar(this,"buildParams",[])}isSupertypeOf(t){if(t instanceof e){if(this.finalized!==!0||t.finalized!==!0)throw new Error("");return wn.call(t.allSupertypes,this.typeName)}else throw new Error(t+" is not a Def")}checkAllFields(t,r){var n=this.allFields;if(this.finalized!==!0)throw new Error(""+this.typeName);function i(s){var o=n[s],a=o.type,c=o.getValue(t);return a.check(c,r)}return t!==null&&typeof t=="object"&&Object.keys(n).every(i)}bases(...t){var r=this.baseNames;if(this.finalized){if(t.length!==r.length)throw new Error("");for(var n=0;n<t.length;n++)if(t[n]!==r[n])throw new Error("");return this}return t.forEach(i=>{r.indexOf(i)<0&&r.push(i)}),this}},If=class{constructor(t,r,n,i){this.name=t,this.type=r,this.defaultFn=n,Ar(this,"hidden"),this.hidden=!!i}toString(){return JSON.stringify(this.name)+": "+this.type}getValue(t){var r=t[this.name];return typeof r<"u"||typeof this.defaultFn=="function"&&(r=this.defaultFn.call(t)),r}};function Cx(e){return Array.isArray(e)?"["+e.map(Cx).join(", ")+"]":e&&typeof e=="object"?"{ "+Object.keys(e).map(function(t){return t+": "+e[t]}).join(", ")+" }":JSON.stringify(e)}function Ft(e){let t={or(...R){return new _f(R.map(M=>t.from(M)))},from(R,M){if(R instanceof dl||R instanceof Pf||R instanceof Ff||R instanceof _f||R instanceof Ro)return R;if(R instanceof ll)return R.type;if(a.check(R)){if(R.length!==1)throw new Error("only one element type is permitted for typed arrays");return new dl(t.from(R[0]))}if(c.check(R))return new Ff(Object.keys(R).map(W=>new If(W,t.from(R[W],W))));if(typeof R=="function"){var K=r.indexOf(R);if(K>=0)return n[K];if(typeof M!="string")throw new Error("missing name");return new Ro(M,R)}return new Pf(R)},def(R){return wn.call(b,R)?b[R]:b[R]=new C(R)},hasDef(R){return wn.call(b,R)}};var r=[],n=[];function i(R,M){let K=Af.call(M),W=new Ro(R,ce=>Af.call(ce)===K);return M&&typeof M.constructor=="function"&&(r.push(M.constructor),n.push(W)),W}let s=i("string","truthy"),o=i("function",function(){}),a=i("array",[]),c=i("object",{}),u=i("RegExp",/./),l=i("Date",new Date),p=i("number",3),d=i("boolean",!0),h=i("null",null),m=i("undefined",void 0),g=typeof BigInt=="function"?i("BigInt",BigInt(1234)):new Ro("BigInt",()=>!1),y={string:s,function:o,array:a,object:c,RegExp:u,Date:l,number:p,boolean:d,null:h,undefined:m,BigInt:g};var b=Object.create(null);function v(R){if(R&&typeof R=="object"){var M=R.type;if(typeof M=="string"&&wn.call(b,M)){var K=b[M];if(K.finalized)return K}}return null}class C extends ll{constructor(M){super(new Ro(M,(K,W)=>this.check(K,W)),M)}check(M,K){if(this.finalized!==!0)throw new Error("prematurely checking unfinalized type "+this.typeName);if(M===null||typeof M!="object")return!1;var W=v(M);return W?K&&W===this?this.checkAllFields(M,K):this.isSupertypeOf(W)?K?W.checkAllFields(M,K)&&this.checkAllFields(M,!1):!0:!1:this.typeName==="SourceLocation"||this.typeName==="Position"?this.checkAllFields(M,K):!1}build(...M){if(this.buildParams=M,this.buildable)return this;this.field("type",String,()=>this.typeName),this.buildable=!0;let K=(ce,se,Z,xt)=>{if(!wn.call(ce,se)){var Le=this.allFields;if(!wn.call(Le,se))throw new Error(""+se);var J=Le[se],$e=J.type,X;if(xt)X=Z;else if(J.defaultFn)X=J.defaultFn.call(ce);else{var me="no value or default function given for field "+JSON.stringify(se)+" of "+this.typeName+"("+this.buildParams.map(function(ue){return Le[ue]}).join(", ")+")";throw new Error(me)}if(!$e.check(X))throw new Error(Cx(X)+" does not match field "+J+" of type "+this.typeName);ce[se]=X}},W=(...ce)=>{var se=ce.length;if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var Z=Object.create(S);if(this.buildParams.forEach(function(xt,Le){Le<se?K(Z,xt,ce[Le],!0):K(Z,xt,null,!1)}),Object.keys(this.allFields).forEach(function(xt){K(Z,xt,null,!1)}),Z.type!==this.typeName)throw new Error("");return Z};return W.from=ce=>{if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var se=Object.create(S);if(Object.keys(this.allFields).forEach(function(Z){wn.call(ce,Z)?K(se,Z,ce[Z],!0):K(se,Z,null,!1)}),se.type!==this.typeName)throw new Error("");return se},Object.defineProperty(E,I(this.typeName),{enumerable:!0,value:W}),this}field(M,K,W,ce){return this.finalized?(console.error("Ignoring attempt to redefine field "+JSON.stringify(M)+" of finalized type "+JSON.stringify(this.typeName)),this):(this.ownFields[M]=new If(M,t.from(K),W,ce),this)}finalize(){if(!this.finalized){var M=this.allFields,K=this.allSupertypes;this.baseNames.forEach(ce=>{var se=b[ce];if(se instanceof ll)se.finalize(),k(M,se.allFields),k(K,se.allSupertypes);else{var Z="unknown supertype name "+JSON.stringify(ce)+" for subtype "+JSON.stringify(this.typeName);throw new Error(Z)}}),k(M,this.ownFields),K[this.typeName]=this,this.fieldNames.length=0;for(var W in M)wn.call(M,W)&&!M[W].hidden&&this.fieldNames.push(W);Object.defineProperty(T,this.typeName,{enumerable:!0,value:this.type}),this.finalized=!0,L(this.typeName,this.supertypeList),this.buildable&&this.supertypeList.lastIndexOf("Expression")>=0&&N(this.typeName)}}}function x(R){if(!wn.call(b,R))throw new Error("");var M=b[R];if(M.finalized!==!0)throw new Error("");return M.supertypeList.slice(1)}function D(R){for(var M={},K=Object.keys(b),W=K.length,ce=0;ce<W;++ce){var se=K[ce],Z=b[se];if(Z.finalized!==!0)throw new Error(""+se);for(var xt=0;xt<Z.supertypeList.length;++xt){var Le=Z.supertypeList[xt];if(wn.call(R,Le)){M[se]=Le;break}}}return M}var E=Object.create(null),S={};function F(R,M){var K=S[R];return m.check(M)?delete S[R]:(o.assert(M),Object.defineProperty(S,R,{enumerable:!0,configurable:!0,value:M})),K}function I(R){return R.replace(/^[A-Z]+/,function(M){var K=M.length;switch(K){case 0:return"";case 1:return M.toLowerCase();default:return M.slice(0,K-1).toLowerCase()+M.charAt(K-1)}})}function A(R){return R=I(R),R.replace(/(Expression)?$/,"Statement")}var T={};function G(R){var M=v(R);if(M)return M.fieldNames.slice(0);if("type"in R)throw new Error("did not recognize object of type "+JSON.stringify(R.type));return Object.keys(R)}function V(R,M){var K=v(R);if(K){var W=K.allFields[M];if(W)return W.getValue(R)}return R&&R[M]}function Y(R,M,K){G(R).forEach(function(W){M.call(this,W,V(R,W))},K)}function P(R,M,K){return G(R).some(function(W){return M.call(this,W,V(R,W))},K)}function N(R){var M=A(R);if(E[M])return;var K=E[I(R)];if(!K)return;let W=function(...ce){return E.expressionStatement(K.apply(E,ce))};W.from=function(...ce){return E.expressionStatement(K.from.apply(E,ce))},E[M]=W}function L(R,M){M.length=0,M.push(R);for(var K=Object.create(null),W=0;W<M.length;++W){R=M[W];var ce=b[R];if(ce.finalized!==!0)throw new Error("");wn.call(K,R)&&delete M[K[R]],K[R]=W,M.push.apply(M,ce.baseNames)}for(var se=0,Z=se,xt=M.length;Z<xt;++Z)wn.call(M,Z)&&(M[se++]=M[Z]);M.length=se}function k(R,M){return Object.keys(M).forEach(function(K){R[K]=M[K]}),R}function $(){Object.keys(b).forEach(function(R){b[R].finalize()})}return{Type:t,builtInTypes:y,getSupertypeNames:x,computeSupertypeLookupTable:D,builders:E,defineMethod:F,getBuilderName:I,getStatementBuilderName:A,namedTypes:T,getFieldNames:G,getFieldValue:V,eachField:Y,someField:P,finalize:$}}tt(()=>module);var XW=Object.prototype,yf=XW.hasOwnProperty;function x_(e){var t=e.use(Ft),r=t.builtInTypes.array,n=t.builtInTypes.number;let i=function p(d,h,m){if(!(this instanceof p))throw new Error("Path constructor cannot be invoked without 'new'");if(h){if(!(h instanceof p))throw new Error("")}else h=null,m=null;this.value=d,this.parentPath=h,this.name=m,this.__childCache=null};var s=i.prototype;function o(p){return p.__childCache||(p.__childCache=Object.create(null))}function a(p,d){var h=o(p),m=p.getValueProperty(d),g=h[d];return(!yf.call(h,d)||g.value!==m)&&(g=h[d]=new p.constructor(m,p,d)),g}s.getValueProperty=function(d){return this.value[d]},s.get=function(...d){for(var h=this,m=d.length,g=0;g<m;++g)h=a(h,d[g]);return h},s.each=function(d,h){for(var m=[],g=this.value.length,y=0,y=0;y<g;++y)yf.call(this.value,y)&&(m[y]=this.get(y));for(h=h||this,y=0;y<g;++y)yf.call(m,y)&&d.call(h,m[y])},s.map=function(d,h){var m=[];return this.each(function(g){m.push(d.call(this,g))},h),m},s.filter=function(d,h){var m=[];return this.each(function(g){d.call(this,g)&&m.push(g)},h),m};function c(){}function u(p,d,h,m){if(r.assert(p.value),d===0)return c;var g=p.value.length;if(g<1)return c;var y=arguments.length;y===2?(h=0,m=g):y===3?(h=Math.max(h,0),m=g):(h=Math.max(h,0),m=Math.min(m,g)),n.assert(h),n.assert(m);for(var b=Object.create(null),v=o(p),C=h;C<m;++C)if(yf.call(p.value,C)){var x=p.get(C);if(x.name!==C)throw new Error("");var D=C+d;x.name=D,b[D]=x,delete v[C]}return delete v.length,function(){for(var E in b){var S=b[E];if(S.name!==+E)throw new Error("");v[E]=S,p.value[E]=S.value}}}s.shift=function(){var d=u(this,-1),h=this.value.shift();return d(),h},s.unshift=function(...d){var h=u(this,d.length),m=this.value.unshift.apply(this.value,d);return h(),m},s.push=function(...d){return r.assert(this.value),delete o(this).length,this.value.push.apply(this.value,d)},s.pop=function(){r.assert(this.value);var d=o(this);return delete d[this.value.length-1],delete d.length,this.value.pop()},s.insertAt=function(d){var h=arguments.length,m=u(this,h-1,d);if(m===c&&h<=1)return this;d=Math.max(d,0);for(var g=1;g<h;++g)this.value[d+g-1]=arguments[g];return m(),this},s.insertBefore=function(...d){for(var h=this.parentPath,m=d.length,g=[this.name],y=0;y<m;++y)g.push(d[y]);return h.insertAt.apply(h,g)},s.insertAfter=function(...d){for(var h=this.parentPath,m=d.length,g=[this.name+1],y=0;y<m;++y)g.push(d[y]);return h.insertAt.apply(h,g)};function l(p){if(!(p instanceof i))throw new Error("");var d=p.parentPath;if(!d)return p;var h=d.value,m=o(d);if(h[p.name]===p.value)m[p.name]=p;else if(r.check(h)){var g=h.indexOf(p.value);g>=0&&(m[p.name=g]=p)}else h[p.name]=p.value,m[p.name]=p;if(h[p.name]!==p.value)throw new Error("");if(p.parentPath.get(p.name)!==p)throw new Error("");return p}return s.replace=function(d){var h=[],m=this.parentPath.value,g=o(this.parentPath),y=arguments.length;if(l(this),r.check(m)){for(var b=m.length,v=u(this.parentPath,y-1,this.name+1),C=[this.name,1],x=0;x<y;++x)C.push(arguments[x]);var D=m.splice.apply(m,C);if(D[0]!==this.value)throw new Error("");if(m.length!==b-1+y)throw new Error("");if(v(),y===0)delete this.value,delete g[this.name],this.__childCache=null;else{if(m[this.name]!==d)throw new Error("");for(this.value!==d&&(this.value=d,this.__childCache=null),x=0;x<y;++x)h.push(this.parentPath.get(this.name+x));if(h[0]!==this)throw new Error("")}}else if(y===1)this.value!==d&&(this.__childCache=null),this.value=m[this.name]=d,h.push(this);else if(y===0)delete m[this.name],delete this.value,this.__childCache=null;else throw new Error("Could not replace path");return h},i}tt(()=>module);var Qa=Object.prototype.hasOwnProperty;function QW(e){var t=e.use(Ft),r=t.Type,n=t.namedTypes,i=n.Node,s=n.Expression,o=t.builtInTypes.array,a=t.builders;let c=function x(D,E){if(!(this instanceof x))throw new Error("Scope constructor cannot be invoked without 'new'");l.check(D.value)||u.assert(D.value);var S;if(E){if(!(E instanceof x))throw new Error("");S=E.depth+1}else E=null,S=0;Object.defineProperties(this,{path:{value:D},node:{value:D.value},isGlobal:{value:!E,enumerable:!0},depth:{value:S},parent:{value:E},bindings:{value:{}},types:{value:{}}})};var u=r.or(n.Program,n.Function,n.CatchClause),l=r.or(n.Function,n.ClassDeclaration,n.ClassExpression,n.InterfaceDeclaration,n.TSInterfaceDeclaration,n.TypeAlias,n.TSTypeAliasDeclaration),p=r.or(n.TypeParameter,n.TSTypeParameter);c.isEstablishedBy=function(x){return u.check(x)||l.check(x)};var d=c.prototype;d.didScan=!1,d.declares=function(x){return this.scan(),Qa.call(this.bindings,x)},d.declaresType=function(x){return this.scan(),Qa.call(this.types,x)},d.declareTemporary=function(x){if(x){if(!/^[a-z$_]/i.test(x))throw new Error("")}else x="t$";x+=this.depth.toString(36)+"$",this.scan();for(var D=0;this.declares(x+D);)++D;var E=x+D;return this.bindings[E]=t.builders.identifier(E)},d.injectTemporary=function(x,D){x||(x=this.declareTemporary());var E=this.path.get("body");return n.BlockStatement.check(E.value)&&(E=E.get("body")),E.unshift(a.variableDeclaration("var",[a.variableDeclarator(x,D||null)])),x},d.scan=function(x){if(x||!this.didScan){for(var D in this.bindings)delete this.bindings[D];for(var D in this.types)delete this.types[D];h(this.path,this.bindings,this.types),this.didScan=!0}},d.getBindings=function(){return this.scan(),this.bindings},d.getTypes=function(){return this.scan(),this.types};function h(x,D,E){var S=x.value;if(l.check(S)){let F=x.get("typeParameters","params");o.check(F.value)&&F.each(I=>{C(I,E)})}u.check(S)&&(n.CatchClause.check(S)?b(x.get("param"),D):m(x,D,E))}function m(x,D,E){var S=x.value;x.parent&&n.FunctionExpression.check(x.parent.node)&&x.parent.node.id&&b(x.parent.get("id"),D),S&&(o.check(S)?x.each(F=>{y(F,D,E)}):n.Function.check(S)?(x.get("params").each(F=>{b(F,D)}),y(x.get("body"),D,E),m(x.get("typeParameters"),D,E)):n.TypeAlias&&n.TypeAlias.check(S)||n.InterfaceDeclaration&&n.InterfaceDeclaration.check(S)||n.TSTypeAliasDeclaration&&n.TSTypeAliasDeclaration.check(S)||n.TSInterfaceDeclaration&&n.TSInterfaceDeclaration.check(S)?v(x.get("id"),E):n.VariableDeclarator.check(S)?(b(x.get("id"),D),y(x.get("init"),D,E)):S.type==="ImportSpecifier"||S.type==="ImportNamespaceSpecifier"||S.type==="ImportDefaultSpecifier"?b(x.get(S.local?"local":S.name?"name":"id"),D):i.check(S)&&!s.check(S)&&t.eachField(S,function(F,I){var A=x.get(F);if(!g(A,I))throw new Error("");y(A,D,E)}))}function g(x,D){return!!(x.value===D||Array.isArray(x.value)&&x.value.length===0&&Array.isArray(D)&&D.length===0)}function y(x,D,E){var S=x.value;if(!(!S||s.check(S)))if(n.FunctionDeclaration.check(S)&&S.id!==null)b(x.get("id"),D);else if(n.ClassDeclaration&&n.ClassDeclaration.check(S)&&S.id!==null)b(x.get("id"),D),m(x.get("typeParameters"),D,E);else if(n.InterfaceDeclaration&&n.InterfaceDeclaration.check(S)||n.TSInterfaceDeclaration&&n.TSInterfaceDeclaration.check(S))v(x.get("id"),E);else if(u.check(S)){if(n.CatchClause.check(S)&&n.Identifier.check(S.param)){var F=S.param.name,I=Qa.call(D,F);m(x.get("body"),D,E),I||delete D[F]}}else m(x,D,E)}function b(x,D){var E=x.value;n.Pattern.assert(E),n.Identifier.check(E)?Qa.call(D,E.name)?D[E.name].push(x):D[E.name]=[x]:n.AssignmentPattern&&n.AssignmentPattern.check(E)?b(x.get("left"),D):n.ObjectPattern&&n.ObjectPattern.check(E)?x.get("properties").each(function(S){var F=S.value;n.Pattern.check(F)?b(S,D):n.Property.check(F)||n.ObjectProperty&&n.ObjectProperty.check(F)?b(S.get("value"),D):n.SpreadProperty&&n.SpreadProperty.check(F)&&b(S.get("argument"),D)}):n.ArrayPattern&&n.ArrayPattern.check(E)?x.get("elements").each(function(S){var F=S.value;n.Pattern.check(F)?b(S,D):n.SpreadElement&&n.SpreadElement.check(F)&&b(S.get("argument"),D)}):n.PropertyPattern&&n.PropertyPattern.check(E)?b(x.get("pattern"),D):(n.SpreadElementPattern&&n.SpreadElementPattern.check(E)||n.RestElement&&n.RestElement.check(E)||n.SpreadPropertyPattern&&n.SpreadPropertyPattern.check(E))&&b(x.get("argument"),D)}function v(x,D){var E=x.value;n.Pattern.assert(E),n.Identifier.check(E)&&(Qa.call(D,E.name)?D[E.name].push(x):D[E.name]=[x])}function C(x,D){var E=x.value;p.assert(E),Qa.call(D,E.name)?D[E.name].push(x):D[E.name]=[x]}return d.lookup=function(x){for(var D=this;D&&!D.declares(x);D=D.parent);return D},d.lookupType=function(x){for(var D=this;D&&!D.declaresType(x);D=D.parent);return D},d.getGlobalScope=function(){for(var x=this;!x.isGlobal;)x=x.parent;return x},c}tt(()=>module);function v_(e){var t=e.use(Ft),r=t.namedTypes,n=t.builders,i=t.builtInTypes.number,s=t.builtInTypes.array,o=e.use(x_),a=e.use(QW);let c=function y(b,v,C){if(!(this instanceof y))throw new Error("NodePath constructor cannot be invoked without 'new'");o.call(this,b,v,C)};var u=c.prototype=Object.create(o.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}});Object.defineProperties(u,{node:{get:function(){return Object.defineProperty(this,"node",{configurable:!0,value:this._computeNode()}),this.node}},parent:{get:function(){return Object.defineProperty(this,"parent",{configurable:!0,value:this._computeParent()}),this.parent}},scope:{get:function(){return Object.defineProperty(this,"scope",{configurable:!0,value:this._computeScope()}),this.scope}}}),u.replace=function(){return delete this.node,delete this.parent,delete this.scope,o.prototype.replace.apply(this,arguments)},u.prune=function(){var y=this.parent;return this.replace(),m(y)},u._computeNode=function(){var y=this.value;if(r.Node.check(y))return y;var b=this.parentPath;return b&&b.node||null},u._computeParent=function(){var y=this.value,b=this.parentPath;if(!r.Node.check(y)){for(;b&&!r.Node.check(b.value);)b=b.parentPath;b&&(b=b.parentPath)}for(;b&&!r.Node.check(b.value);)b=b.parentPath;return b||null},u._computeScope=function(){var y=this.value,b=this.parentPath,v=b&&b.scope;return r.Node.check(y)&&a.isEstablishedBy(y)&&(v=new a(this,v)),v||null},u.getValueProperty=function(y){return t.getFieldValue(this.value,y)},u.needsParens=function(y){var b=this.parentPath;if(!b)return!1;var v=this.value;if(!r.Expression.check(v)||v.type==="Identifier")return!1;for(;!r.Node.check(b.value);)if(b=b.parentPath,!b)return!1;var C=b.value;switch(v.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return C.type==="MemberExpression"&&this.name==="object"&&C.object===v;case"BinaryExpression":case"LogicalExpression":switch(C.type){case"CallExpression":return this.name==="callee"&&C.callee===v;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return!0;case"MemberExpression":return this.name==="object"&&C.object===v;case"BinaryExpression":case"LogicalExpression":{let x=v,D=C.operator,E=p[D],S=x.operator,F=p[S];if(E>F)return!0;if(E===F&&this.name==="right"){if(C.right!==x)throw new Error("Nodes must be equal");return!0}}default:return!1}case"SequenceExpression":switch(C.type){case"ForStatement":return!1;case"ExpressionStatement":return this.name!=="expression";default:return!0}case"YieldExpression":switch(C.type){case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"CallExpression":case"MemberExpression":case"NewExpression":case"ConditionalExpression":case"YieldExpression":return!0;default:return!1}case"Literal":return C.type==="MemberExpression"&&i.check(v.value)&&this.name==="object"&&C.object===v;case"AssignmentExpression":case"ConditionalExpression":switch(C.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return!0;case"CallExpression":return this.name==="callee"&&C.callee===v;case"ConditionalExpression":return this.name==="test"&&C.test===v;case"MemberExpression":return this.name==="object"&&C.object===v;default:return!1}default:if(C.type==="NewExpression"&&this.name==="callee"&&C.callee===v)return d(v)}return!!(y!==!0&&!this.canBeFirstInStatement()&&this.firstInStatement())};function l(y){return r.BinaryExpression.check(y)||r.LogicalExpression.check(y)}var p={};[["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]].forEach(function(y,b){y.forEach(function(v){p[v]=b})});function d(y){return r.CallExpression.check(y)?!0:s.check(y)?y.some(d):r.Node.check(y)?t.someField(y,function(b,v){return d(v)}):!1}u.canBeFirstInStatement=function(){var y=this.node;return!r.FunctionExpression.check(y)&&!r.ObjectExpression.check(y)},u.firstInStatement=function(){return h(this)};function h(y){for(var b,v;y.parent;y=y.parent){if(b=y.node,v=y.parent.node,r.BlockStatement.check(v)&&y.parent.name==="body"&&y.name===0){if(v.body[0]!==b)throw new Error("Nodes must be equal");return!0}if(r.ExpressionStatement.check(v)&&y.name==="expression"){if(v.expression!==b)throw new Error("Nodes must be equal");return!0}if(r.SequenceExpression.check(v)&&y.parent.name==="expressions"&&y.name===0){if(v.expressions[0]!==b)throw new Error("Nodes must be equal");continue}if(r.CallExpression.check(v)&&y.name==="callee"){if(v.callee!==b)throw new Error("Nodes must be equal");continue}if(r.MemberExpression.check(v)&&y.name==="object"){if(v.object!==b)throw new Error("Nodes must be equal");continue}if(r.ConditionalExpression.check(v)&&y.name==="test"){if(v.test!==b)throw new Error("Nodes must be equal");continue}if(l(v)&&y.name==="left"){if(v.left!==b)throw new Error("Nodes must be equal");continue}if(r.UnaryExpression.check(v)&&!v.prefix&&y.name==="argument"){if(v.argument!==b)throw new Error("Nodes must be equal");continue}return!1}return!0}function m(y){if(r.VariableDeclaration.check(y.node)){var b=y.get("declarations").value;if(!b||b.length===0)return y.prune()}else if(r.ExpressionStatement.check(y.node)){if(!y.get("expression").value)return y.prune()}else r.IfStatement.check(y.node)&&g(y);return y}function g(y){var b=y.get("test").value,v=y.get("alternate").value,C=y.get("consequent").value;if(!C&&!v){var x=n.expressionStatement(b);y.replace(x)}else if(!C&&v){var D=n.unaryExpression("!",b,!0);r.UnaryExpression.check(b)&&b.operator==="!"&&(D=b.argument),y.get("test").replace(D),y.get("consequent").replace(v),y.get("alternate").replace()}}return c}tt(()=>module);var bf=Object.prototype.hasOwnProperty;function ZW(e){var t=e.use(Ft),r=e.use(v_),n=t.builtInTypes.array,i=t.builtInTypes.object,s=t.builtInTypes.function,o;let a=function m(){if(!(this instanceof m))throw new Error("PathVisitor constructor cannot be invoked without 'new'");this._reusableContextStack=[],this._methodNameTable=c(this),this._shouldVisitComments=bf.call(this._methodNameTable,"Block")||bf.call(this._methodNameTable,"Line"),this.Context=d(this),this._visiting=!1,this._changeReported=!1};function c(m){var g=Object.create(null);for(var y in m)/^visit[A-Z]/.test(y)&&(g[y.slice(5)]=!0);for(var b=t.computeSupertypeLookupTable(g),v=Object.create(null),C=Object.keys(b),x=C.length,D=0;D<x;++D){var E=C[D];y="visit"+b[E],s.check(m[y])&&(v[E]=y)}return v}a.fromMethodsObject=function(g){if(g instanceof a)return g;if(!i.check(g))return new a;let y=function v(){if(!(this instanceof v))throw new Error("Visitor constructor cannot be invoked without 'new'");a.call(this)};var b=y.prototype=Object.create(l);return b.constructor=y,u(b,g),u(y,a),s.assert(y.fromMethodsObject),s.assert(y.visit),new y};function u(m,g){for(var y in g)bf.call(g,y)&&(m[y]=g[y]);return m}a.visit=function(g,y){return a.fromMethodsObject(y).visit(g)};var l=a.prototype;l.visit=function(){if(this._visiting)throw new Error("Recursively calling visitor.visit(path) resets visitor state. Try this.visit(path) or this.traverse(path) instead.");this._visiting=!0,this._changeReported=!1,this._abortRequested=!1;for(var m=arguments.length,g=new Array(m),y=0;y<m;++y)g[y]=arguments[y];g[0]instanceof r||(g[0]=new r({root:g[0]}).get("root")),this.reset.apply(this,g);var b;try{var v=this.visitWithoutReset(g[0]);b=!0}finally{if(this._visiting=!1,!b&&this._abortRequested)return g[0].value}return v},l.AbortRequest=function(){},l.abort=function(){var m=this;m._abortRequested=!0;var g=new m.AbortRequest;throw g.cancel=function(){m._abortRequested=!1},g},l.reset=function(m){},l.visitWithoutReset=function(m){if(this instanceof this.Context)return this.visitor.visitWithoutReset(m);if(!(m instanceof r))throw new Error("");var g=m.value,y=g&&typeof g=="object"&&typeof g.type=="string"&&this._methodNameTable[g.type];if(y){var b=this.acquireContext(m);try{return b.invokeVisitorMethod(y)}finally{this.releaseContext(b)}}else return p(m,this)};function p(m,g){if(!(m instanceof r))throw new Error("");if(!(g instanceof a))throw new Error("");var y=m.value;if(n.check(y))m.each(g.visitWithoutReset,g);else if(i.check(y)){var b=t.getFieldNames(y);g._shouldVisitComments&&y.comments&&b.indexOf("comments")<0&&b.push("comments");for(var v=b.length,C=[],x=0;x<v;++x){var D=b[x];bf.call(y,D)||(y[D]=t.getFieldValue(y,D)),C.push(m.get(D))}for(var x=0;x<v;++x)g.visitWithoutReset(C[x])}return m.value}l.acquireContext=function(m){return this._reusableContextStack.length===0?new this.Context(m):this._reusableContextStack.pop().reset(m)},l.releaseContext=function(m){if(!(m instanceof this.Context))throw new Error("");this._reusableContextStack.push(m),m.currentPath=null},l.reportChanged=function(){this._changeReported=!0},l.wasChangeReported=function(){return this._changeReported};function d(m){function g(b){if(!(this instanceof g))throw new Error("");if(!(this instanceof a))throw new Error("");if(!(b instanceof r))throw new Error("");Object.defineProperty(this,"visitor",{value:m,writable:!1,enumerable:!0,configurable:!1}),this.currentPath=b,this.needToCallTraverse=!0,Object.seal(this)}if(!(m instanceof a))throw new Error("");var y=g.prototype=Object.create(m);return y.constructor=g,u(y,h),g}var h=Object.create(null);return h.reset=function(g){if(!(this instanceof this.Context))throw new Error("");if(!(g instanceof r))throw new Error("");return this.currentPath=g,this.needToCallTraverse=!0,this},h.invokeVisitorMethod=function(g){if(!(this instanceof this.Context))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");var y=this.visitor[g].call(this,this.currentPath);if(y===!1?this.needToCallTraverse=!1:y!==o&&(this.currentPath=this.currentPath.replace(y)[0],this.needToCallTraverse&&this.traverse(this.currentPath)),this.needToCallTraverse!==!1)throw new Error("Must either call this.traverse or return false in "+g);var b=this.currentPath;return b&&b.value},h.traverse=function(g,y){if(!(this instanceof this.Context))throw new Error("");if(!(g instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,p(g,a.fromMethodsObject(y||this.visitor))},h.visit=function(g,y){if(!(this instanceof this.Context))throw new Error("");if(!(g instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,a.fromMethodsObject(y||this.visitor).visitWithoutReset(g)},h.reportChanged=function(){this.visitor.reportChanged()},h.abort=function(){this.needToCallTraverse=!1,this.visitor.abort()},a}tt(()=>module);function eY(e){var t=e.use(Ft),r=t.getFieldNames,n=t.getFieldValue,i=t.builtInTypes.array,s=t.builtInTypes.object,o=t.builtInTypes.Date,a=t.builtInTypes.RegExp,c=Object.prototype.hasOwnProperty;function u(m,g,y){return i.check(y)?y.length=0:y=null,p(m,g,y)}u.assert=function(m,g){var y=[];if(!u(m,g,y))if(y.length===0){if(m!==g)throw new Error("Nodes must be equal")}else throw new Error("Nodes differ in the following path: "+y.map(l).join(""))};function l(m){return/[_$a-z][_$a-z0-9]*/i.test(m)?"."+m:"["+JSON.stringify(m)+"]"}function p(m,g,y){return m===g?!0:i.check(m)?d(m,g,y):s.check(m)?h(m,g,y):o.check(m)?o.check(g)&&+m==+g:a.check(m)?a.check(g)&&m.source===g.source&&m.global===g.global&&m.multiline===g.multiline&&m.ignoreCase===g.ignoreCase:m==g}function d(m,g,y){i.assert(m);var b=m.length;if(!i.check(g)||g.length!==b)return y&&y.push("length"),!1;for(var v=0;v<b;++v){if(y&&y.push(v),v in m!=v in g||!p(m[v],g[v],y))return!1;if(y){var C=y.pop();if(C!==v)throw new Error(""+C)}}return!0}function h(m,g,y){if(s.assert(m),!s.check(g))return!1;if(m.type!==g.type)return y&&y.push("type"),!1;var b=r(m),v=b.length,C=r(g),x=C.length;if(v===x){for(var D=0;D<v;++D){var E=b[D],S=n(m,E),F=n(g,E);if(y&&y.push(E),!p(S,F,y))return!1;if(y){var I=y.pop();if(I!==E)throw new Error(""+I)}}return!0}if(!y)return!1;var A=Object.create(null);for(D=0;D<v;++D)A[b[D]]=!0;for(D=0;D<x;++D){if(E=C[D],!c.call(A,E))return y.push(E),!1;delete A[E]}for(E in A){y.push(E);break}return!1}return u}tt(()=>module);function tY(e){let t=rY(),r=t.use(Ft);e.forEach(t.use),r.finalize();let n=t.use(ZW);return{Type:r.Type,builtInTypes:r.builtInTypes,namedTypes:r.namedTypes,builders:r.builders,defineMethod:r.defineMethod,getFieldNames:r.getFieldNames,getFieldValue:r.getFieldValue,eachField:r.eachField,someField:r.someField,getSupertypeNames:r.getSupertypeNames,getBuilderName:r.getBuilderName,astNodesAreEquivalent:t.use(eY),finalize:r.finalize,Path:t.use(x_),NodePath:t.use(v_),PathVisitor:n,use:t.use,visit:n.visit}}function rY(){let e=[],t=[];function r(i){var s=e.indexOf(i);return s===-1&&(s=e.length,e.push(i),t[s]=i(n)),t[s]}var n={use:r};return n}tt(()=>module);function D_(){return{BinaryOperators:["==","!=","===","!==","<","<=",">",">=","<<",">>",">>>","+","-","*","/","%","&","|","^","in","instanceof"],AssignmentOperators:["=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","|=","^=","&="],LogicalOperators:["||","&&"]}}tt(()=>module);function C_(e){let t=e.use(D_);return t.BinaryOperators.indexOf("**")<0&&t.BinaryOperators.push("**"),t.AssignmentOperators.indexOf("**=")<0&&t.AssignmentOperators.push("**="),t}tt(()=>module);function E_(e){let t=e.use(C_);return t.LogicalOperators.indexOf("??")<0&&t.LogicalOperators.push("??"),t}tt(()=>module);function nY(e){let t=e.use(E_);return t.LogicalOperators.forEach(r=>{let n=r+"=";t.AssignmentOperators.indexOf(n)<0&&t.AssignmentOperators.push(n)}),t}tt(()=>module);function iY(e){var t=e.use(Ft),r=t.Type,n=r.def,i=r.or,s=e.use(cn),o=s.defaults,a=s.geq;let{BinaryOperators:c,AssignmentOperators:u,LogicalOperators:l}=e.use(D_);n("Printable").field("loc",i(n("SourceLocation"),null),o.null,!0),n("Node").bases("Printable").field("type",String).field("comments",i([n("Comment")],null),o.null,!0),n("SourceLocation").field("start",n("Position")).field("end",n("Position")).field("source",i(String,null),o.null),n("Position").field("line",a(1)).field("column",a(0)),n("File").bases("Node").build("program","name").field("program",n("Program")).field("name",i(String,null),o.null),n("Program").bases("Node").build("body").field("body",[n("Statement")]),n("Function").bases("Node").field("id",i(n("Identifier"),null),o.null).field("params",[n("Pattern")]).field("body",n("BlockStatement")).field("generator",Boolean,o.false).field("async",Boolean,o.false),n("Statement").bases("Node"),n("EmptyStatement").bases("Statement").build(),n("BlockStatement").bases("Statement").build("body").field("body",[n("Statement")]),n("ExpressionStatement").bases("Statement").build("expression").field("expression",n("Expression")),n("IfStatement").bases("Statement").build("test","consequent","alternate").field("test",n("Expression")).field("consequent",n("Statement")).field("alternate",i(n("Statement"),null),o.null),n("LabeledStatement").bases("Statement").build("label","body").field("label",n("Identifier")).field("body",n("Statement")),n("BreakStatement").bases("Statement").build("label").field("label",i(n("Identifier"),null),o.null),n("ContinueStatement").bases("Statement").build("label").field("label",i(n("Identifier"),null),o.null),n("WithStatement").bases("Statement").build("object","body").field("object",n("Expression")).field("body",n("Statement")),n("SwitchStatement").bases("Statement").build("discriminant","cases","lexical").field("discriminant",n("Expression")).field("cases",[n("SwitchCase")]).field("lexical",Boolean,o.false),n("ReturnStatement").bases("Statement").build("argument").field("argument",i(n("Expression"),null)),n("ThrowStatement").bases("Statement").build("argument").field("argument",n("Expression")),n("TryStatement").bases("Statement").build("block","handler","finalizer").field("block",n("BlockStatement")).field("handler",i(n("CatchClause"),null),function(){return this.handlers&&this.handlers[0]||null}).field("handlers",[n("CatchClause")],function(){return this.handler?[this.handler]:[]},!0).field("guardedHandlers",[n("CatchClause")],o.emptyArray).field("finalizer",i(n("BlockStatement"),null),o.null),n("CatchClause").bases("Node").build("param","guard","body").field("param",n("Pattern")).field("guard",i(n("Expression"),null),o.null).field("body",n("BlockStatement")),n("WhileStatement").bases("Statement").build("test","body").field("test",n("Expression")).field("body",n("Statement")),n("DoWhileStatement").bases("Statement").build("body","test").field("body",n("Statement")).field("test",n("Expression")),n("ForStatement").bases("Statement").build("init","test","update","body").field("init",i(n("VariableDeclaration"),n("Expression"),null)).field("test",i(n("Expression"),null)).field("update",i(n("Expression"),null)).field("body",n("Statement")),n("ForInStatement").bases("Statement").build("left","right","body").field("left",i(n("VariableDeclaration"),n("Expression"))).field("right",n("Expression")).field("body",n("Statement")),n("DebuggerStatement").bases("Statement").build(),n("Declaration").bases("Statement"),n("FunctionDeclaration").bases("Function","Declaration").build("id","params","body").field("id",n("Identifier")),n("FunctionExpression").bases("Function","Expression").build("id","params","body"),n("VariableDeclaration").bases("Declaration").build("kind","declarations").field("kind",i("var","let","const")).field("declarations",[n("VariableDeclarator")]),n("VariableDeclarator").bases("Node").build("id","init").field("id",n("Pattern")).field("init",i(n("Expression"),null),o.null),n("Expression").bases("Node"),n("ThisExpression").bases("Expression").build(),n("ArrayExpression").bases("Expression").build("elements").field("elements",[i(n("Expression"),null)]),n("ObjectExpression").bases("Expression").build("properties").field("properties",[n("Property")]),n("Property").bases("Node").build("kind","key","value").field("kind",i("init","get","set")).field("key",i(n("Literal"),n("Identifier"))).field("value",n("Expression")),n("SequenceExpression").bases("Expression").build("expressions").field("expressions",[n("Expression")]);var p=i("-","+","!","~","typeof","void","delete");n("UnaryExpression").bases("Expression").build("operator","argument","prefix").field("operator",p).field("argument",n("Expression")).field("prefix",Boolean,o.true);let d=i(...c);n("BinaryExpression").bases("Expression").build("operator","left","right").field("operator",d).field("left",n("Expression")).field("right",n("Expression"));let h=i(...u);n("AssignmentExpression").bases("Expression").build("operator","left","right").field("operator",h).field("left",i(n("Pattern"),n("MemberExpression"))).field("right",n("Expression"));var m=i("++","--");n("UpdateExpression").bases("Expression").build("operator","argument","prefix").field("operator",m).field("argument",n("Expression")).field("prefix",Boolean);var g=i(...l);n("LogicalExpression").bases("Expression").build("operator","left","right").field("operator",g).field("left",n("Expression")).field("right",n("Expression")),n("ConditionalExpression").bases("Expression").build("test","consequent","alternate").field("test",n("Expression")).field("consequent",n("Expression")).field("alternate",n("Expression")),n("NewExpression").bases("Expression").build("callee","arguments").field("callee",n("Expression")).field("arguments",[n("Expression")]),n("CallExpression").bases("Expression").build("callee","arguments").field("callee",n("Expression")).field("arguments",[n("Expression")]),n("MemberExpression").bases("Expression").build("object","property","computed").field("object",n("Expression")).field("property",i(n("Identifier"),n("Expression"))).field("computed",Boolean,function(){var y=this.property.type;return y==="Literal"||y==="MemberExpression"||y==="BinaryExpression"}),n("Pattern").bases("Node"),n("SwitchCase").bases("Node").build("test","consequent").field("test",i(n("Expression"),null)).field("consequent",[n("Statement")]),n("Identifier").bases("Expression","Pattern").build("name").field("name",String).field("optional",Boolean,o.false),n("Literal").bases("Expression").build("value").field("value",i(String,Boolean,null,Number,RegExp,BigInt)),n("Comment").bases("Printable").field("value",String).field("leading",Boolean,o.true).field("trailing",Boolean,o.false)}tt(()=>module);function sY(e){e.use(iY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("Function").field("generator",Boolean,i.false).field("expression",Boolean,i.false).field("defaults",[n(r("Expression"),null)],i.emptyArray).field("rest",n(r("Identifier"),null),i.null),r("RestElement").bases("Pattern").build("argument").field("argument",r("Pattern")).field("typeAnnotation",n(r("TypeAnnotation"),r("TSTypeAnnotation"),null),i.null),r("SpreadElementPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("FunctionDeclaration").build("id","params","body","generator","expression").field("id",n(r("Identifier"),null)),r("FunctionExpression").build("id","params","body","generator","expression"),r("ArrowFunctionExpression").bases("Function","Expression").build("params","body","expression").field("id",null,i.null).field("body",n(r("BlockStatement"),r("Expression"))).field("generator",!1,i.false),r("ForOfStatement").bases("Statement").build("left","right","body").field("left",n(r("VariableDeclaration"),r("Pattern"))).field("right",r("Expression")).field("body",r("Statement")),r("YieldExpression").bases("Expression").build("argument","delegate").field("argument",n(r("Expression"),null)).field("delegate",Boolean,i.false),r("GeneratorExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",n(r("Expression"),null)),r("ComprehensionExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",n(r("Expression"),null)),r("ComprehensionBlock").bases("Node").build("left","right","each").field("left",r("Pattern")).field("right",r("Expression")).field("each",Boolean),r("Property").field("key",n(r("Literal"),r("Identifier"),r("Expression"))).field("value",n(r("Expression"),r("Pattern"))).field("method",Boolean,i.false).field("shorthand",Boolean,i.false).field("computed",Boolean,i.false),r("ObjectProperty").field("shorthand",Boolean,i.false),r("PropertyPattern").bases("Pattern").build("key","pattern").field("key",n(r("Literal"),r("Identifier"),r("Expression"))).field("pattern",r("Pattern")).field("computed",Boolean,i.false),r("ObjectPattern").bases("Pattern").build("properties").field("properties",[n(r("PropertyPattern"),r("Property"))]),r("ArrayPattern").bases("Pattern").build("elements").field("elements",[n(r("Pattern"),null)]),r("SpreadElement").bases("Node").build("argument").field("argument",r("Expression")),r("ArrayExpression").field("elements",[n(r("Expression"),r("SpreadElement"),r("RestElement"),null)]),r("NewExpression").field("arguments",[n(r("Expression"),r("SpreadElement"))]),r("CallExpression").field("arguments",[n(r("Expression"),r("SpreadElement"))]),r("AssignmentPattern").bases("Pattern").build("left","right").field("left",r("Pattern")).field("right",r("Expression")),r("MethodDefinition").bases("Declaration").build("kind","key","value","static").field("kind",n("constructor","method","get","set")).field("key",r("Expression")).field("value",r("Function")).field("computed",Boolean,i.false).field("static",Boolean,i.false);let s=n(r("MethodDefinition"),r("VariableDeclarator"),r("ClassPropertyDefinition"),r("ClassProperty"),r("StaticBlock"));r("ClassProperty").bases("Declaration").build("key").field("key",n(r("Literal"),r("Identifier"),r("Expression"))).field("computed",Boolean,i.false),r("ClassPropertyDefinition").bases("Declaration").build("definition").field("definition",s),r("ClassBody").bases("Declaration").build("body").field("body",[s]),r("ClassDeclaration").bases("Declaration").build("id","body","superClass").field("id",n(r("Identifier"),null)).field("body",r("ClassBody")).field("superClass",n(r("Expression"),null),i.null),r("ClassExpression").bases("Expression").build("id","body","superClass").field("id",n(r("Identifier"),null),i.null).field("body",r("ClassBody")).field("superClass",n(r("Expression"),null),i.null),r("Super").bases("Expression").build(),r("Specifier").bases("Node"),r("ModuleSpecifier").bases("Specifier").field("local",n(r("Identifier"),null),i.null).field("id",n(r("Identifier"),null),i.null).field("name",n(r("Identifier"),null),i.null),r("ImportSpecifier").bases("ModuleSpecifier").build("imported","local").field("imported",r("Identifier")),r("ImportDefaultSpecifier").bases("ModuleSpecifier").build("local"),r("ImportNamespaceSpecifier").bases("ModuleSpecifier").build("local"),r("ImportDeclaration").bases("Declaration").build("specifiers","source","importKind").field("specifiers",[n(r("ImportSpecifier"),r("ImportNamespaceSpecifier"),r("ImportDefaultSpecifier"))],i.emptyArray).field("source",r("Literal")).field("importKind",n("value","type"),function(){return"value"}),r("ExportNamedDeclaration").bases("Declaration").build("declaration","specifiers","source").field("declaration",n(r("Declaration"),null)).field("specifiers",[r("ExportSpecifier")],i.emptyArray).field("source",n(r("Literal"),null),i.null),r("ExportSpecifier").bases("ModuleSpecifier").build("local","exported").field("exported",r("Identifier")),r("ExportDefaultDeclaration").bases("Declaration").build("declaration").field("declaration",n(r("Declaration"),r("Expression"))),r("ExportAllDeclaration").bases("Declaration").build("source").field("source",r("Literal")),r("TaggedTemplateExpression").bases("Expression").build("tag","quasi").field("tag",r("Expression")).field("quasi",r("TemplateLiteral")),r("TemplateLiteral").bases("Expression").build("quasis","expressions").field("quasis",[r("TemplateElement")]).field("expressions",[r("Expression")]),r("TemplateElement").bases("Node").build("value","tail").field("value",{cooked:String,raw:String}).field("tail",Boolean),r("MetaProperty").bases("Expression").build("meta","property").field("meta",r("Identifier")).field("property",r("Identifier"))}tt(()=>module);function oY(e){e.use(C_),e.use(sY)}tt(()=>module);function aY(e){e.use(oY);let r=e.use(Ft).Type.def,n=e.use(cn).defaults;r("Function").field("async",Boolean,n.false),r("AwaitExpression").bases("Expression").build("argument").field("argument",r("Expression"))}tt(()=>module);function cY(e){e.use(aY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("ForOfStatement").field("await",Boolean,i.false),r("SpreadProperty").bases("Node").build("argument").field("argument",r("Expression")),r("ObjectExpression").field("properties",[n(r("Property"),r("SpreadProperty"),r("SpreadElement"))]),r("TemplateElement").field("value",{cooked:n(String,null),raw:String}),r("SpreadPropertyPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("ObjectPattern").field("properties",[n(r("PropertyPattern"),r("Property"),r("RestElement"),r("SpreadPropertyPattern"))])}tt(()=>module);function uY(e){e.use(cY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("CatchClause").field("param",n(r("Pattern"),null),i.null)}tt(()=>module);function lY(e){e.use(E_),e.use(uY);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,s=e.use(cn).defaults;r("ImportExpression").bases("Expression").build("source").field("source",r("Expression")),r("ExportAllDeclaration").bases("Declaration").build("source","exported").field("source",r("Literal")).field("exported",n(r("Identifier"),null,void 0),s.null),r("ChainElement").bases("Node").field("optional",Boolean,s.false),r("CallExpression").bases("Expression","ChainElement"),r("MemberExpression").bases("Expression","ChainElement"),r("ChainExpression").bases("Expression").build("expression").field("expression",r("ChainElement")),r("OptionalCallExpression").bases("CallExpression").build("callee","arguments","optional").field("optional",Boolean,s.true),r("OptionalMemberExpression").bases("MemberExpression").build("object","property","computed","optional").field("optional",Boolean,s.true)}tt(()=>module);function pY(e){e.use(nY),e.use(lY)}tt(()=>module);function dY(e){e.use(pY);let r=e.use(Ft).Type.def;r("StaticBlock").bases("Declaration").build("body").field("body",[r("Statement")])}tt(()=>module);function gl(e){e.use(dY);let t=e.use(Ft),r=t.Type,n=t.Type.def,i=r.or,o=e.use(cn).defaults;n("AwaitExpression").build("argument","all").field("argument",i(n("Expression"),null)).field("all",Boolean,o.false),n("Decorator").bases("Node").build("expression").field("expression",n("Expression")),n("Property").field("decorators",i([n("Decorator")],null),o.null),n("MethodDefinition").field("decorators",i([n("Decorator")],null),o.null),n("PrivateName").bases("Expression","Pattern").build("id").field("id",n("Identifier")),n("ClassPrivateProperty").bases("ClassProperty").build("key","value").field("key",n("PrivateName")).field("value",i(n("Expression"),null),o.null),n("ImportAttribute").bases("Node").build("key","value").field("key",i(n("Identifier"),n("Literal"))).field("value",n("Expression")),["ImportDeclaration","ExportAllDeclaration","ExportNamedDeclaration"].forEach(a=>{n(a).field("assertions",[n("ImportAttribute")],o.emptyArray)}),n("RecordExpression").bases("Expression").build("properties").field("properties",[i(n("ObjectProperty"),n("ObjectMethod"),n("SpreadElement"))]),n("TupleExpression").bases("Expression").build("elements").field("elements",[i(n("Expression"),n("SpreadElement"),null)]),n("ModuleExpression").bases("Node").build("body").field("body",n("Program"))}tt(()=>module);function fY(e){e.use(gl);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("JSXAttribute").bases("Node").build("name","value").field("name",n(r("JSXIdentifier"),r("JSXNamespacedName"))).field("value",n(r("Literal"),r("JSXExpressionContainer"),r("JSXElement"),r("JSXFragment"),null),i.null),r("JSXIdentifier").bases("Identifier").build("name").field("name",String),r("JSXNamespacedName").bases("Node").build("namespace","name").field("namespace",r("JSXIdentifier")).field("name",r("JSXIdentifier")),r("JSXMemberExpression").bases("MemberExpression").build("object","property").field("object",n(r("JSXIdentifier"),r("JSXMemberExpression"))).field("property",r("JSXIdentifier")).field("computed",Boolean,i.false);let s=n(r("JSXIdentifier"),r("JSXNamespacedName"),r("JSXMemberExpression"));r("JSXSpreadAttribute").bases("Node").build("argument").field("argument",r("Expression"));let o=[n(r("JSXAttribute"),r("JSXSpreadAttribute"))];r("JSXExpressionContainer").bases("Expression").build("expression").field("expression",n(r("Expression"),r("JSXEmptyExpression")));let a=[n(r("JSXText"),r("JSXExpressionContainer"),r("JSXSpreadChild"),r("JSXElement"),r("JSXFragment"),r("Literal"))];r("JSXElement").bases("Expression").build("openingElement","closingElement","children").field("openingElement",r("JSXOpeningElement")).field("closingElement",n(r("JSXClosingElement"),null),i.null).field("children",a,i.emptyArray).field("name",s,function(){return this.openingElement.name},!0).field("selfClosing",Boolean,function(){return this.openingElement.selfClosing},!0).field("attributes",o,function(){return this.openingElement.attributes},!0),r("JSXOpeningElement").bases("Node").build("name","attributes","selfClosing").field("name",s).field("attributes",o,i.emptyArray).field("selfClosing",Boolean,i.false),r("JSXClosingElement").bases("Node").build("name").field("name",s),r("JSXFragment").bases("Expression").build("openingFragment","closingFragment","children").field("openingFragment",r("JSXOpeningFragment")).field("closingFragment",r("JSXClosingFragment")).field("children",a,i.emptyArray),r("JSXOpeningFragment").bases("Node").build(),r("JSXClosingFragment").bases("Node").build(),r("JSXText").bases("Literal").build("value","raw").field("value",String).field("raw",String,function(){return this.value}),r("JSXEmptyExpression").bases("Node").build(),r("JSXSpreadChild").bases("Node").build("expression").field("expression",r("Expression"))}tt(()=>module);function w_(e){var t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults,s=n(r("TypeAnnotation"),r("TSTypeAnnotation"),null),o=n(r("TypeParameterDeclaration"),r("TSTypeParameterDeclaration"),null);r("Identifier").field("typeAnnotation",s,i.null),r("ObjectPattern").field("typeAnnotation",s,i.null),r("Function").field("returnType",s,i.null).field("typeParameters",o,i.null),r("ClassProperty").build("key","value","typeAnnotation","static").field("value",n(r("Expression"),null)).field("static",Boolean,i.false).field("typeAnnotation",s,i.null),["ClassDeclaration","ClassExpression"].forEach(a=>{r(a).field("typeParameters",o,i.null).field("superTypeParameters",n(r("TypeParameterInstantiation"),r("TSTypeParameterInstantiation"),null),i.null).field("implements",n([r("ClassImplements")],[r("TSExpressionWithTypeArguments")]),i.emptyArray)})}tt(()=>module);function S_(e){e.use(gl),e.use(w_);let t=e.use(Ft),r=t.Type.def,n=t.Type.or,i=e.use(cn).defaults;r("Flow").bases("Node"),r("FlowType").bases("Flow"),r("AnyTypeAnnotation").bases("FlowType").build(),r("EmptyTypeAnnotation").bases("FlowType").build(),r("MixedTypeAnnotation").bases("FlowType").build(),r("VoidTypeAnnotation").bases("FlowType").build(),r("SymbolTypeAnnotation").bases("FlowType").build(),r("NumberTypeAnnotation").bases("FlowType").build(),r("BigIntTypeAnnotation").bases("FlowType").build(),r("NumberLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("NumericLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("BigIntLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",null).field("raw",String),r("StringTypeAnnotation").bases("FlowType").build(),r("StringLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",String).field("raw",String),r("BooleanTypeAnnotation").bases("FlowType").build(),r("BooleanLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Boolean).field("raw",String),r("TypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullableTypeAnnotation").bases("FlowType").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullLiteralTypeAnnotation").bases("FlowType").build(),r("NullTypeAnnotation").bases("FlowType").build(),r("ThisTypeAnnotation").bases("FlowType").build(),r("ExistsTypeAnnotation").bases("FlowType").build(),r("ExistentialTypeParam").bases("FlowType").build(),r("FunctionTypeAnnotation").bases("FlowType").build("params","returnType","rest","typeParameters").field("params",[r("FunctionTypeParam")]).field("returnType",r("FlowType")).field("rest",n(r("FunctionTypeParam"),null)).field("typeParameters",n(r("TypeParameterDeclaration"),null)),r("FunctionTypeParam").bases("Node").build("name","typeAnnotation","optional").field("name",n(r("Identifier"),null)).field("typeAnnotation",r("FlowType")).field("optional",Boolean),r("ArrayTypeAnnotation").bases("FlowType").build("elementType").field("elementType",r("FlowType")),r("ObjectTypeAnnotation").bases("FlowType").build("properties","indexers","callProperties").field("properties",[n(r("ObjectTypeProperty"),r("ObjectTypeSpreadProperty"))]).field("indexers",[r("ObjectTypeIndexer")],i.emptyArray).field("callProperties",[r("ObjectTypeCallProperty")],i.emptyArray).field("inexact",n(Boolean,void 0),i.undefined).field("exact",Boolean,i.false).field("internalSlots",[r("ObjectTypeInternalSlot")],i.emptyArray),r("Variance").bases("Node").build("kind").field("kind",n("plus","minus"));let s=n(r("Variance"),"plus","minus",null);r("ObjectTypeProperty").bases("Node").build("key","value","optional").field("key",n(r("Literal"),r("Identifier"))).field("value",r("FlowType")).field("optional",Boolean).field("variance",s,i.null),r("ObjectTypeIndexer").bases("Node").build("id","key","value").field("id",r("Identifier")).field("key",r("FlowType")).field("value",r("FlowType")).field("variance",s,i.null).field("static",Boolean,i.false),r("ObjectTypeCallProperty").bases("Node").build("value").field("value",r("FunctionTypeAnnotation")).field("static",Boolean,i.false),r("QualifiedTypeIdentifier").bases("Node").build("qualification","id").field("qualification",n(r("Identifier"),r("QualifiedTypeIdentifier"))).field("id",r("Identifier")),r("GenericTypeAnnotation").bases("FlowType").build("id","typeParameters").field("id",n(r("Identifier"),r("QualifiedTypeIdentifier"))).field("typeParameters",n(r("TypeParameterInstantiation"),null)),r("MemberTypeAnnotation").bases("FlowType").build("object","property").field("object",r("Identifier")).field("property",n(r("MemberTypeAnnotation"),r("GenericTypeAnnotation"))),r("IndexedAccessType").bases("FlowType").build("objectType","indexType").field("objectType",r("FlowType")).field("indexType",r("FlowType")),r("OptionalIndexedAccessType").bases("FlowType").build("objectType","indexType","optional").field("objectType",r("FlowType")).field("indexType",r("FlowType")).field("optional",Boolean),r("UnionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("IntersectionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("TypeofTypeAnnotation").bases("FlowType").build("argument").field("argument",r("FlowType")),r("ObjectTypeSpreadProperty").bases("Node").build("argument").field("argument",r("FlowType")),r("ObjectTypeInternalSlot").bases("Node").build("id","value","optional","static","method").field("id",r("Identifier")).field("value",r("FlowType")).field("optional",Boolean).field("static",Boolean).field("method",Boolean),r("TypeParameterDeclaration").bases("Node").build("params").field("params",[r("TypeParameter")]),r("TypeParameterInstantiation").bases("Node").build("params").field("params",[r("FlowType")]),r("TypeParameter").bases("FlowType").build("name","variance","bound","default").field("name",String).field("variance",s,i.null).field("bound",n(r("TypeAnnotation"),null),i.null).field("default",n(r("FlowType"),null),i.null),r("ClassProperty").field("variance",s,i.null),r("ClassImplements").bases("Node").build("id").field("id",r("Identifier")).field("superClass",n(r("Expression"),null),i.null).field("typeParameters",n(r("TypeParameterInstantiation"),null),i.null),r("InterfaceTypeAnnotation").bases("FlowType").build("body","extends").field("body",r("ObjectTypeAnnotation")).field("extends",n([r("InterfaceExtends")],null),i.null),r("InterfaceDeclaration").bases("Declaration").build("id","body","extends").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterDeclaration"),null),i.null).field("body",r("ObjectTypeAnnotation")).field("extends",[r("InterfaceExtends")]),r("DeclareInterface").bases("InterfaceDeclaration").build("id","body","extends"),r("InterfaceExtends").bases("Node").build("id").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterInstantiation"),null),i.null),r("TypeAlias").bases("Declaration").build("id","typeParameters","right").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterDeclaration"),null)).field("right",r("FlowType")),r("DeclareTypeAlias").bases("TypeAlias").build("id","typeParameters","right"),r("OpaqueType").bases("Declaration").build("id","typeParameters","impltype","supertype").field("id",r("Identifier")).field("typeParameters",n(r("TypeParameterDeclaration"),null)).field("impltype",r("FlowType")).field("supertype",n(r("FlowType"),null)),r("DeclareOpaqueType").bases("OpaqueType").build("id","typeParameters","supertype").field("impltype",n(r("FlowType"),null)),r("TypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",r("Expression")).field("typeAnnotation",r("TypeAnnotation")),r("TupleTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("DeclareVariable").bases("Statement").build("id").field("id",r("Identifier")),r("DeclareFunction").bases("Statement").build("id").field("id",r("Identifier")).field("predicate",n(r("FlowPredicate"),null),i.null),r("DeclareClass").bases("InterfaceDeclaration").build("id"),r("DeclareModule").bases("Statement").build("id","body").field("id",n(r("Identifier"),r("Literal"))).field("body",r("BlockStatement")),r("DeclareModuleExports").bases("Statement").build("typeAnnotation").field("typeAnnotation",r("TypeAnnotation")),r("DeclareExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",n(r("DeclareVariable"),r("DeclareFunction"),r("DeclareClass"),r("FlowType"),r("TypeAlias"),r("DeclareOpaqueType"),r("InterfaceDeclaration"),null)).field("specifiers",[n(r("ExportSpecifier"),r("ExportBatchSpecifier"))],i.emptyArray).field("source",n(r("Literal"),null),i.null),r("DeclareExportAllDeclaration").bases("Declaration").build("source").field("source",n(r("Literal"),null),i.null),r("ImportDeclaration").field("importKind",n("value","type","typeof"),()=>"value"),r("FlowPredicate").bases("Flow"),r("InferredPredicate").bases("FlowPredicate").build(),r("DeclaredPredicate").bases("FlowPredicate").build("value").field("value",r("Expression")),r("Function").field("predicate",n(r("FlowPredicate"),null),i.null),r("CallExpression").field("typeArguments",n(null,r("TypeParameterInstantiation")),i.null),r("NewExpression").field("typeArguments",n(null,r("TypeParameterInstantiation")),i.null),r("EnumDeclaration").bases("Declaration").build("id","body").field("id",r("Identifier")).field("body",n(r("EnumBooleanBody"),r("EnumNumberBody"),r("EnumStringBody"),r("EnumSymbolBody"))),r("EnumBooleanBody").build("members","explicitType").field("members",[r("EnumBooleanMember")]).field("explicitType",Boolean),r("EnumNumberBody").build("members","explicitType").field("members",[r("EnumNumberMember")]).field("explicitType",Boolean),r("EnumStringBody").build("members","explicitType").field("members",n([r("EnumStringMember")],[r("EnumDefaultedMember")])).field("explicitType",Boolean),r("EnumSymbolBody").build("members").field("members",[r("EnumDefaultedMember")]),r("EnumBooleanMember").build("id","init").field("id",r("Identifier")).field("init",n(r("Literal"),Boolean)),r("EnumNumberMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumStringMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumDefaultedMember").build("id").field("id",r("Identifier"))}tt(()=>module);function mY(e){e.use(gl);var t=e.use(Ft),r=e.use(cn).defaults,n=t.Type.def,i=t.Type.or;n("VariableDeclaration").field("declarations",[i(n("VariableDeclarator"),n("Identifier"))]),n("Property").field("value",i(n("Expression"),n("Pattern"))),n("ArrayPattern").field("elements",[i(n("Pattern"),n("SpreadElement"),null)]),n("ObjectPattern").field("properties",[i(n("Property"),n("PropertyPattern"),n("SpreadPropertyPattern"),n("SpreadProperty"))]),n("ExportSpecifier").bases("ModuleSpecifier").build("id","name"),n("ExportBatchSpecifier").bases("Specifier").build(),n("ExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",i(n("Declaration"),n("Expression"),null)).field("specifiers",[i(n("ExportSpecifier"),n("ExportBatchSpecifier"))],r.emptyArray).field("source",i(n("Literal"),null),r.null),n("Block").bases("Comment").build("value","leading","trailing"),n("Line").bases("Comment").build("value","leading","trailing")}tt(()=>module);function T_(e){e.use(gl);let t=e.use(Ft),r=e.use(cn).defaults,n=t.Type.def,i=t.Type.or,{undefined:s}=t.builtInTypes;n("Noop").bases("Statement").build(),n("DoExpression").bases("Expression").build("body").field("body",[n("Statement")]),n("BindExpression").bases("Expression").build("object","callee").field("object",i(n("Expression"),null)).field("callee",n("Expression")),n("ParenthesizedExpression").bases("Expression").build("expression").field("expression",n("Expression")),n("ExportNamespaceSpecifier").bases("Specifier").build("exported").field("exported",n("Identifier")),n("ExportDefaultSpecifier").bases("Specifier").build("exported").field("exported",n("Identifier")),n("CommentBlock").bases("Comment").build("value","leading","trailing"),n("CommentLine").bases("Comment").build("value","leading","trailing"),n("Directive").bases("Node").build("value").field("value",n("DirectiveLiteral")),n("DirectiveLiteral").bases("Node","Expression").build("value").field("value",String,r["use strict"]),n("InterpreterDirective").bases("Node").build("value").field("value",String),n("BlockStatement").bases("Statement").build("body").field("body",[n("Statement")]).field("directives",[n("Directive")],r.emptyArray),n("Program").bases("Node").build("body").field("body",[n("Statement")]).field("directives",[n("Directive")],r.emptyArray).field("interpreter",i(n("InterpreterDirective"),null),r.null);function o(l=String,p){return["extra",{rawValue:l,raw:String},function(){let h=t.getFieldValue(this,"value");return{rawValue:h,raw:p?p(h):String(h)}}]}n("StringLiteral").bases("Literal").build("value").field("value",String).field(...o(String,l=>JSON.stringify(l))),n("NumericLiteral").bases("Literal").build("value").field("value",Number).field("raw",i(String,null),r.null).field(...o(Number)),n("BigIntLiteral").bases("Literal").build("value").field("value",i(String,Number)).field(...o(String,l=>l+"n")),n("DecimalLiteral").bases("Literal").build("value").field("value",String).field(...o(String,l=>l+"m")),n("NullLiteral").bases("Literal").build().field("value",null,r.null),n("BooleanLiteral").bases("Literal").build("value").field("value",Boolean),n("RegExpLiteral").bases("Literal").build("pattern","flags").field("pattern",String).field("flags",String).field("value",RegExp,function(){return new RegExp(this.pattern,this.flags)}).field(...o(i(RegExp,s),l=>`/${l.pattern}/${l.flags||""}`)).field("regex",{pattern:String,flags:String},function(){return{pattern:this.pattern,flags:this.flags}});var a=i(n("Property"),n("ObjectMethod"),n("ObjectProperty"),n("SpreadProperty"),n("SpreadElement"));n("ObjectExpression").bases("Expression").build("properties").field("properties",[a]),n("ObjectMethod").bases("Node","Function").build("kind","key","params","body","computed").field("kind",i("method","get","set")).field("key",i(n("Literal"),n("Identifier"),n("Expression"))).field("params",[n("Pattern")]).field("body",n("BlockStatement")).field("computed",Boolean,r.false).field("generator",Boolean,r.false).field("async",Boolean,r.false).field("accessibility",i(n("Literal"),null),r.null).field("decorators",i([n("Decorator")],null),r.null),n("ObjectProperty").bases("Node").build("key","value").field("key",i(n("Literal"),n("Identifier"),n("Expression"))).field("value",i(n("Expression"),n("Pattern"))).field("accessibility",i(n("Literal"),null),r.null).field("computed",Boolean,r.false);var c=i(n("MethodDefinition"),n("VariableDeclarator"),n("ClassPropertyDefinition"),n("ClassProperty"),n("ClassPrivateProperty"),n("ClassMethod"),n("ClassPrivateMethod"),n("ClassAccessorProperty"),n("StaticBlock"));n("ClassBody").bases("Declaration").build("body").field("body",[c]),n("ClassMethod").bases("Declaration","Function").build("kind","key","params","body","computed","static").field("key",i(n("Literal"),n("Identifier"),n("Expression"))),n("ClassPrivateMethod").bases("Declaration","Function").build("key","params","body","kind","computed","static").field("key",n("PrivateName")),n("ClassAccessorProperty").bases("Declaration").build("key","value","decorators","computed","static").field("key",i(n("Literal"),n("Identifier"),n("PrivateName"),n("Expression"))).field("value",i(n("Expression"),null),r.null),["ClassMethod","ClassPrivateMethod"].forEach(l=>{n(l).field("kind",i("get","set","method","constructor"),()=>"method").field("body",n("BlockStatement")).field("access",i("public","private","protected",null),r.null)}),["ClassMethod","ClassPrivateMethod","ClassAccessorProperty"].forEach(l=>{n(l).field("computed",Boolean,r.false).field("static",Boolean,r.false).field("abstract",Boolean,r.false).field("accessibility",i("public","private","protected",null),r.null).field("decorators",i([n("Decorator")],null),r.null).field("definite",Boolean,r.false).field("optional",Boolean,r.false).field("override",Boolean,r.false).field("readonly",Boolean,r.false)});var u=i(n("Property"),n("PropertyPattern"),n("SpreadPropertyPattern"),n("SpreadProperty"),n("ObjectProperty"),n("RestProperty"),n("RestElement"));n("ObjectPattern").bases("Pattern").build("properties").field("properties",[u]).field("decorators",i([n("Decorator")],null),r.null),n("SpreadProperty").bases("Node").build("argument").field("argument",n("Expression")),n("RestProperty").bases("Node").build("argument").field("argument",n("Expression")),n("ForAwaitStatement").bases("Statement").build("left","right","body").field("left",i(n("VariableDeclaration"),n("Expression"))).field("right",n("Expression")).field("body",n("Statement")),n("Import").bases("Expression").build()}tt(()=>module);function hY(e){let r=e.use(Ft).Type.def;e.use(T_),e.use(S_),r("V8IntrinsicIdentifier").bases("Expression").build("name").field("name",String),r("TopicReference").bases("Expression").build()}tt(()=>module);function gY(e){e.use(T_),e.use(w_);var t=e.use(Ft),r=t.namedTypes,n=t.Type.def,i=t.Type.or,s=e.use(cn).defaults,o=t.Type.from(function(l,p){return!!(r.StringLiteral&&r.StringLiteral.check(l,p)||r.Literal&&r.Literal.check(l,p)&&typeof l.value=="string")},"StringLiteral");n("TSType").bases("Node");var a=i(n("Identifier"),n("TSQualifiedName"));n("TSTypeReference").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("typeName","typeParameters").field("typeName",a),n("TSHasOptionalTypeParameterInstantiation").field("typeParameters",i(n("TSTypeParameterInstantiation"),null),s.null),n("TSHasOptionalTypeParameters").field("typeParameters",i(n("TSTypeParameterDeclaration"),null,void 0),s.null),n("TSHasOptionalTypeAnnotation").field("typeAnnotation",i(n("TSTypeAnnotation"),null),s.null),n("TSQualifiedName").bases("Node").build("left","right").field("left",a).field("right",a),n("TSAsExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TSType")).field("extra",i({parenthesized:Boolean},null),s.null),n("TSTypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TSType")),n("TSSatisfiesExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",n("Expression")).field("typeAnnotation",n("TSType")),n("TSNonNullExpression").bases("Expression","Pattern").build("expression").field("expression",n("Expression")),["TSAnyKeyword","TSBigIntKeyword","TSBooleanKeyword","TSNeverKeyword","TSNullKeyword","TSNumberKeyword","TSObjectKeyword","TSStringKeyword","TSSymbolKeyword","TSUndefinedKeyword","TSUnknownKeyword","TSVoidKeyword","TSIntrinsicKeyword","TSThisType"].forEach(l=>{n(l).bases("TSType").build()}),n("TSArrayType").bases("TSType").build("elementType").field("elementType",n("TSType")),n("TSLiteralType").bases("TSType").build("literal").field("literal",i(n("NumericLiteral"),n("StringLiteral"),n("BooleanLiteral"),n("TemplateLiteral"),n("UnaryExpression"),n("BigIntLiteral"))),n("TemplateLiteral").field("expressions",i([n("Expression")],[n("TSType")])),["TSUnionType","TSIntersectionType"].forEach(l=>{n(l).bases("TSType").build("types").field("types",[n("TSType")])}),n("TSConditionalType").bases("TSType").build("checkType","extendsType","trueType","falseType").field("checkType",n("TSType")).field("extendsType",n("TSType")).field("trueType",n("TSType")).field("falseType",n("TSType")),n("TSInferType").bases("TSType").build("typeParameter").field("typeParameter",n("TSTypeParameter")),n("TSParenthesizedType").bases("TSType").build("typeAnnotation").field("typeAnnotation",n("TSType"));var c=[i(n("Identifier"),n("RestElement"),n("ArrayPattern"),n("ObjectPattern"))];["TSFunctionType","TSConstructorType"].forEach(l=>{n(l).bases("TSType","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters").field("parameters",c)}),n("TSDeclareFunction").bases("Declaration","TSHasOptionalTypeParameters").build("id","params","returnType").field("declare",Boolean,s.false).field("async",Boolean,s.false).field("generator",Boolean,s.false).field("id",i(n("Identifier"),null),s.null).field("params",[n("Pattern")]).field("returnType",i(n("TSTypeAnnotation"),n("Noop"),null),s.null),n("TSDeclareMethod").bases("Declaration","TSHasOptionalTypeParameters").build("key","params","returnType").field("async",Boolean,s.false).field("generator",Boolean,s.false).field("params",[n("Pattern")]).field("abstract",Boolean,s.false).field("accessibility",i("public","private","protected",void 0),s.undefined).field("static",Boolean,s.false).field("computed",Boolean,s.false).field("optional",Boolean,s.false).field("key",i(n("Identifier"),n("StringLiteral"),n("NumericLiteral"),n("Expression"))).field("kind",i("get","set","method","constructor"),function(){return"method"}).field("access",i("public","private","protected",void 0),s.undefined).field("decorators",i([n("Decorator")],null),s.null).field("returnType",i(n("TSTypeAnnotation"),n("Noop"),null),s.null),n("TSMappedType").bases("TSType").build("typeParameter","typeAnnotation").field("readonly",i(Boolean,"+","-"),s.false).field("typeParameter",n("TSTypeParameter")).field("optional",i(Boolean,"+","-"),s.false).field("typeAnnotation",i(n("TSType"),null),s.null),n("TSTupleType").bases("TSType").build("elementTypes").field("elementTypes",[i(n("TSType"),n("TSNamedTupleMember"))]),n("TSNamedTupleMember").bases("TSType").build("label","elementType","optional").field("label",n("Identifier")).field("optional",Boolean,s.false).field("elementType",n("TSType")),n("TSRestType").bases("TSType").build("typeAnnotation").field("typeAnnotation",n("TSType")),n("TSOptionalType").bases("TSType").build("typeAnnotation").field("typeAnnotation",n("TSType")),n("TSIndexedAccessType").bases("TSType").build("objectType","indexType").field("objectType",n("TSType")).field("indexType",n("TSType")),n("TSTypeOperator").bases("TSType").build("operator").field("operator",String).field("typeAnnotation",n("TSType")),n("TSTypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",i(n("TSType"),n("TSTypeAnnotation"))),n("TSIndexSignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",[n("Identifier")]).field("readonly",Boolean,s.false),n("TSPropertySignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("key","typeAnnotation","optional").field("key",n("Expression")).field("computed",Boolean,s.false).field("readonly",Boolean,s.false).field("optional",Boolean,s.false).field("initializer",i(n("Expression"),null),s.null),n("TSMethodSignature").bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("key","parameters","typeAnnotation").field("key",n("Expression")).field("computed",Boolean,s.false).field("optional",Boolean,s.false).field("parameters",c),n("TSTypePredicate").bases("TSTypeAnnotation","TSType").build("parameterName","typeAnnotation","asserts").field("parameterName",i(n("Identifier"),n("TSThisType"))).field("typeAnnotation",i(n("TSTypeAnnotation"),null),s.null).field("asserts",Boolean,s.false),["TSCallSignatureDeclaration","TSConstructSignatureDeclaration"].forEach(l=>{n(l).bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",c)}),n("TSEnumMember").bases("Node").build("id","initializer").field("id",i(n("Identifier"),o)).field("initializer",i(n("Expression"),null),s.null),n("TSTypeQuery").bases("TSType").build("exprName").field("exprName",i(a,n("TSImportType")));var u=i(n("TSCallSignatureDeclaration"),n("TSConstructSignatureDeclaration"),n("TSIndexSignature"),n("TSMethodSignature"),n("TSPropertySignature"));n("TSTypeLiteral").bases("TSType").build("members").field("members",[u]),n("TSTypeParameter").bases("Identifier").build("name","constraint","default").field("name",i(n("Identifier"),String)).field("constraint",i(n("TSType"),void 0),s.undefined).field("default",i(n("TSType"),void 0),s.undefined),n("TSTypeAssertion").bases("Expression","Pattern").build("typeAnnotation","expression").field("typeAnnotation",n("TSType")).field("expression",n("Expression")).field("extra",i({parenthesized:Boolean},null),s.null),n("TSTypeParameterDeclaration").bases("Declaration").build("params").field("params",[n("TSTypeParameter")]),n("TSInstantiationExpression").bases("Expression","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",n("Expression")),n("TSTypeParameterInstantiation").bases("Node").build("params").field("params",[n("TSType")]),n("TSEnumDeclaration").bases("Declaration").build("id","members").field("id",n("Identifier")).field("const",Boolean,s.false).field("declare",Boolean,s.false).field("members",[n("TSEnumMember")]).field("initializer",i(n("Expression"),null),s.null),n("TSTypeAliasDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","typeAnnotation").field("id",n("Identifier")).field("declare",Boolean,s.false).field("typeAnnotation",n("TSType")),n("TSModuleBlock").bases("Node").build("body").field("body",[n("Statement")]),n("TSModuleDeclaration").bases("Declaration").build("id","body").field("id",i(o,a)).field("declare",Boolean,s.false).field("global",Boolean,s.false).field("body",i(n("TSModuleBlock"),n("TSModuleDeclaration"),null),s.null),n("TSImportType").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("argument","qualifier","typeParameters").field("argument",o).field("qualifier",i(a,void 0),s.undefined),n("TSImportEqualsDeclaration").bases("Declaration").build("id","moduleReference").field("id",n("Identifier")).field("isExport",Boolean,s.false).field("moduleReference",i(a,n("TSExternalModuleReference"))),n("TSExternalModuleReference").bases("Declaration").build("expression").field("expression",o),n("TSExportAssignment").bases("Statement").build("expression").field("expression",n("Expression")),n("TSNamespaceExportDeclaration").bases("Declaration").build("id").field("id",n("Identifier")),n("TSInterfaceBody").bases("Node").build("body").field("body",[u]),n("TSExpressionWithTypeArguments").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",a),n("TSInterfaceDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","body").field("id",a).field("declare",Boolean,s.false).field("extends",i([n("TSExpressionWithTypeArguments")],null),s.null).field("body",n("TSInterfaceBody")),n("TSParameterProperty").bases("Pattern").build("parameter").field("accessibility",i("public","private","protected",void 0),s.undefined).field("readonly",Boolean,s.false).field("parameter",i(n("Identifier"),n("AssignmentPattern"))),n("ClassProperty").field("access",i("public","private","protected",void 0),s.undefined),n("ClassAccessorProperty").bases("Declaration","TSHasOptionalTypeAnnotation"),n("ClassBody").field("body",[i(n("MethodDefinition"),n("VariableDeclarator"),n("ClassPropertyDefinition"),n("ClassProperty"),n("ClassPrivateProperty"),n("ClassAccessorProperty"),n("ClassMethod"),n("ClassPrivateMethod"),n("StaticBlock"),n("TSDeclareMethod"),u)])}tt(()=>module);var Yn;Yn||(Yn={});var{astNodesAreEquivalent:g_e,builders:sc,builtInTypes:Jn,defineMethod:y_e,eachField:b_e,finalize:x_e,getBuilderName:v_e,getFieldNames:yY,getFieldValue:ts,getSupertypeNames:D_e,namedTypes:bY,NodePath:xY,Path:C_e,PathVisitor:E_e,someField:vY,Type:w_e,use:S_e,visit:T_e}=tY([gl,fY,S_,mY,hY,gY]);Object.assign(Yn,bY);var xf=Yn,n_=Rf.default.SourceMapConsumer,DY=Rf.default.SourceMapGenerator,A_=Object.prototype.hasOwnProperty;function CY(){return`
1186
1186
  `}function i_(e,t,r){return e&&A_.call(e,t)?e[t]:r}function EY(...e){let t={},r=e.length;for(let n=0;n<r;++n){let i=Object.keys(e[n]),s=i.length;for(let o=0;o<s;++o)t[i[o]]=!0}return t}function je(e,t){return e.line-t.line||e.column-t.column}function Ms(e){return{line:e.line,column:e.column}}function wY(e,t){if(e){if(!t)return e}else return t||null;let r=new n_(e),n=new n_(t),i=new DY({file:t.file,sourceRoot:t.sourceRoot}),s={};return n.eachMapping(function(o){let a=r.originalPositionFor({line:o.originalLine,column:o.originalColumn}),c=a.source;if(c===null)return;i.addMapping({source:c,original:Ms(a),generated:{line:o.generatedLine,column:o.generatedColumn},name:o.name});let u=r.sourceContentFor(c);u&&!A_.call(s,c)&&(s[c]=u,i.setSourceContent(c,u))}),i.toJSON()}function P_(e,t){if(!e.loc)return null;let r={start:e.loc.start,end:e.loc.end};function n(i){fx(r,i.loc)}return e.declaration&&e.declaration.decorators&&Of(e)&&e.declaration.decorators.forEach(n),je(r.start,r.end)<0&&(r.start=Ms(r.start),t.skipSpaces(r.start,!1,!0),je(r.start,r.end)<0&&(r.end=Ms(r.end),t.skipSpaces(r.end,!0,!0))),e.comments&&e.comments.forEach(n),r}function fx(e,t){e&&t&&(je(t.start,e.start)<0&&(e.start=t.start),je(e.end,t.end)<0&&(e.end=t.end))}function Ex(e,t){let r=e.loc;if(r&&(r.start.line<1&&(r.start.line=1),r.end.line<1&&(r.end.line=1)),e.type==="File"&&(r.start=t.firstPos(),r.end=t.lastPos()),SY(e,t),TY(e,t),r&&e.decorators)e.decorators.forEach(function(n){fx(r,n.loc)});else if(e.declaration&&Of(e)){e.declaration.loc=null;let n=e.declaration.decorators;n&&n.forEach(function(i){fx(r,i.loc)})}else if(xf.MethodDefinition&&xf.MethodDefinition.check(e)||xf.Property.check(e)&&(e.method||e.shorthand))e.value.loc=null,xf.FunctionExpression.check(e.value)&&(e.value.id=null);else if(e.type==="ObjectTypeProperty"){let n=e.loc,i=n&&n.end;i&&(i=Ms(i),t.prevPos(i)&&t.charAt(i)===","&&(i=t.skipSpaces(i,!0,!0))&&(n.end=i))}}function SY(e,t){if(e.type!=="ForStatement")return;function r(n){let i=n&&n.loc,s=i&&i.start,o=i&&Ms(i.end);for(;s&&o&&je(s,o)<0&&(t.prevPos(o),t.charAt(o)===";");)i.end.line=o.line,i.end.column=o.column}r(e.init),r(e.test),r(e.update)}function TY(e,t){if(e.type==="TemplateLiteral"&&e.quasis.length!==0){if(e.loc){let r=Ms(e.loc.start),n=e.quasis[0];je(n.loc.start,r)<0&&(n.loc.start=r);let i=Ms(e.loc.end),s=e.quasis[e.quasis.length-1];je(i,s.loc.end)<0&&(s.loc.end=i)}e.expressions.forEach(function(r,n){let i=t.skipSpaces(r.loc.start,!0,!1);if(t.prevPos(i)&&t.charAt(i)==="{"&&t.prevPos(i)&&t.charAt(i)==="$"){let o=e.quasis[n];je(i,o.loc.end)<0&&(o.loc.end=i)}let s=t.skipSpaces(r.loc.end,!1,!1);if(t.charAt(s)==="}"){let o=e.quasis[n+1];je(o.loc.start,s)<0&&(o.loc.start=s)}})}}function Of(e){if(e)switch(e.type){case"ExportDeclaration":case"ExportDefaultDeclaration":case"ExportDefaultSpecifier":case"DeclareExportDeclaration":case"ExportNamedDeclaration":case"ExportAllDeclaration":return!0}return!1}function F_(e){let t=e.getParentNode();return e.getName()==="declaration"&&Of(t)?t:null}function pl(e,t){let r=e.trailingComma;return typeof r=="object"?!!r[t]:!!r}var mx={tabWidth:4,useTabs:!1,reuseWhitespace:!0,lineTerminator:CY(),wrapColumn:74,sourceFileName:null,sourceMapName:null,sourceRoot:null,inputSourceMap:null,range:!1,tolerant:!0,quote:null,trailingComma:!1,arrayBracketSpacing:!1,objectCurlySpacing:!0,arrowParensAlways:!1,flowObjectCommas:!0,tokens:!0},AY=mx.hasOwnProperty;function Bf(e){let t=e||mx;function r(n){return AY.call(t,n)?t[n]:mx[n]}return{tabWidth:+r("tabWidth"),useTabs:!!r("useTabs"),reuseWhitespace:!!r("reuseWhitespace"),lineTerminator:r("lineTerminator"),wrapColumn:Math.max(r("wrapColumn"),0),sourceFileName:r("sourceFileName"),sourceMapName:r("sourceMapName"),sourceRoot:r("sourceRoot"),inputSourceMap:r("inputSourceMap"),parser:r("esprima")||r("parser"),range:r("range"),tolerant:r("tolerant"),quote:r("quote"),trailingComma:r("trailingComma"),arrayBracketSpacing:r("arrayBracketSpacing"),objectCurlySpacing:r("objectCurlySpacing"),arrowParensAlways:r("arrowParensAlways"),flowObjectCommas:r("flowObjectCommas"),tokens:!!r("tokens")}}var hx=class e{constructor(t,r,n=r){this.sourceLines=t,this.sourceLoc=r,this.targetLoc=n}slice(t,r,n=t.lastPos()){let i=this.sourceLines,s=this.sourceLoc,o=this.targetLoc;function a(c){let u=s[c],l=o[c],p=r;return c==="end"&&(p=n),PY(i,u,t,l,p)}if(je(r,o.start)<=0)if(je(o.end,n)<=0)o={start:Bs(o.start,r.line,r.column),end:Bs(o.end,r.line,r.column)};else{if(je(n,o.start)<=0)return null;s={start:s.start,end:a("end")},o={start:Bs(o.start,r.line,r.column),end:Bs(n,r.line,r.column)}}else{if(je(o.end,r)<=0)return null;je(o.end,n)<=0?(s={start:a("start"),end:s.end},o={start:{line:1,column:0},end:Bs(o.end,r.line,r.column)}):(s={start:a("start"),end:a("end")},o={start:{line:1,column:0},end:Bs(n,r.line,r.column)})}return new e(this.sourceLines,s,o)}add(t,r){return new e(this.sourceLines,this.sourceLoc,{start:s_(this.targetLoc.start,t,r),end:s_(this.targetLoc.end,t,r)})}subtract(t,r){return new e(this.sourceLines,this.sourceLoc,{start:Bs(this.targetLoc.start,t,r),end:Bs(this.targetLoc.end,t,r)})}indent(t,r=!1,n=!1){if(t===0)return this;let i=this.targetLoc,s=i.start.line,o=i.end.line;if(r&&s===1&&o===1)return this;if(i={start:i.start,end:i.end},!r||s>1){let a=i.start.column+t;i.start={line:s,column:n?Math.max(0,a):a}}if(!r||o>1){let a=i.end.column+t;i.end={line:o,column:n?Math.max(0,a):a}}return new e(this.sourceLines,this.sourceLoc,i)}};function s_(e,t,r){return{line:e.line+t-1,column:e.line===1?e.column+r:e.column}}function Bs(e,t,r){return{line:e.line-t+1,column:e.line===t?e.column-r:e.column}}function PY(e,t,r,n,i){let s=je(n,i);if(s===0)return t;let o,a;if(s<0){o=e.skipSpaces(t)||e.lastPos(),a=r.skipSpaces(n)||r.lastPos();let c=i.line-a.line;for(o.line+=c,a.line+=c,c>0&&(o.column=0,a.column=0);je(a,i)<0&&r.nextPos(a,!0););}else{o=e.skipSpaces(t,!0)||e.firstPos(),a=r.skipSpaces(n,!0)||r.firstPos();let c=i.line-a.line;for(o.line+=c,a.line+=c,c<0&&(o.column=e.getLineLength(o.line),a.column=r.getLineLength(a.line));je(i,a)<0&&r.prevPos(a,!0););}return o}var FY=Object.defineProperty,_Y=(e,t,r)=>t in e?FY(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,il=(e,t,r)=>(_Y(e,typeof t!="symbol"?t+"":t,r),r),nc=class e{constructor(t,r=null){this.infos=t,il(this,"length"),il(this,"name"),il(this,"mappings",[]),il(this,"cachedSourceMap",null),il(this,"cachedTabWidth"),this.length=t.length,this.name=r||null,this.name&&this.mappings.push(new hx(this,{start:this.firstPos(),end:this.lastPos()}))}toString(t){return this.sliceString(this.firstPos(),this.lastPos(),t)}getSourceMap(t,r){if(!t)return null;let n=this;function i(a){return a=a||{},a.file=t,r&&(a.sourceRoot=r),a}if(n.cachedSourceMap)return i(n.cachedSourceMap.toJSON());let s=new Rf.default.SourceMapGenerator(i()),o={};return n.mappings.forEach(function(a){let c=a.sourceLines.skipSpaces(a.sourceLoc.start)||a.sourceLines.lastPos(),u=n.skipSpaces(a.targetLoc.start)||n.lastPos();for(;je(c,a.sourceLoc.end)<0&&je(u,a.targetLoc.end)<0;){a.sourceLines.charAt(c),n.charAt(u);let l=a.sourceLines.name;if(s.addMapping({source:l,original:{line:c.line,column:c.column},generated:{line:u.line,column:u.column}}),!gx.call(o,l)){let p=a.sourceLines.toString();s.setSourceContent(l,p),o[l]=p}n.nextPos(u,!0),a.sourceLines.nextPos(c,!0)}}),n.cachedSourceMap=s,s.toJSON()}bootstrapCharAt(t){let r=t.line,n=t.column,i=this.toString().split(yx),s=i[r-1];return typeof s>"u"?"":n===s.length&&r<i.length?`
1187
1187
  `:n>=s.length?"":s.charAt(n)}charAt(t){let r=t.line,n=t.column,i=this,s=i.infos,o=s[r-1],a=n;if(typeof o>"u"||a<0)return"";let c=this.getIndentAt(r);return a<c?" ":(a+=o.sliceStart-c,a===o.sliceEnd&&r<this.length?`
1188
1188
  `:a>=o.sliceEnd?"":o.line.charAt(a))}stripMargin(t,r){if(t===0)return this;if(r&&this.length===1)return this;let n=new e(this.infos.map(function(i,s){return i.line&&(s>0||!r)&&(i={...i,indent:Math.max(0,i.indent-t)}),i}));if(this.mappings.length>0){let i=n.mappings;this.mappings.forEach(function(s){i.push(s.indent(t,r,!0))})}return n}indent(t){if(t===0)return this;let r=new e(this.infos.map(function(n){return n.line&&!n.locked&&(n={...n,indent:n.indent+t}),n}));if(this.mappings.length>0){let n=r.mappings;this.mappings.forEach(function(i){n.push(i.indent(t))})}return r}indentTail(t){if(t===0)return this;if(this.length<2)return this;let r=new e(this.infos.map(function(n,i){return i>0&&n.line&&!n.locked&&(n={...n,indent:n.indent+t}),n}));if(this.mappings.length>0){let n=r.mappings;this.mappings.forEach(function(i){n.push(i.indent(t,!0))})}return r}lockIndentTail(){return this.length<2?this:new e(this.infos.map((t,r)=>({...t,locked:r>0})))}getIndentAt(t){return Math.max(this.infos[t-1].indent,0)}guessTabWidth(){if(typeof this.cachedTabWidth=="number")return this.cachedTabWidth;let t=[],r=0;for(let s=1,o=this.length;s<=o;++s){let a=this.infos[s-1],c=a.line.slice(a.sliceStart,a.sliceEnd);if(Za(c))continue;let u=Math.abs(a.indent-r);t[u]=~~t[u]+1,r=a.indent}let n=-1,i=2;for(let s=1;s<t.length;s+=1)gx.call(t,s)&&t[s]>n&&(n=t[s],i=s);return this.cachedTabWidth=i}startsWithComment(){if(this.infos.length===0)return!1;let t=this.infos[0],r=t.sliceStart,n=t.sliceEnd,i=t.line.slice(r,n).trim();return i.length===0||i.slice(0,2)==="//"||i.slice(0,2)==="/*"}isOnlyWhitespace(){return Za(this.toString())}isPrecededOnlyByWhitespace(t){let r=this.infos[t.line-1],n=Math.max(r.indent,0),i=t.column-n;if(i<=0)return!0;let s=r.sliceStart,o=Math.min(s+i,r.sliceEnd),a=r.line.slice(s,o);return Za(a)}getLineLength(t){let r=this.infos[t-1];return this.getIndentAt(t)+r.sliceEnd-r.sliceStart}nextPos(t,r=!1){let n=Math.max(t.line,0);return Math.max(t.column,0)<this.getLineLength(n)?(t.column+=1,r?!!this.skipSpaces(t,!1,!0):!0):n<this.length?(t.line+=1,t.column=0,r?!!this.skipSpaces(t,!1,!0):!0):!1}prevPos(t,r=!1){let n=t.line,i=t.column;if(i<1){if(n-=1,n<1)return!1;i=this.getLineLength(n)}else i=Math.min(i-1,this.getLineLength(n));return t.line=n,t.column=i,r?!!this.skipSpaces(t,!0,!0):!0}firstPos(){return{line:1,column:0}}lastPos(){return{line:this.length,column:this.getLineLength(this.length)}}skipSpaces(t,r=!1,n=!1){if(t?t=n?t:{line:t.line,column:t.column}:r?t=this.lastPos():t=this.firstPos(),r){for(;this.prevPos(t);)if(!Za(this.charAt(t))&&this.nextPos(t))return t;return null}else{for(;Za(this.charAt(t));)if(!this.nextPos(t))return null;return t}}trimLeft(){let t=this.skipSpaces(this.firstPos(),!1,!0);return t?this.slice(t):No}trimRight(){let t=this.skipSpaces(this.lastPos(),!0,!0);return t?this.slice(this.firstPos(),t):No}trim(){let t=this.skipSpaces(this.firstPos(),!1,!0);if(t===null)return No;let r=this.skipSpaces(this.lastPos(),!0,!0);return r===null?No:this.slice(t,r)}eachPos(t,r=this.firstPos(),n=!1){let i=this.firstPos();if(r&&(i.line=r.line,i.column=r.column),!(n&&!this.skipSpaces(i,!1,!0)))do t.call(this,i);while(this.nextPos(i,n))}bootstrapSlice(t,r){let n=this.toString().split(yx).slice(t.line-1,r.line);return n.length>0&&(n.push(n.pop().slice(0,r.column)),n[0]=n[0].slice(t.column)),j(n.join(`
@@ -1278,7 +1278,7 @@ ${" ".repeat(6+i)}^`),u));t+=`
1278
1278
  ${c.join(`
1279
1279
  `)}
1280
1280
  `}this.message=t}},aJ=new Set(["Literal","StringLiteral","NumericLiteral","BooleanLiteral","NullLiteral","RegExpLiteral","BigIntLiteral"]),W_=new Set(["string","number","boolean","bigint","symbol","undefined"]),Mt=sc;function cJ(e){return/^[$A-Z_a-z][\w$]*$/.test(e)}var Tx="__magicast_proxy";function Fr(e,t=new Set){if(e===void 0)return Mt.identifier("undefined");if(e===null)return Mt.literal(null);if(W_.has(typeof e))return Mt.literal(e);if(t.has(e))throw new yr("Can not serialize circular reference");if(t.add(e),e[Tx])return e.$ast;if(e instanceof RegExp){let r=Mt.regExpLiteral(e.source,e.flags);return delete r.extra.raw,r}return e instanceof Set?Mt.newExpression(Mt.identifier("Set"),[Mt.arrayExpression([...e].map(r=>Fr(r,t)))]):e instanceof Date?Mt.newExpression(Mt.identifier("Date"),[Mt.literal(e.toISOString())]):e instanceof Map?Mt.newExpression(Mt.identifier("Map"),[Mt.arrayExpression([...e].map(([r,n])=>Mt.arrayExpression([Fr(r,t),Fr(n,t)])))]):Array.isArray(e)?Mt.arrayExpression(e.map(r=>Fr(r,t))):typeof e=="object"?Mt.objectExpression(Object.entries(e).map(([r,n])=>Mt.property("init",/^[$A-Z_a-z][\w$]*$/g.test(r)?Mt.identifier(r):Mt.literal(r),Fr(n,t)))):Mt.literal(e)}function uJ(e,t={}){let r=t;return r[Tx]=!0,r.$ast=e,r.$type||(r.$type="object"),r}var lJ={enumerable:!0,configurable:!0};function Sn(e,t,r){let n=uJ(e,t);return new Proxy({},{ownKeys(){return Object.keys(n).filter(i=>i!==Tx&&!i.startsWith("$"))},getOwnPropertyDescriptor(){return lJ},has(i,s){return s in n},...r,get(i,s,o){if(s in n)return n[s];if(r.get)return r.get(i,s,o)},set(i,s,o,a){return s in n?(n[s]=o,!0):r.set?r.set(i,s,o,a):!1}})}var an=sc,px=new WeakMap;function pJ(e,t,r){if(px.has(t))return px.get(t);let n=Sn(t,{get $declaration(){return e},get imported(){return t.type==="ImportDefaultSpecifier"?"default":t.type==="ImportNamespaceSpecifier"?"*":t.imported.type==="Identifier"?t.imported.name:t.imported.value},set imported(i){if(t.type!=="ImportSpecifier")throw new yr("Changing import name is not yet implemented");t.imported.type==="Identifier"?t.imported.name=i:t.imported.value=i},get local(){return t.local.name},set local(i){t.local.name=i},get from(){return e.source.value},set from(i){if(i===e.source.value)return;e.specifiers=e.specifiers.filter(o=>o!==t),e.specifiers.length===0&&(r.body=r.body.filter(o=>o!==e));let s=r.body.find(o=>o.type==="ImportDeclaration"&&o.source.value===i);s?s.specifiers.push(t):r.body.unshift(an.importDeclaration([t],an.stringLiteral(i)))},toJSON(){return{imported:this.imported,local:this.local,from:this.from}}},{ownKeys(){return["imported","local","from","toJSON"]}});return px.set(t,n),n}function dJ(e,t){let r=()=>{let o=[];for(let a of e.body)if(a.type==="ImportDeclaration")for(let c of a.specifiers)o.push(pJ(a,c,e));return o},n=(o,a,c)=>{let u=r(),l=u.find(m=>m.local===o),p=a.local||o;if(l)return l.imported=a.imported,l.local=p,l.from=a.from,!0;let d=a.imported==="default"?an.importDefaultSpecifier(an.identifier(p)):a.imported==="*"?an.importNamespaceSpecifier(an.identifier(p)):an.importSpecifier(an.identifier(a.imported),an.identifier(p)),h=u.find(m=>m.from===a.from)?.$declaration;if(h)h.specifiers.push(d);else if(c==="prepend"||u.length===0)e.body.unshift(an.importDeclaration([d],an.stringLiteral(a.from)));else{let m=u.at(-1).$declaration,g=e.body.indexOf(m);e.body.splice(g+1,0,an.importDeclaration([d],an.stringLiteral(a.from)))}return!0},i=o=>{let a=r().find(l=>l.local===o);if(!a)return!1;let c=a.$declaration,u=a.$ast;return c.specifiers=c.specifiers.filter(l=>l!==u),c.specifiers.length===0&&(e.body=e.body.filter(l=>l!==c)),!0};return Sn(e,{$type:"imports",$add(o){n(o.local||o.imported,o,"prepend")},$prepend(o){n(o.local||o.imported,o,"prepend")},$append(o){n(o.local||o.imported,o,"append")},get $items(){return r()},toJSON(){return r().reduce((o,a)=>(o[a.local]=a,o),{})}},{get(o,a){return r().find(c=>c.local===a)},set(o,a,c){return n(a,c,"prepend")},deleteProperty(o,a){return i(a)},ownKeys(){return r().map(o=>o.local)},has(o,a){return r().some(c=>c.local===a)}})}function Mf(e,t,r){let n=s=>t[s],i=(s,o)=>{t[s]=o};return Sn(e,{$type:"array",push(s){t.push(Fr(s))},pop(){return Pr(t.pop(),r)},unshift(s){t.unshift(Fr(s))},shift(){return Pr(t.shift(),r)},splice(s,o,...a){return t.splice(s,o,...a.map(u=>Fr(u))).map(u=>Pr(u,r))},find(s){return t.map(o=>Pr(o,r)).find(s)},findIndex(s){return t.map(o=>Pr(o,r)).findIndex(s)},includes(s){return t.map(o=>Pr(o,r)).includes(s)},toJSON(){return t.map(s=>Pr(s,r))}},{get(s,o){if(o==="length")return t.length;if(o===Symbol.iterator)return function*(){for(let u of t)yield Pr(u,r)};if(typeof o=="symbol")return;let a=+o;if(Number.isNaN(a))return;let c=n(a);if(c)return Pr(c,r)},set(s,o,a){if(typeof o=="symbol")return!1;let c=+o;return Number.isNaN(c)?!1:(i(c,Fr(a)),!0)},deleteProperty(s,o){if(typeof o=="symbol")return!1;let a=+o;return Number.isNaN(a)?!1:(t[a]=Fr(void 0),!0)},ownKeys(){return["length",...t.map((s,o)=>o.toString())]}})}function fJ(e,t){if("elements"in e)return Mf(e,e.elements,t)}function Y_(e,t){if(e.type!=="CallExpression")throw new yr("Not a function call");function r(i){if(i.type==="Identifier")return i.name;if(i.type==="MemberExpression")return`${r(i.object)}.${r(i.property)}`;throw new yr("Not implemented")}let n=Mf(e,e.arguments,t);return Sn(e,{$type:"function-call",$callee:r(e.callee),$args:n},{})}function mJ(e,t){if(e.type!=="ArrowFunctionExpression")throw new yr("Not an arrow function expression");let r=Mf(e,e.params,t);return Sn(e,{$type:"arrow-function-expression",$params:r,$body:Pr(e.body,t)},{})}var hJ=sc;function gJ(e,t){if(!("properties"in e))return;let r=s=>{for(let o of e.properties){if("key"in o&&"name"in o.key&&o.key.name===s)return o.value;if(o.type==="ObjectProperty"&&(o.key.type==="StringLiteral"||o.key.type==="NumericLiteral"||o.key.type==="BooleanLiteral")&&o.key.value.toString()===s)return o.value.value??o.value}},n=(s,o=!1)=>{if("key"in s&&"name"in s.key)return s.key.name;if(s.type==="ObjectProperty"&&(s.key.type==="StringLiteral"||s.key.type==="NumericLiteral"||s.key.type==="BooleanLiteral"))return s.key.value.toString();if(o)throw new yr(`Casting "${s.type}" is not supported`,{ast:s,code:t?.$code})},i=(s,o)=>{let a=e.properties.find(c=>n(c)===s);a?a.value=o:cJ(s)?e.properties.push({type:"Property",key:{type:"Identifier",name:s},value:o}):e.properties.push({type:"ObjectProperty",key:hJ.stringLiteral(s),value:o})};return Sn(e,{$type:"object",toJSON(){return e.properties.reduce((s,o)=>("key"in o&&"name"in o.key&&(s[o.key.name]=Pr(o.value,t)),s),{})}},{get(s,o){let a=r(o);if(a)return Pr(a,t)},set(s,o,a){return typeof o!="string"&&(o=String(o)),i(o,Fr(a)),!0},deleteProperty(s,o){typeof o!="string"&&(o=String(o));let a=e.properties.findIndex(c=>"key"in c&&"name"in c.key&&c.key.name===o);return a!==-1&&e.properties.splice(a,1),!0},ownKeys(){return e.properties.map(s=>n(s,!0)).filter(Boolean)}})}function J_(e,t){if(e.type!=="NewExpression")throw new yr("Not a new expression");function r(i){if(i.type==="Identifier")return i.name;if(i.type==="MemberExpression")return`${r(i.object)}.${r(i.property)}`;throw new yr("Not implemented")}let n=Mf(e,e.arguments,t);return Sn(e,{$type:"new-expression",$callee:r(e.callee),$args:n},{})}function yJ(e){if(e.type!=="Identifier")throw new yr("Not an identifier");return Sn(e,{$type:"identifier",$name:e.name},{})}function bJ(e){if(e.type!=="LogicalExpression")throw new yr("Not a logical expression");return Sn(e,{$type:"logicalExpression"},{})}function xJ(e){if(e.type!=="MemberExpression")throw new yr("Not a member expression");return Sn(e,{$type:"memberExpression"},{})}var dx=new WeakMap;function Pr(e,t){if(W_.has(typeof e))return e;if(aJ.has(e.type))return e.value;if(dx.has(e))return dx.get(e);let r;switch(e.type){case"ObjectExpression":{r=gJ(e,t);break}case"ArrayExpression":{r=fJ(e,t);break}case"CallExpression":{r=Y_(e,t);break}case"ArrowFunctionExpression":{r=mJ(e,t);break}case"NewExpression":{r=J_(e,t);break}case"Identifier":{r=yJ(e);break}case"LogicalExpression":{r=bJ(e);break}case"MemberExpression":{r=xJ(e);break}case"TSAsExpression":case"TSSatisfiesExpression":{r=Pr(e.expression,t);break}default:throw new yr(`Casting "${e.type}" is not supported`,{ast:e,code:t?.$code})}return dx.set(e,r),r}var ul=sc;function vJ(e,t){let r=i=>{let s=i==="default"?"ExportDefaultDeclaration":"ExportNamedDeclaration";for(let o of e.body)if(o.type===s){if(i==="default")return o.declaration;if(o.declaration&&"declarations"in o.declaration){let a=o.declaration.declarations[0];if("name"in a.id&&a.id.name===i)return a.init}}},n=(i,s)=>{let o=i==="default"?"ExportDefaultDeclaration":"ExportNamedDeclaration",a=Fr(s);for(let c of e.body)if(c.type===o){if(i==="default"){c.declaration=a;return}if(c.declaration&&"declarations"in c.declaration){let u=c.declaration.declarations[0];if("name"in u.id&&u.id.name===i){u.init=a;return}}}e.body.push(i==="default"?ul.exportDefaultDeclaration(a):ul.exportNamedDeclaration(ul.variableDeclaration("const",[ul.variableDeclarator(ul.identifier(i),a)])))};return Sn(e,{$type:"exports"},{get(i,s){let o=r(s);if(o)return Pr(o,t)},set(i,s,o){return n(s,o),!0},ownKeys(){return e.body.flatMap(i=>i.type==="ExportDefaultDeclaration"?["default"]:i.type==="ExportNamedDeclaration"&&i.declaration&&"declarations"in i.declaration?i.declaration.declarations.map(s=>"name"in s.id?s.id.name:""):[]).filter(Boolean)},deleteProperty(i,s){let o=s==="default"?"ExportDefaultDeclaration":"ExportNamedDeclaration";for(let a=0;a<e.body.length;a++){let c=e.body[a];if(c.type===o){if(s==="default")return e.body.splice(a,1),!0;if(c.declaration&&"declarations"in c.declaration){let u=c.declaration.declarations[0];if("name"in u.id&&u.id.name===s)return e.body.splice(a,1),!0}}}return!1}})}function DJ(e,t){let r=e.program;if(r.type!=="Program")throw new yr(`Cannot proxify ${e.type} as module`);let n={$code:t,$type:"module"},i=Sn(r,n,{ownKeys(){return["imports","exports","generate"]}});return n.exports=vJ(r,i),n.imports=dJ(r),n.generate=s=>Ax(i,s),i}function X_(e,t={}){let r={wrapColumn:t.wrapColumn===void 0,indent:t.tabWidth===void 0||t.useTabs===void 0,quote:t.quote===void 0,arrowParens:t.arrowParensAlways===void 0,trailingComma:t.trailingComma===void 0},n=2,i=0,s=0,o=0,a=0,c=/(?<doubleQuote>"[^"]+")|(?<singleQuote>'[^']+')|(?<singleParam>\([^),]+\)\s*=>)|(?<trailingComma>,\s*[\]}])/g,u={doubleQuote:0,singleQuote:0,singleParam:0,trailingComma:0},l=(e||"").split(`
1281
- `),p=!1;for(let d of l){let h=d.trim();if(h.length!==0){if(r.wrapColumn&&d.length>o&&(o=d.length),r.indent){let m=d.match(/^\s+/)?.[0]||"";m.length>0&&(m.length>0&&m.length<n&&(n=m.length),m[0]===" "?i++:m.length>0&&i--)}if(h.at(-1)===";"?s++:h.length>0&&s--,r.quote||r.arrowParens){let m=h.matchAll(c);for(let g of m)if(g.groups)for(let y in u)g.groups[y]&&u[y]++}r.trailingComma&&((d.startsWith("}")||d.startsWith("]"))&&(p?a++:a--),p=h.endsWith(","))}}return{wrapColumn:o,useTabs:i>0,tabWidth:n,quote:u.singleQuote>u.doubleQuote?"single":"double",arrowParensAlways:u.singleParam>0,trailingComma:a>0||u.trailingComma>0,useSemi:s>0,arrayBracketSpacing:void 0,objectCurlySpacing:void 0,...t}}function Q_(e,t){let r=B_(e,{parser:t?.parser||V_(),...t});return DJ(r,e)}function Z_(e,t){let r=B_("("+e+")",{parser:t?.parser||V_(),...t}),n=r.program.body[0];n.type==="ExpressionStatement"&&(n=n.expression),n.extra?.parenthesized&&(n.extra.parenthesized=!1);let i={$ast:r,$code:" "+e+" ",$type:"module"};return Pr(n,i)}function Ax(e,t={}){let r=e.$ast||e,n=t.format===!1||!("$code"in e)?{}:X_(e.$code,t.format),{code:i,map:s}=nJ(r,{...t,...n});return{code:i,map:s}}async function CJ(e,t={}){let r=await Tf.promises.readFile(e,"utf8");return t.sourceFileName=t.sourceFileName??e,Q_(r,t)}async function EJ(e,t,r){let n="$ast"in e?e.$ast:e,{code:i,map:s}=Ax(n,r);await Tf.promises.writeFile(t,i),s&&await Tf.promises.writeFile(t+".map",s)}var Ef=sc,wJ={functionCall(e,...t){let r=Ef.callExpression(Ef.identifier(e),t.map(n=>Fr(n)));return Y_(r)},newExpression(e,...t){let r=Ef.newExpression(Ef.identifier(e),t.map(n=>Fr(n)));return J_(r)},literal(e){return Fr(e)},raw(e){return Z_(e)}};var rs=q(require("@sentry/node"),1);var Fx=q(require("prettier"),1);async function n2(e,t){let r=await(0,Vt.readdir)(e,{withFileTypes:!0}),n=[];for(let i of r){let s=Ne.default.join(e,i.name);if(i.isDirectory()){if(!t.has(i.name)){let o=await n2(s,t);n.push(...o)}}else n.push(s)}return n}async function i2(e){let t=new Set,r=(...u)=>{if(process.env.DEBUG){let l=new Date,p=`${String(l.getMinutes()).padStart(2,"0")}:${String(l.getSeconds()).padStart(2,"0")}.${String(l.getMilliseconds()).padStart(3,"0")}`;console.debug(p,"[builder-dev-tools]",...u)}},n=async u=>{let l=(0,e2.createHash)("md5");return l.update(u),l.digest("hex")},i=Ne.default.normalize(Ne.default.resolve(process.cwd(),e.cwd)),s=kx(Ne.default.normalize(e.cwd))??i,o=bl(Ne.default.normalize(e.cwd))??s,a={...Ne.default,getCwdDir:()=>i,getRepoRootDir:()=>s,getAppRootDir:()=>o,cwd:()=>process.cwd(),exists:async u=>{try{return await(0,Vt.access)(u),!0}catch{return!1}},magicast:Px,existsSync:u=>(0,ut.existsSync)(u),readdir:async(u,l)=>{let p=await(0,Vt.readdir)(u);return l?p.map(d=>Ne.default.join(u,d)):p},readdirRecursive:async(u,l)=>n2(u,new Set(l)),readdirSync:u=>(0,ut.readdirSync)(u),readFile:async u=>{try{return await(0,Vt.readFile)(u,"utf-8")}catch(l){if(l.code==="ENOENT")return null;throw r(l,u),l}},readFileSync(u){try{return(0,ut.readFileSync)(u,"utf-8")}catch(l){if(l.code==="ENOENT")return null;throw r(l,u),l}},readFileSyncBuffer(u){try{return new Uint8Array((0,ut.readFileSync)(u,{encoding:null}))}catch(l){if(l.code==="ENOENT")return null;throw r(l,u),l}},spawnSync:Bo.spawnSync,stat:async u=>await(0,Vt.stat)(u),statSync:u=>(0,ut.statSync)(u),unlinkSync:u=>{(0,ut.unlinkSync)(u)},unlink:async u=>{await(0,Vt.unlink)(u)},writeFile:async(u,l)=>{u=Ne.default.normalize(u);let p={path:u,basename:Ne.default.basename(u),dirname:Ne.default.dirname(u),extname:Ne.default.extname(u)};await(0,Vt.mkdir)(Ne.default.dirname(u),{recursive:!0}),await(0,Vt.writeFile)(u,l);for(let d of t)await d(p)},hash:n,getDeviceId:()=>n(`${(0,yl.hostname)()}:${(0,yl.homedir)()}`),formatCode:async(u,l)=>{let p=null;try{p=await Fx.default.resolveConfig(u)}catch{}try{return Fx.default.format(l,{...p,filepath:u})}catch{}return l},on:(u,l)=>{u==="change"&&t.add(l)},off:(u,l)=>{u==="change"&&t.delete(l)},debug:r,launchEditor:async u=>{try{let l=u.filePath;typeof u.line=="number"&&(l+=`:${u.line}`,typeof u.column=="number"&&(l+=`:${u.column}`)),(0,r2.default)(l,"code",(p,d)=>{rs.captureException(new Error(`Failed to launch editor for ${d}`),{extra:{pathFile:p}})})}catch(l){rs.captureException(new Error("Failed to launch editor",{cause:l}))}},platform:()=>({runtime:"node",os:process.platform}),getRepoInfo:async u=>{let l=Ne.default.normalize(u??e.cwd);return{hasGit:AJ(l),remoteUrl:SJ(l),defaultBranch:TJ(l),commit:PJ(l),currentBranch:FJ(l)}},getFrameworks:()=>[],ts:t2.default,Sentry:rs,version:Te,sdkVersion:null,ignoreMissingConfig:e.ignoreMissingConfig,kind:null},c=await bo(a);return a.getFrameworks=()=>c,a}function s2(){let e=(0,yl.homedir)();return Ne.default.join(e,".config","builder","dev-tools.json")}function _x(e,t){return typeof e=="object"&&e!=null&&t in e}async function oc(){let e=s2();try{let t=await(0,Vt.readFile)(e,"utf-8");if(typeof t=="string")return JSON.parse(t)}catch(t){if(t.code==="ENOENT")return null}return null}async function Ix(e){let t=s2();e=typeof e=="object"&&e!=null?e:{},await(0,Vt.mkdir)(Ne.default.dirname(t),{recursive:!0}),await(0,Vt.writeFile)(t,JSON.stringify(e??{},null,2))}function SJ(e){try{return((0,Bo.spawnSync)("git",["config","--get","remote.origin.url"],{cwd:e}).stdout||"").toString().trim()}catch(t){return rs.captureException(new Error("Error getting git remote URL:",{cause:t})),""}}function TJ(e){let t="master";try{let r=(0,Bo.spawnSync)("git",["branch","-r"],{cwd:e});return r.stdout&&r.stdout.toString().trim().split(`
1281
+ `),p=!1;for(let d of l){let h=d.trim();if(h.length!==0){if(r.wrapColumn&&d.length>o&&(o=d.length),r.indent){let m=d.match(/^\s+/)?.[0]||"";m.length>0&&(m.length>0&&m.length<n&&(n=m.length),m[0]===" "?i++:m.length>0&&i--)}if(h.at(-1)===";"?s++:h.length>0&&s--,r.quote||r.arrowParens){let m=h.matchAll(c);for(let g of m)if(g.groups)for(let y in u)g.groups[y]&&u[y]++}r.trailingComma&&((d.startsWith("}")||d.startsWith("]"))&&(p?a++:a--),p=h.endsWith(","))}}return{wrapColumn:o,useTabs:i>0,tabWidth:n,quote:u.singleQuote>u.doubleQuote?"single":"double",arrowParensAlways:u.singleParam>0,trailingComma:a>0||u.trailingComma>0,useSemi:s>0,arrayBracketSpacing:void 0,objectCurlySpacing:void 0,...t}}function Q_(e,t){let r=B_(e,{parser:t?.parser||V_(),...t});return DJ(r,e)}function Z_(e,t){let r=B_("("+e+")",{parser:t?.parser||V_(),...t}),n=r.program.body[0];n.type==="ExpressionStatement"&&(n=n.expression),n.extra?.parenthesized&&(n.extra.parenthesized=!1);let i={$ast:r,$code:" "+e+" ",$type:"module"};return Pr(n,i)}function Ax(e,t={}){let r=e.$ast||e,n=t.format===!1||!("$code"in e)?{}:X_(e.$code,t.format),{code:i,map:s}=nJ(r,{...t,...n});return{code:i,map:s}}async function CJ(e,t={}){let r=await Tf.promises.readFile(e,"utf8");return t.sourceFileName=t.sourceFileName??e,Q_(r,t)}async function EJ(e,t,r){let n="$ast"in e?e.$ast:e,{code:i,map:s}=Ax(n,r);await Tf.promises.writeFile(t,i),s&&await Tf.promises.writeFile(t+".map",s)}var Ef=sc,wJ={functionCall(e,...t){let r=Ef.callExpression(Ef.identifier(e),t.map(n=>Fr(n)));return Y_(r)},newExpression(e,...t){let r=Ef.newExpression(Ef.identifier(e),t.map(n=>Fr(n)));return J_(r)},literal(e){return Fr(e)},raw(e){return Z_(e)}};var rs=q(require("@sentry/node"),1);var Fx=q(require("prettier"),1);async function n2(e,t){let r=await(0,Vt.readdir)(e,{withFileTypes:!0}),n=[];for(let i of r){let s=Ne.default.join(e,i.name);if(i.isDirectory()){if(!t.has(i.name)){let o=await n2(s,t);n.push(...o)}}else n.push(s)}return n}async function i2(e){let t=new Set,r=(...u)=>{if(process.env.DEBUG){let l=new Date,p=`${String(l.getMinutes()).padStart(2,"0")}:${String(l.getSeconds()).padStart(2,"0")}.${String(l.getMilliseconds()).padStart(3,"0")}`;console.debug(p,"[builder-dev-tools]",...u)}},n=async u=>{let l=(0,e2.createHash)("md5");return l.update(u),l.digest("hex")},i=Ne.default.normalize(Ne.default.resolve(process.cwd(),e.cwd)),s=kx(Ne.default.normalize(e.cwd))??i,o=bl(Ne.default.normalize(e.cwd))??s,a={...Ne.default,getCwdDir:()=>i,getRepoRootDir:()=>s,getAppRootDir:()=>o,cwd:()=>process.cwd(),exists:async u=>{try{return await(0,Vt.access)(u),!0}catch{return!1}},magicast:Px,existsSync:u=>(0,ut.existsSync)(u),readdir:async(u,l)=>{let p=await(0,Vt.readdir)(u);return l?p.map(d=>Ne.default.join(u,d)):p},readdirRecursive:async(u,l)=>n2(u,new Set(l)),readdirSync:u=>(0,ut.readdirSync)(u),readFile:async u=>{try{return await(0,Vt.readFile)(u,"utf-8")}catch(l){if(l.code==="ENOENT")return null;throw r(l,u),l}},readFileSync(u){try{return(0,ut.readFileSync)(u,"utf-8")}catch(l){if(l.code==="ENOENT")return null;throw r(l,u),l}},readFileSyncBuffer(u){try{return new Uint8Array((0,ut.readFileSync)(u,{encoding:null}))}catch(l){if(l.code==="ENOENT")return null;throw r(l,u),l}},spawnSync:Bo.spawnSync,stat:async u=>await(0,Vt.stat)(u),statSync:u=>(0,ut.statSync)(u),unlinkSync:u=>{(0,ut.unlinkSync)(u)},unlink:async u=>{await(0,Vt.unlink)(u)},writeFile:async(u,l)=>{u=Ne.default.normalize(u);let p={path:u,basename:Ne.default.basename(u),dirname:Ne.default.dirname(u),extname:Ne.default.extname(u)};await(0,Vt.mkdir)(Ne.default.dirname(u),{recursive:!0}),await(0,Vt.writeFile)(u,l);for(let d of t)await d(p)},hash:n,getDeviceId:()=>n(`${(0,yl.hostname)()}:${(0,yl.homedir)()}`),formatCode:async(u,l)=>{let p=null;try{p=await Fx.default.resolveConfig(u)}catch{}try{return Fx.default.format(l,{...p,filepath:u})}catch{}return l},on:(u,l)=>{u==="change"&&t.add(l)},off:(u,l)=>{u==="change"&&t.delete(l)},debug:r,launchEditor:async u=>{try{let l=u.filePath;typeof u.line=="number"&&(l+=`:${u.line}`,typeof u.column=="number"&&(l+=`:${u.column}`)),(0,r2.default)(l,"code",(p,d)=>{rs.captureException(new Error(`Failed to launch editor for ${d}`),{extra:{pathFile:p}})})}catch(l){rs.captureException(new Error("Failed to launch editor",{cause:l}))}},platform:()=>({runtime:"node",os:process.platform}),getRepoInfo:async u=>{let l=Ne.default.normalize(u??e.cwd);return{hasGit:AJ(l),remoteUrl:SJ(l),defaultBranch:TJ(l),commit:PJ(l),currentBranch:FJ(l)}},getFrameworks:()=>[],ts:t2.default,Sentry:rs,version:Ce,sdkVersion:null,ignoreMissingConfig:e.ignoreMissingConfig,kind:null},c=await bo(a);return a.getFrameworks=()=>c,a}function s2(){let e=(0,yl.homedir)();return Ne.default.join(e,".config","builder","dev-tools.json")}function _x(e,t){return typeof e=="object"&&e!=null&&t in e}async function oc(){let e=s2();try{let t=await(0,Vt.readFile)(e,"utf-8");if(typeof t=="string")return JSON.parse(t)}catch(t){if(t.code==="ENOENT")return null}return null}async function Ix(e){let t=s2();e=typeof e=="object"&&e!=null?e:{},await(0,Vt.mkdir)(Ne.default.dirname(t),{recursive:!0}),await(0,Vt.writeFile)(t,JSON.stringify(e??{},null,2))}function SJ(e){try{return((0,Bo.spawnSync)("git",["config","--get","remote.origin.url"],{cwd:e}).stdout||"").toString().trim()}catch(t){return rs.captureException(new Error("Error getting git remote URL:",{cause:t})),""}}function TJ(e){let t="master";try{let r=(0,Bo.spawnSync)("git",["branch","-r"],{cwd:e});return r.stdout&&r.stdout.toString().trim().split(`
1282
1282
  `).map(i=>i.trim()).includes("origin/main")?"main":t}catch(r){return rs.captureException(new Error("Error getting git default branch name:",{cause:r})),t}}function AJ(e){try{return((0,Bo.spawnSync)("git",["rev-parse","--is-inside-work-tree"],{cwd:e}).stdout||"").toString().trim()==="true"}catch(t){return rs.captureException(new Error("Error getting git commit:",{cause:t})),!1}}function PJ(e){try{return((0,Bo.spawnSync)("git",["rev-parse","HEAD"],{cwd:e}).stdout||"").toString().trim()}catch(t){return rs.captureException(new Error("Error getting git commit:",{cause:t})),""}}function FJ(e){try{return((0,Bo.spawnSync)("git",["branch","--show-current"],{cwd:e}).stdout||"").toString().trim()}catch(t){return rs.captureException(new Error("Error getting current branch name:",{cause:t})),""}}function kx(e){let t=Ne.default.resolve("/");for(let r=0;r<20;r++){let n=Ne.default.join(e,"package.json");if((0,ut.existsSync)(n))return e;if(e===t)break;e=Ne.default.dirname(e)}return null}function bl(e){let t=Ne.default.resolve("/");for(let r=0;r<20;r++){if((0,ut.existsSync)(Ne.default.join(e,"builder.config.json"))||(0,ut.existsSync)(Ne.default.join(e,"fusion.config.json"))||(0,ut.existsSync)(Ne.default.join(e,"package.json"))||(0,ut.existsSync)(Ne.default.join(e,"remix.config.js"))||(0,ut.existsSync)(Ne.default.join(e,"remix.config.mjs"))||(0,ut.existsSync)(Ne.default.join(e,"remix.config.ts"))||(0,ut.existsSync)(Ne.default.join(e,"vite.config.js"))||(0,ut.existsSync)(Ne.default.join(e,"vite.config.ts"))||(0,ut.existsSync)(Ne.default.join(e,"vite.config.mjs"))||(0,ut.existsSync)(Ne.default.join(e,"next.config.js"))||(0,ut.existsSync)(Ne.default.join(e,"next.config.ts"))||(0,ut.existsSync)(Ne.default.join(e,"angular.json"))||(0,ut.existsSync)(Ne.default.join(e,"project.json"))||(0,ut.existsSync)(Ne.default.join(e,"tsconfig.json")))return e;if(e===t)break;e=Ne.default.dirname(e)}return null}f();f();var ar=[];for(let e=0;e<256;++e)ar.push((e+256).toString(16).slice(1));function o2(e,t=0){return(ar[e[t+0]]+ar[e[t+1]]+ar[e[t+2]]+ar[e[t+3]]+"-"+ar[e[t+4]]+ar[e[t+5]]+"-"+ar[e[t+6]]+ar[e[t+7]]+"-"+ar[e[t+8]]+ar[e[t+9]]+"-"+ar[e[t+10]]+ar[e[t+11]]+ar[e[t+12]]+ar[e[t+13]]+ar[e[t+14]]+ar[e[t+15]]).toLowerCase()}f();var a2=q(require("crypto")),$f=new Uint8Array(256),Lf=$f.length;function Nx(){return Lf>$f.length-16&&(a2.default.randomFillSync($f),Lf=0),$f.slice(Lf,Lf+=16)}f();f();var c2=q(require("crypto")),Rx={randomUUID:c2.default.randomUUID};function _J(e,t,r){if(Rx.randomUUID&&!t&&!e)return Rx.randomUUID();e=e||{};let n=e.random||(e.rng||Nx)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(let i=0;i<16;++i)t[r+i]=n[i];return t}return o2(n)}var Ox=_J;var Mx=q(require("os"),1),u2=q(vt(),1);f();var _r=class extends Error{};async function l2(e){let t=process.env.NODE_ENV!=="test",r=await f2(),n=await d2();Ci.init(t?"2532be1b0436a18cb938b21fc7fa9faf":"",{logLevel:Ci.Types.LogLevel.None,flushIntervalMillis:500});let i=new Ci.Identify;return await Ci.identify(i,{device_id:r,user_id:n,platform:Mx.default.type(),os_name:process.platform,os_version:Mx.default.release()}).promise,Xn.init({dsn:"https://3252dddc08dbb5bf406dc33bf3c13633@o117565.ingest.us.sentry.io/4505630794448896",tracesSampleRate:0,release:ZP,environment:process.env.NODE_ENV,enabled:t,registerEsmLoaderHooks:!1,normalizeDepth:5,maxValueLength:1500,integrations:[Xn.nativeNodeFetchIntegration(),Xn.httpIntegration(),Xn.extraErrorDataIntegration()],beforeSend:(s,o)=>{let a=o.originalException??o.syntheticException;return!(a instanceof _r)&&(e||s.level!=="warning")&&console.error((0,u2.red)(`ERROR ID: ${s.event_id}`),a),s},tracePropagationTargets:[]}),Xn.setUser({username:process.env.USER||process.env.USERNAME||"unknown"}),Xn}async function _e(e,t){let r={...t,app:"dev-tools-cli",package:"cli"},n=await d2(),i=await f2();return await Ci.track(e,r,{user_id:n,device_id:i}).promise}var Uf,Bx;async function p2(e){Uf=e;let t=await oc();await Ix({...t,userId:e})}async function d2(){if(Uf)return Uf;let e=await oc(),t;return _x(e,"userId")&&(t=e.userId),Uf=t,t}async function f2(){if(Bx)return Bx;let e=await oc(),t=Ox();return _x(e,"deviceId")?t=e.deviceId:await Ix({...e,deviceId:t}),Bx=t,t}f();var h2=q(vt(),1),g2=require("undici"),y2=q(vt(),1);var m2="0.0.0";var Lx=q(require("process"),1),b2=q(require("@sentry/node"),1);var he=async(e,t)=>{let r="fetch"in globalThis?globalThis.fetch:g2.fetch;try{let n=b2.getTraceData(),i=await r(e,{...t,headers:{...t?.headers,...kJ(),...n}});if(!i.ok&&i.status===429){let s=await i.json(),o=s.severity??"high",a=s.message??"Rate limit exceeded. Please try again later.";throw console.log(),o==="high"?B.error((0,h2.red)(`${i.status} ${a}
1283
1283
 
1284
1284
  `)):B.warn((0,y2.yellow)(`${i.status} ${a}
@@ -1315,7 +1315,7 @@ Restarting server after Builder Devtools update...
1315
1315
  <h3>How's Devtools working for you?</h3>
1316
1316
  <p>We'd love your feedback!</p>
1317
1317
  </div>
1318
- \`,t.appendChild(e),setTimeout(()=>{e.classList.add("menu-toggle-tooltip-show"),e.addEventListener("click",()=>{e.classList.remove("menu-toggle-tooltip-show")})},1e3)};function ui(t){t.getElementById("go-to-builder").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),Ee(t,!1),window.open(Nr(),"builder")}),t.getElementById("components-link").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation();let u=t.querySelector(".nav-cmp-list .section-content");u.scrollTop=0,oe(t,"nav-cmp-list"),si(t)}),t.getElementById("settings-link").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),oe(t,"nav-settings")}),t.getElementById("add-page-link").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),Ee(t,!1),window.open(je(),"builder")}),t.getElementById("import-from-figma").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),Ee(t,!1),window.open("https://www.figma.com/community/plugin/747985167520967365/builder-io-ai-powered-figma-to-code-react-vue-tailwind-more")})}function ci(t){let e=t.getElementById("enable-edit");e.addEventListener("change",r=>{r.stopPropagation(),Ft(e.checked)}),e.checked=it(),Ft(e.checked)}var At=class extends HTMLElement{constructor(){super()}connectedCallback(){let e=this.attachShadow({mode:"open"});e.innerHTML=\`<style>*,*:before,*:after{box-sizing:border-box}:host{--background-color: rgba(40, 40, 40, 1);--primary-color: rgba(72, 161, 255, 1);--primary-color-subdued: rgb(72, 161, 255, .6);--primary-color-highlight: rgb(126, 188, 255);--primary-contrast-color: white;--edit-color: #1d74e2;--edit-color-highlight: #1c6bd1;--edit-color-alpha: rgb(72, 161, 255, .15);--error-color: #ff2b55;--text-color: white;--text-color-highlight: white;--border-color: #454545;--button-background-color-hover: rgba(255, 255, 255, .1);--menu-width: 320px;--transition-time: .15s;--font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";font-family:var(--font-family);line-height:1.6}button{cursor:pointer;color:var(--text-color);-webkit-tap-highlight-color:transparent}input,select,button{font-family:var(--font-family)}.menu-toggle{position:absolute;right:0;bottom:0;pointer-events:auto;padding:8px;background:transparent;border:none;appearance:none}.menu-toggle div{position:relative;width:64px;height:64px;pointer-events:none;border-radius:50%;background:#000;border:1px solid white;box-shadow:#00000054 0 0 8px}.menu-toggle:hover div{background-color:var(--background-color);border:1px solid rgb(220,220,220)}.menu-toggle svg{position:absolute;top:15px;left:15px;width:33px;height:32px}div.highlight-bg{position:absolute;top:-1px;left:-1px;background-color:#1a1a1a;pointer-events:none;transition:all .4s ease-out;opacity:0}.menu-toggle-highlight-no-transition div.highlight-bg{transition:none}.menu-toggle-highlight div.highlight-bg{opacity:1}.menu-toggle-tooltip{position:absolute;bottom:0;right:0;width:382px;height:72px;padding:0;text-align:left;appearance:none;background-color:transparent;border:none;pointer-events:none;transform:translate3d(320px,0,0);opacity:0;transition:all .15s ease-in-out;color:#fff}.menu-toggle-tooltip.menu-toggle-tooltip-show{pointer-events:auto;opacity:1;transform:translateZ(0)}.menu-toggle-tooltip-content{position:absolute;inset:0 95px 10px 0;padding:8px 12px;background-color:var(--primary-color);box-shadow:#00000054 0 0 20px;border-radius:2px}.menu-toggle-tooltip-content:before{content:"";position:absolute;bottom:15px;right:-6px;width:30px;height:30px;background-color:var(--primary-color);transform:rotate(45deg)}.menu-toggle-tooltip:hover .menu-toggle-tooltip-content,.menu-toggle-tooltip:hover .menu-toggle-tooltip-content:before{background-color:var(--primary-color-highlight)}.menu-toggle-tooltip-content h3{margin:0;font-size:16px}.menu-toggle-tooltip-content p{margin:0;font-size:12px}section{position:absolute;display:grid;grid-template-rows:64px auto 64px;top:0;left:0;width:100%;height:100%;padding:0;pointer-events:none}.section-content{margin:0;padding:0 0 10px;font-weight:300;transform:translate3d(105%,0,0);transition:transform var(--transition-time) ease-in-out;overflow-y:auto}.section-content .error{color:var(--error-color);font-weight:700}section a{text-decoration:none;color:var(--text-color)}section h3,section p{margin-left:16px;margin-right:16px}.info{font-size:12px}ul.list{list-style:none;padding:0;margin:0}ul.list li{display:block;padding:0;margin:0}ul.list a,ul.list button{display:grid;grid-template-columns:24px auto;grid-gap:16px;padding:12px;margin:8px 0;border:none;background:transparent;appearance:none;width:100%;font-weight:300;text-align:left;text-decoration:none;color:var(--text-color)}ul.list a:hover,ul.list button:hover{text-decoration:none;color:var(--text-color);background-color:var(--button-background-color-hover)}ul.list a span,ul.list button span{display:block;font-size:16px;font-weight:500;line-height:1.5;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}header{position:relative;display:grid;grid-template-columns:44px 1fr;gap:8px;padding-left:8px;border-bottom:1px solid var(--border-color);transition:opacity var(--transition-time) ease-in-out;opacity:0;pointer-events:none}header>div{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nav-home header>div{margin-right:56px}header h2{margin:7px 0 0;font-size:18px;font-weight:500;line-height:1.5;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}header p{margin:2px 0 0;font-size:12px;font-weight:300;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}header p button{display:block;margin:0;padding:0;width:100%;font-size:12px;font-weight:300;text-decoration:none;appearance:none;text-align:left;background-color:transparent;border:none;color:var(--primary-color);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}header p button:hover{text-decoration:underline;color:var(--primary-color)}.builder-logo{margin:12px 0 0 8px}#close{display:block;position:absolute;appearance:none;background:transparent;border:none;border-radius:50%;margin:0;padding:0;right:4px;top:8px;width:48px;height:48px;z-index:1;opacity:.7}#close:hover{opacity:1;background-color:var(--button-background-color-hover)}#close svg{position:absolute;top:12px;left:12px;width:24px;height:24px;fill:currentColor;pointer-events:none}.back-button{position:relative;display:block;margin:7px 0 0 -2px;width:48px;height:48px;background:transparent;border:none;appearance:none;border-radius:50%}.back-button:hover{background-color:var(--button-background-color-hover)}.back-button svg{position:absolute;top:12px;left:12px;width:24px;height:24px;fill:currentColor;pointer-events:none}footer{border-top:1px solid var(--border-color);transition:opacity var(--transition-time) ease-in-out;opacity:0;pointer-events:none}section.nav-cmp-list{grid-template-rows:64px auto 120px}footer a{text-decoration:underline;color:var(--primary-color)}footer a:hover{color:var(--primary-color);text-decoration:none}.nav-list{padding:2px 0}.nav-loading{pointer-events:none}.nav-loading-icon{position:absolute;display:inline-block;top:170px;left:0;width:100%;transform:translateZ(0);pointer-events:auto;opacity:0;transition:all 50ms ease-in-out;transition-delay:50ms;pointer-events:none}.nav-loading .nav-loading-icon{opacity:.5}.nav-list h4{margin:8px 8px 8px 10px;font-size:14px;font-weight:600}.nav-list .nav-list-item+h4{margin-top:30px}.nav-list-item{display:grid;grid-template-columns:1fr 1fr;gap:8px;position:relative;margin:2px 0;padding:8px 28px 8px 46px;width:100%;font-size:14px;font-weight:300;text-align:left;border:none;background:transparent;appearance:none}.nav-list-item:hover{background-color:var(--button-background-color-hover)}.nav-list-item-icon{position:absolute;top:4px;left:10px;width:24px;height:24px;object-fit:contain;filter:invert(100%);background-size:24px 24px;background-repeat:no-repeat;background-position:center center}.nav-list-item span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;pointer-events:none}.nav-list-item:after{display:block;position:absolute;content:"";background-image:url('data:image/svg+xml,<svg width="8" height="14" viewBox="0 0 8 14" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1L7 7L1 13" stroke="%23F2F2F2" stroke-opacity="0.5" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/></svg>');background-repeat:no-repeat;background-position:12px 9px;top:0;right:0;width:32px;height:32px;pointer-events:none}.nav-list-item-note{opacity:0;font-size:12px;padding-top:1px;text-align:right}.nav-list-item:hover .nav-list-item-note{opacity:.5}.ui-select{display:block;margin:8px 0 16px;padding:8px 16px;cursor:pointer}.ui-select h3{margin:0;font-size:14px;font-weight:500}.ui-select p{margin:8px 0;font-size:12px;font-weight:300}.ui-select .select{position:relative;margin:8px 0;border-radius:4px;padding:0;line-height:1.1;overflow:hidden;border:1px solid var(--border-color)}.ui-select select{appearance:none;background-color:transparent;border:none;outline:none;padding:8px 32px 8px 8px;margin:0;width:100%;font-size:14px;cursor:pointer;text-overflow:ellipsis;opacity:.6;color:var(--text-color)}.ui-select .select:after{content:"";top:6px;right:5px;width:24px;height:24px;position:absolute;background-image:url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="%23F2F2F2" d="M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"/></svg>');background-repeat:no-repeat;background-position:center;pointer-events:none;opacity:.6}.ui-select .select:hover{border-color:var(--primary-color-subdued)}.ui-text-input .select:focus-within{border-color:var(--primary-color)}.ui-text-input .select:focus-within select{opacity:1}.spinner:after{content:" ";display:block;width:32px;height:32px;margin:0 auto;pointer-events:auto;border-radius:50%;border:3px solid var(--text-color);border-color:var(--text-color) transparent var(--text-color) transparent;animation:spinner .75s linear infinite}@keyframes spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.ui-switch{display:grid;grid-template-columns:auto 48px;grid-gap:20px;margin:8px 0 16px;padding:8px 0 8px 16px;cursor:pointer}.ui-switch>*{pointer-events:none}.ui-switch input{display:none;visibility:hidden}.ui-switch .switcher{display:inline-block;border-radius:100px;width:35px;height:14px;background-color:#ccc;position:relative;top:6px;vertical-align:middle;cursor:pointer}.ui-switch input[type=checkbox]:checked+.switcher{background-color:var(--primary-color-subdued)}.ui-switch .switcher:before{content:"";display:block;width:20px;height:20px;background-color:var(--text-color);box-shadow:0 1px 3px #0009;border-radius:50%;position:absolute;top:-3px;left:0;margin-right:0;transition:all .15s}.ui-switch input[type=checkbox]:checked+.switcher:before{left:100%;margin-left:-20px;background-color:var(--primary-color)}.ui-switch h3{margin:0;font-size:14px;font-weight:500}.ui-switch p{margin:4px 0 0;font-size:12px;font-weight:300}.ui-text-input{display:block;margin:8px 0 16px;padding:8px 16px;cursor:pointer}.ui-text-input h3{margin:0;font-size:14px;font-weight:500}.ui-text-input p{margin:8px 0;font-size:12px;font-weight:300}.ui-text-input .input{position:relative;margin:8px 0;border:1px solid var(--border-color);border-radius:4px;background:transparent;padding:2px;overflow:hidden}.ui-text-input input{display:block;width:235px;font-size:14px;border:none;background:transparent;padding:6px;appearance:none;color:var(--text-color);opacity:.6;outline:none}.ui-text-input .input:hover{border-color:var(--primary-color-subdued)}.ui-text-input .input:focus-within{border-color:var(--primary-color)}.ui-text-input .input:focus-within input{opacity:1}.ui-text-input .input:after{content:"";position:absolute;top:5px;right:14px;width:8px;height:17px;border:2px solid rgba(51,181,51,1);border-top:none;border-left:none;transform:rotate(45deg);opacity:0;transition:opacity 80ms ease-in-out;pointer-events:none}.ui-text-input.saved .input:after{opacity:1}.ui-toast{position:fixed;bottom:8px;left:8px;right:8px;padding:6px 12px;font-size:14px;border-radius:4px;transform:translate3d(0,150%,0);opacity:0;transition:all var(--transition-time) ease-in-out;background-color:var(--primary-color-subdued);color:var(--text-color);pointer-events:none}.ui-toast.ui-toast-show{transform:translateZ(0);opacity:1;pointer-events:auto}[data-view=nav-home] .nav-home .section-content,[data-view=nav-cmp-list] .nav-cmp-list .section-content,[data-view=nav-cmp-detail] .nav-cmp-detail .section-content,[data-view=nav-cmp-input] .nav-cmp-input .section-content,[data-view=nav-settings] .nav-settings .section-content{transform:translateZ(0);pointer-events:auto}[data-view=nav-home] .nav-home header,[data-view=nav-home] .nav-home footer,[data-view=nav-cmp-list] .nav-cmp-list header,[data-view=nav-cmp-list] .nav-cmp-list footer,[data-view=nav-cmp-detail] .nav-cmp-detail header,[data-view=nav-cmp-detail] .nav-cmp-detail footer,[data-view=nav-cmp-input] .nav-cmp-input header,[data-view=nav-cmp-input] .nav-cmp-input footer,[data-view=nav-settings] .nav-settings header,[data-view=nav-settings] .nav-settings footer{opacity:1;pointer-events:auto}[data-view=nav-cmp-list] .nav-home .section-content,[data-view=nav-cmp-detail] .nav-home .section-content,[data-view=nav-cmp-detail] .nav-cmp-list .section-content,[data-view=nav-cmp-input] .nav-home .section-content,[data-view=nav-cmp-input] .nav-cmp-list .section-content,[data-view=nav-cmp-input] .nav-cmp-detail .section-content,[data-view=nav-settings] .nav-home .section-content{transform:translate3d(-105%,0,0)}.cmp-item .nav-list-item-icon{background-image:url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20.83 16.809C20.94 16.561 21 16.289 21 16.008V7.99001C20.9994 7.64108 20.9066 7.29851 20.731 6.99699C20.5554 6.69547 20.3032 6.44571 20 6.27301L13 2.26501C12.6954 2.09103 12.3508 1.99951 12 1.99951C11.6492 1.99951 11.3046 2.09103 11 2.26501L7.988 3.99001M5.441 5.44801L4 6.27301C3.381 6.62801 3 7.28301 3 7.99101V16.009C3 16.718 3.381 17.372 4 17.726L11 21.734C11.3046 21.908 11.6492 21.9995 12 21.9995C12.3508 21.9995 12.6954 21.908 13 21.734L18.544 18.56" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M12 22V12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M14.532 10.538L20.73 6.95996" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M3.27002 6.95996L12 12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M3 3L21 21" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/></svg>');opacity:.3}.cmp-item.registered .nav-list-item-icon{background-image:url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M21 16.008V7.99001C20.9994 7.64108 20.9066 7.29851 20.731 6.99699C20.5554 6.69547 20.3032 6.44571 20 6.27301L13 2.26501C12.6954 2.09103 12.3508 1.99951 12 1.99951C11.6492 1.99951 11.3046 2.09103 11 2.26501L4 6.27301C3.381 6.62801 3 7.28301 3 7.99101V16.009C3 16.718 3.381 17.372 4 17.726L11 21.734C11.3046 21.908 11.6492 21.9995 12 21.9995C12.3508 21.9995 12.6954 21.908 13 21.734L20 17.726C20.619 17.371 21 16.716 21 16.008Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 22V12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 12L20.73 6.95996" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M3.26999 6.95996L12 12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /></svg>');opacity:.8}.search-highlight{background-color:var(--primary-color-alpha);padding:0 2px;border-radius:2px;font-weight:500}.search-container{position:sticky;top:0;z-index:10;padding:12px 16px;background:var(--background-color);border-bottom:1px solid var(--border-color)}.search-input-wrapper{position:relative;display:flex;align-items:center}.search-icon{position:absolute;left:12px;color:var(--text-color-secondary);pointer-events:none}.component-search-input{width:100%;height:36px;padding:8px 36px;border:1px solid var(--border-color);border-radius:6px;background:var(--input-background);color:var(--text-color);font-size:14px;transition:border-color .2s,box-shadow .2s}.component-search-input:focus{outline:none;border-color:var(--primary-color);box-shadow:0 0 0 2px var(--primary-color-alpha)}.component-search-input::placeholder{color:var(--text-color-tertiary)}.clear-search-button{position:absolute;right:8px;padding:4px;color:var(--text-color-secondary);border:none;background:transparent;border-radius:4px;cursor:pointer;opacity:0;transition:opacity .2s,background-color .2s;display:flex;align-items:center;justify-content:center}.clear-search-button:hover{background-color:var(--hover-color)}.component-search-input:not(:placeholder-shown)+.clear-search-button{opacity:1}.no-results{padding:32px 16px;text-align:center;color:var(--text-color-secondary);font-size:14px}#cmp-detail{position:relative}.cmp-loading{pointer-events:none!important}.cmp-loading-icon{position:absolute;display:inline-block;top:170px;left:0;width:100%;transform:translateZ(0);pointer-events:auto;opacity:0;transition:all 50ms ease-in-out;transition-delay:50ms;pointer-events:none}.cmp-loading .cmp-loading-icon{opacity:.5}.cmp-cover{position:absolute;top:160px;left:0;width:100%;height:100vh;background:var(--background-color);transform:translateZ(0);pointer-events:none;display:none}[data-view=nav-cmp-detail] .cmp-cover{display:block;pointer-events:auto}.cmp-enabled .cmp-cover{transform:translate3d(0,105%,0);pointer-events:none}.section-ready .cmp-cover{transition:all var(--transition-time) ease-in-out}.cmp-detail-inputs-container{margin:8px 0 16px;padding:0}.cmp-detail-inputs-container h3{margin:0 0 6px;padding-left:16px;padding-right:8px;font-size:14px;font-weight:500;display:flex;justify-content:space-between;align-items:center}.cmp-detail-inputs-reload{font-weight:300;font-size:.9em;text-decoration:none;appearance:none;text-align:left;background-color:transparent;border:none;color:var(--primary-color);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cmp-detail-inputs-reload:hover{text-decoration:underline;color:var(--primary-color)}.cmp-detail-inputs-container .cmp-inputs-empty{padding:0;margin-top:12px;font-size:12px;font-weight:300;opacity:.5;font-style:italic}.cmp-detail-inputs-container .nav-list-item-icon{opacity:.8;background-size:20px 20px;background-position:4px center}.input-icon{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path></svg>')}.input-icon-array{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 16v-6a2 2 0 1 1 4 0v6"></path> <path d="M10 13h4"></path></svg>')}.input-icon-boolean{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 16h2a2 2 0 1 0 0 -4h-2h2a2 2 0 1 0 0 -4h-2v8z"></path></svg>')}.input-icon-number{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 16v-8l4 8v-8"></path></svg>')}.input-icon-object{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M12 8a2 2 0 0 1 2 2v4a2 2 0 1 1 -4 0v-4a2 2 0 0 1 2 -2z"></path></svg>')}.input-icon-string{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 15a1 1 0 0 0 1 1h2a1 1 0 0 0 1 -1v-2a1 1 0 0 0 -1 -1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1"></path></svg>')}.cmp-input-item-unregistered{opacity:.4}.cmp-input-item-unregistered .input-icon:after{content:"";position:absolute;top:11px;left:4px;width:20px;height:2px;background-color:#000;transform:rotate(-45deg)}.cmp-prop-info{border-bottom:1px solid var(--border-color)}.cmp-input-readonly{margin:16px 0;padding:0 16px;display:grid;grid-template-columns:50% 50%;gap:12px}.cmp-input-readonly h3{margin:0;font-size:14px;font-weight:500}.cmp-input-readonly span{margin-top:2px;font-size:12px;font-weight:300;opacity:.8}.cmp-input-detail{margin:16px 0}.cmp-input-detail a{color:var(--primary-color);text-decoration:none}.cmp-input-detail a:hover{text-decoration:underline}.input-cover{position:absolute;top:175px;left:0;width:100%;height:100%;background:var(--background-color);transform:translateZ(0);transition:all var(--transition-time) ease-in-out;pointer-events:auto}.input-enabled .input-cover{transform:translate3d(0,105%,0);pointer-events:none}.input-loading-icon{position:absolute;display:inline-block;top:190px;left:0;width:100%;transform:translateZ(0);pointer-events:auto;opacity:0;transition:all 50ms ease-in-out;transition-delay:50ms;pointer-events:none}.input-loading .input-loading-icon{opacity:.5}:host{position:fixed;inset:0;z-index:2147483646;user-select:none;pointer-events:none;color:var(--text-color)}aside{position:absolute;top:0;right:0;width:var(--menu-width);height:100%;transform:translate3d(105%,0,0);transition:transform var(--transition-time) ease-in-out;background:var(--background-color);box-shadow:#000000c9 5px 0 20px;overflow:hidden;z-index:1}:host(.show-builder-menu) aside{pointer-events:auto;transform:translateZ(0)}#hit{position:absolute;inset:0;display:none}:host(.show-builder-menu) #hit{display:block;pointer-events:auto}#version{position:absolute;bottom:6px;right:6px;font-size:8px;color:#9b9b9b}</style><div id="hit"></div> <aside data-view="nav-home"> <section class="nav-home"> <header> <svg class="builder-logo" viewBox="0 0 31 36" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M31 9.96854C31.0016 11.4553 30.6701 12.9236 30.03 14.2654C29.3898 15.6072 28.4572 16.7884 27.3007 17.7221L0.702841 2.61812C0.601104 2.56012 0.506714 2.49008 0.421705 2.40951C0.288323 2.27871 0.182333 2.12263 0.109928 1.95039C0.0375215 1.77814 0.000151253 1.59319 0 1.40633C0 1.03335 0.148098 0.675643 0.411715 0.411905C0.675332 0.148167 1.03287 0 1.40568 0L21.036 0C23.6786 0 26.213 1.05025 28.0816 2.91972C29.9502 4.78918 31 7.32472 31 9.96854Z" fill="#18B4F4" /> <path d="M31 25.4757C31.0004 26.7849 30.7429 28.0815 30.2423 29.2912C29.7417 30.5009 29.0078 31.6001 28.0825 32.526C27.1572 33.4519 26.0587 34.1864 24.8497 34.6875C23.6406 35.1886 22.3448 35.4465 21.0361 35.4465H1.40573C1.12766 35.4436 0.856725 35.3581 0.627199 35.201C0.397672 35.044 0.219871 34.8223 0.116289 34.5641C0.0127078 34.3059 -0.011999 34.0228 0.0452946 33.7505C0.102588 33.4783 0.239308 33.2292 0.438156 33.0347C0.517415 32.9551 0.606358 32.8858 0.702893 32.8284L11.1705 26.8843L27.2984 17.7244C28.4548 18.6579 29.3874 19.8387 30.028 21.18C30.6685 22.5213 31.0007 23.9891 31 25.4757Z" fill="#FD6B3C" /> <path d="M27.3011 17.7221L11.1709 26.8843L0.703209 32.8284C0.602697 32.8843 0.509784 32.9528 0.426758 33.0323C4.41799 28.9369 6.6496 23.442 6.64456 17.7221C6.65208 12.0015 4.42111 6.50517 0.429101 2.40948C0.51411 2.49005 0.6085 2.56009 0.710237 2.61809L27.3011 17.7221Z" fill="#A97FF2" /> </svg> <div> <h2 class="builder-home-title">Builder Devtools</h2> <p><button id="go-to-builder">Go to Builder</button></p> </div> <button id="close" aria-label="Close Menu"> <svg viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" > <path stroke="none" d="M0 0h24v24H0z" fill="none" /> <path d="M18 6l-12 12" /> <path d="M6 6l12 12" /> </svg> </button> </header> <div class="section-content"> <ul class="list"> <li> <button id="components-link"> <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M21 16.008V7.99001C20.9994 7.64108 20.9066 7.29851 20.731 6.99699C20.5554 6.69547 20.3032 6.44571 20 6.27301L13 2.26501C12.6954 2.09103 12.3508 1.99951 12 1.99951C11.6492 1.99951 11.3046 2.09103 11 2.26501L4 6.27301C3.381 6.62801 3 7.28301 3 7.99101V16.009C3 16.718 3.381 17.372 4 17.726L11 21.734C11.3046 21.908 11.6492 21.9995 12 21.9995C12.3508 21.9995 12.6954 21.908 13 21.734L20 17.726C20.619 17.371 21 16.716 21 16.008Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 22V12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 12L20.73 6.95996" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M3.26999 6.95996L12 12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> </svg> <span>Components</span> </button> </li> <li> <button id="settings-link"> <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M10.325 4.317C10.751 2.561 13.249 2.561 13.675 4.317C13.7389 4.5808 13.8642 4.82578 14.0407 5.032C14.2172 5.23822 14.4399 5.39985 14.6907 5.50375C14.9414 5.60764 15.2132 5.65085 15.4838 5.62987C15.7544 5.60889 16.0162 5.5243 16.248 5.383C17.791 4.443 19.558 6.209 18.618 7.753C18.4769 7.98466 18.3924 8.24634 18.3715 8.51677C18.3506 8.78721 18.3938 9.05877 18.4975 9.30938C18.6013 9.55999 18.7627 9.78258 18.9687 9.95905C19.1747 10.1355 19.4194 10.2609 19.683 10.325C21.439 10.751 21.439 13.249 19.683 13.675C19.4192 13.7389 19.1742 13.8642 18.968 14.0407C18.7618 14.2172 18.6001 14.4399 18.4963 14.6907C18.3924 14.9414 18.3491 15.2132 18.3701 15.4838C18.3911 15.7544 18.4757 16.0162 18.617 16.248C19.557 17.791 17.791 19.558 16.247 18.618C16.0153 18.4769 15.7537 18.3924 15.4832 18.3715C15.2128 18.3506 14.9412 18.3938 14.6906 18.4975C14.44 18.6013 14.2174 18.7627 14.0409 18.9687C13.8645 19.1747 13.7391 19.4194 13.675 19.683C13.249 21.439 10.751 21.439 10.325 19.683C10.2611 19.4192 10.1358 19.1742 9.95929 18.968C9.7828 18.7618 9.56011 18.6001 9.30935 18.4963C9.05859 18.3924 8.78683 18.3491 8.51621 18.3701C8.24559 18.3911 7.98375 18.4757 7.752 18.617C6.209 19.557 4.442 17.791 5.382 16.247C5.5231 16.0153 5.60755 15.7537 5.62848 15.4832C5.64942 15.2128 5.60624 14.9412 5.50247 14.6906C5.3987 14.44 5.23726 14.2174 5.03127 14.0409C4.82529 13.8645 4.58056 13.7391 4.317 13.675C2.561 13.249 2.561 10.751 4.317 10.325C4.5808 10.2611 4.82578 10.1358 5.032 9.95929C5.23822 9.7828 5.39985 9.56011 5.50375 9.30935C5.60764 9.05859 5.65085 8.78683 5.62987 8.51621C5.60889 8.24559 5.5243 7.98375 5.383 7.752C4.443 6.209 6.209 4.442 7.753 5.382C8.753 5.99 10.049 5.452 10.325 4.317Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M9 12C9 12.7956 9.31607 13.5587 9.87868 14.1213C10.4413 14.6839 11.2044 15 12 15C12.7956 15 13.5587 14.6839 14.1213 14.1213C14.6839 13.5587 15 12.7956 15 12C15 11.2044 14.6839 10.4413 14.1213 9.87868C13.5587 9.31607 12.7956 9 12 9C11.2044 9 10.4413 9.31607 9.87868 9.87868C9.31607 10.4413 9 11.2044 9 12Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> </svg> <span>Settings</span> </button> </li> <li> <button id="add-page-link"> <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" > <path stroke="none" d="M0 0h24v24H0z" fill="none" /> <path d="M14 3v4a1 1 0 0 0 1 1h4" /> <path d="M17 21h-10a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2z" /> <path d="M12 11l0 6" /> <path d="M9 14l6 0" /> </svg> <span>Add Builder Page</span> </button> </li> <li> <button id="import-from-figma"> <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-figma" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" > <path stroke="none" d="M0 0h24v24H0z" fill="none" /> <path d="M15 12m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0" /> <path d="M6 3m0 3a3 3 0 0 1 3 -3h6a3 3 0 0 1 3 3v0a3 3 0 0 1 -3 3h-6a3 3 0 0 1 -3 -3z" /> <path d="M9 9a3 3 0 0 0 0 6h3m-3 0a3 3 0 1 0 3 3v-15" /> </svg> <span>Import From Figma</span> </button> </li> </ul> </div> <footer> <ul class="list"> <li> <a href="https://docs.google.com/forms/d/e/1FAIpQLSdqZcJpRtm_Ia5DTHP6SDY9Xa6LID3KiTjRWkjMzWyJRUtSHw/viewform" target="_blank" > <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M11.013 17.0114L10.013 18.0114L2.513 10.5834C2.0183 10.102 1.62864 9.52342 1.36854 8.88404C1.10845 8.24466 0.983558 7.55836 1.00173 6.86834C1.01991 6.17832 1.18076 5.49954 1.47415 4.87474C1.76755 4.24994 2.18713 3.69266 2.70648 3.23799C3.22583 2.78331 3.8337 2.4411 4.49181 2.23289C5.14991 2.02468 5.844 1.95499 6.53036 2.02821C7.21673 2.10143 7.8805 2.31596 8.47987 2.65831C9.07925 3.00066 9.60124 3.46341 10.013 4.01741C10.8086 2.95654 11.9931 2.2552 13.3059 2.06766C14.6186 1.88012 15.9521 2.22176 17.013 3.01741C18.0739 3.81306 18.7752 4.99755 18.9627 6.3103C19.1503 7.62305 18.8086 8.95654 18.013 10.0174" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" /> <path d="M18.2006 19.8175L16.0286 20.9555C15.9642 20.989 15.8917 21.004 15.8192 20.9987C15.7467 20.9934 15.6771 20.9681 15.6182 20.9256C15.5593 20.8831 15.5134 20.825 15.4855 20.7579C15.4577 20.6907 15.4491 20.6172 15.4606 20.5455L15.8756 18.1345L14.1186 16.4275C14.0662 16.3768 14.0291 16.3123 14.0115 16.2416C13.9939 16.1708 13.9966 16.0965 14.0192 16.0271C14.0418 15.9578 14.0835 15.8962 14.1394 15.8494C14.1954 15.8026 14.2634 15.7725 14.3356 15.7625L16.7636 15.4105L17.8496 13.2175C17.8821 13.1521 17.9322 13.0972 17.9942 13.0588C18.0562 13.0204 18.1277 13 18.2006 13C18.2736 13 18.3451 13.0204 18.4071 13.0588C18.4691 13.0972 18.5191 13.1521 18.5516 13.2175L19.6376 15.4105L22.0656 15.7625C22.1377 15.7728 22.2054 15.8031 22.2611 15.85C22.3168 15.8968 22.3583 15.9583 22.3809 16.0275C22.4034 16.0967 22.4062 16.1708 22.3888 16.2415C22.3715 16.3122 22.3347 16.3766 22.2826 16.4275L20.5256 18.1345L20.9396 20.5445C20.9521 20.6163 20.9441 20.6902 20.9166 20.7578C20.8891 20.8254 20.8433 20.8839 20.7842 20.9267C20.7252 20.9695 20.6553 20.9949 20.5825 21C20.5098 21.005 20.4371 20.9896 20.3726 20.9555L18.2006 19.8175Z" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" /> </svg> <span>Give Feedback</span> </a> </li> </ul> <div id="version"></div> </footer> </section> <section class="nav-cmp-list"> <header> <button class="back-button"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div class="search-container"> <div class="search-input-wrapper"> <svg class="search-icon" viewBox="0 0 24 24" width="16" height="16"> <path fill="none" stroke="currentColor" stroke-width="2" d="M15.5 15.5L20 20M10 17C6.13401 17 3 13.866 3 10C3 6.13401 6.13401 3 10 3C13.866 3 17 6.13401 17 10C17 13.866 13.866 17 10 17Z" /> </svg> <input type="text" id="component-search" class="component-search-input" placeholder="Search components..." autocomplete="off" spellcheck="false" /> <button id="clear-search" class="clear-search-button" type="button" aria-label="Clear search" > <svg viewBox="0 0 24 24" width="16" height="16"> <path fill="none" stroke="currentColor" stroke-width="2" d="M6 6l12 12M6 18L18 6" /> </svg> </button> </div> </div> <div> <h2>Custom Components</h2> <p> <button id="open-builder-registry"></button> </p> </div> </header> <div class="section-content"> <div id="cmp-list" class="cmp-list nav-list"></div> </div> <div class="nav-loading-icon spinner"></div> <footer> <p class="info"> Expand on Builder's selection of built-in blocks by <a target="_blank" href="https://www.builder.io/c/docs/custom-components-intro" >registering components</a > from your codebase. This way, teammates can drag and drop your components within Builder's Visual Editor just like any other block. </p> </footer> </section> <section class="nav-cmp-detail"> <header> <button class="back-button" data-back="nav-cmp-list"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div> <h2 id="cmp-detail-title"></h2> <p> <button id="cmp-open-source"></button> </p> </div> </header> <div class="section-content"> <div id="cmp-error"></div> <label class="ui-switch"> <div> <h3>Register Component</h3> <p> Registers this component so it can be used within Builder Visual CMS </p> </div> <input type="checkbox" role="switch" id="cmp-register" /> <span class="switcher"></span> </label> <div id="cmp-detail"> <label class="ui-text-input"> <h3>Component Name</h3> <div class="input"> <input type="text" id="cmp-name" autocapitalize="off" autocorrect="off" spellcheck="false" autocomplete="off" minlength="2" maxlength="30" required placeholder="e.g. My Counter" /> </div> <p> Unique name to identify this custom component within Builder. Press ESC to cancel </p> </label> <div class="cmp-detail-inputs-container"> <h3> <span>Builder Inputs (Props)</span> <button class="cmp-detail-inputs-reload" id="btn-inputs-reload"> Reload </button> </h3> <div id="cmp-detail-inputs"></div> </div> </div> </div> <div class="cmp-cover"></div> <div class="cmp-loading-icon spinner"></div> </section> <section class="nav-cmp-input"> <header> <button class="back-button" data-back="nav-cmp-detail"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div> <h2 id="cmp-input-title"></h2> <p> <button id="input-open-source"></button> </p> </div> </header> <div class="section-content"> <label class="ui-switch"> <div> <h3>Enable Input</h3> <p>Add this component prop as a Builder input</p> </div> <input type="checkbox" role="switch" id="input-register" /> <span class="switcher"></span> </label> <div class="cmp-prop-info"> <div class="cmp-input-readonly"> <h3>Prop Name</h3> <span id="cmp-prop-name"></span> </div> <div class="cmp-input-readonly"> <h3>Prop Type</h3> <span id="cmp-prop-type"></span> </div> </div> <div class="cmp-input-detail"> <label class="ui-text-input"> <h3>Builder Input Name</h3> <div class="input"> <input type="text" id="input-name" autocapitalize="off" autocorrect="off" spellcheck="false" autocomplete="off" minlength="1" maxlength="30" required placeholder="e.g. Text" /> </div> <p> Friendly name to identify this component prop as a Builder input. Press ESC to cancel </p> </label> <label class="ui-select"> <h3>Builder Input Type</h3> <div class="select"> <select id="input-type"></select> </div> <p> Correlate to what editing UI is appropriate for this Builder input. <a href="https://www.builder.io/c/docs/custom-components-input-types" target="_blank" >Read more about input types.</a > </p> </label> </div> <div class="input-cover"></div> <div class="input-loading-icon spinner"></div> </div> </section> <section class="nav-settings"> <header> <button class="back-button"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div> <h2>Settings</h2> <p>Configure Builder's Devtools</p> </div> </header> <div class="section-content"> <label class="ui-switch"> <div> <h3>Enable edit button in UI</h3> <p>Enables the edit button so you can edit content in Builder</p> </div> <input type="checkbox" role="switch" id="enable-edit" /> <span class="switcher"></span> </label> </div> </section> <div class="ui-toast" id="toast"></div> </aside> <button class="menu-toggle" aria-label="Toggle Builder Devtools"> <div> <div class="highlight-bg"></div> <svg viewBox="0 0 31 36" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M31 9.96854C31.0016 11.4553 30.6701 12.9236 30.03 14.2654C29.3898 15.6072 28.4572 16.7884 27.3007 17.7221L0.702841 2.61812C0.601104 2.56012 0.506714 2.49008 0.421705 2.40951C0.288323 2.27871 0.182333 2.12263 0.109928 1.95039C0.0375215 1.77814 0.000151253 1.59319 0 1.40633C0 1.03335 0.148098 0.675643 0.411715 0.411905C0.675332 0.148167 1.03287 0 1.40568 0L21.036 0C23.6786 0 26.213 1.05025 28.0816 2.91972C29.9502 4.78918 31 7.32472 31 9.96854Z" fill="#18B4F4" /> <path d="M31 25.4757C31.0004 26.7849 30.7429 28.0815 30.2423 29.2912C29.7417 30.5009 29.0078 31.6001 28.0825 32.526C27.1572 33.4519 26.0587 34.1864 24.8497 34.6875C23.6406 35.1886 22.3448 35.4465 21.0361 35.4465H1.40573C1.12766 35.4436 0.856725 35.3581 0.627199 35.201C0.397672 35.044 0.219871 34.8223 0.116289 34.5641C0.0127078 34.3059 -0.011999 34.0228 0.0452946 33.7505C0.102588 33.4783 0.239308 33.2292 0.438156 33.0347C0.517415 32.9551 0.606358 32.8858 0.702893 32.8284L11.1705 26.8843L27.2984 17.7244C28.4548 18.6579 29.3874 19.8387 30.028 21.18C30.6685 22.5213 31.0007 23.9891 31 25.4757Z" fill="#FD6B3C" /> <path d="M27.3011 17.7221L11.1709 26.8843L0.703209 32.8284C0.602697 32.8843 0.509784 32.9528 0.426758 33.0323C4.41799 28.9369 6.6496 23.442 6.64456 17.7221C6.65208 12.0015 4.42111 6.50517 0.429101 2.40948C0.51411 2.49005 0.6085 2.56009 0.710237 2.61809L27.3011 17.7221Z" fill="#A97FF2" /> </svg> </div> </button>\`,ai(e),ui(e),oi(e),ri(e),ti(e),ci(e),this.setAttribute("aria-hidden","true"),e.getElementById("version").textContent="v1.9.19"}highlightOpener(){let e=this.shadowRoot.querySelector(".menu-toggle");e.classList.add("menu-toggle-highlight"),e.classList.add("menu-toggle-highlight-no-transition"),setTimeout(()=>{e.classList.remove("menu-toggle-highlight-no-transition"),setTimeout(()=>{e.classList.remove("menu-toggle-highlight")},20)},20)}};var lo=\`<style>*,*:before,*:after{box-sizing:border-box}html,body,:host{position:fixed;top:0;left:0;width:100%;height:100vh;z-index:2147483646;margin:0;padding:0;line-height:1.8;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";background-color:#252525;color:#fff;transition:opacity .25s ease-in-out}:host([aria-hidden="true"]){opacity:0;pointer-events:none}main{position:absolute;top:0;left:0;width:100%;height:100vh}h1{margin-top:0;font-size:24px;font-weight:300;line-height:1.4}p{margin:20px 0;font-weight:300}button{cursor:pointer}aside{position:absolute;top:0;left:0;width:350px;height:100vh;padding:60px 0 0 50px;background-color:#121212}aside ul{margin:30px 0 0;padding:0;list-style:none}aside li{position:relative;margin:0;padding:20px 10px;font-weight:300}aside li.highlight{color:#48a1ff}aside li.active{font-weight:700}aside li .circle{position:absolute;top:20px;left:10px;width:24px;height:24px;border:3px solid white;border-radius:50%;font-size:14px}aside li.highlight .circle{border-color:#48a1ff}aside li.active .circle:after{content:"";position:absolute;top:3px;left:3px;width:12px;height:12px;border-radius:50%;background-color:#48a1ff}aside li.completed .circle{background-color:#48a1ff}aside li.completed .circle:after{content:"";position:absolute;top:2px;left:6px;width:6px;height:13px;border:3px solid black;border-top:none;border-left:none;transform:rotate(45deg)}aside li .line{position:absolute;top:44px;left:21px;width:3px;height:45px;background-color:#fff}aside li.completed .line{background-color:#48a1ff}aside li span{display:block;margin-left:44px}nav{margin-top:30px}section{position:absolute;top:135px;left:350px;padding:0 80px 0 140px;transition:opacity .15s ease-in-out}section[aria-hidden=true]{pointer-events:none;opacity:0}section h1,section p{min-width:300px;max-width:600px}.button{position:relative;display:inline-block;color:#fff;background-color:#48a1ff;border-radius:4px;text-decoration:none;padding:10px 40px 10px 20px;white-space:nowrap}.button:hover{background-color:#48a1ffd9}#button-icon{position:absolute;top:1px;right:5px;bottom:0;width:30px;background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path fill="none" stroke="white" stroke-linecap="square" stroke-miterlimit="10" stroke-width="48" d="M184 112l144 144-144 144"/></svg>');background-repeat:no-repeat;background-position:center;background-size:24px 24px}.button[aria-disabled=true]{opacity:.9;background-color:#ffffff4d;pointer-events:none;padding-right:60px}.button[aria-disabled=true] #button-icon{top:21px;right:29px;width:8px;height:8px;border-radius:4px;background:#fff;color:#fff;animation:dot-flashing .5s infinite linear alternate;animation-delay:.25s}.button[aria-disabled=true] #button-icon:before,.button[aria-disabled=true] #button-icon:after{content:"";display:inline-block;position:absolute;top:0}.button[aria-disabled=true] #button-icon:before{left:-12px;width:8px;height:8px;border-radius:4px;background-color:#fff;color:#fff;animation:dot-flashing .5s infinite alternate;animation-delay:0s}.button[aria-disabled=true] #button-icon:after{left:12px;width:8px;height:8px;border-radius:4px;background-color:#fff;color:#fff;animation:dot-flashing .5s infinite alternate;animation-delay:.5s}@keyframes dot-flashing{0%{background-color:#fff}50%,to{background-color:#ffffff4d}}.logo{margin-left:9px;background:url('data:image/svg+xml,<svg viewBox="0 0 150 32" fill="none" xmlns="http://www.w3.org/2000/svg" > <g clip-path="url(%23clip0_4_304)"> <path d="M27.9858 8.99927C27.9872 10.3415 27.688 11.667 27.1101 12.8783C26.5321 14.0896 25.6902 15.156 24.6462 15.9989V15.9989L0.634502 2.36355C0.542657 2.31119 0.457444 2.24796 0.380701 2.17523C0.260289 2.05715 0.164605 1.91624 0.0992389 1.76075C0.0338732 1.60525 0.000136546 1.43828 0 1.26959C0 0.932873 0.133698 0.609948 0.371683 0.371854C0.609667 0.13376 0.932443 0 1.269 0L18.9906 0C21.3763 0 23.6642 0.948135 25.3512 2.63583C27.0381 4.32352 27.9858 6.61252 27.9858 8.99927V8.99927Z" fill="%2318B4F4" /> <path d="M27.9858 22.9986C27.9861 24.1806 27.7536 25.351 27.3017 26.4431C26.8498 27.5352 26.1873 28.5275 25.352 29.3634C24.5167 30.1993 23.5249 30.8624 22.4335 31.3147C21.342 31.7671 20.1721 32 18.9907 32H1.26906C1.01802 31.9973 0.77343 31.9202 0.566221 31.7784C0.359012 31.6366 0.198499 31.4364 0.104989 31.2034C0.0114791 30.9703 -0.0108254 30.7147 0.0408974 30.4689C0.0926201 30.2231 0.216046 29.9982 0.395559 29.8226V29.8226C0.467112 29.7508 0.547407 29.6882 0.634555 29.6364L10.0844 24.2703L24.6441 16.001C25.688 16.8438 26.53 17.9097 27.1083 19.1206C27.6866 20.3315 27.9864 21.6566 27.9858 22.9986V22.9986Z" fill="%23FD6B3C" /> <path d="M24.6461 15.9989L10.0843 24.2703L0.634458 29.6365C0.54372 29.6868 0.459841 29.7487 0.384888 29.8205C3.98804 26.1233 6.00266 21.1627 5.99812 15.9989C6.0049 10.8346 3.99085 5.87268 0.387003 2.17523C0.463746 2.24796 0.548959 2.31119 0.640803 2.36355L24.6461 15.9989Z" fill="%23A97FF2" /> <path d="M47.6659 11.7352C51.8177 11.7352 54.1632 15.0531 54.1632 19.0714C54.1632 23.0896 51.8177 26.3821 47.6659 26.3821C45.5086 26.3821 43.8589 25.5188 42.9473 24.0545L42.5709 26.052H39.9736V6.77115H43.1884V13.8914C43.971 12.6959 45.5086 11.7352 47.6659 11.7352ZM47.0187 23.5488C49.4446 23.5488 50.9547 21.5809 50.9547 19.0714C50.9547 16.5089 49.4446 14.5664 47.0187 14.5664C44.5928 14.5664 43.0806 16.5047 43.0806 19.0714C43.0806 21.583 44.5653 23.5488 47.0187 23.5488V23.5488Z" fill="white" /> <path d="M65.4595 20.2859V12.0611H68.668V20.123C68.668 23.7202 67.0246 26.3821 62.4943 26.3821C57.9639 26.3821 56.3206 23.7117 56.3206 20.123V12.0611H59.529V20.2859C59.529 22.4696 60.5527 23.5488 62.49 23.5488C64.4274 23.5488 65.4595 22.4696 65.4595 20.2859Z" fill="white" /> <path d="M71.2355 7.74451C71.2247 7.46284 71.2724 7.18199 71.3755 6.91968C71.4787 6.65737 71.6351 6.41929 71.8348 6.22047C72.0345 6.02165 72.2732 5.8664 72.5359 5.76452C72.7986 5.66264 73.0796 5.61633 73.3611 5.62853C74.5793 5.62853 75.4571 6.50666 75.4571 7.75509C75.4571 9.00352 74.5793 9.8224 73.3611 9.8224C72.1428 9.8224 71.2355 8.9612 71.2355 7.74451Z" fill="white" /> <path d="M128.476 7.74451C128.465 7.46376 128.513 7.18383 128.615 6.92227C128.718 6.66071 128.873 6.42315 129.072 6.22449C129.27 6.02583 129.508 5.87035 129.769 5.7678C130.031 5.66524 130.31 5.61783 130.591 5.62852C131.809 5.62852 132.687 6.50666 132.687 7.75509C132.687 9.00352 131.809 9.8224 130.591 9.8224C129.373 9.8224 128.476 8.9612 128.476 7.74451Z" fill="white" /> <path d="M122.302 24.1031C122.291 23.8223 122.339 23.5422 122.441 23.2805C122.543 23.0188 122.699 22.7811 122.897 22.5824C123.096 22.3837 123.334 22.2282 123.595 22.1258C123.857 22.0233 124.137 21.9761 124.417 21.9872C125.636 21.9872 126.513 22.8653 126.513 24.1031C126.513 25.341 125.636 26.1726 124.417 26.1726C123.199 26.1726 122.302 25.3219 122.302 24.1031Z" fill="white" /> <path d="M74.9516 12.059H71.7432V26.0583H74.9516V12.059Z" fill="white" /> <path d="M78.16 26.0583V6.77115H81.3685V26.0626L78.16 26.0583Z" fill="white" /> <path d="M94.6063 6.77115H97.8148V26.0626H95.2239L94.8474 24.0651C93.9591 25.523 92.3094 26.3927 90.131 26.3927C86.0046 26.3927 83.6591 23.0748 83.6591 19.0819C83.6591 15.0891 86.0046 11.7458 90.131 11.7458C92.3137 11.7458 93.8238 12.7149 94.6063 13.902V6.77115ZM90.7993 14.5707C88.3734 14.5707 86.8633 16.5131 86.8633 19.0756C86.8633 21.5851 88.3734 23.553 90.7993 23.553C93.2252 23.553 94.7354 21.5851 94.7354 19.0756C94.7396 16.5047 93.257 14.5664 90.8036 14.5664L90.7993 14.5707Z" fill="white" /> <path d="M113.479 22.2284C112.482 24.7359 110.162 26.3821 107.117 26.3821C102.887 26.3821 100.137 23.225 100.137 19.0439C100.137 14.9706 102.942 11.7353 107.093 11.7353C111.245 11.7353 113.969 14.8902 113.969 18.991C113.982 19.3255 113.953 19.6604 113.883 19.9876H103.288C103.53 22.2009 104.959 23.6292 107.197 23.6292C108.735 23.6292 110.001 22.8738 110.594 21.473L113.479 22.2284ZM103.341 17.6156H110.784C110.513 15.6731 109.166 14.3506 107.089 14.3506C105.012 14.3506 103.665 15.7006 103.341 17.6156V17.6156Z" fill="white" /> <path d="M123.779 14.9452C123.538 14.9117 123.295 14.8933 123.051 14.8902C120.786 14.8902 119.439 16.0772 119.439 18.7751V26.0583H116.23V12.0611H118.821L119.195 14.0014C119.707 13.1127 120.887 11.9257 123.322 11.9257C123.455 11.9257 123.779 11.9532 123.779 11.9532V14.9452Z" fill="white" /> <path d="M132.192 12.059H128.984V26.0583H132.192V12.059Z" fill="white" /> <path d="M134.483 19.0714C134.483 15.1335 137.287 11.7353 141.735 11.7353C146.183 11.7353 149.015 15.1335 149.015 19.0714C149.015 23.0092 146.213 26.3821 141.735 26.3821C137.258 26.3821 134.483 23.0092 134.483 19.0714ZM141.735 23.5488C144.083 23.5488 145.806 21.7692 145.806 19.0714C145.806 16.3735 144.083 14.5664 141.735 14.5664C139.387 14.5664 137.687 16.346 137.687 19.0714C137.687 21.7968 139.417 23.5488 141.735 23.5488V23.5488Z" fill="white" /> </g> <defs> <clipPath id="clip0_4_304"> <rect width="149.015" height="32" fill="white" /> </clipPath> </defs> </svg>');background-repeat:no-repeat;width:150px;height:32px}@media (max-width: 840px){aside{width:250px;padding:60px 0 0 20px}section{left:250px;padding:0 80px}}@media (max-width: 590px){aside{width:230px;padding:60px 0 0 10px}section{left:230px;padding:0 40px}}#modified-files-message a{color:#cbcbcb;font-weight:300;text-decoration:underline}#modified-files-message a:hover{color:#fff;text-decoration:none}#restart-warning{border-radius:4px;padding:8px 16px;border:1px solid #fd6b3c;background:#fd6b3c1a}#react-router-steps{margin:0 0 5px;padding:0 20px}#need-help{color:#48a1ff;text-decoration:none}#router-message{border-radius:4px;padding:16px;border:1px solid #48a1ff}#router-finish-button{margin-top:12px}#router-checkbox-div{display:flex;align-items:center}#router-checkbox{margin-right:10px;width:15px;height:15px}#success-title{display:flex;align-items:center;gap:10px}#success-title .check-icon{display:inline-block;width:24px;height:24px;border:2px solid #28a745;border-radius:50%;position:relative}#success-title .check-icon:before{content:"";position:absolute;top:50%;left:50%;width:6px;height:12px;border:solid #28a745;border-width:0 2px 2px 0;transform:translate(-50%,-60%) rotate(45deg)}
1318
+ \`,t.appendChild(e),setTimeout(()=>{e.classList.add("menu-toggle-tooltip-show"),e.addEventListener("click",()=>{e.classList.remove("menu-toggle-tooltip-show")})},1e3)};function ui(t){t.getElementById("go-to-builder").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),Ee(t,!1),window.open(Nr(),"builder")}),t.getElementById("components-link").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation();let u=t.querySelector(".nav-cmp-list .section-content");u.scrollTop=0,oe(t,"nav-cmp-list"),si(t)}),t.getElementById("settings-link").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),oe(t,"nav-settings")}),t.getElementById("add-page-link").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),Ee(t,!1),window.open(je(),"builder")}),t.getElementById("import-from-figma").addEventListener("click",s=>{s.preventDefault(),s.stopPropagation(),Ee(t,!1),window.open("https://www.figma.com/community/plugin/747985167520967365/builder-io-ai-powered-figma-to-code-react-vue-tailwind-more")})}function ci(t){let e=t.getElementById("enable-edit");e.addEventListener("change",r=>{r.stopPropagation(),Ft(e.checked)}),e.checked=it(),Ft(e.checked)}var At=class extends HTMLElement{constructor(){super()}connectedCallback(){let e=this.attachShadow({mode:"open"});e.innerHTML=\`<style>*,*:before,*:after{box-sizing:border-box}:host{--background-color: rgba(40, 40, 40, 1);--primary-color: rgba(72, 161, 255, 1);--primary-color-subdued: rgb(72, 161, 255, .6);--primary-color-highlight: rgb(126, 188, 255);--primary-contrast-color: white;--edit-color: #1d74e2;--edit-color-highlight: #1c6bd1;--edit-color-alpha: rgb(72, 161, 255, .15);--error-color: #ff2b55;--text-color: white;--text-color-highlight: white;--border-color: #454545;--button-background-color-hover: rgba(255, 255, 255, .1);--menu-width: 320px;--transition-time: .15s;--font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";font-family:var(--font-family);line-height:1.6}button{cursor:pointer;color:var(--text-color);-webkit-tap-highlight-color:transparent}input,select,button{font-family:var(--font-family)}.menu-toggle{position:absolute;right:0;bottom:0;pointer-events:auto;padding:8px;background:transparent;border:none;appearance:none}.menu-toggle div{position:relative;width:64px;height:64px;pointer-events:none;border-radius:50%;background:#000;border:1px solid white;box-shadow:#00000054 0 0 8px}.menu-toggle:hover div{background-color:var(--background-color);border:1px solid rgb(220,220,220)}.menu-toggle svg{position:absolute;top:15px;left:15px;width:33px;height:32px}div.highlight-bg{position:absolute;top:-1px;left:-1px;background-color:#1a1a1a;pointer-events:none;transition:all .4s ease-out;opacity:0}.menu-toggle-highlight-no-transition div.highlight-bg{transition:none}.menu-toggle-highlight div.highlight-bg{opacity:1}.menu-toggle-tooltip{position:absolute;bottom:0;right:0;width:382px;height:72px;padding:0;text-align:left;appearance:none;background-color:transparent;border:none;pointer-events:none;transform:translate3d(320px,0,0);opacity:0;transition:all .15s ease-in-out;color:#fff}.menu-toggle-tooltip.menu-toggle-tooltip-show{pointer-events:auto;opacity:1;transform:translateZ(0)}.menu-toggle-tooltip-content{position:absolute;inset:0 95px 10px 0;padding:8px 12px;background-color:var(--primary-color);box-shadow:#00000054 0 0 20px;border-radius:2px}.menu-toggle-tooltip-content:before{content:"";position:absolute;bottom:15px;right:-6px;width:30px;height:30px;background-color:var(--primary-color);transform:rotate(45deg)}.menu-toggle-tooltip:hover .menu-toggle-tooltip-content,.menu-toggle-tooltip:hover .menu-toggle-tooltip-content:before{background-color:var(--primary-color-highlight)}.menu-toggle-tooltip-content h3{margin:0;font-size:16px}.menu-toggle-tooltip-content p{margin:0;font-size:12px}section{position:absolute;display:grid;grid-template-rows:64px auto 64px;top:0;left:0;width:100%;height:100%;padding:0;pointer-events:none}.section-content{margin:0;padding:0 0 10px;font-weight:300;transform:translate3d(105%,0,0);transition:transform var(--transition-time) ease-in-out;overflow-y:auto}.section-content .error{color:var(--error-color);font-weight:700}section a{text-decoration:none;color:var(--text-color)}section h3,section p{margin-left:16px;margin-right:16px}.info{font-size:12px}ul.list{list-style:none;padding:0;margin:0}ul.list li{display:block;padding:0;margin:0}ul.list a,ul.list button{display:grid;grid-template-columns:24px auto;grid-gap:16px;padding:12px;margin:8px 0;border:none;background:transparent;appearance:none;width:100%;font-weight:300;text-align:left;text-decoration:none;color:var(--text-color)}ul.list a:hover,ul.list button:hover{text-decoration:none;color:var(--text-color);background-color:var(--button-background-color-hover)}ul.list a span,ul.list button span{display:block;font-size:16px;font-weight:500;line-height:1.5;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}header{position:relative;display:grid;grid-template-columns:44px 1fr;gap:8px;padding-left:8px;border-bottom:1px solid var(--border-color);transition:opacity var(--transition-time) ease-in-out;opacity:0;pointer-events:none}header>div{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nav-home header>div{margin-right:56px}header h2{margin:7px 0 0;font-size:18px;font-weight:500;line-height:1.5;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}header p{margin:2px 0 0;font-size:12px;font-weight:300;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}header p button{display:block;margin:0;padding:0;width:100%;font-size:12px;font-weight:300;text-decoration:none;appearance:none;text-align:left;background-color:transparent;border:none;color:var(--primary-color);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}header p button:hover{text-decoration:underline;color:var(--primary-color)}.builder-logo{margin:12px 0 0 8px}#close{display:block;position:absolute;appearance:none;background:transparent;border:none;border-radius:50%;margin:0;padding:0;right:4px;top:8px;width:48px;height:48px;z-index:1;opacity:.7}#close:hover{opacity:1;background-color:var(--button-background-color-hover)}#close svg{position:absolute;top:12px;left:12px;width:24px;height:24px;fill:currentColor;pointer-events:none}.back-button{position:relative;display:block;margin:7px 0 0 -2px;width:48px;height:48px;background:transparent;border:none;appearance:none;border-radius:50%}.back-button:hover{background-color:var(--button-background-color-hover)}.back-button svg{position:absolute;top:12px;left:12px;width:24px;height:24px;fill:currentColor;pointer-events:none}footer{border-top:1px solid var(--border-color);transition:opacity var(--transition-time) ease-in-out;opacity:0;pointer-events:none}section.nav-cmp-list{grid-template-rows:64px auto 120px}footer a{text-decoration:underline;color:var(--primary-color)}footer a:hover{color:var(--primary-color);text-decoration:none}.nav-list{padding:2px 0}.nav-loading{pointer-events:none}.nav-loading-icon{position:absolute;display:inline-block;top:170px;left:0;width:100%;transform:translateZ(0);pointer-events:auto;opacity:0;transition:all 50ms ease-in-out;transition-delay:50ms;pointer-events:none}.nav-loading .nav-loading-icon{opacity:.5}.nav-list h4{margin:8px 8px 8px 10px;font-size:14px;font-weight:600}.nav-list .nav-list-item+h4{margin-top:30px}.nav-list-item{display:grid;grid-template-columns:1fr 1fr;gap:8px;position:relative;margin:2px 0;padding:8px 28px 8px 46px;width:100%;font-size:14px;font-weight:300;text-align:left;border:none;background:transparent;appearance:none}.nav-list-item:hover{background-color:var(--button-background-color-hover)}.nav-list-item-icon{position:absolute;top:4px;left:10px;width:24px;height:24px;object-fit:contain;filter:invert(100%);background-size:24px 24px;background-repeat:no-repeat;background-position:center center}.nav-list-item span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;pointer-events:none}.nav-list-item:after{display:block;position:absolute;content:"";background-image:url('data:image/svg+xml,<svg width="8" height="14" viewBox="0 0 8 14" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M1 1L7 7L1 13" stroke="%23F2F2F2" stroke-opacity="0.5" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/></svg>');background-repeat:no-repeat;background-position:12px 9px;top:0;right:0;width:32px;height:32px;pointer-events:none}.nav-list-item-note{opacity:0;font-size:12px;padding-top:1px;text-align:right}.nav-list-item:hover .nav-list-item-note{opacity:.5}.ui-select{display:block;margin:8px 0 16px;padding:8px 16px;cursor:pointer}.ui-select h3{margin:0;font-size:14px;font-weight:500}.ui-select p{margin:8px 0;font-size:12px;font-weight:300}.ui-select .select{position:relative;margin:8px 0;border-radius:4px;padding:0;line-height:1.1;overflow:hidden;border:1px solid var(--border-color)}.ui-select select{appearance:none;background-color:transparent;border:none;outline:none;padding:8px 32px 8px 8px;margin:0;width:100%;font-size:14px;cursor:pointer;text-overflow:ellipsis;opacity:.6;color:var(--text-color)}.ui-select .select:after{content:"";top:6px;right:5px;width:24px;height:24px;position:absolute;background-image:url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path fill="%23F2F2F2" d="M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"/></svg>');background-repeat:no-repeat;background-position:center;pointer-events:none;opacity:.6}.ui-select .select:hover{border-color:var(--primary-color-subdued)}.ui-text-input .select:focus-within{border-color:var(--primary-color)}.ui-text-input .select:focus-within select{opacity:1}.spinner:after{content:" ";display:block;width:32px;height:32px;margin:0 auto;pointer-events:auto;border-radius:50%;border:3px solid var(--text-color);border-color:var(--text-color) transparent var(--text-color) transparent;animation:spinner .75s linear infinite}@keyframes spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.ui-switch{display:grid;grid-template-columns:auto 48px;grid-gap:20px;margin:8px 0 16px;padding:8px 0 8px 16px;cursor:pointer}.ui-switch>*{pointer-events:none}.ui-switch input{display:none;visibility:hidden}.ui-switch .switcher{display:inline-block;border-radius:100px;width:35px;height:14px;background-color:#ccc;position:relative;top:6px;vertical-align:middle;cursor:pointer}.ui-switch input[type=checkbox]:checked+.switcher{background-color:var(--primary-color-subdued)}.ui-switch .switcher:before{content:"";display:block;width:20px;height:20px;background-color:var(--text-color);box-shadow:0 1px 3px #0009;border-radius:50%;position:absolute;top:-3px;left:0;margin-right:0;transition:all .15s}.ui-switch input[type=checkbox]:checked+.switcher:before{left:100%;margin-left:-20px;background-color:var(--primary-color)}.ui-switch h3{margin:0;font-size:14px;font-weight:500}.ui-switch p{margin:4px 0 0;font-size:12px;font-weight:300}.ui-text-input{display:block;margin:8px 0 16px;padding:8px 16px;cursor:pointer}.ui-text-input h3{margin:0;font-size:14px;font-weight:500}.ui-text-input p{margin:8px 0;font-size:12px;font-weight:300}.ui-text-input .input{position:relative;margin:8px 0;border:1px solid var(--border-color);border-radius:4px;background:transparent;padding:2px;overflow:hidden}.ui-text-input input{display:block;width:235px;font-size:14px;border:none;background:transparent;padding:6px;appearance:none;color:var(--text-color);opacity:.6;outline:none}.ui-text-input .input:hover{border-color:var(--primary-color-subdued)}.ui-text-input .input:focus-within{border-color:var(--primary-color)}.ui-text-input .input:focus-within input{opacity:1}.ui-text-input .input:after{content:"";position:absolute;top:5px;right:14px;width:8px;height:17px;border:2px solid rgba(51,181,51,1);border-top:none;border-left:none;transform:rotate(45deg);opacity:0;transition:opacity 80ms ease-in-out;pointer-events:none}.ui-text-input.saved .input:after{opacity:1}.ui-toast{position:fixed;bottom:8px;left:8px;right:8px;padding:6px 12px;font-size:14px;border-radius:4px;transform:translate3d(0,150%,0);opacity:0;transition:all var(--transition-time) ease-in-out;background-color:var(--primary-color-subdued);color:var(--text-color);pointer-events:none}.ui-toast.ui-toast-show{transform:translateZ(0);opacity:1;pointer-events:auto}[data-view=nav-home] .nav-home .section-content,[data-view=nav-cmp-list] .nav-cmp-list .section-content,[data-view=nav-cmp-detail] .nav-cmp-detail .section-content,[data-view=nav-cmp-input] .nav-cmp-input .section-content,[data-view=nav-settings] .nav-settings .section-content{transform:translateZ(0);pointer-events:auto}[data-view=nav-home] .nav-home header,[data-view=nav-home] .nav-home footer,[data-view=nav-cmp-list] .nav-cmp-list header,[data-view=nav-cmp-list] .nav-cmp-list footer,[data-view=nav-cmp-detail] .nav-cmp-detail header,[data-view=nav-cmp-detail] .nav-cmp-detail footer,[data-view=nav-cmp-input] .nav-cmp-input header,[data-view=nav-cmp-input] .nav-cmp-input footer,[data-view=nav-settings] .nav-settings header,[data-view=nav-settings] .nav-settings footer{opacity:1;pointer-events:auto}[data-view=nav-cmp-list] .nav-home .section-content,[data-view=nav-cmp-detail] .nav-home .section-content,[data-view=nav-cmp-detail] .nav-cmp-list .section-content,[data-view=nav-cmp-input] .nav-home .section-content,[data-view=nav-cmp-input] .nav-cmp-list .section-content,[data-view=nav-cmp-input] .nav-cmp-detail .section-content,[data-view=nav-settings] .nav-home .section-content{transform:translate3d(-105%,0,0)}.cmp-item .nav-list-item-icon{background-image:url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20.83 16.809C20.94 16.561 21 16.289 21 16.008V7.99001C20.9994 7.64108 20.9066 7.29851 20.731 6.99699C20.5554 6.69547 20.3032 6.44571 20 6.27301L13 2.26501C12.6954 2.09103 12.3508 1.99951 12 1.99951C11.6492 1.99951 11.3046 2.09103 11 2.26501L7.988 3.99001M5.441 5.44801L4 6.27301C3.381 6.62801 3 7.28301 3 7.99101V16.009C3 16.718 3.381 17.372 4 17.726L11 21.734C11.3046 21.908 11.6492 21.9995 12 21.9995C12.3508 21.9995 12.6954 21.908 13 21.734L18.544 18.56" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M12 22V12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M14.532 10.538L20.73 6.95996" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M3.27002 6.95996L12 12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/><path d="M3 3L21 21" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round"/></svg>');opacity:.3}.cmp-item.registered .nav-list-item-icon{background-image:url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M21 16.008V7.99001C20.9994 7.64108 20.9066 7.29851 20.731 6.99699C20.5554 6.69547 20.3032 6.44571 20 6.27301L13 2.26501C12.6954 2.09103 12.3508 1.99951 12 1.99951C11.6492 1.99951 11.3046 2.09103 11 2.26501L4 6.27301C3.381 6.62801 3 7.28301 3 7.99101V16.009C3 16.718 3.381 17.372 4 17.726L11 21.734C11.3046 21.908 11.6492 21.9995 12 21.9995C12.3508 21.9995 12.6954 21.908 13 21.734L20 17.726C20.619 17.371 21 16.716 21 16.008Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 22V12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 12L20.73 6.95996" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M3.26999 6.95996L12 12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /></svg>');opacity:.8}.search-highlight{background-color:var(--primary-color-alpha);padding:0 2px;border-radius:2px;font-weight:500}.search-container{position:sticky;top:0;z-index:10;padding:12px 16px;background:var(--background-color);border-bottom:1px solid var(--border-color)}.search-input-wrapper{position:relative;display:flex;align-items:center}.search-icon{position:absolute;left:12px;color:var(--text-color-secondary);pointer-events:none}.component-search-input{width:100%;height:36px;padding:8px 36px;border:1px solid var(--border-color);border-radius:6px;background:var(--input-background);color:var(--text-color);font-size:14px;transition:border-color .2s,box-shadow .2s}.component-search-input:focus{outline:none;border-color:var(--primary-color);box-shadow:0 0 0 2px var(--primary-color-alpha)}.component-search-input::placeholder{color:var(--text-color-tertiary)}.clear-search-button{position:absolute;right:8px;padding:4px;color:var(--text-color-secondary);border:none;background:transparent;border-radius:4px;cursor:pointer;opacity:0;transition:opacity .2s,background-color .2s;display:flex;align-items:center;justify-content:center}.clear-search-button:hover{background-color:var(--hover-color)}.component-search-input:not(:placeholder-shown)+.clear-search-button{opacity:1}.no-results{padding:32px 16px;text-align:center;color:var(--text-color-secondary);font-size:14px}#cmp-detail{position:relative}.cmp-loading{pointer-events:none!important}.cmp-loading-icon{position:absolute;display:inline-block;top:170px;left:0;width:100%;transform:translateZ(0);pointer-events:auto;opacity:0;transition:all 50ms ease-in-out;transition-delay:50ms;pointer-events:none}.cmp-loading .cmp-loading-icon{opacity:.5}.cmp-cover{position:absolute;top:160px;left:0;width:100%;height:100vh;background:var(--background-color);transform:translateZ(0);pointer-events:none;display:none}[data-view=nav-cmp-detail] .cmp-cover{display:block;pointer-events:auto}.cmp-enabled .cmp-cover{transform:translate3d(0,105%,0);pointer-events:none}.section-ready .cmp-cover{transition:all var(--transition-time) ease-in-out}.cmp-detail-inputs-container{margin:8px 0 16px;padding:0}.cmp-detail-inputs-container h3{margin:0 0 6px;padding-left:16px;padding-right:8px;font-size:14px;font-weight:500;display:flex;justify-content:space-between;align-items:center}.cmp-detail-inputs-reload{font-weight:300;font-size:.9em;text-decoration:none;appearance:none;text-align:left;background-color:transparent;border:none;color:var(--primary-color);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cmp-detail-inputs-reload:hover{text-decoration:underline;color:var(--primary-color)}.cmp-detail-inputs-container .cmp-inputs-empty{padding:0;margin-top:12px;font-size:12px;font-weight:300;opacity:.5;font-style:italic}.cmp-detail-inputs-container .nav-list-item-icon{opacity:.8;background-size:20px 20px;background-position:4px center}.input-icon{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path></svg>')}.input-icon-array{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 16v-6a2 2 0 1 1 4 0v6"></path> <path d="M10 13h4"></path></svg>')}.input-icon-boolean{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 16h2a2 2 0 1 0 0 -4h-2h2a2 2 0 1 0 0 -4h-2v8z"></path></svg>')}.input-icon-number{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 16v-8l4 8v-8"></path></svg>')}.input-icon-object{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M12 8a2 2 0 0 1 2 2v4a2 2 0 1 1 -4 0v-4a2 2 0 0 1 2 -2z"></path></svg>')}.input-icon-string{background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> <path stroke="none" d="M0 0h24v24H0z" fill="none"></path> <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0"></path> <path d="M10 15a1 1 0 0 0 1 1h2a1 1 0 0 0 1 -1v-2a1 1 0 0 0 -1 -1h-2a1 1 0 0 1 -1 -1v-2a1 1 0 0 1 1 -1h2a1 1 0 0 1 1 1"></path></svg>')}.cmp-input-item-unregistered{opacity:.4}.cmp-input-item-unregistered .input-icon:after{content:"";position:absolute;top:11px;left:4px;width:20px;height:2px;background-color:#000;transform:rotate(-45deg)}.cmp-prop-info{border-bottom:1px solid var(--border-color)}.cmp-input-readonly{margin:16px 0;padding:0 16px;display:grid;grid-template-columns:50% 50%;gap:12px}.cmp-input-readonly h3{margin:0;font-size:14px;font-weight:500}.cmp-input-readonly span{margin-top:2px;font-size:12px;font-weight:300;opacity:.8}.cmp-input-detail{margin:16px 0}.cmp-input-detail a{color:var(--primary-color);text-decoration:none}.cmp-input-detail a:hover{text-decoration:underline}.input-cover{position:absolute;top:175px;left:0;width:100%;height:100%;background:var(--background-color);transform:translateZ(0);transition:all var(--transition-time) ease-in-out;pointer-events:auto}.input-enabled .input-cover{transform:translate3d(0,105%,0);pointer-events:none}.input-loading-icon{position:absolute;display:inline-block;top:190px;left:0;width:100%;transform:translateZ(0);pointer-events:auto;opacity:0;transition:all 50ms ease-in-out;transition-delay:50ms;pointer-events:none}.input-loading .input-loading-icon{opacity:.5}:host{position:fixed;inset:0;z-index:2147483646;user-select:none;pointer-events:none;color:var(--text-color)}aside{position:absolute;top:0;right:0;width:var(--menu-width);height:100%;transform:translate3d(105%,0,0);transition:transform var(--transition-time) ease-in-out;background:var(--background-color);box-shadow:#000000c9 5px 0 20px;overflow:hidden;z-index:1}:host(.show-builder-menu) aside{pointer-events:auto;transform:translateZ(0)}#hit{position:absolute;inset:0;display:none}:host(.show-builder-menu) #hit{display:block;pointer-events:auto}#version{position:absolute;bottom:6px;right:6px;font-size:8px;color:#9b9b9b}</style><div id="hit"></div> <aside data-view="nav-home"> <section class="nav-home"> <header> <svg class="builder-logo" viewBox="0 0 31 36" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M31 9.96854C31.0016 11.4553 30.6701 12.9236 30.03 14.2654C29.3898 15.6072 28.4572 16.7884 27.3007 17.7221L0.702841 2.61812C0.601104 2.56012 0.506714 2.49008 0.421705 2.40951C0.288323 2.27871 0.182333 2.12263 0.109928 1.95039C0.0375215 1.77814 0.000151253 1.59319 0 1.40633C0 1.03335 0.148098 0.675643 0.411715 0.411905C0.675332 0.148167 1.03287 0 1.40568 0L21.036 0C23.6786 0 26.213 1.05025 28.0816 2.91972C29.9502 4.78918 31 7.32472 31 9.96854Z" fill="#18B4F4" /> <path d="M31 25.4757C31.0004 26.7849 30.7429 28.0815 30.2423 29.2912C29.7417 30.5009 29.0078 31.6001 28.0825 32.526C27.1572 33.4519 26.0587 34.1864 24.8497 34.6875C23.6406 35.1886 22.3448 35.4465 21.0361 35.4465H1.40573C1.12766 35.4436 0.856725 35.3581 0.627199 35.201C0.397672 35.044 0.219871 34.8223 0.116289 34.5641C0.0127078 34.3059 -0.011999 34.0228 0.0452946 33.7505C0.102588 33.4783 0.239308 33.2292 0.438156 33.0347C0.517415 32.9551 0.606358 32.8858 0.702893 32.8284L11.1705 26.8843L27.2984 17.7244C28.4548 18.6579 29.3874 19.8387 30.028 21.18C30.6685 22.5213 31.0007 23.9891 31 25.4757Z" fill="#FD6B3C" /> <path d="M27.3011 17.7221L11.1709 26.8843L0.703209 32.8284C0.602697 32.8843 0.509784 32.9528 0.426758 33.0323C4.41799 28.9369 6.6496 23.442 6.64456 17.7221C6.65208 12.0015 4.42111 6.50517 0.429101 2.40948C0.51411 2.49005 0.6085 2.56009 0.710237 2.61809L27.3011 17.7221Z" fill="#A97FF2" /> </svg> <div> <h2 class="builder-home-title">Builder Devtools</h2> <p><button id="go-to-builder">Go to Builder</button></p> </div> <button id="close" aria-label="Close Menu"> <svg viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" > <path stroke="none" d="M0 0h24v24H0z" fill="none" /> <path d="M18 6l-12 12" /> <path d="M6 6l12 12" /> </svg> </button> </header> <div class="section-content"> <ul class="list"> <li> <button id="components-link"> <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M21 16.008V7.99001C20.9994 7.64108 20.9066 7.29851 20.731 6.99699C20.5554 6.69547 20.3032 6.44571 20 6.27301L13 2.26501C12.6954 2.09103 12.3508 1.99951 12 1.99951C11.6492 1.99951 11.3046 2.09103 11 2.26501L4 6.27301C3.381 6.62801 3 7.28301 3 7.99101V16.009C3 16.718 3.381 17.372 4 17.726L11 21.734C11.3046 21.908 11.6492 21.9995 12 21.9995C12.3508 21.9995 12.6954 21.908 13 21.734L20 17.726C20.619 17.371 21 16.716 21 16.008Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 22V12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M12 12L20.73 6.95996" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M3.26999 6.95996L12 12" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> </svg> <span>Components</span> </button> </li> <li> <button id="settings-link"> <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M10.325 4.317C10.751 2.561 13.249 2.561 13.675 4.317C13.7389 4.5808 13.8642 4.82578 14.0407 5.032C14.2172 5.23822 14.4399 5.39985 14.6907 5.50375C14.9414 5.60764 15.2132 5.65085 15.4838 5.62987C15.7544 5.60889 16.0162 5.5243 16.248 5.383C17.791 4.443 19.558 6.209 18.618 7.753C18.4769 7.98466 18.3924 8.24634 18.3715 8.51677C18.3506 8.78721 18.3938 9.05877 18.4975 9.30938C18.6013 9.55999 18.7627 9.78258 18.9687 9.95905C19.1747 10.1355 19.4194 10.2609 19.683 10.325C21.439 10.751 21.439 13.249 19.683 13.675C19.4192 13.7389 19.1742 13.8642 18.968 14.0407C18.7618 14.2172 18.6001 14.4399 18.4963 14.6907C18.3924 14.9414 18.3491 15.2132 18.3701 15.4838C18.3911 15.7544 18.4757 16.0162 18.617 16.248C19.557 17.791 17.791 19.558 16.247 18.618C16.0153 18.4769 15.7537 18.3924 15.4832 18.3715C15.2128 18.3506 14.9412 18.3938 14.6906 18.4975C14.44 18.6013 14.2174 18.7627 14.0409 18.9687C13.8645 19.1747 13.7391 19.4194 13.675 19.683C13.249 21.439 10.751 21.439 10.325 19.683C10.2611 19.4192 10.1358 19.1742 9.95929 18.968C9.7828 18.7618 9.56011 18.6001 9.30935 18.4963C9.05859 18.3924 8.78683 18.3491 8.51621 18.3701C8.24559 18.3911 7.98375 18.4757 7.752 18.617C6.209 19.557 4.442 17.791 5.382 16.247C5.5231 16.0153 5.60755 15.7537 5.62848 15.4832C5.64942 15.2128 5.60624 14.9412 5.50247 14.6906C5.3987 14.44 5.23726 14.2174 5.03127 14.0409C4.82529 13.8645 4.58056 13.7391 4.317 13.675C2.561 13.249 2.561 10.751 4.317 10.325C4.5808 10.2611 4.82578 10.1358 5.032 9.95929C5.23822 9.7828 5.39985 9.56011 5.50375 9.30935C5.60764 9.05859 5.65085 8.78683 5.62987 8.51621C5.60889 8.24559 5.5243 7.98375 5.383 7.752C4.443 6.209 6.209 4.442 7.753 5.382C8.753 5.99 10.049 5.452 10.325 4.317Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> <path d="M9 12C9 12.7956 9.31607 13.5587 9.87868 14.1213C10.4413 14.6839 11.2044 15 12 15C12.7956 15 13.5587 14.6839 14.1213 14.1213C14.6839 13.5587 15 12.7956 15 12C15 11.2044 14.6839 10.4413 14.1213 9.87868C13.5587 9.31607 12.7956 9 12 9C11.2044 9 10.4413 9.31607 9.87868 9.87868C9.31607 10.4413 9 11.2044 9 12Z" stroke="currentColor" stroke-width="1.75" stroke-linecap="round" stroke-linejoin="round" /> </svg> <span>Settings</span> </button> </li> <li> <button id="add-page-link"> <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" > <path stroke="none" d="M0 0h24v24H0z" fill="none" /> <path d="M14 3v4a1 1 0 0 0 1 1h4" /> <path d="M17 21h-10a2 2 0 0 1 -2 -2v-14a2 2 0 0 1 2 -2h7l5 5v11a2 2 0 0 1 -2 2z" /> <path d="M12 11l0 6" /> <path d="M9 14l6 0" /> </svg> <span>Add Builder Page</span> </button> </li> <li> <button id="import-from-figma"> <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-figma" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" > <path stroke="none" d="M0 0h24v24H0z" fill="none" /> <path d="M15 12m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0" /> <path d="M6 3m0 3a3 3 0 0 1 3 -3h6a3 3 0 0 1 3 3v0a3 3 0 0 1 -3 3h-6a3 3 0 0 1 -3 -3z" /> <path d="M9 9a3 3 0 0 0 0 6h3m-3 0a3 3 0 1 0 3 3v-15" /> </svg> <span>Import From Figma</span> </button> </li> </ul> </div> <footer> <ul class="list"> <li> <a href="https://docs.google.com/forms/d/e/1FAIpQLSdqZcJpRtm_Ia5DTHP6SDY9Xa6LID3KiTjRWkjMzWyJRUtSHw/viewform" target="_blank" > <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" > <path d="M11.013 17.0114L10.013 18.0114L2.513 10.5834C2.0183 10.102 1.62864 9.52342 1.36854 8.88404C1.10845 8.24466 0.983558 7.55836 1.00173 6.86834C1.01991 6.17832 1.18076 5.49954 1.47415 4.87474C1.76755 4.24994 2.18713 3.69266 2.70648 3.23799C3.22583 2.78331 3.8337 2.4411 4.49181 2.23289C5.14991 2.02468 5.844 1.95499 6.53036 2.02821C7.21673 2.10143 7.8805 2.31596 8.47987 2.65831C9.07925 3.00066 9.60124 3.46341 10.013 4.01741C10.8086 2.95654 11.9931 2.2552 13.3059 2.06766C14.6186 1.88012 15.9521 2.22176 17.013 3.01741C18.0739 3.81306 18.7752 4.99755 18.9627 6.3103C19.1503 7.62305 18.8086 8.95654 18.013 10.0174" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" /> <path d="M18.2006 19.8175L16.0286 20.9555C15.9642 20.989 15.8917 21.004 15.8192 20.9987C15.7467 20.9934 15.6771 20.9681 15.6182 20.9256C15.5593 20.8831 15.5134 20.825 15.4855 20.7579C15.4577 20.6907 15.4491 20.6172 15.4606 20.5455L15.8756 18.1345L14.1186 16.4275C14.0662 16.3768 14.0291 16.3123 14.0115 16.2416C13.9939 16.1708 13.9966 16.0965 14.0192 16.0271C14.0418 15.9578 14.0835 15.8962 14.1394 15.8494C14.1954 15.8026 14.2634 15.7725 14.3356 15.7625L16.7636 15.4105L17.8496 13.2175C17.8821 13.1521 17.9322 13.0972 17.9942 13.0588C18.0562 13.0204 18.1277 13 18.2006 13C18.2736 13 18.3451 13.0204 18.4071 13.0588C18.4691 13.0972 18.5191 13.1521 18.5516 13.2175L19.6376 15.4105L22.0656 15.7625C22.1377 15.7728 22.2054 15.8031 22.2611 15.85C22.3168 15.8968 22.3583 15.9583 22.3809 16.0275C22.4034 16.0967 22.4062 16.1708 22.3888 16.2415C22.3715 16.3122 22.3347 16.3766 22.2826 16.4275L20.5256 18.1345L20.9396 20.5445C20.9521 20.6163 20.9441 20.6902 20.9166 20.7578C20.8891 20.8254 20.8433 20.8839 20.7842 20.9267C20.7252 20.9695 20.6553 20.9949 20.5825 21C20.5098 21.005 20.4371 20.9896 20.3726 20.9555L18.2006 19.8175Z" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" /> </svg> <span>Give Feedback</span> </a> </li> </ul> <div id="version"></div> </footer> </section> <section class="nav-cmp-list"> <header> <button class="back-button"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div class="search-container"> <div class="search-input-wrapper"> <svg class="search-icon" viewBox="0 0 24 24" width="16" height="16"> <path fill="none" stroke="currentColor" stroke-width="2" d="M15.5 15.5L20 20M10 17C6.13401 17 3 13.866 3 10C3 6.13401 6.13401 3 10 3C13.866 3 17 6.13401 17 10C17 13.866 13.866 17 10 17Z" /> </svg> <input type="text" id="component-search" class="component-search-input" placeholder="Search components..." autocomplete="off" spellcheck="false" /> <button id="clear-search" class="clear-search-button" type="button" aria-label="Clear search" > <svg viewBox="0 0 24 24" width="16" height="16"> <path fill="none" stroke="currentColor" stroke-width="2" d="M6 6l12 12M6 18L18 6" /> </svg> </button> </div> </div> <div> <h2>Custom Components</h2> <p> <button id="open-builder-registry"></button> </p> </div> </header> <div class="section-content"> <div id="cmp-list" class="cmp-list nav-list"></div> </div> <div class="nav-loading-icon spinner"></div> <footer> <p class="info"> Expand on Builder's selection of built-in blocks by <a target="_blank" href="https://www.builder.io/c/docs/custom-components-intro" >registering components</a > from your codebase. This way, teammates can drag and drop your components within Builder's Visual Editor just like any other block. </p> </footer> </section> <section class="nav-cmp-detail"> <header> <button class="back-button" data-back="nav-cmp-list"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div> <h2 id="cmp-detail-title"></h2> <p> <button id="cmp-open-source"></button> </p> </div> </header> <div class="section-content"> <div id="cmp-error"></div> <label class="ui-switch"> <div> <h3>Register Component</h3> <p> Registers this component so it can be used within Builder Visual CMS </p> </div> <input type="checkbox" role="switch" id="cmp-register" /> <span class="switcher"></span> </label> <div id="cmp-detail"> <label class="ui-text-input"> <h3>Component Name</h3> <div class="input"> <input type="text" id="cmp-name" autocapitalize="off" autocorrect="off" spellcheck="false" autocomplete="off" minlength="2" maxlength="30" required placeholder="e.g. My Counter" /> </div> <p> Unique name to identify this custom component within Builder. Press ESC to cancel </p> </label> <div class="cmp-detail-inputs-container"> <h3> <span>Builder Inputs (Props)</span> <button class="cmp-detail-inputs-reload" id="btn-inputs-reload"> Reload </button> </h3> <div id="cmp-detail-inputs"></div> </div> </div> </div> <div class="cmp-cover"></div> <div class="cmp-loading-icon spinner"></div> </section> <section class="nav-cmp-input"> <header> <button class="back-button" data-back="nav-cmp-detail"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div> <h2 id="cmp-input-title"></h2> <p> <button id="input-open-source"></button> </p> </div> </header> <div class="section-content"> <label class="ui-switch"> <div> <h3>Enable Input</h3> <p>Add this component prop as a Builder input</p> </div> <input type="checkbox" role="switch" id="input-register" /> <span class="switcher"></span> </label> <div class="cmp-prop-info"> <div class="cmp-input-readonly"> <h3>Prop Name</h3> <span id="cmp-prop-name"></span> </div> <div class="cmp-input-readonly"> <h3>Prop Type</h3> <span id="cmp-prop-type"></span> </div> </div> <div class="cmp-input-detail"> <label class="ui-text-input"> <h3>Builder Input Name</h3> <div class="input"> <input type="text" id="input-name" autocapitalize="off" autocorrect="off" spellcheck="false" autocomplete="off" minlength="1" maxlength="30" required placeholder="e.g. Text" /> </div> <p> Friendly name to identify this component prop as a Builder input. Press ESC to cancel </p> </label> <label class="ui-select"> <h3>Builder Input Type</h3> <div class="select"> <select id="input-type"></select> </div> <p> Correlate to what editing UI is appropriate for this Builder input. <a href="https://www.builder.io/c/docs/custom-components-input-types" target="_blank" >Read more about input types.</a > </p> </label> </div> <div class="input-cover"></div> <div class="input-loading-icon spinner"></div> </div> </section> <section class="nav-settings"> <header> <button class="back-button"> <svg viewBox="0 0 24 24"> <path d="M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" /> </svg> </button> <div> <h2>Settings</h2> <p>Configure Builder's Devtools</p> </div> </header> <div class="section-content"> <label class="ui-switch"> <div> <h3>Enable edit button in UI</h3> <p>Enables the edit button so you can edit content in Builder</p> </div> <input type="checkbox" role="switch" id="enable-edit" /> <span class="switcher"></span> </label> </div> </section> <div class="ui-toast" id="toast"></div> </aside> <button class="menu-toggle" aria-label="Toggle Builder Devtools"> <div> <div class="highlight-bg"></div> <svg viewBox="0 0 31 36" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M31 9.96854C31.0016 11.4553 30.6701 12.9236 30.03 14.2654C29.3898 15.6072 28.4572 16.7884 27.3007 17.7221L0.702841 2.61812C0.601104 2.56012 0.506714 2.49008 0.421705 2.40951C0.288323 2.27871 0.182333 2.12263 0.109928 1.95039C0.0375215 1.77814 0.000151253 1.59319 0 1.40633C0 1.03335 0.148098 0.675643 0.411715 0.411905C0.675332 0.148167 1.03287 0 1.40568 0L21.036 0C23.6786 0 26.213 1.05025 28.0816 2.91972C29.9502 4.78918 31 7.32472 31 9.96854Z" fill="#18B4F4" /> <path d="M31 25.4757C31.0004 26.7849 30.7429 28.0815 30.2423 29.2912C29.7417 30.5009 29.0078 31.6001 28.0825 32.526C27.1572 33.4519 26.0587 34.1864 24.8497 34.6875C23.6406 35.1886 22.3448 35.4465 21.0361 35.4465H1.40573C1.12766 35.4436 0.856725 35.3581 0.627199 35.201C0.397672 35.044 0.219871 34.8223 0.116289 34.5641C0.0127078 34.3059 -0.011999 34.0228 0.0452946 33.7505C0.102588 33.4783 0.239308 33.2292 0.438156 33.0347C0.517415 32.9551 0.606358 32.8858 0.702893 32.8284L11.1705 26.8843L27.2984 17.7244C28.4548 18.6579 29.3874 19.8387 30.028 21.18C30.6685 22.5213 31.0007 23.9891 31 25.4757Z" fill="#FD6B3C" /> <path d="M27.3011 17.7221L11.1709 26.8843L0.703209 32.8284C0.602697 32.8843 0.509784 32.9528 0.426758 33.0323C4.41799 28.9369 6.6496 23.442 6.64456 17.7221C6.65208 12.0015 4.42111 6.50517 0.429101 2.40948C0.51411 2.49005 0.6085 2.56009 0.710237 2.61809L27.3011 17.7221Z" fill="#A97FF2" /> </svg> </div> </button>\`,ai(e),ui(e),oi(e),ri(e),ti(e),ci(e),this.setAttribute("aria-hidden","true"),e.getElementById("version").textContent="v1.9.20"}highlightOpener(){let e=this.shadowRoot.querySelector(".menu-toggle");e.classList.add("menu-toggle-highlight"),e.classList.add("menu-toggle-highlight-no-transition"),setTimeout(()=>{e.classList.remove("menu-toggle-highlight-no-transition"),setTimeout(()=>{e.classList.remove("menu-toggle-highlight")},20)},20)}};var lo=\`<style>*,*:before,*:after{box-sizing:border-box}html,body,:host{position:fixed;top:0;left:0;width:100%;height:100vh;z-index:2147483646;margin:0;padding:0;line-height:1.8;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";background-color:#252525;color:#fff;transition:opacity .25s ease-in-out}:host([aria-hidden="true"]){opacity:0;pointer-events:none}main{position:absolute;top:0;left:0;width:100%;height:100vh}h1{margin-top:0;font-size:24px;font-weight:300;line-height:1.4}p{margin:20px 0;font-weight:300}button{cursor:pointer}aside{position:absolute;top:0;left:0;width:350px;height:100vh;padding:60px 0 0 50px;background-color:#121212}aside ul{margin:30px 0 0;padding:0;list-style:none}aside li{position:relative;margin:0;padding:20px 10px;font-weight:300}aside li.highlight{color:#48a1ff}aside li.active{font-weight:700}aside li .circle{position:absolute;top:20px;left:10px;width:24px;height:24px;border:3px solid white;border-radius:50%;font-size:14px}aside li.highlight .circle{border-color:#48a1ff}aside li.active .circle:after{content:"";position:absolute;top:3px;left:3px;width:12px;height:12px;border-radius:50%;background-color:#48a1ff}aside li.completed .circle{background-color:#48a1ff}aside li.completed .circle:after{content:"";position:absolute;top:2px;left:6px;width:6px;height:13px;border:3px solid black;border-top:none;border-left:none;transform:rotate(45deg)}aside li .line{position:absolute;top:44px;left:21px;width:3px;height:45px;background-color:#fff}aside li.completed .line{background-color:#48a1ff}aside li span{display:block;margin-left:44px}nav{margin-top:30px}section{position:absolute;top:135px;left:350px;padding:0 80px 0 140px;transition:opacity .15s ease-in-out}section[aria-hidden=true]{pointer-events:none;opacity:0}section h1,section p{min-width:300px;max-width:600px}.button{position:relative;display:inline-block;color:#fff;background-color:#48a1ff;border-radius:4px;text-decoration:none;padding:10px 40px 10px 20px;white-space:nowrap}.button:hover{background-color:#48a1ffd9}#button-icon{position:absolute;top:1px;right:5px;bottom:0;width:30px;background-image:url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path fill="none" stroke="white" stroke-linecap="square" stroke-miterlimit="10" stroke-width="48" d="M184 112l144 144-144 144"/></svg>');background-repeat:no-repeat;background-position:center;background-size:24px 24px}.button[aria-disabled=true]{opacity:.9;background-color:#ffffff4d;pointer-events:none;padding-right:60px}.button[aria-disabled=true] #button-icon{top:21px;right:29px;width:8px;height:8px;border-radius:4px;background:#fff;color:#fff;animation:dot-flashing .5s infinite linear alternate;animation-delay:.25s}.button[aria-disabled=true] #button-icon:before,.button[aria-disabled=true] #button-icon:after{content:"";display:inline-block;position:absolute;top:0}.button[aria-disabled=true] #button-icon:before{left:-12px;width:8px;height:8px;border-radius:4px;background-color:#fff;color:#fff;animation:dot-flashing .5s infinite alternate;animation-delay:0s}.button[aria-disabled=true] #button-icon:after{left:12px;width:8px;height:8px;border-radius:4px;background-color:#fff;color:#fff;animation:dot-flashing .5s infinite alternate;animation-delay:.5s}@keyframes dot-flashing{0%{background-color:#fff}50%,to{background-color:#ffffff4d}}.logo{margin-left:9px;background:url('data:image/svg+xml,<svg viewBox="0 0 150 32" fill="none" xmlns="http://www.w3.org/2000/svg" > <g clip-path="url(%23clip0_4_304)"> <path d="M27.9858 8.99927C27.9872 10.3415 27.688 11.667 27.1101 12.8783C26.5321 14.0896 25.6902 15.156 24.6462 15.9989V15.9989L0.634502 2.36355C0.542657 2.31119 0.457444 2.24796 0.380701 2.17523C0.260289 2.05715 0.164605 1.91624 0.0992389 1.76075C0.0338732 1.60525 0.000136546 1.43828 0 1.26959C0 0.932873 0.133698 0.609948 0.371683 0.371854C0.609667 0.13376 0.932443 0 1.269 0L18.9906 0C21.3763 0 23.6642 0.948135 25.3512 2.63583C27.0381 4.32352 27.9858 6.61252 27.9858 8.99927V8.99927Z" fill="%2318B4F4" /> <path d="M27.9858 22.9986C27.9861 24.1806 27.7536 25.351 27.3017 26.4431C26.8498 27.5352 26.1873 28.5275 25.352 29.3634C24.5167 30.1993 23.5249 30.8624 22.4335 31.3147C21.342 31.7671 20.1721 32 18.9907 32H1.26906C1.01802 31.9973 0.77343 31.9202 0.566221 31.7784C0.359012 31.6366 0.198499 31.4364 0.104989 31.2034C0.0114791 30.9703 -0.0108254 30.7147 0.0408974 30.4689C0.0926201 30.2231 0.216046 29.9982 0.395559 29.8226V29.8226C0.467112 29.7508 0.547407 29.6882 0.634555 29.6364L10.0844 24.2703L24.6441 16.001C25.688 16.8438 26.53 17.9097 27.1083 19.1206C27.6866 20.3315 27.9864 21.6566 27.9858 22.9986V22.9986Z" fill="%23FD6B3C" /> <path d="M24.6461 15.9989L10.0843 24.2703L0.634458 29.6365C0.54372 29.6868 0.459841 29.7487 0.384888 29.8205C3.98804 26.1233 6.00266 21.1627 5.99812 15.9989C6.0049 10.8346 3.99085 5.87268 0.387003 2.17523C0.463746 2.24796 0.548959 2.31119 0.640803 2.36355L24.6461 15.9989Z" fill="%23A97FF2" /> <path d="M47.6659 11.7352C51.8177 11.7352 54.1632 15.0531 54.1632 19.0714C54.1632 23.0896 51.8177 26.3821 47.6659 26.3821C45.5086 26.3821 43.8589 25.5188 42.9473 24.0545L42.5709 26.052H39.9736V6.77115H43.1884V13.8914C43.971 12.6959 45.5086 11.7352 47.6659 11.7352ZM47.0187 23.5488C49.4446 23.5488 50.9547 21.5809 50.9547 19.0714C50.9547 16.5089 49.4446 14.5664 47.0187 14.5664C44.5928 14.5664 43.0806 16.5047 43.0806 19.0714C43.0806 21.583 44.5653 23.5488 47.0187 23.5488V23.5488Z" fill="white" /> <path d="M65.4595 20.2859V12.0611H68.668V20.123C68.668 23.7202 67.0246 26.3821 62.4943 26.3821C57.9639 26.3821 56.3206 23.7117 56.3206 20.123V12.0611H59.529V20.2859C59.529 22.4696 60.5527 23.5488 62.49 23.5488C64.4274 23.5488 65.4595 22.4696 65.4595 20.2859Z" fill="white" /> <path d="M71.2355 7.74451C71.2247 7.46284 71.2724 7.18199 71.3755 6.91968C71.4787 6.65737 71.6351 6.41929 71.8348 6.22047C72.0345 6.02165 72.2732 5.8664 72.5359 5.76452C72.7986 5.66264 73.0796 5.61633 73.3611 5.62853C74.5793 5.62853 75.4571 6.50666 75.4571 7.75509C75.4571 9.00352 74.5793 9.8224 73.3611 9.8224C72.1428 9.8224 71.2355 8.9612 71.2355 7.74451Z" fill="white" /> <path d="M128.476 7.74451C128.465 7.46376 128.513 7.18383 128.615 6.92227C128.718 6.66071 128.873 6.42315 129.072 6.22449C129.27 6.02583 129.508 5.87035 129.769 5.7678C130.031 5.66524 130.31 5.61783 130.591 5.62852C131.809 5.62852 132.687 6.50666 132.687 7.75509C132.687 9.00352 131.809 9.8224 130.591 9.8224C129.373 9.8224 128.476 8.9612 128.476 7.74451Z" fill="white" /> <path d="M122.302 24.1031C122.291 23.8223 122.339 23.5422 122.441 23.2805C122.543 23.0188 122.699 22.7811 122.897 22.5824C123.096 22.3837 123.334 22.2282 123.595 22.1258C123.857 22.0233 124.137 21.9761 124.417 21.9872C125.636 21.9872 126.513 22.8653 126.513 24.1031C126.513 25.341 125.636 26.1726 124.417 26.1726C123.199 26.1726 122.302 25.3219 122.302 24.1031Z" fill="white" /> <path d="M74.9516 12.059H71.7432V26.0583H74.9516V12.059Z" fill="white" /> <path d="M78.16 26.0583V6.77115H81.3685V26.0626L78.16 26.0583Z" fill="white" /> <path d="M94.6063 6.77115H97.8148V26.0626H95.2239L94.8474 24.0651C93.9591 25.523 92.3094 26.3927 90.131 26.3927C86.0046 26.3927 83.6591 23.0748 83.6591 19.0819C83.6591 15.0891 86.0046 11.7458 90.131 11.7458C92.3137 11.7458 93.8238 12.7149 94.6063 13.902V6.77115ZM90.7993 14.5707C88.3734 14.5707 86.8633 16.5131 86.8633 19.0756C86.8633 21.5851 88.3734 23.553 90.7993 23.553C93.2252 23.553 94.7354 21.5851 94.7354 19.0756C94.7396 16.5047 93.257 14.5664 90.8036 14.5664L90.7993 14.5707Z" fill="white" /> <path d="M113.479 22.2284C112.482 24.7359 110.162 26.3821 107.117 26.3821C102.887 26.3821 100.137 23.225 100.137 19.0439C100.137 14.9706 102.942 11.7353 107.093 11.7353C111.245 11.7353 113.969 14.8902 113.969 18.991C113.982 19.3255 113.953 19.6604 113.883 19.9876H103.288C103.53 22.2009 104.959 23.6292 107.197 23.6292C108.735 23.6292 110.001 22.8738 110.594 21.473L113.479 22.2284ZM103.341 17.6156H110.784C110.513 15.6731 109.166 14.3506 107.089 14.3506C105.012 14.3506 103.665 15.7006 103.341 17.6156V17.6156Z" fill="white" /> <path d="M123.779 14.9452C123.538 14.9117 123.295 14.8933 123.051 14.8902C120.786 14.8902 119.439 16.0772 119.439 18.7751V26.0583H116.23V12.0611H118.821L119.195 14.0014C119.707 13.1127 120.887 11.9257 123.322 11.9257C123.455 11.9257 123.779 11.9532 123.779 11.9532V14.9452Z" fill="white" /> <path d="M132.192 12.059H128.984V26.0583H132.192V12.059Z" fill="white" /> <path d="M134.483 19.0714C134.483 15.1335 137.287 11.7353 141.735 11.7353C146.183 11.7353 149.015 15.1335 149.015 19.0714C149.015 23.0092 146.213 26.3821 141.735 26.3821C137.258 26.3821 134.483 23.0092 134.483 19.0714ZM141.735 23.5488C144.083 23.5488 145.806 21.7692 145.806 19.0714C145.806 16.3735 144.083 14.5664 141.735 14.5664C139.387 14.5664 137.687 16.346 137.687 19.0714C137.687 21.7968 139.417 23.5488 141.735 23.5488V23.5488Z" fill="white" /> </g> <defs> <clipPath id="clip0_4_304"> <rect width="149.015" height="32" fill="white" /> </clipPath> </defs> </svg>');background-repeat:no-repeat;width:150px;height:32px}@media (max-width: 840px){aside{width:250px;padding:60px 0 0 20px}section{left:250px;padding:0 80px}}@media (max-width: 590px){aside{width:230px;padding:60px 0 0 10px}section{left:230px;padding:0 40px}}#modified-files-message a{color:#cbcbcb;font-weight:300;text-decoration:underline}#modified-files-message a:hover{color:#fff;text-decoration:none}#restart-warning{border-radius:4px;padding:8px 16px;border:1px solid #fd6b3c;background:#fd6b3c1a}#react-router-steps{margin:0 0 5px;padding:0 20px}#need-help{color:#48a1ff;text-decoration:none}#router-message{border-radius:4px;padding:16px;border:1px solid #48a1ff}#router-finish-button{margin-top:12px}#router-checkbox-div{display:flex;align-items:center}#router-checkbox{margin-right:10px;width:15px;height:15px}#success-title{display:flex;align-items:center;gap:10px}#success-title .check-icon{display:inline-block;width:24px;height:24px;border:2px solid #28a745;border-radius:50%;position:relative}#success-title .check-icon:before{content:"";position:absolute;top:50%;left:50%;width:6px;height:12px;border:solid #28a745;border-width:0 2px 2px 0;transform:translate(-50%,-60%) rotate(45deg)}
1319
1319
  </style>\`,Dt=class extends HTMLElement{constructor(){super()}connectedCallback(){let e=this.attachShadow({mode:"open"});e.innerHTML=lo+\`<main>
1320
1320
  <aside>
1321
1321
  <div class="logo"></div>
@@ -1354,7 +1354,7 @@ Restarting server after Builder Devtools update...
1354
1354
  </nav>
1355
1355
  </section>
1356
1356
  </main>
1357
- \`,po();let r=new URL(Vr,ot);r.searchParams.set(Mr,location.href);let n=e.querySelectorAll(".next-step");for(let i of n)i.setAttribute("href",r.href);ye("overview step viewed")}},po=()=>{let t=document.head.querySelector("link[rel='icon'], link[rel='icon shortcut']");t?(t.href="https://cdn.builder.io/favicon.ico",t.removeAttribute("type")):(t=document.createElement("link"),t.rel="icon",t.href="https://cdn.builder.io/favicon.ico",document.head.appendChild(t))};var li=async()=>{(await qr()).isValid||fo()},fo=()=>{customElements.get("builder-dev-tools-overview")||customElements.define("builder-dev-tools-overview",Dt);let t=document.querySelector("builder-dev-tools-overview");t||(t=document.createElement("builder-dev-tools-overview"),t.setAttribute("aria-hidden","true"),document.body.appendChild(t)),setTimeout(()=>{t.removeAttribute("aria-hidden")},32)};var mo=()=>{try{customElements.get("builder-dev-tools-edit")||customElements.define("builder-dev-tools-edit",st),customElements.get("builder-dev-tools-menu")||customElements.define("builder-dev-tools-menu",At);let t=document.querySelector("builder-dev-tools-menu");t||(t=document.createElement("builder-dev-tools-menu"),t.setAttribute("data-version","1.9.19"),document.body.appendChild(t));let e=document.querySelector("builder-dev-tools-edit");e||(e=document.createElement("builder-dev-tools-edit"),document.body.appendChild(e));let r=document.getElementById("builder-dev-tools-style");r||(r=document.createElement("style"),r.id="builder-dev-tools-style",r.innerHTML=".builder-no-scroll{overflow:hidden !important}",document.head.appendChild(r)),li(),Jn()}catch(t){console.error("Builder Devtools:",t)}};window.location===window.parent.location&&(console.debug("Builder.io Devtools v1.9.19"),mo());})();`)}async function pR(e){return dR(e,`<!doctype html>
1357
+ \`,po();let r=new URL(Vr,ot);r.searchParams.set(Mr,location.href);let n=e.querySelectorAll(".next-step");for(let i of n)i.setAttribute("href",r.href);ye("overview step viewed")}},po=()=>{let t=document.head.querySelector("link[rel='icon'], link[rel='icon shortcut']");t?(t.href="https://cdn.builder.io/favicon.ico",t.removeAttribute("type")):(t=document.createElement("link"),t.rel="icon",t.href="https://cdn.builder.io/favicon.ico",document.head.appendChild(t))};var li=async()=>{(await qr()).isValid||fo()},fo=()=>{customElements.get("builder-dev-tools-overview")||customElements.define("builder-dev-tools-overview",Dt);let t=document.querySelector("builder-dev-tools-overview");t||(t=document.createElement("builder-dev-tools-overview"),t.setAttribute("aria-hidden","true"),document.body.appendChild(t)),setTimeout(()=>{t.removeAttribute("aria-hidden")},32)};var mo=()=>{try{customElements.get("builder-dev-tools-edit")||customElements.define("builder-dev-tools-edit",st),customElements.get("builder-dev-tools-menu")||customElements.define("builder-dev-tools-menu",At);let t=document.querySelector("builder-dev-tools-menu");t||(t=document.createElement("builder-dev-tools-menu"),t.setAttribute("data-version","1.9.20"),document.body.appendChild(t));let e=document.querySelector("builder-dev-tools-edit");e||(e=document.createElement("builder-dev-tools-edit"),document.body.appendChild(e));let r=document.getElementById("builder-dev-tools-style");r||(r=document.createElement("style"),r.id="builder-dev-tools-style",r.innerHTML=".builder-no-scroll{overflow:hidden !important}",document.head.appendChild(r)),li(),Jn()}catch(t){console.error("Builder Devtools:",t)}};window.location===window.parent.location&&(console.debug("Builder.io Devtools v1.9.20"),mo());})();`)}async function pR(e){return dR(e,`<!doctype html>
1358
1358
  <html lang="en" dir="ltr">
1359
1359
  <head>
1360
1360
  <meta charset="utf-8" />
@@ -1520,20 +1520,20 @@ Restarting server after Builder Devtools update...
1520
1520
  </script>
1521
1521
  </body>
1522
1522
  </html>
1523
- `)}async function dR(e,t){let r=await QS(e),n=e.getFrameworks();return t.replace(/__LOCAL_APP_ID__/g,r).replace(/__DEV_TOOLS_URL__/g,e.devToolsServerUrl).replace(/__CLIENT_ID__/g,e.getClientId()).replace(/__FRAMEWORK__/g,n.length?n[0].name:"")}f();var fR=require("os");async function mR(e,t){let r=new URL("/cli-auth","https://builder.io");r.searchParams.set("client_id",e.getClientId()),r.searchParams.set("host",await e.getDeviceId()),r.searchParams.set("response_type","code"),r.searchParams.set("cli","true");let n=new URL(ho,e.devToolsServerUrl);n.searchParams.set(od,(0,fR.platform)()),n.searchParams.set(ad,process.versions.node);let i=e.getFrameworks();return i.length>0&&(r.searchParams.set(ba,i[0].name),n.searchParams.set(ba,i[0].name)),r.searchParams.set("redirect_url",n.href),r.searchParams.set("preview_url",t),r.href}async function gR(e,t,r,n){try{if(!e)return bc(r,n,400,"Builder context closed");let i=vte(r);if(i.pathname===jg){if(r.method==="POST"){let s=await xte(r);if(s)try{let o=await uR(e,JSON.parse(s));return hR(r,n,200,o)}catch(o){e.debug("Dev API Error",o.stack||o.message||o);let a={errors:[String(o.message||o)]};return hR(r,n,500,a)}}else if(r.method==="OPTIONS"){let s={"Access-Control-Allow-Methods":"POST, OPTIONS","Access-Control-Allow-Headers":"Content-Type, Cache-Control, X-Builder-Devtools-Version, sentry-trace, baggage"},o=r.headers.origin;o&&o!=="null"?yR(new URL(o))&&(s["Access-Control-Allow-Origin"]=o):s["Access-Control-Allow-Origin"]="*",n.writeHead(200,s),n.end();return}return bc(r,n,405,`${jg} is an API endpoint used only during development by the Builder.io Devtools client-side script`)}if(i.pathname===qg)return gte(r,n,200,await lR(e));if(i.pathname===yS){let s=i.searchParams.get(Ug);return s?bte(n,302,await mR(e,s)):bc(r,n,400,`Missing ${Ug} querystring`)}if(i.pathname===ho)return yte(r,n,200,await pR(e));if(i.pathname===bS){await yt(e,{_:[]},{});let s=await qo(e),{figmaBuilderLinks:o,diagnostics:a}=await Fl({mappingFiles:s,sys:e});return Pl(r,n,200,"application/json",JSON.stringify({figmaBuilderLinks:o,foundErrors:a.length>0,diagnostics:a,version:2,local:!0},null,2))}return i.pathname===go?(e.debug(`Close Dev Tools Server Requested: ${i.href}`),setTimeout(()=>{try{t.close(s=>{e.debug(`Dev Tools Server Closed Error: ${s}`)})}catch(s){e.debug(`Error closing devtools server: ${s}`)}},20),bc(r,n,200,"Closing Dev Tools Server")):bc(r,n,404,"Not found")}catch(i){return e?.Sentry?.captureException(i),bc(r,n,500,`Dev Server Error: ${i}`)}}function hR(e,t,r,n){Pl(e,t,r,"application/json",JSON.stringify(n))}function gte(e,t,r,n){Pl(e,t,r,"application/javascript",n)}function yte(e,t,r,n){Pl(e,t,r,"text/html",n)}function bc(e,t,r,n){Pl(e,t,r,"text/plain",n)}function Pl(e,t,r,n,i){let s={"Content-Type":`${n}; charset=utf-8`,"Cache-Control":"no-cache, no-store, must-revalidate","X-Builder-Devtools-Version":Te},o=e.headers.origin;o&&o!=="null"?yR(new URL(o))&&(s["Access-Control-Allow-Origin"]=o):s["Access-Control-Allow-Origin"]="*",t.writeHead(r,s),t.end(i)}function yR(e){return e.hostname==="localhost"||e.origin==="https://builder.io"||e.origin==="https://www.builder.io"||e.origin.endsWith(".builder.io")?!0:e.port===""?!1:e.port!=="80"&&e.port!=="443"}function bte(e,t,r){e.writeHead(t,{Location:r}),e.end()}async function xte(e){let t="";for await(let r of e)t+=r;return t}function vte(e){let t=e.url||"/";return new URL(t,`http://${e.headers.host}`)}async function bR(e){if(globalThis.__builderDevToolsServer)return e.debug("reusing existing devtools server"),globalThis.__builderDevToolsServer.setContext(e),globalThis.__builderDevToolsServer;let t=await Dte(e),r=(0,Dm.createServer)((i,s)=>{gR(e,r,i,s)}),n=()=>new Promise((i,s)=>{r.listening?(e.debug(`closing devtools server on port ${t}`),r.close(o=>{e=null,o?(e.debug(`error closing devtools server on port ${t}`),s(o)):(e&&e.debug(`closed devtools server on port ${t}`),i())})):(e.debug(`devtools server on port ${t} not listening`),i())});return process.once("SIGTERM",n),process.once("SIGINT",n),process.env.CI!=="true"&&process.stdin.on("end",n),globalThis.__builderDevToolsServer={url:new URL(`http://localhost:${t}`).href,port:t,setContext:i=>{e.debug(`set devtools context on server ${t}`),e=i},close:async()=>{globalThis.__builderDevToolsServer=null,await n()}},new Promise(i=>{r.listen(t,()=>{e.debug(`started devtools server on port ${t}`),i(globalThis.__builderDevToolsServer)})})}function Dte(e){return new Promise(t=>{let r=e.port;try{(0,Dm.request)({hostname:"localhost",port:r,path:go,method:"GET"},i=>{i.on("end",()=>{e.debug(`${go} - Response ended`),t(r)})}).on("error",i=>{e.debug(`${go} - No response ${i}`),t(r)}).end()}catch(n){e.debug(`${go} - Error ${n}`),t(r)}})}async function $D(e){let t={...e,devToolsServerUrl:"",isValid:!1,serverShouldRestart:!1,publicApiKey:"",port:e.port||5273,ignoreMissingConfig:!1,getAllProjectFiles:e.getAllProjectFiles||(()=>Promise.resolve([]))},r=e.getFrameworks().map(s=>s.name).join(", ");t.debug(`create devtools ${xR} [${r}]`);let n=await bR(t);return t.devToolsServerUrl=n.url,t.port=n.port,{getUrl:()=>t.devToolsServerUrl}}var xR=Te;f();var ei=require("path"),cr=require("fs");var Hs=q(vt(),1);async function vR(e){if(console.log(""),ze((0,Hs.bgCyan)((0,Hs.bold)((0,Hs.white)(" add ")))+" "+(0,Hs.dim)(Te)),!e.path&&!process.stdout.isTTY&&process.env.FORCE_TTY!=="1")return De(`This command requires a TTY-enabled terminal.
1523
+ `)}async function dR(e,t){let r=await QS(e),n=e.getFrameworks();return t.replace(/__LOCAL_APP_ID__/g,r).replace(/__DEV_TOOLS_URL__/g,e.devToolsServerUrl).replace(/__CLIENT_ID__/g,e.getClientId()).replace(/__FRAMEWORK__/g,n.length?n[0].name:"")}f();var fR=require("os");async function mR(e,t){let r=new URL("/cli-auth","https://builder.io");r.searchParams.set("client_id",e.getClientId()),r.searchParams.set("host",await e.getDeviceId()),r.searchParams.set("response_type","code"),r.searchParams.set("cli","true");let n=new URL(ho,e.devToolsServerUrl);n.searchParams.set(od,(0,fR.platform)()),n.searchParams.set(ad,process.versions.node);let i=e.getFrameworks();return i.length>0&&(r.searchParams.set(ba,i[0].name),n.searchParams.set(ba,i[0].name)),r.searchParams.set("redirect_url",n.href),r.searchParams.set("preview_url",t),r.href}async function gR(e,t,r,n){try{if(!e)return bc(r,n,400,"Builder context closed");let i=vte(r);if(i.pathname===jg){if(r.method==="POST"){let s=await xte(r);if(s)try{let o=await uR(e,JSON.parse(s));return hR(r,n,200,o)}catch(o){e.debug("Dev API Error",o.stack||o.message||o);let a={errors:[String(o.message||o)]};return hR(r,n,500,a)}}else if(r.method==="OPTIONS"){let s={"Access-Control-Allow-Methods":"POST, OPTIONS","Access-Control-Allow-Headers":"Content-Type, Cache-Control, X-Builder-Devtools-Version, sentry-trace, baggage"},o=r.headers.origin;o&&o!=="null"?yR(new URL(o))&&(s["Access-Control-Allow-Origin"]=o):s["Access-Control-Allow-Origin"]="*",n.writeHead(200,s),n.end();return}return bc(r,n,405,`${jg} is an API endpoint used only during development by the Builder.io Devtools client-side script`)}if(i.pathname===qg)return gte(r,n,200,await lR(e));if(i.pathname===yS){let s=i.searchParams.get(Ug);return s?bte(n,302,await mR(e,s)):bc(r,n,400,`Missing ${Ug} querystring`)}if(i.pathname===ho)return yte(r,n,200,await pR(e));if(i.pathname===bS){await yt(e,{_:[]},{});let s=await qo(e),{figmaBuilderLinks:o,diagnostics:a}=await Fl({mappingFiles:s,sys:e});return Pl(r,n,200,"application/json",JSON.stringify({figmaBuilderLinks:o,foundErrors:a.length>0,diagnostics:a,version:2,local:!0},null,2))}return i.pathname===go?(e.debug(`Close Dev Tools Server Requested: ${i.href}`),setTimeout(()=>{try{t.close(s=>{e.debug(`Dev Tools Server Closed Error: ${s}`)})}catch(s){e.debug(`Error closing devtools server: ${s}`)}},20),bc(r,n,200,"Closing Dev Tools Server")):bc(r,n,404,"Not found")}catch(i){return e?.Sentry?.captureException(i),bc(r,n,500,`Dev Server Error: ${i}`)}}function hR(e,t,r,n){Pl(e,t,r,"application/json",JSON.stringify(n))}function gte(e,t,r,n){Pl(e,t,r,"application/javascript",n)}function yte(e,t,r,n){Pl(e,t,r,"text/html",n)}function bc(e,t,r,n){Pl(e,t,r,"text/plain",n)}function Pl(e,t,r,n,i){let s={"Content-Type":`${n}; charset=utf-8`,"Cache-Control":"no-cache, no-store, must-revalidate","X-Builder-Devtools-Version":Ce},o=e.headers.origin;o&&o!=="null"?yR(new URL(o))&&(s["Access-Control-Allow-Origin"]=o):s["Access-Control-Allow-Origin"]="*",t.writeHead(r,s),t.end(i)}function yR(e){return e.hostname==="localhost"||e.origin==="https://builder.io"||e.origin==="https://www.builder.io"||e.origin.endsWith(".builder.io")?!0:e.port===""?!1:e.port!=="80"&&e.port!=="443"}function bte(e,t,r){e.writeHead(t,{Location:r}),e.end()}async function xte(e){let t="";for await(let r of e)t+=r;return t}function vte(e){let t=e.url||"/";return new URL(t,`http://${e.headers.host}`)}async function bR(e){if(globalThis.__builderDevToolsServer)return e.debug("reusing existing devtools server"),globalThis.__builderDevToolsServer.setContext(e),globalThis.__builderDevToolsServer;let t=await Dte(e),r=(0,Dm.createServer)((i,s)=>{gR(e,r,i,s)}),n=()=>new Promise((i,s)=>{r.listening?(e.debug(`closing devtools server on port ${t}`),r.close(o=>{e=null,o?(e.debug(`error closing devtools server on port ${t}`),s(o)):(e&&e.debug(`closed devtools server on port ${t}`),i())})):(e.debug(`devtools server on port ${t} not listening`),i())});return process.once("SIGTERM",n),process.once("SIGINT",n),process.env.CI!=="true"&&process.stdin.on("end",n),globalThis.__builderDevToolsServer={url:new URL(`http://localhost:${t}`).href,port:t,setContext:i=>{e.debug(`set devtools context on server ${t}`),e=i},close:async()=>{globalThis.__builderDevToolsServer=null,await n()}},new Promise(i=>{r.listen(t,()=>{e.debug(`started devtools server on port ${t}`),i(globalThis.__builderDevToolsServer)})})}function Dte(e){return new Promise(t=>{let r=e.port;try{(0,Dm.request)({hostname:"localhost",port:r,path:go,method:"GET"},i=>{i.on("end",()=>{e.debug(`${go} - Response ended`),t(r)})}).on("error",i=>{e.debug(`${go} - No response ${i}`),t(r)}).end()}catch(n){e.debug(`${go} - Error ${n}`),t(r)}})}async function $D(e){let t={...e,devToolsServerUrl:"",isValid:!1,serverShouldRestart:!1,publicApiKey:"",port:e.port||5273,ignoreMissingConfig:!1,getAllProjectFiles:e.getAllProjectFiles||(()=>Promise.resolve([]))},r=e.getFrameworks().map(s=>s.name).join(", ");t.debug(`create devtools ${xR} [${r}]`);let n=await bR(t);return t.devToolsServerUrl=n.url,t.port=n.port,{getUrl:()=>t.devToolsServerUrl}}var xR=Ce;f();var ei=require("path"),cr=require("fs");var Hs=q(vt(),1);async function vR(e){if(console.log(""),ze((0,Hs.bgCyan)((0,Hs.bold)((0,Hs.white)(" add ")))+" "+(0,Hs.dim)(Ce)),!e.path&&!process.stdout.isTTY&&process.env.FORCE_TTY!=="1")return De(`This command requires a TTY-enabled terminal.
1524
1524
  If you are using Windows Git Bash, try a different terminal or wrap the command with winpty.`),await te(1);let t=e.snippetId;if(!t&&!e.snippet)return De("SnippetId expected. npx builder.io add <snippetId>"),await te(1);let r=Ss(),n=e.snippet||null;if(!n&&t&&(r.start(`Fetching snippet ${t}`),n=await UD(t),r.stop(`Fetched snippet ${t}`)),!n)return De(`No snippet found for id ${t}`),await te(1);let i=process.cwd(),s=bl(i)??i;if(n.files?.length>0){let o=jD(s,n.framework||"react"),a=e.path||await nt({message:"Where should we copy the files?",initialValue:o,validate(u){if(u.length===0)return"File path is required!";if(u[0]!==".")return"Please enter a relative path."}});if(ve(a))return De("Cancelled sync"),await te(0);let c=await Cm(s,n,n.files,a,!1);return B.success("All files have been written successfully."),{snippet:n,pathInput:a,writtenFiles:c,timeStamp:Date.now()}}else{let{code:o,suggestedName:a,framework:c}=n;c&&(a=await Ete(s,c,o)),a??="./src/components/MyComponent.jsx";let u=DR(n,Cte(n.code),n.framework);try{n.framework==="html"?u=await Zr(s,u,"html",void 0):n.framework==="angular"?u=await Zr(s,u,"angular",void 0):n.framework==="vue"?u=await Zr(s,u,"vue",void 0):n.framework==="svelte"?u=await Zr(s,u,"svelte",void 0):u=await Zr(s,u,"typescript",void 0)}catch{}let l=e.path;if(!l){try{let h=(await i2({cwd:process.cwd()})).getFrameworks();if(h.length>0){let m;if(h.some(g=>g.name.includes("qwik"))?m="qwik":h.some(g=>g.name.includes("react"))?m="react":m=h[0].name,n.framework&&n.framework!==m){let g=await ir({message:`This snippet is for ${n.framework}, but you are using ${m}. Continue?`,initialValue:!1});if(ve(g)||!g)return console.log("Please go back to builder and change the output framework to match your project."),console.log(),await te(0)}}}catch{}if(l=await nt({message:"Where should we copy the code?",initialValue:a?.startsWith("./")?a:`./${a}`,validate(d){if(d.length===0)return"File path is required!";if(d[0]!==".")return"Please enter a relative path."}}),ve(l))return console.log(""),await te(0)}let p=(0,ei.resolve)(s,l);B.info(`Writing code to ${p}`),(0,cr.mkdirSync)((0,ei.dirname)(p),{recursive:!0}),(0,cr.writeFileSync)(p,u)}}function UD(e){return he(`https://cdn.builder.io/api/v1/snippet/${e}`).then(t=>t.status===404?null:t.json())}function Cte(e){return e.replace(/^```jsx\s?|\s?```$/g,"").trim()}function DR(e,t,r,n=!1){if(!r)return t;let i="This code was generated by Builder.io",s=n?`https://builder.io/content/${e.contentId}?codeSession=${e.sessionKey}&sid=${e.id}`:"",o=["vue","html","svelte"].includes(r.toLowerCase()),a=[i,s].filter(Boolean);return`${o?a.map(u=>`<!-- ${u} -->`).join(`
1525
1525
  `):`/**
1526
1526
  ${a.map(u=>` * ${u}`).join(`
1527
1527
  `)}
1528
1528
  */`}
1529
- ${t}`}async function Ete(e,t,r){let n,i=Ste(r,t.toLowerCase());switch(t.toLowerCase()){case"react":let s=await wte(e);n=`components/${i||"MyComponent"}.${s?"tsx":"jsx"}`;break;case"angular":n=`app/components/${i||"my-component"}.component.ts`;break;case"vue":n=`components/${i||"MyComponent"}.vue`;break;case"svelte":n=`components/${i||"MyComponent"}.svelte`;break;case"html":n=`${i||"my-design"}.html`;break;case"qwik":n=`components/${i||"MyComponent"}.tsx`;break;default:n=`components/${i||"MyComponent"}.tsx`}return n=(0,cr.existsSync)("./src")?`./src/${n}`:`./${n}`,n}async function wte(e){if((0,cr.existsSync)((0,ei.join)(e,"./tsconfig.json")))return!0;let t=kx(e);return t&&(0,cr.existsSync)((0,ei.join)(t,"./package.json"))?(0,cr.readFileSync)((0,ei.join)(t,"./package.json"),"utf-8").includes("typescript"):!1}function Ste(e,t){let r={vue:/name:\s*'([^']+)'/,react:/function (\w+)\([\w\W]+\)/,qwik:/export const (\w+) = component\$/,angular:/selector:\s*'([^']+)'/};if(!r[t])return null;let n=e.match(r[t]);return t==="react"&&!n?.[1]?e.match(/const (\w+)[\w\W]+=\s*\(/)?.[1]||null:n?.[1]||null}async function Cm(e,t,r,n,i){let s=[];for(let o of r){let a=Tte(n,o.path),c=(0,ei.resolve)(e,a);if("code"in o){let u=await Pte(e,t,o.code,Ate(o.path),i);(0,cr.existsSync)(c)||(0,cr.mkdirSync)((0,ei.dirname)(c),{recursive:!0}),(0,cr.writeFileSync)(c,u),s.push({...o,path:a,code:u,timestamp:(0,cr.statSync)(c).mtime.getTime()}),B.info(`Writing file to ${c}`)}else(0,cr.mkdirSync)(c,{recursive:!0}),s=s.concat(await Cm(e,t,o.files,a,i))}return s}function Tte(e,t){let r=e.replace(/^\.?\/+|\/+$/g,""),n=t.replace(/^\.?\/+|\/+$/g,""),i=r.split("/").filter(Boolean),s=n.split("/").filter(Boolean),o=-1;for(let c=0;c<i.length;c++){let u=s.indexOf(i[c]);u!==-1&&(o=u)}return[...i,...s.slice(o+1)].join("/")}function Ate(e){switch(e.split(".").pop()?.toLowerCase()){case"html":case"svelte":return"html";case"vue":return"vue";case"ts":case"tsx":case"js":case"jsx":return"typescript";case"css":return"css";case"json":return"json";default:return"typescript"}}async function Pte(e,t,r,n,i){let s=r;try{s=await Zr(e,r,n,void 0)}catch{}return i?DR(t,s,n,i):s}function jD(e,t){let n=(0,cr.existsSync)((0,ei.join)(e,"src"))?"src/":"";switch(t.toLowerCase()){case"angular":return`./${n}app/components/`;case"html":return"./";default:return`./${n}components/`}}var wR=q(require("chokidar"),1),SR=q(require("ignore"),1);function TR(e){let t=e.match(/builder\.io\/content\/([^?]+)\?codeSession=([^&]+)&sid=([^\s]+)/);return t?{contentId:t[1],sessionKey:t[2],snippetId:t[3]}:{}}async function xc(e,t="**/*",r,n=!1){return await MD(t,{cwd:e,ignoreFiles:qD,ignore:[...GD,...r||[]],absolute:!1,dot:n})}async function Fte(e,t,r){let n=await MD("**/*",{cwd:e,ignoreFiles:qD,ignore:GD}),i=[];for(let s of n){let o=(0,Kr.resolve)(e,s);try{let a=(0,Vr.readFileSync)(o,"utf-8");if(a.includes("This code was generated by Builder.io")){let c=TR(a);if(t&&r&&(c.contentId!==t||c.sessionKey!==r))continue;i.push({path:s,code:Em(a),name:s.split("/").pop()||"",timestamp:(0,Vr.statSync)(o).mtime.getTime(),snippetId:c.snippetId})}}catch(a){console.error(`Error reading file ${o}:`,a)}}return i}function _te(e,t){let r=TR(e);return r.contentId===t.contentId&&r.sessionKey===t.sessionKey}function AR(e){return e.filter(t=>(t=t.toLowerCase(),!t.endsWith(".png")&&!t.endsWith(".jpg")&&!t.endsWith(".jpeg")&&!t.endsWith(".gif")&&!t.endsWith(".ico")&&!t.endsWith(".webp")&&!t.includes(".mapper.")))}var qD=[".gitignore",".prettierignore",".builderignore"],GD=["**/*.yml","**/*.yaml","**/*.snap","**/*.liquid","**/.git","**/.env","**/.env.*","**/.env.local","**/.env.development","**/.env.production","**/.env.test","**/.env.development.local","**/.env.production.local","**/build","**/dist","**/*.pyc","**/.DS_Store","**/.vscode","**/node_modules","**/__pycache__","**/coverage","**/.next","**/coverage","**/example","**/yarn.lock","**/pnpm-lock.yaml","**/__snapshots__","**/package-lock.json","**/fusion.config.json","**/builder.config.json","**/.gradle","**/xcuserdata","**/.build","**/*.zip","**/*.pem","**/*.key","**/*.p12","**/*.pfx","**/*.cer","**/*.crt","**/*.der","**/*.p7b","**/*.p7c","**/*.jks","**/*.keystore","**/id_rsa","**/id_rsa.*","**/id_dsa","**/id_dsa.*","**/id_ecdsa","**/id_ecdsa.*","**/id_ed25519","**/id_ed25519.*","**/.ssh/**","**/known_hosts","**/authorized_keys","**/.aws/**","**/credentials","**/.gcp/**","**/.azure/**","**/gcloud/**","**/google-credentials.json","**/gcp-key.json","**/service-account*.json","**/.npmrc","**/.pypirc","**/.dockercfg","**/.docker/config.json","**/token.json","**/tokens.json","**/secrets.json","**/secret.json","**/api-keys.json","**/apikeys.json","**/*.sql","**/*.sqlite","**/*.sqlite3","**/*.db","**/*.dump","**/*.bak","**/passwd","**/password","**/passwords","**/.htpasswd","**/shadow","**/.git-credentials","**/.gitconfig","**/.netrc","**/kubeconfig","**/.kube/**","**/k8s-secrets.yaml","**/k8s-secrets.yml","**/*.tfstate","**/*.tfstate.*","**/.terraform/**","**/.history","**/.bash_history","**/.zsh_history","**/wallet.dat","**/.gnupg/**","**/private.xml","**/signing.properties","**/*.ovpn","**/wp-config.php","**/config.inc.php","**/settings.py","**/local_settings.py","**/database.yml","**/secrets.yml","**/.tox/**","**/firebase-adminsdk*.json","**/firebaseConfig.json","**/google-services.json","**/GoogleService-Info.plist"];function Ite(e){let t=(0,SR.default)().add(GD);function r(n){try{let i=(0,Kr.resolve)(e,n);if((0,Vr.existsSync)(i)){let s=(0,Vr.readFileSync)(i,"utf8");t.add(s)}}catch(i){console.debug(`No ${n} found or error reading it:`,i)}}for(let n of qD)r(n);return n=>{let i=n.split(Kr.sep).join("/");return t.ignores(i)}}function CR(e,t,r){let n=Ite(e),i=wR.default.watch(e,{ignored:n,ignoreInitial:!0,awaitWriteFinish:{stabilityThreshold:500,pollInterval:600},ignorePermissionErrors:!0,followSymlinks:!1,atomic:600}),s=async a=>{let c=(0,Kr.relative)(e,a);try{let u=(0,Vr.readFileSync)(a,"utf-8");if(_te(u,t.snippet)){let l=t.writtenFiles.find(p=>p.path===c);l?(l.code=Em(u),l.timestamp=Date.now()):t.writtenFiles.push({path:c,code:Em(u),timestamp:Date.now(),name:c.split("/").pop()||""}),t.timeStamp=Date.now(),r(t)}}catch(u){console.debug(`Error reading file ${a}:`,u)}};i.on("add",async a=>{B.info(`File added: ${a}`),await s(a)}).on("change",async a=>{B.info(`File changed: ${a}`),await s(a)}).on("unlink",a=>{B.info(`File deleted: ${a}`);let c=(0,Kr.relative)(e,a);t.writtenFiles=t.writtenFiles.filter(u=>u.path!==c),t.timeStamp=Date.now(),r(t)}).on("unlinkDir",a=>{B.info(`Folder deleted: ${a}`);let c=(0,Kr.relative)(e,a);t.writtenFiles=t.writtenFiles.filter(u=>!u.path.startsWith(c)),t.timeStamp=Date.now(),r(t)}).on("ready",()=>{console.debug("Initial scan complete. Ready for changes.")}).on("error",a=>{console.error(`Watcher error: ${a}`)}),i.on("raw",async(a,c,u)=>{if(a==="rename"){B.info(`File renamed: ${u?.oldPath} -> ${c}`);let l=u?.oldPath?(0,Kr.relative)(e,u.oldPath):void 0,p=c?(0,Kr.relative)(e,c):void 0;if(l&&p){let d=t.writtenFiles.find(h=>h.path===l);d&&(d.path=p,t.timeStamp=Date.now(),r(t))}}});let o=async()=>{await i.close()};return process.on("SIGINT",o),process.on("SIGTERM",o),o}async function PR(e,t){console.log(""),ze((0,Ks.bgMagenta)((0,Ks.bold)((0,Ks.white)(" sync server ")))+" "+(0,Ks.dim)(Te)),e.debug("builder sync server init");let r=await Is(e),n=t,i=()=>Promise.resolve();n&&setTimeout(()=>{i=CR(e.getAppRootDir(),n,s=>{n=s})},1e3),await $D({...r,ensureFigmaImportPage:()=>Promise.reject("Not supported"),getPastSyncInfo:({sessionKey:s,since:o})=>!n||s!==n.snippet.sessionKey?null:{...n,hasChanged:n.timeStamp>o},resyncSnippet:async s=>{await i();let o=await zD({path:n?.pathInput,snippet:s.snippet,cwd:e.getAppRootDir()});return o&&(n=o,i=CR(e.getAppRootDir(),n,a=>{n=a})),n},getClientId:()=>"builder-sync-cli",closeAppServer:async()=>{await i()},restartAppServer:async()=>{e.debug("restart server")},enableAppWatch:async s=>s,...e})}async function zD(e){let t=e.snippetId,r=e.snippet||null;if(!r&&t&&(r=await UD(t)),!r)return De(`No snippet found for id ${t}`),await te(1);let n=process.cwd(),i=bl(n)??n,s=await Fte(i,r.contentId,r.sessionKey),o=s.filter(p=>p.snippetId===r.id);if(B.info(`Found ${o.length} matching files for snippet ${r.id} in existing files ${s.length}`),o.length>0){let p=Math.max(...o.map(d=>d.timestamp||0));return{snippet:r,writtenFiles:o,pathInput:ER(o.map(d=>d.path)),timeStamp:p}}let a=jD(i,r.framework||"react"),c=e.path||ER(s.map(p=>p.path))||await nt({message:"Where should we copy the files?",initialValue:a,validate(p){if(p.length===0)return"File path is required!";if(p[0]!==".")return"Please enter a relative path."}});ve(c)&&(De("Cancelled sync"),process.exit(0));for(let p of s){let d=(0,Kr.resolve)(i,p.path);try{(0,Vr.unlinkSync)(d),B.info(`Deleted old file: ${d}`);let h=(0,Kr.dirname)(d);(0,Vr.readdirSync)(h).length===0&&((0,Vr.rmdirSync)(h),B.info(`Deleted empty folder: ${h}`))}catch(h){B.error(`Error cleaning up file ${d}: ${h}`)}}let u=await Cm(i,r,r.files,c,!0);B.success("All files have been written successfully.");let l=Math.max(...u.map(p=>p.timestamp||0));return{snippet:r,writtenFiles:u.map(p=>({...p,code:Em(p.code)})),pathInput:c,timeStamp:l||Date.now()}}function Em(e){if(!e)return e;let t=/<!--\s*This code was generated by Builder\.io\s*-->\s*(?:<!--\s*https:\/\/builder\.io\/content\/[a-f0-9]+\?codeSession=[a-f0-9]+&sid=[a-f0-9]+\s*-->\s*)?/,r=/\/\*\*\s*\n\s*\* This code was generated by Builder\.io\s*\n\s*\* https:\/\/builder\.io\/content\/[a-f0-9]+\?codeSession=[a-f0-9]+&sid=[a-f0-9]+\s*\n\s*\*\/\s*/,n=e.replace(t,"").replace(r,"");return n=n.replace(/^\n+/,""),n}function ER(e){if(e.length===0)return"";if(e.length===1)return`./${e[0].slice(0,e[0].lastIndexOf("/")+1)}`;let t=e.map(i=>i.split("/")),r=Math.min(...t.map(i=>i.length)),n=[];for(let i=0;i<r;i++){let s=t[0][i];if(t.every(o=>o[i]===s))n.push(s);else break}return`./${n.join("/")}`}f();var Ws=q(vt(),1);f();f();var HD=q(require("process"),1);function KD(){let{env:e}=HD.default,{TERM:t,TERM_PROGRAM:r}=e;return HD.default.platform!=="win32"?t!=="linux":!!e.WT_SESSION||!!e.TERMINUS_SUBLIME||e.ConEmuTask==="{cmd::Cmder}"||r==="Terminus-Sublime"||r==="vscode"||t==="xterm-256color"||t==="alacritty"||t==="rxvt-unicode"||t==="rxvt-unicode-256color"||e.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var VD=q(vt(),1),ss=q(cd(),1),wm=require("process"),Vs=q(require("readline"),1),_l=q(vt(),1),Fn=()=>{let e=WD?["\u25D2","\u25D0","\u25D3","\u25D1"]:["\u2022","o","O","0"],t=WD?80:120,r,n,i=!1,s="",o="",a="",c=b=>{let v=b>1?"Something went wrong":"Canceled";i&&m(v,b)},u=(b,v)=>{console.error(v,b),c(2)},l=()=>c(1),p=()=>{process.on("uncaughtExceptionMonitor",u),process.on("unhandledRejection",u),process.on("SIGINT",l),process.on("SIGTERM",l),process.on("exit",c)},d=()=>{process.removeListener("uncaughtExceptionMonitor",u),process.removeListener("unhandledRejection",u),process.removeListener("SIGINT",l),process.removeListener("SIGTERM",l),process.removeListener("exit",c)},h=(b="")=>{i=!0,r=Mte(),s=b.replace(/\.+$/,""),process.stdout.write(`${VD.default.gray(kte)}
1529
+ ${t}`}async function Ete(e,t,r){let n,i=Ste(r,t.toLowerCase());switch(t.toLowerCase()){case"react":let s=await wte(e);n=`components/${i||"MyComponent"}.${s?"tsx":"jsx"}`;break;case"angular":n=`app/components/${i||"my-component"}.component.ts`;break;case"vue":n=`components/${i||"MyComponent"}.vue`;break;case"svelte":n=`components/${i||"MyComponent"}.svelte`;break;case"html":n=`${i||"my-design"}.html`;break;case"qwik":n=`components/${i||"MyComponent"}.tsx`;break;default:n=`components/${i||"MyComponent"}.tsx`}return n=(0,cr.existsSync)("./src")?`./src/${n}`:`./${n}`,n}async function wte(e){if((0,cr.existsSync)((0,ei.join)(e,"./tsconfig.json")))return!0;let t=kx(e);return t&&(0,cr.existsSync)((0,ei.join)(t,"./package.json"))?(0,cr.readFileSync)((0,ei.join)(t,"./package.json"),"utf-8").includes("typescript"):!1}function Ste(e,t){let r={vue:/name:\s*'([^']+)'/,react:/function (\w+)\([\w\W]+\)/,qwik:/export const (\w+) = component\$/,angular:/selector:\s*'([^']+)'/};if(!r[t])return null;let n=e.match(r[t]);return t==="react"&&!n?.[1]?e.match(/const (\w+)[\w\W]+=\s*\(/)?.[1]||null:n?.[1]||null}async function Cm(e,t,r,n,i){let s=[];for(let o of r){let a=Tte(n,o.path),c=(0,ei.resolve)(e,a);if("code"in o){let u=await Pte(e,t,o.code,Ate(o.path),i);(0,cr.existsSync)(c)||(0,cr.mkdirSync)((0,ei.dirname)(c),{recursive:!0}),(0,cr.writeFileSync)(c,u),s.push({...o,path:a,code:u,timestamp:(0,cr.statSync)(c).mtime.getTime()}),B.info(`Writing file to ${c}`)}else(0,cr.mkdirSync)(c,{recursive:!0}),s=s.concat(await Cm(e,t,o.files,a,i))}return s}function Tte(e,t){let r=e.replace(/^\.?\/+|\/+$/g,""),n=t.replace(/^\.?\/+|\/+$/g,""),i=r.split("/").filter(Boolean),s=n.split("/").filter(Boolean),o=-1;for(let c=0;c<i.length;c++){let u=s.indexOf(i[c]);u!==-1&&(o=u)}return[...i,...s.slice(o+1)].join("/")}function Ate(e){switch(e.split(".").pop()?.toLowerCase()){case"html":case"svelte":return"html";case"vue":return"vue";case"ts":case"tsx":case"js":case"jsx":return"typescript";case"css":return"css";case"json":return"json";default:return"typescript"}}async function Pte(e,t,r,n,i){let s=r;try{s=await Zr(e,r,n,void 0)}catch{}return i?DR(t,s,n,i):s}function jD(e,t){let n=(0,cr.existsSync)((0,ei.join)(e,"src"))?"src/":"";switch(t.toLowerCase()){case"angular":return`./${n}app/components/`;case"html":return"./";default:return`./${n}components/`}}var wR=q(require("chokidar"),1),SR=q(require("ignore"),1);function TR(e){let t=e.match(/builder\.io\/content\/([^?]+)\?codeSession=([^&]+)&sid=([^\s]+)/);return t?{contentId:t[1],sessionKey:t[2],snippetId:t[3]}:{}}async function xc(e,t="**/*",r,n=!1){return await MD(t,{cwd:e,ignoreFiles:qD,ignore:[...GD,...r||[]],absolute:!1,dot:n})}async function Fte(e,t,r){let n=await MD("**/*",{cwd:e,ignoreFiles:qD,ignore:GD}),i=[];for(let s of n){let o=(0,Kr.resolve)(e,s);try{let a=(0,Vr.readFileSync)(o,"utf-8");if(a.includes("This code was generated by Builder.io")){let c=TR(a);if(t&&r&&(c.contentId!==t||c.sessionKey!==r))continue;i.push({path:s,code:Em(a),name:s.split("/").pop()||"",timestamp:(0,Vr.statSync)(o).mtime.getTime(),snippetId:c.snippetId})}}catch(a){console.error(`Error reading file ${o}:`,a)}}return i}function _te(e,t){let r=TR(e);return r.contentId===t.contentId&&r.sessionKey===t.sessionKey}function AR(e){return e.filter(t=>(t=t.toLowerCase(),!t.endsWith(".png")&&!t.endsWith(".jpg")&&!t.endsWith(".jpeg")&&!t.endsWith(".gif")&&!t.endsWith(".ico")&&!t.endsWith(".webp")&&!t.includes(".mapper.")))}var qD=[".gitignore",".prettierignore",".builderignore"],GD=["**/*.yml","**/*.yaml","**/*.snap","**/*.liquid","**/.git","**/.env","**/.env.*","**/.env.local","**/.env.development","**/.env.production","**/.env.test","**/.env.development.local","**/.env.production.local","**/build","**/dist","**/*.pyc","**/.DS_Store","**/.vscode","**/node_modules","**/__pycache__","**/coverage","**/.next","**/coverage","**/example","**/yarn.lock","**/pnpm-lock.yaml","**/__snapshots__","**/package-lock.json","**/fusion.config.json","**/builder.config.json","**/.gradle","**/xcuserdata","**/.build","**/*.zip","**/*.pem","**/*.key","**/*.p12","**/*.pfx","**/*.cer","**/*.crt","**/*.der","**/*.p7b","**/*.p7c","**/*.jks","**/*.keystore","**/id_rsa","**/id_rsa.*","**/id_dsa","**/id_dsa.*","**/id_ecdsa","**/id_ecdsa.*","**/id_ed25519","**/id_ed25519.*","**/.ssh/**","**/known_hosts","**/authorized_keys","**/.aws/**","**/credentials","**/.gcp/**","**/.azure/**","**/gcloud/**","**/google-credentials.json","**/gcp-key.json","**/service-account*.json","**/.npmrc","**/.pypirc","**/.dockercfg","**/.docker/config.json","**/token.json","**/tokens.json","**/secrets.json","**/secret.json","**/api-keys.json","**/apikeys.json","**/*.sql","**/*.sqlite","**/*.sqlite3","**/*.db","**/*.dump","**/*.bak","**/passwd","**/password","**/passwords","**/.htpasswd","**/shadow","**/.git-credentials","**/.gitconfig","**/.netrc","**/kubeconfig","**/.kube/**","**/k8s-secrets.yaml","**/k8s-secrets.yml","**/*.tfstate","**/*.tfstate.*","**/.terraform/**","**/.history","**/.bash_history","**/.zsh_history","**/wallet.dat","**/.gnupg/**","**/private.xml","**/signing.properties","**/*.ovpn","**/wp-config.php","**/config.inc.php","**/settings.py","**/local_settings.py","**/database.yml","**/secrets.yml","**/.tox/**","**/firebase-adminsdk*.json","**/firebaseConfig.json","**/google-services.json","**/GoogleService-Info.plist"];function Ite(e){let t=(0,SR.default)().add(GD);function r(n){try{let i=(0,Kr.resolve)(e,n);if((0,Vr.existsSync)(i)){let s=(0,Vr.readFileSync)(i,"utf8");t.add(s)}}catch(i){console.debug(`No ${n} found or error reading it:`,i)}}for(let n of qD)r(n);return n=>{let i=n.split(Kr.sep).join("/");return t.ignores(i)}}function CR(e,t,r){let n=Ite(e),i=wR.default.watch(e,{ignored:n,ignoreInitial:!0,awaitWriteFinish:{stabilityThreshold:500,pollInterval:600},ignorePermissionErrors:!0,followSymlinks:!1,atomic:600}),s=async a=>{let c=(0,Kr.relative)(e,a);try{let u=(0,Vr.readFileSync)(a,"utf-8");if(_te(u,t.snippet)){let l=t.writtenFiles.find(p=>p.path===c);l?(l.code=Em(u),l.timestamp=Date.now()):t.writtenFiles.push({path:c,code:Em(u),timestamp:Date.now(),name:c.split("/").pop()||""}),t.timeStamp=Date.now(),r(t)}}catch(u){console.debug(`Error reading file ${a}:`,u)}};i.on("add",async a=>{B.info(`File added: ${a}`),await s(a)}).on("change",async a=>{B.info(`File changed: ${a}`),await s(a)}).on("unlink",a=>{B.info(`File deleted: ${a}`);let c=(0,Kr.relative)(e,a);t.writtenFiles=t.writtenFiles.filter(u=>u.path!==c),t.timeStamp=Date.now(),r(t)}).on("unlinkDir",a=>{B.info(`Folder deleted: ${a}`);let c=(0,Kr.relative)(e,a);t.writtenFiles=t.writtenFiles.filter(u=>!u.path.startsWith(c)),t.timeStamp=Date.now(),r(t)}).on("ready",()=>{console.debug("Initial scan complete. Ready for changes.")}).on("error",a=>{console.error(`Watcher error: ${a}`)}),i.on("raw",async(a,c,u)=>{if(a==="rename"){B.info(`File renamed: ${u?.oldPath} -> ${c}`);let l=u?.oldPath?(0,Kr.relative)(e,u.oldPath):void 0,p=c?(0,Kr.relative)(e,c):void 0;if(l&&p){let d=t.writtenFiles.find(h=>h.path===l);d&&(d.path=p,t.timeStamp=Date.now(),r(t))}}});let o=async()=>{await i.close()};return process.on("SIGINT",o),process.on("SIGTERM",o),o}async function PR(e,t){console.log(""),ze((0,Ks.bgMagenta)((0,Ks.bold)((0,Ks.white)(" sync server ")))+" "+(0,Ks.dim)(Ce)),e.debug("builder sync server init");let r=await Is(e),n=t,i=()=>Promise.resolve();n&&setTimeout(()=>{i=CR(e.getAppRootDir(),n,s=>{n=s})},1e3),await $D({...r,ensureFigmaImportPage:()=>Promise.reject("Not supported"),getPastSyncInfo:({sessionKey:s,since:o})=>!n||s!==n.snippet.sessionKey?null:{...n,hasChanged:n.timeStamp>o},resyncSnippet:async s=>{await i();let o=await zD({path:n?.pathInput,snippet:s.snippet,cwd:e.getAppRootDir()});return o&&(n=o,i=CR(e.getAppRootDir(),n,a=>{n=a})),n},getClientId:()=>"builder-sync-cli",closeAppServer:async()=>{await i()},restartAppServer:async()=>{e.debug("restart server")},enableAppWatch:async s=>s,...e})}async function zD(e){let t=e.snippetId,r=e.snippet||null;if(!r&&t&&(r=await UD(t)),!r)return De(`No snippet found for id ${t}`),await te(1);let n=process.cwd(),i=bl(n)??n,s=await Fte(i,r.contentId,r.sessionKey),o=s.filter(p=>p.snippetId===r.id);if(B.info(`Found ${o.length} matching files for snippet ${r.id} in existing files ${s.length}`),o.length>0){let p=Math.max(...o.map(d=>d.timestamp||0));return{snippet:r,writtenFiles:o,pathInput:ER(o.map(d=>d.path)),timeStamp:p}}let a=jD(i,r.framework||"react"),c=e.path||ER(s.map(p=>p.path))||await nt({message:"Where should we copy the files?",initialValue:a,validate(p){if(p.length===0)return"File path is required!";if(p[0]!==".")return"Please enter a relative path."}});ve(c)&&(De("Cancelled sync"),process.exit(0));for(let p of s){let d=(0,Kr.resolve)(i,p.path);try{(0,Vr.unlinkSync)(d),B.info(`Deleted old file: ${d}`);let h=(0,Kr.dirname)(d);(0,Vr.readdirSync)(h).length===0&&((0,Vr.rmdirSync)(h),B.info(`Deleted empty folder: ${h}`))}catch(h){B.error(`Error cleaning up file ${d}: ${h}`)}}let u=await Cm(i,r,r.files,c,!0);B.success("All files have been written successfully.");let l=Math.max(...u.map(p=>p.timestamp||0));return{snippet:r,writtenFiles:u.map(p=>({...p,code:Em(p.code)})),pathInput:c,timeStamp:l||Date.now()}}function Em(e){if(!e)return e;let t=/<!--\s*This code was generated by Builder\.io\s*-->\s*(?:<!--\s*https:\/\/builder\.io\/content\/[a-f0-9]+\?codeSession=[a-f0-9]+&sid=[a-f0-9]+\s*-->\s*)?/,r=/\/\*\*\s*\n\s*\* This code was generated by Builder\.io\s*\n\s*\* https:\/\/builder\.io\/content\/[a-f0-9]+\?codeSession=[a-f0-9]+&sid=[a-f0-9]+\s*\n\s*\*\/\s*/,n=e.replace(t,"").replace(r,"");return n=n.replace(/^\n+/,""),n}function ER(e){if(e.length===0)return"";if(e.length===1)return`./${e[0].slice(0,e[0].lastIndexOf("/")+1)}`;let t=e.map(i=>i.split("/")),r=Math.min(...t.map(i=>i.length)),n=[];for(let i=0;i<r;i++){let s=t[0][i];if(t.every(o=>o[i]===s))n.push(s);else break}return`./${n.join("/")}`}f();var Ws=q(vt(),1);f();f();var HD=q(require("process"),1);function KD(){let{env:e}=HD.default,{TERM:t,TERM_PROGRAM:r}=e;return HD.default.platform!=="win32"?t!=="linux":!!e.WT_SESSION||!!e.TERMINUS_SUBLIME||e.ConEmuTask==="{cmd::Cmder}"||r==="Terminus-Sublime"||r==="vscode"||t==="xterm-256color"||t==="alacritty"||t==="rxvt-unicode"||t==="rxvt-unicode-256color"||e.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var VD=q(vt(),1),ss=q(cd(),1),wm=require("process"),Vs=q(require("readline"),1),_l=q(vt(),1),Fn=()=>{let e=WD?["\u25D2","\u25D0","\u25D3","\u25D1"]:["\u2022","o","O","0"],t=WD?80:120,r,n,i=!1,s="",o="",a="",c=b=>{let v=b>1?"Something went wrong":"Canceled";i&&m(v,b)},u=(b,v)=>{console.error(v,b),c(2)},l=()=>c(1),p=()=>{process.on("uncaughtExceptionMonitor",u),process.on("unhandledRejection",u),process.on("SIGINT",l),process.on("SIGTERM",l),process.on("exit",c)},d=()=>{process.removeListener("uncaughtExceptionMonitor",u),process.removeListener("unhandledRejection",u),process.removeListener("SIGINT",l),process.removeListener("SIGTERM",l),process.removeListener("exit",c)},h=(b="")=>{i=!0,r=Mte(),s=b.replace(/\.+$/,""),process.stdout.write(`${VD.default.gray(kte)}
1530
1530
  `);let v=0,C=0;p(),process.env.CI||(n=setInterval(()=>{let x=VD.default.magenta(e[v]),D=".".repeat(Math.floor(C)).slice(0,3);process.stdout.write(ss.cursor.move(-999,-a.split(`
1531
1531
  `).length+1)),process.stdout.write(ss.erase.down(a.split(`
1532
1532
  `).length));let E=`${x} ${s}${D}${o}`;process.stdout.write(E),v=v+1<e.length?v+1:0,C=C<e.length?C+.125:0,a=E},t))},m=(b,v=0)=>{s=b??s,i=!1,clearInterval(n);let C=v===0?(0,_l.green)(Ote):v===1?(0,_l.red)(Nte):(0,_l.red)(Rte);process.stdout.write(ss.cursor.move(-999,-a.split(`
1533
1533
  `).length+1)),process.stdout.write(ss.erase.down(a.split(`
1534
1534
  `).length)),process.stdout.write(`${C} ${s}
1535
1535
  `),a=s,d(),r()};return{start:h,stop:m,message:(b="")=>{s=b??s},extra:(b="")=>{o=b}}},WD=KD(),Sm=(e,t)=>WD?e:t,kte=Sm("\u2502","|"),Nte=Sm("\u25A0","x"),Rte=Sm("\u25B2","x"),Ote=Sm("\u25C7","o"),Bte=globalThis.process.platform.startsWith("win");function Mte({input:e=wm.stdin,output:t=wm.stdout,overwrite:r=!0,hideCursor:n=!0}={}){let i=Vs.createInterface({input:e,output:t,prompt:"",tabSize:1});Vs.emitKeypressEvents(e,i),e.isTTY&&e.setRawMode(!0);let s=(o,{name:a})=>{if(String(o)===""){n&&t.write(ss.cursor.show),process.exit(0);return}if(!r)return;Vs.moveCursor(t,a==="return"?0:-1,a==="return"?-1:0,()=>{Vs.clearLine(t,1,()=>{e.once("keypress",s)})})};return n&&t.write(ss.cursor.hide),e.once("keypress",s),()=>{e.off("keypress",s),n&&t.write(ss.cursor.show),e.isTTY&&!Bte&&e.setRawMode(!1),i.terminal=!1,i.close()}}f();async function*Il(e){if(!e)return;let t="",r=e.getReader(),n,i;try{for(;!n&&({value:i,done:n}=await r.read(),!n);){let s=new TextDecoder().decode(i);t+=s;let o=t.split(`
1536
- `);for(let a=0;a<o.length-1;a++)yield o[a];t=o[o.length-1]}}catch(s){throw s}finally{try{r.releaseLock()}catch(s){console.error("Error releasing lock",s)}}}var FR=async(e,t)=>{console.log(""),ze((0,Ws.bgCyan)((0,Ws.bold)((0,Ws.white)(" code indexing ")))+" "+(0,Ws.dim)(Te)),console.error("NOT SUPPORTED YET"),sr("DONE")};f();var U=q(vt(),1);function ti(e){switch(_e("cli help",{subcommand:e}),console.log(""),ze((0,U.bgCyan)((0,U.bold)((0,U.white)(" help ")))+" "+(0,U.dim)(Te)),e){case"add":case"generate":case"gen":case"g":ze(`${(0,U.cyan)("\u2192")} ${(0,U.bold)("Generate Figma Components")}
1536
+ `);for(let a=0;a<o.length-1;a++)yield o[a];t=o[o.length-1]}}catch(s){throw s}finally{try{r.releaseLock()}catch(s){console.error("Error releasing lock",s)}}}var FR=async(e,t)=>{console.log(""),ze((0,Ws.bgCyan)((0,Ws.bold)((0,Ws.white)(" code indexing ")))+" "+(0,Ws.dim)(Ce)),console.error("NOT SUPPORTED YET"),sr("DONE")};f();var U=q(vt(),1);function ti(e){switch(_e("cli help",{subcommand:e}),console.log(""),ze((0,U.bgCyan)((0,U.bold)((0,U.white)(" help ")))+" "+(0,U.dim)(Ce)),e){case"add":case"generate":case"gen":case"g":ze(`${(0,U.cyan)("\u2192")} ${(0,U.bold)("Generate Figma Components")}
1537
1537
 
1538
1538
  ${(0,U.bgGreen)((0,U.white)(` npx ${fr()} figma generate URL [URL ...] `))}
1539
1539
 
@@ -1863,7 +1863,7 @@ ${a.userPrompt}`)}}a.attachments=t.attachments??[],a.searchResponse=l,a.rerankFi
1863
1863
  `),{files:i,diff:`${o}${s}`}}catch(t){this.#e.Sentry?.captureException(t,{tags:{operation:"codegen-git"}});return}}#se(){return["status","--porcelain=v1","-z","--ignore-submodules=dirty"]}async isCleanWorkTree(){try{return(await this.git(this.#se())).trim().length===0}catch{return!1}}async#Se(t,r){let n=!1,i=r.applyResults;for(let s of i)try{if(s.action==="delete")await this.deleteFile(s.filePath)&&(n=!0);else if(s.content&&await this.writeFile(s.filePath,s.content)){let{resolvedPath:a}=this.resolveWorkspacePath(s.filePath,!0);this.#z.add(a),n=!0}}catch(o){t.Sentry?.captureException(o)}return n}#oe(){return this.#n?.folders?.length===1&&this.#n.folders[0].name==="."}#B(){return this.#n?.folders?.length===1}resolveWorkspacePath(t,r){return $8({filePath:t,forceWorkspace:r,workspace:this.#n,workingDirectory:this.#o,sys:this.#e,canCollapseWorkspace:this.#B()})}#b(){try{let t=this.getSessionContext();return us(t.turns)?.user.principals}catch{return}}absolutePathToWorkspaceUrl(t){return U8({absolutePath:t,workspace:this.#n,workingDirectory:this.#o,sys:this.#e,canCollapseWorkspace:this.#B()})}async readFile(t){let r=Qs(t,"read",this.#i?.accessControl,this.#b());if(!r.allowed)throw new Error(`ACL denied: ${r.message}`);try{if(t==="AGENTS.md"&&this.#n?.agentsMD)return this.#n.agentsMD;let{resolvedPath:n}=this.resolveWorkspacePath(t,!1);if(await this.#e.exists(n))return await this.#e.readFile(n);if({resolvedPath:n}=this.resolveWorkspacePath(t,!0),await this.#e.exists(n))return await this.#e.readFile(n)}catch(n){this.#e.Sentry?.captureException(n,{extra:{filePath:t}})}return null}async fileExists(t){let r=Qs(t,"read",this.#i?.accessControl,this.#b());if(!r.allowed)throw new Error(`ACL denied: ${r.message}`);try{if(t==="AGENTS.md"&&this.#n?.agentsMD)return!0;let{resolvedPath:n}=this.resolveWorkspacePath(t,!1);if(await this.#e.exists(n)||({resolvedPath:n}=this.resolveWorkspacePath(t,!0),await this.#e.exists(n)))return!0}catch(n){this.#e.Sentry?.captureException(n,{extra:{filePath:t}})}return!1}readFileSync(t){let r=Qs(t,"read",this.#i?.accessControl,this.#b());if(!r.allowed)throw new Error(`ACL denied: ${r.message}`);try{if(t==="AGENTS.md"&&this.#n?.agentsMD)return this.#n.agentsMD;let{resolvedPath:n}=this.resolveWorkspacePath(t,!1);if(this.#e.existsSync(n))return this.#e.readFileSync(n);if({resolvedPath:n}=this.resolveWorkspacePath(t,!0),this.#e.existsSync(n))return this.#e.readFileSync(n)}catch(n){this.#e.Sentry?.captureException(n,{extra:{filePath:t}})}return null}async writeFile(t,r){let n=Qs(t,"write",this.#i?.accessControl,this.#b());if(!n.allowed)throw new Error(`ACL denied: ${n.message}`);try{let{resolvedPath:i}=this.resolveWorkspacePath(t,!0);return await this.#e.writeFile(i,r),!0}catch(i){return this.#e.Sentry?.captureException(i,{extra:{filePath:t}}),!1}}async listDir(t){let r=Qs(t,"list",this.#i?.accessControl,this.#b());if(!r.allowed)throw new Error(`ACL denied: ${r.message}`);try{let{resolvedPath:n,workspaceFolder:i}=this.resolveWorkspacePath(t,!0);if(!await this.#e.exists(n))return[];let s=await this.#e.readdir(n,!1);if(this.#oe())return s.map(o=>this.#e.join(t,o).replace(/^\.\//,""));if(i&&this.#n?.folders){let o=i.name||i.path;return s.map(a=>`${o}/${this.#e.join(t,a).replace(/^\.\//,"")}`)}return s}catch(n){return this.#e.Sentry?.captureException(n,{extra:{dirPath:t}}),[]}}async stat(t){let r=Qs(t,"read",this.#i?.accessControl,this.#b());if(!r.allowed)throw new Error(`ACL denied: ${r.message}`);try{let{resolvedPath:n}=this.resolveWorkspacePath(t,!1);if(await this.#e.exists(n))return await this.#e.stat(n);if({resolvedPath:n}=this.resolveWorkspacePath(t,!0),await this.#e.exists(n))return await this.#e.stat(n)}catch(n){this.#e.Sentry?.captureException(n,{extra:{filePath:t}})}return null}async deleteFile(t){let r=Qs(t,"write",this.#i?.accessControl,this.#b());if(!r.allowed)throw new Error(`ACL denied: ${r.message}`);try{let{resolvedPath:n}=this.resolveWorkspacePath(t,!0);return await this.#e.exists(n)?(await this.#e.unlink(n),!0):!1}catch(n){return this.#e.Sentry?.captureException(n,{extra:{filePath:t}}),!1}}getLinesStats(){let t=this.#l?.turns.reduce((r,n)=>{let i=n.applyResults.reduce((s,o)=>({added:s.added+o.addedLines,removed:s.removed+o.removedLines}),{added:0,removed:0});return{added:r.added+i.added,removed:r.removed+i.removed}},{added:0,removed:0})??{added:0,removed:0};return{...t,net:t.added-t.removed}}async getDiffFromRemote(){if(!this.#t?.git)return[];try{let t=(await this.git(["branch","--show-current"])).trim();if(!t)throw new Error("Could not determine current branch");let r=!1;try{r=(await this.git(["remote"])).includes("origin")}catch{return console.warn("No git remotes configured, cannot get diff from remote"),[]}if(!r){console.warn("Origin remote not found, trying to get diff from local main branch");try{let o=await this.git(["branch","--list"]),a=o.includes("* main")||o.includes(" main"),c=o.includes("* master")||o.includes(" master"),u=null;if(a?u="main":c&&(u="master"),u&&u!==t){let l=await this.git(["diff",u,"--"]);return!l||l.trim()===""?[]:$0(l)}else return console.warn("No local main/master branch found or already on main branch"),[]}catch(o){return console.warn("Failed to get diff from local main branch:",o),[]}}let n=!1,i;try{let o=`origin/${t}`;if(n=(await this.git(["ls-remote","--heads","origin",t])).trim().length>0,n)i=o;else{i=await this.getDefaultBranch();let c=i.split("/")[1];try{await this.git(["fetch","origin",c])}catch(u){console.warn("Failed to fetch latest changes from remote:",u)}}}catch(o){return console.warn("Failed to check remote branches:",o),[]}let s=await this.git(["diff",i,"--"]);return!s||s.trim()===""?[]:$0(s)}catch(t){return console.error("getDiffFromRemote error:",t),[]}}async getDefaultBranch(){try{let r=(await this.git(["remote","show","origin"])).match(/HEAD branch: (.+)/);if(r)return`origin/${r[1].trim()}`}catch{}try{if((await this.git(["ls-remote","--heads","origin","main"])).trim().length>0)return"origin/main"}catch{}try{if((await this.git(["ls-remote","--heads","origin","master"])).trim().length>0)return"origin/master"}catch{}try{let r=(await this.git(["ls-remote","--heads","origin"])).trim().split(`
1864
1864
  `).map(n=>n.split(" ")[1]).filter(n=>n&&!n.includes("HEAD"));if(r.length>0)return`origin/${r[0].replace("refs/heads/","")}`}catch{}throw new Error("Could not determine default branch. No remote branches found.")}};function G8(e){for(let t=e.turns.length-1;t>=0;t--){let r=e.turns[t];if(r.state==="done"&&r.nextUrl)return r}}function vie(e){for(let t=e.turns.length-1;t>=0;t--){let r=e.turns[t];if(r.nextUrl&&(r.applyResults.length>0||r.user.role==="user"))return r}}function us(e){return e[e.length-1]}function Die(e){for(let t=e.length-1;t>=0;t--)e[t].state!=="done"&&e.splice(t,1)}async function Cie(e,t,r,n){let i=new URL(`${Fe}/codegen/restore-consumed-credit`);t.builderPublicKey&&i.searchParams.set("apiKey",t.builderPublicKey),t.userId&&i.searchParams.set("userId",t.userId);let s={"Content-Type":"application/json"};t.builderPrivateKey&&(s.Authorization=`Bearer ${t.builderPrivateKey}`);try{await he(i,{method:"POST",body:JSON.stringify({sessionId:r,restoreCredits:n}),headers:s})}catch(o){e.Sentry?.captureException(o)}}async function*Eie(e,t,r,n,i){if(!t.builderPrivateKey)throw new Error("Missing builder public key during completion stream");let s=JSON.stringify(r),o=new URL(`${Fe}/codegen/completion`);t.builderPublicKey&&o.searchParams.set("apiKey",t.builderPublicKey),t.userId&&o.searchParams.set("userId",t.userId);let a=performance.now(),c=a,u=!1,l=!1,p=[];try{let d=await he(o,{method:"POST",body:s,keepalive:!1,headers:{Connection:"close","Content-Type":"application/json",Authorization:`Bearer ${t.builderPrivateKey}`},signal:i});if(!d.ok){if(d.status===402){yield await d.json();return}let m=await d.text(),g=new Error(`Bad Status: ${d.status}: ${m}`);throw g.name="BadStatus",g}let h=Il(d.body);for await(let m of h)if(c=performance.now(),m.length!==0){p.push(m),p=p.slice(-10);try{let g=JSON.parse(m);u=!0,yield g}catch(g){e.Sentry?.captureException(g,{extra:{value:m}})}}}catch(d){if(d instanceof Error&&d.name==="AbortError")throw d;let h=performance.now();if(l){e.Sentry?.captureException(new Error("Error after stream ended",{cause:d}),{extra:{didStream:u,lastMessageElapsed:h-c,totalElapsed:h-a,lastEvents:p}});return}let m=d instanceof Error?d.name:"UnknownError",g=new _r(`codegen/completion endpoint: ${m}`,{cause:d});throw e.Sentry?.captureException(g,{extra:{didStream:u,lastMessageElapsed:h-c,totalElapsed:h-a,lastEvents:p}}),g}finally{l=!0}}async function wie(e,t,r,n){let i,o=JSON.stringify(r);for(let a=0;a<3;a++){try{let c=new URL(`${Fe}/codegen/feedback`);t.builderPublicKey&&c.searchParams.set("apiKey",t.builderPublicKey),t.userId&&c.searchParams.set("userId",t.userId);let u={"Content-Type":"application/json"};t.builderPrivateKey&&(u.Authorization=`Bearer ${t.builderPrivateKey}`);let l=await he(c,{method:"POST",body:o,keepalive:!0,headers:u});if(l.ok)return!0;throw new Error(`Bad Status: ${l.status}`)}catch(c){i=c}a<2&&await r0(a)}return i&&e.Sentry?.captureException(i),!1}async function z8(e,t,r,n){let i,o=JSON.stringify(r);for(let a=0;a<2;a++){try{let c=new URL(`${Fe}/codegen/sessions/set-last-completion`);t.builderPublicKey&&c.searchParams.set("apiKey",t.builderPublicKey),t.userId&&c.searchParams.set("userId",t.userId);let u={"Content-Type":"application/json"};t.builderPrivateKey&&(u.Authorization=`Bearer ${t.builderPrivateKey}`);let l=await he(c,{method:"POST",body:o,keepalive:!0,headers:u});if(l.ok)return!0;throw new Error(`Bad Status: ${l.status}`)}catch(c){i=c}a<1&&await r0(a)}return i&&e.Sentry?.captureException(i),!1}async function U0(e,t,r,n,i){try{let s=new URL(`${Fe}/codegen/sessions/${r}/turns`);t.builderPublicKey&&s.searchParams.set("apiKey",t.builderPublicKey),t.userId&&s.searchParams.set("userId",t.userId),s.searchParams.set("linear",String(n)),i&&s.searchParams.set("completionIdCursor",i);let o={"Content-Type":"application/json"};t.builderPrivateKey&&(o.Authorization=`Bearer ${t.builderPrivateKey}`);let a=await he(s,{method:"GET",headers:o,keepalive:!0});if(!a.ok)throw new Error("Failed to get turns");return await a.json()}catch(s){return e.Sentry?.captureException(s),{turns:[],sessionId:r,initialUrl:void 0,beforeCommit:void 0,title:void 0,createdUnixTime:void 0,updatedUnixTime:void 0,allIds:[],lastCompletionId:void 0,canLoadMore:!1}}}async function Sie(e,t){let r=[];async function n(u){try{let l=e.resolve(t,u);if(await e.exists(l)){let p=await e.readFile(l);if(p){let d=OR(p,u);r.push(d)}}}catch(l){console.debug(`No ${u} found or error reading it:`,l)}}async function i(u){try{let l=e.resolve(t,u);if(await e.exists(l)){let p=await e.readFile(l);if(p){let d="hash-"+await e.hash(p);r.push({id:d,name:u,content:p,filePath:u})}}}catch(l){console.debug(`No ${u} found or error reading it:`,l)}}let s=[".cursor/rules",".builder/rules"],o=[".cursorrules",".builderrules",".windsurfrules",".github/copilot-instructions.md"],a=e.cwd(),c;do{try{for(let u of s){let l=e.resolve(a,u);if(await e.exists(l)){let p=await e.readdir(l);for(let d of p){let h=e.relative(t,e.resolve(a,`${u}/${d}`));await n(h)}}}}catch(u){console.debug(`Error reading ${a}:`,u)}for(let u of o){let l=e.relative(t,e.resolve(a,u));await i(l)}if(c=a,a=e.dirname(a),a===c)break}while(c!==t);return r}var Tie=e=>{if(!e)return{id:void 0,isInitial:!0};let t=new URL(e);return t.protocol==="cgen:"?{isInitial:!1,id:t.pathname.slice(1)}:{isInitial:!0,id:void 0}};async function j0(e,t){let r=await e.getRepoInfo(t),n={client:"@builder.io/dev-tools",clientVersion:e.version,nodeVersion:process.version,frameworks:e.getFrameworks().map(i=>i.name),systemPlatform:process.platform,systemEOL:Wm.default.EOL,systemArch:Wm.default.arch(),inGitRepo:!!r.remoteUrl};try{let i=Wm.default.userInfo();n.systemShell=i.shell??void 0}catch{}return n}function J8(){let e=!1,t=[],r,n;i();function i(){n=new Promise(c=>r=c)}async function*s(){await n;let c=t.shift();c&&(yield c),e||(yield*s())}function o(c){t.push(c),r(),i()}function a(){e=!0,r()}return[s(),o,a]}function H8(e){return e.endsWith("package.json")||e.endsWith("Podfile")||e.endsWith("Cartfile")||e.endsWith("global.css")||e.endsWith("tailwind.config.ts")||e.endsWith("tailwind.config.js")||e.endsWith("libraries.toml")||e.endsWith("CLAUDE.md")||e.endsWith("AGENT.md")||e.endsWith("AGENTS.md")}function Aie(e){return e?[/ERROR[ ]in\b/i,/(\b|^)failed to compile\b/i,/(\b|^)Internal server error\b/i,/(\b|^)Error when evaluating SSR module virtual\b/i,/(\b|^)ReferenceError: \w* is not defined\b/i,/(\b|^)Found \d+ errors?\./i,/(\b|^)error TS\d+\b/i,/(\b|^)Module build failed\b/i,/(\b|^)Build failed\b/i,/(\b|^)\[Error:.*\]/i,/(\b|^)uncaughtException: /i].some(r=>r.test(e)):!1}async function X8(e,t){try{let r=e.resolve(e.cwd(),t);if(!await e.exists(r))throw new Error(`Workspace file not found: ${t}`);let n=await e.readFile(r);if(!n)throw new Error(`Failed to read workspace file: ${t}`);let i=JSON.parse(n);if(!i.folders||!Array.isArray(i.folders))throw new Error('Invalid workspace configuration: missing "folders" array');let s=e.dirname(r);return{workspace:i,workingDirectory:s}}catch(r){throw console.error(`Error loading workspace: ${r instanceof Error?r.message:String(r)}`),r}}function K8(e,t){return{userPrompt:e.userPrompt+`
1865
1865
 
1866
- `+t.userPrompt,files:Array.from(new Set([...e.files??[],...t.files??[]])),includeBaseFiles:e.includeBaseFiles,skipSearch:t.skipSearch,attachments:t.attachments,debugMode:t.debugMode,displayPrompt:t.displayPrompt,ephemeralUserPrompt:t.ephemeralUserPrompt,dropAbortedPrompt:t.dropAbortedPrompt,user:t.user}}function Pie(){let e=setInterval(()=>{},1073741824);return()=>clearInterval(e)}function Fie(e){let t=e.trim().split(/\s+/).filter(Boolean),r=Number.parseInt(t[0]??"",10),n=Number.parseInt(t[1]??"",10);return{ahead:Number.isFinite(r)?r:0,behind:Number.isFinite(n)?n:0}}function _ie(e){if(e.startsWith("ai/")){let t=e.split("/");if(t.length<3)return{sessionId:void 0,featureBranch:e};let r=t.pop();t.shift();let n=t.join("/");return{sessionId:r,featureBranch:n}}else if(e.startsWith("ai_")){let t=e.split("_");if(t.length<3)return{sessionId:void 0,featureBranch:e};let r=t.pop();t.shift();let n=t.join("_");return{sessionId:r,featureBranch:n}}return{sessionId:void 0,featureBranch:e}}var Ic=class extends Error{code;stdout;stderr;constructor(t,r,n,i,s){super(t,s),this.name="BashError",this.code=r,this.stdout=n,this.stderr=i}};var z0=q(require("readline"),1);f();async function Rc(e){let{default:t}=await import("open");await t(e)}f();var q0=require("process");async function Xm(e,t){let r=["builder.config.json","fusion.config.json"],n=e.cwd(),i=!!t.local||!t.projectId,s,o={devCommand:"",workingDirectory:n,projectId:t.projectId,branchName:t.branchName,serverUrl:"",commitMode:"commits",isLocal:i,allowedCommands:["npm *","pnpm *","yarn *","yarn","git diff *","git diff","git log *","git log","git status *","git status","git add *","git commit *","git pull *","git fetch *","git merge *","echo *","cd *","rm *","find *","ls *","cp *","mv *","curl *","npx tsc *","head *","lsof *","kill *","ps *","awk *","cat *","grep *","sed *","tail *","touch *","mkdir *","npx *","env","printenv *","sleep *","netlify *"]};if(t.configJson)try{let d=JSON.parse(t.configJson);o=Object.assign({},o,d),o.projectId&&(i=!1,o.isLocal=!1)}catch(d){e.Sentry?.captureException(d)}else{for(let d of r){let h=e.join(n,d);if(await e.exists(h)){s=h;break}}if(s)try{let d=await e.readFile(s);if(d){let h=JSON.parse(d);o=Object.assign({},o,h)}}catch(d){e.Sentry?.captureException(d)}}o.command&&(o.devCommand||(o.devCommand=o.command),delete o.command);let a=t.c||t.command,c=t.p||t.port,u=t.installCommand,l=t.serverUrl,p=t.interactive&&!t.configJson&&!t.fusionInit&&i;if(l)p=!1,o.serverUrl=l,a||(o.devCommand="");else if(a&&c){p=!1;let d="http://localhost";if(o.serverUrl)try{let h=new URL(o.serverUrl);d=`${h.protocol}//${h.hostname}`}catch{d="http://localhost"}o.serverUrl=`${d}:${c}`,o.devCommand=a}if(a&&c&&(p=!1),c&&!l&&(o.serverUrl=`http://localhost:${c}`),u&&(o.setupCommand=u),a&&(o.devCommand=a),typeof t.authenticateProxy=="boolean"&&(o.authenticateProxy=t.authenticateProxy),p){if(!o.devCommand){let d=await nt({message:"Enter the command to run for the dev server (e.g. 'npm run dev')",placeholder:"npm run dev",validate:h=>{if(h.trim()===""||h.length===0)return"Command cannot be empty"}});if(ve(d))return De("Goodbye! \u{1F44B}"),await(0,q0.exit)(1);o.devCommand=d}if(!o.serverUrl){let d=await nt({message:"Enter the port number for the dev server",placeholder:"3000",validate:h=>{let m=Number(h);if(isNaN(m)||m<0||m>65535||Math.floor(m)!==m)return"Invalid port number, must be an integer between 0 and 65535"}});if(ve(d))return De("Goodbye! \u{1F44B}"),await(0,q0.exit)(1);o.serverUrl=`http://localhost:${d}`}await e.writeFile(s??e.join(n,r[0]),JSON.stringify(Iie(o,"workingDirectory","projectId","authenticateProxy"),null,2))}return o}var Iie=(e,...t)=>{let r={};if(e&&typeof e=="object")for(let n in e)(!e.hasOwnProperty||e.hasOwnProperty(n))&&(t.includes(n)||(r[n]=e[n]));return r};var t3=async(e,t,r)=>{t==="indexing"?await FR(e,r):t==="generate"||t==="gen"||t==="g"?await Q8(e,r):t==="gen"?ti("code"):await Q8(e,r)},Q8=async(e,t)=>{if(console.log(""),ze((0,pe.bgCyan)((0,pe.bold)((0,pe.white)(" code ")))+" "+(0,pe.dim)(Te)),!Mie()&&!t.prompt){await _e("tty error",{}),B.error(`This command requires a TTY-enabled terminal.
1866
+ `+t.userPrompt,files:Array.from(new Set([...e.files??[],...t.files??[]])),includeBaseFiles:e.includeBaseFiles,skipSearch:t.skipSearch,attachments:t.attachments,debugMode:t.debugMode,displayPrompt:t.displayPrompt,ephemeralUserPrompt:t.ephemeralUserPrompt,dropAbortedPrompt:t.dropAbortedPrompt,user:t.user}}function Pie(){let e=setInterval(()=>{},1073741824);return()=>clearInterval(e)}function Fie(e){let t=e.trim().split(/\s+/).filter(Boolean),r=Number.parseInt(t[0]??"",10),n=Number.parseInt(t[1]??"",10);return{ahead:Number.isFinite(r)?r:0,behind:Number.isFinite(n)?n:0}}function _ie(e){if(e.startsWith("ai/")){let t=e.split("/");if(t.length<3)return{sessionId:void 0,featureBranch:e};let r=t.pop();t.shift();let n=t.join("/");return{sessionId:r,featureBranch:n}}else if(e.startsWith("ai_")){let t=e.split("_");if(t.length<3)return{sessionId:void 0,featureBranch:e};let r=t.pop();t.shift();let n=t.join("_");return{sessionId:r,featureBranch:n}}return{sessionId:void 0,featureBranch:e}}var Ic=class extends Error{code;stdout;stderr;constructor(t,r,n,i,s){super(t,s),this.name="BashError",this.code=r,this.stdout=n,this.stderr=i}};var z0=q(require("readline"),1);f();async function Rc(e){let{default:t}=await import("open");await t(e)}f();var q0=require("process");async function Xm(e,t){let r=["builder.config.json","fusion.config.json"],n=e.cwd(),i=!!t.local||!t.projectId,s,o={devCommand:"",workingDirectory:n,projectId:t.projectId,branchName:t.branchName,serverUrl:"",commitMode:"commits",isLocal:i,allowedCommands:["npm *","pnpm *","yarn *","yarn","git diff *","git diff","git log *","git log","git status *","git status","git add *","git commit *","git pull *","git fetch *","git merge *","echo *","cd *","rm *","find *","ls *","cp *","mv *","curl *","npx tsc *","head *","lsof *","kill *","ps *","awk *","cat *","grep *","sed *","tail *","touch *","mkdir *","npx *","env","printenv *","sleep *","netlify *"]};if(t.configJson)try{let d=JSON.parse(t.configJson);o=Object.assign({},o,d),o.projectId&&(i=!1,o.isLocal=!1)}catch(d){e.Sentry?.captureException(d)}else{for(let d of r){let h=e.join(n,d);if(await e.exists(h)){s=h;break}}if(s)try{let d=await e.readFile(s);if(d){let h=JSON.parse(d);o=Object.assign({},o,h)}}catch(d){e.Sentry?.captureException(d)}}o.command&&(o.devCommand||(o.devCommand=o.command),delete o.command);let a=t.c||t.command,c=t.p||t.port,u=t.installCommand,l=t.serverUrl,p=t.interactive&&!t.configJson&&!t.fusionInit&&i;if(l)p=!1,o.serverUrl=l,a||(o.devCommand="");else if(a&&c){p=!1;let d="http://localhost";if(o.serverUrl)try{let h=new URL(o.serverUrl);d=`${h.protocol}//${h.hostname}`}catch{d="http://localhost"}o.serverUrl=`${d}:${c}`,o.devCommand=a}if(a&&c&&(p=!1),c&&!l&&(o.serverUrl=`http://localhost:${c}`),u&&(o.setupCommand=u),a&&(o.devCommand=a),typeof t.authenticateProxy=="boolean"&&(o.authenticateProxy=t.authenticateProxy),p){if(!o.devCommand){let d=await nt({message:"Enter the command to run for the dev server (e.g. 'npm run dev')",placeholder:"npm run dev",validate:h=>{if(h.trim()===""||h.length===0)return"Command cannot be empty"}});if(ve(d))return De("Goodbye! \u{1F44B}"),await(0,q0.exit)(1);o.devCommand=d}if(!o.serverUrl){let d=await nt({message:"Enter the port number for the dev server",placeholder:"3000",validate:h=>{let m=Number(h);if(isNaN(m)||m<0||m>65535||Math.floor(m)!==m)return"Invalid port number, must be an integer between 0 and 65535"}});if(ve(d))return De("Goodbye! \u{1F44B}"),await(0,q0.exit)(1);o.serverUrl=`http://localhost:${d}`}await e.writeFile(s??e.join(n,r[0]),JSON.stringify(Iie(o,"workingDirectory","projectId","authenticateProxy"),null,2))}return o}var Iie=(e,...t)=>{let r={};if(e&&typeof e=="object")for(let n in e)(!e.hasOwnProperty||e.hasOwnProperty(n))&&(t.includes(n)||(r[n]=e[n]));return r};var t3=async(e,t,r)=>{t==="indexing"?await FR(e,r):t==="generate"||t==="gen"||t==="g"?await Q8(e,r):t==="gen"?ti("code"):await Q8(e,r)},Q8=async(e,t)=>{if(console.log(""),ze((0,pe.bgCyan)((0,pe.bold)((0,pe.white)(" code ")))+" "+(0,pe.dim)(Ce)),!Mie()&&!t.prompt){await _e("tty error",{}),B.error(`This command requires a TTY-enabled terminal.
1867
1867
  If you are using Windows Git Bash, try a different terminal or wrap the command with winpty.`),await te(1);return}await _e("figma code started",{}),t.workspace||await Kl(e,!t.prompt);let r=await yt(e,t,{forceSpaceId:t.spaceId,builderPrivateKey:!0,builderPublicKey:!0}),n,i;if(t.workspace){let y=await X8(e,t.workspace);n=y.workspace,i=y.workingDirectory}let s=await Xm(e,t),o=new Pi({sys:e,credentials:r,position:"cli",initialUrl:t.url,mode:t.mode??"quality-v3",mcpServers:t.mcpSupport||!1,fusionConfig:{...s,workingDirectory:i,workspace:n}}),a=t.prompt,c=(y,b)=>{(b.ctrl&&b.name==="c"||b.name==="escape")&&o.abort()},u,l=()=>{u&&p(),u=z0.default.createInterface({input:process.stdin,output:process.stdout}),process.stdin.isTTY&&process.stdin.setRawMode(!0),z0.default.emitKeypressEvents(process.stdin,u),process.stdin.on("keypress",c)},p=()=>{u&&(process.stdin.removeListener("keypress",c),process.stdin.isTTY&&process.stdin.setRawMode(!1),u.close(),u=void 0)},d,h;await o.initializeSession();let m="",g="";a&&await o.sendMessage({userPrompt:a,user:{source:"builder.io",userId:r.userId,role:"user"}}),await o.connectToEventLoop(!1,async y=>{switch(y.type){case"start":{if(m="",g=y.title,y.name==="tool"&&["view_path","Read"].includes(y.filePath))break;d&&(d.stop(),d=void 0),h&&(h[1](`
1868
1868
  `),h[2](),h=void 0),y.name==="text"?(h=J8(),Cs.message(h[0],{symbol:(0,pe.magenta)("~")})):(d=Fn(),d.start(y.title),d.extra(Z8));break}case"delta":{m+=y.delta,y.name==="tool"||(h?h[1](y.delta):d&&d.extra(`
1869
1869
 
@@ -1910,7 +1910,7 @@ Found several ${(0,pe.bold)("tsconfig.json")} files (${c.length}) instead:
1910
1910
  ${(0,pe.dim)(c.join(`
1911
1911
  `))}`)),u&&t&&(await _e("cli code monorepo",{}),await ir({message:"Do you want to continue anyway?",active:"Yes",inactive:"No (recommended)",initialValue:!1})!==!0)){B.info("cd into the nested project, and run the command again"),await te(1);return}e.Sentry?.setExtra("nonRootPackageJsons",i),e.Sentry?.setExtra("nonRootTsConfigs",c),e.Sentry?.setExtra("packageJson",s),e.Sentry?.setExtra("cwdDir",r)}async function n3(e){let t=await e.getRepoInfo(),r={client:"@builder.io/dev-tools",clientVersion:e.version,nodeVersion:process.version,frameworks:e.getFrameworks().map(n=>n.name),systemPlatform:process.platform,systemEOL:Qm.default.EOL,systemArch:Qm.default.arch(),inGitRepo:t.hasGit};try{let n=Qm.default.userInfo();r.systemShell=n.shell??void 0}catch{}return r}function Mie(){return process.stdout.isTTY||process.env.FORCE_TTY==="1"}function Lie(e){return e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:`${(e/(1024*1024)).toFixed(1)} MB`}f();var In=q(require("typescript"),1);function H0(e){return!(e.category!==In.DiagnosticCategory.Error||!e.file||e.code===6133||e.code===6138||e.code===6305||e.code===6196||e.code===6192||e.code===6198||e.code===6199||e.code===6205||e.code===1449||e.code===2578||e.code===7006||e.code===5074||e.code===7026||e.code===2503||e.code===2695||e.code===2322)}var s3=async(e,t)=>{let r=await n3(e);e.Sentry?.setContext("userContext",r),await _e("figma publish started",{});let n=!t.yes||!t.skipInstallation;if(n&&!process.stdout.isTTY&&process.env.FORCE_TTY!=="1")return await _e("tty error",{}),De(`This command requires a TTY-enabled terminal.
1912
1912
  see docs for more information on how to run non-interactive.
1913
- If you are using Windows Git Bash, try a different terminal or wrap the command with winpty.`),await te(1);let i=Zm(t);console.log(""),ze((0,ge.bgCyan)((0,ge.bold)((0,ge.white)(" figma publish ")))+" "+(0,ge.dim)(Te)),await Kl(e,n);let s,o,a,c,u,l;if(t.clearMappings)s=[],o=[],a=[],c=[],u=[],l=[];else{s=await qo(e);let F=await Fl({mappingFiles:s,sys:e});o=F.figmaBuilderLinks,a=F.figmaLinksToResolve,c=F.mapperFiles;let{filteredLinks:I,skippedLinks:A}=Wie(o);u=I,l=A}let{builderPrivateKey:p,builderPublicKey:d,userId:h,spaceName:m,figmaAuth:g}=await yt(e,t,{forceSpaceId:t.spaceId,builderPrivateKey:!0,builderPublicKey:!0,figmaAuth:a.length>0});if(g&&a.length>0&&await jf(e,t,g,o,a),l.length>0){if(await _e("figma publish user error",{mappingFiles:s.length,filteredLinks:u.length,skippedLinks:l.length}),t.force!==!0)return B.message(""),De(`Found some errors in the mapping files. Please fix the issues and try again, or use the ${(0,ge.bold)("--force")} flag to publish regardless.`),await te(1);B.warn("Local mappings contain some type errors, but --force flag was used, skipping.")}let y;try{y=await Is(e)}catch(F){e.Sentry?.captureException(F,{level:"warning"})}let b=m?`${(0,ge.bold)(m)} ${(0,ge.dim)("("+d+")")}`:`space id "${(0,ge.bold)(d)}"`;if(u.length===0){let F=t.clearMappings?`Clear mappings flag is set. All existing mappings will be removed from space: ${b}.`:`No mappings found. Publishing will remove all existing mapping in space: ${b}.`;B.warning(F);let I=i||t.yes||await ir({message:"Do you want to continue?",active:"Publish",inactive:"Cancel"});if(ve(I)||!I)return De("Publish cancelled."),await te(1)}else{let F=!1;for(let A of u)if(A.imports&&A.imports.length>0){let T=A.imports.filter(G=>G.importPath?.startsWith("."));T.length>0&&(F=!0,B.warn(`${(0,ge.dim)(`Found relative imports in ${A.loc}:`)}
1913
+ If you are using Windows Git Bash, try a different terminal or wrap the command with winpty.`),await te(1);let i=Zm(t);console.log(""),ze((0,ge.bgCyan)((0,ge.bold)((0,ge.white)(" figma publish ")))+" "+(0,ge.dim)(Ce)),await Kl(e,n);let s,o,a,c,u,l;if(t.clearMappings)s=[],o=[],a=[],c=[],u=[],l=[];else{s=await qo(e);let F=await Fl({mappingFiles:s,sys:e});o=F.figmaBuilderLinks,a=F.figmaLinksToResolve,c=F.mapperFiles;let{filteredLinks:I,skippedLinks:A}=Wie(o);u=I,l=A}let{builderPrivateKey:p,builderPublicKey:d,userId:h,spaceName:m,figmaAuth:g}=await yt(e,t,{forceSpaceId:t.spaceId,builderPrivateKey:!0,builderPublicKey:!0,figmaAuth:a.length>0});if(g&&a.length>0&&await jf(e,t,g,o,a),l.length>0){if(await _e("figma publish user error",{mappingFiles:s.length,filteredLinks:u.length,skippedLinks:l.length}),t.force!==!0)return B.message(""),De(`Found some errors in the mapping files. Please fix the issues and try again, or use the ${(0,ge.bold)("--force")} flag to publish regardless.`),await te(1);B.warn("Local mappings contain some type errors, but --force flag was used, skipping.")}let y;try{y=await Is(e)}catch(F){e.Sentry?.captureException(F,{level:"warning"})}let b=m?`${(0,ge.bold)(m)} ${(0,ge.dim)("("+d+")")}`:`space id "${(0,ge.bold)(d)}"`;if(u.length===0){let F=t.clearMappings?`Clear mappings flag is set. All existing mappings will be removed from space: ${b}.`:`No mappings found. Publishing will remove all existing mapping in space: ${b}.`;B.warning(F);let I=i||t.yes||await ir({message:"Do you want to continue?",active:"Publish",inactive:"Cancel"});if(ve(I)||!I)return De("Publish cancelled."),await te(1)}else{let F=!1;for(let A of u)if(A.imports&&A.imports.length>0){let T=A.imports.filter(G=>G.importPath?.startsWith("."));T.length>0&&(F=!0,B.warn(`${(0,ge.dim)(`Found relative imports in ${A.loc}:`)}
1914
1914
  ${T.map(G=>G.importPath).join("/n")}`))}F&&B.warn(`${(0,ge.yellow)(`Relative imports may break when code is generated in different projects.
1915
1915
  Instead, use one of these approaches:`)}
1916
1916
  ${(0,ge.dim)("\u2022")} Package imports ${(0,ge.dim)('(e.g. import { Button } from "@your-org/components")')}
@@ -2154,7 +2154,7 @@ Please set the BUILDER_PUBLIC_KEY environment variable.`);return{figmaAuth:a,bui
2154
2154
  `+a+`
2155
2155
  `)}else(0,kr.writeFileSync)(s,a+`
2156
2156
  `)}}function W0(e){let t=(0,fn.join)(e.getAppRootDir(),".config","builderio","data.json"),r=[(0,fn.join)(e.getAppRootDir(),"node_modules",".builder","data.json"),t,(0,fn.join)(e.getRepoRootDir(),".git",".builder.json")];for(let n of r)if((0,kr.existsSync)(n))try{let i=(0,kr.readFileSync)(n,"utf8");return JSON.parse(i).credentials}catch(i){e.Sentry?.captureException(i)}return{}}async function l3(e){let t,r,n,i=new Promise((p,d)=>{t=p,r=d}),s=e.initialPort,o=0,a=(0,o3.createServer)((p,d)=>e.requestListener(s,p,d,t,r)),c=()=>{u(),a&&("closeAllConnections"in a&&a.closeAllConnections(),a.close(p=>{p&&e.sys.Sentry?.captureException(p)}))};process.on("uncaughtExceptionMonitor",c),process.on("unhandledRejection",c),process.on("SIGINT",c),process.on("SIGTERM",c),process.on("exit",c);let u=()=>{process.removeListener("uncaughtExceptionMonitor",c),process.removeListener("unhandledRejection",c),process.removeListener("SIGINT",c),process.removeListener("SIGTERM",c),process.removeListener("exit",c)},l=()=>new Promise((p,d)=>{let h=m=>{a.removeListener("error",h),m.code==="EADDRINUSE"&&o<V0?(B.warning(`Port ${s} is already in use, trying next port`),s++,o++,p(0)):d(m)};a.once("error",h),a.listen(s,()=>{a.removeListener("error",h);let m=a.address();p(m.port)})});try{let p=0;for(;p===0&&o<V0;)p=await l();if(p===0)throw new Error(`Failed to find an available port after ${V0} attempts`);let d=e.onListen(p);B.warn(`Required authenticating with ${e.name}
2157
- OPEN: ${(0,Zs.dim)(d)}`),n=Fn(),n.start(`Waiting for ${e.name} authentication`),await Rc(d);let h=await i;return n&&n.stop(`Authenticated with ${e.name} successfully`),h}catch(p){throw n&&(n.stop(`Failed to authenticate with ${e.name}.`,-1),ti("auth")),e.sys.Sentry?.captureException(p),c(),p}finally{c()}}var Et=q(vt(),1),Oc=require("path");var tse="https://cdn.builder.io",d3=async(e,t)=>{console.log(""),ze((0,Et.bgCyan)((0,Et.bold)((0,Et.white)(" figma migrate ")))+" "+(0,Et.dim)(Te));let{builderPrivateKey:r,builderPublicKey:n}=await yt(e,t,{forceSpaceId:t.spaceId,builderPrivateKey:!0,builderPublicKey:!0});await _e("figma publish started",{spaceId:n});let i=await qo(e);if(i.length>0){await _e("figma migrate with existing files",{spaceId:n}),B.warning(`${(0,Et.yellow)("This repo already has figma mappings in:")}
2157
+ OPEN: ${(0,Zs.dim)(d)}`),n=Fn(),n.start(`Waiting for ${e.name} authentication`),await Rc(d);let h=await i;return n&&n.stop(`Authenticated with ${e.name} successfully`),h}catch(p){throw n&&(n.stop(`Failed to authenticate with ${e.name}.`,-1),ti("auth")),e.sys.Sentry?.captureException(p),c(),p}finally{c()}}var Et=q(vt(),1),Oc=require("path");var tse="https://cdn.builder.io",d3=async(e,t)=>{console.log(""),ze((0,Et.bgCyan)((0,Et.bold)((0,Et.white)(" figma migrate ")))+" "+(0,Et.dim)(Ce));let{builderPrivateKey:r,builderPublicKey:n}=await yt(e,t,{forceSpaceId:t.spaceId,builderPrivateKey:!0,builderPublicKey:!0});await _e("figma publish started",{spaceId:n});let i=await qo(e);if(i.length>0){await _e("figma migrate with existing files",{spaceId:n}),B.warning(`${(0,Et.yellow)("This repo already has figma mappings in:")}
2158
2158
 
2159
2159
  ${i.map(u=>` - ${(0,Oc.relative)(e.getAppRootDir(),u)}`).join(`
2160
2160
  `)}
@@ -2173,7 +2173,7 @@ Migration is going to create new files, possibly duplicates.`);let c=await ir({m
2173
2173
  ${o}
2174
2174
 
2175
2175
  ${s}`,"typescript",void 0)}function p3(e){let{importName:t,importPath:r}=e,n="importType"in e?e.importType:e.exportType;if(t&&r){let i=JSON.stringify(r);return n==="named"?`import { ${t} } from ${i};`:`import ${t} from ${i};`}return""}f();var rh=q(require("prompts"),1),Mc=q(require("fs"),1);var le=q(vt(),1),h3=require("path");var Wl=q(m3(),1);function ose(e){try{return new URL(e),!0}catch{return!1}}var g3=async(e,t)=>{let r=await j0(e);e.Sentry?.setContext("userContext",r);let n=!t.componentName||!t.mappingOutput||!t.skipInstallation;if(n&&!process.stdout.isTTY&&process.env.FORCE_TTY!=="1")return await _e("tty error",{}),De(`This command requires a TTY-enabled terminal.
2176
- If you are using Windows Git Bash, try a different terminal or wrap the command with winpty.`),await te(1);if(console.log(""),ze((0,le.bgMagenta)((0,le.bold)((0,le.white)(" figma generate ")))+" "+(0,le.dim)(Te)),B.message((0,le.dim)(`This command will help you create new mapper files to connect Figma components to your code components.
2176
+ If you are using Windows Git Bash, try a different terminal or wrap the command with winpty.`),await te(1);if(console.log(""),ze((0,le.bgMagenta)((0,le.bold)((0,le.white)(" figma generate ")))+" "+(0,le.dim)(Ce)),B.message((0,le.dim)(`This command will help you create new mapper files to connect Figma components to your code components.
2177
2177
  Check out `)+(0,le.bold)((0,le.cyan)("https://www.builder.io/c/docs/cli-mapping"))+(0,le.dim)(" for more details.")),t.componentName&&!t.mappingOutput)return B.error("Mapping output must be provided when mapping a single component"),await te(1);if(typeof t.mappingOutput=="string"&&!dr(t.mappingOutput))return B.error("Mapping output must end with .mapper.{tsx, ts, jsx, js, mjs}, e.g. my-component.mapper.tsx"),await te(1);await Kl(e,n);let i;i=Fn(),i.start("Loading type information");let s;try{s=await Is(e)}catch(b){return e.Sentry?.captureException(b),i.stop("Repo's framework is not supported"),await _e("figma generate, framework not supported",{frameworks:e.getFrameworks().map(v=>v.name)}),i.message(`We can not generate mappers automatically, but it's possible to do it manually:
2178
2178
  https://www.builder.io/c/docs/mapping-functions`),await te(1)}let o=[],a;if(t.token)B.message(),a=await yt(e,t,{}),o=await w2(a,t.token,!!t.verbose);else{i&&(i.stop("Component metadata processed"),i=void 0);let b=t._.slice(2);if(!b.length)return De(`No Figma URL provided, use:
2179
2179
  npx builder.io figma generate "https://..."`),ti(),await te(1);if(a=await yt(e,t,{builderPrivateKey:!0,builderPublicKey:!0,figmaAuth:S2(b),forceSpaceId:t.spaceId}),!a.builderPrivateKey||!a.builderPublicKey)return De("Missing builder.io credentials"),await te(1);let v=await u3(a.builderPublicKey,a.builderPrivateKey),C=await J0({privateKey:a.builderPrivateKey,spaceId:a.builderPublicKey});if(!v.features?.includes("component-mapping")&&C.length===0)return De("Component mapping is an enterprise feature. Please visit "+(0,le.bold)((0,le.cyan)("https://www.builder.io/unlock-enterprise"))+" to start your trial."),await te(1);i=Fn(),i.start("Gathering Figma component info"),o=await T2(e,t,a.figmaAuth,{privateKey:a.builderPrivateKey,spaceId:a.builderPublicKey},b)}await _e("figma generate started",{spaceId:a.builderPublicKey,mode:t.componentName?"non-interactive":"interactive"});let c=zu(Ba),u,l,p=await s.getRegistry({readAllInputTypes:!0});i&&(i.stop("Figma's component metadata loaded"),i=void 0),B.message();let d=await qo(e),{figmaBuilderLinks:h,figmaLinksToResolve:m}=await Fl({sys:e,mappingFiles:d});m.length>0&&a.figmaAuth&&await jf(e,t,a.figmaAuth,h,m);let g=await cse(o,h);o=o.filter(([,b])=>g.includes(b.key));let y=[];for(let b=0;b<o.length;b++){let[v,C]=o[b];b>0&&B.info(`Mapped ${b} / ${o.length} components:
@@ -3865,12 +3865,12 @@ ${i.jsx}
3865
3865
  `);return t.length===0?"":`
3866
3866
  This component has the following variants:
3867
3867
 
3868
- ${t}`}var C3=async(e,t)=>{console.log(""),ze((0,eo.bgCyan)((0,eo.bold)((0,eo.white)(" figma report ")))+" "+(0,eo.dim)(Te));let{figmaAuth:r}=await yt(e,t,{figmaAuth:!0}),n=b=>{(t.debug||t.verbose)&&(typeof b!="string"&&(b=JSON.stringify(b,null,2)),B.info(b))},i={sys:e,args:t,debug:n,figmaAuth:r};if(!t.url)throw new Error("Please provide a Figma team or file URL using the --url flag");let{teamId:s,fileKey:o,nodeId:a}=Dse(t.url);if(n({teamId:s,fileKey:o,nodeId:a}),!s&&!o)throw new Error("Invalid Figma URL. Expected format: https://www.figma.com/files/team/{team_id}/... or https://www.figma.com/file/{file_key}/...");let c=Nr.join(process.cwd(),"figma-components");if(await Rr.access(c).then(()=>!0).catch(()=>!1)){let b=await ir({message:`Directory ${c} exists. Would you like to merge with existing files?`,initialValue:!0});ve(b)?process.exit(1):b?B.info("Will merge with existing directory"):(B.info("Removing existing directory and starting fresh"),await Rr.rm(c,{recursive:!0,force:!0}))}await Rr.mkdir(c,{recursive:!0}),await Rr.writeFile(Nr.join(c,"MAPPING_GUIDE.md"),D3,"utf-8"),await Rr.writeFile(Nr.join(c,"MAP_VUE.md"),b3,"utf-8"),await Rr.writeFile(Nr.join(c,"MAP_ANGULAR.md"),x3,"utf-8"),await Rr.writeFile(Nr.join(c,"MAP_REACT.md"),v3,"utf-8");let u,l=new Set,p=Fn();if(p.start(),s){let b=0,v=()=>{b++,p.message(`Fetching team components (this may take a while) [${b}/??]`)};u=await Promise.all([Cse(i,s,v),Ese(i,s,v)]).then(([C,x])=>[...C,...x])}else if(o)p.start("Fetching file components"),{fileComponents:u,remoteKeys:l}=await wse(i,o,a);else throw new Error("Neither team ID nor file key could be extracted from URL");if(p.stop(`Fetched ${u.length} components`),l.size>0){p.start("Fetching remote component data");let b=await Ase(i,l);p.stop(`Fetched ${b.length} remote components`),u.push(...b.filter(v=>v!==void 0))}p.start("Resolving component data");let d=await Pse(i,u);p.stop(`Resolved ${d.length} components`);let h=[],m=[];d=d.filter(b=>Ose(b.componentData)?(h.push(b),!1):Rse(b)?(m.push(b),!1):!0),await Promise.all(d.map(b=>_se(b,c)));let g={components:d.map(b=>({name:b.name,key:b.key,dir:Nr.relative(c,Nr.join(c,ny(b.name)))}))};await Rr.writeFile(Nr.join(c,"index.json"),JSON.stringify(g,null,2),"utf-8");let y=h.length+m.length;B.info(`
3868
+ ${t}`}var C3=async(e,t)=>{console.log(""),ze((0,eo.bgCyan)((0,eo.bold)((0,eo.white)(" figma report ")))+" "+(0,eo.dim)(Ce));let{figmaAuth:r}=await yt(e,t,{figmaAuth:!0}),n=b=>{(t.debug||t.verbose)&&(typeof b!="string"&&(b=JSON.stringify(b,null,2)),B.info(b))},i={sys:e,args:t,debug:n,figmaAuth:r};if(!t.url)throw new Error("Please provide a Figma team or file URL using the --url flag");let{teamId:s,fileKey:o,nodeId:a}=Dse(t.url);if(n({teamId:s,fileKey:o,nodeId:a}),!s&&!o)throw new Error("Invalid Figma URL. Expected format: https://www.figma.com/files/team/{team_id}/... or https://www.figma.com/file/{file_key}/...");let c=Nr.join(process.cwd(),"figma-components");if(await Rr.access(c).then(()=>!0).catch(()=>!1)){let b=await ir({message:`Directory ${c} exists. Would you like to merge with existing files?`,initialValue:!0});ve(b)?process.exit(1):b?B.info("Will merge with existing directory"):(B.info("Removing existing directory and starting fresh"),await Rr.rm(c,{recursive:!0,force:!0}))}await Rr.mkdir(c,{recursive:!0}),await Rr.writeFile(Nr.join(c,"MAPPING_GUIDE.md"),D3,"utf-8"),await Rr.writeFile(Nr.join(c,"MAP_VUE.md"),b3,"utf-8"),await Rr.writeFile(Nr.join(c,"MAP_ANGULAR.md"),x3,"utf-8"),await Rr.writeFile(Nr.join(c,"MAP_REACT.md"),v3,"utf-8");let u,l=new Set,p=Fn();if(p.start(),s){let b=0,v=()=>{b++,p.message(`Fetching team components (this may take a while) [${b}/??]`)};u=await Promise.all([Cse(i,s,v),Ese(i,s,v)]).then(([C,x])=>[...C,...x])}else if(o)p.start("Fetching file components"),{fileComponents:u,remoteKeys:l}=await wse(i,o,a);else throw new Error("Neither team ID nor file key could be extracted from URL");if(p.stop(`Fetched ${u.length} components`),l.size>0){p.start("Fetching remote component data");let b=await Ase(i,l);p.stop(`Fetched ${b.length} remote components`),u.push(...b.filter(v=>v!==void 0))}p.start("Resolving component data");let d=await Pse(i,u);p.stop(`Resolved ${d.length} components`);let h=[],m=[];d=d.filter(b=>Ose(b.componentData)?(h.push(b),!1):Rse(b)?(m.push(b),!1):!0),await Promise.all(d.map(b=>_se(b,c)));let g={components:d.map(b=>({name:b.name,key:b.key,dir:Nr.relative(c,Nr.join(c,ny(b.name)))}))};await Rr.writeFile(Nr.join(c,"index.json"),JSON.stringify(g,null,2),"utf-8");let y=h.length+m.length;B.info(`
3869
3869
  Reports generated in: ${c}
3870
3870
  Processed ${d.length} components${y>0?`
3871
3871
  Skipped ${y} components
3872
3872
  - ${h.length} empty (no inputs and no JSX)
3873
- - ${m.length} hidden (name starts with _ or .)`:""}`)};function Rse(e){return e.name.startsWith("_")||e.name.startsWith(".")}function Ose(e){return e?e.inputs.length===0&&e.jsx==="":!0}var E3=async(e,t,r)=>{if(t==="migrate")await d3(e,r);else if(t==="publish"||t==="p")await s3(e,r);else if(t==="add"||t==="generate"||t==="gen"||t==="g")await g3(e,r);else if(t==="report")await C3(e,r);else if(t==="auth"){console.log(""),ze((0,kn.bgCyan)((0,kn.bold)((0,kn.white)(" figma auth ")))+" "+(0,kn.dim)(Te));let{builderPublicKey:n}=await yt(e,r,{figmaAuth:!0,builderPrivateKey:!0,builderPublicKey:!0,force:!0});await _e("figma auth",{spaceId:n}),sr((0,kn.bgGreen)((0,kn.bold)((0,kn.white)(" Done! \u{1F389} "))))}else t==="help"&&ti(r._[2])};f();function Q0(e,t){return{cwd:e,command:t[0],snippetId:t[1],path:t[2]}}f();var td=q(t$(),1),j7=q(require("http"),1),q7=q(require("net"),1),G7=q(require("@amplitude/analytics-node"),1),$n=q(vt(),1);f();var P7=q(require("stream"),1),F7=require("crypto");f();var lbe=q(s$(),1),pbe=q(kw(),1),dbe=q(Ow(),1),fbe=q(qw(),1),zw=q(A7(),1);function _7(e){let t=!1,r="2.0",n=new zw.default(e),i=new P7.default.EventEmitter,s={clients:new Map,events:new Map,methods:new Map},o=new Map([["rpc.on",d],["rpc.off",h]]);function a(x){return JSON.stringify({jsonrpc:r,id:x?.id,notification:x?.notification,result:x?.result,params:x?.params,error:x?.error})}function c(){n.on("listening",()=>{t=!0,i.emit("listening"),n.on("connection",(x,D)=>{let E=D.url||"/",S=(0,F7.randomUUID)();s.clients.set(S,x),i.emit("connection",x,S),l(x,S,E),x.on("error",F=>i.emit("socket-error",S,F)),x.on("close",()=>{s.clients.delete(S),i.emit("disconnection",S)})}),n.on("error",x=>i.emit("error",x))})}function u(x){return!!x.params&&Array.isArray(x.params)&&x.params.length>0}function l(x,D,E="/"){x.on("message",async S=>{let F={};try{S instanceof ArrayBuffer&&(F.binary=!0,S=Buffer.from(S).toString())}catch{return x.send(a({id:null,error:{code:-32700,message:"Parse error"}}))}let I;try{I=JSON.parse(S)}catch{return x.send(a({id:null,error:{code:-32700,message:"Parse error"}}))}try{let A=s;if(o.has(I.method)){let T=o.get(I.method);return x.send(T(A,I,D),F)}if(!A.methods.has(I.method))return x.send(a({id:I.id,error:{code:-32601,message:"Method not found"}}),F);try{let G=await A.methods.get(I.method)(I.params,D);return x.send(a({id:I.id,result:G||void 0}),F)}catch(T){return x.send(a({id:I.id,error:{code:-32e3,message:T?.message||"Internal error",data:T?.data}}),F)}}catch{return x.send(a({id:I?.id||null,error:{code:-32603,message:"Internal error"}}),F)}})}function p(x,D,...E){let F=[...s.clients.entries()].filter(([I])=>D.has(I)).map(([I,A])=>A);for(let I of F)I.send(a({notification:x,params:E}))}function d(x,D,E){if(!u(D))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});if(!x.events.has(D.params[0]))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});let S=D.params[0];return x.events.get(S).add(E),a({id:D.id,result:{[S]:!0}})}function h(x,D,E){if(!u(D))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});if(!x.events.has(D.params[0]))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});let S=D.params[0];return x.events.get(S).delete(E),a({id:D.id,result:{[S]:!1}})}function m(x,D,E="/"){s.methods.set(x,D)}function g(x,D){i.on(x,D)}function y(x,D="/"){let E=s;E.events.has(x)||E.events.set(x,new Set)}function b(x,D="/",...E){let S=s;if(!S.events.has(x))return;let F=S.events.get(x);p(x,F,D,...E)}async function v(x,D,E,S){n.handleUpgrade(x,D,E,F=>{t||n.emit("listening"),n.emit("connection",F,x),S&&S(F,x)})}function C(){return new Promise((x,D)=>{try{n.close(),i.emit("close"),x(null)}catch(E){D(E)}})}return c(),{on:g,event:x=>y(x),handleUpgrade:v,clients:()=>s.clients||new Map,register:(x,D)=>m(x,D),emit:(x,...D)=>b(x,"/",...D),notify:(x,D,...E)=>p(x,new Set([D]),...E),close:C}}var I7=`When debugging is required, follow these steps:
3873
+ - ${m.length} hidden (name starts with _ or .)`:""}`)};function Rse(e){return e.name.startsWith("_")||e.name.startsWith(".")}function Ose(e){return e?e.inputs.length===0&&e.jsx==="":!0}var E3=async(e,t,r)=>{if(t==="migrate")await d3(e,r);else if(t==="publish"||t==="p")await s3(e,r);else if(t==="add"||t==="generate"||t==="gen"||t==="g")await g3(e,r);else if(t==="report")await C3(e,r);else if(t==="auth"){console.log(""),ze((0,kn.bgCyan)((0,kn.bold)((0,kn.white)(" figma auth ")))+" "+(0,kn.dim)(Ce));let{builderPublicKey:n}=await yt(e,r,{figmaAuth:!0,builderPrivateKey:!0,builderPublicKey:!0,force:!0});await _e("figma auth",{spaceId:n}),sr((0,kn.bgGreen)((0,kn.bold)((0,kn.white)(" Done! \u{1F389} "))))}else t==="help"&&ti(r._[2])};f();function Q0(e,t){return{cwd:e,command:t[0],snippetId:t[1],path:t[2]}}f();var td=q(t$(),1),j7=q(require("http"),1),q7=q(require("net"),1),G7=q(require("@amplitude/analytics-node"),1),$n=q(vt(),1);f();var P7=q(require("stream"),1),F7=require("crypto");f();var lbe=q(s$(),1),pbe=q(kw(),1),dbe=q(Ow(),1),fbe=q(qw(),1),zw=q(A7(),1);function _7(e){let t=!1,r="2.0",n=new zw.default(e),i=new P7.default.EventEmitter,s={clients:new Map,events:new Map,methods:new Map},o=new Map([["rpc.on",d],["rpc.off",h]]);function a(x){return JSON.stringify({jsonrpc:r,id:x?.id,notification:x?.notification,result:x?.result,params:x?.params,error:x?.error})}function c(){n.on("listening",()=>{t=!0,i.emit("listening"),n.on("connection",(x,D)=>{let E=D.url||"/",S=(0,F7.randomUUID)();s.clients.set(S,x),i.emit("connection",x,S),l(x,S,E),x.on("error",F=>i.emit("socket-error",S,F)),x.on("close",()=>{s.clients.delete(S),i.emit("disconnection",S)})}),n.on("error",x=>i.emit("error",x))})}function u(x){return!!x.params&&Array.isArray(x.params)&&x.params.length>0}function l(x,D,E="/"){x.on("message",async S=>{let F={};try{S instanceof ArrayBuffer&&(F.binary=!0,S=Buffer.from(S).toString())}catch{return x.send(a({id:null,error:{code:-32700,message:"Parse error"}}))}let I;try{I=JSON.parse(S)}catch{return x.send(a({id:null,error:{code:-32700,message:"Parse error"}}))}try{let A=s;if(o.has(I.method)){let T=o.get(I.method);return x.send(T(A,I,D),F)}if(!A.methods.has(I.method))return x.send(a({id:I.id,error:{code:-32601,message:"Method not found"}}),F);try{let G=await A.methods.get(I.method)(I.params,D);return x.send(a({id:I.id,result:G||void 0}),F)}catch(T){return x.send(a({id:I.id,error:{code:-32e3,message:T?.message||"Internal error",data:T?.data}}),F)}}catch{return x.send(a({id:I?.id||null,error:{code:-32603,message:"Internal error"}}),F)}})}function p(x,D,...E){let F=[...s.clients.entries()].filter(([I])=>D.has(I)).map(([I,A])=>A);for(let I of F)I.send(a({notification:x,params:E}))}function d(x,D,E){if(!u(D))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});if(!x.events.has(D.params[0]))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});let S=D.params[0];return x.events.get(S).add(E),a({id:D.id,result:{[S]:!0}})}function h(x,D,E){if(!u(D))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});if(!x.events.has(D.params[0]))return a({id:D.id,error:{code:-32602,message:"Invalid params"}});let S=D.params[0];return x.events.get(S).delete(E),a({id:D.id,result:{[S]:!1}})}function m(x,D,E="/"){s.methods.set(x,D)}function g(x,D){i.on(x,D)}function y(x,D="/"){let E=s;E.events.has(x)||E.events.set(x,new Set)}function b(x,D="/",...E){let S=s;if(!S.events.has(x))return;let F=S.events.get(x);p(x,F,D,...E)}async function v(x,D,E,S){n.handleUpgrade(x,D,E,F=>{t||n.emit("listening"),n.emit("connection",F,x),S&&S(F,x)})}function C(){return new Promise((x,D)=>{try{n.close(),i.emit("close"),x(null)}catch(E){D(E)}})}return c(),{on:g,event:x=>y(x),handleUpgrade:v,clients:()=>s.clients||new Map,register:(x,D)=>m(x,D),emit:(x,...D)=>b(x,"/",...D),notify:(x,D,...E)=>p(x,new Set([D]),...E),close:C}}var I7=`When debugging is required, follow these steps:
3874
3874
 
3875
3875
  ## Gather information
3876
3876
 
@@ -3897,20 +3897,20 @@ If the solution is unreasonable or infeasible, or if any of the tests are incorr
3897
3897
 
3898
3898
  Do not hack around the problem, make the necessary changes to fix the problem if it's possible.
3899
3899
  Those could be file changes, or (dev_server_control) dev-server command changes, or proxy port changes, etc. or a combination of them.
3900
- `;f();var bs=q(require("fs"),1),Ln=q(require("fs/promises"),1),rr=q(require("path"),1);var yu=class{logIdCounter=0;initStatusLogs=[];sys;config;debug=!0;initState={isRunning:!1,isComplete:!1,success:!1,currentStep:"initial",error:void 0,repos:[]};constructor(t){this.sys=t.sys,this.config=t,this.debug=t.debug??!0}async checkout(t,r,n){try{await this.git(["checkout",t],n)}catch{return await this.git(["checkout","-b",t,r],n),!0}return await this.git(["reset","--hard",r],n),!1}async execAsync(t,r,n){return Js(r,{exec:t,cwd:n,debug:this.debug,sys:this.sys})}async git(t,r){return Js(t,{cwd:r,debug:this.debug,sys:this.sys})}async init(){let t=this.config;this.clearInitLogs(),this.initState.isRunning=!0,this.initState.isComplete=!1;let r=(t.fusionConfig.workspace?.folders??[]).filter(n=>n.branchName&&n.repoUrl&&n.name&&n.path&&n.repoName);this.debug&&console.log(`[DEBUG] Starting initialization with ${r.length} repositories`),this.addInitLog("log",`Starting initialization with ${r.length} repositories`,{step:"init"});try{if(!r.length){let n="At least one repository must be configured";throw new Error(n)}if(!t.sys){let n="DevToolsSys is required in config";throw this.addInitLog("error",n,{step:"validation",error:n}),new Error(n)}return await this.step1CheckDirectories(t,r),this.addInitLog("log","Directories checked",{step:"check-directories"}),await this.step2ConfigureGitRepositories(t,r),this.addInitLog("log","Git repositories configured",{step:"configure-git-repos"}),await this.step3ConfigureGitUser(t,r),this.addInitLog("log","Git user configured",{step:"configure-git-user"}),await this.step4StashChanges(t,r),this.addInitLog("log","Initialization completed successfully",{step:"stash-changes"}),await this.step5CollectRepoInfo(t,r),this.addInitLog("log","Repo info collected",{step:"collect-repo-info"}),this.debug&&console.log("[DEBUG] Initialization completed successfully"),this.addInitLog("complete","Initialization completed successfully",{step:"init-success",success:!0}),!0}catch(n){let i=n instanceof Error?n.message:String(n);this.debug&&console.error(`[DEBUG] Initialization failed with error: ${i}`);let s=this.initStatusLogs.some(o=>o.type==="error"&&o.step&&o.step!=="init-failed");return this.addInitLog("complete",`Initialization failed with error: ${i}`,{step:s?void 0:"init-failed",success:!1,error:i}),t.sys.Sentry?.captureException(n,{tags:{operation:"init",...t.sentryTags}}),!1}}addInitLog(t,r,n){let i={id:++this.logIdCounter,timestamp:new Date().toISOString(),type:t,message:r,...n};this.debug&&console.log(`[DEBUG] ${i.timestamp} ${i.type} ${i.message}`),this.initStatusLogs.push(i),this.initStatusLogs.length>1e3&&this.initStatusLogs.splice(0,this.initStatusLogs.length-1e3),n?.step&&(this.initState.currentStep=n.step),t==="complete"&&(this.initState.isComplete=!0,this.initState.isRunning=!1,this.initState.success=n?.success??!1,this.initState.error=n?.error),t==="error"&&n?.error&&(this.initState.error=n.error)}clearInitLogs(){this.initStatusLogs.length=0,this.logIdCounter=0,this.initState.isRunning=!1,this.initState.isComplete=!1,this.initState.success=!1,this.initState.currentStep="initial",this.initState.error=void 0}async hasFilesButNoGit(t){if(bs.existsSync(t))try{let n=(await Ln.readdir(t)).length>0,i=bs.existsSync(rr.join(t,".git"));return n&&!i}catch{return!1}return!1}async step1CheckDirectories(t,r){this.debug&&console.log("[DEBUG] Checking directories"),this.addInitLog("log","Checking directories",{step:"check-directories"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");if(!bs.existsSync(n)){let i=`Volume directory ${n} does not exist`;throw this.addInitLog("error",i,{step:"check-directories",error:i}),new Error(i)}this.addInitLog("log",`Volume directory exists: ${n}`,{step:"check-directories"});for(let i of r){let s=rr.join(n,i.path);if(bs.existsSync(s))this.addInitLog("log",`Directory already exists: ${s}`,{step:"check-directories"});else{this.debug&&console.log(`[DEBUG] Creating directory: ${s}`),this.addInitLog("log",`Creating directory: ${s}`,{step:"create-directories"});try{await Ln.mkdir(s,{recursive:!0})}catch(o){let a=`Failed to create directory for ${i.repoName} at ${s}: ${o}`;throw this.addInitLog("error",a,{step:"create-directories",error:a}),new Error(a,{cause:o})}}}}async step2ConfigureGitRepositories(t,r){this.addInitLog("log","Configuring git repositories",{step:"configure-git-repos"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??"."),i=rr.join(n,"/temp-cloning"),s=async()=>{bs.existsSync(i)&&(this.addInitLog("log",`Removing temp cloning directory: ${i}`,{step:"configure-git-repos"}),await Ln.rm(i,{recursive:!0,force:!0}))};await s(),this.addInitLog("log",`Creating temp cloning path: ${i}`,{step:"configure-git-repos"}),await Ln.mkdir(i,{recursive:!0});try{for(let o of r){let a=rr.join(n,o.path);if(this.addInitLog("log",`Processing repository: ${o.repoName}`,{step:"configure-git-repos"}),await this.isGitConfigured(a)){await this.cleanupLockFiles(a,o.repoName,t);try{o.enableGit?(this.addInitLog("log",`Git already configured for ${o.repoName}, validating repo`,{step:"check-existing-git"}),await this.validateGitRepo(a)):this.addInitLog("log",`Git already configured for ${o.repoName}, skipping validation because it's not main repo`,{step:"check-existing-git"})}catch(l){let p=`Failed to validate git repo for ${o.repoName}: ${l}`;throw this.addInitLog("error",p,{step:"check-existing-git",error:p}),l}this.addInitLog("log","Git repo is in good state, checking remote URL",{step:"check-existing-git"});let u=await this.getGitRemoteUrl(a);if(u){let l=this.sanitizeGitRemoteUrl(u),p=this.sanitizeGitRemoteUrl(o.repoUrl);if(l!==p){this.addInitLog("log",`Updating remote URL for ${o.repoName}`,{step:"update-remote-url"});try{await this.git(["remote","set-url","origin",o.repoUrl],a)}catch(d){let h=`Failed to update git remote URL for ${o.repoName}: ${d}`;throw this.addInitLog("error",h,{step:"update-remote-url",error:h}),new Error(h)}}}else{this.addInitLog("log",`Adding remote origin for ${o.repoName}`,{step:"check-existing-git"});try{await this.git(["remote","add","origin",o.repoUrl],a)}catch(l){let p=`Failed to add git remote origin for ${o.repoName}: ${l}`;throw this.addInitLog("error",p,{step:"check-existing-git",error:p}),new Error(p)}}}else{if(await this.hasFilesButNoGit(a)){let h="Code directory already exists but is not a git repo";throw this.addInitLog("error",h,{step:"check-existing-git",error:h}),new Error(h)}this.addInitLog("log",`Cloning repository: ${o.repoName}`,{step:"clone-repo"});let l=o.backupMetadata?await E8(t.sys,o.backupMetadata):void 0;if(l&&!l.success)throw this.addInitLog("error",`Failed to download backup for ${o.repoName}: ${l.error}`,{step:"clone-repo",error:l.error.message}),l.error;let p=rr.join(i,o.path);if(await this.cloneRepository({repo:o,repoPath:p,backupResult:l,config:t}))this.addInitLog("log",`Successfully cloned ${o.repoName}`,{step:"clone-repo"});else{let h=`Failed to clone repository ${o.repoName}`;throw this.addInitLog("error",h,{step:"clone-repo",error:h}),new Error(h)}if(l&&l.success&&l.partial)try{await this.restoreFromPartialBackup({repo:o,repoPath:p,backupResult:l})}catch(h){throw h}await Ln.rename(p,a)}}}catch(o){throw console.log(`[DEBUG] Error in step2ConfigureGitRepositories: ${o}`),this.addInitLog("error",`Failed to configure git repositories: ${o}`,{step:"configure-git-repos",error:String(o)}),o}finally{await s()}}async step3ConfigureGitUser(t,r){this.debug&&console.log("[DEBUG] Configuring git user"),this.addInitLog("log","Configuring git user",{step:"configure-git-user"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");for(let i of r){let s=rr.join(n,i.path);this.addInitLog("log",`Setting git user for ${i.repoName}`,{step:"configure-git-user"});try{await this.git(["config","user.email","builder-bot@builder.io"],s),await this.git(["config","user.name","Builder.io"],s)}catch(o){let a=`Failed to configure git user for ${i.repoName}: ${o}`;throw this.addInitLog("error",a,{step:"configure-git-user",error:a}),new Error(a)}}}async step4StashChanges(t,r){this.debug&&console.log("[DEBUG] Stashing changes"),this.addInitLog("log","Stashing changes",{step:"stash-changes"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");for(let i of r){if(!i.enableGit)continue;let s=rr.join(n,i.path);try{this.addInitLog("log",`Stashing changes for ${i.repoName}`,{step:"stash-changes"}),await this.git(["stash","--include-untracked"],s),this.addInitLog("log",`Successfully stashed changes for ${i.repoName}`,{step:"stash-changes"})}catch(o){this.debug&&console.log(`[DEBUG] Stash failed for ${i.repoName} (likely no changes)`),this.addInitLog("log",`No changes to stash for ${i.repoName}`,{step:"stash-changes"}),t.sys.Sentry?.captureException(o,{tags:{operation:"init",...t.sentryTags}})}}}async step5CollectRepoInfo(t,r){this.debug&&console.log("[DEBUG] Collecting repo info"),this.addInitLog("log","Collecting repo info",{step:"collect-repo-info"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");this.initState.repos=[];for(let i of r){let s=rr.join(n,i.path);try{let o=await this.git(["rev-parse","HEAD"],s),a=await this.git(["branch","--show-current"],s);this.initState.repos.push({repoName:i.repoName,enabledGit:!!i.enableGit,lastCommitHash:o.trim(),branch:a.trim()})}catch(o){t.sys.Sentry?.captureException(o,{tags:{operation:"init",...t.sentryTags}})}}}async isGitConfigured(t){try{return await this.git(["rev-parse","--is-inside-work-tree"],t),!0}catch{return!1}}async getGitRemoteUrl(t){try{return(await this.git(["config","--get","remote.origin.url"],t)).trim()}catch{return null}}sanitizeGitRemoteUrl(t){return t.replace(/https:\/\/[^@]+@/,"https://")}async cleanupLockFiles(t,r,n){let i=rr.join(t,".git");try{let o=(await Ln.readdir(i)).filter(c=>c.endsWith(".lock"));if(o.length===0)return;let a=[];for(let c of o){let u=rr.join(i,c);try{await Ln.unlink(u),a.push(c)}catch(l){n.sys.Sentry?.captureException(new Error(`Failed to remove ${c} for ${r}: ${l}`),{tags:{operation:"init",...n.sentryTags}})}}a.length>0&&n.sys.Sentry?.captureMessage(`Lock files found for ${r} and removed: ${a.join(", ")}`,{tags:{operation:"init",...n.sentryTags}})}catch(s){n.sys.Sentry?.captureException(new Error(`Failed to cleanup lock files for ${r}: ${s}`),{tags:{operation:"init",...n.sentryTags}})}}async validateGitRepo(t){try{await this.git(["fsck","--connectivity-only"],t)}catch(r){throw new Error("Git repo is in bad state",{cause:r})}}async restoreFromPartialBackup({repo:t,repoPath:r,backupResult:n}){try{this.addInitLog("log",`Checking for git backup for ${t.repoName}`,{step:"apply-partial-backup"});let i=async()=>{try{await this.git(["remote","remove","backup"],r)}catch(s){this.addInitLog("error",`Failed to cleanup restore: ${s}`,{step:"apply-partial-backup",error:String(s)})}};if(!n.bundlePath){try{this.addInitLog("log",`Found empty git backup, applying it to ${t.repoName}`,{step:"apply-partial-backup"}),await this.checkout(n.gitBranchName,n.lastCommitHash,r)}catch(s){throw this.addInitLog("error",`Failed to checkout backup branch: ${s}`,{step:"apply-partial-backup",error:String(s)}),s}return}try{this.addInitLog("log",`Found git backup, applying it to ${t.repoName}`,{step:"apply-partial-backup"}),await this.git(["remote","add","backup",n.bundlePath],r),await this.git(["fetch","backup"],r);let s=n.gitBranchName;await this.checkout(s,`backup/${s}`,r),this.addInitLog("log",`Successfully restored from backup to branch ${s}`,{step:"apply-partial-backup"}),await i(),this.addInitLog("log",`Cleaned up backup for ${t.repoName}`,{step:"apply-partial-backup"})}catch(s){throw await i(),this.addInitLog("error",String(s),{step:"apply-partial-backup",error:String(s)}),s}}catch(i){let s=new Error(`Failed to check git backup for ${t.repoName}. Cannot proceed without backup recovery.`,{cause:i});throw this.addInitLog("error",s.message,{step:"apply-partial-backup",error:String(i)}),s}}async cloneRepository({repo:t,repoPath:r,backupResult:n,config:i}){let s=[t.branchName??"main",null,"main","master"];if(n&&n.success&&!n.partial){if(!n.bundlePath)throw new Error("Full backups must have a bundle path");this.addInitLog("log",`Downloaded full git backup, cloning it to ${r}`,{step:"clone-repo"});try{await this.git(["clone",n.bundlePath,r]);for(let c of s)if(c)try{await this.git(["checkout",c],r)}catch{continue}await this.checkout(n.gitBranchName,n.lastCommitHash,r);let o=(await this.git(["branch","--show-current"],r)).trim(),a=(await this.git(["rev-parse","HEAD"],r)).trim();if(o!==n.gitBranchName)throw new Error(`Backup branch ${n.gitBranchName} does not match local branch ${o}`);if(a!==n.lastCommitHash)throw new Error(`Backup commit hash ${n.lastCommitHash} does not match local commit hash ${a}`);return!0}catch(o){throw this.addInitLog("error",`Failed to clone git backup for ${t.repoName}: ${o}`,{step:"clone-repo",error:String(o)}),o}}for(let o of s)try{if(bs.existsSync("/template")&&t.repoName===XD)return this.addInitLog("log",`Starting copy of template to ${r}`,{step:"clone-repo"}),this.debug&&console.log("[DEBUG] Copying from template instead of cloning"),await this.execAsync("rm",["-rf",r],"/"),await this.execAsync("cp",["-a","/template",r],"/"),this.addInitLog("log",`Copied from template for ${t.repoName}`,{step:"clone-repo"}),!0;{let a=["clone"];return o&&a.push("-b",o),a.push(t.repoUrl,r),this.debug&&console.log(`[DEBUG] Cloning with branch: ${o||"default"}`),await this.git(a),JD.includes(t.repoName)&&(await bs.rmSync(rr.join(r,".git"),{recursive:!0,force:!0}),await this.git(["init"],r),await this.git(["add","."],r),await this.git(["branch","-M","main"],r),await this.git(["commit","-m","Initial setup"],r),this.addInitLog("log",`Cleared git history for ${t.repoName}`,{step:"clone-repo"})),!0}}catch(a){this.debug&&console.log(`[DEBUG] Clone failed for branch ${o||"default"}: ${a}`),this.addInitLog("error",`Clone failed for branch ${o||"default"}: ${a}`,{step:"clone-repo",error:String(a)});continue}return!1}};f();var k7=q(require("@sentry/node"),1),N7=q(require("@amplitude/analytics-node"),1),Cg=async()=>{await Promise.allSettled([k7.flush(),N7.flush().promise]),process.exit(0)};function R7(){process.on("SIGINT",Cg),process.on("SIGTERM",Cg)}function O7(){process.removeListener("SIGINT",Cg),process.removeListener("SIGTERM",Cg)}f();var po=q(require("os"),1);function B7(e,t,r,n){let i=null,s=async()=>{try{let o=new URL(`${Fe}/projects/machine-status`);t.builderPublicKey&&o.searchParams.set("apiKey",t.builderPublicKey),t.userId&&o.searchParams.set("userId",t.userId);let a=XO(),c;a&&r.machine?c={...r.machine,environment:"remote"}:a||(c={cpus:po.cpus().length,memory:Math.round(po.totalmem()/(1024*1024*1024)),platform:po.platform(),arch:po.arch(),environment:"local"});let u={status:"ok",state:n.state,setupState:n.setupState,devState:n.devState,editorReady:n.editorReady,httpServerState:n.httpServerState,initState:n.initState,errorMessage:n.errorMessage,devToolsVersion:n.devToolsVersion,idleTime:performance.now()-n.lastRequestTime,upTime:performance.now()-n.startTime,machine:c,projectId:r.projectId},l={"Content-Type":"application/json"};t.builderPrivateKey&&(l.Authorization=`Bearer ${t.builderPrivateKey}`),await he(o,{method:"POST",body:JSON.stringify(u),headers:l,keepalive:!0})}catch(o){e.Sentry?.captureException(new Error("Failed to ping fusion status",{cause:o}))}};return{start:()=>{if(i)return;s();let o=60*1e3;i=setInterval(s,o)},stop:()=>{i&&(clearInterval(i),i=null)}}}f();var xs=require("fs"),L7=require("fs/promises");f();async function M7(e,t,r){try{let n=new URL(`${Fe}/projects/metrics`);t.builderPublicKey&&n.searchParams.set("apiKey",t.builderPublicKey),t.userId&&n.searchParams.set("userId",t.userId);let i={"Content-Type":"application/json"};t.builderPrivateKey&&(i.Authorization=`Bearer ${t.builderPrivateKey}`),await he(n,{method:"POST",body:JSON.stringify(r),headers:i,keepalive:!0})}catch(n){e.Sentry?.captureException(new Error("Failed to push metrics",{cause:n}))}}var Eg="/app-backup-test",Hw="/app/.mark",Kw={operation:"dry-run-backup-git",dryRunBackupGit:"true"},$7=async(e,t)=>{let r=await hbe(e,t);return r&&(r.success?B.success("\u2705 Dry run backup git succeeded"):(B.error(`\u274C Dry run backup git failed: ${r.error}`),e.sys.Sentry?.captureException(new Error(`Attempted dry run backup failed: ${r.error}`),{tags:Kw})),M7(e.sys,e.credentials,{counters:[{key:"projects_backup_dry_run_ended",value:1,attributes:{outcome:r.success?"success":r.error??"unknown",version:Te}}]}),r)},hbe=async({sys:e,fusionConfig:t,credentials:r},n)=>{function i(s){let o=t.workspace?.folders.find(u=>u.backupMetadata)?.backupMetadata?.check,a=n.repos.find(u=>u.enabledGit),c=s.initState.repos.find(u=>u.enabledGit);return JSON.stringify({backupCheck:o,mainRepo:a,backupMainRepo:c},null,2)}try{let s=process.env.FLY_MACHINE_ID??"unknown";if((0,xs.existsSync)(Hw)&&(0,xs.readFileSync)(Hw,"utf8")===s)return null;if((0,xs.writeFileSync)(Hw,s),B.info("Attempting dry run backup git"),n.currentStep!=="init-success")return{success:!1,error:"main-init-failed"};(0,xs.existsSync)(Eg)&&await(0,L7.rm)(Eg,{recursive:!0,force:!0}),await(0,xs.mkdirSync)(Eg,{recursive:!0});let o=new yu({sys:e,fusionConfig:{...t,_attemptDryRunBackupGit:!1,workingDirectory:Eg},debug:!0,credentials:r,sentryTags:Kw}),a=await o.init(),c=i(o);if(!a)return console.error(`\u274C Backup failed: ${o.initState.currentStep}
3900
+ `;f();var bs=q(require("fs"),1),Ln=q(require("fs/promises"),1),rr=q(require("path"),1);var yu=class{logIdCounter=0;initStatusLogs=[];sys;config;debug=!0;initState={isRunning:!1,isComplete:!1,success:!1,currentStep:"initial",error:void 0,repos:[]};constructor(t){this.sys=t.sys,this.config=t,this.debug=t.debug??!0}async checkout(t,r,n){try{await this.git(["checkout",t],n)}catch{return await this.git(["checkout","-b",t,r],n),!0}return await this.git(["reset","--hard",r],n),!1}async execAsync(t,r,n){return Js(r,{exec:t,cwd:n,debug:this.debug,sys:this.sys})}async git(t,r){return Js(t,{cwd:r,debug:this.debug,sys:this.sys})}async init(){let t=this.config;this.clearInitLogs(),this.initState.isRunning=!0,this.initState.isComplete=!1;let r=(t.fusionConfig.workspace?.folders??[]).filter(n=>n.branchName&&n.repoUrl&&n.name&&n.path&&n.repoName);this.debug&&console.log(`[DEBUG] Starting initialization with ${r.length} repositories`),this.addInitLog("log",`Starting initialization with ${r.length} repositories`,{step:"init"});try{if(!r.length){let n="At least one repository must be configured";throw new Error(n)}if(!t.sys){let n="DevToolsSys is required in config";throw this.addInitLog("error",n,{step:"validation",error:n}),new Error(n)}return await this.step1CheckDirectories(t,r),this.addInitLog("log","Directories checked",{step:"check-directories"}),await this.step2ConfigureGitRepositories(t,r),this.addInitLog("log","Git repositories configured",{step:"configure-git-repos"}),await this.step3ConfigureGitUser(t,r),this.addInitLog("log","Git user configured",{step:"configure-git-user"}),await this.step4StashChanges(t,r),this.addInitLog("log","Initialization completed successfully",{step:"stash-changes"}),await this.step5CollectRepoInfo(t,r),this.addInitLog("log","Repo info collected",{step:"collect-repo-info"}),this.debug&&console.log("[DEBUG] Initialization completed successfully"),this.addInitLog("complete","Initialization completed successfully",{step:"init-success",success:!0}),!0}catch(n){let i=n instanceof Error?n.message:String(n);this.debug&&console.error(`[DEBUG] Initialization failed with error: ${i}`);let s=this.initStatusLogs.some(o=>o.type==="error"&&o.step&&o.step!=="init-failed");return this.addInitLog("complete",`Initialization failed with error: ${i}`,{step:s?void 0:"init-failed",success:!1,error:i}),t.sys.Sentry?.captureException(n,{tags:{operation:"init",...t.sentryTags}}),!1}}addInitLog(t,r,n){let i={id:++this.logIdCounter,timestamp:new Date().toISOString(),type:t,message:r,...n};this.debug&&console.log(`[DEBUG] ${i.timestamp} ${i.type} ${i.message}`),this.initStatusLogs.push(i),this.initStatusLogs.length>1e3&&this.initStatusLogs.splice(0,this.initStatusLogs.length-1e3),n?.step&&(this.initState.currentStep=n.step),t==="complete"&&(this.initState.isComplete=!0,this.initState.isRunning=!1,this.initState.success=n?.success??!1,this.initState.error=n?.error),t==="error"&&n?.error&&(this.initState.error=n.error)}clearInitLogs(){this.initStatusLogs.length=0,this.logIdCounter=0,this.initState.isRunning=!1,this.initState.isComplete=!1,this.initState.success=!1,this.initState.currentStep="initial",this.initState.error=void 0}async hasFilesButNoGit(t){if(bs.existsSync(t))try{let n=(await Ln.readdir(t)).length>0,i=bs.existsSync(rr.join(t,".git"));return n&&!i}catch{return!1}return!1}async step1CheckDirectories(t,r){this.debug&&console.log("[DEBUG] Checking directories"),this.addInitLog("log","Checking directories",{step:"check-directories"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");if(!bs.existsSync(n)){let i=`Volume directory ${n} does not exist`;throw this.addInitLog("error",i,{step:"check-directories",error:i}),new Error(i)}this.addInitLog("log",`Volume directory exists: ${n}`,{step:"check-directories"});for(let i of r){let s=rr.join(n,i.path);if(bs.existsSync(s))this.addInitLog("log",`Directory already exists: ${s}`,{step:"check-directories"});else{this.debug&&console.log(`[DEBUG] Creating directory: ${s}`),this.addInitLog("log",`Creating directory: ${s}`,{step:"create-directories"});try{await Ln.mkdir(s,{recursive:!0})}catch(o){let a=`Failed to create directory for ${i.repoName} at ${s}: ${o}`;throw this.addInitLog("error",a,{step:"create-directories",error:a}),new Error(a,{cause:o})}}}}async step2ConfigureGitRepositories(t,r){this.addInitLog("log","Configuring git repositories",{step:"configure-git-repos"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??"."),i=rr.join(n,"/temp-cloning"),s=async()=>{bs.existsSync(i)&&(this.addInitLog("log",`Removing temp cloning directory: ${i}`,{step:"configure-git-repos"}),await Ln.rm(i,{recursive:!0,force:!0}))};await s(),this.addInitLog("log",`Creating temp cloning path: ${i}`,{step:"configure-git-repos"}),await Ln.mkdir(i,{recursive:!0});try{for(let o of r){let a=rr.join(n,o.path);if(this.addInitLog("log",`Processing repository: ${o.repoName}`,{step:"configure-git-repos"}),await this.isGitConfigured(a)){await this.cleanupLockFiles(a,o.repoName,t);try{o.enableGit?(this.addInitLog("log",`Git already configured for ${o.repoName}, validating repo`,{step:"check-existing-git"}),await this.validateGitRepo(a)):this.addInitLog("log",`Git already configured for ${o.repoName}, skipping validation because it's not main repo`,{step:"check-existing-git"})}catch(l){let p=`Failed to validate git repo for ${o.repoName}: ${l}`;throw this.addInitLog("error",p,{step:"check-existing-git",error:p}),l}this.addInitLog("log","Git repo is in good state, checking remote URL",{step:"check-existing-git"});let u=await this.getGitRemoteUrl(a);if(u){let l=this.sanitizeGitRemoteUrl(u),p=this.sanitizeGitRemoteUrl(o.repoUrl);if(l!==p){this.addInitLog("log",`Updating remote URL for ${o.repoName}`,{step:"update-remote-url"});try{await this.git(["remote","set-url","origin",o.repoUrl],a)}catch(d){let h=`Failed to update git remote URL for ${o.repoName}: ${d}`;throw this.addInitLog("error",h,{step:"update-remote-url",error:h}),new Error(h)}}}else{this.addInitLog("log",`Adding remote origin for ${o.repoName}`,{step:"check-existing-git"});try{await this.git(["remote","add","origin",o.repoUrl],a)}catch(l){let p=`Failed to add git remote origin for ${o.repoName}: ${l}`;throw this.addInitLog("error",p,{step:"check-existing-git",error:p}),new Error(p)}}}else{if(await this.hasFilesButNoGit(a)){let h="Code directory already exists but is not a git repo";throw this.addInitLog("error",h,{step:"check-existing-git",error:h}),new Error(h)}this.addInitLog("log",`Cloning repository: ${o.repoName}`,{step:"clone-repo"});let l=o.backupMetadata?await E8(t.sys,o.backupMetadata):void 0;if(l&&!l.success)throw this.addInitLog("error",`Failed to download backup for ${o.repoName}: ${l.error}`,{step:"clone-repo",error:l.error.message}),l.error;let p=rr.join(i,o.path);if(await this.cloneRepository({repo:o,repoPath:p,backupResult:l,config:t}))this.addInitLog("log",`Successfully cloned ${o.repoName}`,{step:"clone-repo"});else{let h=`Failed to clone repository ${o.repoName}`;throw this.addInitLog("error",h,{step:"clone-repo",error:h}),new Error(h)}if(l&&l.success&&l.partial)try{await this.restoreFromPartialBackup({repo:o,repoPath:p,backupResult:l})}catch(h){throw h}await Ln.rename(p,a)}}}catch(o){throw console.log(`[DEBUG] Error in step2ConfigureGitRepositories: ${o}`),this.addInitLog("error",`Failed to configure git repositories: ${o}`,{step:"configure-git-repos",error:String(o)}),o}finally{await s()}}async step3ConfigureGitUser(t,r){this.debug&&console.log("[DEBUG] Configuring git user"),this.addInitLog("log","Configuring git user",{step:"configure-git-user"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");for(let i of r){let s=rr.join(n,i.path);this.addInitLog("log",`Setting git user for ${i.repoName}`,{step:"configure-git-user"});try{await this.git(["config","user.email","builder-bot@builder.io"],s),await this.git(["config","user.name","Builder.io"],s)}catch(o){let a=`Failed to configure git user for ${i.repoName}: ${o}`;throw this.addInitLog("error",a,{step:"configure-git-user",error:a}),new Error(a)}}}async step4StashChanges(t,r){this.debug&&console.log("[DEBUG] Stashing changes"),this.addInitLog("log","Stashing changes",{step:"stash-changes"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");for(let i of r){if(!i.enableGit)continue;let s=rr.join(n,i.path);try{this.addInitLog("log",`Stashing changes for ${i.repoName}`,{step:"stash-changes"}),await this.git(["stash","--include-untracked"],s),this.addInitLog("log",`Successfully stashed changes for ${i.repoName}`,{step:"stash-changes"})}catch(o){this.debug&&console.log(`[DEBUG] Stash failed for ${i.repoName} (likely no changes)`),this.addInitLog("log",`No changes to stash for ${i.repoName}`,{step:"stash-changes"}),t.sys.Sentry?.captureException(o,{tags:{operation:"init",...t.sentryTags}})}}}async step5CollectRepoInfo(t,r){this.debug&&console.log("[DEBUG] Collecting repo info"),this.addInitLog("log","Collecting repo info",{step:"collect-repo-info"});let n=rr.resolve(process.cwd(),t.fusionConfig.workingDirectory??".");this.initState.repos=[];for(let i of r){let s=rr.join(n,i.path);try{let o=await this.git(["rev-parse","HEAD"],s),a=await this.git(["branch","--show-current"],s);this.initState.repos.push({repoName:i.repoName,enabledGit:!!i.enableGit,lastCommitHash:o.trim(),branch:a.trim()})}catch(o){t.sys.Sentry?.captureException(o,{tags:{operation:"init",...t.sentryTags}})}}}async isGitConfigured(t){try{return await this.git(["rev-parse","--is-inside-work-tree"],t),!0}catch{return!1}}async getGitRemoteUrl(t){try{return(await this.git(["config","--get","remote.origin.url"],t)).trim()}catch{return null}}sanitizeGitRemoteUrl(t){return t.replace(/https:\/\/[^@]+@/,"https://")}async cleanupLockFiles(t,r,n){let i=rr.join(t,".git");try{let o=(await Ln.readdir(i)).filter(c=>c.endsWith(".lock"));if(o.length===0)return;let a=[];for(let c of o){let u=rr.join(i,c);try{await Ln.unlink(u),a.push(c)}catch(l){n.sys.Sentry?.captureException(new Error(`Failed to remove ${c} for ${r}: ${l}`),{tags:{operation:"init",...n.sentryTags}})}}a.length>0&&n.sys.Sentry?.captureMessage(`Lock files found for ${r} and removed: ${a.join(", ")}`,{tags:{operation:"init",...n.sentryTags}})}catch(s){n.sys.Sentry?.captureException(new Error(`Failed to cleanup lock files for ${r}: ${s}`),{tags:{operation:"init",...n.sentryTags}})}}async validateGitRepo(t){try{await this.git(["fsck","--connectivity-only"],t)}catch(r){throw new Error("Git repo is in bad state",{cause:r})}}async restoreFromPartialBackup({repo:t,repoPath:r,backupResult:n}){try{this.addInitLog("log",`Checking for git backup for ${t.repoName}`,{step:"apply-partial-backup"});let i=async()=>{try{await this.git(["remote","remove","backup"],r)}catch(s){this.addInitLog("error",`Failed to cleanup restore: ${s}`,{step:"apply-partial-backup",error:String(s)})}};if(!n.bundlePath){try{this.addInitLog("log",`Found empty git backup, applying it to ${t.repoName}`,{step:"apply-partial-backup"}),await this.checkout(n.gitBranchName,n.lastCommitHash,r)}catch(s){throw this.addInitLog("error",`Failed to checkout backup branch: ${s}`,{step:"apply-partial-backup",error:String(s)}),s}return}try{this.addInitLog("log",`Found git backup, applying it to ${t.repoName}`,{step:"apply-partial-backup"}),await this.git(["remote","add","backup",n.bundlePath],r),await this.git(["fetch","backup"],r);let s=n.gitBranchName;await this.checkout(s,`backup/${s}`,r),this.addInitLog("log",`Successfully restored from backup to branch ${s}`,{step:"apply-partial-backup"}),await i(),this.addInitLog("log",`Cleaned up backup for ${t.repoName}`,{step:"apply-partial-backup"})}catch(s){throw await i(),this.addInitLog("error",String(s),{step:"apply-partial-backup",error:String(s)}),s}}catch(i){let s=new Error(`Failed to check git backup for ${t.repoName}. Cannot proceed without backup recovery.`,{cause:i});throw this.addInitLog("error",s.message,{step:"apply-partial-backup",error:String(i)}),s}}async cloneRepository({repo:t,repoPath:r,backupResult:n,config:i}){let s=[t.branchName??"main",null,"main","master"];if(n&&n.success&&!n.partial){if(!n.bundlePath)throw new Error("Full backups must have a bundle path");this.addInitLog("log",`Downloaded full git backup, cloning it to ${r}`,{step:"clone-repo"});try{await this.git(["clone",n.bundlePath,r]);for(let c of s)if(c)try{await this.git(["checkout",c],r)}catch{continue}await this.checkout(n.gitBranchName,n.lastCommitHash,r);let o=(await this.git(["branch","--show-current"],r)).trim(),a=(await this.git(["rev-parse","HEAD"],r)).trim();if(o!==n.gitBranchName)throw new Error(`Backup branch ${n.gitBranchName} does not match local branch ${o}`);if(a!==n.lastCommitHash)throw new Error(`Backup commit hash ${n.lastCommitHash} does not match local commit hash ${a}`);return!0}catch(o){throw this.addInitLog("error",`Failed to clone git backup for ${t.repoName}: ${o}`,{step:"clone-repo",error:String(o)}),o}}for(let o of s)try{if(bs.existsSync("/template")&&t.repoName===XD)return this.addInitLog("log",`Starting copy of template to ${r}`,{step:"clone-repo"}),this.debug&&console.log("[DEBUG] Copying from template instead of cloning"),await this.execAsync("rm",["-rf",r],"/"),await this.execAsync("cp",["-a","/template",r],"/"),this.addInitLog("log",`Copied from template for ${t.repoName}`,{step:"clone-repo"}),!0;{let a=["clone"];return o&&a.push("-b",o),a.push(t.repoUrl,r),this.debug&&console.log(`[DEBUG] Cloning with branch: ${o||"default"}`),await this.git(a),JD.includes(t.repoName)&&(await bs.rmSync(rr.join(r,".git"),{recursive:!0,force:!0}),await this.git(["init"],r),await this.git(["add","."],r),await this.git(["branch","-M","main"],r),await this.git(["commit","-m","Initial setup"],r),this.addInitLog("log",`Cleared git history for ${t.repoName}`,{step:"clone-repo"})),!0}}catch(a){this.debug&&console.log(`[DEBUG] Clone failed for branch ${o||"default"}: ${a}`),this.addInitLog("error",`Clone failed for branch ${o||"default"}: ${a}`,{step:"clone-repo",error:String(a)});continue}return!1}};f();var k7=q(require("@sentry/node"),1),N7=q(require("@amplitude/analytics-node"),1),Cg=async()=>{await Promise.allSettled([k7.flush(),N7.flush().promise]),process.exit(0)};function R7(){process.on("SIGINT",Cg),process.on("SIGTERM",Cg)}function O7(){process.removeListener("SIGINT",Cg),process.removeListener("SIGTERM",Cg)}f();var po=q(require("os"),1);function B7(e,t,r,n){let i=null,s=async()=>{try{let o=new URL(`${Fe}/projects/machine-status`);t.builderPublicKey&&o.searchParams.set("apiKey",t.builderPublicKey),t.userId&&o.searchParams.set("userId",t.userId);let a=XO(),c;a&&r.machine?c={...r.machine,environment:"remote"}:a||(c={cpus:po.cpus().length,memory:Math.round(po.totalmem()/(1024*1024*1024)),platform:po.platform(),arch:po.arch(),environment:"local"});let u={status:"ok",state:n.state,setupState:n.setupState,devState:n.devState,editorReady:n.editorReady,httpServerState:n.httpServerState,initState:n.initState,errorMessage:n.errorMessage,devToolsVersion:n.devToolsVersion,idleTime:performance.now()-n.lastRequestTime,upTime:performance.now()-n.startTime,machine:c,projectId:r.projectId},l={"Content-Type":"application/json"};t.builderPrivateKey&&(l.Authorization=`Bearer ${t.builderPrivateKey}`),await he(o,{method:"POST",body:JSON.stringify(u),headers:l,keepalive:!0})}catch(o){e.Sentry?.captureException(new Error("Failed to ping fusion status",{cause:o}))}};return{start:()=>{if(i)return;s();let o=60*1e3;i=setInterval(s,o)},stop:()=>{i&&(clearInterval(i),i=null)}}}f();var xs=require("fs"),L7=require("fs/promises");f();async function M7(e,t,r){try{let n=new URL(`${Fe}/projects/metrics`);t.builderPublicKey&&n.searchParams.set("apiKey",t.builderPublicKey),t.userId&&n.searchParams.set("userId",t.userId);let i={"Content-Type":"application/json"};t.builderPrivateKey&&(i.Authorization=`Bearer ${t.builderPrivateKey}`),await he(n,{method:"POST",body:JSON.stringify(r),headers:i,keepalive:!0})}catch(n){e.Sentry?.captureException(new Error("Failed to push metrics",{cause:n}))}}var Eg="/app-backup-test",Hw="/app/.mark",Kw={operation:"dry-run-backup-git",dryRunBackupGit:"true"},$7=async(e,t)=>{let r=await hbe(e,t);return r&&(r.success?B.success("\u2705 Dry run backup git succeeded"):(B.error(`\u274C Dry run backup git failed: ${r.error}`),e.sys.Sentry?.captureException(new Error(`Attempted dry run backup failed: ${r.error}`),{tags:Kw})),M7(e.sys,e.credentials,{counters:[{key:"projects_backup_dry_run_ended",value:1,attributes:{outcome:r.success?"success":r.error??"unknown",version:Ce}}]}),r)},hbe=async({sys:e,fusionConfig:t,credentials:r},n)=>{function i(s){let o=t.workspace?.folders.find(u=>u.backupMetadata)?.backupMetadata?.check,a=n.repos.find(u=>u.enabledGit),c=s.initState.repos.find(u=>u.enabledGit);return JSON.stringify({backupCheck:o,mainRepo:a,backupMainRepo:c},null,2)}try{let s=process.env.FLY_MACHINE_ID??"unknown";if((0,xs.existsSync)(Hw)&&(0,xs.readFileSync)(Hw,"utf8")===s)return null;if((0,xs.writeFileSync)(Hw,s),B.info("Attempting dry run backup git"),n.currentStep!=="init-success")return{success:!1,error:"main-init-failed"};(0,xs.existsSync)(Eg)&&await(0,L7.rm)(Eg,{recursive:!0,force:!0}),await(0,xs.mkdirSync)(Eg,{recursive:!0});let o=new yu({sys:e,fusionConfig:{...t,_attemptDryRunBackupGit:!1,workingDirectory:Eg},debug:!0,credentials:r,sentryTags:Kw}),a=await o.init(),c=i(o);if(!a)return console.error(`\u274C Backup failed: ${o.initState.currentStep}
3901
3901
  ${c}`),{success:!1,error:`backup-failed:${o.initState.currentStep}`};let u=o.initState.repos.find(d=>d.enabledGit);if(!u)return console.error(`\u274C Backup repo not found
3902
3902
  ${c}`),{success:!1,error:"backup-repo-not-found"};let l=n.repos.find(d=>d.enabledGit);if(!l)return console.error(`\u274C Main repo not found
3903
3903
  ${c}`),{success:!1,error:"main-repo-not-found"};if(u.branch!==l.branch)return console.error(`\u274C Backup branch mismatch: ${u.branch} !== ${l.branch}
3904
3904
  ${c}`),{success:!1,error:"backup-branch-mismatch"};let p=t.workspace?.folders.find(d=>d.backupMetadata)?.backupMetadata;if(p){if(u.branch!==p.check.backup.gitBranchName)return console.error(`\u274C Backup branch mismatch: ${u.branch} !== ${p.check.backup.gitBranchName}
3905
3905
  ${c}`),{success:!1,error:"backup-branch-mismatch-in-metadata"};if(u.lastCommitHash!==p.check.backup.lastCommitHash)return console.error(`\u274C Backup commit hash mismatch: ${u.lastCommitHash} !== ${p.check.backup.lastCommitHash}
3906
- ${c}`),{success:!1,error:"backup-commit-hash-mismatch-in-metadata"}}return u.lastCommitHash!==l.lastCommitHash?(console.error(`\u274C Backup commit hash mismatch: ${u.lastCommitHash} !== ${l.lastCommitHash}`),{success:!1,error:"backup-commit-hash-mismatch"}):{success:!0}}catch(s){return e.Sentry?.captureException(s,{tags:Kw}),{success:!1,error:"error"}}};var wg=48752;async function gbe(e){return new Promise(t=>{let r=q7.createServer();r.listen(e,()=>{r.once("close",()=>{t(!0)}),r.close()}),r.on("error",()=>{t(!1)})})}async function ybe(e){let t=e,r=100;for(let n=0;n<r;n++){if(await gbe(t))return t;t=Math.floor(Math.random()*16384)+49152}throw new Error(`Could not find an available port after ${r} attempts`)}function U7(e,t,r){if(e.jsonOutput){let n={type:"server_error",data:{error:t,details:r,timestamp:Date.now()}};console.log(JSON.stringify(n))}}var bu;async function z7({sys:e,args:t}){let r=process.env.FLY_APP_NAME?{flyAppName:process.env.FLY_APP_NAME,flyMachineId:process.env.FLY_MACHINE_ID,flyRegion:process.env.FLY_REGION,flyPublicIp:process.env.FLY_PUBLIC_IP,flyVmMemoryMb:process.env.FLY_VM_MEMORY_MB,flyPrimaryRegion:process.env.PRIMARY_REGION}:void 0;r&&(e.Sentry?.setContext("flyIo",r),e.Sentry?.getCurrentScope().setContext("flyIo",r)),ze((0,$n.bgCyan)((0,$n.bold)((0,$n.white)(" fusion ")))+" "+(0,$n.dim)(Te));let n=await Xm(e,t),i=await bbe(e,t,n),s=performance.now(),o="initial",a={status:"ok",get state(){return o},set state(v){o!==v&&n.projectId&&n.branchName&&zl(e,i,{projectId:n.projectId,branchName:n.branchName,lastServerState:v}),o=v},isFinalState:!1,editorReady:!1,initState:void 0,setupState:void 0,devState:void 0,httpServerState:void 0,errorMessage:void 0,devToolsVersion:e.version,lastRequestTime:s,startTime:s},c;e.Sentry?.setContext("fusionConfig",{...n}),e.Sentry?.getCurrentScope().setContext("fusionConfig",{...n});let{app:u,proxyUrl:l,server:p}=await xbe(i,n,a,e,n.isLocal||!!t.local),d=B7(e,i,n,a);d&&d.start();let h=wbe(e,n,r),m=!1,g=!1,y=!1,b=v=>async()=>{if(console.log(`\u{1F50D} Received ${v} signal`),a.state==="init-running"){console.log("\u{1F50D} Init is running, skipping"),y=!0;return}if(m){console.log("\u{1F50D} Server already closing, skipping");return}a.state="closing",m=!0,setTimeout(()=>{m=!1},1e3),console.log("\u{1F50D} Closing server gracefully");try{if(p.closeAllConnections(),h(),d&&(d.stop(),d=null),await Promise.race([new Promise(C=>p.close(C)),new Promise(C=>setTimeout(C,1e3))]),c&&(await c.close(),c=void 0),!g&&a.initState?.success){g=!0;let C=await Sg(e,i,n,c,"quality-v4",void 0,void 0,a);a.state="closing",console.log("\u{1F50D} Closing codeGenServer"),await C.close(!!n.autoBackupGit),bu=void 0}await e.Sentry?.flush(2e3),await G7.flush().promise,process.exit(0)}catch(C){e.Sentry?.captureException(C);let x=C instanceof Error?C.message:String(C);B.error(`\u274C FAILED TO CLOSE SERVER: ${x}`),process.exit(1)}};if(O7(),process.on("SIGTERM",b("SIGTERM")),process.on("SIGINT",b("SIGINT")),t.fusionInit){a.state="init-running";let v=new yu({sys:e,fusionConfig:n,debug:!0,credentials:i,sentryTags:{operation:"fusion-init"}});if(a.initState=v.initState,a.initStatusLogs=v.initStatusLogs,!await v.init()){B.error("\u274C Initialization failed"),e.Sentry?.captureException(new Error("Initialization failed"),{level:"fatal",tags:{operation:"fusion-init"},extra:{initState:v.initState}}),a.state="error",a.isFinalState=!0,a.errorMessage=v.initState.error,y&&await b("init-end")();return}if(B.success("\u2705 Initialization completed successfully"),a.state="init-complete",y){await b("init-end")();return}n._attemptDryRunBackupGit&&$7({sys:e,fusionConfig:n,debug:!0,credentials:i},v.initState).then(x=>{x&&(a._attemptDryRunBackupOutcome=x.success?"success":x.error)}).catch(x=>{e.Sentry?.captureException(x,{tags:{operation:"dry-run-backup-git",dryRunBackupGit:"true"}})})}c=await vbe(e,n,a,t),t.fusionInit&&c&&await Promise.race([c.ensureSetupCommand(),new Promise(v=>setTimeout(v,2e3))]),await Dbe({sys:e,credentials:i,args:t,fusionConfig:n,proxyUrl:l,server:p,app:u,devServer:c,sharedState:a}),await _e("launch",{...n,dev:!!t.dev})}async function bbe(e,t,r){let n;try{if(n=await yt(e,t,{builderPrivateKey:!0,builderPublicKey:!0}),!n.builderPublicKey||!n.builderPrivateKey){let i="You need to be logged in to use the fusion command.";return U7(t,i),B.error(i),De("Please login first with: npx builder.io login"),await te(1)}if(!n.timestamp&&!r.projectId){let i=await e.getDeviceId();if(i)try{let s=new URL(`${Fe}/fusion/cli-key`);s.searchParams.set("host",i),s.searchParams.set("apiKey",n.builderPublicKey);let o=await he(s.toString(),{headers:{"Content-Type":"application/json",Authorization:`Bearer ${n.builderPrivateKey}`},method:"GET"});if(!o.ok){let u=await o.text();throw new Error(`Failed to fetch original private key: ${u}`)}let c=(await o.json())?.key;c&&(n.builderPrivateKey=c,n.timestamp=new Date().toISOString(),eh(e,n))}catch(s){e.Sentry?.captureException(new Error("Failed to fetch original private key, using existing credentials",{cause:s}))}}B.success(`Logged in as space: ${n.spaceName||n.builderPublicKey}`)}catch(i){let s="Authentication failed.";return U7(t,s,i instanceof Error?i.message:String(i)),B.error(s),De("Please login first with: npx builder.io login"),await te(1)}return n}async function xbe(e,t,r,n,i){let s=!!t.isLocal,o=wg;i&&(o=await ybe(wg),o!==wg&&B.info(`\u26A0\uFE0F Port ${wg} is in use, using port ${o} instead`)),B.info(`\u{1F50D} Setting up Builder.io server on port ${o}`);let a=(0,td.default)(),c=j7.createServer(a);a.use((h,m,g)=>{s||console.log("HTTP request: ",h.url),h.query._skip_activity!=="true"?r.lastRequestTime=performance.now():B.info(`\u23F0 Request ignored at ${performance.now()}`),g()});let u=e.builderPrivateKey,l=t.authenticateProxy??!1;if(m8({app:a,validBuilderPrivateKey:u,authenticateProxy:l,isLocal:s,sharedState:r}),t?.autoBackupGit||t.autoShutdown){let y=(t.autoShutdownThresholdMinutes??60)*60,b=y*1e3,v=!1,C=setInterval(async()=>{if(performance.now()-r.lastRequestTime>b){if(v){B.info("\u23F0 Shutdown already in progress");return}B.info(`\u23F0 Threshold reached (${Math.round(y)} seconds without requests)`),v=!0;try{(await H7("inactivity-timeout",!!t.autoShutdown))?.success&&clearInterval(C)}catch(D){let E=new Error("Failed to gracefully shutdown server",{cause:D});n.Sentry?.captureException(E,{tags:{operation:"shutdown"}})}finally{v=!1}}},1e3*10);process.on("exit",()=>clearInterval(C))}let p=`http://localhost:${o}`;return await new Promise((h,m)=>{c.listen(o,async()=>{B.success(`\u{1F680} Builder.io server running at ${p}`),h(!0)})}),{app:a,proxyUrl:p,server:c,availablePort:o}}async function vbe(e,t,r,n){if(n.serverUrl&&!n.command){B.info(`Proxying to existing dev server at ${(0,$n.cyan)(t.serverUrl)}...`),r.devState="running",r.setupState="installed",r.httpServerState="ok-2xx";return}else{B.info(`Running ${(0,$n.cyan)(t.devCommand)} on host ${(0,$n.cyan)(t.serverUrl)}...`);let i=await b8(e,t,n.fusionInit?"not-installed":"installed");return r.devState=i.devState,r.setupState=i.setupState,r.httpServerState=i.httpServerState,i.emitter.on("devState",s=>{r.devState=s}),i.emitter.on("setupState",s=>{r.setupState=s}),i.emitter.on("httpServerState",s=>{r.httpServerState=s}),i}}async function Dbe({sys:e,credentials:t,args:r,fusionConfig:n,app:i,server:s,proxyUrl:o,devServer:a,sharedState:c}){try{let u=td.default.Router();u.post("/generate",async(b,v)=>{try{let{prompt:C,userMessage:x,context:{pushChanges:D,sessionId:E,commitMode:S}}=b.body;if(!C&&!x)return v.status(400).json({error:"No prompt/userMessage provided"});v.setHeader("Content-Type","text/event-stream"),v.setHeader("Cache-Control","no-cache"),v.setHeader("Connection","keep-alive");let F=await Sg(e,t,n,a,"quality-v4",E,S,c),I=F.connectToEventLoop(!1,A=>{v.write(JSON.stringify(A)+`
3906
+ ${c}`),{success:!1,error:"backup-commit-hash-mismatch-in-metadata"}}return u.lastCommitHash!==l.lastCommitHash?(console.error(`\u274C Backup commit hash mismatch: ${u.lastCommitHash} !== ${l.lastCommitHash}`),{success:!1,error:"backup-commit-hash-mismatch"}):{success:!0}}catch(s){return e.Sentry?.captureException(s,{tags:Kw}),{success:!1,error:"error"}}};var wg=48752;async function gbe(e){return new Promise(t=>{let r=q7.createServer();r.listen(e,()=>{r.once("close",()=>{t(!0)}),r.close()}),r.on("error",()=>{t(!1)})})}async function ybe(e){let t=e,r=100;for(let n=0;n<r;n++){if(await gbe(t))return t;t=Math.floor(Math.random()*16384)+49152}throw new Error(`Could not find an available port after ${r} attempts`)}function U7(e,t,r){if(e.jsonOutput){let n={type:"server_error",data:{error:t,details:r,timestamp:Date.now()}};console.log(JSON.stringify(n))}}var bu;async function z7({sys:e,args:t}){let r=process.env.FLY_APP_NAME?{flyAppName:process.env.FLY_APP_NAME,flyMachineId:process.env.FLY_MACHINE_ID,flyRegion:process.env.FLY_REGION,flyPublicIp:process.env.FLY_PUBLIC_IP,flyVmMemoryMb:process.env.FLY_VM_MEMORY_MB,flyPrimaryRegion:process.env.PRIMARY_REGION}:void 0;r&&(e.Sentry?.setContext("flyIo",r),e.Sentry?.getCurrentScope().setContext("flyIo",r)),ze((0,$n.bgCyan)((0,$n.bold)((0,$n.white)(" fusion ")))+" "+(0,$n.dim)(Ce));let n=await Xm(e,t),i=await bbe(e,t,n),s=performance.now(),o="initial",a={status:"ok",get state(){return o},set state(v){o!==v&&n.projectId&&n.branchName&&zl(e,i,{projectId:n.projectId,branchName:n.branchName,lastServerVersion:Ce,lastServerState:v}),o=v},isFinalState:!1,editorReady:!1,initState:void 0,setupState:void 0,devState:void 0,httpServerState:void 0,errorMessage:void 0,devToolsVersion:Ce,lastRequestTime:s,startTime:s},c;e.Sentry?.setContext("fusionConfig",{...n}),e.Sentry?.getCurrentScope().setContext("fusionConfig",{...n});let{app:u,proxyUrl:l,server:p}=await xbe(i,n,a,e,n.isLocal||!!t.local),d=B7(e,i,n,a);d&&d.start();let h=wbe(e,n,r),m=!1,g=!1,y=!1,b=v=>async()=>{if(console.log(`\u{1F50D} Received ${v} signal`),a.state==="init-running"){console.log("\u{1F50D} Init is running, skipping"),y=!0;return}if(m){console.log("\u{1F50D} Server already closing, skipping");return}a.state="closing",m=!0,setTimeout(()=>{m=!1},1e3),console.log("\u{1F50D} Closing server gracefully");try{if(p.closeAllConnections(),h(),d&&(d.stop(),d=null),await Promise.race([new Promise(C=>p.close(C)),new Promise(C=>setTimeout(C,1e3))]),c&&(await c.close(),c=void 0),!g&&a.initState?.success){g=!0;let C=await Sg(e,i,n,c,"quality-v4",void 0,void 0,a);a.state="closing",console.log("\u{1F50D} Closing codeGenServer"),await C.close(!!n.autoBackupGit),bu=void 0}await e.Sentry?.flush(2e3),await G7.flush().promise,process.exit(0)}catch(C){e.Sentry?.captureException(C);let x=C instanceof Error?C.message:String(C);B.error(`\u274C FAILED TO CLOSE SERVER: ${x}`),process.exit(1)}};if(O7(),process.on("SIGTERM",b("SIGTERM")),process.on("SIGINT",b("SIGINT")),t.fusionInit){a.state="init-running";let v=new yu({sys:e,fusionConfig:n,debug:!0,credentials:i,sentryTags:{operation:"fusion-init"}});if(a.initState=v.initState,a.initStatusLogs=v.initStatusLogs,!await v.init()){B.error("\u274C Initialization failed"),e.Sentry?.captureException(new Error("Initialization failed"),{level:"fatal",tags:{operation:"fusion-init"},extra:{initState:v.initState}}),a.state="error",a.isFinalState=!0,a.errorMessage=v.initState.error,y&&await b("init-end")();return}if(B.success("\u2705 Initialization completed successfully"),a.state="init-complete",y){await b("init-end")();return}n._attemptDryRunBackupGit&&$7({sys:e,fusionConfig:n,debug:!0,credentials:i},v.initState).then(x=>{x&&(a._attemptDryRunBackupOutcome=x.success?"success":x.error)}).catch(x=>{e.Sentry?.captureException(x,{tags:{operation:"dry-run-backup-git",dryRunBackupGit:"true"}})})}c=await vbe(e,n,a,t),t.fusionInit&&c&&await Promise.race([c.ensureSetupCommand(),new Promise(v=>setTimeout(v,2e3))]),await Dbe({sys:e,credentials:i,args:t,fusionConfig:n,proxyUrl:l,server:p,app:u,devServer:c,sharedState:a}),await _e("launch",{...n,dev:!!t.dev})}async function bbe(e,t,r){let n;try{if(n=await yt(e,t,{builderPrivateKey:!0,builderPublicKey:!0}),!n.builderPublicKey||!n.builderPrivateKey){let i="You need to be logged in to use the fusion command.";return U7(t,i),B.error(i),De("Please login first with: npx builder.io login"),await te(1)}if(!n.timestamp&&!r.projectId){let i=await e.getDeviceId();if(i)try{let s=new URL(`${Fe}/fusion/cli-key`);s.searchParams.set("host",i),s.searchParams.set("apiKey",n.builderPublicKey);let o=await he(s.toString(),{headers:{"Content-Type":"application/json",Authorization:`Bearer ${n.builderPrivateKey}`},method:"GET"});if(!o.ok){let u=await o.text();throw new Error(`Failed to fetch original private key: ${u}`)}let c=(await o.json())?.key;c&&(n.builderPrivateKey=c,n.timestamp=new Date().toISOString(),eh(e,n))}catch(s){e.Sentry?.captureException(new Error("Failed to fetch original private key, using existing credentials",{cause:s}))}}B.success(`Logged in as space: ${n.spaceName||n.builderPublicKey}`)}catch(i){let s="Authentication failed.";return U7(t,s,i instanceof Error?i.message:String(i)),B.error(s),De("Please login first with: npx builder.io login"),await te(1)}return n}async function xbe(e,t,r,n,i){let s=!!t.isLocal,o=wg;i&&(o=await ybe(wg),o!==wg&&B.info(`\u26A0\uFE0F Port ${wg} is in use, using port ${o} instead`)),B.info(`\u{1F50D} Setting up Builder.io server on port ${o}`);let a=(0,td.default)(),c=j7.createServer(a);a.use((h,m,g)=>{s||console.log("HTTP request: ",h.url),h.query._skip_activity!=="true"?r.lastRequestTime=performance.now():B.info(`\u23F0 Request ignored at ${performance.now()}`),g()});let u=e.builderPrivateKey,l=t.authenticateProxy??!1;if(m8({app:a,validBuilderPrivateKey:u,authenticateProxy:l,isLocal:s,sharedState:r}),t?.autoBackupGit||t.autoShutdown){let y=(t.autoShutdownThresholdMinutes??60)*60,b=y*1e3,v=!1,C=setInterval(async()=>{if(performance.now()-r.lastRequestTime>b){if(v){B.info("\u23F0 Shutdown already in progress");return}B.info(`\u23F0 Threshold reached (${Math.round(y)} seconds without requests)`),v=!0;try{(await H7("inactivity-timeout",!!t.autoShutdown))?.success&&clearInterval(C)}catch(D){let E=new Error("Failed to gracefully shutdown server",{cause:D});n.Sentry?.captureException(E,{tags:{operation:"shutdown"}})}finally{v=!1}}},1e3*10);process.on("exit",()=>clearInterval(C))}let p=`http://localhost:${o}`;return await new Promise((h,m)=>{c.listen(o,async()=>{B.success(`\u{1F680} Builder.io server running at ${p}`),h(!0)})}),{app:a,proxyUrl:p,server:c,availablePort:o}}async function vbe(e,t,r,n){if(n.serverUrl&&!n.command){B.info(`Proxying to existing dev server at ${(0,$n.cyan)(t.serverUrl)}...`),r.devState="running",r.setupState="installed",r.httpServerState="ok-2xx";return}else{B.info(`Running ${(0,$n.cyan)(t.devCommand)} on host ${(0,$n.cyan)(t.serverUrl)}...`);let i=await b8(e,t,n.fusionInit?"not-installed":"installed");return r.devState=i.devState,r.setupState=i.setupState,r.httpServerState=i.httpServerState,i.emitter.on("devState",s=>{r.devState=s}),i.emitter.on("setupState",s=>{r.setupState=s}),i.emitter.on("httpServerState",s=>{r.httpServerState=s}),i}}async function Dbe({sys:e,credentials:t,args:r,fusionConfig:n,app:i,server:s,proxyUrl:o,devServer:a,sharedState:c}){try{let u=td.default.Router();u.post("/generate",async(b,v)=>{try{let{prompt:C,userMessage:x,context:{pushChanges:D,sessionId:E,commitMode:S}}=b.body;if(!C&&!x)return v.status(400).json({error:"No prompt/userMessage provided"});v.setHeader("Content-Type","text/event-stream"),v.setHeader("Cache-Control","no-cache"),v.setHeader("Connection","keep-alive");let F=await Sg(e,t,n,a,"quality-v4",E,S,c),I=F.connectToEventLoop(!1,A=>{v.write(JSON.stringify(A)+`
3907
3907
  `)});try{if(await F.pullLatestFromRemote(),await F.sendMessage(C?{userPrompt:C}:x),await new Promise(A=>setTimeout(A,100)),await F.waitUntilIdle(),D)try{await F.pushChanges(!1)}catch(A){v.write(`${JSON.stringify({type:"error",message:`[GIT_PUSH_ERROR]: ${A instanceof Error?A.message:String(A)}`})}
3908
3908
  `),e.Sentry?.captureException(A)}}catch(A){e.Sentry?.captureException(A);let T=A instanceof Error?A.message:String(A);v.write(`${JSON.stringify({type:"error",message:`Error: ${T}`})}
3909
3909
  `)}finally{I()}v.end()}catch(C){e.Sentry?.captureException(C);let x=C instanceof Error?C.message:String(C);v.headersSent?(v.write(`data: ${JSON.stringify({type:"error",message:`Fatal error: ${x}`})}
3910
3910
 
3911
3911
  `),v.end()):v.status(500).json({error:x})}}),u.get("/get-zip",async(b,v)=>{try{let x=await(await Sg(e,t,n,a,"quality-v3",void 0,void 0,c)).archiveProject();v.setHeader("Content-Type","application/zip"),v.setHeader("Content-Disposition",`attachment; filename="${e.basename(x)}"`),v.download(x,D=>{D&&e.Sentry?.captureException(D),e.unlink(x).catch(E=>{e.Sentry?.captureException(E)})})}catch(C){e.Sentry?.captureException(C),v.status(500).json({error:"Failed to create project archive",details:C instanceof Error?C.message:String(C)})}}),u.post("/shutdown",async(b,v)=>{try{let C=await H7("api-request",!!n.autoShutdown);C?.success?v.json(C):v.status(500).json(C)}catch(C){e.Sentry?.captureException(C),v.status(500).json({success:!1,error:"Failed to shutdown",details:C instanceof Error?C.message:String(C)})}});let l=n.serverUrl?Km(n.serverUrl,e):void 0,p=a?(b,v,C)=>{let x=a.proxyMiddleware;x?x(b,v,C):v.status(500).json({error:"PROJECT NOT SET UP"})}:l;p&&i.use("/",p),i.use(Hm,td.default.json(),td.default.urlencoded({extended:!0}),u);let d=_7({noServer:!0});s.on("upgrade",function(v,C,x){let{pathname:D}=new URL(v.url??"/","wss://base.url"),S=(a?.proxyMiddleware??l)?.upgrade;if(D===Fc+"/ws"){let F=v.headers["sec-websocket-protocol"];if(!n.isLocal&&(!F||F!==t.builderPrivateKey)){e.Sentry?.captureException(new Error("Unauthorized WebSocket connection attempt"),{extra:{headerExists:!!v.headers["sec-websocket-protocol"]}}),C.write(`HTTP/1.1 401 Unauthorized\r
3912
3912
  \r
3913
- `),C.destroy();return}d.handleUpgrade(v,C,x,function(A){A.emit("connection",A,v)})}else S?S(v,C,x):C.destroy()}),Cbe({ws:d,app:i,sys:e,credentials:t,fusionConfig:n,devServer:a,sharedState:c}),c.state="ready";let h=r.app?"builder://":r.dev?"http://localhost:1234":"https://builder.io",m=new URL(`${h}/app/projects/local`);m.searchParams.set("localEditUrl",o);let g=await e.getDeviceId();if(g&&m.searchParams.set("host",g),t.builderPublicKey&&m.searchParams.set("spaceId",t.builderPublicKey),r.jsonOutput){let b={type:"server_ready",data:{proxyUrl:o,fusionEditorUrl:m.href,urlHost:h,command:n.devCommand,serverUrl:n.serverUrl,credentials:t}};console.log(JSON.stringify(b))}r.open===!1?n.isLocal&&console.log(`\u{1F517} Access Builder.io at: ${m.href}`):(B.info(`OPEN BROWSER: ${m.href}`),await Rc(m.href)),setTimeout(()=>{c.editorReady=!0},100)}catch(u){c.state="error",c.isFinalState=!0,c.errorMessage=u instanceof Error?u.message:String(u),e.Sentry?.captureException(u,{level:"fatal"})}}function Cbe({ws:e,app:t,sys:r,fusionConfig:n,credentials:i,devServer:s,sharedState:o}){e.register("initializeSession",async c=>{let u,l,p,d;return typeof c[0]=="object"&&c[0]?{sessionId:u,commitMode:l,customInstructions:p,codeGenMode:d}=c[0]:typeof c[0]=="string"&&(u=c[0]),typeof c[2]=="string"&&(l=c[2]),(await Sg(r,i,n,s,d??"quality-v3",u,l,o,p)).getSessionId()}),e.register("connectToEventLoop",async(c,u)=>{let l=await ed();if(!l)throw new Error("Server not found");let p=e.clients().get(u);if(!p)throw new Error("Client not found");let d=l.getSessionId(),h=l.connectToEventLoop(!0,m=>{m&&!m.timestamp&&(m.timestamp=Date.now()),e.notify(`${d}/event`,u,[JSON.stringify(m)])});p.on("close",h)});function a(c){e.register(c,async([u,...l])=>{n.isLocal||console.log("WS request: ",c,JSON.stringify(l));let p=await ed();if(!p)throw new Error("Server not found");try{let d=p[c];if(typeof d!="function")throw new Error(`Method ${c} not found on codeGenServer`);return d.apply(p,l)}catch(d){throw r.Sentry?.captureException(d,{tags:{functionName:c},extra:{args:l}}),d}})}a("stopEventLoop"),a("abort"),a("abortToolCall"),a("abortSetupCommand"),a("clearSession"),a("loadHistory"),a("loadMoreTurns"),a("getAllFiles"),a("sendFeedback"),a("sendMessage"),a("configureDevOrchestrator"),a("restoreFromCompletionId"),a("restoreBeforeCompletionId"),a("restoreAll"),a("restoreHEAD"),a("undoLastUserMessage"),a("pushChanges"),a("pullLatestFromRemote"),a("syncChangesFromMain"),a("hasChangesRelativeToRemote"),a("setCommitMode"),a("pushRepoV2"),a("readFile"),a("writeFile"),a("deleteFile"),a("fileExists"),a("manualCommit"),a("uploadBackup"),a("getDiffFromRemote"),e.register("ping",()=>(o.lastRequestTime=performance.now(),{version:Te,supports:["customInstructions","newChat","clearSession","appCustomInstructions"]})),e.register("getBuilderRules",async()=>{let c=await ed();if(!c){let u=r.resolve(r.getAppRootDir(),".builderrules");return await r.exists(u)?await r.readFile(u):null}try{return await c.readFile(".builderrules")}catch{return null}}),e.register("setBuilderRules",async c=>{let u=await ed(),l=c[1];if(!u){let p=r.resolve(r.getAppRootDir(),".builderrules");l?await r.writeFile(p,l):await r.exists(p)&&await r.unlink(p);return}l?await u.writeFile(".builderrules",l):await u.deleteFile(".builderrules")})}async function Ebe(e,t,r,n,i,s,o,a,c){let u=new Pi({sys:e,credentials:t,position:"fusion",sessionOrCompletionId:r.sessionId??s,mode:i,maxTokens:8e4,mcpServers:!0,fusionConfig:r,builtInCustomInstructions:[{id:"debugging-errors",name:"debugging-errors",type:"agent-mode",description:"If the user is experiencing an error, or debugging is mentioned by the user.",content:I7},...c??[]],fusionContext:{devServerOrchestrator:n,commitMode:o??r.commitMode??"commits",git:!!r.projectId,gitAutoInit:!0}});return r.projectId&&u.setDebug(!0),await u.initializeSession(),a.state="active-session",a.isFinalState=!0,u}function ed(){return bu||Promise.resolve(void 0)}function Sg(e,t,r,n,i,s,o,a,c){return bu||(bu=Ebe(e,t,r,n,i,s,o,a,c)),bu}function wbe(e,t,r){if(t.isLocal)return()=>{};let s=24*(60*60*1e3),o=Date.now(),a=setInterval(()=>{let c=Date.now()-o,u=Math.floor(c/s);u>1&&e.Sentry?.captureException(new Error(`Rogue devtools detected: ${u} days`),{extra:{timeSinceStart:c},contexts:{flyIo:r,fusionConfig:{...t}}})},s*2);return()=>clearInterval(a)}var H7=async(e,t=!1)=>{B.info(`\u{1F504} Attempting graceful shutdown: ${e}`);let r=()=>{t&&process.kill(process.pid,"SIGTERM")},n=await ed();if(!n)return B.info("\u{1F51A} No active session, shutting down"),r(),{success:!0,message:"No active session, shutting down",skipped:!0,reason:"no_active_session"};if(!n.isIdle())return{success:!1,message:"Not idle, skipping backup",skipped:!0,reason:"not_idle"};if(!n.fusionConfig?.autoBackupGit)return B.info("Auto backup git is disabled, skipping backup"),r(),{success:!0,message:"Auto backup git is disabled, skipping backup",skipped:!0,reason:"auto_backup_git_disabled"};if(!await n.needsBackup())return B.info("\u2705 Already backed up after last request, shutting down"),r(),{success:!0,message:"Already backed up, shutting down",skipped:!0,reason:"already_backed_up"};B.info("\u{1F4E6} Attempting to backup before shutdown...");try{let o=await n.uploadBackup();return o.success&&(B.info("\u2705 Backup successful, shutting down"),r()),o}catch(o){let a=`Backup error: ${o instanceof Error?o.message:String(o)}`;return B.error(`\u274C ${a}`),{success:!1,message:a,error:o instanceof Error?o:new Error(String(o))}}};var fo=q(vt(),1);f();var vs=q(require("@sentry/node"),1),Ui=q(vt(),1);var ej=q(require("crypto"),1);f();var K7=`You are tasked with generating comprehensive documentation for a design system based on the provided components.
3913
+ `),C.destroy();return}d.handleUpgrade(v,C,x,function(A){A.emit("connection",A,v)})}else S?S(v,C,x):C.destroy()}),Cbe({ws:d,app:i,sys:e,credentials:t,fusionConfig:n,devServer:a,sharedState:c}),c.state="ready";let h=r.app?"builder://":r.dev?"http://localhost:1234":"https://builder.io",m=new URL(`${h}/app/projects/local`);m.searchParams.set("localEditUrl",o);let g=await e.getDeviceId();if(g&&m.searchParams.set("host",g),t.builderPublicKey&&m.searchParams.set("spaceId",t.builderPublicKey),r.jsonOutput){let b={type:"server_ready",data:{proxyUrl:o,fusionEditorUrl:m.href,urlHost:h,command:n.devCommand,serverUrl:n.serverUrl,credentials:t}};console.log(JSON.stringify(b))}r.open===!1?n.isLocal&&console.log(`\u{1F517} Access Builder.io at: ${m.href}`):(B.info(`OPEN BROWSER: ${m.href}`),await Rc(m.href)),setTimeout(()=>{c.editorReady=!0},100)}catch(u){c.state="error",c.isFinalState=!0,c.errorMessage=u instanceof Error?u.message:String(u),e.Sentry?.captureException(u,{level:"fatal"})}}function Cbe({ws:e,app:t,sys:r,fusionConfig:n,credentials:i,devServer:s,sharedState:o}){e.register("initializeSession",async c=>{let u,l,p,d;return typeof c[0]=="object"&&c[0]?{sessionId:u,commitMode:l,customInstructions:p,codeGenMode:d}=c[0]:typeof c[0]=="string"&&(u=c[0]),typeof c[2]=="string"&&(l=c[2]),(await Sg(r,i,n,s,d??"quality-v3",u,l,o,p)).getSessionId()}),e.register("connectToEventLoop",async(c,u)=>{let l=await ed();if(!l)throw new Error("Server not found");let p=e.clients().get(u);if(!p)throw new Error("Client not found");let d=l.getSessionId(),h=l.connectToEventLoop(!0,m=>{m&&!m.timestamp&&(m.timestamp=Date.now()),e.notify(`${d}/event`,u,[JSON.stringify(m)])});p.on("close",h)});function a(c){e.register(c,async([u,...l])=>{n.isLocal||console.log("WS request: ",c,JSON.stringify(l));let p=await ed();if(!p)throw new Error("Server not found");try{let d=p[c];if(typeof d!="function")throw new Error(`Method ${c} not found on codeGenServer`);return d.apply(p,l)}catch(d){throw r.Sentry?.captureException(d,{tags:{functionName:c},extra:{args:l}}),d}})}a("stopEventLoop"),a("abort"),a("abortToolCall"),a("abortSetupCommand"),a("clearSession"),a("loadHistory"),a("loadMoreTurns"),a("getAllFiles"),a("sendFeedback"),a("sendMessage"),a("configureDevOrchestrator"),a("restoreFromCompletionId"),a("restoreBeforeCompletionId"),a("restoreAll"),a("restoreHEAD"),a("undoLastUserMessage"),a("pushChanges"),a("pullLatestFromRemote"),a("syncChangesFromMain"),a("hasChangesRelativeToRemote"),a("setCommitMode"),a("pushRepoV2"),a("readFile"),a("writeFile"),a("deleteFile"),a("fileExists"),a("manualCommit"),a("uploadBackup"),a("getDiffFromRemote"),e.register("ping",()=>(o.lastRequestTime=performance.now(),{version:Ce,supports:["customInstructions","newChat","clearSession","appCustomInstructions"]})),e.register("getBuilderRules",async()=>{let c=await ed();if(!c){let u=r.resolve(r.getAppRootDir(),".builderrules");return await r.exists(u)?await r.readFile(u):null}try{return await c.readFile(".builderrules")}catch{return null}}),e.register("setBuilderRules",async c=>{let u=await ed(),l=c[1];if(!u){let p=r.resolve(r.getAppRootDir(),".builderrules");l?await r.writeFile(p,l):await r.exists(p)&&await r.unlink(p);return}l?await u.writeFile(".builderrules",l):await u.deleteFile(".builderrules")})}async function Ebe(e,t,r,n,i,s,o,a,c){let u=new Pi({sys:e,credentials:t,position:"fusion",sessionOrCompletionId:r.sessionId??s,mode:i,maxTokens:8e4,mcpServers:!0,fusionConfig:r,builtInCustomInstructions:[{id:"debugging-errors",name:"debugging-errors",type:"agent-mode",description:"If the user is experiencing an error, or debugging is mentioned by the user.",content:I7},...c??[]],fusionContext:{devServerOrchestrator:n,commitMode:o??r.commitMode??"commits",git:!!r.projectId,gitAutoInit:!0}});return r.projectId&&u.setDebug(!0),await u.initializeSession(),a.state="active-session",a.isFinalState=!0,u}function ed(){return bu||Promise.resolve(void 0)}function Sg(e,t,r,n,i,s,o,a,c){return bu||(bu=Ebe(e,t,r,n,i,s,o,a,c)),bu}function wbe(e,t,r){if(t.isLocal)return()=>{};let s=24*(60*60*1e3),o=Date.now(),a=setInterval(()=>{let c=Date.now()-o,u=Math.floor(c/s);u>1&&e.Sentry?.captureException(new Error(`Rogue devtools detected: ${u} days`),{extra:{timeSinceStart:c},contexts:{flyIo:r,fusionConfig:{...t}}})},s*2);return()=>clearInterval(a)}var H7=async(e,t=!1)=>{B.info(`\u{1F504} Attempting graceful shutdown: ${e}`);let r=()=>{t&&process.kill(process.pid,"SIGTERM")},n=await ed();if(!n)return B.info("\u{1F51A} No active session, shutting down"),r(),{success:!0,message:"No active session, shutting down",skipped:!0,reason:"no_active_session"};if(!n.isIdle())return{success:!1,message:"Not idle, skipping backup",skipped:!0,reason:"not_idle"};if(!n.fusionConfig?.autoBackupGit)return B.info("Auto backup git is disabled, skipping backup"),r(),{success:!0,message:"Auto backup git is disabled, skipping backup",skipped:!0,reason:"auto_backup_git_disabled"};if(!await n.needsBackup())return B.info("\u2705 Already backed up after last request, shutting down"),r(),{success:!0,message:"Already backed up, shutting down",skipped:!0,reason:"already_backed_up"};B.info("\u{1F4E6} Attempting to backup before shutdown...");try{let o=await n.uploadBackup();return o.success&&(B.info("\u2705 Backup successful, shutting down"),r()),o}catch(o){let a=`Backup error: ${o instanceof Error?o.message:String(o)}`;return B.error(`\u274C ${a}`),{success:!1,message:a,error:o instanceof Error?o:new Error(String(o))}}};var fo=q(vt(),1);f();var vs=q(require("@sentry/node"),1),Ui=q(vt(),1);var ej=q(require("crypto"),1);f();var K7=`You are tasked with generating comprehensive documentation for a design system based on the provided components.
3914
3914
 
3915
3915
  ---
3916
3916
 
@@ -4367,14 +4367,14 @@ function AdvancedExample() {
4367
4367
  - **No Coupling**: Document standalone usage, variants, and individual component capabilities
4368
4368
 
4369
4369
  ## Output
4370
- Return only the complete MDX file content, ready to be saved as \`repo-indexing/{{COMPONENT_NAME_KEBAB}}.mdx\`. You must use the Write tool in your response.`;var QU=q(require("@sentry/node"),1);var aS=async(e,t,r,n,i={})=>{let s={sessionId:r,componentName:n.name,designSystemPackage:i.designSystemPackage||"none",designSystemVersion:i.designSystemVersion||"none",designSystemId:i.designSystemId||"none",userId:t.userId,spaceId:t.builderPublicKey},{storeRepoIndexing:o,designSystemPackage:a,designSystemVersion:c,retriesAllowed:u=1,workspaceConfig:l,debug:p}=i,d=n.name.toLowerCase().replace(/ /g,"-"),h={userPrompt:XU.replaceAll("{{COMPONENT_NAME}}",n.name).replaceAll("{{COMPONENT_DESCRIPTION}}",n.description).replaceAll("{{RELATED_COMPONENTS}}",n.relatedComponents.join(", ")).replaceAll("{{FILE_LIST}}",n.relevantFiles.join(", ")).replaceAll("{{COMPONENT_NAME_KEBAB}}",d)};try{let m=await xu(e,t,r,h,p,a,l,{tags:{component:n.name,operation:"component-docs"}},s);if(m){let g={sessionId:r,name:n.name,description:n.description,relatedComponents:n.relatedComponents,relevantFiles:n.relevantFiles,content:m,hash:n.hash,...i.designSystemId&&{designSystemId:i.designSystemId},...c&&{designSystemVersion:c},...a&&{designSystemPackage:a}};await _g(t,g),o&&await e.writeFile(e.join(e.getAppRootDir(),"repo-indexing",`${d}.mdx`),String(m))}}catch(m){let g=new _r("Failed to generate and store component docs",{cause:m});if(QU.captureException(g,{tags:{operation:"generate-component-docs",component:n.name},extra:{kebabName:d,components:n.relatedComponents}}),u===0)throw g;return aS(e,t,r,n,{...i,retriesAllowed:u-1})}},ZU=async(e,t,r)=>{let n=new Set(t.map(s=>s.name)),i=r.filter(s=>!n.has(s.name));i.length>0&&await mxe(e,i.map(s=>s.id))},mxe=async(e,t)=>{let r=new URL("/mappings/deprecate-component-docs",Fe);r.searchParams.set("apiKey",e.builderPublicKey),r.searchParams.set("userId",e.userId);let n=await he(r,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e.builderPrivateKey}`},body:JSON.stringify(t)});if(!n.ok){let i=await n.text();throw console.error("API request failed:",n.status,i),new Error(`Failed to mark component as deprecated: ${n.status} ${i}`)}};var tj=require("path");f();var nd=8,Ng="Done \u2713",hxe=(e,t,r,n=0,i=!1,s)=>{let a=Date.now()-r,c=Math.floor(a/6e4),u=Math.floor(a%6e4/1e3),l=`${c}m ${u}s`,p=new Date().toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"}),d=i||t.length<e.length,h=d?"Component Library updated":"Component Library created",m=d?"Updated on":"Created On";if(t.length===0&&e.length>0&&n===0&&!i){B.info(`
4370
+ Return only the complete MDX file content, ready to be saved as \`repo-indexing/{{COMPONENT_NAME_KEBAB}}.mdx\`. You must use the Write tool in your response.`;var QU=q(require("@sentry/node"),1);var aS=async(e,t,r,n,i={})=>{let s={sessionId:r,componentName:n.name,designSystemPackage:i.designSystemPackage||"none",designSystemVersion:i.designSystemVersion||"none",designSystemId:i.designSystemId||"none",userId:t.userId,spaceId:t.builderPublicKey},{storeRepoIndexing:o,designSystemPackage:a,designSystemVersion:c,retriesAllowed:u=1,workspaceConfig:l,debug:p}=i,d=n.name.toLowerCase().replace(/ /g,"-"),h={userPrompt:XU.replaceAll("{{COMPONENT_NAME}}",n.name).replaceAll("{{COMPONENT_DESCRIPTION}}",n.description).replaceAll("{{RELATED_COMPONENTS}}",n.relatedComponents.join(", ")).replaceAll("{{FILE_LIST}}",n.relevantFiles.join(", ")).replaceAll("{{COMPONENT_NAME_KEBAB}}",d)};try{let m=await xu(e,t,r,h,p,a,l,{tags:{component:n.name,operation:"component-docs"}},s);if(m){let g={sessionId:r,name:n.name,description:n.description,relatedComponents:n.relatedComponents,relevantFiles:n.relevantFiles,content:m,hash:n.hash,...i.designSystemId&&{designSystemId:i.designSystemId},...c&&{designSystemVersion:c},...a&&{designSystemPackage:a}};await _g(t,g),o&&await e.writeFile(e.join(e.getAppRootDir(),"repo-indexing",`${d}.mdx`),String(m))}}catch(m){let g=new _r("Failed to generate and store component docs",{cause:m});if(QU.captureException(g,{tags:{operation:"generate-component-docs",component:n.name},extra:{kebabName:d,components:n.relatedComponents}}),u===0)throw g;return aS(e,t,r,n,{...i,retriesAllowed:u-1})}},ZU=async(e,t,r)=>{let n=new Set(t.map(s=>s.name)),i=r.filter(s=>!n.has(s.name));i.length>0&&await mxe(e,i.map(s=>s.id))},mxe=async(e,t)=>{let r=new URL("/mappings/deprecate-component-docs",Fe);r.searchParams.set("apiKey",e.builderPublicKey),r.searchParams.set("userId",e.userId);let n=await he(r,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e.builderPrivateKey}`},body:JSON.stringify(t)});if(!n.ok){let i=await n.text();throw console.error("API request failed:",n.status,i),new Error(`Failed to mark component as deprecated: ${n.status} ${i}`)}};var tj=require("path");var nd=8,Ng="Done \u2713",hxe=(e,t,r,n=0,i=!1,s)=>{let a=Date.now()-r,c=Math.floor(a/6e4),u=Math.floor(a%6e4/1e3),l=`${c}m ${u}s`,p=new Date().toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"}),d=i||t.length<e.length,h=d?"Component Library updated":"Component Library created",m=d?"Updated on":"Created On";if(t.length===0&&e.length>0&&n===0&&!i){B.info(`
4371
4371
  \u{1F4CB} This Repository is already fully indexed, if you want to overwrite use --force.`);return}B.info(`\u{1F4CB} ${h}
4372
4372
  ${m}: ${p}
4373
4373
  Components indexed: ${t.length} of ${e.length} total components
4374
4374
  took: ${l}`),n>0?B.warn(`${n} component${n===1?"":"s"} failed to index, please try again later`):B.info(`Add "${s}" to your "builder.config.json" file to use your design system with code generation.
4375
4375
 
4376
4376
  Learn more at https://www.builder.io/c/docs/component-indexing#generating-code.
4377
- `)},uS=async(e,t)=>{let{designSystemPackage:r,skipDetailedGrouping:n,force:i,skipHeader:s,storeRepoIndexing:o,listIndexedRepos:a}=t,{designSystemName:c}=t,u=Date.now();vs.getCurrentScope().setTag("operation","repo-indexing"),vs.getCurrentScope().setTag("designSystemPackage",r||"none"),s||ze((0,Ui.bgCyan)((0,Ui.bold)((0,Ui.white)(" repository indexing ")))+" "+(0,Ui.dim)(Te)+`
4377
+ `)},uS=async(e,t)=>{let{designSystemPackage:r,skipDetailedGrouping:n,force:i,skipHeader:s,storeRepoIndexing:o,listIndexedRepos:a}=t,{designSystemName:c}=t,u=Date.now();vs.getCurrentScope().setTag("operation","repo-indexing"),vs.getCurrentScope().setTag("designSystemPackage",r||"none"),s||ze((0,Ui.bgCyan)((0,Ui.bold)((0,Ui.white)(" repository indexing ")))+" "+(0,Ui.dim)(Ce)+`
4378
4378
  `);let l=await yt(e,t,{forceSpaceId:t.spaceId,builderPrivateKey:!0,builderPublicKey:!0});if(a){let D=await Ig(l);if(D.length===0){console.log("No indexed repositories found");return}console.log("Indexed repositories:"),D.forEach((E,S)=>{console.log(`${S+1}. ${E.designSystemName}`)});return}let p=ej.default.randomUUID().slice(0,8);vs.getCurrentScope().setTag("sessionId",p);try{let D=await yxe(l,t.debug);if(!D.isAllowed){console.error(`Error: ${D.reason||"Access denied for repository indexing"}`);return}}catch{console.error("Error: We were unable to determine if your subscription is an enterprise subscription. Contact support@builder.io for more information.");return}let d=await KU(e,r),h=d.version,m=d.name,g;try{if(c===void 0){let D=await Ig(l),E=[...D.map(F=>({value:F.id,label:F.designSystemName}))],S="new";if(E.length>0&&(S=await ws({message:"Which design system would you like to index? You can bypass this by re-running this command with the --designSystemName flag.",options:[...E,{value:"new",label:"Create a new design system"}]}),ve(S)))return;if(S==="new"){let F=await nt({message:"What is your design system name?",initialValue:m,validate(I){if(I.trim().length===0)return"A design system name is required"}});if(ve(F))return;if(c=F,g=await oS(l,c),g){let I=await ir({message:`A design system with the name "${c}" already exists. Would you like to proceed with this design system?`});if(ve(I)||!I)return}}else g=D.find(F=>F.id===S),c=g.designSystemName}else if(g=await oS(l,c),!g){let D=await ir({message:`No indexed design system named "${c}" exists. Would you like to proceed with creating a new design system index?`});if(ve(D)||!D)return}}catch(D){let E=new _r("Failed to select a design system",{cause:D});vs.captureException(E,{tags:{operation:"repo-indexing",sessionId:p,designSystemPackage:r||"none"}}),console.log("Sorry, we encountered a problem when selecting a design system to index. Please try again. If the issue persists, contact support@builder.io.");return}let y=Ss();y.start("Indexing repository");let b={folders:[{path:e.getCwdDir()}]};if(r)if((0,tj.isAbsolute)(r))b.folders.push({path:r});else{let D=e.join(e.getAppRootDir(),`node_modules/${r}`);if(!await e.exists(D)){y.stop(""),console.error(`Design system package ${r} is not installed. Please install it first.`);return}b.folders.push({path:D})}t.includeDirectories&&t.includeDirectories.split(",").forEach(E=>{let S=E.trim();S.length>0&&b.folders.push({path:S})}),t.debug&&console.log("Workspace config",b);let v=g?.id||"";!g&&c&&(v=await VU(l,{designSystemName:c,designSystemVersion:h,designSystemPackage:r,status:"in-progress"}));let x={sessionId:p,commandString:process.argv.slice(2).join(" "),forceBoolean:t.force||!1,currentDirectory:e.getCwdDir(),skipDetailedGroupingBoolean:t.skipDetailedGrouping,designSystemPackage:r||"none",designSystemPackageName:m||"none",designSystemVersion:h||"none",designSystemId:v||"none",workspaceConfig:b,includeDirectories:t.includeDirectories||"none",debugBoolean:t.debug||!1,storeRepoIndexingBoolean:o||!1,listIndexedReposBoolean:a||!1,userId:l.userId,spaceId:l.builderPublicKey};try{await _e("repo indexing started",x),y.message("Looking for components");let D=await gxe(l,t.debug,v),E=D.filter($=>$.name!==$i),{numComponentsFound:S,componentsToIndex:F,discoveredComponents:I}=await JU(e,l,`${p}-component-discovery`,E,{designSystemPackage:r,designSystemVersion:h,workspaceConfig:b,debug:t.debug,force:i});if(S===0){B.info(Fg("We were unable to index your repository because no components were found. If your components are a dependency of your project be sure to specify the package name using --designSystemPackage when re-running this command.",(process.stdout.columns||80)-4));return}if(F.length===0){B.info(Fg("Component index is up to date!",(process.stdout.columns||80)-4));return}if(n)return;let A=D.find($=>$.name===$i);if(i){let $=D.filter(R=>R.name!==$i&&R.name!=="component-groups").length;if(y.stop(`${S} new and ${$} existing component docs found`),$>0){let R=await ir({message:"Using --force will remove existing component documents. Continue?"});if(typeof R=="symbol"||!R){y.stop("Canceled");return}}y.start("")}if(!A||i){y.message("Summarizing component library");let $={userPrompt:K7.replaceAll("{{COMPONENTS}}",JSON.stringify(I.map(W=>({name:W.name,description:W.description,relatedComponents:W.relatedComponents}))))},R="",M=`${p}-agentsmd`;try{R=await xu(e,l,M,$,t.debug,r,b,{tags:{operation:"repo-agent-docs"}},x)}catch(W){let ce=W instanceof Error?W.message:String(W);throw vs.captureException(W,{tags:{operation:"repo-agent-docs",step:"generate-agent-docs"},extra:{...t.debug&&W instanceof Error?{stack:W.stack}:{}}}),v&&await kg(l,{id:v,designSystemName:c,designSystemPackage:r,designSystemVersion:h,status:"failed"}),new Error(ce)}if(!R)throw new Error(`${$i} file not found`);o&&await e.writeFile(e.join(e.getAppRootDir(),"repo-indexing",$i),R);let K={name:$i,description:"Repository agent documentation",relatedComponents:[],relevantFiles:[],content:R,sessionId:M,...v&&{designSystemId:v},...h&&{designSystemVersion:h},...r&&{designSystemPackage:r}};try{await _g(l,K,t.debug),y.message("Agent docs stored")}catch(W){let ce=W instanceof Error?W.message:String(W);throw vs.captureException(W,{tags:{operation:"store-agent-docs",step:"store-agent-docs"},extra:{fileName:$i,...t.debug&&W instanceof Error?{stack:W.stack}:{}}}),console.error(`Failed to store ${$i} file:`,ce),new Error(ce)}}let T=0,G=[];y.stop("Started indexing component docs:");let V=new cS.default.MultiBar({clearOnComplete:!1,hideCursor:!0},cS.default.Presets.shades_grey);V.log(""),V.log(`Indexing in progress with ${nd} workers...`);let Y=V.create(F.length,T,{name:"Total"},{format:`${(0,Ui.cyan)("{bar}")} | {name} | {percentage}% | (Step {value}/{total})`}),P={};for(let $=0;$<nd;$++)P[$]={statusBar:V.create(1,0,{name:"Starting..."},{format:"{name}"}),name:"Starting..."};let N=($,R)=>{R?P[$].name=`Indexing: ${R}`:P[$].name=Ng,Y.update(T)},L=async($,R)=>{let M=[],K=[...$],W=async Le=>{for(;K.length>0;){let J=K.shift();if(!J)break;N(Le,J.name);try{await aS(e,l,`${p}-${J.name}-doc`,J,{designSystemId:v,designSystemPackage:r,designSystemVersion:h,storeRepoIndexing:o,workspaceConfig:b,debug:t.debug}),y.message(`Component docs stored for ${J.name}`),G.push(J),T++}catch{M.push(J.name)}}N(Le,"")},ce=Array.from({length:R},(Le,J)=>W(J)),se=0,Z=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],xt=setInterval(()=>{for(let Le=0;Le<nd;Le++)P[Le].name!==Ng?P[Le].statusBar.update(0,{name:`${P[Le].name} ${Z[se]}`}):P[Le].statusBar.update(0,{name:Ng});se=(se+1)%Z.length},100);await Promise.all(ce),clearInterval(xt);for(let Le=0;Le<nd;Le++)P[Le].statusBar.update(0,{name:Ng});return V.stop(),M.length>0?(console.log(`
4379
4379
  We were unable to index the following components:
4380
4380
 
@@ -4383,7 +4383,7 @@ ${M.join(", ")}
4383
4383
  Re-run your command and try again. If this problem persists, please contact us at support@builder.io.
4384
4384
  `),{numFailed:M.length}):{numFailed:0}},{numFailed:k}=await L(F,nd);await ZU(l,I,D.filter($=>$.name!==$i)),hxe(I,G,u,k,i,c),await _e("repo indexing completed",{sessionId:p,commandString:process.argv.slice(2).join(" "),forceBoolean:t.force,skipDetailedGroupingBoolean:t.skipDetailedGrouping,designSystemPackage:r||"none",designSystemId:v||"none",userId:l.userId,spaceId:l.builderPublicKey}),v&&await kg(l,{id:v,designSystemName:c,designSystemPackage:r,designSystemVersion:h,status:"completed"})}catch(D){throw console.error(`
4385
4385
  Detailed error information:`),console.error("Error ID:",p),console.error("Error:",D instanceof Error?D.message:String(D)),vs.captureException(D,{tags:{operation:"repo-indexing",sessionId:p,designSystemPackage:r||"none"},extra:{skipDetailedGrouping:n,force:i,...t.debug&&D instanceof Error?{stack:D.stack}:{}}}),t.debug&&console.error(`
4386
- Stack trace:`,D instanceof Error?D.stack:""),v&&await kg(l,{id:v,designSystemName:c,designSystemPackage:r,designSystemVersion:h,status:"failed"}),D}},gxe=async(e,t,r)=>{let n=new URL("/mappings/get-component-docs",Fe);n.searchParams.set("apiKey",e.builderPublicKey),n.searchParams.set("userId",e.userId);let i=await he(n,{method:"GET",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e.builderPrivateKey}`}});if(!i.ok){let o=await i.text();return t&&console.error("API request failed:",i.status,o),[]}let s=await i.json();if(r){let o=s.filter(a=>a.designSystemId===r);return o?.length?o:s.filter(a=>!a.designSystemId)}return s},yxe=async(e,t)=>{let r=new URL("/allow-feature",Fe);r.searchParams.set("feature","repo-indexing"),r.searchParams.set("apiKey",e.builderPublicKey),r.searchParams.set("userId",e.userId);let n=await he(r,{method:"GET",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e.builderPrivateKey}`}});if(!n.ok){let s=await n.text();return t&&console.error("API request failed:",n.status,s),{isAllowed:!1,reason:s||"Unable to verify permissions"}}let i=await n.json();return{isAllowed:i.isAllowed,reason:i.reason}};f();f();var Rg=q(vt(),1);var rj=(e,t)=>{try{let{builderPublicKey:r,userId:n,spaceName:i}=Y0(e,t);if(r===void 0){B.message((0,Rg.red)("\u2717 Not Authenticated to Builder.io")),B.message('Re-run this with the "auth" command to authenticate with Builder.io.');return}B.message((0,Rg.green)("\u2713 Authenticated to Builder.io")),i!==void 0&&B.message(`Space Name: ${i}`),r!==void 0&&B.message(`Space ID: ${r}`),n!==void 0&&B.message(`User ID: ${n}`)}catch(r){e.Sentry?.captureException(new _r("Failed to read credentials",{cause:r})),B.error("Sorry, we ran into a problem while checking authentication. Please try again. If this issue persists, contact support@builder.io.")}};var Un=q(vt(),1);var nj=async(e,t,r)=>{if(t==="status"){rj(e,r);return}console.log(""),ze((0,Un.bgCyan)((0,Un.bold)((0,Un.white)(" figma auth ")))+" "+(0,Un.dim)(Te));let{builderPublicKey:n}=await yt(e,r,{builderPrivateKey:!0,builderPublicKey:!0,force:!0});await _e("auth",{spaceId:n}),sr((0,Un.bgGreen)((0,Un.bold)((0,Un.white)(" Done! \u{1F389} "))))};async function bxe(e){console.log(""),ze((0,fo.bgMagenta)((0,fo.bold)((0,fo.white)(" dev-tools server ")))+" "+(0,fo.dim)(Te)),e.debug("builder dev tools cli init");let t=await(0,ij.createDevTools)(e);await(0,oj.createDevToolsServer)({...t,getClientId:()=>"builder-dev-tools-cli",closeAppServer:async()=>{},restartAppServer:async()=>{e.debug("restart server")},enableAppWatch:async r=>r,...e})}R7();async function xxe(){let e=(0,aj.default)(process.argv.slice(2),{string:["figmaToken","privateKey","spaceId","cwd","prompt","mode","token","url","command","c","serverUrl","builderPublicKey","builderPrivateKey","builderUserId","repoFullName","branchName","installCommand","projectId","configJson","workspace","enabledTools","designSystemPackage","includeDirectories"],boolean:["help","ci","force","verbose","fusionInit","debug","dryrun","yes","skipInstallation","skipDetailedGrouping","noAuth","auth","dev","app","noOpen","open","silent","interactive","jsonOutput","local","clearMappings","index","storeRepoIndexing","listIndexedRepos"],alias:{p:"port",c:"command",json:"jsonOutput"},default:{interactive:!1,fusionInit:!1}});e.cwd&&process.chdir(e.cwd);let t=await l2(!!(e.verbose||e.debug));await t.withScope(async r=>{try{let n=await(0,sj.createDevToolsNodeSys)({cwd:process.cwd(),ignoreMissingConfig:!0});if(n.Sentry?.setTag("cli-command",e._.join(" ")),n.Sentry?.setContext("flags-args",{...e}),await yt(n,e,{}),e.help)return ti(e._[e._.length-1]),await te(0);let i=e._[0];if(i==="figma"){let s=e._[1];try{return await E3(n,s,e),await te(0)}catch(o){return n.Sentry?.captureException(o),await te(1)}}else if(i==="code"){let s=e._[1];try{e.index&&(e.skipDetailedGrouping=!0,e.skipHeader=!0,await uS(n,e)),await t3(n,s,e)}catch(o){return n.Sentry?.captureException(o),await te(1)}}else if(i==="index-repo")try{return await uS(n,e),await te(0)}catch(s){return n.Sentry?.captureException(s),await te(1)}else if(i==="launch"||i==="fusion")try{await z7({sys:n,args:e})}catch(s){return n.Sentry?.captureException(s),await te(1)}else if(i==="add"){let s=Q0(n.getAppRootDir(),process.argv.slice(2));return await vR(s),await te(0)}else if(i==="sync"){let s=Q0(n.getAppRootDir(),process.argv.slice(2)),o=await zD(s);await PR(n,o).then(()=>{B.success("Builder dev tools is running")}).catch(a=>(B.error("Cannot start builder dev tools"),n.Sentry?.captureException(a),te(1)))}else if(i==="auth"){let s=e._[1];try{return await nj(n,s,e),await te(0)}catch(o){return n.Sentry?.captureException(o),await te(1)}}else{if(i==="help")return ti(e._[1]),await te(0);if(i==="publish"||i==="migrate"||i==="generate")return De("Command not found, do you mean `npx builder.io figma "+i+"`?"),await te(1);bxe(n).then(()=>{B.success("Builder dev tools is running")}).catch(s=>(B.error("Cannot start builder dev tools"),t.captureException(s),te(1)))}}catch(n){return t.captureException(n),console.error("Cannot start builder dev tools",n),await te(1)}})}xxe();var vxe=void 0;
4386
+ Stack trace:`,D instanceof Error?D.stack:""),v&&await kg(l,{id:v,designSystemName:c,designSystemPackage:r,designSystemVersion:h,status:"failed"}),D}},gxe=async(e,t,r)=>{let n=new URL("/mappings/get-component-docs",Fe);n.searchParams.set("apiKey",e.builderPublicKey),n.searchParams.set("userId",e.userId);let i=await he(n,{method:"GET",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e.builderPrivateKey}`}});if(!i.ok){let o=await i.text();return t&&console.error("API request failed:",i.status,o),[]}let s=await i.json();if(r){let o=s.filter(a=>a.designSystemId===r);return o?.length?o:s.filter(a=>!a.designSystemId)}return s},yxe=async(e,t)=>{let r=new URL("/allow-feature",Fe);r.searchParams.set("feature","repo-indexing"),r.searchParams.set("apiKey",e.builderPublicKey),r.searchParams.set("userId",e.userId);let n=await he(r,{method:"GET",headers:{"Content-Type":"application/json",Authorization:`Bearer ${e.builderPrivateKey}`}});if(!n.ok){let s=await n.text();return t&&console.error("API request failed:",n.status,s),{isAllowed:!1,reason:s||"Unable to verify permissions"}}let i=await n.json();return{isAllowed:i.isAllowed,reason:i.reason}};f();f();var Rg=q(vt(),1);var rj=(e,t)=>{try{let{builderPublicKey:r,userId:n,spaceName:i}=Y0(e,t);if(r===void 0){B.message((0,Rg.red)("\u2717 Not Authenticated to Builder.io")),B.message('Re-run this with the "auth" command to authenticate with Builder.io.');return}B.message((0,Rg.green)("\u2713 Authenticated to Builder.io")),i!==void 0&&B.message(`Space Name: ${i}`),r!==void 0&&B.message(`Space ID: ${r}`),n!==void 0&&B.message(`User ID: ${n}`)}catch(r){e.Sentry?.captureException(new _r("Failed to read credentials",{cause:r})),B.error("Sorry, we ran into a problem while checking authentication. Please try again. If this issue persists, contact support@builder.io.")}};var Un=q(vt(),1);var nj=async(e,t,r)=>{if(t==="status"){rj(e,r);return}console.log(""),ze((0,Un.bgCyan)((0,Un.bold)((0,Un.white)(" figma auth ")))+" "+(0,Un.dim)(Ce));let{builderPublicKey:n}=await yt(e,r,{builderPrivateKey:!0,builderPublicKey:!0,force:!0});await _e("auth",{spaceId:n}),sr((0,Un.bgGreen)((0,Un.bold)((0,Un.white)(" Done! \u{1F389} "))))};async function bxe(e){console.log(""),ze((0,fo.bgMagenta)((0,fo.bold)((0,fo.white)(" dev-tools server ")))+" "+(0,fo.dim)(Ce)),e.debug("builder dev tools cli init");let t=await(0,ij.createDevTools)(e);await(0,oj.createDevToolsServer)({...t,getClientId:()=>"builder-dev-tools-cli",closeAppServer:async()=>{},restartAppServer:async()=>{e.debug("restart server")},enableAppWatch:async r=>r,...e})}R7();async function xxe(){let e=(0,aj.default)(process.argv.slice(2),{string:["figmaToken","privateKey","spaceId","cwd","prompt","mode","token","url","command","c","serverUrl","builderPublicKey","builderPrivateKey","builderUserId","repoFullName","branchName","installCommand","projectId","configJson","workspace","enabledTools","designSystemPackage","includeDirectories"],boolean:["help","ci","force","verbose","fusionInit","debug","dryrun","yes","skipInstallation","skipDetailedGrouping","noAuth","auth","dev","app","noOpen","open","silent","interactive","jsonOutput","local","clearMappings","index","storeRepoIndexing","listIndexedRepos"],alias:{p:"port",c:"command",json:"jsonOutput"},default:{interactive:!1,fusionInit:!1}});e.cwd&&process.chdir(e.cwd);let t=await l2(!!(e.verbose||e.debug));await t.withScope(async r=>{try{let n=await(0,sj.createDevToolsNodeSys)({cwd:process.cwd(),ignoreMissingConfig:!0});if(n.Sentry?.setTag("cli-command",e._.join(" ")),n.Sentry?.setContext("flags-args",{...e}),await yt(n,e,{}),e.help)return ti(e._[e._.length-1]),await te(0);let i=e._[0];if(i==="figma"){let s=e._[1];try{return await E3(n,s,e),await te(0)}catch(o){return n.Sentry?.captureException(o),await te(1)}}else if(i==="code"){let s=e._[1];try{e.index&&(e.skipDetailedGrouping=!0,e.skipHeader=!0,await uS(n,e)),await t3(n,s,e)}catch(o){return n.Sentry?.captureException(o),await te(1)}}else if(i==="index-repo")try{return await uS(n,e),await te(0)}catch(s){return n.Sentry?.captureException(s),await te(1)}else if(i==="launch"||i==="fusion")try{await z7({sys:n,args:e})}catch(s){return n.Sentry?.captureException(s),await te(1)}else if(i==="add"){let s=Q0(n.getAppRootDir(),process.argv.slice(2));return await vR(s),await te(0)}else if(i==="sync"){let s=Q0(n.getAppRootDir(),process.argv.slice(2)),o=await zD(s);await PR(n,o).then(()=>{B.success("Builder dev tools is running")}).catch(a=>(B.error("Cannot start builder dev tools"),n.Sentry?.captureException(a),te(1)))}else if(i==="auth"){let s=e._[1];try{return await nj(n,s,e),await te(0)}catch(o){return n.Sentry?.captureException(o),await te(1)}}else{if(i==="help")return ti(e._[1]),await te(0);if(i==="publish"||i==="migrate"||i==="generate")return De("Command not found, do you mean `npx builder.io figma "+i+"`?"),await te(1);bxe(n).then(()=>{B.success("Builder dev tools is running")}).catch(s=>(B.error("Cannot start builder dev tools"),t.captureException(s),te(1)))}}catch(n){return t.captureException(n),console.error("Cannot start builder dev tools",n),await te(1)}})}xxe();var vxe=void 0;
4387
4387
  /*! Bundled license information:
4388
4388
 
4389
4389
  is-extglob/index.js: