grafast 0.0.1-beta.3 → 0.0.1-beta.4
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/dist/index.js +1 -1
- package/dist/steps/node.d.ts +2 -2
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -494,4 +494,4 @@ ${t}
|
|
|
494
494
|
return newObj;
|
|
495
495
|
})`,e)}finalize(){return this.tupleToObjectJIT((e=>{this.unbatchedExecute=e})),super.finalize()}execute(e,t,n){const r=[];for(let a=0;a<e;a++)r[a]=this.unbatchedExecute(n,...t.map((e=>e[a])));return r}unbatchedExecute(e,...t){throw new Error(`${this} didn't finalize? No unbatchedExecute method.`)}deduplicate(e){const t=JSON.stringify(this.keys);return e.filter((e=>JSON.stringify(e.keys)===t))}optimize(e){if(this.dependencies.every((e=>e instanceof o.ConstantStep))){const t=e.meta,n=this.keys.join(",");t[n]||(t[n]=[]);const r=t[n].find((e=>this.keys.every(((t,n)=>e[t]===this.dependencies[n].data)))),a=this.dependencies.some((e=>e.isSensitive));if(void 0!==r)return(0,o.constant)(r,a);{const e=Object.create(null);for(let t=0,n=this.keys.length;t<n;t++){const n=this.keys[t],r=this.dependencies[t].data;e[n]=r}return t[n].push(e),(0,o.constant)(e,a)}}return this}get(e){const t=this.keys.indexOf(e);if(t<0)throw new Error(`This ObjectStep doesn't have key '${String(e)}'; supported keys: '${this.keys.join("', '")}'`);return this.getDep(t)}}t.ObjectStep=ObjectStep,t.object=function(e){return new ObjectStep(e)}},2354:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.partitionByIndex=void 0;const r=n(5163).__importDefault(n(2645)),a=n(764),o=n(2512),s=n(2600),i=(e,t,n)=>(e[n]||(e[n]=[]),e[n].push(t),e),l=(e,t,n)=>{const r=n-1;return e[r]||(e[r]=[]),e[r].push(t),e},c=()=>[];t.partitionByIndex=function(e,t,n=0){if(0!==n&&1!==n)throw new Error("partitionByIndex only supports 0- and 1-indexed lists currently; please use 'lambda' to convert your index");return(0,s.listTransform)({listStep:e,itemPlanCallback:t,initialState:c,reduceCallback:1===n?l:i,listItem:(0,a.isListCapableStep)(e)?t=>(0,o.each)(t,(t=>e.listItem(t))):void 0,meta:`partitionByIndex${n}:${r.default.yellow(e.id)}${t.name?`/${t.name}`:""}`})}},3942:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.proxy=t.ProxyStep=void 0;const r=n(6397),a=n(764);class ProxyStep extends a.UnbatchedExecutableStep{static{this.$$export={moduleName:"grafast",exportName:"ProxyStep"}}constructor(e,t){super(),this.isSyncAndSafe=!0,this.stream=void 0,this.$depId=e.id,this.addDependency(t)}toStringMeta(){return this.operationPlan.dangerouslyGetStep(this.$depId).toString()}addDependency(e){return super.addDependency(e)}execute(e,t){return t[0]}unbatchedExecute(e,t){return t}}t.ProxyStep=ProxyStep,t.proxy=function(e,t=e){const n=new ProxyStep(e,t),a=new Proxy(n,(o=e,{get(e,t,n){if("deduplicate"===t)return()=>[n];if("optimize"===t)return delete e[r.$$proxy],()=>[e];if(t in e){const n=e[t];return"function"==typeof n?function(...t){return n.apply(e,t)}:n}{const e=o[t];return"function"==typeof e?function(...t){return e.apply(o,t)}:e}},has:(e,t)=>t in e||t in o,set(e,t,n,r){if(t in e)return Reflect.set(e,t,n,r);throw new Error(`Setting through a ProxyStep is currently forbidden (attempted to set '${String(t)}' on '${e}'`)},getPrototypeOf:e=>Object.getPrototypeOf(o)}));var o;return n[r.$$proxy]=a,a}},8877:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.remapKeys=t.RemapKeysStep=void 0;const r=n(5163),a=r.__importDefault(n(2645)),o=r.__importStar(n(7073)),s=n(764);class RemapKeysStep extends s.UnbatchedExecutableStep{static{this.$$export={moduleName:"grafast",exportName:"RemapKeysStep"}}constructor(e,t){super(),this.actualKeyByDesiredKey=t,this.isSyncAndSafe=!0,this.allowMultipleOptimizations=!0,this.addDependency(e)}toStringMeta(){return a.default.bold.yellow(String(this.dependencies[0].id))+":"+JSON.stringify(this.actualKeyByDesiredKey)}optimize(){for(const[e,t]of Object.entries(this.actualKeyByDesiredKey))if(String(e)!==String(t))return this;return this.getDep(0)}finalize(){!function(e,t){const n=Object.entries(e);n.every((([e,t])=>(0,o.isSafeObjectPropertyName)(e)&&(0,o.isSafeObjectPropertyName)(t)))?o.default.runInBatch(o.default`(function(obj) {
|
|
496
496
|
return (obj == null ? obj : { ${o.default.join(n.map((([e,t])=>o.default`${o.default.safeKeyOrThrow(e)}: obj${o.default.get(t)}`)),", ")} });
|
|
497
|
-
})`,t):t((t=>null==t?t:Object.keys(e).reduce(((n,r)=>(n[r]=t[e[r]],n)),Object.create(null))))}(this.actualKeyByDesiredKey,(e=>{this.mapper=e})),super.finalize()}execute(e,t){return t[0].map(this.mapper)}unbatchedExecute(e,t){return this.mapper(t)}deduplicate(e){const t=JSON.stringify(this.actualKeyByDesiredKey);return e.filter((e=>JSON.stringify(e.actualKeyByDesiredKey)===t))}}t.RemapKeysStep=RemapKeysStep,t.remapKeys=function(e,t){return new RemapKeysStep(e,t)}},5289:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reverse=t.ReverseStep=t.reverseArray=void 0;const r=n(764);function a(e){if(!Array.isArray(e))throw new Error("Attempted to reverse an array, but what was passed wasn't an array");const t=e.length,n=[];for(let r=0;r<t;r++)n[r]=e[t-r-1];return n}t.reverseArray=a;class ReverseStep extends r.UnbatchedExecutableStep{static{this.$$export={moduleName:"grafast",exportName:"ReverseStep"}}constructor(e){super(),this.isSyncAndSafe=!0,this.allowMultipleOptimizations=!0,this.addDependency(e)}execute(e,t){return t[0].map((e=>null==e?e:a(e)))}unbatchedExecute(e,t){return null==t?t:a(t)}deduplicate(e){return e}}t.ReverseStep=ReverseStep,t.reverse=function(e){return new ReverseStep(e)}},9081:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setter=t.SetterStep=void 0;const r=n(764);class SetterStep extends r.ModifierStep{static{this.$$export={moduleName:"grafast",exportName:"SetterStep"}}constructor(e){super(e),this.setters=new Map}set(e,t){this.setters.set(e,t)}apply(){for(const[e,t]of this.setters.entries())this.$parent.set(e,t)}}t.SetterStep=SetterStep,t.setter=function(e){return new SetterStep(e)}},927:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.stringifyPayload=void 0,t.stringifyPayload=function(e,t){if(!t||"string"!=typeof e.data)return JSON.stringify(e);let n="{",r=!0;if(e.incremental)throw new Error("Haven't implemented incremental yet");if(void 0!==e.errors&&(r||(n+=","),r=!1,n+=`"errors":${JSON.stringify(e.errors)}`),void 0===e.data);else if(null===e.data)r||(n+=","),r=!1,n+='"data":null';else{if("string"!=typeof e.data)throw new Error("Expected data to be null, undefined, or a JSON string");r||(n+=","),r=!1,n+=`"data":${e.data}`}return void 0!==e.extensions&&(r||(n+=","),r=!1,n+=`"extensions":${JSON.stringify(e.extensions)}`),void 0!==e.label&&(r||(n+=","),r=!1,n+=`"label":${JSON.stringify(e.label)}`),void 0!==e.hasNext&&(r||(n+=","),r=!1,n+=`"hasNext":${JSON.stringify(e.hasNext)}`),n+="}",n}},6522:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.stripAnsi=t.ANSI_REGEXP=void 0,t.ANSI_REGEXP=/[\u001B\u009B][[\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\d\/#&.:=?%@~_]+)*|[a-zA-Z\d]+(?:;[-a-zA-Z\d\/#&.:=?%@~_]*)*)?\u0007)|(?:(?:\d{1,4}(?:;\d{0,4})*)?[\dA-PR-TZcf-nq-uy=><~]))/g,t.stripAnsi=function(e){return e.replace(t.ANSI_REGEXP,"")}},680:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.subscribe=void 0;const r=n(1610),a=n(6587);t.subscribe=function(e,t=r.NULL_PRESET,n=!1){return(0,a.withGrafastArgs)(e,t,n)}},6076:()=>{"use strict";const e=Symbol.for("grafast"),t=globalThis;if(!0===t[e]);else if(t[e])console.trace(`WARNING: more than one version of the 'grafast' module has been instantiated - you must ensure there is exactly one grafast (e.g. using yarn "resolutions" or similar techniques). Try clearing your package lockfile and reinstalling. ${t[e].stack}`),t[e]=!0;else try{throw new Error("The first 'grafast' was installed here")}catch(n){t[e]=n}},8912:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.timeSource=void 0,t.timeSource="undefined"!=typeof performance&&"function"==typeof performance.now?performance:Date},6787:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hasItemPlan=t.assertNotAsync=t.canonicalJSONStringify=t.stepsAreInSamePhase=t.stepAMayDependOnStepB=t.stepADependsOnStepB=t.isTypePlanned=t.findVariableNamesUsed=t.arrayOfLengthCb=t.arrayOfLength=t.stack=t.sharedNull=t.getEnumValueConfig=t.inputObjectFieldSpec=t.newInputObjectTypeBuilder=t.newGrafastFieldConfigBuilder=t.objectFieldSpec=t.newObjectTypeBuilder=t.objectSpec=t.arraysMatch=t.isDeferred=t.isPromiseLike=t.isPromise=t.defaultValueToValueNode=t.assertNullPrototype=t.ROOT_VALUE_OBJECT=void 0;const r=n(5163),a=r.__importStar(n(8372)),o=r.__importStar(n(9790)),s=n(4068),i=n(5509),l=n(4065),{GraphQLBoolean:c,GraphQLEnumType:u,GraphQLFloat:p,GraphQLID:d,GraphQLInputObjectType:f,GraphQLInt:h,GraphQLInterfaceType:y,GraphQLList:b,GraphQLNonNull:m,GraphQLObjectType:g,GraphQLScalarType:S,GraphQLString:P,GraphQLUnionType:v,Kind:w}=a;function O(e){if(null==e)return{kind:w.NULL};if("boolean"==typeof e)return{kind:w.BOOLEAN,value:e};if("number"==typeof e)return e===Math.round(e)?{kind:w.INT,value:String(e)}:{kind:w.FLOAT,value:String(e)};if("string"==typeof e)return{kind:w.STRING,value:e};if(Array.isArray(e))return{kind:w.LIST,values:e.map(O)};if("object"==typeof e&&null!==e)return{kind:w.OBJECT,fields:Object.keys(e).map((t=>({kind:w.OBJECT_FIELD,name:{kind:w.NAME,value:t},value:O(e[t])})))};const t=e;throw console.error(`Unhandled type when converting custom scalar to ValueNode: ${(0,l.inspect)(t)}`),new Error("Unhandled type when converting custom scalar to ValueNode")}function $(e,t){if(e instanceof m){if(null==t)throw new Error("defaultValue contained null/undefined at a position that is marked as non-null");return $(e.ofType,t)}if(void 0===t)return;if(null===t)return{kind:w.NULL};if(e===c){if("boolean"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting boolean");return{kind:w.BOOLEAN,value:t}}if(e===h){if("number"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting int");return{kind:w.INT,value:String(parseInt(String(t),10))}}if(e===p){if("number"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting int");return{kind:w.FLOAT,value:String(t)}}if(e===P||e===d){if("string"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting string");return{kind:w.STRING,value:t}}if(e instanceof u){const n=e.getValues().find((e=>e.value===t));if(!n)throw console.error(`Default contained invalid value for enum ${e.name}: ${(0,l.inspect)(t)}`),new Error(`Default contained invalid value for enum ${e.name}`);return{kind:w.ENUM,value:n.name}}if(e instanceof S)return O(t);if(e instanceof b){if(!Array.isArray(t))throw new Error("defaultValue contained invalid value at location expecting a list");return{kind:w.LIST,values:t.map((t=>{const n=$(e.ofType,t);if(void 0===n)throw new Error("defaultValue contained invalid list (contained `undefined`)");return n}))}}if(e instanceof f){if("object"!=typeof t||null===t)throw new Error("defaultValue contained invalid value at location expecting an object");const n=e.getFields(),r=[];for(const e in n){const a=n[e],o=$(a.type,void 0!==t[e]?t[e]:a.defaultValue);void 0!==o&&r.push({kind:w.OBJECT_FIELD,name:{kind:w.NAME,value:e},value:o})}return{kind:w.OBJECT,fields:r}}const n=e;throw console.error(`Encountered unexpected type when processing defaultValue ${(0,l.inspect)(n)}`),new Error("Encountered unexpected type when processing defaultValue")}function E(e){return"object"==typeof e&&null!==e&&"function"==typeof e.then&&"function"==typeof e.catch}function x(e){const{assertStep:t,...n}=e;return{...n,...t?{extensions:{...e.extensions,grafast:{assertStep:t,...e.extensions?.grafast}}}:null,fields:()=>{const t="function"==typeof e.fields?e.fields():e.fields;return Object.keys(t).reduce(((n,r)=>(n[r]=k(t[r],`${e.name}.${r}`),n)),{})}}}function k(e,t){const{plan:n,subscribePlan:r,args:a,...o}=e;N(n,`${t??"?"}.plan`),N(r,`${t??"?"}.subscribePlan`);const s=a?Object.keys(a).reduce(((e,n)=>{const{inputPlan:r,applyPlan:o,autoApplyAfterParentPlan:s,autoApplyAfterParentSubscribePlan:i,...l}=a[n];return N(r,`${t??"?"}(${n}:).inputPlan`),N(o,`${t??"?"}(${n}:).applyPlan`),e[n]={...l,...r||o?{extensions:{grafast:{...r?{inputPlan:r}:null,...s?{autoApplyAfterParentPlan:s}:null,...o?{applyPlan:o}:null,...i?{autoApplyAfterParentSubscribePlan:i}:null}}}:null},e}),Object.create(null)):{};return{...o,args:s,...n||r?{extensions:{...o.extensions,grafast:{...o.extensions?.grafast,...n?{plan:n}:null,...r?{subscribePlan:r}:null}}}:null}}function _(e,t){const{inputPlan:n,applyPlan:r,autoApplyAfterParentInputPlan:a,autoApplyAfterParentApplyPlan:o,...s}=e;return N(n,`${t??"?"}.inputPlan`),N(r,`${t??"?"}.applyPlan`),n||r?{...s,extensions:{grafast:{...n?{inputPlan:n}:null,...r?{applyPlan:r}:null,...a?{autoApplyAfterParentInputPlan:a}:null,...o?{autoApplyAfterParentApplyPlan:o}:null}}}:s}t.ROOT_VALUE_OBJECT=Object.freeze(Object.create(null)),t.assertNullPrototype=function(e,t){s.isDev&&o.strictEqual(Object.getPrototypeOf(e),null,`Expected ${t} to have a null prototype`)},t.defaultValueToValueNode=function(e,t){if(void 0!==t)return $(e,t)},t.isPromise=E,t.isPromiseLike=function(e){return null!=e&&"function"==typeof e.then},t.isDeferred=function(e){return E(e)&&"function"==typeof e.resolve&&"function"==typeof e.reject},t.arraysMatch=function(e,t,n){if(e===t)return!0;const r=e.length;if(r!==t.length)return!1;if(void 0!==n){for(let a=0;a<r;a++)if(!n(e[a],t[a]))return!1}else for(let n=0;n<r;n++)if(e[n]!==t[n])return!1;return!0},t.objectSpec=x,t.newObjectTypeBuilder=function(e){return t=>new g(x({assertStep:e,...t}))},t.objectFieldSpec=k,t.newGrafastFieldConfigBuilder=function(){return e=>e},t.newInputObjectTypeBuilder=function(){return e=>new f(function(e){return{...e,fields:()=>{const t="function"==typeof e.fields?e.fields():e.fields;return Object.keys(t).reduce(((n,r)=>(n[r]=_(t[r],`${e.name}.${r}`),n)),{})}}}(e))},t.inputObjectFieldSpec=_;const j=Symbol("valueConfigByValue");function I(e,t){switch(e.kind){case w.INT:case w.FLOAT:case w.STRING:case w.BOOLEAN:case w.NULL:case w.ENUM:return;case w.LIST:for(const n of e.values)I(n,t);return;case w.OBJECT:for(const n of e.fields)I(n.value,t);return;case w.VARIABLE:return void t.add(e.name.value);default:{const t=e;throw new Error(`Unsupported valueNode: ${JSON.stringify(t)}`)}}}function L(e,t){if(void 0!==e)for(const n of e)if(void 0!==n.arguments)for(const e of n.arguments)I(e.value,t)}function T(e,t,n){switch(L(t.directives,n),t.kind){case w.FIELD:return void C(e,t,n);case w.INLINE_FRAGMENT:L(t.directives,n);for(const r of t.selectionSet.selections)T(e,r,n);return;case w.FRAGMENT_SPREAD:{L(t.directives,n);const r=t.name.value,a=e.fragments[r];if(L(a.directives,n),a.variableDefinitions?.length)throw new i.SafeError("Grafast doesn't support variable definitions on fragments yet.");for(const t of a.selectionSet.selections)T(e,t,n);return}default:throw new Error(`Unsupported selection ${t.kind}`)}}function C(e,t,n){if(function(e,t){if(void 0!==e)for(const n of e)I(n.value,t)}(t.arguments,n),L(t.directives,n),void 0!==t.selectionSet)for(const r of t.selectionSet.selections)T(e,r,n)}function A(e,t){if(e===t)throw new Error("Invalid call to stepADependsOnStepB");for(const n of e.dependencies){if(n===t)return!0;if(A(n,t))return!0}return!1}t.getEnumValueConfig=function(e,t){if(!e[j]){const t=e.toConfig();e[j]=Object.values(t.values).reduce(((e,t)=>(e[t.value]=t,e)),Object.create(null))}return e[j][t]},t.sharedNull=Object.freeze(Object.create(null)),t.stack=function(e,t=4){try{throw new Error(e)}catch(e){const n=e.stack.split("\n"),r=n.findIndex((e=>e.startsWith("Error:")));if(r<0)return void console.dir(e.stack);const a=[n[r],...n.slice(r+2,r+2+t)].map((e=>e.replace(/^(.*?)\(\/home[^)]*\/packages\/([^)]*)\)/,((e,t,n)=>`${t}${" ".repeat(Math.max(0,45-t.length))}(${n})`))));console.log(a.join("\n"))}},t.arrayOfLength=function(e,t){const n=[];for(let r=0;r<e;r++)n[r]=t;return n},t.arrayOfLengthCb=function(e,t){const n=[];for(let r=0;r<e;r++)n[r]=t();return n},t.findVariableNamesUsed=function(e,t){const n=new Set;return C(e,t,n),[...n].sort()},t.isTypePlanned=function(e,t){if(t instanceof g)return!!t.extensions?.grafast?.assertStep;if(t instanceof v||t instanceof y){const n=t instanceof v?t.getTypes():e.getImplementations(t).objects;let r=null,a=0;for(const e of n){const o=!!e.extensions?.grafast?.assertStep;if(null===r)r=o;else if(o!==r)throw new Error(`The '${t.name}' interface or union type's first type '${n[0]}' ${r?"expected a plan":"did not expect a plan"}, however the type '${e}' (index = ${a}) ${o?"expected a plan":"did not expect a plan"}. All types in an interface or union must be in agreement about whether a plan is expected or not.`);a++}return!!r}return!1},t.stepADependsOnStepB=A,t.stepAMayDependOnStepB=function(e,t){return e.layerPlan.ancestry.includes(t.layerPlan)&&!A(t,e)},t.stepsAreInSamePhase=function(e,t){let n=t.layerPlan;do{if(n===e.layerPlan)return!0;const t=n.reason.type;switch(t){case"subscription":case"defer":case"polymorphic":return!1;case"listItem":if(n.reason.stream)continue;continue;case"root":case"nullableBoundary":case"subroutine":case"mutationField":continue;default:throw new Error(`Unhandled layer plan type '${t}'`)}}while(n=n.parentLayerPlan);throw new Error(`${t} is not dependent on ${e}, perhaps you passed the arguments in the wrong order?`)};function N(e,t){if("AsyncFunction"===e?.constructor?.name)throw new Error(`Plans must be synchronous, but this schema has an async function at '${t}': ${e.toString()}`)}t.canonicalJSONStringify=e=>JSON.stringify(e),t.assertNotAsync=N,t.hasItemPlan=function(e){return"itemPlan"in e&&"function"==typeof e.itemPlan}},14:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="0.0.1-beta.3"},9640:(e,t,n)=>{"use strict";e=n.nmd(e);const r=(e,t)=>(...n)=>`[${e(...n)+t}m`,a=(e,t)=>(...n)=>{const r=e(...n);return`[${38+t};5;${r}m`},o=(e,t)=>(...n)=>{const r=e(...n);return`[${38+t};2;${r[0]};${r[1]};${r[2]}m`},s=e=>e,i=(e,t,n)=>[e,t,n],l=(e,t,n)=>{Object.defineProperty(e,t,{get:()=>{const r=n();return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0}),r},enumerable:!0,configurable:!0})};let c;const u=(e,t,r,a)=>{void 0===c&&(c=n(9));const o=a?10:0,s={};for(const[n,a]of Object.entries(c)){const i="ansi16"===n?"ansi":n;n===t?s[i]=e(r,o):"object"==typeof a&&(s[i]=e(a[t],o))}return s};Object.defineProperty(e,"exports",{enumerable:!0,get:function(){const e=new Map,t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],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],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],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.gray=t.color.blackBright,t.bgColor.bgGray=t.bgColor.bgBlackBright,t.color.grey=t.color.blackBright,t.bgColor.bgGrey=t.bgColor.bgBlackBright;for(const[n,r]of Object.entries(t)){for(const[n,a]of Object.entries(r))t[n]={open:`[${a[0]}m`,close:`[${a[1]}m`},r[n]=t[n],e.set(a[0],a[1]);Object.defineProperty(t,n,{value:r,enumerable:!1})}return Object.defineProperty(t,"codes",{value:e,enumerable:!1}),t.color.close="[39m",t.bgColor.close="[49m",l(t.color,"ansi",(()=>u(r,"ansi16",s,!1))),l(t.color,"ansi256",(()=>u(a,"ansi256",s,!1))),l(t.color,"ansi16m",(()=>u(o,"rgb",i,!1))),l(t.bgColor,"ansi",(()=>u(r,"ansi16",s,!0))),l(t.bgColor,"ansi256",(()=>u(a,"ansi256",s,!0))),l(t.bgColor,"ansi16m",(()=>u(o,"rgb",i,!0))),t}})},5635:(e,t,n)=>{const r=n(9448),a={};for(const e of Object.keys(r))a[r[e]]=e;const o={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=o;for(const e of Object.keys(o)){if(!("channels"in o[e]))throw new Error("missing channels property: "+e);if(!("labels"in o[e]))throw new Error("missing channel labels property: "+e);if(o[e].labels.length!==o[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:t,labels:n}=o[e];delete o[e].channels,delete o[e].labels,Object.defineProperty(o[e],"channels",{value:t}),Object.defineProperty(o[e],"labels",{value:n})}o.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.min(t,n,r),o=Math.max(t,n,r),s=o-a;let i,l;o===a?i=0:t===o?i=(n-r)/s:n===o?i=2+(r-t)/s:r===o&&(i=4+(t-n)/s),i=Math.min(60*i,360),i<0&&(i+=360);const c=(a+o)/2;return l=o===a?0:c<=.5?s/(o+a):s/(2-o-a),[i,100*l,100*c]},o.rgb.hsv=function(e){let t,n,r,a,o;const s=e[0]/255,i=e[1]/255,l=e[2]/255,c=Math.max(s,i,l),u=c-Math.min(s,i,l),p=function(e){return(c-e)/6/u+.5};return 0===u?(a=0,o=0):(o=u/c,t=p(s),n=p(i),r=p(l),s===c?a=r-n:i===c?a=1/3+t-r:l===c&&(a=2/3+n-t),a<0?a+=1:a>1&&(a-=1)),[360*a,100*o,100*c]},o.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const a=o.rgb.hsl(e)[0],s=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[a,100*s,100*r]},o.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.min(1-t,1-n,1-r);return[100*((1-t-a)/(1-a)||0),100*((1-n-a)/(1-a)||0),100*((1-r-a)/(1-a)||0),100*a]},o.rgb.keyword=function(e){const t=a[e];if(t)return t;let n,o=1/0;for(const t of Object.keys(r)){const a=r[t],l=(i=a,((s=e)[0]-i[0])**2+(s[1]-i[1])**2+(s[2]-i[2])**2);l<o&&(o=l,n=t)}var s,i;return n},o.keyword.rgb=function(e){return r[e]},o.rgb.xyz=function(e){let t=e[0]/255,n=e[1]/255,r=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;return[100*(.4124*t+.3576*n+.1805*r),100*(.2126*t+.7152*n+.0722*r),100*(.0193*t+.1192*n+.9505*r)]},o.rgb.lab=function(e){const t=o.rgb.xyz(e);let n=t[0],r=t[1],a=t[2];n/=95.047,r/=100,a/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,a=a>.008856?a**(1/3):7.787*a+16/116;return[116*r-16,500*(n-r),200*(r-a)]},o.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let a,o,s;if(0===n)return s=255*r,[s,s,s];a=r<.5?r*(1+n):r+n-r*n;const i=2*r-a,l=[0,0,0];for(let e=0;e<3;e++)o=t+1/3*-(e-1),o<0&&o++,o>1&&o--,s=6*o<1?i+6*(a-i)*o:2*o<1?a:3*o<2?i+(a-i)*(2/3-o)*6:i,l[e]=255*s;return l},o.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,a=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,a*=o<=1?o:2-o;return[t,100*(0===r?2*a/(o+a):2*n/(r+n)),100*((r+n)/2)]},o.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const a=Math.floor(t)%6,o=t-Math.floor(t),s=255*r*(1-n),i=255*r*(1-n*o),l=255*r*(1-n*(1-o));switch(r*=255,a){case 0:return[r,l,s];case 1:return[i,r,s];case 2:return[s,r,l];case 3:return[s,i,r];case 4:return[l,s,r];case 5:return[r,s,i]}},o.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,a=Math.max(r,.01);let o,s;s=(2-n)*r;const i=(2-n)*a;return o=n*a,o/=i<=1?i:2-i,o=o||0,s/=2,[t,100*o,100*s]},o.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const a=n+r;let o;a>1&&(n/=a,r/=a);const s=Math.floor(6*t),i=1-r;o=6*t-s,0!=(1&s)&&(o=1-o);const l=n+o*(i-n);let c,u,p;switch(s){default:case 6:case 0:c=i,u=l,p=n;break;case 1:c=l,u=i,p=n;break;case 2:c=n,u=i,p=l;break;case 3:c=n,u=l,p=i;break;case 4:c=l,u=n,p=i;break;case 5:c=i,u=n,p=l}return[255*c,255*u,255*p]},o.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,a=e[3]/100;return[255*(1-Math.min(1,t*(1-a)+a)),255*(1-Math.min(1,n*(1-a)+a)),255*(1-Math.min(1,r*(1-a)+a))]},o.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let a,o,s;return a=3.2406*t+-1.5372*n+-.4986*r,o=-.9689*t+1.8758*n+.0415*r,s=.0557*t+-.204*n+1.057*r,a=a>.0031308?1.055*a**(1/2.4)-.055:12.92*a,o=o>.0031308?1.055*o**(1/2.4)-.055:12.92*o,s=s>.0031308?1.055*s**(1/2.4)-.055:12.92*s,a=Math.min(Math.max(0,a),1),o=Math.min(Math.max(0,o),1),s=Math.min(Math.max(0,s),1),[255*a,255*o,255*s]},o.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;return[116*n-16,500*(t-n),200*(n-r)]},o.lab.xyz=function(e){let t,n,r;n=(e[0]+16)/116,t=e[1]/500+n,r=n-e[2]/200;const a=n**3,o=t**3,s=r**3;return n=a>.008856?a:(n-16/116)/7.787,t=o>.008856?o:(t-16/116)/7.787,r=s>.008856?s:(r-16/116)/7.787,t*=95.047,n*=100,r*=108.883,[t,n,r]},o.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let a;a=360*Math.atan2(r,n)/2/Math.PI,a<0&&(a+=360);return[t,Math.sqrt(n*n+r*r),a]},o.lch.lab=function(e){const t=e[0],n=e[1],r=e[2]/360*2*Math.PI;return[t,n*Math.cos(r),n*Math.sin(r)]},o.rgb.ansi16=function(e,t=null){const[n,r,a]=e;let s=null===t?o.rgb.hsv(e)[2]:t;if(s=Math.round(s/50),0===s)return 30;let i=30+(Math.round(a/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===s&&(i+=60),i},o.hsv.ansi16=function(e){return o.rgb.ansi16(o.hsv.rgb(e),e[2])},o.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];if(t===n&&n===r)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;return 16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},o.ansi16.rgb=function(e){let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=.5*(1+~~(e>50));return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},o.ansi256.rgb=function(e){if(e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;return[Math.floor(e/36)/5*255,Math.floor((t=e%36)/6)/5*255,t%6/5*255]},o.rgb.hex=function(e){const t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},o.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let n=t[0];3===t[0].length&&(n=n.split("").map((e=>e+e)).join(""));const r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},o.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.max(Math.max(t,n),r),o=Math.min(Math.min(t,n),r),s=a-o;let i,l;return i=s<1?o/(1-s):0,l=s<=0?0:a===t?(n-r)/s%6:a===n?2+(r-t)/s:4+(t-n)/s,l/=6,l%=1,[360*l,100*s,100*i]},o.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let a=0;return r<1&&(a=(n-.5*r)/(1-r)),[e[0],100*r,100*a]},o.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let a=0;return r<1&&(a=(n-r)/(1-r)),[e[0],100*r,100*a]},o.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];const a=[0,0,0],o=t%1*6,s=o%1,i=1-s;let l=0;switch(Math.floor(o)){case 0:a[0]=1,a[1]=s,a[2]=0;break;case 1:a[0]=i,a[1]=1,a[2]=0;break;case 2:a[0]=0,a[1]=1,a[2]=s;break;case 3:a[0]=0,a[1]=i,a[2]=1;break;case 4:a[0]=s,a[1]=0,a[2]=1;break;default:a[0]=1,a[1]=0,a[2]=i}return l=(1-n)*r,[255*(n*a[0]+l),255*(n*a[1]+l),255*(n*a[2]+l)]},o.hcg.hsv=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);let r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},o.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100*(1-t)+.5*t;let r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},o.hcg.hwb=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},o.hwb.hcg=function(e){const t=e[1]/100,n=1-e[2]/100,r=n-t;let a=0;return r<1&&(a=(n-r)/(1-r)),[e[0],100*r,100*a]},o.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},o.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},o.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},o.gray.hsl=function(e){return[0,0,e[0]]},o.gray.hsv=o.gray.hsl,o.gray.hwb=function(e){return[0,100,e[0]]},o.gray.cmyk=function(e){return[0,0,0,e[0]]},o.gray.lab=function(e){return[e[0],0,0]},o.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n},o.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},9:(e,t,n)=>{const r=n(5635),a=n(482),o={};Object.keys(r).forEach((e=>{o[e]={},Object.defineProperty(o[e],"channels",{value:r[e].channels}),Object.defineProperty(o[e],"labels",{value:r[e].labels});const t=a(e);Object.keys(t).forEach((n=>{const r=t[n];o[e][n]=function(e){const t=function(...t){const n=t[0];if(null==n)return n;n.length>1&&(t=n);const r=e(t);if("object"==typeof r)for(let e=r.length,t=0;t<e;t++)r[t]=Math.round(r[t]);return r};return"conversion"in e&&(t.conversion=e.conversion),t}(r),o[e][n].raw=function(e){const t=function(...t){const n=t[0];return null==n?n:(n.length>1&&(t=n),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}(r)}))})),e.exports=o},482:(e,t,n)=>{const r=n(5635);function a(e){const t=function(){const e={},t=Object.keys(r);for(let n=t.length,r=0;r<n;r++)e[t[r]]={distance:-1,parent:null};return e}(),n=[e];for(t[e].distance=0;n.length;){const e=n.pop(),a=Object.keys(r[e]);for(let r=a.length,o=0;o<r;o++){const r=a[o],s=t[r];-1===s.distance&&(s.distance=t[e].distance+1,s.parent=e,n.unshift(r))}}return t}function o(e,t){return function(n){return t(e(n))}}function s(e,t){const n=[t[e].parent,e];let a=r[t[e].parent][e],s=t[e].parent;for(;t[s].parent;)n.unshift(t[s].parent),a=o(r[t[s].parent][s],a),s=t[s].parent;return a.conversion=n,a}e.exports=function(e){const t=a(e),n={},r=Object.keys(t);for(let e=r.length,a=0;a<e;a++){const e=r[a];null!==t[e].parent&&(n[e]=s(e,t))}return n}},9448:e=>{"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},2181:e=>{"use strict";e.exports={stdout:!1,stderr:!1}},2645:(e,t,n)=>{"use strict";const r=n(9640),{stdout:a,stderr:o}=n(2181),{stringReplaceAll:s,stringEncaseCRLFWithFirstIndex:i}=n(1957),{isArray:l}=Array,c=["ansi","ansi","ansi256","ansi16m"],u=Object.create(null);class ChalkClass{constructor(e){return p(e)}}const p=e=>{const t={};return((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");const n=a?a.level:0;e.level=void 0===t.level?n:t.level})(t,e),t.template=(...e)=>S(t.template,...e),Object.setPrototypeOf(t,d.prototype),Object.setPrototypeOf(t.template,t),t.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},t.template.Instance=ChalkClass,t.template};function d(e){return p(e)}for(const[e,t]of Object.entries(r))u[e]={get(){const n=b(this,y(t.open,t.close,this._styler),this._isEmpty);return Object.defineProperty(this,e,{value:n}),n}};u.visible={get(){const e=b(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:e}),e}};const f=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(const e of f)u[e]={get(){const{level:t}=this;return function(...n){const a=y(r.color[c[t]][e](...n),r.color.close,this._styler);return b(this,a,this._isEmpty)}}};for(const e of f){u["bg"+e[0].toUpperCase()+e.slice(1)]={get(){const{level:t}=this;return function(...n){const a=y(r.bgColor[c[t]][e](...n),r.bgColor.close,this._styler);return b(this,a,this._isEmpty)}}}}const h=Object.defineProperties((()=>{}),{...u,level:{enumerable:!0,get(){return this._generator.level},set(e){this._generator.level=e}}}),y=(e,t,n)=>{let r,a;return void 0===n?(r=e,a=t):(r=n.openAll+e,a=t+n.closeAll),{open:e,close:t,openAll:r,closeAll:a,parent:n}},b=(e,t,n)=>{const r=(...e)=>l(e[0])&&l(e[0].raw)?m(r,S(r,...e)):m(r,1===e.length?""+e[0]:e.join(" "));return Object.setPrototypeOf(r,h),r._generator=e,r._styler=t,r._isEmpty=n,r},m=(e,t)=>{if(e.level<=0||!t)return e._isEmpty?"":t;let n=e._styler;if(void 0===n)return t;const{openAll:r,closeAll:a}=n;if(-1!==t.indexOf(""))for(;void 0!==n;)t=s(t,n.close,n.open),n=n.parent;const o=t.indexOf("\n");return-1!==o&&(t=i(t,a,r,o)),r+t+a};let g;const S=(e,...t)=>{const[r]=t;if(!l(r)||!l(r.raw))return t.join(" ");const a=t.slice(1),o=[r.raw[0]];for(let e=1;e<r.length;e++)o.push(String(a[e-1]).replace(/[{}\\]/g,"\\$&"),String(r.raw[e]));return void 0===g&&(g=n(1070)),g(e,o.join(""))};Object.defineProperties(d.prototype,u);const P=d();P.supportsColor=a,P.stderr=d({level:o?o.level:0}),P.stderr.supportsColor=o,e.exports=P},1070:e=>{"use strict";const t=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,n=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,r=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,a=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi,o=new Map([["n","\n"],["r","\r"],["t","\t"],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a",""]]);function s(e){const t="u"===e[0],n="{"===e[1];return t&&!n&&5===e.length||"x"===e[0]&&3===e.length?String.fromCharCode(parseInt(e.slice(1),16)):t&&n?String.fromCodePoint(parseInt(e.slice(2,-1),16)):o.get(e)||e}function i(e,t){const n=[],o=t.trim().split(/\s*,\s*/g);let i;for(const t of o){const o=Number(t);if(Number.isNaN(o)){if(!(i=t.match(r)))throw new Error(`Invalid Chalk template style argument: ${t} (in style '${e}')`);n.push(i[2].replace(a,((e,t,n)=>t?s(t):n)))}else n.push(o)}return n}function l(e){n.lastIndex=0;const t=[];let r;for(;null!==(r=n.exec(e));){const e=r[1];if(r[2]){const n=i(e,r[2]);t.push([e].concat(n))}else t.push([e])}return t}function c(e,t){const n={};for(const e of t)for(const t of e.styles)n[t[0]]=e.inverse?null:t.slice(1);let r=e;for(const[e,t]of Object.entries(n))if(Array.isArray(t)){if(!(e in r))throw new Error(`Unknown Chalk style: ${e}`);r=t.length>0?r[e](...t):r[e]}return r}e.exports=(e,n)=>{const r=[],a=[];let o=[];if(n.replace(t,((t,n,i,u,p,d)=>{if(n)o.push(s(n));else if(u){const t=o.join("");o=[],a.push(0===r.length?t:c(e,r)(t)),r.push({inverse:i,styles:l(u)})}else if(p){if(0===r.length)throw new Error("Found extraneous } in Chalk template literal");a.push(c(e,r)(o.join(""))),o=[],r.pop()}else o.push(d)})),a.push(o.join("")),r.length>0){const e=`Chalk template literal is missing ${r.length} closing bracket${1===r.length?"":"s"} (\`}\`)`;throw new Error(e)}return a.join("")}},1957:e=>{"use strict";e.exports={stringReplaceAll:(e,t,n)=>{let r=e.indexOf(t);if(-1===r)return e;const a=t.length;let o=0,s="";do{s+=e.substr(o,r-o)+t+n,o=r+a,r=e.indexOf(t,o)}while(-1!==r);return s+=e.substr(o),s},stringEncaseCRLFWithFirstIndex:(e,t,n,r)=>{let a=0,o="";do{const s="\r"===e[r-1];o+=e.substr(a,(s?r-1:r)-a)+t+(s?"\r\n":"\n")+n,a=r+1,r=e.indexOf("\n",a)}while(-1!==r);return o+=e.substr(a),o}}},5881:e=>{var t=1e3,n=60*t,r=60*n,a=24*r,o=7*a,s=365.25*a;function i(e,t,n,r){var a=t>=1.5*n;return Math.round(e/n)+" "+r+(a?"s":"")}e.exports=function(e,l){l=l||{};var c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!i)return;var l=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return l*s;case"weeks":case"week":case"w":return l*o;case"days":case"day":case"d":return l*a;case"hours":case"hour":case"hrs":case"hr":case"h":return l*r;case"minutes":case"minute":case"mins":case"min":case"m":return l*n;case"seconds":case"second":case"secs":case"sec":case"s":return l*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:return}}(e);if("number"===c&&isFinite(e))return l.long?function(e){var o=Math.abs(e);if(o>=a)return i(e,o,a,"day");if(o>=r)return i(e,o,r,"hour");if(o>=n)return i(e,o,n,"minute");if(o>=t)return i(e,o,t,"second");return e+" ms"}(e):function(e){var o=Math.abs(e);if(o>=a)return Math.round(e/a)+"d";if(o>=r)return Math.round(e/r)+"h";if(o>=n)return Math.round(e/n)+"m";if(o>=t)return Math.round(e/t)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},5130:(e,t,n)=>{t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,a=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(a=r))})),t.splice(a,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(7123)(t);const{formatters:r}=e.exports;r.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},7123:(e,t,n)=>{e.exports=function(e){function t(e){let n,a,o,s=null;function i(...e){if(!i.enabled)return;const r=i,a=Number(new Date),o=a-(n||a);r.diff=o,r.prev=n,r.curr=a,n=a,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let s=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,a)=>{if("%%"===n)return"%";s++;const o=t.formatters[a];if("function"==typeof o){const t=e[s];n=o.call(r,t),e.splice(s,1),s--}return n})),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=r,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(a!==t.namespaces&&(a=t.namespaces,o=t.enabled(e)),o),set:e=>{s=e}}),"function"==typeof t.init&&t.init(i),i}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function a(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(a),...t.skips.map(a).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),a=r.length;for(n=0;n<a;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.slice(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(5881),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((n=>{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},161:e=>{"use strict";var t=Object.prototype.hasOwnProperty,n="~";function r(){}function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,r,o,s){if("function"!=typeof r)throw new TypeError("The listener must be a function");var i=new a(r,o||e,s),l=n?n+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],i]:e._events[l].push(i):(e._events[l]=i,e._eventsCount++),e}function s(e,t){0==--e._eventsCount?e._events=new r:delete e._events[t]}function i(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),i.prototype.eventNames=function(){var e,r,a=[];if(0===this._eventsCount)return a;for(r in e=this._events)t.call(e,r)&&a.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?a.concat(Object.getOwnPropertySymbols(e)):a},i.prototype.listeners=function(e){var t=n?n+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var a=0,o=r.length,s=new Array(o);a<o;a++)s[a]=r[a].fn;return s},i.prototype.listenerCount=function(e){var t=n?n+e:e,r=this._events[t];return r?r.fn?1:r.length:0},i.prototype.emit=function(e,t,r,a,o,s){var i=n?n+e:e;if(!this._events[i])return!1;var l,c,u=this._events[i],p=arguments.length;if(u.fn){switch(u.once&&this.removeListener(e,u.fn,void 0,!0),p){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,t),!0;case 3:return u.fn.call(u.context,t,r),!0;case 4:return u.fn.call(u.context,t,r,a),!0;case 5:return u.fn.call(u.context,t,r,a,o),!0;case 6:return u.fn.call(u.context,t,r,a,o,s),!0}for(c=1,l=new Array(p-1);c<p;c++)l[c-1]=arguments[c];u.fn.apply(u.context,l)}else{var d,f=u.length;for(c=0;c<f;c++)switch(u[c].once&&this.removeListener(e,u[c].fn,void 0,!0),p){case 1:u[c].fn.call(u[c].context);break;case 2:u[c].fn.call(u[c].context,t);break;case 3:u[c].fn.call(u[c].context,t,r);break;case 4:u[c].fn.call(u[c].context,t,r,a);break;default:if(!l)for(d=1,l=new Array(p-1);d<p;d++)l[d-1]=arguments[d];u[c].fn.apply(u[c].context,l)}}return!0},i.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},i.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},i.prototype.removeListener=function(e,t,r,a){var o=n?n+e:e;if(!this._events[o])return this;if(!t)return s(this,o),this;var i=this._events[o];if(i.fn)i.fn!==t||a&&!i.once||r&&i.context!==r||s(this,o);else{for(var l=0,c=[],u=i.length;l<u;l++)(i[l].fn!==t||a&&!i[l].once||r&&i[l].context!==r)&&c.push(i[l]);c.length?this._events[o]=1===c.length?c[0]:c:s(this,o)}return this},i.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&s(this,t)):(this._events=new r,this._eventsCount=0),this},i.prototype.off=i.prototype.removeListener,i.prototype.addListener=i.prototype.on,i.prefixed=n,i.EventEmitter=i,e.exports=i},5163:(e,t,n)=>{"use strict";n.r(t),n.d(t,{__assign:()=>o,__asyncDelegator:()=>E,__asyncGenerator:()=>$,__asyncValues:()=>x,__await:()=>O,__awaiter:()=>h,__classPrivateFieldGet:()=>L,__classPrivateFieldIn:()=>C,__classPrivateFieldSet:()=>T,__createBinding:()=>b,__decorate:()=>i,__esDecorate:()=>c,__exportStar:()=>m,__extends:()=>a,__generator:()=>y,__importDefault:()=>I,__importStar:()=>j,__makeTemplateObject:()=>k,__metadata:()=>f,__param:()=>l,__propKey:()=>p,__read:()=>S,__rest:()=>s,__runInitializers:()=>u,__setFunctionName:()=>d,__spread:()=>P,__spreadArray:()=>w,__spreadArrays:()=>v,__values:()=>g});var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)};function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var o=function(){return o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},o.apply(this,arguments)};function s(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n}function i(e,t,n,r){var a,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var i=e.length-1;i>=0;i--)(a=e[i])&&(s=(o<3?a(s):o>3?a(t,n,s):a(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s}function l(e,t){return function(n,r){t(n,r,e)}}function c(e,t,n,r,a,o){function s(e){if(void 0!==e&&"function"!=typeof e)throw new TypeError("Function expected");return e}for(var i,l=r.kind,c="getter"===l?"get":"setter"===l?"set":"value",u=!t&&e?r.static?e:e.prototype:null,p=t||(u?Object.getOwnPropertyDescriptor(u,r.name):{}),d=!1,f=n.length-1;f>=0;f--){var h={};for(var y in r)h[y]="access"===y?{}:r[y];for(var y in r.access)h.access[y]=r.access[y];h.addInitializer=function(e){if(d)throw new TypeError("Cannot add initializers after decoration has completed");o.push(s(e||null))};var b=(0,n[f])("accessor"===l?{get:p.get,set:p.set}:p[c],h);if("accessor"===l){if(void 0===b)continue;if(null===b||"object"!=typeof b)throw new TypeError("Object expected");(i=s(b.get))&&(p.get=i),(i=s(b.set))&&(p.set=i),(i=s(b.init))&&a.push(i)}else(i=s(b))&&("field"===l?a.push(i):p[c]=i)}u&&Object.defineProperty(u,r.name,p),d=!0}function u(e,t,n){for(var r=arguments.length>2,a=0;a<t.length;a++)n=r?t[a].call(e,n):t[a].call(e);return r?n:void 0}function p(e){return"symbol"==typeof e?e:"".concat(e)}function d(e,t,n){return"symbol"==typeof t&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:n?"".concat(n," ",t):t})}function f(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function h(e,t,n,r){return new(n||(n=Promise))((function(a,o){function s(e){try{l(r.next(e))}catch(e){o(e)}}function i(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,i)}l((r=r.apply(e,t||[])).next())}))}function y(e,t){var n,r,a,o,s={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function i(i){return function(l){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,i[0]&&(s=0)),s;)try{if(n=1,r&&(a=2&i[0]?r.return:i[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,i[1])).done)return a;switch(r=0,a&&(i=[2&i[0],a.value]),i[0]){case 0:case 1:a=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!(a=s.trys,(a=a.length>0&&a[a.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!a||i[1]>a[0]&&i[1]<a[3])){s.label=i[1];break}if(6===i[0]&&s.label<a[1]){s.label=a[1],a=i;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(i);break}a[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=a=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}var b=Object.create?function(e,t,n,r){void 0===r&&(r=n);var a=Object.getOwnPropertyDescriptor(t,n);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,a)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]};function m(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||b(t,e,n)}function g(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function S(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)s.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return s}function P(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(S(arguments[t]));return e}function v(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),a=0;for(t=0;t<n;t++)for(var o=arguments[t],s=0,i=o.length;s<i;s++,a++)r[a]=o[s];return r}function w(e,t,n){if(n||2===arguments.length)for(var r,a=0,o=t.length;a<o;a++)!r&&a in t||(r||(r=Array.prototype.slice.call(t,0,a)),r[a]=t[a]);return e.concat(r||Array.prototype.slice.call(t))}function O(e){return this instanceof O?(this.v=e,this):new O(e)}function $(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,a=n.apply(e,t||[]),o=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(e){a[e]&&(r[e]=function(t){return new Promise((function(n,r){o.push([e,t,n,r])>1||i(e,t)}))})}function i(e,t){try{(n=a[e](t)).value instanceof O?Promise.resolve(n.value.v).then(l,c):u(o[0][2],n)}catch(e){u(o[0][3],e)}var n}function l(e){i("next",e)}function c(e){i("throw",e)}function u(e,t){e(t),o.shift(),o.length&&i(o[0][0],o[0][1])}}function E(e){var t,n;return t={},r("next"),r("throw",(function(e){throw e})),r("return"),t[Symbol.iterator]=function(){return this},t;function r(r,a){t[r]=e[r]?function(t){return(n=!n)?{value:O(e[r](t)),done:!1}:a?a(t):t}:a}}function x(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=g(e),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise((function(r,a){(function(e,t,n,r){Promise.resolve(r).then((function(t){e({value:t,done:n})}),t)})(r,a,(t=e[n](t)).done,t.value)}))}}}function k(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var _=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function j(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&b(t,e,n);return _(t,e),t}function I(e){return e&&e.__esModule?e:{default:e}}function L(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)}function T(e,t,n,r,a){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!a)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!a:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?a.call(e,n):a?a.value=n:t.set(e,n),n}function C(e,t){if(null===t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("Cannot use 'in' operator on non-object");return"function"==typeof e?t===e:e.has(t)}},607:(e,t)=>{"use strict";function n(e){return this.c.get(e)?.v}Object.defineProperty(t,"__esModule",{value:!0}),t.LRU=void 0;class LRU{constructor({maxLength:e,dispose:t}){if(e<2)throw new Error("Max length must be >= 2");if(parseInt(String(e),10)!==e)throw new Error("Max length must be an integer");this.length=0,this.m=e,this.h=null,this.t=null,this.c=new Map,this.d=t||null,this.s=!1,this.get=n,this.reset()}reset(){const e=this.c.values();if(this.c.clear(),this.h=null,this.t=null,this.length=0,null!==this.d)for(const t of e)this.d(t.k,t.v)}get(e){const t=this.c.get(e);if(void 0!==t)return null===this.h?this.h=this.t=t:t!==this.h&&(t.p.n=t.n,null!==t.n?t.n.p=t.p:this.t=t.p,t.n=this.h,this.h.p=t,this.h=t,t.p=null),t.v}set(e,t){const n=this.c.get(e);if(void 0!==n)n.v=t;else{const n={k:e,v:t,n:null,p:null};this.c.set(e,n),this.a(n)}}a(e){if(null===this.h)return this.h=this.t=e,void(this.length=1);if(this.h.p=e,e.n=this.h,this.h=e,this.s){const e=this.t;this.c.delete(e.k),this.t=e.p,this.t.n=null,null!==this.d&&this.d(e.k,e.v)}else 0===this.length&&(this.t=e),this.length++,this.length===this.m&&(this.s=!0,this.get=LRU.prototype.get)}}t.LRU=LRU,t.default=LRU},7073:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.undefined=t.tmp=t.tempVar=t.te=t.substring=t.subcomment=t.set=t.safeKeyOrThrow=t.runInBatch=t.run=t.ref=t.optionalGet=t.literal=t.lit=t.join=t.isTE=t.identifier=t.get=t.eval=t.dangerouslyIncludeRawCode=t.dangerousKey=t.compile=t.cache=t.batch=t.Idents=t.isSafeObjectPropertyName=t.toJSON=t.stringifyJSON=t.stringifyString=void 0;const r=n(2008),a=n(5570);function o(e,t){const n=e.$$export;if(n){if(n.exportName!==t)throw new Error(`Attempted to export same thing under multiple names '${n.exportName}' and '${t}'`)}else Object.defineProperty(e,"$$export",{value:{moduleName:"tamedevil",exportName:t}});return e}const s="undefined"!=typeof process&&!1;function i(e){return{[a.$$type]:"RAW",t:e}}function l(e,t){const n={[a.$$type]:"RAW",t:e};return o(n,t),n}function c(e,t){return Object.freeze({[a.$$type]:"REF",v:e,n:t})}function u(e){return Object.freeze({[a.$$type]:"INDENT",c:"QUERY"===e[a.$$type]?e:p([e])})}function p(e){return Object.freeze({[a.$$type]:"QUERY",n:e})}function d(e){return"object"==typeof e&&null!==e&&"string"==typeof e[a.$$type]}function f(e,t){if(d(e))return e;throw new Error(`[tamedevil] Invalid expression. Expected an TE item${t?` at ${t}`:""} but received '${String(e)}'. This may mean that there is an issue in the TE expression where a dynamic value was not escaped via 'te.ref(...)', an embedded string wasn't wrapped with 'te.string(...)', or a TE expression was added without using the \`te\` tagged template literal.`)}t.isTE=d;const h=(e,t,n,r)=>{const a=t.get(n);if(a)return a;const o=t.size+1;if(o>65535)throw new Error("[tamedevil] This TE statement would contain too many placeholders; tamedevil supports at most 65535 placeholders. To solve this, consider passing multiple values in using a single array or object.");const s=r?function(e,t){if(!(t in e))return t;for(let n=0;n<1e6;n++){const r=t+n;if(!(r in e))return r}throw new Error("Failed to find an available variable name to use")}(e,r):`_$$_ref_${o}`;return t.set(n,s),e[s]=n,s},y=(e,t)=>{const n=e.get(t);if(n)return n;const r=`_$_tmp${e.size+1}`;return e.set(t,r),r};function b(e,t,n,r,o=0){let i="";switch(null==e&&f(e),e[a.$$type]){case"QUERY":for(const a of e.n)i+=b(a,t,n,r,o);break;case"RAW":if(""===e.t)break;i+=s?e.t.replace(/\n/g,"\n"+" ".repeat(o)):e.t;break;case"REF":i+=h(t,n,e.v,e.n);break;case"VARIABLE":i+=y(r,e.s);break;case"INDENT":if(!s)throw new Error("INDENT nodes only allowed in development mode");i+="\n"+" ".repeat(o+1),i+=b(e.c,t,n,r,o+1),i+="\n"+" ".repeat(o);break;default:throw new Error(`Unsupported node found in TE: ${String(f(e))}`)}return i}function m(e){const t=Object.create(null),n=new Map,r=new Map;let a=b(e,t,n,r),o="";for(const e of r.values())o+=`let ${e};\n`;o.length>0&&(a=o+"\n"+a);return{string:s?a.replace(/\n\s*\n/g,"\n"):a,refs:t}}t.compile=m;const g=function(e,...t){if(!Array.isArray(e)||!e.raw)throw new Error("[tamedevil] te should be used as a template literal, not a function call.");const n=e.length;if(1===n){const t=e[0];return""===t?$:"undefined"===t?E:i(t)}if(2===n&&""===e[0]&&""===e[1]){const e=t[0];return void 0!==e[a.$$type]?e:f(e)}const r=[];let o=null,s="";const l=n-1;for(let c=0;c<n;c++){const n=e[c];if(s+=n,c!==l){const e=t[c],n=void 0!==e[a.$$type]?e:f(e,`literal placeholder ${c}`);if("RAW"===n[a.$$type])o=n,s+=n.t;else if("QUERY"===n[a.$$type]){const e=n.n,t=e.length;for(let n=0;n<t;n++){const t=e[n];"RAW"===t[a.$$type]?(o=t,s+=t.t):(""!==s&&(null!==o&&o.t===s||(o=i(s)),r.push(o),s=""),r.push(t))}}else""!==s&&(null!==o&&o.t===s||(o=i(s)),r.push(o),s=""),r.push(n)}}return""!==s&&(null!==o&&o.t===s||(o=i(s)),r.push(o),s=""),1===r.length?r[0]:p(r)},S=Object.create(null);function P(e){if(1!==e.length)throw new Error("te.cache can currently only be used with a static string");const t=e[0],n=S[t];if(n)return n;const r=i(t);return S[t]=r,r}t.cache=P;let v=!1;function w(e){if(!v){v=!0;try{throw new Error("te.dangerouslyIncludeRawCode first invoked here")}catch(e){console.warn(`[tamedevil] WARNING: you're using the te.dangerouslyIncludeRawCode escape hatch, usage of this API is rarely required and is highly discouraged due to the potential security ramifications. Please be sure this is what you intend. ${e.stack}`)}}if("string"!=typeof e)throw new Error(`[tamedevil] te.dangerouslyIncludeRawCode must be passed a string, but it was passed '${String(e)}'.`);return i(e)}function O(e,t){if(null!=t){if(!A(t))throw new Error(`Invalid variable name '${t}'`);return c(e,t)}return c(e)}t.dangerouslyIncludeRawCode=w,t.ref=O;const $=l("","blank"),E=l("undefined","undefined");t.undefined=E;const x=200,k="\\".charCodeAt(0),_='"'.charCodeAt(0);function j(e){const t=e.length;if(t>x)return JSON.stringify(e);for(let n=0;n<t;n++){const t=e.charCodeAt(n);if(t===k||t===_||0==(65504&t)||0!=(49152&t))return JSON.stringify(e)}return`"${e}"`}t.stringifyString=j;function I(e){if(void 0===e)return E;if(null===e||"string"==typeof e||"boolean"==typeof e||"number"==typeof e&&Number.isFinite(e)){const n=e;return i((0,t.stringifyJSON)(n))}return O(e)}function L(e,t){if("string"!=typeof e||"string"!=typeof t)throw new Error("Invalid call to te.substring");const n=e.length;if(n<x){const r=t.charCodeAt(0);let a=!0;for(let t=0;t<n;t++){const n=e.charCodeAt(t);if(n===k||n===r||0==(65504&n)||0!=(49152&n)){a=!1;break}}if(a)return i(e)}const r=JSON.stringify(e),a=r.substring(1,r.length-1);return i('"'===t?a:"'"===t?a.replace(/'/g,"\\'"):a.replace(/[`$]/g,"\\$&"))}function T(e){return i(String(e).replace(/\*\//g,"* /"))}t.stringifyJSON=e=>{if(null==e)return"null";if(!0===e)return"true";if(!1===e)return"false";const t=typeof e;return"number"===t?""+e:"string"===t?j(e):JSON.stringify(e)},t.toJSON=t.stringifyJSON,t.lit=I,t.literal=I,t.substring=L,t.subcomment=T;const C=[...Object.getOwnPropertyNames(Object.prototype),...Object.getOwnPropertySymbols(Object.prototype)];t.isSafeObjectPropertyName=e=>("number"==typeof e||"symbol"==typeof e||"string"==typeof e&&/^(?:[0-9a-z$]|_[a-z0-9$])[a-z0-9_$]*$/i.test(e))&&!C.includes(e);function A(e){return!r.reservedWords.has(e)&&!!/^[a-zA-Z_$][a-zA-Z0-9_$]*$/.test(e)}function N(e){if("string"!=typeof e||!A(e))throw new Error(`Invalid identifier name '${e}'`);return i(e)}function M(e){if((0,t.isSafeObjectPropertyName)(e))return(e=>Number.isFinite(e)||"string"==typeof e&&("_"===e||/^(?:[a-z$]|_[a-z0-9$])[a-z0-9_$]*$/i.test(e)))(e)?i(String(e)):i(JSON.stringify(e));throw new Error(`Forbidden object key: ${JSON.stringify(e)}; consider using 'Object.create(null)' and assigning properties using te.lit.`)}function B(e){return e.length<x&&/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(e)}function D(e){return"string"==typeof e&&B(e)?i(`.${e}`):"string"==typeof e||"number"==typeof e&&Number.isFinite(e)?i(`[${(0,t.stringifyJSON)(e)}]`):K`[${K.lit(e)}]`}function R(e){return"string"==typeof e&&B(e)?i(`?.${e}`):"string"==typeof e||"number"==typeof e&&Number.isFinite(e)?i(`?.[${(0,t.stringifyJSON)(e)}]`):K`?.[${K.lit(e)}]`}function G(e,n=!1){if(!n&&C.includes(e))throw new Error(`Attempted to set '${String(e)}' on an object that isn't declared as having a null prototype. This could be unsafe.`);return"string"==typeof e&&B(e)?i(`.${e}`):"string"==typeof e||"number"==typeof e&&Number.isFinite(e)?i(`[${(0,t.stringifyJSON)(e)}]`):K`[${K.lit(e)}]`}function F(e=Symbol()){if("symbol"!=typeof e)throw new Error("Invalid call to te.tempVar");return function(e){return Object.freeze({[a.$$type]:"VARIABLE",s:e})}(e)}function z(e,t){const n=void 0!==e[a.$$type]?e:f(e),r=K.tempVar();return K`(${r} = ${n}, ${t(r)})`}function V(e,...t){if("raw"in e)return V(K(e,...t));if(t.length>0)throw new Error("Invalid call to `te.run`");const n=m(void 0!==e[a.$$type]?e:f(e)),r=Object.keys(n.refs),o=Object.values(n.refs);if(s&&q)throw new Error("te.run called, but batch is active - recommend you use runInBatch");try{return function(...e){return new Function(...e)}(...r,n.string)(...o)}catch(e){throw console.error("Error occurred during code generation:"),console.error(e),console.error("Function definition:"),console.error(n.string),new Error("Error occurred during code generation.")}}t.identifier=N,t.dangerousKey=M,t.safeKeyOrThrow=M,t.get=D,t.optionalGet=R,t.set=G,t.tempVar=F,t.tmp=z,t.eval=V,t.run=V;let q=null;function H(e,t){if(!q)throw new Error("te.runInBatch failed - there's no active batch");q.push({fragment:e,callback:t})}function U(e){if(q)throw new Error("te.batch failed - there's already a batch in progress");let t;try{q=[],e(),t=q}finally{q=null}if(0===t.length)return;const n=K`return [\n${K.join(t.map((e=>e.fragment)),",\n")}\n];`,r=K.run(n);for(let e=0,n=t.length;e<n;e++)t[e].callback(r[e])}function Q(e,t=""){if(!Array.isArray(e))throw new Error(`[tamedevil] Invalid te.join call - the first argument should be an array, but it was '${String(e)}'.`);if("string"!=typeof t)throw new Error(`[tamedevil] Invalid separator passed to te.join - must be a string, but we received '${String(t)}'`);if(0===e.length)return $;if(1===e.length){const t=e[0];return void 0!==t[a.$$type]?t:f(t,"join item 0")}const n=t.length>0;let r="";const o=[];for(let s=0,l=e.length;s<l;s++){const l=e[s],c=void 0!==l[a.$$type]?l:f(l,`join item ${s}`);if(s>0&&n&&(r+=t),"QUERY"===c[a.$$type])for(const e of c.n)"RAW"===e[a.$$type]?r+=e.t:(""!==r&&(o.push(i(r)),r=""),o.push(e));else"RAW"===c[a.$$type]?r+=c.t:(""!==r&&(o.push(i(r)),r=""),o.push(c))}return""!==r&&(o.push(i(r)),r=""),1===o.length?o[0]:p(o)}t.runInBatch=H,t.batch=U,t.join=Q;t.Idents=class Idents{constructor(){this.idents=new Set(r.reservedWords)}forbid(e){for(const t in e)this.idents.add(t)}makeSafeIdentifier(e){const{idents:t}=this,n="i_"+e.replace(/[^a-zA-Z0-9_$]+/g,"").replace(/_+/,"_");let r;for(let e=1;e<1e4;e++){const a=n+(e>1?String(e):"");if(!t.has(a)){r=a;break}}if(!r)throw new Error("Too many identifiers!");return t.add(r),r}};const K=g;t.te=K,t.default=K;const W={te:K,cache:P,ref:O,reference:O,lit:I,literal:I,substring:L,subcomment:T,join:Q,identifier:N,safeKeyOrThrow:M,dangerousKey:M,get:D,optionalGet:R,set:G,tmp:z,tempVar:F,run:V,eval:V,runInBatch:H,batch:U,compile:m,indent:function(e,...t){const n="raw"in e?K(e,...t):void 0!==e[a.$$type]?e:f(e);return s?u(n):n},indentIf:function(e,t){const n=void 0!==t[a.$$type]?t:f(t);return s&&e?u(n):n},undefined:E,blank:$,isTE:d,dangerouslyIncludeRawCode:w};Object.entries(W).forEach((([e,t])=>{t.$$export||o(t,e)})),Object.assign(g,W)},2008:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reservedWords=void 0,t.reservedWords=new Set(["await","break","case","catch","class","const","continue","debugger","default","delete","do","else","export","extends","false","finally","for","function","if","import","in","instanceof","new","null","return","super","switch","this","throw","true","try","typeof","var","void","while","with","let","static","yield","enum","implements","interface","package","private","protected","public","abstract","boolean","byte","char","double","final","float","goto","int","long","native","short","synchronized","throws","transient","volatile","arguments","as","import","require","eval","Function","from","get","of","in","set","null","undefined","Math","Number","BigInt","true","false","async","window","global","globalThis","process","require","import","constructor","class"])},5570:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.$$type=void 0;t.$$type=Symbol.for("tamedevil-type-1")},1261:e=>{"use strict";if(void 0===r){var t=new Error("Cannot find module 'undefined'");throw t.code="MODULE_NOT_FOUND",t}e.exports=r},8372:t=>{"use strict";t.exports=e},9402:e=>{"use strict";e.exports=n},1138:e=>{"use strict";if(void 0===t){var n=new Error("Cannot find module 'undefined'");throw n.code="MODULE_NOT_FOUND",n}e.exports=t},553:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.applyHooks=t.AsyncHooks=void 0;const r=n(282);t.AsyncHooks=class AsyncHooks{constructor(){this.callbacks=Object.create(null)}hook(e,t){this.callbacks[e]=this.callbacks[e]||[],this.callbacks[e].push(t)}process(e,...t){const n=this.callbacks[e];if(!n)return;const r=n.length;let a;for(let e=0;e<r;e++){const r=n[e];if(void 0!==a)a=a.then((()=>r.apply(null,t)));else{const e=r.apply(null,t);null!=e&&(a=e)}}return a}},t.applyHooks=function(e,t,n){const a=Object.create(null);let o=0;if(e)for(const n of e){const e=t(n);if(!e)continue;const r=Object.keys(e);for(const t of r){const r=e[t];if(!r)continue;const s=e=>"function"!=typeof e,i=(e=>"function"==typeof e)(r)?r:r.callback,{provides:l,before:c,after:u}=s(r)?r:{};a[t]||(a[t]=[]);const p=String(o++);a[t].push({id:p,plugin:n,callback:i,provides:[...l||[],p,n.name],before:c||[],after:u||[]})}}for(const e in a){const t=a[e];if(!t)continue;const o=(0,r.sortWithBeforeAfterProvides)(t,"id");for(const t of o)n(e,t.callback,t.plugin)}}},5172:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sortedPlugins=t.resolvePresets=t.isResolvedPreset=t.AsyncHooks=t.applyHooks=void 0,n(2630);const r=n(282);var a=n(553);Object.defineProperty(t,"applyHooks",{enumerable:!0,get:function(){return a.applyHooks}}),Object.defineProperty(t,"AsyncHooks",{enumerable:!0,get:function(){return a.AsyncHooks}});var o=n(6600);Object.defineProperty(t,"isResolvedPreset",{enumerable:!0,get:function(){return o.isResolvedPreset}}),Object.defineProperty(t,"resolvePresets",{enumerable:!0,get:function(){return o.resolvePresets}}),t.sortedPlugins=function(e){return e?(0,r.sortWithBeforeAfterProvides)(e,"name"):[]}},2630:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},6600:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolvePresets=t.isResolvedPreset=void 0,n(2630);const r=n(282),a=["name","experimental","provides","before","after"],o=["plugins","disablePlugins","extends"];let s;try{if(s=n(1138).inspect,"function"!=typeof s)throw new Error("Failed to load inspect")}catch{s=e=>Array.isArray(e)||!e||null===Object.getPrototypeOf(e)||Object.getPrototypeOf(e)===Object.prototype?JSON.stringify(e):String(e)}function i(e){return e.plugins&&0===e.extends?.length||!1}function l(e,t=!0){if(1===e.length){const t=e[0];if(t&&i(t))return t}const n={extends:[],plugins:[],disablePlugins:[]};for(const t of e){p(n,u(t))}return n.plugins&&(n.plugins=(0,r.sortWithBeforeAfterProvides)(n.plugins,"name")),t&&n.disablePlugins&&n.disablePlugins.length>0&&console.warn(`One or more of the plugin(s) entered in your preset's 'disablePlugins' list was not found:\n${n.disablePlugins.map((e=>` - ${e}`)).join("\n")}\nThe list of know plugins is:\n ${n.plugins?.map((e=>e.name)).join(", ")??"-"}`),n}function c(e){if("object"!=typeof e||null==e)throw new Error(`Expected plugin, but found '${s(e)}'`);const t=Object.getPrototypeOf(e);if(t!==Object.prototype&&null!==t)throw new Error(`Expected plugin to be a plain object, but found '${s(e)}'`);if("string"!=typeof e.name)throw new Error(`Expected plugin to have a string 'name'; found ${s(e.name)} (${s(e)})`);if(null!=e.version&&"string"!=typeof e.version)throw new Error(`Expected plugin '${e.name}' to have a string 'version'; found ${s(e.version)}`);for(const t of o)if(e[t])throw new Error(`Plugin '${e.name}' has '${t}' property which suggests it is a preset rather than a plugin. If it is indeed a preset you should add it to your preset via 'extends' rather than 'plugins'.`)}function u(e){if(!function(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return null===t||t===Object.prototype||"[object Object]"===String(e)}(e))throw new Error(`Expected a GraphileConfig preset (a plain JS object), but found '${s(e)}'`);try{for(const t of a)if(e[t])throw new Error(`Preset has '${t}' property which suggests it is a plugin rather than a preset. If it is indeed a plugin you should add it to your preset via 'plugins' rather than 'extends'.`);const{extends:t=[]}=e,n=l(t,!1);p(n,e);const r=n.disablePlugins;if(r){const e=new Set(n.plugins),t=new Set(r);for(const n of e)c(n),t.has(n.name)&&(t.delete(n.name),e.delete(n));n.plugins=[...e],n.disablePlugins=[...t]}return n}catch(t){throw new Error(`Error occurred when resolving preset: ${t}\nPreset: ${s(e)}`)}}function p(e,t){if(null!=e.extends&&0!==e.extends.length)throw new Error("First argument to mergePreset must be a resolved preset");const n=new Set([...e.plugins||[],...t.plugins||[]]);e.plugins=[...n],t.disablePlugins&&(e.disablePlugins=[...new Set([...e.disablePlugins??[],...t.disablePlugins??[]])]);const r=Object.keys(e).filter(d),a=Object.keys(t).filter(d),o=[...new Set([...r,...a])];for(const n of o){const r=e[n],a=t[n];if(r&&a){if(Array.isArray(r)!==Array.isArray(a))throw new Error(`${n} contains an array entry in one preset and a non-array entry in another, this doesn't make sense`);Array.isArray(a)?e[n]=a:e[n]=Object.assign(Object.create(null),r,a)}else e[n]=r||a}}function d(e){return"extends"!==e&&"plugins"!==e&&"disablePlugins"!==e}t.isResolvedPreset=i,t.resolvePresets=l},282:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sortWithBeforeAfterProvides=void 0,t.sortWithBeforeAfterProvides=function(e,t){const n=e.map((e=>{const n=[...e.before??[]],r=[...e.after??[]],a=[...e.provides??[]];return a.includes(e[t])||a.push(e[t]),{thing:e,before:n,after:r,provides:a}}));for(const{thing:e,before:r}of n){const{[t]:a}=e;if(r.length){const t=r.splice(0,r.length);for(const{thing:r,provides:o,after:s}of n)r!==e&&t.some((e=>o.includes(e)))&&s.push(a)}}const r=new Set;for(const{provides:e}of n)for(const t of e)r.add(t);for(const{after:e}of n)e.splice(0,e.length,...e.filter((e=>r.has(e))));const a=[],o=[...n];for(let e=0;e<1e4;e++){let e=0;if(0===o.length)break;for(let t=0;t<o.length;t++){const n=o[t];if(!n)continue;const{thing:r,after:s}=n;o.some((({thing:e,provides:t})=>e!==r&&t.some((e=>s.includes(e)))))||(e++,o.splice(t,1),a.push(r),t--)}if(0===e)throw new Error(`Infinite loop in dependencies detected; remaining items:\n ${o.map((e=>`${e.thing[t]} (after: ${e.after}; provides: ${e.provides})`)).join("\n ")}`)}if(a.length!==n.length)throw new Error(`Expected the same number of list entries after sorting (${a.length} != ${n.length})`);return a}},835:(e,t,n)=>{"use strict";n.r(t),n.d(t,{$$asyncIterator:()=>y,$$iterator:()=>o,createAsyncIterator:()=>S,createIterator:()=>p,forAwaitEach:()=>w,forEach:()=>f,getAsyncIterator:()=>m,getAsyncIteratorMethod:()=>g,getIterator:()=>c,getIteratorMethod:()=>u,isArrayLike:()=>i,isAsyncIterable:()=>b,isCollection:()=>l,isIterable:()=>s});var r="function"==typeof Symbol?Symbol:void 0,a=r&&r.iterator,o=a||"@@iterator";function s(e){return!!u(e)}function i(e){var t=null!=e&&e.length;return"number"==typeof t&&t>=0&&t%1==0}function l(e){return Object(e)===e&&(i(e)||s(e))}function c(e){var t=u(e);if(t)return t.call(e)}function u(e){if(null!=e){var t=a&&e[a]||e["@@iterator"];if("function"==typeof t)return t}}function p(e){if(null!=e){var t=c(e);if(t)return t;if(i(e))return new d(e)}}function d(e){this._o=e,this._i=0}function f(e,t,n){if(null!=e){if("function"==typeof e.forEach)return e.forEach(t,n);var r=0,a=c(e);if(a){for(var o;!(o=a.next()).done;)if(t.call(n,o.value,r++,e),r>9999999)throw new TypeError("Near-infinite iteration.")}else if(i(e))for(;r<e.length;r++)e.hasOwnProperty(r)&&t.call(n,e[r],r,e)}}d.prototype[o]=function(){return this},d.prototype.next=function(){return void 0===this._o||this._i>=this._o.length?(this._o=void 0,{value:void 0,done:!0}):{value:this._o[this._i++],done:!1}};var h=r&&r.asyncIterator,y=h||"@@asyncIterator";function b(e){return!!g(e)}function m(e){var t=g(e);if(t)return t.call(e)}function g(e){if(null!=e){var t=h&&e[h]||e["@@asyncIterator"];if("function"==typeof t)return t}}function S(e){if(null!=e){var t=m(e);if(t)return t;var n=p(e);if(n)return new P(n)}}function P(e){this._i=e}function v(e,t,n){var r;return new Promise((function(a){a((r=e[t](n)).value)})).then((function(e){return{value:e,done:r.done}}))}function w(e,t,n){var r=S(e);if(r){var a=0;return new Promise((function(o,s){!function i(){return r.next().then((function(r){return r.done?o():Promise.resolve(t.call(n,r.value,a++,e)).then(i).catch(s),null})).catch(s),null}()}))}}P.prototype[y]=function(){return this},P.prototype.next=function(e){return v(this._i,"next",e)},P.prototype.return=function(e){return this._i.return?v(this._i,"return",e):Promise.resolve({value:e,done:!0})},P.prototype.throw=function(e){return this._i.throw?v(this._i,"throw",e):Promise.reject(e)}}},s={};function i(e){var t=s[e];if(void 0!==t)return t.exports;var n=s[e]={id:e,loaded:!1,exports:{}};return o[e](n,n.exports,i),n.loaded=!0,n.exports}i.m=o,a=[],i.O=(e,t,n,r)=>{if(!t){var o=1/0;for(u=0;u<a.length;u++){for(var[t,n,r]=a[u],s=!0,l=0;l<t.length;l++)(!1&r||o>=r)&&Object.keys(i.O).every((e=>i.O[e](t[l])))?t.splice(l--,1):(s=!1,r<o&&(o=r));if(s){a.splice(u--,1);var c=n();void 0!==c&&(e=c)}}return e}r=r||0;for(var u=a.length;u>0&&a[u-1][2]>r;u--)a[u]=a[u-1];a[u]=[t,n,r]},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e={826:0};i.O.j=t=>0===e[t];var t=(t,n)=>{var r,a,[o,s,l]=n,c=0;if(o.some((t=>0!==e[t]))){for(r in s)i.o(s,r)&&(i.m[r]=s[r]);if(l)var u=l(i)}for(t&&t(n);c<o.length;c++)a=o[c],i.o(e,a)&&e[a]&&e[a][0](),e[a]=0;return i.O(u)},n=this.webpackChunkgrafast=this.webpackChunkgrafast||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))})();var l=i(5590);return l=i.O(l)})()));
|
|
497
|
+
})`,t):t((t=>null==t?t:Object.keys(e).reduce(((n,r)=>(n[r]=t[e[r]],n)),Object.create(null))))}(this.actualKeyByDesiredKey,(e=>{this.mapper=e})),super.finalize()}execute(e,t){return t[0].map(this.mapper)}unbatchedExecute(e,t){return this.mapper(t)}deduplicate(e){const t=JSON.stringify(this.actualKeyByDesiredKey);return e.filter((e=>JSON.stringify(e.actualKeyByDesiredKey)===t))}}t.RemapKeysStep=RemapKeysStep,t.remapKeys=function(e,t){return new RemapKeysStep(e,t)}},5289:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reverse=t.ReverseStep=t.reverseArray=void 0;const r=n(764);function a(e){if(!Array.isArray(e))throw new Error("Attempted to reverse an array, but what was passed wasn't an array");const t=e.length,n=[];for(let r=0;r<t;r++)n[r]=e[t-r-1];return n}t.reverseArray=a;class ReverseStep extends r.UnbatchedExecutableStep{static{this.$$export={moduleName:"grafast",exportName:"ReverseStep"}}constructor(e){super(),this.isSyncAndSafe=!0,this.allowMultipleOptimizations=!0,this.addDependency(e)}execute(e,t){return t[0].map((e=>null==e?e:a(e)))}unbatchedExecute(e,t){return null==t?t:a(t)}deduplicate(e){return e}}t.ReverseStep=ReverseStep,t.reverse=function(e){return new ReverseStep(e)}},9081:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setter=t.SetterStep=void 0;const r=n(764);class SetterStep extends r.ModifierStep{static{this.$$export={moduleName:"grafast",exportName:"SetterStep"}}constructor(e){super(e),this.setters=new Map}set(e,t){this.setters.set(e,t)}apply(){for(const[e,t]of this.setters.entries())this.$parent.set(e,t)}}t.SetterStep=SetterStep,t.setter=function(e){return new SetterStep(e)}},927:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.stringifyPayload=void 0,t.stringifyPayload=function(e,t){if(!t||"string"!=typeof e.data)return JSON.stringify(e);let n="{",r=!0;if(e.incremental)throw new Error("Haven't implemented incremental yet");if(void 0!==e.errors&&(r||(n+=","),r=!1,n+=`"errors":${JSON.stringify(e.errors)}`),void 0===e.data);else if(null===e.data)r||(n+=","),r=!1,n+='"data":null';else{if("string"!=typeof e.data)throw new Error("Expected data to be null, undefined, or a JSON string");r||(n+=","),r=!1,n+=`"data":${e.data}`}return void 0!==e.extensions&&(r||(n+=","),r=!1,n+=`"extensions":${JSON.stringify(e.extensions)}`),void 0!==e.label&&(r||(n+=","),r=!1,n+=`"label":${JSON.stringify(e.label)}`),void 0!==e.hasNext&&(r||(n+=","),r=!1,n+=`"hasNext":${JSON.stringify(e.hasNext)}`),n+="}",n}},6522:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.stripAnsi=t.ANSI_REGEXP=void 0,t.ANSI_REGEXP=/[\u001B\u009B][[\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\d\/#&.:=?%@~_]+)*|[a-zA-Z\d]+(?:;[-a-zA-Z\d\/#&.:=?%@~_]*)*)?\u0007)|(?:(?:\d{1,4}(?:;\d{0,4})*)?[\dA-PR-TZcf-nq-uy=><~]))/g,t.stripAnsi=function(e){return e.replace(t.ANSI_REGEXP,"")}},680:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.subscribe=void 0;const r=n(1610),a=n(6587);t.subscribe=function(e,t=r.NULL_PRESET,n=!1){return(0,a.withGrafastArgs)(e,t,n)}},6076:()=>{"use strict";const e=Symbol.for("grafast"),t=globalThis;if(!0===t[e]);else if(t[e])console.trace(`WARNING: more than one version of the 'grafast' module has been instantiated - you must ensure there is exactly one grafast (e.g. using yarn "resolutions" or similar techniques). Try clearing your package lockfile and reinstalling. ${t[e].stack}`),t[e]=!0;else try{throw new Error("The first 'grafast' was installed here")}catch(n){t[e]=n}},8912:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.timeSource=void 0,t.timeSource="undefined"!=typeof performance&&"function"==typeof performance.now?performance:Date},6787:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hasItemPlan=t.assertNotAsync=t.canonicalJSONStringify=t.stepsAreInSamePhase=t.stepAMayDependOnStepB=t.stepADependsOnStepB=t.isTypePlanned=t.findVariableNamesUsed=t.arrayOfLengthCb=t.arrayOfLength=t.stack=t.sharedNull=t.getEnumValueConfig=t.inputObjectFieldSpec=t.newInputObjectTypeBuilder=t.newGrafastFieldConfigBuilder=t.objectFieldSpec=t.newObjectTypeBuilder=t.objectSpec=t.arraysMatch=t.isDeferred=t.isPromiseLike=t.isPromise=t.defaultValueToValueNode=t.assertNullPrototype=t.ROOT_VALUE_OBJECT=void 0;const r=n(5163),a=r.__importStar(n(8372)),o=r.__importStar(n(9790)),s=n(4068),i=n(5509),l=n(4065),{GraphQLBoolean:c,GraphQLEnumType:u,GraphQLFloat:p,GraphQLID:d,GraphQLInputObjectType:f,GraphQLInt:h,GraphQLInterfaceType:y,GraphQLList:b,GraphQLNonNull:m,GraphQLObjectType:g,GraphQLScalarType:S,GraphQLString:P,GraphQLUnionType:v,Kind:w}=a;function O(e){if(null==e)return{kind:w.NULL};if("boolean"==typeof e)return{kind:w.BOOLEAN,value:e};if("number"==typeof e)return e===Math.round(e)?{kind:w.INT,value:String(e)}:{kind:w.FLOAT,value:String(e)};if("string"==typeof e)return{kind:w.STRING,value:e};if(Array.isArray(e))return{kind:w.LIST,values:e.map(O)};if("object"==typeof e&&null!==e)return{kind:w.OBJECT,fields:Object.keys(e).map((t=>({kind:w.OBJECT_FIELD,name:{kind:w.NAME,value:t},value:O(e[t])})))};const t=e;throw console.error(`Unhandled type when converting custom scalar to ValueNode: ${(0,l.inspect)(t)}`),new Error("Unhandled type when converting custom scalar to ValueNode")}function $(e,t){if(e instanceof m){if(null==t)throw new Error("defaultValue contained null/undefined at a position that is marked as non-null");return $(e.ofType,t)}if(void 0===t)return;if(null===t)return{kind:w.NULL};if(e===c){if("boolean"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting boolean");return{kind:w.BOOLEAN,value:t}}if(e===h){if("number"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting int");return{kind:w.INT,value:String(parseInt(String(t),10))}}if(e===p){if("number"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting int");return{kind:w.FLOAT,value:String(t)}}if(e===P||e===d){if("string"!=typeof t)throw new Error("defaultValue contained invalid value at a position expecting string");return{kind:w.STRING,value:t}}if(e instanceof u){const n=e.getValues().find((e=>e.value===t));if(!n)throw console.error(`Default contained invalid value for enum ${e.name}: ${(0,l.inspect)(t)}`),new Error(`Default contained invalid value for enum ${e.name}`);return{kind:w.ENUM,value:n.name}}if(e instanceof S)return O(t);if(e instanceof b){if(!Array.isArray(t))throw new Error("defaultValue contained invalid value at location expecting a list");return{kind:w.LIST,values:t.map((t=>{const n=$(e.ofType,t);if(void 0===n)throw new Error("defaultValue contained invalid list (contained `undefined`)");return n}))}}if(e instanceof f){if("object"!=typeof t||null===t)throw new Error("defaultValue contained invalid value at location expecting an object");const n=e.getFields(),r=[];for(const e in n){const a=n[e],o=$(a.type,void 0!==t[e]?t[e]:a.defaultValue);void 0!==o&&r.push({kind:w.OBJECT_FIELD,name:{kind:w.NAME,value:e},value:o})}return{kind:w.OBJECT,fields:r}}const n=e;throw console.error(`Encountered unexpected type when processing defaultValue ${(0,l.inspect)(n)}`),new Error("Encountered unexpected type when processing defaultValue")}function E(e){return"object"==typeof e&&null!==e&&"function"==typeof e.then&&"function"==typeof e.catch}function x(e){const{assertStep:t,...n}=e;return{...n,...t?{extensions:{...e.extensions,grafast:{assertStep:t,...e.extensions?.grafast}}}:null,fields:()=>{const t="function"==typeof e.fields?e.fields():e.fields;return Object.keys(t).reduce(((n,r)=>(n[r]=k(t[r],`${e.name}.${r}`),n)),{})}}}function k(e,t){const{plan:n,subscribePlan:r,args:a,...o}=e;N(n,`${t??"?"}.plan`),N(r,`${t??"?"}.subscribePlan`);const s=a?Object.keys(a).reduce(((e,n)=>{const{inputPlan:r,applyPlan:o,autoApplyAfterParentPlan:s,autoApplyAfterParentSubscribePlan:i,...l}=a[n];return N(r,`${t??"?"}(${n}:).inputPlan`),N(o,`${t??"?"}(${n}:).applyPlan`),e[n]={...l,...r||o?{extensions:{grafast:{...r?{inputPlan:r}:null,...s?{autoApplyAfterParentPlan:s}:null,...o?{applyPlan:o}:null,...i?{autoApplyAfterParentSubscribePlan:i}:null}}}:null},e}),Object.create(null)):{};return{...o,args:s,...n||r?{extensions:{...o.extensions,grafast:{...o.extensions?.grafast,...n?{plan:n}:null,...r?{subscribePlan:r}:null}}}:null}}function _(e,t){const{inputPlan:n,applyPlan:r,autoApplyAfterParentInputPlan:a,autoApplyAfterParentApplyPlan:o,...s}=e;return N(n,`${t??"?"}.inputPlan`),N(r,`${t??"?"}.applyPlan`),n||r?{...s,extensions:{grafast:{...n?{inputPlan:n}:null,...r?{applyPlan:r}:null,...a?{autoApplyAfterParentInputPlan:a}:null,...o?{autoApplyAfterParentApplyPlan:o}:null}}}:s}t.ROOT_VALUE_OBJECT=Object.freeze(Object.create(null)),t.assertNullPrototype=function(e,t){s.isDev&&o.strictEqual(Object.getPrototypeOf(e),null,`Expected ${t} to have a null prototype`)},t.defaultValueToValueNode=function(e,t){if(void 0!==t)return $(e,t)},t.isPromise=E,t.isPromiseLike=function(e){return null!=e&&"function"==typeof e.then},t.isDeferred=function(e){return E(e)&&"function"==typeof e.resolve&&"function"==typeof e.reject},t.arraysMatch=function(e,t,n){if(e===t)return!0;const r=e.length;if(r!==t.length)return!1;if(void 0!==n){for(let a=0;a<r;a++)if(!n(e[a],t[a]))return!1}else for(let n=0;n<r;n++)if(e[n]!==t[n])return!1;return!0},t.objectSpec=x,t.newObjectTypeBuilder=function(e){return t=>new g(x({assertStep:e,...t}))},t.objectFieldSpec=k,t.newGrafastFieldConfigBuilder=function(){return e=>e},t.newInputObjectTypeBuilder=function(){return e=>new f(function(e){return{...e,fields:()=>{const t="function"==typeof e.fields?e.fields():e.fields;return Object.keys(t).reduce(((n,r)=>(n[r]=_(t[r],`${e.name}.${r}`),n)),{})}}}(e))},t.inputObjectFieldSpec=_;const j=Symbol("valueConfigByValue");function I(e,t){switch(e.kind){case w.INT:case w.FLOAT:case w.STRING:case w.BOOLEAN:case w.NULL:case w.ENUM:return;case w.LIST:for(const n of e.values)I(n,t);return;case w.OBJECT:for(const n of e.fields)I(n.value,t);return;case w.VARIABLE:return void t.add(e.name.value);default:{const t=e;throw new Error(`Unsupported valueNode: ${JSON.stringify(t)}`)}}}function L(e,t){if(void 0!==e)for(const n of e)if(void 0!==n.arguments)for(const e of n.arguments)I(e.value,t)}function T(e,t,n){switch(L(t.directives,n),t.kind){case w.FIELD:return void C(e,t,n);case w.INLINE_FRAGMENT:L(t.directives,n);for(const r of t.selectionSet.selections)T(e,r,n);return;case w.FRAGMENT_SPREAD:{L(t.directives,n);const r=t.name.value,a=e.fragments[r];if(L(a.directives,n),a.variableDefinitions?.length)throw new i.SafeError("Grafast doesn't support variable definitions on fragments yet.");for(const t of a.selectionSet.selections)T(e,t,n);return}default:throw new Error(`Unsupported selection ${t.kind}`)}}function C(e,t,n){if(function(e,t){if(void 0!==e)for(const n of e)I(n.value,t)}(t.arguments,n),L(t.directives,n),void 0!==t.selectionSet)for(const r of t.selectionSet.selections)T(e,r,n)}function A(e,t){if(e===t)throw new Error("Invalid call to stepADependsOnStepB");for(const n of e.dependencies){if(n===t)return!0;if(A(n,t))return!0}return!1}t.getEnumValueConfig=function(e,t){if(!e[j]){const t=e.toConfig();e[j]=Object.values(t.values).reduce(((e,t)=>(e[t.value]=t,e)),Object.create(null))}return e[j][t]},t.sharedNull=Object.freeze(Object.create(null)),t.stack=function(e,t=4){try{throw new Error(e)}catch(e){const n=e.stack.split("\n"),r=n.findIndex((e=>e.startsWith("Error:")));if(r<0)return void console.dir(e.stack);const a=[n[r],...n.slice(r+2,r+2+t)].map((e=>e.replace(/^(.*?)\(\/home[^)]*\/packages\/([^)]*)\)/,((e,t,n)=>`${t}${" ".repeat(Math.max(0,45-t.length))}(${n})`))));console.log(a.join("\n"))}},t.arrayOfLength=function(e,t){const n=[];for(let r=0;r<e;r++)n[r]=t;return n},t.arrayOfLengthCb=function(e,t){const n=[];for(let r=0;r<e;r++)n[r]=t();return n},t.findVariableNamesUsed=function(e,t){const n=new Set;return C(e,t,n),[...n].sort()},t.isTypePlanned=function(e,t){if(t instanceof g)return!!t.extensions?.grafast?.assertStep;if(t instanceof v||t instanceof y){const n=t instanceof v?t.getTypes():e.getImplementations(t).objects;let r=null,a=0;for(const e of n){const o=!!e.extensions?.grafast?.assertStep;if(null===r)r=o;else if(o!==r)throw new Error(`The '${t.name}' interface or union type's first type '${n[0]}' ${r?"expected a plan":"did not expect a plan"}, however the type '${e}' (index = ${a}) ${o?"expected a plan":"did not expect a plan"}. All types in an interface or union must be in agreement about whether a plan is expected or not.`);a++}return!!r}return!1},t.stepADependsOnStepB=A,t.stepAMayDependOnStepB=function(e,t){return e.layerPlan.ancestry.includes(t.layerPlan)&&!A(t,e)},t.stepsAreInSamePhase=function(e,t){let n=t.layerPlan;do{if(n===e.layerPlan)return!0;const t=n.reason.type;switch(t){case"subscription":case"defer":case"polymorphic":return!1;case"listItem":if(n.reason.stream)continue;continue;case"root":case"nullableBoundary":case"subroutine":case"mutationField":continue;default:throw new Error(`Unhandled layer plan type '${t}'`)}}while(n=n.parentLayerPlan);throw new Error(`${t} is not dependent on ${e}, perhaps you passed the arguments in the wrong order?`)};function N(e,t){if("AsyncFunction"===e?.constructor?.name)throw new Error(`Plans must be synchronous, but this schema has an async function at '${t}': ${e.toString()}`)}t.canonicalJSONStringify=e=>JSON.stringify(e),t.assertNotAsync=N,t.hasItemPlan=function(e){return"itemPlan"in e&&"function"==typeof e.itemPlan}},14:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.version=void 0,t.version="0.0.1-beta.4"},9640:(e,t,n)=>{"use strict";e=n.nmd(e);const r=(e,t)=>(...n)=>`[${e(...n)+t}m`,a=(e,t)=>(...n)=>{const r=e(...n);return`[${38+t};5;${r}m`},o=(e,t)=>(...n)=>{const r=e(...n);return`[${38+t};2;${r[0]};${r[1]};${r[2]}m`},s=e=>e,i=(e,t,n)=>[e,t,n],l=(e,t,n)=>{Object.defineProperty(e,t,{get:()=>{const r=n();return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0}),r},enumerable:!0,configurable:!0})};let c;const u=(e,t,r,a)=>{void 0===c&&(c=n(9));const o=a?10:0,s={};for(const[n,a]of Object.entries(c)){const i="ansi16"===n?"ansi":n;n===t?s[i]=e(r,o):"object"==typeof a&&(s[i]=e(a[t],o))}return s};Object.defineProperty(e,"exports",{enumerable:!0,get:function(){const e=new Map,t={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],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],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],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};t.color.gray=t.color.blackBright,t.bgColor.bgGray=t.bgColor.bgBlackBright,t.color.grey=t.color.blackBright,t.bgColor.bgGrey=t.bgColor.bgBlackBright;for(const[n,r]of Object.entries(t)){for(const[n,a]of Object.entries(r))t[n]={open:`[${a[0]}m`,close:`[${a[1]}m`},r[n]=t[n],e.set(a[0],a[1]);Object.defineProperty(t,n,{value:r,enumerable:!1})}return Object.defineProperty(t,"codes",{value:e,enumerable:!1}),t.color.close="[39m",t.bgColor.close="[49m",l(t.color,"ansi",(()=>u(r,"ansi16",s,!1))),l(t.color,"ansi256",(()=>u(a,"ansi256",s,!1))),l(t.color,"ansi16m",(()=>u(o,"rgb",i,!1))),l(t.bgColor,"ansi",(()=>u(r,"ansi16",s,!0))),l(t.bgColor,"ansi256",(()=>u(a,"ansi256",s,!0))),l(t.bgColor,"ansi16m",(()=>u(o,"rgb",i,!0))),t}})},5635:(e,t,n)=>{const r=n(9448),a={};for(const e of Object.keys(r))a[r[e]]=e;const o={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=o;for(const e of Object.keys(o)){if(!("channels"in o[e]))throw new Error("missing channels property: "+e);if(!("labels"in o[e]))throw new Error("missing channel labels property: "+e);if(o[e].labels.length!==o[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:t,labels:n}=o[e];delete o[e].channels,delete o[e].labels,Object.defineProperty(o[e],"channels",{value:t}),Object.defineProperty(o[e],"labels",{value:n})}o.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.min(t,n,r),o=Math.max(t,n,r),s=o-a;let i,l;o===a?i=0:t===o?i=(n-r)/s:n===o?i=2+(r-t)/s:r===o&&(i=4+(t-n)/s),i=Math.min(60*i,360),i<0&&(i+=360);const c=(a+o)/2;return l=o===a?0:c<=.5?s/(o+a):s/(2-o-a),[i,100*l,100*c]},o.rgb.hsv=function(e){let t,n,r,a,o;const s=e[0]/255,i=e[1]/255,l=e[2]/255,c=Math.max(s,i,l),u=c-Math.min(s,i,l),p=function(e){return(c-e)/6/u+.5};return 0===u?(a=0,o=0):(o=u/c,t=p(s),n=p(i),r=p(l),s===c?a=r-n:i===c?a=1/3+t-r:l===c&&(a=2/3+n-t),a<0?a+=1:a>1&&(a-=1)),[360*a,100*o,100*c]},o.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const a=o.rgb.hsl(e)[0],s=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[a,100*s,100*r]},o.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.min(1-t,1-n,1-r);return[100*((1-t-a)/(1-a)||0),100*((1-n-a)/(1-a)||0),100*((1-r-a)/(1-a)||0),100*a]},o.rgb.keyword=function(e){const t=a[e];if(t)return t;let n,o=1/0;for(const t of Object.keys(r)){const a=r[t],l=(i=a,((s=e)[0]-i[0])**2+(s[1]-i[1])**2+(s[2]-i[2])**2);l<o&&(o=l,n=t)}var s,i;return n},o.keyword.rgb=function(e){return r[e]},o.rgb.xyz=function(e){let t=e[0]/255,n=e[1]/255,r=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;return[100*(.4124*t+.3576*n+.1805*r),100*(.2126*t+.7152*n+.0722*r),100*(.0193*t+.1192*n+.9505*r)]},o.rgb.lab=function(e){const t=o.rgb.xyz(e);let n=t[0],r=t[1],a=t[2];n/=95.047,r/=100,a/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,a=a>.008856?a**(1/3):7.787*a+16/116;return[116*r-16,500*(n-r),200*(r-a)]},o.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let a,o,s;if(0===n)return s=255*r,[s,s,s];a=r<.5?r*(1+n):r+n-r*n;const i=2*r-a,l=[0,0,0];for(let e=0;e<3;e++)o=t+1/3*-(e-1),o<0&&o++,o>1&&o--,s=6*o<1?i+6*(a-i)*o:2*o<1?a:3*o<2?i+(a-i)*(2/3-o)*6:i,l[e]=255*s;return l},o.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,a=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,a*=o<=1?o:2-o;return[t,100*(0===r?2*a/(o+a):2*n/(r+n)),100*((r+n)/2)]},o.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const a=Math.floor(t)%6,o=t-Math.floor(t),s=255*r*(1-n),i=255*r*(1-n*o),l=255*r*(1-n*(1-o));switch(r*=255,a){case 0:return[r,l,s];case 1:return[i,r,s];case 2:return[s,r,l];case 3:return[s,i,r];case 4:return[l,s,r];case 5:return[r,s,i]}},o.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,a=Math.max(r,.01);let o,s;s=(2-n)*r;const i=(2-n)*a;return o=n*a,o/=i<=1?i:2-i,o=o||0,s/=2,[t,100*o,100*s]},o.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const a=n+r;let o;a>1&&(n/=a,r/=a);const s=Math.floor(6*t),i=1-r;o=6*t-s,0!=(1&s)&&(o=1-o);const l=n+o*(i-n);let c,u,p;switch(s){default:case 6:case 0:c=i,u=l,p=n;break;case 1:c=l,u=i,p=n;break;case 2:c=n,u=i,p=l;break;case 3:c=n,u=l,p=i;break;case 4:c=l,u=n,p=i;break;case 5:c=i,u=n,p=l}return[255*c,255*u,255*p]},o.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,a=e[3]/100;return[255*(1-Math.min(1,t*(1-a)+a)),255*(1-Math.min(1,n*(1-a)+a)),255*(1-Math.min(1,r*(1-a)+a))]},o.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let a,o,s;return a=3.2406*t+-1.5372*n+-.4986*r,o=-.9689*t+1.8758*n+.0415*r,s=.0557*t+-.204*n+1.057*r,a=a>.0031308?1.055*a**(1/2.4)-.055:12.92*a,o=o>.0031308?1.055*o**(1/2.4)-.055:12.92*o,s=s>.0031308?1.055*s**(1/2.4)-.055:12.92*s,a=Math.min(Math.max(0,a),1),o=Math.min(Math.max(0,o),1),s=Math.min(Math.max(0,s),1),[255*a,255*o,255*s]},o.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;return[116*n-16,500*(t-n),200*(n-r)]},o.lab.xyz=function(e){let t,n,r;n=(e[0]+16)/116,t=e[1]/500+n,r=n-e[2]/200;const a=n**3,o=t**3,s=r**3;return n=a>.008856?a:(n-16/116)/7.787,t=o>.008856?o:(t-16/116)/7.787,r=s>.008856?s:(r-16/116)/7.787,t*=95.047,n*=100,r*=108.883,[t,n,r]},o.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let a;a=360*Math.atan2(r,n)/2/Math.PI,a<0&&(a+=360);return[t,Math.sqrt(n*n+r*r),a]},o.lch.lab=function(e){const t=e[0],n=e[1],r=e[2]/360*2*Math.PI;return[t,n*Math.cos(r),n*Math.sin(r)]},o.rgb.ansi16=function(e,t=null){const[n,r,a]=e;let s=null===t?o.rgb.hsv(e)[2]:t;if(s=Math.round(s/50),0===s)return 30;let i=30+(Math.round(a/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===s&&(i+=60),i},o.hsv.ansi16=function(e){return o.rgb.ansi16(o.hsv.rgb(e),e[2])},o.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];if(t===n&&n===r)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;return 16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},o.ansi16.rgb=function(e){let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=.5*(1+~~(e>50));return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},o.ansi256.rgb=function(e){if(e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;return[Math.floor(e/36)/5*255,Math.floor((t=e%36)/6)/5*255,t%6/5*255]},o.rgb.hex=function(e){const t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},o.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let n=t[0];3===t[0].length&&(n=n.split("").map((e=>e+e)).join(""));const r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},o.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.max(Math.max(t,n),r),o=Math.min(Math.min(t,n),r),s=a-o;let i,l;return i=s<1?o/(1-s):0,l=s<=0?0:a===t?(n-r)/s%6:a===n?2+(r-t)/s:4+(t-n)/s,l/=6,l%=1,[360*l,100*s,100*i]},o.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let a=0;return r<1&&(a=(n-.5*r)/(1-r)),[e[0],100*r,100*a]},o.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let a=0;return r<1&&(a=(n-r)/(1-r)),[e[0],100*r,100*a]},o.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];const a=[0,0,0],o=t%1*6,s=o%1,i=1-s;let l=0;switch(Math.floor(o)){case 0:a[0]=1,a[1]=s,a[2]=0;break;case 1:a[0]=i,a[1]=1,a[2]=0;break;case 2:a[0]=0,a[1]=1,a[2]=s;break;case 3:a[0]=0,a[1]=i,a[2]=1;break;case 4:a[0]=s,a[1]=0,a[2]=1;break;default:a[0]=1,a[1]=0,a[2]=i}return l=(1-n)*r,[255*(n*a[0]+l),255*(n*a[1]+l),255*(n*a[2]+l)]},o.hcg.hsv=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);let r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},o.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100*(1-t)+.5*t;let r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},o.hcg.hwb=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},o.hwb.hcg=function(e){const t=e[1]/100,n=1-e[2]/100,r=n-t;let a=0;return r<1&&(a=(n-r)/(1-r)),[e[0],100*r,100*a]},o.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},o.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},o.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},o.gray.hsl=function(e){return[0,0,e[0]]},o.gray.hsv=o.gray.hsl,o.gray.hwb=function(e){return[0,100,e[0]]},o.gray.cmyk=function(e){return[0,0,0,e[0]]},o.gray.lab=function(e){return[e[0],0,0]},o.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n},o.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}},9:(e,t,n)=>{const r=n(5635),a=n(482),o={};Object.keys(r).forEach((e=>{o[e]={},Object.defineProperty(o[e],"channels",{value:r[e].channels}),Object.defineProperty(o[e],"labels",{value:r[e].labels});const t=a(e);Object.keys(t).forEach((n=>{const r=t[n];o[e][n]=function(e){const t=function(...t){const n=t[0];if(null==n)return n;n.length>1&&(t=n);const r=e(t);if("object"==typeof r)for(let e=r.length,t=0;t<e;t++)r[t]=Math.round(r[t]);return r};return"conversion"in e&&(t.conversion=e.conversion),t}(r),o[e][n].raw=function(e){const t=function(...t){const n=t[0];return null==n?n:(n.length>1&&(t=n),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}(r)}))})),e.exports=o},482:(e,t,n)=>{const r=n(5635);function a(e){const t=function(){const e={},t=Object.keys(r);for(let n=t.length,r=0;r<n;r++)e[t[r]]={distance:-1,parent:null};return e}(),n=[e];for(t[e].distance=0;n.length;){const e=n.pop(),a=Object.keys(r[e]);for(let r=a.length,o=0;o<r;o++){const r=a[o],s=t[r];-1===s.distance&&(s.distance=t[e].distance+1,s.parent=e,n.unshift(r))}}return t}function o(e,t){return function(n){return t(e(n))}}function s(e,t){const n=[t[e].parent,e];let a=r[t[e].parent][e],s=t[e].parent;for(;t[s].parent;)n.unshift(t[s].parent),a=o(r[t[s].parent][s],a),s=t[s].parent;return a.conversion=n,a}e.exports=function(e){const t=a(e),n={},r=Object.keys(t);for(let e=r.length,a=0;a<e;a++){const e=r[a];null!==t[e].parent&&(n[e]=s(e,t))}return n}},9448:e=>{"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},2181:e=>{"use strict";e.exports={stdout:!1,stderr:!1}},2645:(e,t,n)=>{"use strict";const r=n(9640),{stdout:a,stderr:o}=n(2181),{stringReplaceAll:s,stringEncaseCRLFWithFirstIndex:i}=n(1957),{isArray:l}=Array,c=["ansi","ansi","ansi256","ansi16m"],u=Object.create(null);class ChalkClass{constructor(e){return p(e)}}const p=e=>{const t={};return((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");const n=a?a.level:0;e.level=void 0===t.level?n:t.level})(t,e),t.template=(...e)=>S(t.template,...e),Object.setPrototypeOf(t,d.prototype),Object.setPrototypeOf(t.template,t),t.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},t.template.Instance=ChalkClass,t.template};function d(e){return p(e)}for(const[e,t]of Object.entries(r))u[e]={get(){const n=b(this,y(t.open,t.close,this._styler),this._isEmpty);return Object.defineProperty(this,e,{value:n}),n}};u.visible={get(){const e=b(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:e}),e}};const f=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(const e of f)u[e]={get(){const{level:t}=this;return function(...n){const a=y(r.color[c[t]][e](...n),r.color.close,this._styler);return b(this,a,this._isEmpty)}}};for(const e of f){u["bg"+e[0].toUpperCase()+e.slice(1)]={get(){const{level:t}=this;return function(...n){const a=y(r.bgColor[c[t]][e](...n),r.bgColor.close,this._styler);return b(this,a,this._isEmpty)}}}}const h=Object.defineProperties((()=>{}),{...u,level:{enumerable:!0,get(){return this._generator.level},set(e){this._generator.level=e}}}),y=(e,t,n)=>{let r,a;return void 0===n?(r=e,a=t):(r=n.openAll+e,a=t+n.closeAll),{open:e,close:t,openAll:r,closeAll:a,parent:n}},b=(e,t,n)=>{const r=(...e)=>l(e[0])&&l(e[0].raw)?m(r,S(r,...e)):m(r,1===e.length?""+e[0]:e.join(" "));return Object.setPrototypeOf(r,h),r._generator=e,r._styler=t,r._isEmpty=n,r},m=(e,t)=>{if(e.level<=0||!t)return e._isEmpty?"":t;let n=e._styler;if(void 0===n)return t;const{openAll:r,closeAll:a}=n;if(-1!==t.indexOf(""))for(;void 0!==n;)t=s(t,n.close,n.open),n=n.parent;const o=t.indexOf("\n");return-1!==o&&(t=i(t,a,r,o)),r+t+a};let g;const S=(e,...t)=>{const[r]=t;if(!l(r)||!l(r.raw))return t.join(" ");const a=t.slice(1),o=[r.raw[0]];for(let e=1;e<r.length;e++)o.push(String(a[e-1]).replace(/[{}\\]/g,"\\$&"),String(r.raw[e]));return void 0===g&&(g=n(1070)),g(e,o.join(""))};Object.defineProperties(d.prototype,u);const P=d();P.supportsColor=a,P.stderr=d({level:o?o.level:0}),P.stderr.supportsColor=o,e.exports=P},1070:e=>{"use strict";const t=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,n=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,r=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,a=/\\(u(?:[a-f\d]{4}|{[a-f\d]{1,6}})|x[a-f\d]{2}|.)|([^\\])/gi,o=new Map([["n","\n"],["r","\r"],["t","\t"],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a",""]]);function s(e){const t="u"===e[0],n="{"===e[1];return t&&!n&&5===e.length||"x"===e[0]&&3===e.length?String.fromCharCode(parseInt(e.slice(1),16)):t&&n?String.fromCodePoint(parseInt(e.slice(2,-1),16)):o.get(e)||e}function i(e,t){const n=[],o=t.trim().split(/\s*,\s*/g);let i;for(const t of o){const o=Number(t);if(Number.isNaN(o)){if(!(i=t.match(r)))throw new Error(`Invalid Chalk template style argument: ${t} (in style '${e}')`);n.push(i[2].replace(a,((e,t,n)=>t?s(t):n)))}else n.push(o)}return n}function l(e){n.lastIndex=0;const t=[];let r;for(;null!==(r=n.exec(e));){const e=r[1];if(r[2]){const n=i(e,r[2]);t.push([e].concat(n))}else t.push([e])}return t}function c(e,t){const n={};for(const e of t)for(const t of e.styles)n[t[0]]=e.inverse?null:t.slice(1);let r=e;for(const[e,t]of Object.entries(n))if(Array.isArray(t)){if(!(e in r))throw new Error(`Unknown Chalk style: ${e}`);r=t.length>0?r[e](...t):r[e]}return r}e.exports=(e,n)=>{const r=[],a=[];let o=[];if(n.replace(t,((t,n,i,u,p,d)=>{if(n)o.push(s(n));else if(u){const t=o.join("");o=[],a.push(0===r.length?t:c(e,r)(t)),r.push({inverse:i,styles:l(u)})}else if(p){if(0===r.length)throw new Error("Found extraneous } in Chalk template literal");a.push(c(e,r)(o.join(""))),o=[],r.pop()}else o.push(d)})),a.push(o.join("")),r.length>0){const e=`Chalk template literal is missing ${r.length} closing bracket${1===r.length?"":"s"} (\`}\`)`;throw new Error(e)}return a.join("")}},1957:e=>{"use strict";e.exports={stringReplaceAll:(e,t,n)=>{let r=e.indexOf(t);if(-1===r)return e;const a=t.length;let o=0,s="";do{s+=e.substr(o,r-o)+t+n,o=r+a,r=e.indexOf(t,o)}while(-1!==r);return s+=e.substr(o),s},stringEncaseCRLFWithFirstIndex:(e,t,n,r)=>{let a=0,o="";do{const s="\r"===e[r-1];o+=e.substr(a,(s?r-1:r)-a)+t+(s?"\r\n":"\n")+n,a=r+1,r=e.indexOf("\n",a)}while(-1!==r);return o+=e.substr(a),o}}},5881:e=>{var t=1e3,n=60*t,r=60*n,a=24*r,o=7*a,s=365.25*a;function i(e,t,n,r){var a=t>=1.5*n;return Math.round(e/n)+" "+r+(a?"s":"")}e.exports=function(e,l){l=l||{};var c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!i)return;var l=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return l*s;case"weeks":case"week":case"w":return l*o;case"days":case"day":case"d":return l*a;case"hours":case"hour":case"hrs":case"hr":case"h":return l*r;case"minutes":case"minute":case"mins":case"min":case"m":return l*n;case"seconds":case"second":case"secs":case"sec":case"s":return l*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:return}}(e);if("number"===c&&isFinite(e))return l.long?function(e){var o=Math.abs(e);if(o>=a)return i(e,o,a,"day");if(o>=r)return i(e,o,r,"hour");if(o>=n)return i(e,o,n,"minute");if(o>=t)return i(e,o,t,"second");return e+" ms"}(e):function(e){var o=Math.abs(e);if(o>=a)return Math.round(e/a)+"d";if(o>=r)return Math.round(e/r)+"h";if(o>=n)return Math.round(e/n)+"m";if(o>=t)return Math.round(e/t)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},5130:(e,t,n)=>{t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,a=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(a=r))})),t.splice(a,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(7123)(t);const{formatters:r}=e.exports;r.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},7123:(e,t,n)=>{e.exports=function(e){function t(e){let n,a,o,s=null;function i(...e){if(!i.enabled)return;const r=i,a=Number(new Date),o=a-(n||a);r.diff=o,r.prev=n,r.curr=a,n=a,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let s=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,a)=>{if("%%"===n)return"%";s++;const o=t.formatters[a];if("function"==typeof o){const t=e[s];n=o.call(r,t),e.splice(s,1),s--}return n})),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=r,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(a!==t.namespaces&&(a=t.namespaces,o=t.enabled(e)),o),set:e=>{s=e}}),"function"==typeof t.init&&t.init(i),i}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function a(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(a),...t.skips.map(a).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),a=r.length;for(n=0;n<a;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.slice(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(5881),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((n=>{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},161:e=>{"use strict";var t=Object.prototype.hasOwnProperty,n="~";function r(){}function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,r,o,s){if("function"!=typeof r)throw new TypeError("The listener must be a function");var i=new a(r,o||e,s),l=n?n+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],i]:e._events[l].push(i):(e._events[l]=i,e._eventsCount++),e}function s(e,t){0==--e._eventsCount?e._events=new r:delete e._events[t]}function i(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),i.prototype.eventNames=function(){var e,r,a=[];if(0===this._eventsCount)return a;for(r in e=this._events)t.call(e,r)&&a.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?a.concat(Object.getOwnPropertySymbols(e)):a},i.prototype.listeners=function(e){var t=n?n+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var a=0,o=r.length,s=new Array(o);a<o;a++)s[a]=r[a].fn;return s},i.prototype.listenerCount=function(e){var t=n?n+e:e,r=this._events[t];return r?r.fn?1:r.length:0},i.prototype.emit=function(e,t,r,a,o,s){var i=n?n+e:e;if(!this._events[i])return!1;var l,c,u=this._events[i],p=arguments.length;if(u.fn){switch(u.once&&this.removeListener(e,u.fn,void 0,!0),p){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,t),!0;case 3:return u.fn.call(u.context,t,r),!0;case 4:return u.fn.call(u.context,t,r,a),!0;case 5:return u.fn.call(u.context,t,r,a,o),!0;case 6:return u.fn.call(u.context,t,r,a,o,s),!0}for(c=1,l=new Array(p-1);c<p;c++)l[c-1]=arguments[c];u.fn.apply(u.context,l)}else{var d,f=u.length;for(c=0;c<f;c++)switch(u[c].once&&this.removeListener(e,u[c].fn,void 0,!0),p){case 1:u[c].fn.call(u[c].context);break;case 2:u[c].fn.call(u[c].context,t);break;case 3:u[c].fn.call(u[c].context,t,r);break;case 4:u[c].fn.call(u[c].context,t,r,a);break;default:if(!l)for(d=1,l=new Array(p-1);d<p;d++)l[d-1]=arguments[d];u[c].fn.apply(u[c].context,l)}}return!0},i.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},i.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},i.prototype.removeListener=function(e,t,r,a){var o=n?n+e:e;if(!this._events[o])return this;if(!t)return s(this,o),this;var i=this._events[o];if(i.fn)i.fn!==t||a&&!i.once||r&&i.context!==r||s(this,o);else{for(var l=0,c=[],u=i.length;l<u;l++)(i[l].fn!==t||a&&!i[l].once||r&&i[l].context!==r)&&c.push(i[l]);c.length?this._events[o]=1===c.length?c[0]:c:s(this,o)}return this},i.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&s(this,t)):(this._events=new r,this._eventsCount=0),this},i.prototype.off=i.prototype.removeListener,i.prototype.addListener=i.prototype.on,i.prefixed=n,i.EventEmitter=i,e.exports=i},5163:(e,t,n)=>{"use strict";n.r(t),n.d(t,{__assign:()=>o,__asyncDelegator:()=>E,__asyncGenerator:()=>$,__asyncValues:()=>x,__await:()=>O,__awaiter:()=>h,__classPrivateFieldGet:()=>L,__classPrivateFieldIn:()=>C,__classPrivateFieldSet:()=>T,__createBinding:()=>b,__decorate:()=>i,__esDecorate:()=>c,__exportStar:()=>m,__extends:()=>a,__generator:()=>y,__importDefault:()=>I,__importStar:()=>j,__makeTemplateObject:()=>k,__metadata:()=>f,__param:()=>l,__propKey:()=>p,__read:()=>S,__rest:()=>s,__runInitializers:()=>u,__setFunctionName:()=>d,__spread:()=>P,__spreadArray:()=>w,__spreadArrays:()=>v,__values:()=>g});var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)};function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var o=function(){return o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e},o.apply(this,arguments)};function s(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var a=0;for(r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]])}return n}function i(e,t,n,r){var a,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var i=e.length-1;i>=0;i--)(a=e[i])&&(s=(o<3?a(s):o>3?a(t,n,s):a(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s}function l(e,t){return function(n,r){t(n,r,e)}}function c(e,t,n,r,a,o){function s(e){if(void 0!==e&&"function"!=typeof e)throw new TypeError("Function expected");return e}for(var i,l=r.kind,c="getter"===l?"get":"setter"===l?"set":"value",u=!t&&e?r.static?e:e.prototype:null,p=t||(u?Object.getOwnPropertyDescriptor(u,r.name):{}),d=!1,f=n.length-1;f>=0;f--){var h={};for(var y in r)h[y]="access"===y?{}:r[y];for(var y in r.access)h.access[y]=r.access[y];h.addInitializer=function(e){if(d)throw new TypeError("Cannot add initializers after decoration has completed");o.push(s(e||null))};var b=(0,n[f])("accessor"===l?{get:p.get,set:p.set}:p[c],h);if("accessor"===l){if(void 0===b)continue;if(null===b||"object"!=typeof b)throw new TypeError("Object expected");(i=s(b.get))&&(p.get=i),(i=s(b.set))&&(p.set=i),(i=s(b.init))&&a.push(i)}else(i=s(b))&&("field"===l?a.push(i):p[c]=i)}u&&Object.defineProperty(u,r.name,p),d=!0}function u(e,t,n){for(var r=arguments.length>2,a=0;a<t.length;a++)n=r?t[a].call(e,n):t[a].call(e);return r?n:void 0}function p(e){return"symbol"==typeof e?e:"".concat(e)}function d(e,t,n){return"symbol"==typeof t&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:!0,value:n?"".concat(n," ",t):t})}function f(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function h(e,t,n,r){return new(n||(n=Promise))((function(a,o){function s(e){try{l(r.next(e))}catch(e){o(e)}}function i(e){try{l(r.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,i)}l((r=r.apply(e,t||[])).next())}))}function y(e,t){var n,r,a,o,s={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return o={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function i(i){return function(l){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,i[0]&&(s=0)),s;)try{if(n=1,r&&(a=2&i[0]?r.return:i[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,i[1])).done)return a;switch(r=0,a&&(i=[2&i[0],a.value]),i[0]){case 0:case 1:a=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!(a=s.trys,(a=a.length>0&&a[a.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!a||i[1]>a[0]&&i[1]<a[3])){s.label=i[1];break}if(6===i[0]&&s.label<a[1]){s.label=a[1],a=i;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(i);break}a[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=a=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}}var b=Object.create?function(e,t,n,r){void 0===r&&(r=n);var a=Object.getOwnPropertyDescriptor(t,n);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,a)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]};function m(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||b(t,e,n)}function g(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function S(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)s.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return s}function P(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(S(arguments[t]));return e}function v(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),a=0;for(t=0;t<n;t++)for(var o=arguments[t],s=0,i=o.length;s<i;s++,a++)r[a]=o[s];return r}function w(e,t,n){if(n||2===arguments.length)for(var r,a=0,o=t.length;a<o;a++)!r&&a in t||(r||(r=Array.prototype.slice.call(t,0,a)),r[a]=t[a]);return e.concat(r||Array.prototype.slice.call(t))}function O(e){return this instanceof O?(this.v=e,this):new O(e)}function $(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,a=n.apply(e,t||[]),o=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(e){a[e]&&(r[e]=function(t){return new Promise((function(n,r){o.push([e,t,n,r])>1||i(e,t)}))})}function i(e,t){try{(n=a[e](t)).value instanceof O?Promise.resolve(n.value.v).then(l,c):u(o[0][2],n)}catch(e){u(o[0][3],e)}var n}function l(e){i("next",e)}function c(e){i("throw",e)}function u(e,t){e(t),o.shift(),o.length&&i(o[0][0],o[0][1])}}function E(e){var t,n;return t={},r("next"),r("throw",(function(e){throw e})),r("return"),t[Symbol.iterator]=function(){return this},t;function r(r,a){t[r]=e[r]?function(t){return(n=!n)?{value:O(e[r](t)),done:!1}:a?a(t):t}:a}}function x(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=g(e),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise((function(r,a){(function(e,t,n,r){Promise.resolve(r).then((function(t){e({value:t,done:n})}),t)})(r,a,(t=e[n](t)).done,t.value)}))}}}function k(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var _=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function j(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&b(t,e,n);return _(t,e),t}function I(e){return e&&e.__esModule?e:{default:e}}function L(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)}function T(e,t,n,r,a){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!a)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!a:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?a.call(e,n):a?a.value=n:t.set(e,n),n}function C(e,t){if(null===t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("Cannot use 'in' operator on non-object");return"function"==typeof e?t===e:e.has(t)}},607:(e,t)=>{"use strict";function n(e){return this.c.get(e)?.v}Object.defineProperty(t,"__esModule",{value:!0}),t.LRU=void 0;class LRU{constructor({maxLength:e,dispose:t}){if(e<2)throw new Error("Max length must be >= 2");if(parseInt(String(e),10)!==e)throw new Error("Max length must be an integer");this.length=0,this.m=e,this.h=null,this.t=null,this.c=new Map,this.d=t||null,this.s=!1,this.get=n,this.reset()}reset(){const e=this.c.values();if(this.c.clear(),this.h=null,this.t=null,this.length=0,null!==this.d)for(const t of e)this.d(t.k,t.v)}get(e){const t=this.c.get(e);if(void 0!==t)return null===this.h?this.h=this.t=t:t!==this.h&&(t.p.n=t.n,null!==t.n?t.n.p=t.p:this.t=t.p,t.n=this.h,this.h.p=t,this.h=t,t.p=null),t.v}set(e,t){const n=this.c.get(e);if(void 0!==n)n.v=t;else{const n={k:e,v:t,n:null,p:null};this.c.set(e,n),this.a(n)}}a(e){if(null===this.h)return this.h=this.t=e,void(this.length=1);if(this.h.p=e,e.n=this.h,this.h=e,this.s){const e=this.t;this.c.delete(e.k),this.t=e.p,this.t.n=null,null!==this.d&&this.d(e.k,e.v)}else 0===this.length&&(this.t=e),this.length++,this.length===this.m&&(this.s=!0,this.get=LRU.prototype.get)}}t.LRU=LRU,t.default=LRU},7073:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.undefined=t.tmp=t.tempVar=t.te=t.substring=t.subcomment=t.set=t.safeKeyOrThrow=t.runInBatch=t.run=t.ref=t.optionalGet=t.literal=t.lit=t.join=t.isTE=t.identifier=t.get=t.eval=t.dangerouslyIncludeRawCode=t.dangerousKey=t.compile=t.cache=t.batch=t.Idents=t.isSafeObjectPropertyName=t.toJSON=t.stringifyJSON=t.stringifyString=void 0;const r=n(2008),a=n(5570);function o(e,t){const n=e.$$export;if(n){if(n.exportName!==t)throw new Error(`Attempted to export same thing under multiple names '${n.exportName}' and '${t}'`)}else Object.defineProperty(e,"$$export",{value:{moduleName:"tamedevil",exportName:t}});return e}const s="undefined"!=typeof process&&!1;function i(e){return{[a.$$type]:"RAW",t:e}}function l(e,t){const n={[a.$$type]:"RAW",t:e};return o(n,t),n}function c(e,t){return Object.freeze({[a.$$type]:"REF",v:e,n:t})}function u(e){return Object.freeze({[a.$$type]:"INDENT",c:"QUERY"===e[a.$$type]?e:p([e])})}function p(e){return Object.freeze({[a.$$type]:"QUERY",n:e})}function d(e){return"object"==typeof e&&null!==e&&"string"==typeof e[a.$$type]}function f(e,t){if(d(e))return e;throw new Error(`[tamedevil] Invalid expression. Expected an TE item${t?` at ${t}`:""} but received '${String(e)}'. This may mean that there is an issue in the TE expression where a dynamic value was not escaped via 'te.ref(...)', an embedded string wasn't wrapped with 'te.string(...)', or a TE expression was added without using the \`te\` tagged template literal.`)}t.isTE=d;const h=(e,t,n,r)=>{const a=t.get(n);if(a)return a;const o=t.size+1;if(o>65535)throw new Error("[tamedevil] This TE statement would contain too many placeholders; tamedevil supports at most 65535 placeholders. To solve this, consider passing multiple values in using a single array or object.");const s=r?function(e,t){if(!(t in e))return t;for(let n=0;n<1e6;n++){const r=t+n;if(!(r in e))return r}throw new Error("Failed to find an available variable name to use")}(e,r):`_$$_ref_${o}`;return t.set(n,s),e[s]=n,s},y=(e,t)=>{const n=e.get(t);if(n)return n;const r=`_$_tmp${e.size+1}`;return e.set(t,r),r};function b(e,t,n,r,o=0){let i="";switch(null==e&&f(e),e[a.$$type]){case"QUERY":for(const a of e.n)i+=b(a,t,n,r,o);break;case"RAW":if(""===e.t)break;i+=s?e.t.replace(/\n/g,"\n"+" ".repeat(o)):e.t;break;case"REF":i+=h(t,n,e.v,e.n);break;case"VARIABLE":i+=y(r,e.s);break;case"INDENT":if(!s)throw new Error("INDENT nodes only allowed in development mode");i+="\n"+" ".repeat(o+1),i+=b(e.c,t,n,r,o+1),i+="\n"+" ".repeat(o);break;default:throw new Error(`Unsupported node found in TE: ${String(f(e))}`)}return i}function m(e){const t=Object.create(null),n=new Map,r=new Map;let a=b(e,t,n,r),o="";for(const e of r.values())o+=`let ${e};\n`;o.length>0&&(a=o+"\n"+a);return{string:s?a.replace(/\n\s*\n/g,"\n"):a,refs:t}}t.compile=m;const g=function(e,...t){if(!Array.isArray(e)||!e.raw)throw new Error("[tamedevil] te should be used as a template literal, not a function call.");const n=e.length;if(1===n){const t=e[0];return""===t?$:"undefined"===t?E:i(t)}if(2===n&&""===e[0]&&""===e[1]){const e=t[0];return void 0!==e[a.$$type]?e:f(e)}const r=[];let o=null,s="";const l=n-1;for(let c=0;c<n;c++){const n=e[c];if(s+=n,c!==l){const e=t[c],n=void 0!==e[a.$$type]?e:f(e,`literal placeholder ${c}`);if("RAW"===n[a.$$type])o=n,s+=n.t;else if("QUERY"===n[a.$$type]){const e=n.n,t=e.length;for(let n=0;n<t;n++){const t=e[n];"RAW"===t[a.$$type]?(o=t,s+=t.t):(""!==s&&(null!==o&&o.t===s||(o=i(s)),r.push(o),s=""),r.push(t))}}else""!==s&&(null!==o&&o.t===s||(o=i(s)),r.push(o),s=""),r.push(n)}}return""!==s&&(null!==o&&o.t===s||(o=i(s)),r.push(o),s=""),1===r.length?r[0]:p(r)},S=Object.create(null);function P(e){if(1!==e.length)throw new Error("te.cache can currently only be used with a static string");const t=e[0],n=S[t];if(n)return n;const r=i(t);return S[t]=r,r}t.cache=P;let v=!1;function w(e){if(!v){v=!0;try{throw new Error("te.dangerouslyIncludeRawCode first invoked here")}catch(e){console.warn(`[tamedevil] WARNING: you're using the te.dangerouslyIncludeRawCode escape hatch, usage of this API is rarely required and is highly discouraged due to the potential security ramifications. Please be sure this is what you intend. ${e.stack}`)}}if("string"!=typeof e)throw new Error(`[tamedevil] te.dangerouslyIncludeRawCode must be passed a string, but it was passed '${String(e)}'.`);return i(e)}function O(e,t){if(null!=t){if(!A(t))throw new Error(`Invalid variable name '${t}'`);return c(e,t)}return c(e)}t.dangerouslyIncludeRawCode=w,t.ref=O;const $=l("","blank"),E=l("undefined","undefined");t.undefined=E;const x=200,k="\\".charCodeAt(0),_='"'.charCodeAt(0);function j(e){const t=e.length;if(t>x)return JSON.stringify(e);for(let n=0;n<t;n++){const t=e.charCodeAt(n);if(t===k||t===_||0==(65504&t)||0!=(49152&t))return JSON.stringify(e)}return`"${e}"`}t.stringifyString=j;function I(e){if(void 0===e)return E;if(null===e||"string"==typeof e||"boolean"==typeof e||"number"==typeof e&&Number.isFinite(e)){const n=e;return i((0,t.stringifyJSON)(n))}return O(e)}function L(e,t){if("string"!=typeof e||"string"!=typeof t)throw new Error("Invalid call to te.substring");const n=e.length;if(n<x){const r=t.charCodeAt(0);let a=!0;for(let t=0;t<n;t++){const n=e.charCodeAt(t);if(n===k||n===r||0==(65504&n)||0!=(49152&n)){a=!1;break}}if(a)return i(e)}const r=JSON.stringify(e),a=r.substring(1,r.length-1);return i('"'===t?a:"'"===t?a.replace(/'/g,"\\'"):a.replace(/[`$]/g,"\\$&"))}function T(e){return i(String(e).replace(/\*\//g,"* /"))}t.stringifyJSON=e=>{if(null==e)return"null";if(!0===e)return"true";if(!1===e)return"false";const t=typeof e;return"number"===t?""+e:"string"===t?j(e):JSON.stringify(e)},t.toJSON=t.stringifyJSON,t.lit=I,t.literal=I,t.substring=L,t.subcomment=T;const C=[...Object.getOwnPropertyNames(Object.prototype),...Object.getOwnPropertySymbols(Object.prototype)];t.isSafeObjectPropertyName=e=>("number"==typeof e||"symbol"==typeof e||"string"==typeof e&&/^(?:[0-9a-z$]|_[a-z0-9$])[a-z0-9_$]*$/i.test(e))&&!C.includes(e);function A(e){return!r.reservedWords.has(e)&&!!/^[a-zA-Z_$][a-zA-Z0-9_$]*$/.test(e)}function N(e){if("string"!=typeof e||!A(e))throw new Error(`Invalid identifier name '${e}'`);return i(e)}function M(e){if((0,t.isSafeObjectPropertyName)(e))return(e=>Number.isFinite(e)||"string"==typeof e&&("_"===e||/^(?:[a-z$]|_[a-z0-9$])[a-z0-9_$]*$/i.test(e)))(e)?i(String(e)):i(JSON.stringify(e));throw new Error(`Forbidden object key: ${JSON.stringify(e)}; consider using 'Object.create(null)' and assigning properties using te.lit.`)}function B(e){return e.length<x&&/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(e)}function D(e){return"string"==typeof e&&B(e)?i(`.${e}`):"string"==typeof e||"number"==typeof e&&Number.isFinite(e)?i(`[${(0,t.stringifyJSON)(e)}]`):K`[${K.lit(e)}]`}function R(e){return"string"==typeof e&&B(e)?i(`?.${e}`):"string"==typeof e||"number"==typeof e&&Number.isFinite(e)?i(`?.[${(0,t.stringifyJSON)(e)}]`):K`?.[${K.lit(e)}]`}function G(e,n=!1){if(!n&&C.includes(e))throw new Error(`Attempted to set '${String(e)}' on an object that isn't declared as having a null prototype. This could be unsafe.`);return"string"==typeof e&&B(e)?i(`.${e}`):"string"==typeof e||"number"==typeof e&&Number.isFinite(e)?i(`[${(0,t.stringifyJSON)(e)}]`):K`[${K.lit(e)}]`}function F(e=Symbol()){if("symbol"!=typeof e)throw new Error("Invalid call to te.tempVar");return function(e){return Object.freeze({[a.$$type]:"VARIABLE",s:e})}(e)}function z(e,t){const n=void 0!==e[a.$$type]?e:f(e),r=K.tempVar();return K`(${r} = ${n}, ${t(r)})`}function V(e,...t){if("raw"in e)return V(K(e,...t));if(t.length>0)throw new Error("Invalid call to `te.run`");const n=m(void 0!==e[a.$$type]?e:f(e)),r=Object.keys(n.refs),o=Object.values(n.refs);if(s&&q)throw new Error("te.run called, but batch is active - recommend you use runInBatch");try{return function(...e){return new Function(...e)}(...r,n.string)(...o)}catch(e){throw console.error("Error occurred during code generation:"),console.error(e),console.error("Function definition:"),console.error(n.string),new Error("Error occurred during code generation.")}}t.identifier=N,t.dangerousKey=M,t.safeKeyOrThrow=M,t.get=D,t.optionalGet=R,t.set=G,t.tempVar=F,t.tmp=z,t.eval=V,t.run=V;let q=null;function H(e,t){if(!q)throw new Error("te.runInBatch failed - there's no active batch");q.push({fragment:e,callback:t})}function U(e){if(q)throw new Error("te.batch failed - there's already a batch in progress");let t;try{q=[],e(),t=q}finally{q=null}if(0===t.length)return;const n=K`return [\n${K.join(t.map((e=>e.fragment)),",\n")}\n];`,r=K.run(n);for(let e=0,n=t.length;e<n;e++)t[e].callback(r[e])}function Q(e,t=""){if(!Array.isArray(e))throw new Error(`[tamedevil] Invalid te.join call - the first argument should be an array, but it was '${String(e)}'.`);if("string"!=typeof t)throw new Error(`[tamedevil] Invalid separator passed to te.join - must be a string, but we received '${String(t)}'`);if(0===e.length)return $;if(1===e.length){const t=e[0];return void 0!==t[a.$$type]?t:f(t,"join item 0")}const n=t.length>0;let r="";const o=[];for(let s=0,l=e.length;s<l;s++){const l=e[s],c=void 0!==l[a.$$type]?l:f(l,`join item ${s}`);if(s>0&&n&&(r+=t),"QUERY"===c[a.$$type])for(const e of c.n)"RAW"===e[a.$$type]?r+=e.t:(""!==r&&(o.push(i(r)),r=""),o.push(e));else"RAW"===c[a.$$type]?r+=c.t:(""!==r&&(o.push(i(r)),r=""),o.push(c))}return""!==r&&(o.push(i(r)),r=""),1===o.length?o[0]:p(o)}t.runInBatch=H,t.batch=U,t.join=Q;t.Idents=class Idents{constructor(){this.idents=new Set(r.reservedWords)}forbid(e){for(const t in e)this.idents.add(t)}makeSafeIdentifier(e){const{idents:t}=this,n="i_"+e.replace(/[^a-zA-Z0-9_$]+/g,"").replace(/_+/,"_");let r;for(let e=1;e<1e4;e++){const a=n+(e>1?String(e):"");if(!t.has(a)){r=a;break}}if(!r)throw new Error("Too many identifiers!");return t.add(r),r}};const K=g;t.te=K,t.default=K;const W={te:K,cache:P,ref:O,reference:O,lit:I,literal:I,substring:L,subcomment:T,join:Q,identifier:N,safeKeyOrThrow:M,dangerousKey:M,get:D,optionalGet:R,set:G,tmp:z,tempVar:F,run:V,eval:V,runInBatch:H,batch:U,compile:m,indent:function(e,...t){const n="raw"in e?K(e,...t):void 0!==e[a.$$type]?e:f(e);return s?u(n):n},indentIf:function(e,t){const n=void 0!==t[a.$$type]?t:f(t);return s&&e?u(n):n},undefined:E,blank:$,isTE:d,dangerouslyIncludeRawCode:w};Object.entries(W).forEach((([e,t])=>{t.$$export||o(t,e)})),Object.assign(g,W)},2008:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reservedWords=void 0,t.reservedWords=new Set(["await","break","case","catch","class","const","continue","debugger","default","delete","do","else","export","extends","false","finally","for","function","if","import","in","instanceof","new","null","return","super","switch","this","throw","true","try","typeof","var","void","while","with","let","static","yield","enum","implements","interface","package","private","protected","public","abstract","boolean","byte","char","double","final","float","goto","int","long","native","short","synchronized","throws","transient","volatile","arguments","as","import","require","eval","Function","from","get","of","in","set","null","undefined","Math","Number","BigInt","true","false","async","window","global","globalThis","process","require","import","constructor","class"])},5570:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.$$type=void 0;t.$$type=Symbol.for("tamedevil-type-1")},1261:e=>{"use strict";if(void 0===r){var t=new Error("Cannot find module 'undefined'");throw t.code="MODULE_NOT_FOUND",t}e.exports=r},8372:t=>{"use strict";t.exports=e},9402:e=>{"use strict";e.exports=n},1138:e=>{"use strict";if(void 0===t){var n=new Error("Cannot find module 'undefined'");throw n.code="MODULE_NOT_FOUND",n}e.exports=t},553:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.applyHooks=t.AsyncHooks=void 0;const r=n(282);t.AsyncHooks=class AsyncHooks{constructor(){this.callbacks=Object.create(null)}hook(e,t){this.callbacks[e]=this.callbacks[e]||[],this.callbacks[e].push(t)}process(e,...t){const n=this.callbacks[e];if(!n)return;const r=n.length;let a;for(let e=0;e<r;e++){const r=n[e];if(void 0!==a)a=a.then((()=>r.apply(null,t)));else{const e=r.apply(null,t);null!=e&&(a=e)}}return a}},t.applyHooks=function(e,t,n){const a=Object.create(null);let o=0;if(e)for(const n of e){const e=t(n);if(!e)continue;const r=Object.keys(e);for(const t of r){const r=e[t];if(!r)continue;const s=e=>"function"!=typeof e,i=(e=>"function"==typeof e)(r)?r:r.callback,{provides:l,before:c,after:u}=s(r)?r:{};a[t]||(a[t]=[]);const p=String(o++);a[t].push({id:p,plugin:n,callback:i,provides:[...l||[],p,n.name],before:c||[],after:u||[]})}}for(const e in a){const t=a[e];if(!t)continue;const o=(0,r.sortWithBeforeAfterProvides)(t,"id");for(const t of o)n(e,t.callback,t.plugin)}}},5172:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sortedPlugins=t.resolvePresets=t.isResolvedPreset=t.AsyncHooks=t.applyHooks=void 0,n(2630);const r=n(282);var a=n(553);Object.defineProperty(t,"applyHooks",{enumerable:!0,get:function(){return a.applyHooks}}),Object.defineProperty(t,"AsyncHooks",{enumerable:!0,get:function(){return a.AsyncHooks}});var o=n(6600);Object.defineProperty(t,"isResolvedPreset",{enumerable:!0,get:function(){return o.isResolvedPreset}}),Object.defineProperty(t,"resolvePresets",{enumerable:!0,get:function(){return o.resolvePresets}}),t.sortedPlugins=function(e){return e?(0,r.sortWithBeforeAfterProvides)(e,"name"):[]}},2630:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},6600:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolvePresets=t.isResolvedPreset=void 0,n(2630);const r=n(282),a=["name","experimental","provides","before","after"],o=["plugins","disablePlugins","extends"];let s;try{if(s=n(1138).inspect,"function"!=typeof s)throw new Error("Failed to load inspect")}catch{s=e=>Array.isArray(e)||!e||null===Object.getPrototypeOf(e)||Object.getPrototypeOf(e)===Object.prototype?JSON.stringify(e):String(e)}function i(e){return e.plugins&&0===e.extends?.length||!1}function l(e,t=!0){if(1===e.length){const t=e[0];if(t&&i(t))return t}const n={extends:[],plugins:[],disablePlugins:[]};for(const t of e){p(n,u(t))}return n.plugins&&(n.plugins=(0,r.sortWithBeforeAfterProvides)(n.plugins,"name")),t&&n.disablePlugins&&n.disablePlugins.length>0&&console.warn(`One or more of the plugin(s) entered in your preset's 'disablePlugins' list was not found:\n${n.disablePlugins.map((e=>` - ${e}`)).join("\n")}\nThe list of know plugins is:\n ${n.plugins?.map((e=>e.name)).join(", ")??"-"}`),n}function c(e){if("object"!=typeof e||null==e)throw new Error(`Expected plugin, but found '${s(e)}'`);const t=Object.getPrototypeOf(e);if(t!==Object.prototype&&null!==t)throw new Error(`Expected plugin to be a plain object, but found '${s(e)}'`);if("string"!=typeof e.name)throw new Error(`Expected plugin to have a string 'name'; found ${s(e.name)} (${s(e)})`);if(null!=e.version&&"string"!=typeof e.version)throw new Error(`Expected plugin '${e.name}' to have a string 'version'; found ${s(e.version)}`);for(const t of o)if(e[t])throw new Error(`Plugin '${e.name}' has '${t}' property which suggests it is a preset rather than a plugin. If it is indeed a preset you should add it to your preset via 'extends' rather than 'plugins'.`)}function u(e){if(!function(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return null===t||t===Object.prototype||"[object Object]"===String(e)}(e))throw new Error(`Expected a GraphileConfig preset (a plain JS object), but found '${s(e)}'`);try{for(const t of a)if(e[t])throw new Error(`Preset has '${t}' property which suggests it is a plugin rather than a preset. If it is indeed a plugin you should add it to your preset via 'plugins' rather than 'extends'.`);const{extends:t=[]}=e,n=l(t,!1);p(n,e);const r=n.disablePlugins;if(r){const e=new Set(n.plugins),t=new Set(r);for(const n of e)c(n),t.has(n.name)&&(t.delete(n.name),e.delete(n));n.plugins=[...e],n.disablePlugins=[...t]}return n}catch(t){throw new Error(`Error occurred when resolving preset: ${t}\nPreset: ${s(e)}`)}}function p(e,t){if(null!=e.extends&&0!==e.extends.length)throw new Error("First argument to mergePreset must be a resolved preset");const n=new Set([...e.plugins||[],...t.plugins||[]]);e.plugins=[...n],t.disablePlugins&&(e.disablePlugins=[...new Set([...e.disablePlugins??[],...t.disablePlugins??[]])]);const r=Object.keys(e).filter(d),a=Object.keys(t).filter(d),o=[...new Set([...r,...a])];for(const n of o){const r=e[n],a=t[n];if(r&&a){if(Array.isArray(r)!==Array.isArray(a))throw new Error(`${n} contains an array entry in one preset and a non-array entry in another, this doesn't make sense`);Array.isArray(a)?e[n]=a:e[n]=Object.assign(Object.create(null),r,a)}else e[n]=r||a}}function d(e){return"extends"!==e&&"plugins"!==e&&"disablePlugins"!==e}t.isResolvedPreset=i,t.resolvePresets=l},282:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sortWithBeforeAfterProvides=void 0,t.sortWithBeforeAfterProvides=function(e,t){const n=e.map((e=>{const n=[...e.before??[]],r=[...e.after??[]],a=[...e.provides??[]];return a.includes(e[t])||a.push(e[t]),{thing:e,before:n,after:r,provides:a}}));for(const{thing:e,before:r}of n){const{[t]:a}=e;if(r.length){const t=r.splice(0,r.length);for(const{thing:r,provides:o,after:s}of n)r!==e&&t.some((e=>o.includes(e)))&&s.push(a)}}const r=new Set;for(const{provides:e}of n)for(const t of e)r.add(t);for(const{after:e}of n)e.splice(0,e.length,...e.filter((e=>r.has(e))));const a=[],o=[...n];for(let e=0;e<1e4;e++){let e=0;if(0===o.length)break;for(let t=0;t<o.length;t++){const n=o[t];if(!n)continue;const{thing:r,after:s}=n;o.some((({thing:e,provides:t})=>e!==r&&t.some((e=>s.includes(e)))))||(e++,o.splice(t,1),a.push(r),t--)}if(0===e)throw new Error(`Infinite loop in dependencies detected; remaining items:\n ${o.map((e=>`${e.thing[t]} (after: ${e.after}; provides: ${e.provides})`)).join("\n ")}`)}if(a.length!==n.length)throw new Error(`Expected the same number of list entries after sorting (${a.length} != ${n.length})`);return a}},835:(e,t,n)=>{"use strict";n.r(t),n.d(t,{$$asyncIterator:()=>y,$$iterator:()=>o,createAsyncIterator:()=>S,createIterator:()=>p,forAwaitEach:()=>w,forEach:()=>f,getAsyncIterator:()=>m,getAsyncIteratorMethod:()=>g,getIterator:()=>c,getIteratorMethod:()=>u,isArrayLike:()=>i,isAsyncIterable:()=>b,isCollection:()=>l,isIterable:()=>s});var r="function"==typeof Symbol?Symbol:void 0,a=r&&r.iterator,o=a||"@@iterator";function s(e){return!!u(e)}function i(e){var t=null!=e&&e.length;return"number"==typeof t&&t>=0&&t%1==0}function l(e){return Object(e)===e&&(i(e)||s(e))}function c(e){var t=u(e);if(t)return t.call(e)}function u(e){if(null!=e){var t=a&&e[a]||e["@@iterator"];if("function"==typeof t)return t}}function p(e){if(null!=e){var t=c(e);if(t)return t;if(i(e))return new d(e)}}function d(e){this._o=e,this._i=0}function f(e,t,n){if(null!=e){if("function"==typeof e.forEach)return e.forEach(t,n);var r=0,a=c(e);if(a){for(var o;!(o=a.next()).done;)if(t.call(n,o.value,r++,e),r>9999999)throw new TypeError("Near-infinite iteration.")}else if(i(e))for(;r<e.length;r++)e.hasOwnProperty(r)&&t.call(n,e[r],r,e)}}d.prototype[o]=function(){return this},d.prototype.next=function(){return void 0===this._o||this._i>=this._o.length?(this._o=void 0,{value:void 0,done:!0}):{value:this._o[this._i++],done:!1}};var h=r&&r.asyncIterator,y=h||"@@asyncIterator";function b(e){return!!g(e)}function m(e){var t=g(e);if(t)return t.call(e)}function g(e){if(null!=e){var t=h&&e[h]||e["@@asyncIterator"];if("function"==typeof t)return t}}function S(e){if(null!=e){var t=m(e);if(t)return t;var n=p(e);if(n)return new P(n)}}function P(e){this._i=e}function v(e,t,n){var r;return new Promise((function(a){a((r=e[t](n)).value)})).then((function(e){return{value:e,done:r.done}}))}function w(e,t,n){var r=S(e);if(r){var a=0;return new Promise((function(o,s){!function i(){return r.next().then((function(r){return r.done?o():Promise.resolve(t.call(n,r.value,a++,e)).then(i).catch(s),null})).catch(s),null}()}))}}P.prototype[y]=function(){return this},P.prototype.next=function(e){return v(this._i,"next",e)},P.prototype.return=function(e){return this._i.return?v(this._i,"return",e):Promise.resolve({value:e,done:!0})},P.prototype.throw=function(e){return this._i.throw?v(this._i,"throw",e):Promise.reject(e)}}},s={};function i(e){var t=s[e];if(void 0!==t)return t.exports;var n=s[e]={id:e,loaded:!1,exports:{}};return o[e](n,n.exports,i),n.loaded=!0,n.exports}i.m=o,a=[],i.O=(e,t,n,r)=>{if(!t){var o=1/0;for(u=0;u<a.length;u++){for(var[t,n,r]=a[u],s=!0,l=0;l<t.length;l++)(!1&r||o>=r)&&Object.keys(i.O).every((e=>i.O[e](t[l])))?t.splice(l--,1):(s=!1,r<o&&(o=r));if(s){a.splice(u--,1);var c=n();void 0!==c&&(e=c)}}return e}r=r||0;for(var u=a.length;u>0&&a[u-1][2]>r;u--)a[u]=a[u-1];a[u]=[t,n,r]},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{var e={826:0};i.O.j=t=>0===e[t];var t=(t,n)=>{var r,a,[o,s,l]=n,c=0;if(o.some((t=>0!==e[t]))){for(r in s)i.o(s,r)&&(i.m[r]=s[r]);if(l)var u=l(i)}for(t&&t(n);c<o.length;c++)a=o[c],i.o(e,a)&&e[a]&&e[a][0](),e[a]=0;return i.O(u)},n=this.webpackChunkgrafast=this.webpackChunkgrafast||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))})();var l=i(5590);return l=i.O(l)})()));
|
package/dist/steps/node.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { GraphQLObjectType } from "graphql";
|
|
2
|
-
import type { ExecutionExtra, NodeIdHandler, PolymorphicData } from "../interfaces.js";
|
|
2
|
+
import type { AnyInputStep, ExecutionExtra, NodeIdHandler, PolymorphicData } from "../interfaces.js";
|
|
3
3
|
import type { ExecutableStep, PolymorphicStep } from "../step.js";
|
|
4
4
|
import { UnbatchedExecutableStep } from "../step.js";
|
|
5
5
|
/**
|
|
@@ -33,5 +33,5 @@ export declare class NodeStep extends UnbatchedExecutableStep implements Polymor
|
|
|
33
33
|
export declare function node(possibleTypes: {
|
|
34
34
|
[typeName: string]: NodeIdHandler;
|
|
35
35
|
}, $id: ExecutableStep<string>): NodeStep;
|
|
36
|
-
export declare function specFromNodeId(handler: NodeIdHandler<any>, $id: ExecutableStep<string>): any;
|
|
36
|
+
export declare function specFromNodeId(handler: NodeIdHandler<any>, $id: ExecutableStep<string> | AnyInputStep): any;
|
|
37
37
|
//# sourceMappingURL=node.d.ts.map
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const version = "0.0.1-beta.
|
|
1
|
+
export declare const version = "0.0.1-beta.4";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|