view-contracts 0.3.3 → 0.3.5
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/README.md +6 -6
- package/cli-contract.yaml +1 -1
- package/dist/view-contracts.bundle.mjs +169 -153
- package/dist/view-contracts.bundle.mjs.map +4 -4
- package/docs/cli-reference.md +1 -1
- package/package.json +1 -1
- package/renderers/NATIVE_THEME_EMIT.md +73 -0
- package/renderers/compose/README.md +7 -0
- package/renderers/compose/templates/Screen.kt.hbs +3 -5
- package/renderers/compose/templates/VcTheme.kt.hbs +7 -13
- package/renderers/react/defaults/theme.yaml +7 -0
- package/renderers/react/defaults/tokens.yaml +11 -0
- package/renderers/react/lowering/foldStyle.ts +87 -0
- package/renderers/react/lowering/lowerToJsx.ts +58 -69
- package/renderers/react/renderComponents.ts +180 -24
- package/renderers/react/renderRuntime.ts +36 -43
- package/renderers/react/routes.yaml +2 -2
- package/renderers/react/runtime/index.ts +1 -1
- package/renderers/react/runtime/style.ts +3 -55
- package/renderers/react/runtime/theme.css +1 -1
- package/renderers/react/runtime/types.ts +0 -24
- package/renderers/react/style/foldLiterals.ts +129 -0
- package/renderers/react/syncGeneratedRuntime.ts +35 -47
- package/renderers/react/templates/components-index.ts.hbs +2 -2
- package/renderers/react/templates/runtime.ts.hbs +10 -0
- package/renderers/react/templates/style-helpers.ts.hbs +2 -2
- package/renderers/swiftui/README.md +7 -0
- package/renderers/swiftui/templates/Screen.swift.hbs +3 -5
- package/renderers/swiftui/templates/VcTheme.swift.hbs +8 -16
- package/spec/ui-dsl.schema.json +1331 -345
- package/src/generated/schema/allowed-components.ts +1 -1
- package/src/generated/schema/dsl-enums.ts +1 -1
- package/src/generated/schema/dsl-properties.ts +1 -1
- package/src/generated/schema/index.ts +1 -1
- package/src/generated/schema/lowering-style-properties.ts +9 -2
- package/src/generated/schema/react-renderer-element-config.ts +1 -1
- package/src/generated/schema/schema-document.ts +1 -1
|
@@ -1,52 +1,52 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire as __banner_createRequire } from 'module';
|
|
3
3
|
const require = __banner_createRequire(import.meta.url);
|
|
4
|
-
var
|
|
5
|
-
`)}displayWidth(e){return
|
|
6
|
-
`+" ".repeat(r+l)),
|
|
7
|
-
${
|
|
8
|
-
`)}};function
|
|
4
|
+
var cy=Object.create;var lu=Object.defineProperty;var ly=Object.getOwnPropertyDescriptor;var uy=Object.getOwnPropertyNames;var fy=Object.getPrototypeOf,py=Object.prototype.hasOwnProperty;var nt=(t=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(t,{get:(e,r)=>(typeof require<"u"?require:e)[r]}):t)(function(t){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+t+'" is not supported')});var w=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}};var dy=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of uy(e))!py.call(t,i)&&i!==r&&lu(t,i,{get:()=>e[i],enumerable:!(n=ly(e,i))||n.enumerable});return t};var xi=(t,e,r)=>(r=t!=null?cy(fy(t)):{},dy(e||!t||!t.__esModule?lu(r,"default",{value:t,enumerable:!0}):r,t));var ln=w(_s=>{var Ci=class extends Error{constructor(e,r,n){super(n),Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name,this.code=r,this.exitCode=e,this.nestedError=void 0}},vs=class extends Ci{constructor(e){super(1,"commander.invalidArgument",e),Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name}};_s.CommanderError=Ci;_s.InvalidArgumentError=vs});var Pi=w(bs=>{var{InvalidArgumentError:hy}=ln(),ws=class{constructor(e,r){switch(this.description=r||"",this.variadic=!1,this.parseArg=void 0,this.defaultValue=void 0,this.defaultValueDescription=void 0,this.argChoices=void 0,e[0]){case"<":this.required=!0,this._name=e.slice(1,-1);break;case"[":this.required=!1,this._name=e.slice(1,-1);break;default:this.required=!0,this._name=e;break}this._name.endsWith("...")&&(this.variadic=!0,this._name=this._name.slice(0,-3))}name(){return this._name}_collectValue(e,r){return r===this.defaultValue||!Array.isArray(r)?[e]:(r.push(e),r)}default(e,r){return this.defaultValue=e,this.defaultValueDescription=r,this}argParser(e){return this.parseArg=e,this}choices(e){return this.argChoices=e.slice(),this.parseArg=(r,n)=>{if(!this.argChoices.includes(r))throw new hy(`Allowed choices are ${this.argChoices.join(", ")}.`);return this.variadic?this._collectValue(r,n):r},this}argRequired(){return this.required=!0,this}argOptional(){return this.required=!1,this}};function my(t){let e=t.name()+(t.variadic===!0?"...":"");return t.required?"<"+e+">":"["+e+"]"}bs.Argument=ws;bs.humanReadableArgName=my});var $s=w(Es=>{var{humanReadableArgName:gy}=Pi(),Ss=class{constructor(){this.helpWidth=void 0,this.minWidthToWrap=40,this.sortSubcommands=!1,this.sortOptions=!1,this.showGlobalOptions=!1}prepareContext(e){this.helpWidth=this.helpWidth??e.helpWidth??80}visibleCommands(e){let r=e.commands.filter(i=>!i._hidden),n=e._getHelpCommand();return n&&!n._hidden&&r.push(n),this.sortSubcommands&&r.sort((i,o)=>i.name().localeCompare(o.name())),r}compareOptions(e,r){let n=i=>i.short?i.short.replace(/^-/,""):i.long.replace(/^--/,"");return n(e).localeCompare(n(r))}visibleOptions(e){let r=e.options.filter(i=>!i.hidden),n=e._getHelpOption();if(n&&!n.hidden){let i=n.short&&e._findOption(n.short),o=n.long&&e._findOption(n.long);!i&&!o?r.push(n):n.long&&!o?r.push(e.createOption(n.long,n.description)):n.short&&!i&&r.push(e.createOption(n.short,n.description))}return this.sortOptions&&r.sort(this.compareOptions),r}visibleGlobalOptions(e){if(!this.showGlobalOptions)return[];let r=[];for(let n=e.parent;n;n=n.parent){let i=n.options.filter(o=>!o.hidden);r.push(...i)}return this.sortOptions&&r.sort(this.compareOptions),r}visibleArguments(e){return e._argsDescription&&e.registeredArguments.forEach(r=>{r.description=r.description||e._argsDescription[r.name()]||""}),e.registeredArguments.find(r=>r.description)?e.registeredArguments:[]}subcommandTerm(e){let r=e.registeredArguments.map(n=>gy(n)).join(" ");return e._name+(e._aliases[0]?"|"+e._aliases[0]:"")+(e.options.length?" [options]":"")+(r?" "+r:"")}optionTerm(e){return e.flags}argumentTerm(e){return e.name()}longestSubcommandTermLength(e,r){return r.visibleCommands(e).reduce((n,i)=>Math.max(n,this.displayWidth(r.styleSubcommandTerm(r.subcommandTerm(i)))),0)}longestOptionTermLength(e,r){return r.visibleOptions(e).reduce((n,i)=>Math.max(n,this.displayWidth(r.styleOptionTerm(r.optionTerm(i)))),0)}longestGlobalOptionTermLength(e,r){return r.visibleGlobalOptions(e).reduce((n,i)=>Math.max(n,this.displayWidth(r.styleOptionTerm(r.optionTerm(i)))),0)}longestArgumentTermLength(e,r){return r.visibleArguments(e).reduce((n,i)=>Math.max(n,this.displayWidth(r.styleArgumentTerm(r.argumentTerm(i)))),0)}commandUsage(e){let r=e._name;e._aliases[0]&&(r=r+"|"+e._aliases[0]);let n="";for(let i=e.parent;i;i=i.parent)n=i.name()+" "+n;return n+r+" "+e.usage()}commandDescription(e){return e.description()}subcommandDescription(e){return e.summary()||e.description()}optionDescription(e){let r=[];if(e.argChoices&&r.push(`choices: ${e.argChoices.map(n=>JSON.stringify(n)).join(", ")}`),e.defaultValue!==void 0&&(e.required||e.optional||e.isBoolean()&&typeof e.defaultValue=="boolean")&&r.push(`default: ${e.defaultValueDescription||JSON.stringify(e.defaultValue)}`),e.presetArg!==void 0&&e.optional&&r.push(`preset: ${JSON.stringify(e.presetArg)}`),e.envVar!==void 0&&r.push(`env: ${e.envVar}`),r.length>0){let n=`(${r.join(", ")})`;return e.description?`${e.description} ${n}`:n}return e.description}argumentDescription(e){let r=[];if(e.argChoices&&r.push(`choices: ${e.argChoices.map(n=>JSON.stringify(n)).join(", ")}`),e.defaultValue!==void 0&&r.push(`default: ${e.defaultValueDescription||JSON.stringify(e.defaultValue)}`),r.length>0){let n=`(${r.join(", ")})`;return e.description?`${e.description} ${n}`:n}return e.description}formatItemList(e,r,n){return r.length===0?[]:[n.styleTitle(e),...r,""]}groupItems(e,r,n){let i=new Map;return e.forEach(o=>{let s=n(o);i.has(s)||i.set(s,[])}),r.forEach(o=>{let s=n(o);i.has(s)||i.set(s,[]),i.get(s).push(o)}),i}formatHelp(e,r){let n=r.padWidth(e,r),i=r.helpWidth??80;function o(f,h){return r.formatItem(f,n,h,r)}let s=[`${r.styleTitle("Usage:")} ${r.styleUsage(r.commandUsage(e))}`,""],a=r.commandDescription(e);a.length>0&&(s=s.concat([r.boxWrap(r.styleCommandDescription(a),i),""]));let l=r.visibleArguments(e).map(f=>o(r.styleArgumentTerm(r.argumentTerm(f)),r.styleArgumentDescription(r.argumentDescription(f))));if(s=s.concat(this.formatItemList("Arguments:",l,r)),this.groupItems(e.options,r.visibleOptions(e),f=>f.helpGroupHeading??"Options:").forEach((f,h)=>{let m=f.map(g=>o(r.styleOptionTerm(r.optionTerm(g)),r.styleOptionDescription(r.optionDescription(g))));s=s.concat(this.formatItemList(h,m,r))}),r.showGlobalOptions){let f=r.visibleGlobalOptions(e).map(h=>o(r.styleOptionTerm(r.optionTerm(h)),r.styleOptionDescription(r.optionDescription(h))));s=s.concat(this.formatItemList("Global Options:",f,r))}return this.groupItems(e.commands,r.visibleCommands(e),f=>f.helpGroup()||"Commands:").forEach((f,h)=>{let m=f.map(g=>o(r.styleSubcommandTerm(r.subcommandTerm(g)),r.styleSubcommandDescription(r.subcommandDescription(g))));s=s.concat(this.formatItemList(h,m,r))}),s.join(`
|
|
5
|
+
`)}displayWidth(e){return uu(e).length}styleTitle(e){return e}styleUsage(e){return e.split(" ").map(r=>r==="[options]"?this.styleOptionText(r):r==="[command]"?this.styleSubcommandText(r):r[0]==="["||r[0]==="<"?this.styleArgumentText(r):this.styleCommandText(r)).join(" ")}styleCommandDescription(e){return this.styleDescriptionText(e)}styleOptionDescription(e){return this.styleDescriptionText(e)}styleSubcommandDescription(e){return this.styleDescriptionText(e)}styleArgumentDescription(e){return this.styleDescriptionText(e)}styleDescriptionText(e){return e}styleOptionTerm(e){return this.styleOptionText(e)}styleSubcommandTerm(e){return e.split(" ").map(r=>r==="[options]"?this.styleOptionText(r):r[0]==="["||r[0]==="<"?this.styleArgumentText(r):this.styleSubcommandText(r)).join(" ")}styleArgumentTerm(e){return this.styleArgumentText(e)}styleOptionText(e){return e}styleArgumentText(e){return e}styleSubcommandText(e){return e}styleCommandText(e){return e}padWidth(e,r){return Math.max(r.longestOptionTermLength(e,r),r.longestGlobalOptionTermLength(e,r),r.longestSubcommandTermLength(e,r),r.longestArgumentTermLength(e,r))}preformatted(e){return/\n[^\S\r\n]/.test(e)}formatItem(e,r,n,i){let s=" ".repeat(2);if(!n)return s+e;let a=e.padEnd(r+e.length-i.displayWidth(e)),l=2,p=(this.helpWidth??80)-r-l-2,f;return p<this.minWidthToWrap||i.preformatted(n)?f=n:f=i.boxWrap(n,p).replace(/\n/g,`
|
|
6
|
+
`+" ".repeat(r+l)),s+a+" ".repeat(l)+f.replace(/\n/g,`
|
|
7
|
+
${s}`)}boxWrap(e,r){if(r<this.minWidthToWrap)return e;let n=e.split(/\r\n|\n/),i=/[\s]*[^\s]+/g,o=[];return n.forEach(s=>{let a=s.match(i);if(a===null){o.push("");return}let l=[a.shift()],u=this.displayWidth(l[0]);a.forEach(p=>{let f=this.displayWidth(p);if(u+f<=r){l.push(p),u+=f;return}o.push(l.join(""));let h=p.trimStart();l=[h],u=this.displayWidth(h)}),o.push(l.join(""))}),o.join(`
|
|
8
|
+
`)}};function uu(t){let e=/\x1b\[\d*(;\d*)*m/g;return t.replace(e,"")}Es.Help=Ss;Es.stripColor=uu});var ks=w(Ps=>{var{InvalidArgumentError:yy}=ln(),xs=class{constructor(e,r){this.flags=e,this.description=r||"",this.required=e.includes("<"),this.optional=e.includes("["),this.variadic=/\w\.\.\.[>\]]$/.test(e),this.mandatory=!1;let n=vy(e);this.short=n.shortFlag,this.long=n.longFlag,this.negate=!1,this.long&&(this.negate=this.long.startsWith("--no-")),this.defaultValue=void 0,this.defaultValueDescription=void 0,this.presetArg=void 0,this.envVar=void 0,this.parseArg=void 0,this.hidden=!1,this.argChoices=void 0,this.conflictsWith=[],this.implied=void 0,this.helpGroupHeading=void 0}default(e,r){return this.defaultValue=e,this.defaultValueDescription=r,this}preset(e){return this.presetArg=e,this}conflicts(e){return this.conflictsWith=this.conflictsWith.concat(e),this}implies(e){let r=e;return typeof e=="string"&&(r={[e]:!0}),this.implied=Object.assign(this.implied||{},r),this}env(e){return this.envVar=e,this}argParser(e){return this.parseArg=e,this}makeOptionMandatory(e=!0){return this.mandatory=!!e,this}hideHelp(e=!0){return this.hidden=!!e,this}_collectValue(e,r){return r===this.defaultValue||!Array.isArray(r)?[e]:(r.push(e),r)}choices(e){return this.argChoices=e.slice(),this.parseArg=(r,n)=>{if(!this.argChoices.includes(r))throw new yy(`Allowed choices are ${this.argChoices.join(", ")}.`);return this.variadic?this._collectValue(r,n):r},this}name(){return this.long?this.long.replace(/^--/,""):this.short.replace(/^-/,"")}attributeName(){return this.negate?fu(this.name().replace(/^no-/,"")):fu(this.name())}helpGroup(e){return this.helpGroupHeading=e,this}is(e){return this.short===e||this.long===e}isBoolean(){return!this.required&&!this.optional&&!this.negate}},Cs=class{constructor(e){this.positiveOptions=new Map,this.negativeOptions=new Map,this.dualOptions=new Set,e.forEach(r=>{r.negate?this.negativeOptions.set(r.attributeName(),r):this.positiveOptions.set(r.attributeName(),r)}),this.negativeOptions.forEach((r,n)=>{this.positiveOptions.has(n)&&this.dualOptions.add(n)})}valueFromOption(e,r){let n=r.attributeName();if(!this.dualOptions.has(n))return!0;let i=this.negativeOptions.get(n).presetArg,o=i!==void 0?i:!1;return r.negate===(o===e)}};function fu(t){return t.split("-").reduce((e,r)=>e+r[0].toUpperCase()+r.slice(1))}function vy(t){let e,r,n=/^-[^-]$/,i=/^--[^-]/,o=t.split(/[ |,]+/).concat("guard");if(n.test(o[0])&&(e=o.shift()),i.test(o[0])&&(r=o.shift()),!e&&n.test(o[0])&&(e=o.shift()),!e&&i.test(o[0])&&(e=r,r=o.shift()),o[0].startsWith("-")){let s=o[0],a=`option creation failed due to '${s}' in option flags '${t}'`;throw/^-[^-][^-]/.test(s)?new Error(`${a}
|
|
9
9
|
- a short flag is a single dash and a single character
|
|
10
10
|
- either use a single dash and a single character (for a short flag)
|
|
11
|
-
- or use a double dash for a long option (and can have two, like '--ws, --workspace')`):n.test(
|
|
12
|
-
- too many short flags`):i.test(
|
|
11
|
+
- or use a double dash for a long option (and can have two, like '--ws, --workspace')`):n.test(s)?new Error(`${a}
|
|
12
|
+
- too many short flags`):i.test(s)?new Error(`${a}
|
|
13
13
|
- too many long flags`):new Error(`${a}
|
|
14
|
-
- unrecognised flag format`)}if(e===void 0&&r===void 0)throw new Error(`option creation failed due to no flags found in '${t}'.`);return{shortFlag:e,longFlag:r}}
|
|
14
|
+
- unrecognised flag format`)}if(e===void 0&&r===void 0)throw new Error(`option creation failed due to no flags found in '${t}'.`);return{shortFlag:e,longFlag:r}}Ps.Option=xs;Ps.DualOptions=Cs});var du=w(pu=>{function _y(t,e){if(Math.abs(t.length-e.length)>3)return Math.max(t.length,e.length);let r=[];for(let n=0;n<=t.length;n++)r[n]=[n];for(let n=0;n<=e.length;n++)r[0][n]=n;for(let n=1;n<=e.length;n++)for(let i=1;i<=t.length;i++){let o=1;t[i-1]===e[n-1]?o=0:o=1,r[i][n]=Math.min(r[i-1][n]+1,r[i][n-1]+1,r[i-1][n-1]+o),i>1&&n>1&&t[i-1]===e[n-2]&&t[i-2]===e[n-1]&&(r[i][n]=Math.min(r[i][n],r[i-2][n-2]+1))}return r[t.length][e.length]}function wy(t,e){if(!e||e.length===0)return"";e=Array.from(new Set(e));let r=t.startsWith("--");r&&(t=t.slice(2),e=e.map(s=>s.slice(2)));let n=[],i=3,o=.4;return e.forEach(s=>{if(s.length<=1)return;let a=_y(t,s),l=Math.max(t.length,s.length);(l-a)/l>o&&(a<i?(i=a,n=[s]):a===i&&n.push(s))}),n.sort((s,a)=>s.localeCompare(a)),r&&(n=n.map(s=>`--${s}`)),n.length>1?`
|
|
15
15
|
(Did you mean one of ${n.join(", ")}?)`:n.length===1?`
|
|
16
|
-
(Did you mean ${n[0]}?)`:""}
|
|
17
|
-
- specify the name in Command constructor or using .name()`);return r=r||{},r.isDefault&&(this._defaultCommandName=e._name),(r.noHelp||r.hidden)&&(e._hidden=!0),this._registerCommand(e),e.parent=this,e._checkForBrokenPassThrough(),this}createArgument(e,r){return new
|
|
18
|
-
Expecting one of '${n.join("', '")}'`);return this._lifeCycleHooks[e]?this._lifeCycleHooks[e].push(r):this._lifeCycleHooks[e]=[r],this}exitOverride(e){return e?this._exitCallback=e:this._exitCallback=r=>{if(r.code!=="commander.executeSubCommandAsync")throw r},this}_exit(e,r,n){this._exitCallback&&this._exitCallback(new
|
|
19
|
-
- already used by option '${r.flags}'`)}this._initOptionGroup(e),this.options.push(e)}_registerCommand(e){let r=i=>[i.name()].concat(i.aliases()),n=r(e).find(i=>this._findCommand(i));if(n){let i=r(this._findCommand(n)).join("|"),
|
|
20
|
-
- either make a new Command for each call to parse, or stop storing options as properties`);this._name=this._savedState._name,this._scriptPath=null,this.rawArgs=[],this._optionValues={...this._savedState._optionValues},this._optionValueSources={...this._savedState._optionValueSources},this.args=[],this.processedArgs=[]}_checkForMissingExecutable(e,r,n){if(
|
|
16
|
+
(Did you mean ${n[0]}?)`:""}pu.suggestSimilar=wy});var yu=w(Ts=>{var by=nt("node:events").EventEmitter,As=nt("node:child_process"),xt=nt("node:path"),ki=nt("node:fs"),ie=nt("node:process"),{Argument:Sy,humanReadableArgName:Ey}=Pi(),{CommanderError:Os}=ln(),{Help:$y,stripColor:xy}=$s(),{Option:hu,DualOptions:Cy}=ks(),{suggestSimilar:mu}=du(),Rs=class t extends by{constructor(e){super(),this.commands=[],this.options=[],this.parent=null,this._allowUnknownOption=!1,this._allowExcessArguments=!1,this.registeredArguments=[],this._args=this.registeredArguments,this.args=[],this.rawArgs=[],this.processedArgs=[],this._scriptPath=null,this._name=e||"",this._optionValues={},this._optionValueSources={},this._storeOptionsAsProperties=!1,this._actionHandler=null,this._executableHandler=!1,this._executableFile=null,this._executableDir=null,this._defaultCommandName=null,this._exitCallback=null,this._aliases=[],this._combineFlagAndOptionalValue=!0,this._description="",this._summary="",this._argsDescription=void 0,this._enablePositionalOptions=!1,this._passThroughOptions=!1,this._lifeCycleHooks={},this._showHelpAfterError=!1,this._showSuggestionAfterError=!0,this._savedState=null,this._outputConfiguration={writeOut:r=>ie.stdout.write(r),writeErr:r=>ie.stderr.write(r),outputError:(r,n)=>n(r),getOutHelpWidth:()=>ie.stdout.isTTY?ie.stdout.columns:void 0,getErrHelpWidth:()=>ie.stderr.isTTY?ie.stderr.columns:void 0,getOutHasColors:()=>Is()??(ie.stdout.isTTY&&ie.stdout.hasColors?.()),getErrHasColors:()=>Is()??(ie.stderr.isTTY&&ie.stderr.hasColors?.()),stripColor:r=>xy(r)},this._hidden=!1,this._helpOption=void 0,this._addImplicitHelpCommand=void 0,this._helpCommand=void 0,this._helpConfiguration={},this._helpGroupHeading=void 0,this._defaultCommandGroup=void 0,this._defaultOptionGroup=void 0}copyInheritedSettings(e){return this._outputConfiguration=e._outputConfiguration,this._helpOption=e._helpOption,this._helpCommand=e._helpCommand,this._helpConfiguration=e._helpConfiguration,this._exitCallback=e._exitCallback,this._storeOptionsAsProperties=e._storeOptionsAsProperties,this._combineFlagAndOptionalValue=e._combineFlagAndOptionalValue,this._allowExcessArguments=e._allowExcessArguments,this._enablePositionalOptions=e._enablePositionalOptions,this._showHelpAfterError=e._showHelpAfterError,this._showSuggestionAfterError=e._showSuggestionAfterError,this}_getCommandAndAncestors(){let e=[];for(let r=this;r;r=r.parent)e.push(r);return e}command(e,r,n){let i=r,o=n;typeof i=="object"&&i!==null&&(o=i,i=null),o=o||{};let[,s,a]=e.match(/([^ ]+) *(.*)/),l=this.createCommand(s);return i&&(l.description(i),l._executableHandler=!0),o.isDefault&&(this._defaultCommandName=l._name),l._hidden=!!(o.noHelp||o.hidden),l._executableFile=o.executableFile||null,a&&l.arguments(a),this._registerCommand(l),l.parent=this,l.copyInheritedSettings(this),i?this:l}createCommand(e){return new t(e)}createHelp(){return Object.assign(new $y,this.configureHelp())}configureHelp(e){return e===void 0?this._helpConfiguration:(this._helpConfiguration=e,this)}configureOutput(e){return e===void 0?this._outputConfiguration:(this._outputConfiguration={...this._outputConfiguration,...e},this)}showHelpAfterError(e=!0){return typeof e!="string"&&(e=!!e),this._showHelpAfterError=e,this}showSuggestionAfterError(e=!0){return this._showSuggestionAfterError=!!e,this}addCommand(e,r){if(!e._name)throw new Error(`Command passed to .addCommand() must have a name
|
|
17
|
+
- specify the name in Command constructor or using .name()`);return r=r||{},r.isDefault&&(this._defaultCommandName=e._name),(r.noHelp||r.hidden)&&(e._hidden=!0),this._registerCommand(e),e.parent=this,e._checkForBrokenPassThrough(),this}createArgument(e,r){return new Sy(e,r)}argument(e,r,n,i){let o=this.createArgument(e,r);return typeof n=="function"?o.default(i).argParser(n):o.default(n),this.addArgument(o),this}arguments(e){return e.trim().split(/ +/).forEach(r=>{this.argument(r)}),this}addArgument(e){let r=this.registeredArguments.slice(-1)[0];if(r?.variadic)throw new Error(`only the last argument can be variadic '${r.name()}'`);if(e.required&&e.defaultValue!==void 0&&e.parseArg===void 0)throw new Error(`a default value for a required argument is never used: '${e.name()}'`);return this.registeredArguments.push(e),this}helpCommand(e,r){if(typeof e=="boolean")return this._addImplicitHelpCommand=e,e&&this._defaultCommandGroup&&this._initCommandGroup(this._getHelpCommand()),this;let n=e??"help [command]",[,i,o]=n.match(/([^ ]+) *(.*)/),s=r??"display help for command",a=this.createCommand(i);return a.helpOption(!1),o&&a.arguments(o),s&&a.description(s),this._addImplicitHelpCommand=!0,this._helpCommand=a,(e||r)&&this._initCommandGroup(a),this}addHelpCommand(e,r){return typeof e!="object"?(this.helpCommand(e,r),this):(this._addImplicitHelpCommand=!0,this._helpCommand=e,this._initCommandGroup(e),this)}_getHelpCommand(){return this._addImplicitHelpCommand??(this.commands.length&&!this._actionHandler&&!this._findCommand("help"))?(this._helpCommand===void 0&&this.helpCommand(void 0,void 0),this._helpCommand):null}hook(e,r){let n=["preSubcommand","preAction","postAction"];if(!n.includes(e))throw new Error(`Unexpected value for event passed to hook : '${e}'.
|
|
18
|
+
Expecting one of '${n.join("', '")}'`);return this._lifeCycleHooks[e]?this._lifeCycleHooks[e].push(r):this._lifeCycleHooks[e]=[r],this}exitOverride(e){return e?this._exitCallback=e:this._exitCallback=r=>{if(r.code!=="commander.executeSubCommandAsync")throw r},this}_exit(e,r,n){this._exitCallback&&this._exitCallback(new Os(e,r,n)),ie.exit(e)}action(e){let r=n=>{let i=this.registeredArguments.length,o=n.slice(0,i);return this._storeOptionsAsProperties?o[i]=this:o[i]=this.opts(),o.push(this),e.apply(this,o)};return this._actionHandler=r,this}createOption(e,r){return new hu(e,r)}_callParseArg(e,r,n,i){try{return e.parseArg(r,n)}catch(o){if(o.code==="commander.invalidArgument"){let s=`${i} ${o.message}`;this.error(s,{exitCode:o.exitCode,code:o.code})}throw o}}_registerOption(e){let r=e.short&&this._findOption(e.short)||e.long&&this._findOption(e.long);if(r){let n=e.long&&this._findOption(e.long)?e.long:e.short;throw new Error(`Cannot add option '${e.flags}'${this._name&&` to command '${this._name}'`} due to conflicting flag '${n}'
|
|
19
|
+
- already used by option '${r.flags}'`)}this._initOptionGroup(e),this.options.push(e)}_registerCommand(e){let r=i=>[i.name()].concat(i.aliases()),n=r(e).find(i=>this._findCommand(i));if(n){let i=r(this._findCommand(n)).join("|"),o=r(e).join("|");throw new Error(`cannot add command '${o}' as already have command '${i}'`)}this._initCommandGroup(e),this.commands.push(e)}addOption(e){this._registerOption(e);let r=e.name(),n=e.attributeName();if(e.negate){let o=e.long.replace(/^--no-/,"--");this._findOption(o)||this.setOptionValueWithSource(n,e.defaultValue===void 0?!0:e.defaultValue,"default")}else e.defaultValue!==void 0&&this.setOptionValueWithSource(n,e.defaultValue,"default");let i=(o,s,a)=>{o==null&&e.presetArg!==void 0&&(o=e.presetArg);let l=this.getOptionValue(n);o!==null&&e.parseArg?o=this._callParseArg(e,o,l,s):o!==null&&e.variadic&&(o=e._collectValue(o,l)),o==null&&(e.negate?o=!1:e.isBoolean()||e.optional?o=!0:o=""),this.setOptionValueWithSource(n,o,a)};return this.on("option:"+r,o=>{let s=`error: option '${e.flags}' argument '${o}' is invalid.`;i(o,s,"cli")}),e.envVar&&this.on("optionEnv:"+r,o=>{let s=`error: option '${e.flags}' value '${o}' from env '${e.envVar}' is invalid.`;i(o,s,"env")}),this}_optionEx(e,r,n,i,o){if(typeof r=="object"&&r instanceof hu)throw new Error("To add an Option object use addOption() instead of option() or requiredOption()");let s=this.createOption(r,n);if(s.makeOptionMandatory(!!e.mandatory),typeof i=="function")s.default(o).argParser(i);else if(i instanceof RegExp){let a=i;i=(l,u)=>{let p=a.exec(l);return p?p[0]:u},s.default(o).argParser(i)}else s.default(i);return this.addOption(s)}option(e,r,n,i){return this._optionEx({},e,r,n,i)}requiredOption(e,r,n,i){return this._optionEx({mandatory:!0},e,r,n,i)}combineFlagAndOptionalValue(e=!0){return this._combineFlagAndOptionalValue=!!e,this}allowUnknownOption(e=!0){return this._allowUnknownOption=!!e,this}allowExcessArguments(e=!0){return this._allowExcessArguments=!!e,this}enablePositionalOptions(e=!0){return this._enablePositionalOptions=!!e,this}passThroughOptions(e=!0){return this._passThroughOptions=!!e,this._checkForBrokenPassThrough(),this}_checkForBrokenPassThrough(){if(this.parent&&this._passThroughOptions&&!this.parent._enablePositionalOptions)throw new Error(`passThroughOptions cannot be used for '${this._name}' without turning on enablePositionalOptions for parent command(s)`)}storeOptionsAsProperties(e=!0){if(this.options.length)throw new Error("call .storeOptionsAsProperties() before adding options");if(Object.keys(this._optionValues).length)throw new Error("call .storeOptionsAsProperties() before setting option values");return this._storeOptionsAsProperties=!!e,this}getOptionValue(e){return this._storeOptionsAsProperties?this[e]:this._optionValues[e]}setOptionValue(e,r){return this.setOptionValueWithSource(e,r,void 0)}setOptionValueWithSource(e,r,n){return this._storeOptionsAsProperties?this[e]=r:this._optionValues[e]=r,this._optionValueSources[e]=n,this}getOptionValueSource(e){return this._optionValueSources[e]}getOptionValueSourceWithGlobals(e){let r;return this._getCommandAndAncestors().forEach(n=>{n.getOptionValueSource(e)!==void 0&&(r=n.getOptionValueSource(e))}),r}_prepareUserArgs(e,r){if(e!==void 0&&!Array.isArray(e))throw new Error("first parameter to parse must be array or undefined");if(r=r||{},e===void 0&&r.from===void 0){ie.versions?.electron&&(r.from="electron");let i=ie.execArgv??[];(i.includes("-e")||i.includes("--eval")||i.includes("-p")||i.includes("--print"))&&(r.from="eval")}e===void 0&&(e=ie.argv),this.rawArgs=e.slice();let n;switch(r.from){case void 0:case"node":this._scriptPath=e[1],n=e.slice(2);break;case"electron":ie.defaultApp?(this._scriptPath=e[1],n=e.slice(2)):n=e.slice(1);break;case"user":n=e.slice(0);break;case"eval":n=e.slice(1);break;default:throw new Error(`unexpected parse option { from: '${r.from}' }`)}return!this._name&&this._scriptPath&&this.nameFromFilename(this._scriptPath),this._name=this._name||"program",n}parse(e,r){this._prepareForParse();let n=this._prepareUserArgs(e,r);return this._parseCommand([],n),this}async parseAsync(e,r){this._prepareForParse();let n=this._prepareUserArgs(e,r);return await this._parseCommand([],n),this}_prepareForParse(){this._savedState===null?this.saveStateBeforeParse():this.restoreStateBeforeParse()}saveStateBeforeParse(){this._savedState={_name:this._name,_optionValues:{...this._optionValues},_optionValueSources:{...this._optionValueSources}}}restoreStateBeforeParse(){if(this._storeOptionsAsProperties)throw new Error(`Can not call parse again when storeOptionsAsProperties is true.
|
|
20
|
+
- either make a new Command for each call to parse, or stop storing options as properties`);this._name=this._savedState._name,this._scriptPath=null,this.rawArgs=[],this._optionValues={...this._savedState._optionValues},this._optionValueSources={...this._savedState._optionValueSources},this.args=[],this.processedArgs=[]}_checkForMissingExecutable(e,r,n){if(ki.existsSync(e))return;let i=r?`searched for local subcommand relative to directory '${r}'`:"no directory for search for local subcommand, use .executableDir() to supply a custom directory",o=`'${e}' does not exist
|
|
21
21
|
- if '${n}' is not meant to be an executable command, remove description parameter from '.command()' and use '.description()' instead
|
|
22
22
|
- if the default executable name is not suitable, use the executableFile option to supply a custom name or path
|
|
23
|
-
- ${i}`;throw new Error(
|
|
23
|
+
- ${i}`;throw new Error(o)}_executeSubCommand(e,r){r=r.slice();let n=!1,i=[".js",".ts",".tsx",".mjs",".cjs"];function o(p,f){let h=xt.resolve(p,f);if(ki.existsSync(h))return h;if(i.includes(xt.extname(f)))return;let m=i.find(g=>ki.existsSync(`${h}${g}`));if(m)return`${h}${m}`}this._checkForMissingMandatoryOptions(),this._checkForConflictingOptions();let s=e._executableFile||`${this._name}-${e._name}`,a=this._executableDir||"";if(this._scriptPath){let p;try{p=ki.realpathSync(this._scriptPath)}catch{p=this._scriptPath}a=xt.resolve(xt.dirname(p),a)}if(a){let p=o(a,s);if(!p&&!e._executableFile&&this._scriptPath){let f=xt.basename(this._scriptPath,xt.extname(this._scriptPath));f!==this._name&&(p=o(a,`${f}-${e._name}`))}s=p||s}n=i.includes(xt.extname(s));let l;ie.platform!=="win32"?n?(r.unshift(s),r=gu(ie.execArgv).concat(r),l=As.spawn(ie.argv[0],r,{stdio:"inherit"})):l=As.spawn(s,r,{stdio:"inherit"}):(this._checkForMissingExecutable(s,a,e._name),r.unshift(s),r=gu(ie.execArgv).concat(r),l=As.spawn(ie.execPath,r,{stdio:"inherit"})),l.killed||["SIGUSR1","SIGUSR2","SIGTERM","SIGINT","SIGHUP"].forEach(f=>{ie.on(f,()=>{l.killed===!1&&l.exitCode===null&&l.kill(f)})});let u=this._exitCallback;l.on("close",p=>{p=p??1,u?u(new Os(p,"commander.executeSubCommandAsync","(close)")):ie.exit(p)}),l.on("error",p=>{if(p.code==="ENOENT")this._checkForMissingExecutable(s,a,e._name);else if(p.code==="EACCES")throw new Error(`'${s}' not executable`);if(!u)ie.exit(1);else{let f=new Os(1,"commander.executeSubCommandAsync","(error)");f.nestedError=p,u(f)}}),this.runningCommand=l}_dispatchSubcommand(e,r,n){let i=this._findCommand(e);i||this.help({error:!0}),i._prepareForParse();let o;return o=this._chainOrCallSubCommandHook(o,i,"preSubcommand"),o=this._chainOrCall(o,()=>{if(i._executableHandler)this._executeSubCommand(i,r.concat(n));else return i._parseCommand(r,n)}),o}_dispatchHelpCommand(e){e||this.help();let r=this._findCommand(e);return r&&!r._executableHandler&&r.help(),this._dispatchSubcommand(e,[],[this._getHelpOption()?.long??this._getHelpOption()?.short??"--help"])}_checkNumberOfArguments(){this.registeredArguments.forEach((e,r)=>{e.required&&this.args[r]==null&&this.missingArgument(e.name())}),!(this.registeredArguments.length>0&&this.registeredArguments[this.registeredArguments.length-1].variadic)&&this.args.length>this.registeredArguments.length&&this._excessArguments(this.args)}_processArguments(){let e=(n,i,o)=>{let s=i;if(i!==null&&n.parseArg){let a=`error: command-argument value '${i}' is invalid for argument '${n.name()}'.`;s=this._callParseArg(n,i,o,a)}return s};this._checkNumberOfArguments();let r=[];this.registeredArguments.forEach((n,i)=>{let o=n.defaultValue;n.variadic?i<this.args.length?(o=this.args.slice(i),n.parseArg&&(o=o.reduce((s,a)=>e(n,a,s),n.defaultValue))):o===void 0&&(o=[]):i<this.args.length&&(o=this.args[i],n.parseArg&&(o=e(n,o,n.defaultValue))),r[i]=o}),this.processedArgs=r}_chainOrCall(e,r){return e?.then&&typeof e.then=="function"?e.then(()=>r()):r()}_chainOrCallHooks(e,r){let n=e,i=[];return this._getCommandAndAncestors().reverse().filter(o=>o._lifeCycleHooks[r]!==void 0).forEach(o=>{o._lifeCycleHooks[r].forEach(s=>{i.push({hookedCommand:o,callback:s})})}),r==="postAction"&&i.reverse(),i.forEach(o=>{n=this._chainOrCall(n,()=>o.callback(o.hookedCommand,this))}),n}_chainOrCallSubCommandHook(e,r,n){let i=e;return this._lifeCycleHooks[n]!==void 0&&this._lifeCycleHooks[n].forEach(o=>{i=this._chainOrCall(i,()=>o(this,r))}),i}_parseCommand(e,r){let n=this.parseOptions(r);if(this._parseOptionsEnv(),this._parseOptionsImplied(),e=e.concat(n.operands),r=n.unknown,this.args=e.concat(r),e&&this._findCommand(e[0]))return this._dispatchSubcommand(e[0],e.slice(1),r);if(this._getHelpCommand()&&e[0]===this._getHelpCommand().name())return this._dispatchHelpCommand(e[1]);if(this._defaultCommandName)return this._outputHelpIfRequested(r),this._dispatchSubcommand(this._defaultCommandName,e,r);this.commands.length&&this.args.length===0&&!this._actionHandler&&!this._defaultCommandName&&this.help({error:!0}),this._outputHelpIfRequested(n.unknown),this._checkForMissingMandatoryOptions(),this._checkForConflictingOptions();let i=()=>{n.unknown.length>0&&this.unknownOption(n.unknown[0])},o=`command:${this.name()}`;if(this._actionHandler){i(),this._processArguments();let s;return s=this._chainOrCallHooks(s,"preAction"),s=this._chainOrCall(s,()=>this._actionHandler(this.processedArgs)),this.parent&&(s=this._chainOrCall(s,()=>{this.parent.emit(o,e,r)})),s=this._chainOrCallHooks(s,"postAction"),s}if(this.parent?.listenerCount(o))i(),this._processArguments(),this.parent.emit(o,e,r);else if(e.length){if(this._findCommand("*"))return this._dispatchSubcommand("*",e,r);this.listenerCount("command:*")?this.emit("command:*",e,r):this.commands.length?this.unknownCommand():(i(),this._processArguments())}else this.commands.length?(i(),this.help({error:!0})):(i(),this._processArguments())}_findCommand(e){if(e)return this.commands.find(r=>r._name===e||r._aliases.includes(e))}_findOption(e){return this.options.find(r=>r.is(e))}_checkForMissingMandatoryOptions(){this._getCommandAndAncestors().forEach(e=>{e.options.forEach(r=>{r.mandatory&&e.getOptionValue(r.attributeName())===void 0&&e.missingMandatoryOptionValue(r)})})}_checkForConflictingLocalOptions(){let e=this.options.filter(n=>{let i=n.attributeName();return this.getOptionValue(i)===void 0?!1:this.getOptionValueSource(i)!=="default"});e.filter(n=>n.conflictsWith.length>0).forEach(n=>{let i=e.find(o=>n.conflictsWith.includes(o.attributeName()));i&&this._conflictingOption(n,i)})}_checkForConflictingOptions(){this._getCommandAndAncestors().forEach(e=>{e._checkForConflictingLocalOptions()})}parseOptions(e){let r=[],n=[],i=r;function o(p){return p.length>1&&p[0]==="-"}let s=p=>/^-(\d+|\d*\.\d+)(e[+-]?\d+)?$/.test(p)?!this._getCommandAndAncestors().some(f=>f.options.map(h=>h.short).some(h=>/^-\d$/.test(h))):!1,a=null,l=null,u=0;for(;u<e.length||l;){let p=l??e[u++];if(l=null,p==="--"){i===n&&i.push(p),i.push(...e.slice(u));break}if(a&&(!o(p)||s(p))){this.emit(`option:${a.name()}`,p);continue}if(a=null,o(p)){let f=this._findOption(p);if(f){if(f.required){let h=e[u++];h===void 0&&this.optionMissingArgument(f),this.emit(`option:${f.name()}`,h)}else if(f.optional){let h=null;u<e.length&&(!o(e[u])||s(e[u]))&&(h=e[u++]),this.emit(`option:${f.name()}`,h)}else this.emit(`option:${f.name()}`);a=f.variadic?f:null;continue}}if(p.length>2&&p[0]==="-"&&p[1]!=="-"){let f=this._findOption(`-${p[1]}`);if(f){f.required||f.optional&&this._combineFlagAndOptionalValue?this.emit(`option:${f.name()}`,p.slice(2)):(this.emit(`option:${f.name()}`),l=`-${p.slice(2)}`);continue}}if(/^--[^=]+=/.test(p)){let f=p.indexOf("="),h=this._findOption(p.slice(0,f));if(h&&(h.required||h.optional)){this.emit(`option:${h.name()}`,p.slice(f+1));continue}}if(i===r&&o(p)&&!(this.commands.length===0&&s(p))&&(i=n),(this._enablePositionalOptions||this._passThroughOptions)&&r.length===0&&n.length===0){if(this._findCommand(p)){r.push(p),n.push(...e.slice(u));break}else if(this._getHelpCommand()&&p===this._getHelpCommand().name()){r.push(p,...e.slice(u));break}else if(this._defaultCommandName){n.push(p,...e.slice(u));break}}if(this._passThroughOptions){i.push(p,...e.slice(u));break}i.push(p)}return{operands:r,unknown:n}}opts(){if(this._storeOptionsAsProperties){let e={},r=this.options.length;for(let n=0;n<r;n++){let i=this.options[n].attributeName();e[i]=i===this._versionOptionName?this._version:this[i]}return e}return this._optionValues}optsWithGlobals(){return this._getCommandAndAncestors().reduce((e,r)=>Object.assign(e,r.opts()),{})}error(e,r){this._outputConfiguration.outputError(`${e}
|
|
24
24
|
`,this._outputConfiguration.writeErr),typeof this._showHelpAfterError=="string"?this._outputConfiguration.writeErr(`${this._showHelpAfterError}
|
|
25
25
|
`):this._showHelpAfterError&&(this._outputConfiguration.writeErr(`
|
|
26
|
-
`),this.outputHelp({error:!0}));let n=r||{},i=n.exitCode||1,
|
|
27
|
-
`),this._exit(0,"commander.version",e)}),this}description(e,r){return e===void 0&&r===void 0?this._description:(this._description=e,r&&(this._argsDescription=r),this)}summary(e){return e===void 0?this._summary:(this._summary=e,this)}alias(e){if(e===void 0)return this._aliases[0];let r=this;if(this.commands.length!==0&&this.commands[this.commands.length-1]._executableHandler&&(r=this.commands[this.commands.length-1]),e===r._name)throw new Error("Command alias can't be the same as its name");let n=this.parent?._findCommand(e);if(n){let i=[n.name()].concat(n.aliases()).join("|");throw new Error(`cannot add alias '${e}' to command '${this.name()}' as already have command '${i}'`)}return r._aliases.push(e),this}aliases(e){return e===void 0?this._aliases:(e.forEach(r=>this.alias(r)),this)}usage(e){if(e===void 0){if(this._usage)return this._usage;let r=this.registeredArguments.map(n=>
|
|
28
|
-
Expecting one of '${n.join("', '")}'`);let i=`${e}Help`;return this.on(i,
|
|
29
|
-
`)}),this}_outputHelpIfRequested(e){let r=this._getHelpOption();r&&e.find(i=>r.is(i))&&(this.outputHelp(),this._exit(0,"commander.helpDisplayed","(outputHelp)"))}};function Wl(t){return t.map(e=>{if(!e.startsWith("--inspect"))return e;let r,n="127.0.0.1",i="9229",s;return(s=e.match(/^(--inspect(-brk)?)$/))!==null?r=s[1]:(s=e.match(/^(--inspect(-brk|-port)?)=([^:]+)$/))!==null?(r=s[1],/^\d+$/.test(s[3])?i=s[3]:n=s[3]):(s=e.match(/^(--inspect(-brk|-port)?)=([^:]+):(\d+)$/))!==null&&(r=s[1],n=s[3],i=s[4]),r&&i!=="0"?`${r}=${n}:${parseInt(i)+1}`:e})}function wo(){if(ie.env.NO_COLOR||ie.env.FORCE_COLOR==="0"||ie.env.FORCE_COLOR==="false")return!1;if(ie.env.FORCE_COLOR||ie.env.CLICOLOR_FORCE!==void 0)return!0}bo.Command=_o;bo.useColor=wo});var Ql=w(Ge=>{var{Argument:Jl}=wi(),{Command:So}=Kl(),{CommanderError:zg,InvalidArgumentError:Yl}=on(),{Help:Wg}=fo(),{Option:Xl}=go();Ge.program=new So;Ge.createCommand=t=>new So(t);Ge.createOption=(t,e)=>new Xl(t,e);Ge.createArgument=(t,e)=>new Jl(t,e);Ge.Command=So;Ge.Option=Xl;Ge.Argument=Jl;Ge.Help=Wg;Ge.CommanderError=zg;Ge.InvalidArgumentError=Yl;Ge.InvalidOptionArgumentError=Yl});var pn=w(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.regexpCode=re.getEsmExportName=re.getProperty=re.safeStringify=re.stringify=re.strConcat=re.addCodeArg=re.str=re._=re.nil=re._Code=re.Name=re.IDENTIFIER=re._CodeOrName=void 0;var fn=class{};re._CodeOrName=fn;re.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Yt=class extends fn{constructor(e){if(super(),!re.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};re.Name=Yt;var ze=class extends fn{constructor(e){super(),this._items=typeof e=="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((r,n)=>`${r}${n}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((r,n)=>(n instanceof Yt&&(r[n.str]=(r[n.str]||0)+1),r),{})}};re._Code=ze;re.nil=new ze("");function ju(t,...e){let r=[t[0]],n=0;for(;n<e.length;)Oo(r,e[n]),r.push(t[++n]);return new ze(r)}re._=ju;var Po=new ze("+");function Du(t,...e){let r=[dn(t[0])],n=0;for(;n<e.length;)r.push(Po),Oo(r,e[n]),r.push(Po,dn(t[++n]));return Py(r),new ze(r)}re.str=Du;function Oo(t,e){e instanceof ze?t.push(...e._items):e instanceof Yt?t.push(e):t.push(Ry(e))}re.addCodeArg=Oo;function Py(t){let e=1;for(;e<t.length-1;){if(t[e]===Po){let r=Oy(t[e-1],t[e+1]);if(r!==void 0){t.splice(e-1,3,r);continue}t[e++]="+"}e++}}function Oy(t,e){if(e==='""')return t;if(t==='""')return e;if(typeof t=="string")return e instanceof Yt||t[t.length-1]!=='"'?void 0:typeof e!="string"?`${t.slice(0,-1)}${e}"`:e[0]==='"'?t.slice(0,-1)+e.slice(1):void 0;if(typeof e=="string"&&e[0]==='"'&&!(t instanceof Yt))return`"${t}${e.slice(1)}`}function Ay(t,e){return e.emptyStr()?t:t.emptyStr()?e:Du`${t}${e}`}re.strConcat=Ay;function Ry(t){return typeof t=="number"||typeof t=="boolean"||t===null?t:dn(Array.isArray(t)?t.join(","):t)}function Iy(t){return new ze(dn(t))}re.stringify=Iy;function dn(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}re.safeStringify=dn;function Ty(t){return typeof t=="string"&&re.IDENTIFIER.test(t)?new ze(`.${t}`):ju`[${t}]`}re.getProperty=Ty;function Ny(t){if(typeof t=="string"&&re.IDENTIFIER.test(t))return new ze(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)}re.getEsmExportName=Ny;function My(t){return new ze(t.toString())}re.regexpCode=My});var Io=w(Le=>{"use strict";Object.defineProperty(Le,"__esModule",{value:!0});Le.ValueScope=Le.ValueScopeName=Le.Scope=Le.varKinds=Le.UsedValueState=void 0;var Me=pn(),Ao=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}},Ci;(function(t){t[t.Started=0]="Started",t[t.Completed=1]="Completed"})(Ci||(Le.UsedValueState=Ci={}));Le.varKinds={const:new Me.Name("const"),let:new Me.Name("let"),var:new Me.Name("var")};var ki=class{constructor({prefixes:e,parent:r}={}){this._names={},this._prefixes=e,this._parent=r}toName(e){return e instanceof Me.Name?e:this.name(e)}name(e){return new Me.Name(this._newName(e))}_newName(e){let r=this._names[e]||this._nameGroup(e);return`${e}${r.index++}`}_nameGroup(e){var r,n;if(!((n=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||n===void 0)&&n.has(e)||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}};Le.Scope=ki;var xi=class extends Me.Name{constructor(e,r){super(r),this.prefix=e}setValue(e,{property:r,itemIndex:n}){this.value=e,this.scopePath=(0,Me._)`.${new Me.Name(r)}[${n}]`}};Le.ValueScopeName=xi;var Ly=(0,Me._)`\n`,Ro=class extends ki{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?Ly:Me.nil}}get(){return this._scope}name(e){return new xi(e,this._newName(e))}value(e,r){var n;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let i=this.toName(e),{prefix:s}=i,o=(n=r.key)!==null&&n!==void 0?n:r.ref,a=this._values[s];if(a){let d=a.get(o);if(d)return d}else a=this._values[s]=new Map;a.set(o,i);let l=this._scope[s]||(this._scope[s]=[]),u=l.length;return l[u]=r.ref,i.setValue(r,{property:s,itemIndex:u}),i}getValue(e,r){let n=this._values[e];if(n)return n.get(r)}scopeRefs(e,r=this._values){return this._reduceValues(r,n=>{if(n.scopePath===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return(0,Me._)`${e}${n.scopePath}`})}scopeCode(e=this._values,r,n){return this._reduceValues(e,i=>{if(i.value===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return i.value.code},r,n)}_reduceValues(e,r,n={},i){let s=Me.nil;for(let o in e){let a=e[o];if(!a)continue;let l=n[o]=n[o]||new Map;a.forEach(u=>{if(l.has(u))return;l.set(u,Ci.Started);let d=r(u);if(d){let f=this.opts.es5?Le.varKinds.var:Le.varKinds.const;s=(0,Me._)`${s}${f} ${u} = ${d};${this.opts._n}`}else if(d=i?.(u))s=(0,Me._)`${s}${d}${this.opts._n}`;else throw new Ao(u);l.set(u,Ci.Completed)})}return s}};Le.ValueScope=Ro});var W=w(J=>{"use strict";Object.defineProperty(J,"__esModule",{value:!0});J.or=J.and=J.not=J.CodeGen=J.operators=J.varKinds=J.ValueScopeName=J.ValueScope=J.Scope=J.Name=J.regexpCode=J.stringify=J.getProperty=J.nil=J.strConcat=J.str=J._=void 0;var ee=pn(),at=Io(),jt=pn();Object.defineProperty(J,"_",{enumerable:!0,get:function(){return jt._}});Object.defineProperty(J,"str",{enumerable:!0,get:function(){return jt.str}});Object.defineProperty(J,"strConcat",{enumerable:!0,get:function(){return jt.strConcat}});Object.defineProperty(J,"nil",{enumerable:!0,get:function(){return jt.nil}});Object.defineProperty(J,"getProperty",{enumerable:!0,get:function(){return jt.getProperty}});Object.defineProperty(J,"stringify",{enumerable:!0,get:function(){return jt.stringify}});Object.defineProperty(J,"regexpCode",{enumerable:!0,get:function(){return jt.regexpCode}});Object.defineProperty(J,"Name",{enumerable:!0,get:function(){return jt.Name}});var Ri=Io();Object.defineProperty(J,"Scope",{enumerable:!0,get:function(){return Ri.Scope}});Object.defineProperty(J,"ValueScope",{enumerable:!0,get:function(){return Ri.ValueScope}});Object.defineProperty(J,"ValueScopeName",{enumerable:!0,get:function(){return Ri.ValueScopeName}});Object.defineProperty(J,"varKinds",{enumerable:!0,get:function(){return Ri.varKinds}});J.operators={GT:new ee._Code(">"),GTE:new ee._Code(">="),LT:new ee._Code("<"),LTE:new ee._Code("<="),EQ:new ee._Code("==="),NEQ:new ee._Code("!=="),NOT:new ee._Code("!"),OR:new ee._Code("||"),AND:new ee._Code("&&"),ADD:new ee._Code("+")};var Ot=class{optimizeNodes(){return this}optimizeNames(e,r){return this}},To=class extends Ot{constructor(e,r,n){super(),this.varKind=e,this.name=r,this.rhs=n}render({es5:e,_n:r}){let n=e?at.varKinds.var:this.varKind,i=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${i};`+r}optimizeNames(e,r){if(e[this.name.str])return this.rhs&&(this.rhs=Sr(this.rhs,e,r)),this}get names(){return this.rhs instanceof ee._CodeOrName?this.rhs.names:{}}},Pi=class extends Ot{constructor(e,r,n){super(),this.lhs=e,this.rhs=r,this.sideEffects=n}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,r){if(!(this.lhs instanceof ee.Name&&!e[this.lhs.str]&&!this.sideEffects))return this.rhs=Sr(this.rhs,e,r),this}get names(){let e=this.lhs instanceof ee.Name?{}:{...this.lhs.names};return Ai(e,this.rhs)}},No=class extends Pi{constructor(e,r,n,i){super(e,n,i),this.op=r}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},Mo=class extends Ot{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},Lo=class extends Ot{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},jo=class extends Ot{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},Do=class extends Ot{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,r){return this.code=Sr(this.code,e,r),this}get names(){return this.code instanceof ee._CodeOrName?this.code.names:{}}},hn=class extends Ot{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((r,n)=>r+n.render(e),"")}optimizeNodes(){let{nodes:e}=this,r=e.length;for(;r--;){let n=e[r].optimizeNodes();Array.isArray(n)?e.splice(r,1,...n):n?e[r]=n:e.splice(r,1)}return e.length>0?this:void 0}optimizeNames(e,r){let{nodes:n}=this,i=n.length;for(;i--;){let s=n[i];s.optimizeNames(e,r)||(jy(e,s.names),n.splice(i,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,r)=>Zt(e,r.names),{})}},At=class extends hn{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},qo=class extends hn{},br=class extends At{};br.kind="else";var Xt=class t extends At{constructor(e,r){super(r),this.condition=e}render(e){let r=`if(${this.condition})`+super.render(e);return this.else&&(r+="else "+this.else.render(e)),r}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let r=this.else;if(r){let n=r.optimizeNodes();r=this.else=Array.isArray(n)?new br(n):n}if(r)return e===!1?r instanceof t?r:r.nodes:this.nodes.length?this:new t(qu(e),r instanceof t?[r]:r.nodes);if(!(e===!1||!this.nodes.length))return this}optimizeNames(e,r){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(e,r),!!(super.optimizeNames(e,r)||this.else))return this.condition=Sr(this.condition,e,r),this}get names(){let e=super.names;return Ai(e,this.condition),this.else&&Zt(e,this.else.names),e}};Xt.kind="if";var Qt=class extends At{};Qt.kind="for";var Vo=class extends Qt{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,r){if(super.optimizeNames(e,r))return this.iteration=Sr(this.iteration,e,r),this}get names(){return Zt(super.names,this.iteration.names)}},Fo=class extends Qt{constructor(e,r,n,i){super(),this.varKind=e,this.name=r,this.from=n,this.to=i}render(e){let r=e.es5?at.varKinds.var:this.varKind,{name:n,from:i,to:s}=this;return`for(${r} ${n}=${i}; ${n}<${s}; ${n}++)`+super.render(e)}get names(){let e=Ai(super.names,this.from);return Ai(e,this.to)}},Oi=class extends Qt{constructor(e,r,n,i){super(),this.loop=e,this.varKind=r,this.name=n,this.iterable=i}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,r){if(super.optimizeNames(e,r))return this.iterable=Sr(this.iterable,e,r),this}get names(){return Zt(super.names,this.iterable.names)}},mn=class extends At{constructor(e,r,n){super(),this.name=e,this.args=r,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}};mn.kind="func";var gn=class extends hn{render(e){return"return "+super.render(e)}};gn.kind="return";var Ho=class extends At{render(e){let r="try"+super.render(e);return this.catch&&(r+=this.catch.render(e)),this.finally&&(r+=this.finally.render(e)),r}optimizeNodes(){var e,r;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(e,r){var n,i;return super.optimizeNames(e,r),(n=this.catch)===null||n===void 0||n.optimizeNames(e,r),(i=this.finally)===null||i===void 0||i.optimizeNames(e,r),this}get names(){let e=super.names;return this.catch&&Zt(e,this.catch.names),this.finally&&Zt(e,this.finally.names),e}},yn=class extends At{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}};yn.kind="catch";var vn=class extends At{render(e){return"finally"+super.render(e)}};vn.kind="finally";var Bo=class{constructor(e,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
|
|
30
|
-
`:""},this._extScope=e,this._scope=new at.Scope({parent:e}),this._nodes=[new qo]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,r){let n=this._extScope.value(e,r);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,r){return this._extScope.getValue(e,r)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,r,n,i){let s=this._scope.toName(r);return n!==void 0&&i&&(this._constants[s.str]=n),this._leafNode(new To(e,s,n)),s}const(e,r,n){return this._def(at.varKinds.const,e,r,n)}let(e,r,n){return this._def(at.varKinds.let,e,r,n)}var(e,r,n){return this._def(at.varKinds.var,e,r,n)}assign(e,r,n){return this._leafNode(new Pi(e,r,n))}add(e,r){return this._leafNode(new No(e,J.operators.ADD,r))}code(e){return typeof e=="function"?e():e!==ee.nil&&this._leafNode(new Do(e)),this}object(...e){let r=["{"];for(let[n,i]of e)r.length>1&&r.push(","),r.push(n),(n!==i||this.opts.es5)&&(r.push(":"),(0,ee.addCodeArg)(r,i));return r.push("}"),new ee._Code(r)}if(e,r,n){if(this._blockNode(new Xt(e)),r&&n)this.code(r).else().code(n).endIf();else if(r)this.code(r).endIf();else if(n)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new Xt(e))}else(){return this._elseNode(new br)}endIf(){return this._endBlockNode(Xt,br)}_for(e,r){return this._blockNode(e),r&&this.code(r).endFor(),this}for(e,r){return this._for(new Vo(e),r)}forRange(e,r,n,i,s=this.opts.es5?at.varKinds.var:at.varKinds.let){let o=this._scope.toName(e);return this._for(new Fo(s,o,r,n),()=>i(o))}forOf(e,r,n,i=at.varKinds.const){let s=this._scope.toName(e);if(this.opts.es5){let o=r instanceof ee.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,ee._)`${o}.length`,a=>{this.var(s,(0,ee._)`${o}[${a}]`),n(s)})}return this._for(new Oi("of",i,s,r),()=>n(s))}forIn(e,r,n,i=this.opts.es5?at.varKinds.var:at.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,ee._)`Object.keys(${r})`,n);let s=this._scope.toName(e);return this._for(new Oi("in",i,s,r),()=>n(s))}endFor(){return this._endBlockNode(Qt)}label(e){return this._leafNode(new Mo(e))}break(e){return this._leafNode(new Lo(e))}return(e){let r=new gn;if(this._blockNode(r),this.code(e),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(gn)}try(e,r,n){if(!r&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');let i=new Ho;if(this._blockNode(i),this.code(e),r){let s=this.name("e");this._currNode=i.catch=new yn(s),r(s)}return n&&(this._currNode=i.finally=new vn,this.code(n)),this._endBlockNode(yn,vn)}throw(e){return this._leafNode(new jo(e))}block(e,r){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(r),this}endBlock(e){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let n=this._nodes.length-r;if(n<0||e!==void 0&&n!==e)throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=r,this}func(e,r=ee.nil,n,i){return this._blockNode(new mn(e,r,n)),i&&this.code(i).endFunc(),this}endFunc(){return this._endBlockNode(mn)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,r){let n=this._currNode;if(n instanceof e||r&&n instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${e.kind}/${r.kind}`:e.kind}"`)}_elseNode(e){let r=this._currNode;if(!(r instanceof Xt))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let r=this._nodes;r[r.length-1]=e}};J.CodeGen=Bo;function Zt(t,e){for(let r in e)t[r]=(t[r]||0)+(e[r]||0);return t}function Ai(t,e){return e instanceof ee._CodeOrName?Zt(t,e.names):t}function Sr(t,e,r){if(t instanceof ee.Name)return n(t);if(!i(t))return t;return new ee._Code(t._items.reduce((s,o)=>(o instanceof ee.Name&&(o=n(o)),o instanceof ee._Code?s.push(...o._items):s.push(o),s),[]));function n(s){let o=r[s.str];return o===void 0||e[s.str]!==1?s:(delete e[s.str],o)}function i(s){return s instanceof ee._Code&&s._items.some(o=>o instanceof ee.Name&&e[o.str]===1&&r[o.str]!==void 0)}}function jy(t,e){for(let r in e)t[r]=(t[r]||0)-(e[r]||0)}function qu(t){return typeof t=="boolean"||typeof t=="number"||t===null?!t:(0,ee._)`!${Uo(t)}`}J.not=qu;var Dy=Vu(J.operators.AND);function qy(...t){return t.reduce(Dy)}J.and=qy;var Vy=Vu(J.operators.OR);function Fy(...t){return t.reduce(Vy)}J.or=Fy;function Vu(t){return(e,r)=>e===ee.nil?r:r===ee.nil?e:(0,ee._)`${Uo(e)} ${t} ${Uo(r)}`}function Uo(t){return t instanceof ee.Name?t:(0,ee._)`(${t})`}});var X=w(Y=>{"use strict";Object.defineProperty(Y,"__esModule",{value:!0});Y.checkStrictMode=Y.getErrorPath=Y.Type=Y.useFunc=Y.setEvaluated=Y.evaluatedPropsToName=Y.mergeEvaluated=Y.eachItem=Y.unescapeJsonPointer=Y.escapeJsonPointer=Y.escapeFragment=Y.unescapeFragment=Y.schemaRefOrVal=Y.schemaHasRulesButRef=Y.schemaHasRules=Y.checkUnknownRules=Y.alwaysValidSchema=Y.toHash=void 0;var ae=W(),Hy=pn();function By(t){let e={};for(let r of t)e[r]=!0;return e}Y.toHash=By;function Uy(t,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(Bu(t,e),!Uu(e,t.self.RULES.all))}Y.alwaysValidSchema=Uy;function Bu(t,e=t.schema){let{opts:r,self:n}=t;if(!r.strictSchema||typeof e=="boolean")return;let i=n.RULES.keywords;for(let s in e)i[s]||Wu(t,`unknown keyword: "${s}"`)}Y.checkUnknownRules=Bu;function Uu(t,e){if(typeof t=="boolean")return!t;for(let r in t)if(e[r])return!0;return!1}Y.schemaHasRules=Uu;function Gy(t,e){if(typeof t=="boolean")return!t;for(let r in t)if(r!=="$ref"&&e.all[r])return!0;return!1}Y.schemaHasRulesButRef=Gy;function zy({topSchemaRef:t,schemaPath:e},r,n,i){if(!i){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,ae._)`${r}`}return(0,ae._)`${t}${e}${(0,ae.getProperty)(n)}`}Y.schemaRefOrVal=zy;function Wy(t){return Gu(decodeURIComponent(t))}Y.unescapeFragment=Wy;function Ky(t){return encodeURIComponent(zo(t))}Y.escapeFragment=Ky;function zo(t){return typeof t=="number"?`${t}`:t.replace(/~/g,"~0").replace(/\//g,"~1")}Y.escapeJsonPointer=zo;function Gu(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}Y.unescapeJsonPointer=Gu;function Jy(t,e){if(Array.isArray(t))for(let r of t)e(r);else e(t)}Y.eachItem=Jy;function Fu({mergeNames:t,mergeToName:e,mergeValues:r,resultToName:n}){return(i,s,o,a)=>{let l=o===void 0?s:o instanceof ae.Name?(s instanceof ae.Name?t(i,s,o):e(i,s,o),o):s instanceof ae.Name?(e(i,o,s),s):r(s,o);return a===ae.Name&&!(l instanceof ae.Name)?n(i,l):l}}Y.mergeEvaluated={props:Fu({mergeNames:(t,e,r)=>t.if((0,ae._)`${r} !== true && ${e} !== undefined`,()=>{t.if((0,ae._)`${e} === true`,()=>t.assign(r,!0),()=>t.assign(r,(0,ae._)`${r} || {}`).code((0,ae._)`Object.assign(${r}, ${e})`))}),mergeToName:(t,e,r)=>t.if((0,ae._)`${r} !== true`,()=>{e===!0?t.assign(r,!0):(t.assign(r,(0,ae._)`${r} || {}`),Wo(t,r,e))}),mergeValues:(t,e)=>t===!0?!0:{...t,...e},resultToName:zu}),items:Fu({mergeNames:(t,e,r)=>t.if((0,ae._)`${r} !== true && ${e} !== undefined`,()=>t.assign(r,(0,ae._)`${e} === true ? true : ${r} > ${e} ? ${r} : ${e}`)),mergeToName:(t,e,r)=>t.if((0,ae._)`${r} !== true`,()=>t.assign(r,e===!0?!0:(0,ae._)`${r} > ${e} ? ${r} : ${e}`)),mergeValues:(t,e)=>t===!0?!0:Math.max(t,e),resultToName:(t,e)=>t.var("items",e)})};function zu(t,e){if(e===!0)return t.var("props",!0);let r=t.var("props",(0,ae._)`{}`);return e!==void 0&&Wo(t,r,e),r}Y.evaluatedPropsToName=zu;function Wo(t,e,r){Object.keys(r).forEach(n=>t.assign((0,ae._)`${e}${(0,ae.getProperty)(n)}`,!0))}Y.setEvaluated=Wo;var Hu={};function Yy(t,e){return t.scopeValue("func",{ref:e,code:Hu[e.code]||(Hu[e.code]=new Hy._Code(e.code))})}Y.useFunc=Yy;var Go;(function(t){t[t.Num=0]="Num",t[t.Str=1]="Str"})(Go||(Y.Type=Go={}));function Xy(t,e,r){if(t instanceof ae.Name){let n=e===Go.Num;return r?n?(0,ae._)`"[" + ${t} + "]"`:(0,ae._)`"['" + ${t} + "']"`:n?(0,ae._)`"/" + ${t}`:(0,ae._)`"/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,ae.getProperty)(t).toString():"/"+zo(t)}Y.getErrorPath=Xy;function Wu(t,e,r=t.opts.strictSchema){if(r){if(e=`strict mode: ${e}`,r===!0)throw new Error(e);t.self.logger.warn(e)}}Y.checkStrictMode=Wu});var We=w(Ko=>{"use strict";Object.defineProperty(Ko,"__esModule",{value:!0});var Ce=W(),Qy={data:new Ce.Name("data"),valCxt:new Ce.Name("valCxt"),instancePath:new Ce.Name("instancePath"),parentData:new Ce.Name("parentData"),parentDataProperty:new Ce.Name("parentDataProperty"),rootData:new Ce.Name("rootData"),dynamicAnchors:new Ce.Name("dynamicAnchors"),vErrors:new Ce.Name("vErrors"),errors:new Ce.Name("errors"),this:new Ce.Name("this"),self:new Ce.Name("self"),scope:new Ce.Name("scope"),json:new Ce.Name("json"),jsonPos:new Ce.Name("jsonPos"),jsonLen:new Ce.Name("jsonLen"),jsonPart:new Ce.Name("jsonPart")};Ko.default=Qy});var _n=w(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke.extendErrors=ke.resetErrorsCount=ke.reportExtraError=ke.reportError=ke.keyword$DataError=ke.keywordError=void 0;var te=W(),Ii=X(),Ae=We();ke.keywordError={message:({keyword:t})=>(0,te.str)`must pass "${t}" keyword validation`};ke.keyword$DataError={message:({keyword:t,schemaType:e})=>e?(0,te.str)`"${t}" keyword must be ${e} ($data)`:(0,te.str)`"${t}" keyword is invalid ($data)`};function Zy(t,e=ke.keywordError,r,n){let{it:i}=t,{gen:s,compositeRule:o,allErrors:a}=i,l=Yu(t,e,r);n??(o||a)?Ku(s,l):Ju(i,(0,te._)`[${l}]`)}ke.reportError=Zy;function ev(t,e=ke.keywordError,r){let{it:n}=t,{gen:i,compositeRule:s,allErrors:o}=n,a=Yu(t,e,r);Ku(i,a),s||o||Ju(n,Ae.default.vErrors)}ke.reportExtraError=ev;function tv(t,e){t.assign(Ae.default.errors,e),t.if((0,te._)`${Ae.default.vErrors} !== null`,()=>t.if(e,()=>t.assign((0,te._)`${Ae.default.vErrors}.length`,e),()=>t.assign(Ae.default.vErrors,null)))}ke.resetErrorsCount=tv;function rv({gen:t,keyword:e,schemaValue:r,data:n,errsCount:i,it:s}){if(i===void 0)throw new Error("ajv implementation error");let o=t.name("err");t.forRange("i",i,Ae.default.errors,a=>{t.const(o,(0,te._)`${Ae.default.vErrors}[${a}]`),t.if((0,te._)`${o}.instancePath === undefined`,()=>t.assign((0,te._)`${o}.instancePath`,(0,te.strConcat)(Ae.default.instancePath,s.errorPath))),t.assign((0,te._)`${o}.schemaPath`,(0,te.str)`${s.errSchemaPath}/${e}`),s.opts.verbose&&(t.assign((0,te._)`${o}.schema`,r),t.assign((0,te._)`${o}.data`,n))})}ke.extendErrors=rv;function Ku(t,e){let r=t.const("err",e);t.if((0,te._)`${Ae.default.vErrors} === null`,()=>t.assign(Ae.default.vErrors,(0,te._)`[${r}]`),(0,te._)`${Ae.default.vErrors}.push(${r})`),t.code((0,te._)`${Ae.default.errors}++`)}function Ju(t,e){let{gen:r,validateName:n,schemaEnv:i}=t;i.$async?r.throw((0,te._)`new ${t.ValidationError}(${e})`):(r.assign((0,te._)`${n}.errors`,e),r.return(!1))}var er={keyword:new te.Name("keyword"),schemaPath:new te.Name("schemaPath"),params:new te.Name("params"),propertyName:new te.Name("propertyName"),message:new te.Name("message"),schema:new te.Name("schema"),parentSchema:new te.Name("parentSchema")};function Yu(t,e,r){let{createErrors:n}=t.it;return n===!1?(0,te._)`{}`:nv(t,e,r)}function nv(t,e,r={}){let{gen:n,it:i}=t,s=[iv(i,r),sv(t,r)];return ov(t,e,s),n.object(...s)}function iv({errorPath:t},{instancePath:e}){let r=e?(0,te.str)`${t}${(0,Ii.getErrorPath)(e,Ii.Type.Str)}`:t;return[Ae.default.instancePath,(0,te.strConcat)(Ae.default.instancePath,r)]}function sv({keyword:t,it:{errSchemaPath:e}},{schemaPath:r,parentSchema:n}){let i=n?e:(0,te.str)`${e}/${t}`;return r&&(i=(0,te.str)`${i}${(0,Ii.getErrorPath)(r,Ii.Type.Str)}`),[er.schemaPath,i]}function ov(t,{params:e,message:r},n){let{keyword:i,data:s,schemaValue:o,it:a}=t,{opts:l,propertyName:u,topSchemaRef:d,schemaPath:f}=a;n.push([er.keyword,i],[er.params,typeof e=="function"?e(t):e||(0,te._)`{}`]),l.messages&&n.push([er.message,typeof r=="function"?r(t):r]),l.verbose&&n.push([er.schema,o],[er.parentSchema,(0,te._)`${d}${f}`],[Ae.default.data,s]),u&&n.push([er.propertyName,u])}});var Qu=w(Er=>{"use strict";Object.defineProperty(Er,"__esModule",{value:!0});Er.boolOrEmptySchema=Er.topBoolOrEmptySchema=void 0;var av=_n(),cv=W(),lv=We(),uv={message:"boolean schema is false"};function fv(t){let{gen:e,schema:r,validateName:n}=t;r===!1?Xu(t,!1):typeof r=="object"&&r.$async===!0?e.return(lv.default.data):(e.assign((0,cv._)`${n}.errors`,null),e.return(!0))}Er.topBoolOrEmptySchema=fv;function dv(t,e){let{gen:r,schema:n}=t;n===!1?(r.var(e,!1),Xu(t)):r.var(e,!0)}Er.boolOrEmptySchema=dv;function Xu(t,e){let{gen:r,data:n}=t,i={gen:r,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:t};(0,av.reportError)(i,uv,void 0,e)}});var Jo=w($r=>{"use strict";Object.defineProperty($r,"__esModule",{value:!0});$r.getRules=$r.isJSONType=void 0;var pv=["string","number","integer","boolean","null","object","array"],hv=new Set(pv);function mv(t){return typeof t=="string"&&hv.has(t)}$r.isJSONType=mv;function gv(){let t={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...t,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},t.number,t.string,t.array,t.object],post:{rules:[]},all:{},keywords:{}}}$r.getRules=gv});var Yo=w(Dt=>{"use strict";Object.defineProperty(Dt,"__esModule",{value:!0});Dt.shouldUseRule=Dt.shouldUseGroup=Dt.schemaHasRulesForType=void 0;function yv({schema:t,self:e},r){let n=e.RULES.types[r];return n&&n!==!0&&Zu(t,n)}Dt.schemaHasRulesForType=yv;function Zu(t,e){return e.rules.some(r=>ef(t,r))}Dt.shouldUseGroup=Zu;function ef(t,e){var r;return t[e.keyword]!==void 0||((r=e.definition.implements)===null||r===void 0?void 0:r.some(n=>t[n]!==void 0))}Dt.shouldUseRule=ef});var wn=w(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.reportTypeError=xe.checkDataTypes=xe.checkDataType=xe.coerceAndCheckDataType=xe.getJSONTypes=xe.getSchemaTypes=xe.DataType=void 0;var vv=Jo(),_v=Yo(),wv=_n(),K=W(),tf=X(),Cr;(function(t){t[t.Correct=0]="Correct",t[t.Wrong=1]="Wrong"})(Cr||(xe.DataType=Cr={}));function bv(t){let e=rf(t.type);if(e.includes("null")){if(t.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!e.length&&t.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');t.nullable===!0&&e.push("null")}return e}xe.getSchemaTypes=bv;function rf(t){let e=Array.isArray(t)?t:t?[t]:[];if(e.every(vv.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}xe.getJSONTypes=rf;function Sv(t,e){let{gen:r,data:n,opts:i}=t,s=Ev(e,i.coerceTypes),o=e.length>0&&!(s.length===0&&e.length===1&&(0,_v.schemaHasRulesForType)(t,e[0]));if(o){let a=Qo(e,n,i.strictNumbers,Cr.Wrong);r.if(a,()=>{s.length?$v(t,e,s):Zo(t)})}return o}xe.coerceAndCheckDataType=Sv;var nf=new Set(["string","number","integer","boolean","null"]);function Ev(t,e){return e?t.filter(r=>nf.has(r)||e==="array"&&r==="array"):[]}function $v(t,e,r){let{gen:n,data:i,opts:s}=t,o=n.let("dataType",(0,K._)`typeof ${i}`),a=n.let("coerced",(0,K._)`undefined`);s.coerceTypes==="array"&&n.if((0,K._)`${o} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>n.assign(i,(0,K._)`${i}[0]`).assign(o,(0,K._)`typeof ${i}`).if(Qo(e,i,s.strictNumbers),()=>n.assign(a,i))),n.if((0,K._)`${a} !== undefined`);for(let u of r)(nf.has(u)||u==="array"&&s.coerceTypes==="array")&&l(u);n.else(),Zo(t),n.endIf(),n.if((0,K._)`${a} !== undefined`,()=>{n.assign(i,a),Cv(t,a)});function l(u){switch(u){case"string":n.elseIf((0,K._)`${o} == "number" || ${o} == "boolean"`).assign(a,(0,K._)`"" + ${i}`).elseIf((0,K._)`${i} === null`).assign(a,(0,K._)`""`);return;case"number":n.elseIf((0,K._)`${o} == "boolean" || ${i} === null
|
|
31
|
-
|| (${
|
|
32
|
-
|| (${
|
|
33
|
-
|| ${o} === "boolean" || ${i} === null`).assign(a,(0,K._)`[${i}]`)}}}function Cv({gen:t,parentData:e,parentDataProperty:r},n){t.if((0,K._)`${e} !== undefined`,()=>t.assign((0,K._)`${e}[${r}]`,n))}function Xo(t,e,r,n=Cr.Correct){let i=n===Cr.Correct?K.operators.EQ:K.operators.NEQ,s;switch(t){case"null":return(0,K._)`${e} ${i} null`;case"array":s=(0,K._)`Array.isArray(${e})`;break;case"object":s=(0,K._)`${e} && typeof ${e} == "object" && !Array.isArray(${e})`;break;case"integer":s=o((0,K._)`!(${e} % 1) && !isNaN(${e})`);break;case"number":s=o();break;default:return(0,K._)`typeof ${e} ${i} ${t}`}return n===Cr.Correct?s:(0,K.not)(s);function o(a=K.nil){return(0,K.and)((0,K._)`typeof ${e} == "number"`,a,r?(0,K._)`isFinite(${e})`:K.nil)}}xe.checkDataType=Xo;function Qo(t,e,r,n){if(t.length===1)return Xo(t[0],e,r,n);let i,s=(0,tf.toHash)(t);if(s.array&&s.object){let o=(0,K._)`typeof ${e} != "object"`;i=s.null?o:(0,K._)`!${e} || ${o}`,delete s.null,delete s.array,delete s.object}else i=K.nil;s.number&&delete s.integer;for(let o in s)i=(0,K.and)(i,Xo(o,e,r,n));return i}xe.checkDataTypes=Qo;var kv={message:({schema:t})=>`must be ${t}`,params:({schema:t,schemaValue:e})=>typeof t=="string"?(0,K._)`{type: ${t}}`:(0,K._)`{type: ${e}}`};function Zo(t){let e=xv(t);(0,wv.reportError)(e,kv)}xe.reportTypeError=Zo;function xv(t){let{gen:e,data:r,schema:n}=t,i=(0,tf.schemaRefOrVal)(t,n,"type");return{gen:e,keyword:"type",data:r,schema:n.type,schemaCode:i,schemaValue:i,parentSchema:n,params:{},it:t}}});var of=w(Ti=>{"use strict";Object.defineProperty(Ti,"__esModule",{value:!0});Ti.assignDefaults=void 0;var kr=W(),Pv=X();function Ov(t,e){let{properties:r,items:n}=t.schema;if(e==="object"&&r)for(let i in r)sf(t,i,r[i].default);else e==="array"&&Array.isArray(n)&&n.forEach((i,s)=>sf(t,s,i.default))}Ti.assignDefaults=Ov;function sf(t,e,r){let{gen:n,compositeRule:i,data:s,opts:o}=t;if(r===void 0)return;let a=(0,kr._)`${s}${(0,kr.getProperty)(e)}`;if(i){(0,Pv.checkStrictMode)(t,`default is ignored for: ${a}`);return}let l=(0,kr._)`${a} === undefined`;o.useDefaults==="empty"&&(l=(0,kr._)`${l} || ${a} === null || ${a} === ""`),n.if(l,(0,kr._)`${a} = ${(0,kr.stringify)(r)}`)}});var Ke=w(oe=>{"use strict";Object.defineProperty(oe,"__esModule",{value:!0});oe.validateUnion=oe.validateArray=oe.usePattern=oe.callValidateCode=oe.schemaProperties=oe.allSchemaProperties=oe.noPropertyInData=oe.propertyInData=oe.isOwnProperty=oe.hasPropFunc=oe.reportMissingProp=oe.checkMissingProp=oe.checkReportMissingProp=void 0;var ue=W(),ea=X(),qt=We(),Av=X();function Rv(t,e){let{gen:r,data:n,it:i}=t;r.if(ra(r,n,e,i.opts.ownProperties),()=>{t.setParams({missingProperty:(0,ue._)`${e}`},!0),t.error()})}oe.checkReportMissingProp=Rv;function Iv({gen:t,data:e,it:{opts:r}},n,i){return(0,ue.or)(...n.map(s=>(0,ue.and)(ra(t,e,s,r.ownProperties),(0,ue._)`${i} = ${s}`)))}oe.checkMissingProp=Iv;function Tv(t,e){t.setParams({missingProperty:e},!0),t.error()}oe.reportMissingProp=Tv;function af(t){return t.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,ue._)`Object.prototype.hasOwnProperty`})}oe.hasPropFunc=af;function ta(t,e,r){return(0,ue._)`${af(t)}.call(${e}, ${r})`}oe.isOwnProperty=ta;function Nv(t,e,r,n){let i=(0,ue._)`${e}${(0,ue.getProperty)(r)} !== undefined`;return n?(0,ue._)`${i} && ${ta(t,e,r)}`:i}oe.propertyInData=Nv;function ra(t,e,r,n){let i=(0,ue._)`${e}${(0,ue.getProperty)(r)} === undefined`;return n?(0,ue.or)(i,(0,ue.not)(ta(t,e,r))):i}oe.noPropertyInData=ra;function cf(t){return t?Object.keys(t).filter(e=>e!=="__proto__"):[]}oe.allSchemaProperties=cf;function Mv(t,e){return cf(e).filter(r=>!(0,ea.alwaysValidSchema)(t,e[r]))}oe.schemaProperties=Mv;function Lv({schemaCode:t,data:e,it:{gen:r,topSchemaRef:n,schemaPath:i,errorPath:s},it:o},a,l,u){let d=u?(0,ue._)`${t}, ${e}, ${n}${i}`:e,f=[[qt.default.instancePath,(0,ue.strConcat)(qt.default.instancePath,s)],[qt.default.parentData,o.parentData],[qt.default.parentDataProperty,o.parentDataProperty],[qt.default.rootData,qt.default.rootData]];o.opts.dynamicRef&&f.push([qt.default.dynamicAnchors,qt.default.dynamicAnchors]);let h=(0,ue._)`${d}, ${r.object(...f)}`;return l!==ue.nil?(0,ue._)`${a}.call(${l}, ${h})`:(0,ue._)`${a}(${h})`}oe.callValidateCode=Lv;var jv=(0,ue._)`new RegExp`;function Dv({gen:t,it:{opts:e}},r){let n=e.unicodeRegExp?"u":"",{regExp:i}=e.code,s=i(r,n);return t.scopeValue("pattern",{key:s.toString(),ref:s,code:(0,ue._)`${i.code==="new RegExp"?jv:(0,Av.useFunc)(t,i)}(${r}, ${n})`})}oe.usePattern=Dv;function qv(t){let{gen:e,data:r,keyword:n,it:i}=t,s=e.name("valid");if(i.allErrors){let a=e.let("valid",!0);return o(()=>e.assign(a,!1)),a}return e.var(s,!0),o(()=>e.break()),s;function o(a){let l=e.const("len",(0,ue._)`${r}.length`);e.forRange("i",0,l,u=>{t.subschema({keyword:n,dataProp:u,dataPropType:ea.Type.Num},s),e.if((0,ue.not)(s),a)})}}oe.validateArray=qv;function Vv(t){let{gen:e,schema:r,keyword:n,it:i}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(l=>(0,ea.alwaysValidSchema)(i,l))&&!i.opts.unevaluated)return;let o=e.let("valid",!1),a=e.name("_valid");e.block(()=>r.forEach((l,u)=>{let d=t.subschema({keyword:n,schemaProp:u,compositeRule:!0},a);e.assign(o,(0,ue._)`${o} || ${a}`),t.mergeValidEvaluated(d,a)||e.if((0,ue.not)(o))})),t.result(o,()=>t.reset(),()=>t.error(!0))}oe.validateUnion=Vv});var ff=w(ht=>{"use strict";Object.defineProperty(ht,"__esModule",{value:!0});ht.validateKeywordUsage=ht.validSchemaType=ht.funcKeywordCode=ht.macroKeywordCode=void 0;var Re=W(),tr=We(),Fv=Ke(),Hv=_n();function Bv(t,e){let{gen:r,keyword:n,schema:i,parentSchema:s,it:o}=t,a=e.macro.call(o.self,i,s,o),l=uf(r,n,a);o.opts.validateSchema!==!1&&o.self.validateSchema(a,!0);let u=r.name("valid");t.subschema({schema:a,schemaPath:Re.nil,errSchemaPath:`${o.errSchemaPath}/${n}`,topSchemaRef:l,compositeRule:!0},u),t.pass(u,()=>t.error(!0))}ht.macroKeywordCode=Bv;function Uv(t,e){var r;let{gen:n,keyword:i,schema:s,parentSchema:o,$data:a,it:l}=t;zv(l,e);let u=!a&&e.compile?e.compile.call(l.self,s,o,l):e.validate,d=uf(n,i,u),f=n.let("valid");t.block$data(f,h),t.ok((r=e.valid)!==null&&r!==void 0?r:f);function h(){if(e.errors===!1)_(),e.modifying&&lf(t),x(()=>t.error());else{let E=e.async?m():g();e.modifying&&lf(t),x(()=>Gv(t,E))}}function m(){let E=n.let("ruleErrs",null);return n.try(()=>_((0,Re._)`await `),V=>n.assign(f,!1).if((0,Re._)`${V} instanceof ${l.ValidationError}`,()=>n.assign(E,(0,Re._)`${V}.errors`),()=>n.throw(V))),E}function g(){let E=(0,Re._)`${d}.errors`;return n.assign(E,null),_(Re.nil),E}function _(E=e.async?(0,Re._)`await `:Re.nil){let V=l.opts.passContext?tr.default.this:tr.default.self,G=!("compile"in e&&!a||e.schema===!1);n.assign(f,(0,Re._)`${E}${(0,Fv.callValidateCode)(t,d,V,G)}`,e.modifying)}function x(E){var V;n.if((0,Re.not)((V=e.valid)!==null&&V!==void 0?V:f),E)}}ht.funcKeywordCode=Uv;function lf(t){let{gen:e,data:r,it:n}=t;e.if(n.parentData,()=>e.assign(r,(0,Re._)`${n.parentData}[${n.parentDataProperty}]`))}function Gv(t,e){let{gen:r}=t;r.if((0,Re._)`Array.isArray(${e})`,()=>{r.assign(tr.default.vErrors,(0,Re._)`${tr.default.vErrors} === null ? ${e} : ${tr.default.vErrors}.concat(${e})`).assign(tr.default.errors,(0,Re._)`${tr.default.vErrors}.length`),(0,Hv.extendErrors)(t)},()=>t.error())}function zv({schemaEnv:t},e){if(e.async&&!t.$async)throw new Error("async keyword in sync schema")}function uf(t,e,r){if(r===void 0)throw new Error(`keyword "${e}" failed to compile`);return t.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,Re.stringify)(r)})}function Wv(t,e,r=!1){return!e.length||e.some(n=>n==="array"?Array.isArray(t):n==="object"?t&&typeof t=="object"&&!Array.isArray(t):typeof t==n||r&&typeof t>"u")}ht.validSchemaType=Wv;function Kv({schema:t,opts:e,self:r,errSchemaPath:n},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw new Error("ajv implementation error");let o=i.dependencies;if(o?.some(a=>!Object.prototype.hasOwnProperty.call(t,a)))throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema&&!i.validateSchema(t[s])){let l=`keyword "${s}" value is invalid at path "${n}": `+r.errorsText(i.validateSchema.errors);if(e.validateSchema==="log")r.logger.error(l);else throw new Error(l)}}ht.validateKeywordUsage=Kv});var pf=w(Vt=>{"use strict";Object.defineProperty(Vt,"__esModule",{value:!0});Vt.extendSubschemaMode=Vt.extendSubschemaData=Vt.getSubschema=void 0;var mt=W(),df=X();function Jv(t,{keyword:e,schemaProp:r,schema:n,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(e!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(e!==void 0){let a=t.schema[e];return r===void 0?{schema:a,schemaPath:(0,mt._)`${t.schemaPath}${(0,mt.getProperty)(e)}`,errSchemaPath:`${t.errSchemaPath}/${e}`}:{schema:a[r],schemaPath:(0,mt._)`${t.schemaPath}${(0,mt.getProperty)(e)}${(0,mt.getProperty)(r)}`,errSchemaPath:`${t.errSchemaPath}/${e}/${(0,df.escapeFragment)(r)}`}}if(n!==void 0){if(i===void 0||s===void 0||o===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw new Error('either "keyword" or "schema" must be passed')}Vt.getSubschema=Jv;function Yv(t,e,{dataProp:r,dataPropType:n,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=e;if(r!==void 0){let{errorPath:u,dataPathArr:d,opts:f}=e,h=a.let("data",(0,mt._)`${e.data}${(0,mt.getProperty)(r)}`,!0);l(h),t.errorPath=(0,mt.str)`${u}${(0,df.getErrorPath)(r,n,f.jsPropertySyntax)}`,t.parentDataProperty=(0,mt._)`${r}`,t.dataPathArr=[...d,t.parentDataProperty]}if(i!==void 0){let u=i instanceof mt.Name?i:a.let("data",i,!0);l(u),o!==void 0&&(t.propertyName=o)}s&&(t.dataTypes=s);function l(u){t.data=u,t.dataLevel=e.dataLevel+1,t.dataTypes=[],e.definedProperties=new Set,t.parentData=e.data,t.dataNames=[...e.dataNames,u]}}Vt.extendSubschemaData=Yv;function Xv(t,{jtdDiscriminator:e,jtdMetadata:r,compositeRule:n,createErrors:i,allErrors:s}){n!==void 0&&(t.compositeRule=n),i!==void 0&&(t.createErrors=i),s!==void 0&&(t.allErrors=s),t.jtdDiscriminator=e,t.jtdMetadata=r}Vt.extendSubschemaMode=Xv});var na=w((rx,hf)=>{"use strict";hf.exports=function t(e,r){if(e===r)return!0;if(e&&r&&typeof e=="object"&&typeof r=="object"){if(e.constructor!==r.constructor)return!1;var n,i,s;if(Array.isArray(e)){if(n=e.length,n!=r.length)return!1;for(i=n;i--!==0;)if(!t(e[i],r[i]))return!1;return!0}if(e.constructor===RegExp)return e.source===r.source&&e.flags===r.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===r.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===r.toString();if(s=Object.keys(e),n=s.length,n!==Object.keys(r).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(r,s[i]))return!1;for(i=n;i--!==0;){var o=s[i];if(!t(e[o],r[o]))return!1}return!0}return e!==e&&r!==r}});var gf=w((nx,mf)=>{"use strict";var Ft=mf.exports=function(t,e,r){typeof e=="function"&&(r=e,e={}),r=e.cb||r;var n=typeof r=="function"?r:r.pre||function(){},i=r.post||function(){};Ni(e,n,i,t,"",t)};Ft.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Ft.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Ft.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Ft.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Ni(t,e,r,n,i,s,o,a,l,u){if(n&&typeof n=="object"&&!Array.isArray(n)){e(n,i,s,o,a,l,u);for(var d in n){var f=n[d];if(Array.isArray(f)){if(d in Ft.arrayKeywords)for(var h=0;h<f.length;h++)Ni(t,e,r,f[h],i+"/"+d+"/"+h,s,i,d,n,h)}else if(d in Ft.propsKeywords){if(f&&typeof f=="object")for(var m in f)Ni(t,e,r,f[m],i+"/"+d+"/"+Qv(m),s,i,d,n,m)}else(d in Ft.keywords||t.allKeys&&!(d in Ft.skipKeywords))&&Ni(t,e,r,f,i+"/"+d,s,i,d,n)}r(n,i,s,o,a,l,u)}}function Qv(t){return t.replace(/~/g,"~0").replace(/\//g,"~1")}});var bn=w(je=>{"use strict";Object.defineProperty(je,"__esModule",{value:!0});je.getSchemaRefs=je.resolveUrl=je.normalizeId=je._getFullPath=je.getFullPath=je.inlineRef=void 0;var Zv=X(),e_=na(),t_=gf(),r_=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function n_(t,e=!0){return typeof t=="boolean"?!0:e===!0?!ia(t):e?yf(t)<=e:!1}je.inlineRef=n_;var i_=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function ia(t){for(let e in t){if(i_.has(e))return!0;let r=t[e];if(Array.isArray(r)&&r.some(ia)||typeof r=="object"&&ia(r))return!0}return!1}function yf(t){let e=0;for(let r in t){if(r==="$ref")return 1/0;if(e++,!r_.has(r)&&(typeof t[r]=="object"&&(0,Zv.eachItem)(t[r],n=>e+=yf(n)),e===1/0))return 1/0}return e}function vf(t,e="",r){r!==!1&&(e=xr(e));let n=t.parse(e);return _f(t,n)}je.getFullPath=vf;function _f(t,e){return t.serialize(e).split("#")[0]+"#"}je._getFullPath=_f;var s_=/#\/?$/;function xr(t){return t?t.replace(s_,""):""}je.normalizeId=xr;function o_(t,e,r){return r=xr(r),t.resolve(e,r)}je.resolveUrl=o_;var a_=/^[a-z_][-a-z0-9._]*$/i;function c_(t,e){if(typeof t=="boolean")return{};let{schemaId:r,uriResolver:n}=this.opts,i=xr(t[r]||e),s={"":i},o=vf(n,i,!1),a={},l=new Set;return t_(t,{allKeys:!0},(f,h,m,g)=>{if(g===void 0)return;let _=o+h,x=s[g];typeof f[r]=="string"&&(x=E.call(this,f[r])),V.call(this,f.$anchor),V.call(this,f.$dynamicAnchor),s[h]=x;function E(G){let j=this.opts.uriResolver.resolve;if(G=xr(x?j(x,G):G),l.has(G))throw d(G);l.add(G);let L=this.refs[G];return typeof L=="string"&&(L=this.refs[L]),typeof L=="object"?u(f,L.schema,G):G!==xr(_)&&(G[0]==="#"?(u(f,a[G],G),a[G]=f):this.refs[G]=_),G}function V(G){if(typeof G=="string"){if(!a_.test(G))throw new Error(`invalid anchor "${G}"`);E.call(this,`#${G}`)}}}),a;function u(f,h,m){if(h!==void 0&&!e_(f,h))throw d(m)}function d(f){return new Error(`reference "${f}" resolves to more than one schema`)}}je.getSchemaRefs=c_});var $n=w(Ht=>{"use strict";Object.defineProperty(Ht,"__esModule",{value:!0});Ht.getData=Ht.KeywordCxt=Ht.validateFunctionCode=void 0;var $f=Qu(),wf=wn(),oa=Yo(),Mi=wn(),l_=of(),En=ff(),sa=pf(),q=W(),z=We(),u_=bn(),Rt=X(),Sn=_n();function f_(t){if(xf(t)&&(Pf(t),kf(t))){h_(t);return}Cf(t,()=>(0,$f.topBoolOrEmptySchema)(t))}Ht.validateFunctionCode=f_;function Cf({gen:t,validateName:e,schema:r,schemaEnv:n,opts:i},s){i.code.es5?t.func(e,(0,q._)`${z.default.data}, ${z.default.valCxt}`,n.$async,()=>{t.code((0,q._)`"use strict"; ${bf(r,i)}`),p_(t,i),t.code(s)}):t.func(e,(0,q._)`${z.default.data}, ${d_(i)}`,n.$async,()=>t.code(bf(r,i)).code(s))}function d_(t){return(0,q._)`{${z.default.instancePath}="", ${z.default.parentData}, ${z.default.parentDataProperty}, ${z.default.rootData}=${z.default.data}${t.dynamicRef?(0,q._)`, ${z.default.dynamicAnchors}={}`:q.nil}}={}`}function p_(t,e){t.if(z.default.valCxt,()=>{t.var(z.default.instancePath,(0,q._)`${z.default.valCxt}.${z.default.instancePath}`),t.var(z.default.parentData,(0,q._)`${z.default.valCxt}.${z.default.parentData}`),t.var(z.default.parentDataProperty,(0,q._)`${z.default.valCxt}.${z.default.parentDataProperty}`),t.var(z.default.rootData,(0,q._)`${z.default.valCxt}.${z.default.rootData}`),e.dynamicRef&&t.var(z.default.dynamicAnchors,(0,q._)`${z.default.valCxt}.${z.default.dynamicAnchors}`)},()=>{t.var(z.default.instancePath,(0,q._)`""`),t.var(z.default.parentData,(0,q._)`undefined`),t.var(z.default.parentDataProperty,(0,q._)`undefined`),t.var(z.default.rootData,z.default.data),e.dynamicRef&&t.var(z.default.dynamicAnchors,(0,q._)`{}`)})}function h_(t){let{schema:e,opts:r,gen:n}=t;Cf(t,()=>{r.$comment&&e.$comment&&Af(t),__(t),n.let(z.default.vErrors,null),n.let(z.default.errors,0),r.unevaluated&&m_(t),Of(t),S_(t)})}function m_(t){let{gen:e,validateName:r}=t;t.evaluated=e.const("evaluated",(0,q._)`${r}.evaluated`),e.if((0,q._)`${t.evaluated}.dynamicProps`,()=>e.assign((0,q._)`${t.evaluated}.props`,(0,q._)`undefined`)),e.if((0,q._)`${t.evaluated}.dynamicItems`,()=>e.assign((0,q._)`${t.evaluated}.items`,(0,q._)`undefined`))}function bf(t,e){let r=typeof t=="object"&&t[e.schemaId];return r&&(e.code.source||e.code.process)?(0,q._)`/*# sourceURL=${r} */`:q.nil}function g_(t,e){if(xf(t)&&(Pf(t),kf(t))){y_(t,e);return}(0,$f.boolOrEmptySchema)(t,e)}function kf({schema:t,self:e}){if(typeof t=="boolean")return!t;for(let r in t)if(e.RULES.all[r])return!0;return!1}function xf(t){return typeof t.schema!="boolean"}function y_(t,e){let{schema:r,gen:n,opts:i}=t;i.$comment&&r.$comment&&Af(t),w_(t),b_(t);let s=n.const("_errs",z.default.errors);Of(t,s),n.var(e,(0,q._)`${s} === ${z.default.errors}`)}function Pf(t){(0,Rt.checkUnknownRules)(t),v_(t)}function Of(t,e){if(t.opts.jtd)return Sf(t,[],!1,e);let r=(0,wf.getSchemaTypes)(t.schema),n=(0,wf.coerceAndCheckDataType)(t,r);Sf(t,r,!n,e)}function v_(t){let{schema:e,errSchemaPath:r,opts:n,self:i}=t;e.$ref&&n.ignoreKeywordsWithRef&&(0,Rt.schemaHasRulesButRef)(e,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function __(t){let{schema:e,opts:r}=t;e.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,Rt.checkStrictMode)(t,"default is ignored in the schema root")}function w_(t){let e=t.schema[t.opts.schemaId];e&&(t.baseId=(0,u_.resolveUrl)(t.opts.uriResolver,t.baseId,e))}function b_(t){if(t.schema.$async&&!t.schemaEnv.$async)throw new Error("async schema in sync schema")}function Af({gen:t,schemaEnv:e,schema:r,errSchemaPath:n,opts:i}){let s=r.$comment;if(i.$comment===!0)t.code((0,q._)`${z.default.self}.logger.log(${s})`);else if(typeof i.$comment=="function"){let o=(0,q.str)`${n}/$comment`,a=t.scopeValue("root",{ref:e.root});t.code((0,q._)`${z.default.self}.opts.$comment(${s}, ${o}, ${a}.schema)`)}}function S_(t){let{gen:e,schemaEnv:r,validateName:n,ValidationError:i,opts:s}=t;r.$async?e.if((0,q._)`${z.default.errors} === 0`,()=>e.return(z.default.data),()=>e.throw((0,q._)`new ${i}(${z.default.vErrors})`)):(e.assign((0,q._)`${n}.errors`,z.default.vErrors),s.unevaluated&&E_(t),e.return((0,q._)`${z.default.errors} === 0`))}function E_({gen:t,evaluated:e,props:r,items:n}){r instanceof q.Name&&t.assign((0,q._)`${e}.props`,r),n instanceof q.Name&&t.assign((0,q._)`${e}.items`,n)}function Sf(t,e,r,n){let{gen:i,schema:s,data:o,allErrors:a,opts:l,self:u}=t,{RULES:d}=u;if(s.$ref&&(l.ignoreKeywordsWithRef||!(0,Rt.schemaHasRulesButRef)(s,d))){i.block(()=>If(t,"$ref",d.all.$ref.definition));return}l.jtd||$_(t,e),i.block(()=>{for(let h of d.rules)f(h);f(d.post)});function f(h){(0,oa.shouldUseGroup)(s,h)&&(h.type?(i.if((0,Mi.checkDataType)(h.type,o,l.strictNumbers)),Ef(t,h),e.length===1&&e[0]===h.type&&r&&(i.else(),(0,Mi.reportTypeError)(t)),i.endIf()):Ef(t,h),a||i.if((0,q._)`${z.default.errors} === ${n||0}`))}}function Ef(t,e){let{gen:r,schema:n,opts:{useDefaults:i}}=t;i&&(0,l_.assignDefaults)(t,e.type),r.block(()=>{for(let s of e.rules)(0,oa.shouldUseRule)(n,s)&&If(t,s.keyword,s.definition,e.type)})}function $_(t,e){t.schemaEnv.meta||!t.opts.strictTypes||(C_(t,e),t.opts.allowUnionTypes||k_(t,e),x_(t,t.dataTypes))}function C_(t,e){if(e.length){if(!t.dataTypes.length){t.dataTypes=e;return}e.forEach(r=>{Rf(t.dataTypes,r)||aa(t,`type "${r}" not allowed by context "${t.dataTypes.join(",")}"`)}),O_(t,e)}}function k_(t,e){e.length>1&&!(e.length===2&&e.includes("null"))&&aa(t,"use allowUnionTypes to allow union type keyword")}function x_(t,e){let r=t.self.RULES.all;for(let n in r){let i=r[n];if(typeof i=="object"&&(0,oa.shouldUseRule)(t.schema,i)){let{type:s}=i.definition;s.length&&!s.some(o=>P_(e,o))&&aa(t,`missing type "${s.join(",")}" for keyword "${n}"`)}}}function P_(t,e){return t.includes(e)||e==="number"&&t.includes("integer")}function Rf(t,e){return t.includes(e)||e==="integer"&&t.includes("number")}function O_(t,e){let r=[];for(let n of t.dataTypes)Rf(e,n)?r.push(n):e.includes("integer")&&n==="number"&&r.push("integer");t.dataTypes=r}function aa(t,e){let r=t.schemaEnv.baseId+t.errSchemaPath;e+=` at "${r}" (strictTypes)`,(0,Rt.checkStrictMode)(t,e,t.opts.strictTypes)}var Li=class{constructor(e,r,n){if((0,En.validateKeywordUsage)(e,r,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=r.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Rt.schemaRefOrVal)(e,this.schema,n,this.$data),this.schemaType=r.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=r,this.$data)this.schemaCode=e.gen.const("vSchema",Tf(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,En.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=e.gen.const("_errs",z.default.errors))}result(e,r,n){this.failResult((0,q.not)(e),r,n)}failResult(e,r,n){this.gen.if(e),n?n():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,r){this.failResult((0,q.not)(e),void 0,r)}fail(e){if(e===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:r}=this;this.fail((0,q._)`${r} !== undefined && (${(0,q.or)(this.invalid$data(),e)})`)}error(e,r,n){if(r){this.setParams(r),this._error(e,n),this.setParams({});return}this._error(e,n)}_error(e,r){(e?Sn.reportExtraError:Sn.reportError)(this,this.def.error,r)}$dataError(){(0,Sn.reportError)(this,this.def.$dataError||Sn.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,Sn.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,r){r?Object.assign(this.params,e):this.params=e}block$data(e,r,n=q.nil){this.gen.block(()=>{this.check$data(e,n),r()})}check$data(e=q.nil,r=q.nil){if(!this.$data)return;let{gen:n,schemaCode:i,schemaType:s,def:o}=this;n.if((0,q.or)((0,q._)`${i} === undefined`,r)),e!==q.nil&&n.assign(e,!0),(s.length||o.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),e!==q.nil&&n.assign(e,!1)),n.else()}invalid$data(){let{gen:e,schemaCode:r,schemaType:n,def:i,it:s}=this;return(0,q.or)(o(),a());function o(){if(n.length){if(!(r instanceof q.Name))throw new Error("ajv implementation error");let l=Array.isArray(n)?n:[n];return(0,q._)`${(0,Mi.checkDataTypes)(l,r,s.opts.strictNumbers,Mi.DataType.Wrong)}`}return q.nil}function a(){if(i.validateSchema){let l=e.scopeValue("validate$data",{ref:i.validateSchema});return(0,q._)`!${l}(${r})`}return q.nil}}subschema(e,r){let n=(0,sa.getSubschema)(this.it,e);(0,sa.extendSubschemaData)(n,this.it,e),(0,sa.extendSubschemaMode)(n,e);let i={...this.it,...n,items:void 0,props:void 0};return g_(i,r),i}mergeEvaluated(e,r){let{it:n,gen:i}=this;n.opts.unevaluated&&(n.props!==!0&&e.props!==void 0&&(n.props=Rt.mergeEvaluated.props(i,e.props,n.props,r)),n.items!==!0&&e.items!==void 0&&(n.items=Rt.mergeEvaluated.items(i,e.items,n.items,r)))}mergeValidEvaluated(e,r){let{it:n,gen:i}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return i.if(r,()=>this.mergeEvaluated(e,q.Name)),!0}};Ht.KeywordCxt=Li;function If(t,e,r,n){let i=new Li(t,r,e);"code"in r?r.code(i,n):i.$data&&r.validate?(0,En.funcKeywordCode)(i,r):"macro"in r?(0,En.macroKeywordCode)(i,r):(r.compile||r.validate)&&(0,En.funcKeywordCode)(i,r)}var A_=/^\/(?:[^~]|~0|~1)*$/,R_=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Tf(t,{dataLevel:e,dataNames:r,dataPathArr:n}){let i,s;if(t==="")return z.default.rootData;if(t[0]==="/"){if(!A_.test(t))throw new Error(`Invalid JSON-pointer: ${t}`);i=t,s=z.default.rootData}else{let u=R_.exec(t);if(!u)throw new Error(`Invalid JSON-pointer: ${t}`);let d=+u[1];if(i=u[2],i==="#"){if(d>=e)throw new Error(l("property/index",d));return n[e-d]}if(d>e)throw new Error(l("data",d));if(s=r[e-d],!i)return s}let o=s,a=i.split("/");for(let u of a)u&&(s=(0,q._)`${s}${(0,q.getProperty)((0,Rt.unescapeJsonPointer)(u))}`,o=(0,q._)`${o} && ${s}`);return o;function l(u,d){return`Cannot access ${u} ${d} levels up, current level is ${e}`}}Ht.getData=Tf});var ji=w(la=>{"use strict";Object.defineProperty(la,"__esModule",{value:!0});var ca=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}};la.default=ca});var Cn=w(da=>{"use strict";Object.defineProperty(da,"__esModule",{value:!0});var ua=bn(),fa=class extends Error{constructor(e,r,n,i){super(i||`can't resolve reference ${n} from id ${r}`),this.missingRef=(0,ua.resolveUrl)(e,r,n),this.missingSchema=(0,ua.normalizeId)((0,ua.getFullPath)(e,this.missingRef))}};da.default=fa});var kn=w(Je=>{"use strict";Object.defineProperty(Je,"__esModule",{value:!0});Je.resolveSchema=Je.getCompilingSchema=Je.resolveRef=Je.compileSchema=Je.SchemaEnv=void 0;var ct=W(),I_=ji(),rr=We(),lt=bn(),Nf=X(),T_=$n(),Pr=class{constructor(e){var r;this.refs={},this.dynamicAnchors={};let n;typeof e.schema=="object"&&(n=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(r=e.baseId)!==null&&r!==void 0?r:(0,lt.normalizeId)(n?.[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=n?.$async,this.refs={}}};Je.SchemaEnv=Pr;function ha(t){let e=Mf.call(this,t);if(e)return e;let r=(0,lt.getFullPath)(this.opts.uriResolver,t.root.baseId),{es5:n,lines:i}=this.opts.code,{ownProperties:s}=this.opts,o=new ct.CodeGen(this.scope,{es5:n,lines:i,ownProperties:s}),a;t.$async&&(a=o.scopeValue("Error",{ref:I_.default,code:(0,ct._)`require("ajv/dist/runtime/validation_error").default`}));let l=o.scopeName("validate");t.validateName=l;let u={gen:o,allErrors:this.opts.allErrors,data:rr.default.data,parentData:rr.default.parentData,parentDataProperty:rr.default.parentDataProperty,dataNames:[rr.default.data],dataPathArr:[ct.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===!0?{ref:t.schema,code:(0,ct.stringify)(t.schema)}:{ref:t.schema}),validateName:l,ValidationError:a,schema:t.schema,schemaEnv:t,rootId:r,baseId:t.baseId||r,schemaPath:ct.nil,errSchemaPath:t.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,ct._)`""`,opts:this.opts,self:this},d;try{this._compilations.add(t),(0,T_.validateFunctionCode)(u),o.optimize(this.opts.code.optimize);let f=o.toString();d=`${o.scopeRefs(rr.default.scope)}return ${f}`,this.opts.code.process&&(d=this.opts.code.process(d,t));let m=new Function(`${rr.default.self}`,`${rr.default.scope}`,d)(this,this.scope.get());if(this.scope.value(l,{ref:m}),m.errors=null,m.schema=t.schema,m.schemaEnv=t,t.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:l,validateCode:f,scopeValues:o._values}),this.opts.unevaluated){let{props:g,items:_}=u;m.evaluated={props:g instanceof ct.Name?void 0:g,items:_ instanceof ct.Name?void 0:_,dynamicProps:g instanceof ct.Name,dynamicItems:_ instanceof ct.Name},m.source&&(m.source.evaluated=(0,ct.stringify)(m.evaluated))}return t.validate=m,t}catch(f){throw delete t.validate,delete t.validateName,d&&this.logger.error("Error compiling schema, function code:",d),f}finally{this._compilations.delete(t)}}Je.compileSchema=ha;function N_(t,e,r){var n;r=(0,lt.resolveUrl)(this.opts.uriResolver,e,r);let i=t.refs[r];if(i)return i;let s=j_.call(this,t,r);if(s===void 0){let o=(n=t.localRefs)===null||n===void 0?void 0:n[r],{schemaId:a}=this.opts;o&&(s=new Pr({schema:o,schemaId:a,root:t,baseId:e}))}if(s!==void 0)return t.refs[r]=M_.call(this,s)}Je.resolveRef=N_;function M_(t){return(0,lt.inlineRef)(t.schema,this.opts.inlineRefs)?t.schema:t.validate?t:ha.call(this,t)}function Mf(t){for(let e of this._compilations)if(L_(e,t))return e}Je.getCompilingSchema=Mf;function L_(t,e){return t.schema===e.schema&&t.root===e.root&&t.baseId===e.baseId}function j_(t,e){let r;for(;typeof(r=this.refs[e])=="string";)e=r;return r||this.schemas[e]||Di.call(this,t,e)}function Di(t,e){let r=this.opts.uriResolver.parse(e),n=(0,lt._getFullPath)(this.opts.uriResolver,r),i=(0,lt.getFullPath)(this.opts.uriResolver,t.baseId,void 0);if(Object.keys(t.schema).length>0&&n===i)return pa.call(this,r,t);let s=(0,lt.normalizeId)(n),o=this.refs[s]||this.schemas[s];if(typeof o=="string"){let a=Di.call(this,t,o);return typeof a?.schema!="object"?void 0:pa.call(this,r,a)}if(typeof o?.schema=="object"){if(o.validate||ha.call(this,o),s===(0,lt.normalizeId)(e)){let{schema:a}=o,{schemaId:l}=this.opts,u=a[l];return u&&(i=(0,lt.resolveUrl)(this.opts.uriResolver,i,u)),new Pr({schema:a,schemaId:l,root:t,baseId:i})}return pa.call(this,r,o)}}Je.resolveSchema=Di;var D_=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function pa(t,{baseId:e,schema:r,root:n}){var i;if(((i=t.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(let a of t.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let l=r[(0,Nf.unescapeFragment)(a)];if(l===void 0)return;r=l;let u=typeof r=="object"&&r[this.opts.schemaId];!D_.has(a)&&u&&(e=(0,lt.resolveUrl)(this.opts.uriResolver,e,u))}let s;if(typeof r!="boolean"&&r.$ref&&!(0,Nf.schemaHasRulesButRef)(r,this.RULES)){let a=(0,lt.resolveUrl)(this.opts.uriResolver,e,r.$ref);s=Di.call(this,n,a)}let{schemaId:o}=this.opts;if(s=s||new Pr({schema:r,schemaId:o,root:n,baseId:e}),s.schema!==s.root.schema)return s}});var Lf=w((lx,q_)=>{q_.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var ya=w((ux,Hf)=>{"use strict";var V_=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),Df=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),ma=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),qf=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),F_=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function ga(t){let e="",r=0,n=0;for(n=0;n<t.length;n++)if(r=t[n].charCodeAt(0),r!==48){if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";e+=t[n];break}for(n+=1;n<t.length;n++){if(r=t[n].charCodeAt(0),!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";e+=t[n]}return e}var H_=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function jf(t){return t.length=0,!0}function B_(t,e,r){if(t.length){let n=ga(t);if(n!=="")e.push(n);else return r.error=!0,!1;t.length=0}return!0}function U_(t){let e=0,r={error:!1,address:"",zone:""},n=[],i=[],s=!1,o=!1,a=B_;for(let l=0;l<t.length;l++){let u=t[l];if(!(u==="["||u==="]"))if(u===":"){if(s===!0&&(o=!0),!a(i,n,r))break;if(++e>7){r.error=!0;break}l>0&&t[l-1]===":"&&(s=!0),n.push(":");continue}else if(u==="%"){if(!a(i,n,r))break;a=jf}else{i.push(u);continue}}return i.length&&(a===jf?r.zone=i.join(""):o?n.push(i.join("")):n.push(ga(i))),r.address=n.join(""),r}function Vf(t){if(G_(t,":")<2)return{host:t,isIPV6:!1};let e=U_(t);if(e.error)return{host:t,isIPV6:!1};{let r=e.address,n=e.address;return e.zone&&(r+="%"+e.zone,n+="%25"+e.zone),{host:r,isIPV6:!0,escapedHost:n}}}function G_(t,e){let r=0;for(let n=0;n<t.length;n++)t[n]===e&&r++;return r}function z_(t){let e=t,r=[],n=-1,i=0;for(;i=e.length;){if(i===1){if(e===".")break;if(e==="/"){r.push("/");break}else{r.push(e);break}}else if(i===2){if(e[0]==="."){if(e[1]===".")break;if(e[1]==="/"){e=e.slice(2);continue}}else if(e[0]==="/"&&(e[1]==="."||e[1]==="/")){r.push("/");break}}else if(i===3&&e==="/.."){r.length!==0&&r.pop(),r.push("/");break}if(e[0]==="."){if(e[1]==="."){if(e[2]==="/"){e=e.slice(3);continue}}else if(e[1]==="/"){e=e.slice(2);continue}}else if(e[0]==="/"&&e[1]==="."){if(e[2]==="/"){e=e.slice(2);continue}else if(e[2]==="."&&e[3]==="/"){e=e.slice(3),r.length!==0&&r.pop();continue}}if((n=e.indexOf("/",1))===-1){r.push(e);break}else r.push(e.slice(0,n)),e=e.slice(n)}return r.join("")}var W_={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},K_=/[@/?#:]/g,J_=/[@/?#]/g;function Ff(t,e){let r=e?J_:K_;return r.lastIndex=0,t.replace(r,n=>W_[n])}function Y_(t,e=!1){if(t.indexOf("%")===-1)return t;let r="";for(let n=0;n<t.length;n++){if(t[n]==="%"&&n+2<t.length){let i=t.slice(n+1,n+3);if(ma(i)){let s=i.toUpperCase(),o=String.fromCharCode(parseInt(s,16));e&&qf(o)?r+=o:r+="%"+s,n+=2;continue}}r+=t[n]}return r}function X_(t){let e="";for(let r=0;r<t.length;r++){if(t[r]==="%"&&r+2<t.length){let n=t.slice(r+1,r+3);if(ma(n)){let i=n.toUpperCase(),s=String.fromCharCode(parseInt(i,16));s!=="."&&qf(s)?e+=s:e+="%"+i,r+=2;continue}}F_(t[r])?e+=t[r]:e+=escape(t[r])}return e}function Q_(t){let e="";for(let r=0;r<t.length;r++){if(t[r]==="%"&&r+2<t.length){let n=t.slice(r+1,r+3);if(ma(n)){e+="%"+n.toUpperCase(),r+=2;continue}}e+=escape(t[r])}return e}function Z_(t){let e=[];if(t.userinfo!==void 0&&(e.push(t.userinfo),e.push("@")),t.host!==void 0){let r=unescape(t.host);if(!Df(r)){let n=Vf(r);n.isIPV6===!0?r=`[${n.escapedHost}]`:r=Ff(r,!1)}e.push(r)}return(typeof t.port=="number"||typeof t.port=="string")&&(e.push(":"),e.push(String(t.port))),e.length?e.join(""):void 0}Hf.exports={nonSimpleDomain:H_,recomposeAuthority:Z_,reescapeHostDelimiters:Ff,normalizePercentEncoding:Y_,normalizePathEncoding:X_,escapePreservingEscapes:Q_,removeDotSegments:z_,isIPv4:Df,isUUID:V_,normalizeIPv6:Vf,stringArrayToHexStripped:ga}});var Wf=w((fx,zf)=>{"use strict";var{isUUID:ew}=ya(),tw=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,rw=["http","https","ws","wss","urn","urn:uuid"];function nw(t){return rw.indexOf(t)!==-1}function va(t){return t.secure===!0?!0:t.secure===!1?!1:t.scheme?t.scheme.length===3&&(t.scheme[0]==="w"||t.scheme[0]==="W")&&(t.scheme[1]==="s"||t.scheme[1]==="S")&&(t.scheme[2]==="s"||t.scheme[2]==="S"):!1}function Bf(t){return t.host||(t.error=t.error||"HTTP URIs must have a host."),t}function Uf(t){let e=String(t.scheme).toLowerCase()==="https";return(t.port===(e?443:80)||t.port==="")&&(t.port=void 0),t.path||(t.path="/"),t}function iw(t){return t.secure=va(t),t.resourceName=(t.path||"/")+(t.query?"?"+t.query:""),t.path=void 0,t.query=void 0,t}function sw(t){if((t.port===(va(t)?443:80)||t.port==="")&&(t.port=void 0),typeof t.secure=="boolean"&&(t.scheme=t.secure?"wss":"ws",t.secure=void 0),t.resourceName){let[e,r]=t.resourceName.split("?");t.path=e&&e!=="/"?e:void 0,t.query=r,t.resourceName=void 0}return t.fragment=void 0,t}function ow(t,e){if(!t.path)return t.error="URN can not be parsed",t;let r=t.path.match(tw);if(r){let n=e.scheme||t.scheme||"urn";t.nid=r[1].toLowerCase(),t.nss=r[2];let i=`${n}:${e.nid||t.nid}`,s=_a(i);t.path=void 0,s&&(t=s.parse(t,e))}else t.error=t.error||"URN can not be parsed.";return t}function aw(t,e){if(t.nid===void 0)throw new Error("URN without nid cannot be serialized");let r=e.scheme||t.scheme||"urn",n=t.nid.toLowerCase(),i=`${r}:${e.nid||n}`,s=_a(i);s&&(t=s.serialize(t,e));let o=t,a=t.nss;return o.path=`${n||e.nid}:${a}`,e.skipEscape=!0,o}function cw(t,e){let r=t;return r.uuid=r.nss,r.nss=void 0,!e.tolerant&&(!r.uuid||!ew(r.uuid))&&(r.error=r.error||"UUID is not valid."),r}function lw(t){let e=t;return e.nss=(t.uuid||"").toLowerCase(),e}var Gf={scheme:"http",domainHost:!0,parse:Bf,serialize:Uf},uw={scheme:"https",domainHost:Gf.domainHost,parse:Bf,serialize:Uf},qi={scheme:"ws",domainHost:!0,parse:iw,serialize:sw},fw={scheme:"wss",domainHost:qi.domainHost,parse:qi.parse,serialize:qi.serialize},dw={scheme:"urn",parse:ow,serialize:aw,skipNormalize:!0},pw={scheme:"urn:uuid",parse:cw,serialize:lw,skipNormalize:!0},Vi={http:Gf,https:uw,ws:qi,wss:fw,urn:dw,"urn:uuid":pw};Object.setPrototypeOf(Vi,null);function _a(t){return t&&(Vi[t]||Vi[t.toLowerCase()])||void 0}zf.exports={wsIsSecure:va,SCHEMES:Vi,isValidSchemeName:nw,getSchemeHandler:_a}});var Zf=w((dx,Fi)=>{"use strict";var{normalizeIPv6:hw,removeDotSegments:xn,recomposeAuthority:mw,normalizePercentEncoding:gw,normalizePathEncoding:yw,escapePreservingEscapes:vw,reescapeHostDelimiters:_w,isIPv4:ww,nonSimpleDomain:bw}=ya(),{SCHEMES:Sw,getSchemeHandler:Jf}=Wf();function Ew(t,e){return typeof t=="string"?t=Pw(t,e):typeof t=="object"&&(t=Or(nr(t,e),e)),t}function $w(t,e,r){let n=r?Object.assign({scheme:"null"},r):{scheme:"null"},i=Yf(Or(t,n),Or(e,n),n,!0);return n.skipEscape=!0,nr(i,n)}function Yf(t,e,r,n){let i={};return n||(t=Or(nr(t,r),r),e=Or(nr(e,r),r)),r=r||{},!r.tolerant&&e.scheme?(i.scheme=e.scheme,i.userinfo=e.userinfo,i.host=e.host,i.port=e.port,i.path=xn(e.path||""),i.query=e.query):(e.userinfo!==void 0||e.host!==void 0||e.port!==void 0?(i.userinfo=e.userinfo,i.host=e.host,i.port=e.port,i.path=xn(e.path||""),i.query=e.query):(e.path?(e.path[0]==="/"?i.path=xn(e.path):((t.userinfo!==void 0||t.host!==void 0||t.port!==void 0)&&!t.path?i.path="/"+e.path:t.path?i.path=t.path.slice(0,t.path.lastIndexOf("/")+1)+e.path:i.path=e.path,i.path=xn(i.path)),i.query=e.query):(i.path=t.path,e.query!==void 0?i.query=e.query:i.query=t.query),i.userinfo=t.userinfo,i.host=t.host,i.port=t.port),i.scheme=t.scheme),i.fragment=e.fragment,i}function Cw(t,e,r){let n=Kf(t,r),i=Kf(e,r);return n!==void 0&&i!==void 0&&n.toLowerCase()===i.toLowerCase()}function nr(t,e){let r={host:t.host,scheme:t.scheme,userinfo:t.userinfo,port:t.port,path:t.path,query:t.query,nid:t.nid,nss:t.nss,uuid:t.uuid,fragment:t.fragment,reference:t.reference,resourceName:t.resourceName,secure:t.secure,error:""},n=Object.assign({},e),i=[],s=Jf(n.scheme||r.scheme);s&&s.serialize&&s.serialize(r,n),r.path!==void 0&&(n.skipEscape?r.path=gw(r.path):(r.path=vw(r.path),r.scheme!==void 0&&(r.path=r.path.split("%3A").join(":")))),n.reference!=="suffix"&&r.scheme&&i.push(r.scheme,":");let o=mw(r);if(o!==void 0&&(n.reference!=="suffix"&&i.push("//"),i.push(o),r.path&&r.path[0]!=="/"&&i.push("/")),r.path!==void 0){let a=r.path;!n.absolutePath&&(!s||!s.absolutePath)&&(a=xn(a)),o===void 0&&a[0]==="/"&&a[1]==="/"&&(a="/%2F"+a.slice(2)),i.push(a)}return r.query!==void 0&&i.push("?",r.query),r.fragment!==void 0&&i.push("#",r.fragment),i.join("")}var kw=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function xw(t,e){if(e[2]!==void 0&&t.path&&t.path[0]!=="/")return'URI path must start with "/" when authority is present.';if(typeof t.port=="number"&&(t.port<0||t.port>65535))return"URI port is malformed."}function Xf(t,e){let r=Object.assign({},e),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},i=!1,s=!1;r.reference==="suffix"&&(r.scheme?t=r.scheme+":"+t:t="//"+t);let o=t.match(kw);if(o){n.scheme=o[1],n.userinfo=o[3],n.host=o[4],n.port=parseInt(o[5],10),n.path=o[6]||"",n.query=o[7],n.fragment=o[8],isNaN(n.port)&&(n.port=o[5]);let a=xw(n,o);if(a!==void 0&&(n.error=n.error||a,i=!0),n.host)if(ww(n.host)===!1){let d=hw(n.host);n.host=d.host.toLowerCase(),s=d.isIPV6}else s=!0;n.scheme===void 0&&n.userinfo===void 0&&n.host===void 0&&n.port===void 0&&n.query===void 0&&!n.path?n.reference="same-document":n.scheme===void 0?n.reference="relative":n.fragment===void 0?n.reference="absolute":n.reference="uri",r.reference&&r.reference!=="suffix"&&r.reference!==n.reference&&(n.error=n.error||"URI is not a "+r.reference+" reference.");let l=Jf(r.scheme||n.scheme);if(!r.unicodeSupport&&(!l||!l.unicodeSupport)&&n.host&&(r.domainHost||l&&l.domainHost)&&s===!1&&bw(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(u){n.error=n.error||"Host's domain name can not be converted to ASCII: "+u}if((!l||l&&!l.skipNormalize)&&(t.indexOf("%")!==-1&&(n.scheme!==void 0&&(n.scheme=unescape(n.scheme)),n.host!==void 0&&(n.host=_w(unescape(n.host),s))),n.path&&(n.path=yw(n.path)),n.fragment))try{n.fragment=encodeURI(decodeURIComponent(n.fragment))}catch{n.error=n.error||"URI malformed"}l&&l.parse&&l.parse(n,r)}else n.error=n.error||"URI can not be parsed.";return{parsed:n,malformedAuthorityOrPort:i}}function Or(t,e){return Xf(t,e).parsed}function Pw(t,e){return Qf(t,e).normalized}function Qf(t,e){let{parsed:r,malformedAuthorityOrPort:n}=Xf(t,e);return{normalized:n?t:nr(r,e),malformedAuthorityOrPort:n}}function Kf(t,e){if(typeof t=="string"){let{normalized:r,malformedAuthorityOrPort:n}=Qf(t,e);return n?void 0:r}if(typeof t=="object")return nr(t,e)}var wa={SCHEMES:Sw,normalize:Ew,resolve:$w,resolveComponent:Yf,equal:Cw,serialize:nr,parse:Or};Fi.exports=wa;Fi.exports.default=wa;Fi.exports.fastUri=wa});var td=w(ba=>{"use strict";Object.defineProperty(ba,"__esModule",{value:!0});var ed=Zf();ed.code='require("ajv/dist/runtime/uri").default';ba.default=ed});var ld=w(we=>{"use strict";Object.defineProperty(we,"__esModule",{value:!0});we.CodeGen=we.Name=we.nil=we.stringify=we.str=we._=we.KeywordCxt=void 0;var Ow=$n();Object.defineProperty(we,"KeywordCxt",{enumerable:!0,get:function(){return Ow.KeywordCxt}});var Ar=W();Object.defineProperty(we,"_",{enumerable:!0,get:function(){return Ar._}});Object.defineProperty(we,"str",{enumerable:!0,get:function(){return Ar.str}});Object.defineProperty(we,"stringify",{enumerable:!0,get:function(){return Ar.stringify}});Object.defineProperty(we,"nil",{enumerable:!0,get:function(){return Ar.nil}});Object.defineProperty(we,"Name",{enumerable:!0,get:function(){return Ar.Name}});Object.defineProperty(we,"CodeGen",{enumerable:!0,get:function(){return Ar.CodeGen}});var Aw=ji(),od=Cn(),Rw=Jo(),Pn=kn(),Iw=W(),On=bn(),Hi=wn(),Ea=X(),rd=Lf(),Tw=td(),ad=(t,e)=>new RegExp(t,e);ad.code="new RegExp";var Nw=["removeAdditional","useDefaults","coerceTypes"],Mw=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),Lw={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},jw={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},nd=200;function Dw(t){var e,r,n,i,s,o,a,l,u,d,f,h,m,g,_,x,E,V,G,j,L,Q,ne,Mt,nt;let _e=t.strict,Ne=(e=t.code)===null||e===void 0?void 0:e.optimize,Ee=Ne===!0||Ne===void 0?1:Ne||0,it=(n=(r=t.code)===null||r===void 0?void 0:r.regExp)!==null&&n!==void 0?n:ad,st=(i=t.uriResolver)!==null&&i!==void 0?i:Tw.default;return{strictSchema:(o=(s=t.strictSchema)!==null&&s!==void 0?s:_e)!==null&&o!==void 0?o:!0,strictNumbers:(l=(a=t.strictNumbers)!==null&&a!==void 0?a:_e)!==null&&l!==void 0?l:!0,strictTypes:(d=(u=t.strictTypes)!==null&&u!==void 0?u:_e)!==null&&d!==void 0?d:"log",strictTuples:(h=(f=t.strictTuples)!==null&&f!==void 0?f:_e)!==null&&h!==void 0?h:"log",strictRequired:(g=(m=t.strictRequired)!==null&&m!==void 0?m:_e)!==null&&g!==void 0?g:!1,code:t.code?{...t.code,optimize:Ee,regExp:it}:{optimize:Ee,regExp:it},loopRequired:(_=t.loopRequired)!==null&&_!==void 0?_:nd,loopEnum:(x=t.loopEnum)!==null&&x!==void 0?x:nd,meta:(E=t.meta)!==null&&E!==void 0?E:!0,messages:(V=t.messages)!==null&&V!==void 0?V:!0,inlineRefs:(G=t.inlineRefs)!==null&&G!==void 0?G:!0,schemaId:(j=t.schemaId)!==null&&j!==void 0?j:"$id",addUsedSchema:(L=t.addUsedSchema)!==null&&L!==void 0?L:!0,validateSchema:(Q=t.validateSchema)!==null&&Q!==void 0?Q:!0,validateFormats:(ne=t.validateFormats)!==null&&ne!==void 0?ne:!0,unicodeRegExp:(Mt=t.unicodeRegExp)!==null&&Mt!==void 0?Mt:!0,int32range:(nt=t.int32range)!==null&&nt!==void 0?nt:!0,uriResolver:st}}var An=class{constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...Dw(e)};let{es5:r,lines:n}=this.opts.code;this.scope=new Iw.ValueScope({scope:{},prefixes:Mw,es5:r,lines:n}),this.logger=Uw(e.logger);let i=e.validateFormats;e.validateFormats=!1,this.RULES=(0,Rw.getRules)(),id.call(this,Lw,e,"NOT SUPPORTED"),id.call(this,jw,e,"DEPRECATED","warn"),this._metaOpts=Hw.call(this),e.formats&&Vw.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&Fw.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),qw.call(this),e.validateFormats=i}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:r,schemaId:n}=this.opts,i=rd;n==="id"&&(i={...rd},i.id=i.$id,delete i.$id),r&&e&&this.addMetaSchema(i,i[n],!1)}defaultMeta(){let{meta:e,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[r]||e:void 0}validate(e,r){let n;if(typeof e=="string"){if(n=this.getSchema(e),!n)throw new Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);let i=n(r);return"$async"in n||(this.errors=n.errors),i}compile(e,r){let n=this._addSchema(e,r);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:n}=this.opts;return i.call(this,e,r);async function i(d,f){await s.call(this,d.$schema);let h=this._addSchema(d,f);return h.validate||o.call(this,h)}async function s(d){d&&!this.getSchema(d)&&await i.call(this,{$ref:d},!0)}async function o(d){try{return this._compileSchemaEnv(d)}catch(f){if(!(f instanceof od.default))throw f;return a.call(this,f),await l.call(this,f.missingSchema),o.call(this,d)}}function a({missingSchema:d,missingRef:f}){if(this.refs[d])throw new Error(`AnySchema ${d} is loaded but ${f} cannot be resolved`)}async function l(d){let f=await u.call(this,d);this.refs[d]||await s.call(this,f.$schema),this.refs[d]||this.addSchema(f,d,r)}async function u(d){let f=this._loading[d];if(f)return f;try{return await(this._loading[d]=n(d))}finally{delete this._loading[d]}}}addSchema(e,r,n,i=this.opts.validateSchema){if(Array.isArray(e)){for(let o of e)this.addSchema(o,void 0,n,i);return this}let s;if(typeof e=="object"){let{schemaId:o}=this.opts;if(s=e[o],s!==void 0&&typeof s!="string")throw new Error(`schema ${o} must be string`)}return r=(0,On.normalizeId)(r||s),this._checkUnique(r),this.schemas[r]=this._addSchema(e,n,r,i,!0),this}addMetaSchema(e,r,n=this.opts.validateSchema){return this.addSchema(e,r,!0,n),this}validateSchema(e,r){if(typeof e=="boolean")return!0;let n;if(n=e.$schema,n!==void 0&&typeof n!="string")throw new Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let i=this.validate(n,e);if(!i&&r){let s="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(s);else throw new Error(s)}return i}getSchema(e){let r;for(;typeof(r=sd.call(this,e))=="string";)e=r;if(r===void 0){let{schemaId:n}=this.opts,i=new Pn.SchemaEnv({schema:{},schemaId:n});if(r=Pn.resolveSchema.call(this,i,e),!r)return;this.refs[e]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=sd.call(this,e);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{let r=e;this._cache.delete(r);let n=e[this.opts.schemaId];return n&&(n=(0,On.normalizeId)(n),delete this.schemas[n],delete this.refs[n]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let r of e)this.addKeyword(r);return this}addKeyword(e,r){let n;if(typeof e=="string")n=e,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=n);else if(typeof e=="object"&&r===void 0){if(r=e,n=r.keyword,Array.isArray(n)&&!n.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(zw.call(this,n,r),!r)return(0,Ea.eachItem)(n,s=>Sa.call(this,s)),this;Kw.call(this,r);let i={...r,type:(0,Hi.getJSONTypes)(r.type),schemaType:(0,Hi.getJSONTypes)(r.schemaType)};return(0,Ea.eachItem)(n,i.type.length===0?s=>Sa.call(this,s,i):s=>i.type.forEach(o=>Sa.call(this,s,i,o))),this}getKeyword(e){let r=this.RULES.all[e];return typeof r=="object"?r.definition:!!r}removeKeyword(e){let{RULES:r}=this;delete r.keywords[e],delete r.all[e];for(let n of r.rules){let i=n.rules.findIndex(s=>s.keyword===e);i>=0&&n.rules.splice(i,1)}return this}addFormat(e,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[e]=r,this}errorsText(e=this.errors,{separator:r=", ",dataVar:n="data"}={}){return!e||e.length===0?"No errors":e.map(i=>`${n}${i.instancePath} ${i.message}`).reduce((i,s)=>i+r+s)}$dataMetaSchema(e,r){let n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let i of r){let s=i.split("/").slice(1),o=e;for(let a of s)o=o[a];for(let a in n){let l=n[a];if(typeof l!="object")continue;let{$data:u}=l.definition,d=o[a];u&&d&&(o[a]=cd(d))}}return e}_removeAllSchemas(e,r){for(let n in e){let i=e[n];(!r||r.test(n))&&(typeof i=="string"?delete e[n]:i&&!i.meta&&(this._cache.delete(i.schema),delete e[n]))}}_addSchema(e,r,n,i=this.opts.validateSchema,s=this.opts.addUsedSchema){let o,{schemaId:a}=this.opts;if(typeof e=="object")o=e[a];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof e!="boolean")throw new Error("schema must be object or boolean")}let l=this._cache.get(e);if(l!==void 0)return l;n=(0,On.normalizeId)(o||n);let u=On.getSchemaRefs.call(this,e,n);return l=new Pn.SchemaEnv({schema:e,schemaId:a,meta:r,baseId:n,localRefs:u}),this._cache.set(l.schema,l),s&&!n.startsWith("#")&&(n&&this._checkUnique(n),this.refs[n]=l),i&&this.validateSchema(e,!0),l}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):Pn.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let r=this.opts;this.opts=this._metaOpts;try{Pn.compileSchema.call(this,e)}finally{this.opts=r}}};An.ValidationError=Aw.default;An.MissingRefError=od.default;we.default=An;function id(t,e,r,n="error"){for(let i in t){let s=i;s in e&&this.logger[n](`${r}: option ${i}. ${t[s]}`)}}function sd(t){return t=(0,On.normalizeId)(t),this.schemas[t]||this.refs[t]}function qw(){let t=this.opts.schemas;if(t)if(Array.isArray(t))this.addSchema(t);else for(let e in t)this.addSchema(t[e],e)}function Vw(){for(let t in this.opts.formats){let e=this.opts.formats[t];e&&this.addFormat(t,e)}}function Fw(t){if(Array.isArray(t)){this.addVocabulary(t);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let e in t){let r=t[e];r.keyword||(r.keyword=e),this.addKeyword(r)}}function Hw(){let t={...this.opts};for(let e of Nw)delete t[e];return t}var Bw={log(){},warn(){},error(){}};function Uw(t){if(t===!1)return Bw;if(t===void 0)return console;if(t.log&&t.warn&&t.error)return t;throw new Error("logger must implement log, warn and error methods")}var Gw=/^[a-z_$][a-z0-9_$:-]*$/i;function zw(t,e){let{RULES:r}=this;if((0,Ea.eachItem)(t,n=>{if(r.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!Gw.test(n))throw new Error(`Keyword ${n} has invalid name`)}),!!e&&e.$data&&!("code"in e||"validate"in e))throw new Error('$data keyword must have "code" or "validate" function')}function Sa(t,e,r){var n;let i=e?.post;if(r&&i)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:s}=this,o=i?s.post:s.rules.find(({type:l})=>l===r);if(o||(o={type:r,rules:[]},s.rules.push(o)),s.keywords[t]=!0,!e)return;let a={keyword:t,definition:{...e,type:(0,Hi.getJSONTypes)(e.type),schemaType:(0,Hi.getJSONTypes)(e.schemaType)}};e.before?Ww.call(this,o,a,e.before):o.rules.push(a),s.all[t]=a,(n=e.implements)===null||n===void 0||n.forEach(l=>this.addKeyword(l))}function Ww(t,e,r){let n=t.rules.findIndex(i=>i.keyword===r);n>=0?t.rules.splice(n,0,e):(t.rules.push(e),this.logger.warn(`rule ${r} is not defined`))}function Kw(t){let{metaSchema:e}=t;e!==void 0&&(t.$data&&this.opts.$data&&(e=cd(e)),t.validateSchema=this.compile(e,!0))}var Jw={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function cd(t){return{anyOf:[t,Jw]}}});var ud=w($a=>{"use strict";Object.defineProperty($a,"__esModule",{value:!0});var Yw={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};$a.default=Yw});var Gi=w(ir=>{"use strict";Object.defineProperty(ir,"__esModule",{value:!0});ir.callRef=ir.getValidate=void 0;var Xw=Cn(),fd=Ke(),De=W(),Rr=We(),dd=kn(),Bi=X(),Qw={keyword:"$ref",schemaType:"string",code(t){let{gen:e,schema:r,it:n}=t,{baseId:i,schemaEnv:s,validateName:o,opts:a,self:l}=n,{root:u}=s;if((r==="#"||r==="#/")&&i===u.baseId)return f();let d=dd.resolveRef.call(l,u,i,r);if(d===void 0)throw new Xw.default(n.opts.uriResolver,i,r);if(d instanceof dd.SchemaEnv)return h(d);return m(d);function f(){if(s===u)return Ui(t,o,s,s.$async);let g=e.scopeValue("root",{ref:u});return Ui(t,(0,De._)`${g}.validate`,u,u.$async)}function h(g){let _=pd(t,g);Ui(t,_,g,g.$async)}function m(g){let _=e.scopeValue("schema",a.code.source===!0?{ref:g,code:(0,De.stringify)(g)}:{ref:g}),x=e.name("valid"),E=t.subschema({schema:g,dataTypes:[],schemaPath:De.nil,topSchemaRef:_,errSchemaPath:r},x);t.mergeEvaluated(E),t.ok(x)}}};function pd(t,e){let{gen:r}=t;return e.validate?r.scopeValue("validate",{ref:e.validate}):(0,De._)`${r.scopeValue("wrapper",{ref:e})}.validate`}ir.getValidate=pd;function Ui(t,e,r,n){let{gen:i,it:s}=t,{allErrors:o,schemaEnv:a,opts:l}=s,u=l.passContext?Rr.default.this:De.nil;n?d():f();function d(){if(!a.$async)throw new Error("async schema referenced by sync schema");let g=i.let("valid");i.try(()=>{i.code((0,De._)`await ${(0,fd.callValidateCode)(t,e,u)}`),m(e),o||i.assign(g,!0)},_=>{i.if((0,De._)`!(${_} instanceof ${s.ValidationError})`,()=>i.throw(_)),h(_),o||i.assign(g,!1)}),t.ok(g)}function f(){t.result((0,fd.callValidateCode)(t,e,u),()=>m(e),()=>h(e))}function h(g){let _=(0,De._)`${g}.errors`;i.assign(Rr.default.vErrors,(0,De._)`${Rr.default.vErrors} === null ? ${_} : ${Rr.default.vErrors}.concat(${_})`),i.assign(Rr.default.errors,(0,De._)`${Rr.default.vErrors}.length`)}function m(g){var _;if(!s.opts.unevaluated)return;let x=(_=r?.validate)===null||_===void 0?void 0:_.evaluated;if(s.props!==!0)if(x&&!x.dynamicProps)x.props!==void 0&&(s.props=Bi.mergeEvaluated.props(i,x.props,s.props));else{let E=i.var("props",(0,De._)`${g}.evaluated.props`);s.props=Bi.mergeEvaluated.props(i,E,s.props,De.Name)}if(s.items!==!0)if(x&&!x.dynamicItems)x.items!==void 0&&(s.items=Bi.mergeEvaluated.items(i,x.items,s.items));else{let E=i.var("items",(0,De._)`${g}.evaluated.items`);s.items=Bi.mergeEvaluated.items(i,E,s.items,De.Name)}}}ir.callRef=Ui;ir.default=Qw});var hd=w(Ca=>{"use strict";Object.defineProperty(Ca,"__esModule",{value:!0});var Zw=ud(),e0=Gi(),t0=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",Zw.default,e0.default];Ca.default=t0});var md=w(ka=>{"use strict";Object.defineProperty(ka,"__esModule",{value:!0});var zi=W(),Bt=zi.operators,Wi={maximum:{okStr:"<=",ok:Bt.LTE,fail:Bt.GT},minimum:{okStr:">=",ok:Bt.GTE,fail:Bt.LT},exclusiveMaximum:{okStr:"<",ok:Bt.LT,fail:Bt.GTE},exclusiveMinimum:{okStr:">",ok:Bt.GT,fail:Bt.LTE}},r0={message:({keyword:t,schemaCode:e})=>(0,zi.str)`must be ${Wi[t].okStr} ${e}`,params:({keyword:t,schemaCode:e})=>(0,zi._)`{comparison: ${Wi[t].okStr}, limit: ${e}}`},n0={keyword:Object.keys(Wi),type:"number",schemaType:"number",$data:!0,error:r0,code(t){let{keyword:e,data:r,schemaCode:n}=t;t.fail$data((0,zi._)`${r} ${Wi[e].fail} ${n} || isNaN(${r})`)}};ka.default=n0});var gd=w(xa=>{"use strict";Object.defineProperty(xa,"__esModule",{value:!0});var Rn=W(),i0={message:({schemaCode:t})=>(0,Rn.str)`must be multiple of ${t}`,params:({schemaCode:t})=>(0,Rn._)`{multipleOf: ${t}}`},s0={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:i0,code(t){let{gen:e,data:r,schemaCode:n,it:i}=t,s=i.opts.multipleOfPrecision,o=e.let("res"),a=s?(0,Rn._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:(0,Rn._)`${o} !== parseInt(${o})`;t.fail$data((0,Rn._)`(${n} === 0 || (${o} = ${r}/${n}, ${a}))`)}};xa.default=s0});var vd=w(Pa=>{"use strict";Object.defineProperty(Pa,"__esModule",{value:!0});function yd(t){let e=t.length,r=0,n=0,i;for(;n<e;)r++,i=t.charCodeAt(n++),i>=55296&&i<=56319&&n<e&&(i=t.charCodeAt(n),(i&64512)===56320&&n++);return r}Pa.default=yd;yd.code='require("ajv/dist/runtime/ucs2length").default'});var _d=w(Oa=>{"use strict";Object.defineProperty(Oa,"__esModule",{value:!0});var sr=W(),o0=X(),a0=vd(),c0={message({keyword:t,schemaCode:e}){let r=t==="maxLength"?"more":"fewer";return(0,sr.str)`must NOT have ${r} than ${e} characters`},params:({schemaCode:t})=>(0,sr._)`{limit: ${t}}`},l0={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:c0,code(t){let{keyword:e,data:r,schemaCode:n,it:i}=t,s=e==="maxLength"?sr.operators.GT:sr.operators.LT,o=i.opts.unicode===!1?(0,sr._)`${r}.length`:(0,sr._)`${(0,o0.useFunc)(t.gen,a0.default)}(${r})`;t.fail$data((0,sr._)`${o} ${s} ${n}`)}};Oa.default=l0});var wd=w(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});var u0=Ke(),f0=X(),Ir=W(),d0={message:({schemaCode:t})=>(0,Ir.str)`must match pattern "${t}"`,params:({schemaCode:t})=>(0,Ir._)`{pattern: ${t}}`},p0={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:d0,code(t){let{gen:e,data:r,$data:n,schema:i,schemaCode:s,it:o}=t,a=o.opts.unicodeRegExp?"u":"";if(n){let{regExp:l}=o.opts.code,u=l.code==="new RegExp"?(0,Ir._)`new RegExp`:(0,f0.useFunc)(e,l),d=e.let("valid");e.try(()=>e.assign(d,(0,Ir._)`${u}(${s}, ${a}).test(${r})`),()=>e.assign(d,!1)),t.fail$data((0,Ir._)`!${d}`)}else{let l=(0,u0.usePattern)(t,i);t.fail$data((0,Ir._)`!${l}.test(${r})`)}}};Aa.default=p0});var bd=w(Ra=>{"use strict";Object.defineProperty(Ra,"__esModule",{value:!0});var In=W(),h0={message({keyword:t,schemaCode:e}){let r=t==="maxProperties"?"more":"fewer";return(0,In.str)`must NOT have ${r} than ${e} properties`},params:({schemaCode:t})=>(0,In._)`{limit: ${t}}`},m0={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:h0,code(t){let{keyword:e,data:r,schemaCode:n}=t,i=e==="maxProperties"?In.operators.GT:In.operators.LT;t.fail$data((0,In._)`Object.keys(${r}).length ${i} ${n}`)}};Ra.default=m0});var Sd=w(Ia=>{"use strict";Object.defineProperty(Ia,"__esModule",{value:!0});var Tn=Ke(),Nn=W(),g0=X(),y0={message:({params:{missingProperty:t}})=>(0,Nn.str)`must have required property '${t}'`,params:({params:{missingProperty:t}})=>(0,Nn._)`{missingProperty: ${t}}`},v0={keyword:"required",type:"object",schemaType:"array",$data:!0,error:y0,code(t){let{gen:e,schema:r,schemaCode:n,data:i,$data:s,it:o}=t,{opts:a}=o;if(!s&&r.length===0)return;let l=r.length>=a.loopRequired;if(o.allErrors?u():d(),a.strictRequired){let m=t.parentSchema.properties,{definedProperties:g}=t.it;for(let _ of r)if(m?.[_]===void 0&&!g.has(_)){let x=o.schemaEnv.baseId+o.errSchemaPath,E=`required property "${_}" is not defined at "${x}" (strictRequired)`;(0,g0.checkStrictMode)(o,E,o.opts.strictRequired)}}function u(){if(l||s)t.block$data(Nn.nil,f);else for(let m of r)(0,Tn.checkReportMissingProp)(t,m)}function d(){let m=e.let("missing");if(l||s){let g=e.let("valid",!0);t.block$data(g,()=>h(m,g)),t.ok(g)}else e.if((0,Tn.checkMissingProp)(t,r,m)),(0,Tn.reportMissingProp)(t,m),e.else()}function f(){e.forOf("prop",n,m=>{t.setParams({missingProperty:m}),e.if((0,Tn.noPropertyInData)(e,i,m,a.ownProperties),()=>t.error())})}function h(m,g){t.setParams({missingProperty:m}),e.forOf(m,n,()=>{e.assign(g,(0,Tn.propertyInData)(e,i,m,a.ownProperties)),e.if((0,Nn.not)(g),()=>{t.error(),e.break()})},Nn.nil)}}};Ia.default=v0});var Ed=w(Ta=>{"use strict";Object.defineProperty(Ta,"__esModule",{value:!0});var Mn=W(),_0={message({keyword:t,schemaCode:e}){let r=t==="maxItems"?"more":"fewer";return(0,Mn.str)`must NOT have ${r} than ${e} items`},params:({schemaCode:t})=>(0,Mn._)`{limit: ${t}}`},w0={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:_0,code(t){let{keyword:e,data:r,schemaCode:n}=t,i=e==="maxItems"?Mn.operators.GT:Mn.operators.LT;t.fail$data((0,Mn._)`${r}.length ${i} ${n}`)}};Ta.default=w0});var Ki=w(Na=>{"use strict";Object.defineProperty(Na,"__esModule",{value:!0});var $d=na();$d.code='require("ajv/dist/runtime/equal").default';Na.default=$d});var Cd=w(La=>{"use strict";Object.defineProperty(La,"__esModule",{value:!0});var Ma=wn(),be=W(),b0=X(),S0=Ki(),E0={message:({params:{i:t,j:e}})=>(0,be.str)`must NOT have duplicate items (items ## ${e} and ${t} are identical)`,params:({params:{i:t,j:e}})=>(0,be._)`{i: ${t}, j: ${e}}`},$0={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:E0,code(t){let{gen:e,data:r,$data:n,schema:i,parentSchema:s,schemaCode:o,it:a}=t;if(!n&&!i)return;let l=e.let("valid"),u=s.items?(0,Ma.getSchemaTypes)(s.items):[];t.block$data(l,d,(0,be._)`${o} === false`),t.ok(l);function d(){let g=e.let("i",(0,be._)`${r}.length`),_=e.let("j");t.setParams({i:g,j:_}),e.assign(l,!0),e.if((0,be._)`${g} > 1`,()=>(f()?h:m)(g,_))}function f(){return u.length>0&&!u.some(g=>g==="object"||g==="array")}function h(g,_){let x=e.name("item"),E=(0,Ma.checkDataTypes)(u,x,a.opts.strictNumbers,Ma.DataType.Wrong),V=e.const("indices",(0,be._)`{}`);e.for((0,be._)`;${g}--;`,()=>{e.let(x,(0,be._)`${r}[${g}]`),e.if(E,(0,be._)`continue`),u.length>1&&e.if((0,be._)`typeof ${x} == "string"`,(0,be._)`${x} += "_"`),e.if((0,be._)`typeof ${V}[${x}] == "number"`,()=>{e.assign(_,(0,be._)`${V}[${x}]`),t.error(),e.assign(l,!1).break()}).code((0,be._)`${V}[${x}] = ${g}`)})}function m(g,_){let x=(0,b0.useFunc)(e,S0.default),E=e.name("outer");e.label(E).for((0,be._)`;${g}--;`,()=>e.for((0,be._)`${_} = ${g}; ${_}--;`,()=>e.if((0,be._)`${x}(${r}[${g}], ${r}[${_}])`,()=>{t.error(),e.assign(l,!1).break(E)})))}}};La.default=$0});var kd=w(Da=>{"use strict";Object.defineProperty(Da,"__esModule",{value:!0});var ja=W(),C0=X(),k0=Ki(),x0={message:"must be equal to constant",params:({schemaCode:t})=>(0,ja._)`{allowedValue: ${t}}`},P0={keyword:"const",$data:!0,error:x0,code(t){let{gen:e,data:r,$data:n,schemaCode:i,schema:s}=t;n||s&&typeof s=="object"?t.fail$data((0,ja._)`!${(0,C0.useFunc)(e,k0.default)}(${r}, ${i})`):t.fail((0,ja._)`${s} !== ${r}`)}};Da.default=P0});var xd=w(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});var Ln=W(),O0=X(),A0=Ki(),R0={message:"must be equal to one of the allowed values",params:({schemaCode:t})=>(0,Ln._)`{allowedValues: ${t}}`},I0={keyword:"enum",schemaType:"array",$data:!0,error:R0,code(t){let{gen:e,data:r,$data:n,schema:i,schemaCode:s,it:o}=t;if(!n&&i.length===0)throw new Error("enum must have non-empty array");let a=i.length>=o.opts.loopEnum,l,u=()=>l??(l=(0,O0.useFunc)(e,A0.default)),d;if(a||n)d=e.let("valid"),t.block$data(d,f);else{if(!Array.isArray(i))throw new Error("ajv implementation error");let m=e.const("vSchema",s);d=(0,Ln.or)(...i.map((g,_)=>h(m,_)))}t.pass(d);function f(){e.assign(d,!1),e.forOf("v",s,m=>e.if((0,Ln._)`${u()}(${r}, ${m})`,()=>e.assign(d,!0).break()))}function h(m,g){let _=i[g];return typeof _=="object"&&_!==null?(0,Ln._)`${u()}(${r}, ${m}[${g}])`:(0,Ln._)`${r} === ${_}`}}};qa.default=I0});var Pd=w(Va=>{"use strict";Object.defineProperty(Va,"__esModule",{value:!0});var T0=md(),N0=gd(),M0=_d(),L0=wd(),j0=bd(),D0=Sd(),q0=Ed(),V0=Cd(),F0=kd(),H0=xd(),B0=[T0.default,N0.default,M0.default,L0.default,j0.default,D0.default,q0.default,V0.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},F0.default,H0.default];Va.default=B0});var Ha=w(jn=>{"use strict";Object.defineProperty(jn,"__esModule",{value:!0});jn.validateAdditionalItems=void 0;var or=W(),Fa=X(),U0={message:({params:{len:t}})=>(0,or.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,or._)`{limit: ${t}}`},G0={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:U0,code(t){let{parentSchema:e,it:r}=t,{items:n}=e;if(!Array.isArray(n)){(0,Fa.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}Od(t,n)}};function Od(t,e){let{gen:r,schema:n,data:i,keyword:s,it:o}=t;o.items=!0;let a=r.const("len",(0,or._)`${i}.length`);if(n===!1)t.setParams({len:e.length}),t.pass((0,or._)`${a} <= ${e.length}`);else if(typeof n=="object"&&!(0,Fa.alwaysValidSchema)(o,n)){let u=r.var("valid",(0,or._)`${a} <= ${e.length}`);r.if((0,or.not)(u),()=>l(u)),t.ok(u)}function l(u){r.forRange("i",e.length,a,d=>{t.subschema({keyword:s,dataProp:d,dataPropType:Fa.Type.Num},u),o.allErrors||r.if((0,or.not)(u),()=>r.break())})}}jn.validateAdditionalItems=Od;jn.default=G0});var Ba=w(Dn=>{"use strict";Object.defineProperty(Dn,"__esModule",{value:!0});Dn.validateTuple=void 0;var Ad=W(),Ji=X(),z0=Ke(),W0={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(t){let{schema:e,it:r}=t;if(Array.isArray(e))return Rd(t,"additionalItems",e);r.items=!0,!(0,Ji.alwaysValidSchema)(r,e)&&t.ok((0,z0.validateArray)(t))}};function Rd(t,e,r=t.schema){let{gen:n,parentSchema:i,data:s,keyword:o,it:a}=t;d(i),a.opts.unevaluated&&r.length&&a.items!==!0&&(a.items=Ji.mergeEvaluated.items(n,r.length,a.items));let l=n.name("valid"),u=n.const("len",(0,Ad._)`${s}.length`);r.forEach((f,h)=>{(0,Ji.alwaysValidSchema)(a,f)||(n.if((0,Ad._)`${u} > ${h}`,()=>t.subschema({keyword:o,schemaProp:h,dataProp:h},l)),t.ok(l))});function d(f){let{opts:h,errSchemaPath:m}=a,g=r.length,_=g===f.minItems&&(g===f.maxItems||f[e]===!1);if(h.strictTuples&&!_){let x=`"${o}" is ${g}-tuple, but minItems or maxItems/${e} are not specified or different at path "${m}"`;(0,Ji.checkStrictMode)(a,x,h.strictTuples)}}}Dn.validateTuple=Rd;Dn.default=W0});var Id=w(Ua=>{"use strict";Object.defineProperty(Ua,"__esModule",{value:!0});var K0=Ba(),J0={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:t=>(0,K0.validateTuple)(t,"items")};Ua.default=J0});var Nd=w(Ga=>{"use strict";Object.defineProperty(Ga,"__esModule",{value:!0});var Td=W(),Y0=X(),X0=Ke(),Q0=Ha(),Z0={message:({params:{len:t}})=>(0,Td.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,Td._)`{limit: ${t}}`},e2={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:Z0,code(t){let{schema:e,parentSchema:r,it:n}=t,{prefixItems:i}=r;n.items=!0,!(0,Y0.alwaysValidSchema)(n,e)&&(i?(0,Q0.validateAdditionalItems)(t,i):t.ok((0,X0.validateArray)(t)))}};Ga.default=e2});var Md=w(za=>{"use strict";Object.defineProperty(za,"__esModule",{value:!0});var Ye=W(),Yi=X(),t2={message:({params:{min:t,max:e}})=>e===void 0?(0,Ye.str)`must contain at least ${t} valid item(s)`:(0,Ye.str)`must contain at least ${t} and no more than ${e} valid item(s)`,params:({params:{min:t,max:e}})=>e===void 0?(0,Ye._)`{minContains: ${t}}`:(0,Ye._)`{minContains: ${t}, maxContains: ${e}}`},r2={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:t2,code(t){let{gen:e,schema:r,parentSchema:n,data:i,it:s}=t,o,a,{minContains:l,maxContains:u}=n;s.opts.next?(o=l===void 0?1:l,a=u):o=1;let d=e.const("len",(0,Ye._)`${i}.length`);if(t.setParams({min:o,max:a}),a===void 0&&o===0){(0,Yi.checkStrictMode)(s,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&o>a){(0,Yi.checkStrictMode)(s,'"minContains" > "maxContains" is always invalid'),t.fail();return}if((0,Yi.alwaysValidSchema)(s,r)){let _=(0,Ye._)`${d} >= ${o}`;a!==void 0&&(_=(0,Ye._)`${_} && ${d} <= ${a}`),t.pass(_);return}s.items=!0;let f=e.name("valid");a===void 0&&o===1?m(f,()=>e.if(f,()=>e.break())):o===0?(e.let(f,!0),a!==void 0&&e.if((0,Ye._)`${i}.length > 0`,h)):(e.let(f,!1),h()),t.result(f,()=>t.reset());function h(){let _=e.name("_valid"),x=e.let("count",0);m(_,()=>e.if(_,()=>g(x)))}function m(_,x){e.forRange("i",0,d,E=>{t.subschema({keyword:"contains",dataProp:E,dataPropType:Yi.Type.Num,compositeRule:!0},_),x()})}function g(_){e.code((0,Ye._)`${_}++`),a===void 0?e.if((0,Ye._)`${_} >= ${o}`,()=>e.assign(f,!0).break()):(e.if((0,Ye._)`${_} > ${a}`,()=>e.assign(f,!1).break()),o===1?e.assign(f,!0):e.if((0,Ye._)`${_} >= ${o}`,()=>e.assign(f,!0)))}}};za.default=r2});var Xi=w(gt=>{"use strict";Object.defineProperty(gt,"__esModule",{value:!0});gt.validateSchemaDeps=gt.validatePropertyDeps=gt.error=void 0;var Wa=W(),n2=X(),qn=Ke();gt.error={message:({params:{property:t,depsCount:e,deps:r}})=>{let n=e===1?"property":"properties";return(0,Wa.str)`must have ${n} ${r} when property ${t} is present`},params:({params:{property:t,depsCount:e,deps:r,missingProperty:n}})=>(0,Wa._)`{property: ${t},
|
|
26
|
+
`),this.outputHelp({error:!0}));let n=r||{},i=n.exitCode||1,o=n.code||"commander.error";this._exit(i,o,e)}_parseOptionsEnv(){this.options.forEach(e=>{if(e.envVar&&e.envVar in ie.env){let r=e.attributeName();(this.getOptionValue(r)===void 0||["default","config","env"].includes(this.getOptionValueSource(r)))&&(e.required||e.optional?this.emit(`optionEnv:${e.name()}`,ie.env[e.envVar]):this.emit(`optionEnv:${e.name()}`))}})}_parseOptionsImplied(){let e=new Cy(this.options),r=n=>this.getOptionValue(n)!==void 0&&!["default","implied"].includes(this.getOptionValueSource(n));this.options.filter(n=>n.implied!==void 0&&r(n.attributeName())&&e.valueFromOption(this.getOptionValue(n.attributeName()),n)).forEach(n=>{Object.keys(n.implied).filter(i=>!r(i)).forEach(i=>{this.setOptionValueWithSource(i,n.implied[i],"implied")})})}missingArgument(e){let r=`error: missing required argument '${e}'`;this.error(r,{code:"commander.missingArgument"})}optionMissingArgument(e){let r=`error: option '${e.flags}' argument missing`;this.error(r,{code:"commander.optionMissingArgument"})}missingMandatoryOptionValue(e){let r=`error: required option '${e.flags}' not specified`;this.error(r,{code:"commander.missingMandatoryOptionValue"})}_conflictingOption(e,r){let n=s=>{let a=s.attributeName(),l=this.getOptionValue(a),u=this.options.find(f=>f.negate&&a===f.attributeName()),p=this.options.find(f=>!f.negate&&a===f.attributeName());return u&&(u.presetArg===void 0&&l===!1||u.presetArg!==void 0&&l===u.presetArg)?u:p||s},i=s=>{let a=n(s),l=a.attributeName();return this.getOptionValueSource(l)==="env"?`environment variable '${a.envVar}'`:`option '${a.flags}'`},o=`error: ${i(e)} cannot be used with ${i(r)}`;this.error(o,{code:"commander.conflictingOption"})}unknownOption(e){if(this._allowUnknownOption)return;let r="";if(e.startsWith("--")&&this._showSuggestionAfterError){let i=[],o=this;do{let s=o.createHelp().visibleOptions(o).filter(a=>a.long).map(a=>a.long);i=i.concat(s),o=o.parent}while(o&&!o._enablePositionalOptions);r=mu(e,i)}let n=`error: unknown option '${e}'${r}`;this.error(n,{code:"commander.unknownOption"})}_excessArguments(e){if(this._allowExcessArguments)return;let r=this.registeredArguments.length,n=r===1?"":"s",o=`error: too many arguments${this.parent?` for '${this.name()}'`:""}. Expected ${r} argument${n} but got ${e.length}.`;this.error(o,{code:"commander.excessArguments"})}unknownCommand(){let e=this.args[0],r="";if(this._showSuggestionAfterError){let i=[];this.createHelp().visibleCommands(this).forEach(o=>{i.push(o.name()),o.alias()&&i.push(o.alias())}),r=mu(e,i)}let n=`error: unknown command '${e}'${r}`;this.error(n,{code:"commander.unknownCommand"})}version(e,r,n){if(e===void 0)return this._version;this._version=e,r=r||"-V, --version",n=n||"output the version number";let i=this.createOption(r,n);return this._versionOptionName=i.attributeName(),this._registerOption(i),this.on("option:"+i.name(),()=>{this._outputConfiguration.writeOut(`${e}
|
|
27
|
+
`),this._exit(0,"commander.version",e)}),this}description(e,r){return e===void 0&&r===void 0?this._description:(this._description=e,r&&(this._argsDescription=r),this)}summary(e){return e===void 0?this._summary:(this._summary=e,this)}alias(e){if(e===void 0)return this._aliases[0];let r=this;if(this.commands.length!==0&&this.commands[this.commands.length-1]._executableHandler&&(r=this.commands[this.commands.length-1]),e===r._name)throw new Error("Command alias can't be the same as its name");let n=this.parent?._findCommand(e);if(n){let i=[n.name()].concat(n.aliases()).join("|");throw new Error(`cannot add alias '${e}' to command '${this.name()}' as already have command '${i}'`)}return r._aliases.push(e),this}aliases(e){return e===void 0?this._aliases:(e.forEach(r=>this.alias(r)),this)}usage(e){if(e===void 0){if(this._usage)return this._usage;let r=this.registeredArguments.map(n=>Ey(n));return[].concat(this.options.length||this._helpOption!==null?"[options]":[],this.commands.length?"[command]":[],this.registeredArguments.length?r:[]).join(" ")}return this._usage=e,this}name(e){return e===void 0?this._name:(this._name=e,this)}helpGroup(e){return e===void 0?this._helpGroupHeading??"":(this._helpGroupHeading=e,this)}commandsGroup(e){return e===void 0?this._defaultCommandGroup??"":(this._defaultCommandGroup=e,this)}optionsGroup(e){return e===void 0?this._defaultOptionGroup??"":(this._defaultOptionGroup=e,this)}_initOptionGroup(e){this._defaultOptionGroup&&!e.helpGroupHeading&&e.helpGroup(this._defaultOptionGroup)}_initCommandGroup(e){this._defaultCommandGroup&&!e.helpGroup()&&e.helpGroup(this._defaultCommandGroup)}nameFromFilename(e){return this._name=xt.basename(e,xt.extname(e)),this}executableDir(e){return e===void 0?this._executableDir:(this._executableDir=e,this)}helpInformation(e){let r=this.createHelp(),n=this._getOutputContext(e);r.prepareContext({error:n.error,helpWidth:n.helpWidth,outputHasColors:n.hasColors});let i=r.formatHelp(this,r);return n.hasColors?i:this._outputConfiguration.stripColor(i)}_getOutputContext(e){e=e||{};let r=!!e.error,n,i,o;return r?(n=a=>this._outputConfiguration.writeErr(a),i=this._outputConfiguration.getErrHasColors(),o=this._outputConfiguration.getErrHelpWidth()):(n=a=>this._outputConfiguration.writeOut(a),i=this._outputConfiguration.getOutHasColors(),o=this._outputConfiguration.getOutHelpWidth()),{error:r,write:a=>(i||(a=this._outputConfiguration.stripColor(a)),n(a)),hasColors:i,helpWidth:o}}outputHelp(e){let r;typeof e=="function"&&(r=e,e=void 0);let n=this._getOutputContext(e),i={error:n.error,write:n.write,command:this};this._getCommandAndAncestors().reverse().forEach(s=>s.emit("beforeAllHelp",i)),this.emit("beforeHelp",i);let o=this.helpInformation({error:n.error});if(r&&(o=r(o),typeof o!="string"&&!Buffer.isBuffer(o)))throw new Error("outputHelp callback must return a string or a Buffer");n.write(o),this._getHelpOption()?.long&&this.emit(this._getHelpOption().long),this.emit("afterHelp",i),this._getCommandAndAncestors().forEach(s=>s.emit("afterAllHelp",i))}helpOption(e,r){return typeof e=="boolean"?(e?(this._helpOption===null&&(this._helpOption=void 0),this._defaultOptionGroup&&this._initOptionGroup(this._getHelpOption())):this._helpOption=null,this):(this._helpOption=this.createOption(e??"-h, --help",r??"display help for command"),(e||r)&&this._initOptionGroup(this._helpOption),this)}_getHelpOption(){return this._helpOption===void 0&&this.helpOption(void 0,void 0),this._helpOption}addHelpOption(e){return this._helpOption=e,this._initOptionGroup(e),this}help(e){this.outputHelp(e);let r=Number(ie.exitCode??0);r===0&&e&&typeof e!="function"&&e.error&&(r=1),this._exit(r,"commander.help","(outputHelp)")}addHelpText(e,r){let n=["beforeAll","before","after","afterAll"];if(!n.includes(e))throw new Error(`Unexpected value for position to addHelpText.
|
|
28
|
+
Expecting one of '${n.join("', '")}'`);let i=`${e}Help`;return this.on(i,o=>{let s;typeof r=="function"?s=r({error:o.error,command:o.command}):s=r,s&&o.write(`${s}
|
|
29
|
+
`)}),this}_outputHelpIfRequested(e){let r=this._getHelpOption();r&&e.find(i=>r.is(i))&&(this.outputHelp(),this._exit(0,"commander.helpDisplayed","(outputHelp)"))}};function gu(t){return t.map(e=>{if(!e.startsWith("--inspect"))return e;let r,n="127.0.0.1",i="9229",o;return(o=e.match(/^(--inspect(-brk)?)$/))!==null?r=o[1]:(o=e.match(/^(--inspect(-brk|-port)?)=([^:]+)$/))!==null?(r=o[1],/^\d+$/.test(o[3])?i=o[3]:n=o[3]):(o=e.match(/^(--inspect(-brk|-port)?)=([^:]+):(\d+)$/))!==null&&(r=o[1],n=o[3],i=o[4]),r&&i!=="0"?`${r}=${n}:${parseInt(i)+1}`:e})}function Is(){if(ie.env.NO_COLOR||ie.env.FORCE_COLOR==="0"||ie.env.FORCE_COLOR==="false")return!1;if(ie.env.FORCE_COLOR||ie.env.CLICOLOR_FORCE!==void 0)return!0}Ts.Command=Rs;Ts.useColor=Is});var bu=w(Ue=>{var{Argument:vu}=Pi(),{Command:Ns}=yu(),{CommanderError:Py,InvalidArgumentError:_u}=ln(),{Help:ky}=$s(),{Option:wu}=ks();Ue.program=new Ns;Ue.createCommand=t=>new Ns(t);Ue.createOption=(t,e)=>new wu(t,e);Ue.createArgument=(t,e)=>new vu(t,e);Ue.Command=Ns;Ue.Option=wu;Ue.Argument=vu;Ue.Help=ky;Ue.CommanderError=Py;Ue.InvalidArgumentError=_u;Ue.InvalidOptionArgumentError=_u});var gn=w(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.regexpCode=re.getEsmExportName=re.getProperty=re.safeStringify=re.stringify=re.strConcat=re.addCodeArg=re.str=re._=re.nil=re._Code=re.Name=re.IDENTIFIER=re._CodeOrName=void 0;var hn=class{};re._CodeOrName=hn;re.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Qt=class extends hn{constructor(e){if(super(),!re.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};re.Name=Qt;var Ge=class extends hn{constructor(e){super(),this._items=typeof e=="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((r,n)=>`${r}${n}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((r,n)=>(n instanceof Qt&&(r[n.str]=(r[n.str]||0)+1),r),{})}};re._Code=Ge;re.nil=new Ge("");function pf(t,...e){let r=[t[0]],n=0;for(;n<e.length;)Us(r,e[n]),r.push(t[++n]);return new Ge(r)}re._=pf;var Bs=new Ge("+");function df(t,...e){let r=[mn(t[0])],n=0;for(;n<e.length;)r.push(Bs),Us(r,e[n]),r.push(Bs,mn(t[++n]));return sv(r),new Ge(r)}re.str=df;function Us(t,e){e instanceof Ge?t.push(...e._items):e instanceof Qt?t.push(e):t.push(lv(e))}re.addCodeArg=Us;function sv(t){let e=1;for(;e<t.length-1;){if(t[e]===Bs){let r=av(t[e-1],t[e+1]);if(r!==void 0){t.splice(e-1,3,r);continue}t[e++]="+"}e++}}function av(t,e){if(e==='""')return t;if(t==='""')return e;if(typeof t=="string")return e instanceof Qt||t[t.length-1]!=='"'?void 0:typeof e!="string"?`${t.slice(0,-1)}${e}"`:e[0]==='"'?t.slice(0,-1)+e.slice(1):void 0;if(typeof e=="string"&&e[0]==='"'&&!(t instanceof Qt))return`"${t}${e.slice(1)}`}function cv(t,e){return e.emptyStr()?t:t.emptyStr()?e:df`${t}${e}`}re.strConcat=cv;function lv(t){return typeof t=="number"||typeof t=="boolean"||t===null?t:mn(Array.isArray(t)?t.join(","):t)}function uv(t){return new Ge(mn(t))}re.stringify=uv;function mn(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}re.safeStringify=mn;function fv(t){return typeof t=="string"&&re.IDENTIFIER.test(t)?new Ge(`.${t}`):pf`[${t}]`}re.getProperty=fv;function pv(t){if(typeof t=="string"&&re.IDENTIFIER.test(t))return new Ge(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)}re.getEsmExportName=pv;function dv(t){return new Ge(t.toString())}re.regexpCode=dv});var zs=w(Le=>{"use strict";Object.defineProperty(Le,"__esModule",{value:!0});Le.ValueScope=Le.ValueScopeName=Le.Scope=Le.varKinds=Le.UsedValueState=void 0;var Me=gn(),Gs=class extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}},Ii;(function(t){t[t.Started=0]="Started",t[t.Completed=1]="Completed"})(Ii||(Le.UsedValueState=Ii={}));Le.varKinds={const:new Me.Name("const"),let:new Me.Name("let"),var:new Me.Name("var")};var Ti=class{constructor({prefixes:e,parent:r}={}){this._names={},this._prefixes=e,this._parent=r}toName(e){return e instanceof Me.Name?e:this.name(e)}name(e){return new Me.Name(this._newName(e))}_newName(e){let r=this._names[e]||this._nameGroup(e);return`${e}${r.index++}`}_nameGroup(e){var r,n;if(!((n=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||n===void 0)&&n.has(e)||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}};Le.Scope=Ti;var Ni=class extends Me.Name{constructor(e,r){super(r),this.prefix=e}setValue(e,{property:r,itemIndex:n}){this.value=e,this.scopePath=(0,Me._)`.${new Me.Name(r)}[${n}]`}};Le.ValueScopeName=Ni;var hv=(0,Me._)`\n`,Ws=class extends Ti{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?hv:Me.nil}}get(){return this._scope}name(e){return new Ni(e,this._newName(e))}value(e,r){var n;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let i=this.toName(e),{prefix:o}=i,s=(n=r.key)!==null&&n!==void 0?n:r.ref,a=this._values[o];if(a){let p=a.get(s);if(p)return p}else a=this._values[o]=new Map;a.set(s,i);let l=this._scope[o]||(this._scope[o]=[]),u=l.length;return l[u]=r.ref,i.setValue(r,{property:o,itemIndex:u}),i}getValue(e,r){let n=this._values[e];if(n)return n.get(r)}scopeRefs(e,r=this._values){return this._reduceValues(r,n=>{if(n.scopePath===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return(0,Me._)`${e}${n.scopePath}`})}scopeCode(e=this._values,r,n){return this._reduceValues(e,i=>{if(i.value===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return i.value.code},r,n)}_reduceValues(e,r,n={},i){let o=Me.nil;for(let s in e){let a=e[s];if(!a)continue;let l=n[s]=n[s]||new Map;a.forEach(u=>{if(l.has(u))return;l.set(u,Ii.Started);let p=r(u);if(p){let f=this.opts.es5?Le.varKinds.var:Le.varKinds.const;o=(0,Me._)`${o}${f} ${u} = ${p};${this.opts._n}`}else if(p=i?.(u))o=(0,Me._)`${o}${p}${this.opts._n}`;else throw new Gs(u);l.set(u,Ii.Completed)})}return o}};Le.ValueScope=Ws});var z=w(J=>{"use strict";Object.defineProperty(J,"__esModule",{value:!0});J.or=J.and=J.not=J.CodeGen=J.operators=J.varKinds=J.ValueScopeName=J.ValueScope=J.Scope=J.Name=J.regexpCode=J.stringify=J.getProperty=J.nil=J.strConcat=J.str=J._=void 0;var ee=gn(),it=zs(),Lt=gn();Object.defineProperty(J,"_",{enumerable:!0,get:function(){return Lt._}});Object.defineProperty(J,"str",{enumerable:!0,get:function(){return Lt.str}});Object.defineProperty(J,"strConcat",{enumerable:!0,get:function(){return Lt.strConcat}});Object.defineProperty(J,"nil",{enumerable:!0,get:function(){return Lt.nil}});Object.defineProperty(J,"getProperty",{enumerable:!0,get:function(){return Lt.getProperty}});Object.defineProperty(J,"stringify",{enumerable:!0,get:function(){return Lt.stringify}});Object.defineProperty(J,"regexpCode",{enumerable:!0,get:function(){return Lt.regexpCode}});Object.defineProperty(J,"Name",{enumerable:!0,get:function(){return Lt.Name}});var Di=zs();Object.defineProperty(J,"Scope",{enumerable:!0,get:function(){return Di.Scope}});Object.defineProperty(J,"ValueScope",{enumerable:!0,get:function(){return Di.ValueScope}});Object.defineProperty(J,"ValueScopeName",{enumerable:!0,get:function(){return Di.ValueScopeName}});Object.defineProperty(J,"varKinds",{enumerable:!0,get:function(){return Di.varKinds}});J.operators={GT:new ee._Code(">"),GTE:new ee._Code(">="),LT:new ee._Code("<"),LTE:new ee._Code("<="),EQ:new ee._Code("==="),NEQ:new ee._Code("!=="),NOT:new ee._Code("!"),OR:new ee._Code("||"),AND:new ee._Code("&&"),ADD:new ee._Code("+")};var Pt=class{optimizeNodes(){return this}optimizeNames(e,r){return this}},Ks=class extends Pt{constructor(e,r,n){super(),this.varKind=e,this.name=r,this.rhs=n}render({es5:e,_n:r}){let n=e?it.varKinds.var:this.varKind,i=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${i};`+r}optimizeNames(e,r){if(e[this.name.str])return this.rhs&&(this.rhs=xr(this.rhs,e,r)),this}get names(){return this.rhs instanceof ee._CodeOrName?this.rhs.names:{}}},Mi=class extends Pt{constructor(e,r,n){super(),this.lhs=e,this.rhs=r,this.sideEffects=n}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,r){if(!(this.lhs instanceof ee.Name&&!e[this.lhs.str]&&!this.sideEffects))return this.rhs=xr(this.rhs,e,r),this}get names(){let e=this.lhs instanceof ee.Name?{}:{...this.lhs.names};return ji(e,this.rhs)}},Js=class extends Mi{constructor(e,r,n,i){super(e,n,i),this.op=r}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}},Ys=class extends Pt{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}},Xs=class extends Pt{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}},Qs=class extends Pt{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}},Zs=class extends Pt{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,r){return this.code=xr(this.code,e,r),this}get names(){return this.code instanceof ee._CodeOrName?this.code.names:{}}},yn=class extends Pt{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((r,n)=>r+n.render(e),"")}optimizeNodes(){let{nodes:e}=this,r=e.length;for(;r--;){let n=e[r].optimizeNodes();Array.isArray(n)?e.splice(r,1,...n):n?e[r]=n:e.splice(r,1)}return e.length>0?this:void 0}optimizeNames(e,r){let{nodes:n}=this,i=n.length;for(;i--;){let o=n[i];o.optimizeNames(e,r)||(mv(e,o.names),n.splice(i,1))}return n.length>0?this:void 0}get names(){return this.nodes.reduce((e,r)=>tr(e,r.names),{})}},kt=class extends yn{render(e){return"{"+e._n+super.render(e)+"}"+e._n}},ea=class extends yn{},$r=class extends kt{};$r.kind="else";var Zt=class t extends kt{constructor(e,r){super(r),this.condition=e}render(e){let r=`if(${this.condition})`+super.render(e);return this.else&&(r+="else "+this.else.render(e)),r}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let r=this.else;if(r){let n=r.optimizeNodes();r=this.else=Array.isArray(n)?new $r(n):n}if(r)return e===!1?r instanceof t?r:r.nodes:this.nodes.length?this:new t(hf(e),r instanceof t?[r]:r.nodes);if(!(e===!1||!this.nodes.length))return this}optimizeNames(e,r){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(e,r),!!(super.optimizeNames(e,r)||this.else))return this.condition=xr(this.condition,e,r),this}get names(){let e=super.names;return ji(e,this.condition),this.else&&tr(e,this.else.names),e}};Zt.kind="if";var er=class extends kt{};er.kind="for";var ta=class extends er{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,r){if(super.optimizeNames(e,r))return this.iteration=xr(this.iteration,e,r),this}get names(){return tr(super.names,this.iteration.names)}},ra=class extends er{constructor(e,r,n,i){super(),this.varKind=e,this.name=r,this.from=n,this.to=i}render(e){let r=e.es5?it.varKinds.var:this.varKind,{name:n,from:i,to:o}=this;return`for(${r} ${n}=${i}; ${n}<${o}; ${n}++)`+super.render(e)}get names(){let e=ji(super.names,this.from);return ji(e,this.to)}},Li=class extends er{constructor(e,r,n,i){super(),this.loop=e,this.varKind=r,this.name=n,this.iterable=i}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,r){if(super.optimizeNames(e,r))return this.iterable=xr(this.iterable,e,r),this}get names(){return tr(super.names,this.iterable.names)}},vn=class extends kt{constructor(e,r,n){super(),this.name=e,this.args=r,this.async=n}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}};vn.kind="func";var _n=class extends yn{render(e){return"return "+super.render(e)}};_n.kind="return";var na=class extends kt{render(e){let r="try"+super.render(e);return this.catch&&(r+=this.catch.render(e)),this.finally&&(r+=this.finally.render(e)),r}optimizeNodes(){var e,r;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(e,r){var n,i;return super.optimizeNames(e,r),(n=this.catch)===null||n===void 0||n.optimizeNames(e,r),(i=this.finally)===null||i===void 0||i.optimizeNames(e,r),this}get names(){let e=super.names;return this.catch&&tr(e,this.catch.names),this.finally&&tr(e,this.finally.names),e}},wn=class extends kt{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}};wn.kind="catch";var bn=class extends kt{render(e){return"finally"+super.render(e)}};bn.kind="finally";var ia=class{constructor(e,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
|
|
30
|
+
`:""},this._extScope=e,this._scope=new it.Scope({parent:e}),this._nodes=[new ea]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,r){let n=this._extScope.value(e,r);return(this._values[n.prefix]||(this._values[n.prefix]=new Set)).add(n),n}getScopeValue(e,r){return this._extScope.getValue(e,r)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,r,n,i){let o=this._scope.toName(r);return n!==void 0&&i&&(this._constants[o.str]=n),this._leafNode(new Ks(e,o,n)),o}const(e,r,n){return this._def(it.varKinds.const,e,r,n)}let(e,r,n){return this._def(it.varKinds.let,e,r,n)}var(e,r,n){return this._def(it.varKinds.var,e,r,n)}assign(e,r,n){return this._leafNode(new Mi(e,r,n))}add(e,r){return this._leafNode(new Js(e,J.operators.ADD,r))}code(e){return typeof e=="function"?e():e!==ee.nil&&this._leafNode(new Zs(e)),this}object(...e){let r=["{"];for(let[n,i]of e)r.length>1&&r.push(","),r.push(n),(n!==i||this.opts.es5)&&(r.push(":"),(0,ee.addCodeArg)(r,i));return r.push("}"),new ee._Code(r)}if(e,r,n){if(this._blockNode(new Zt(e)),r&&n)this.code(r).else().code(n).endIf();else if(r)this.code(r).endIf();else if(n)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new Zt(e))}else(){return this._elseNode(new $r)}endIf(){return this._endBlockNode(Zt,$r)}_for(e,r){return this._blockNode(e),r&&this.code(r).endFor(),this}for(e,r){return this._for(new ta(e),r)}forRange(e,r,n,i,o=this.opts.es5?it.varKinds.var:it.varKinds.let){let s=this._scope.toName(e);return this._for(new ra(o,s,r,n),()=>i(s))}forOf(e,r,n,i=it.varKinds.const){let o=this._scope.toName(e);if(this.opts.es5){let s=r instanceof ee.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,ee._)`${s}.length`,a=>{this.var(o,(0,ee._)`${s}[${a}]`),n(o)})}return this._for(new Li("of",i,o,r),()=>n(o))}forIn(e,r,n,i=this.opts.es5?it.varKinds.var:it.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,(0,ee._)`Object.keys(${r})`,n);let o=this._scope.toName(e);return this._for(new Li("in",i,o,r),()=>n(o))}endFor(){return this._endBlockNode(er)}label(e){return this._leafNode(new Ys(e))}break(e){return this._leafNode(new Xs(e))}return(e){let r=new _n;if(this._blockNode(r),this.code(e),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(_n)}try(e,r,n){if(!r&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');let i=new na;if(this._blockNode(i),this.code(e),r){let o=this.name("e");this._currNode=i.catch=new wn(o),r(o)}return n&&(this._currNode=i.finally=new bn,this.code(n)),this._endBlockNode(wn,bn)}throw(e){return this._leafNode(new Qs(e))}block(e,r){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(r),this}endBlock(e){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let n=this._nodes.length-r;if(n<0||e!==void 0&&n!==e)throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${e} expected`);return this._nodes.length=r,this}func(e,r=ee.nil,n,i){return this._blockNode(new vn(e,r,n)),i&&this.code(i).endFunc(),this}endFunc(){return this._endBlockNode(vn)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,r){let n=this._currNode;if(n instanceof e||r&&n instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${e.kind}/${r.kind}`:e.kind}"`)}_elseNode(e){let r=this._currNode;if(!(r instanceof Zt))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let r=this._nodes;r[r.length-1]=e}};J.CodeGen=ia;function tr(t,e){for(let r in e)t[r]=(t[r]||0)+(e[r]||0);return t}function ji(t,e){return e instanceof ee._CodeOrName?tr(t,e.names):t}function xr(t,e,r){if(t instanceof ee.Name)return n(t);if(!i(t))return t;return new ee._Code(t._items.reduce((o,s)=>(s instanceof ee.Name&&(s=n(s)),s instanceof ee._Code?o.push(...s._items):o.push(s),o),[]));function n(o){let s=r[o.str];return s===void 0||e[o.str]!==1?o:(delete e[o.str],s)}function i(o){return o instanceof ee._Code&&o._items.some(s=>s instanceof ee.Name&&e[s.str]===1&&r[s.str]!==void 0)}}function mv(t,e){for(let r in e)t[r]=(t[r]||0)-(e[r]||0)}function hf(t){return typeof t=="boolean"||typeof t=="number"||t===null?!t:(0,ee._)`!${oa(t)}`}J.not=hf;var gv=mf(J.operators.AND);function yv(...t){return t.reduce(gv)}J.and=yv;var vv=mf(J.operators.OR);function _v(...t){return t.reduce(vv)}J.or=_v;function mf(t){return(e,r)=>e===ee.nil?r:r===ee.nil?e:(0,ee._)`${oa(e)} ${t} ${oa(r)}`}function oa(t){return t instanceof ee.Name?t:(0,ee._)`(${t})`}});var X=w(Y=>{"use strict";Object.defineProperty(Y,"__esModule",{value:!0});Y.checkStrictMode=Y.getErrorPath=Y.Type=Y.useFunc=Y.setEvaluated=Y.evaluatedPropsToName=Y.mergeEvaluated=Y.eachItem=Y.unescapeJsonPointer=Y.escapeJsonPointer=Y.escapeFragment=Y.unescapeFragment=Y.schemaRefOrVal=Y.schemaHasRulesButRef=Y.schemaHasRules=Y.checkUnknownRules=Y.alwaysValidSchema=Y.toHash=void 0;var ce=z(),wv=gn();function bv(t){let e={};for(let r of t)e[r]=!0;return e}Y.toHash=bv;function Sv(t,e){return typeof e=="boolean"?e:Object.keys(e).length===0?!0:(vf(t,e),!_f(e,t.self.RULES.all))}Y.alwaysValidSchema=Sv;function vf(t,e=t.schema){let{opts:r,self:n}=t;if(!r.strictSchema||typeof e=="boolean")return;let i=n.RULES.keywords;for(let o in e)i[o]||Sf(t,`unknown keyword: "${o}"`)}Y.checkUnknownRules=vf;function _f(t,e){if(typeof t=="boolean")return!t;for(let r in t)if(e[r])return!0;return!1}Y.schemaHasRules=_f;function Ev(t,e){if(typeof t=="boolean")return!t;for(let r in t)if(r!=="$ref"&&e.all[r])return!0;return!1}Y.schemaHasRulesButRef=Ev;function $v({topSchemaRef:t,schemaPath:e},r,n,i){if(!i){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,ce._)`${r}`}return(0,ce._)`${t}${e}${(0,ce.getProperty)(n)}`}Y.schemaRefOrVal=$v;function xv(t){return wf(decodeURIComponent(t))}Y.unescapeFragment=xv;function Cv(t){return encodeURIComponent(aa(t))}Y.escapeFragment=Cv;function aa(t){return typeof t=="number"?`${t}`:t.replace(/~/g,"~0").replace(/\//g,"~1")}Y.escapeJsonPointer=aa;function wf(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}Y.unescapeJsonPointer=wf;function Pv(t,e){if(Array.isArray(t))for(let r of t)e(r);else e(t)}Y.eachItem=Pv;function gf({mergeNames:t,mergeToName:e,mergeValues:r,resultToName:n}){return(i,o,s,a)=>{let l=s===void 0?o:s instanceof ce.Name?(o instanceof ce.Name?t(i,o,s):e(i,o,s),s):o instanceof ce.Name?(e(i,s,o),o):r(o,s);return a===ce.Name&&!(l instanceof ce.Name)?n(i,l):l}}Y.mergeEvaluated={props:gf({mergeNames:(t,e,r)=>t.if((0,ce._)`${r} !== true && ${e} !== undefined`,()=>{t.if((0,ce._)`${e} === true`,()=>t.assign(r,!0),()=>t.assign(r,(0,ce._)`${r} || {}`).code((0,ce._)`Object.assign(${r}, ${e})`))}),mergeToName:(t,e,r)=>t.if((0,ce._)`${r} !== true`,()=>{e===!0?t.assign(r,!0):(t.assign(r,(0,ce._)`${r} || {}`),ca(t,r,e))}),mergeValues:(t,e)=>t===!0?!0:{...t,...e},resultToName:bf}),items:gf({mergeNames:(t,e,r)=>t.if((0,ce._)`${r} !== true && ${e} !== undefined`,()=>t.assign(r,(0,ce._)`${e} === true ? true : ${r} > ${e} ? ${r} : ${e}`)),mergeToName:(t,e,r)=>t.if((0,ce._)`${r} !== true`,()=>t.assign(r,e===!0?!0:(0,ce._)`${r} > ${e} ? ${r} : ${e}`)),mergeValues:(t,e)=>t===!0?!0:Math.max(t,e),resultToName:(t,e)=>t.var("items",e)})};function bf(t,e){if(e===!0)return t.var("props",!0);let r=t.var("props",(0,ce._)`{}`);return e!==void 0&&ca(t,r,e),r}Y.evaluatedPropsToName=bf;function ca(t,e,r){Object.keys(r).forEach(n=>t.assign((0,ce._)`${e}${(0,ce.getProperty)(n)}`,!0))}Y.setEvaluated=ca;var yf={};function kv(t,e){return t.scopeValue("func",{ref:e,code:yf[e.code]||(yf[e.code]=new wv._Code(e.code))})}Y.useFunc=kv;var sa;(function(t){t[t.Num=0]="Num",t[t.Str=1]="Str"})(sa||(Y.Type=sa={}));function Av(t,e,r){if(t instanceof ce.Name){let n=e===sa.Num;return r?n?(0,ce._)`"[" + ${t} + "]"`:(0,ce._)`"['" + ${t} + "']"`:n?(0,ce._)`"/" + ${t}`:(0,ce._)`"/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,ce.getProperty)(t).toString():"/"+aa(t)}Y.getErrorPath=Av;function Sf(t,e,r=t.opts.strictSchema){if(r){if(e=`strict mode: ${e}`,r===!0)throw new Error(e);t.self.logger.warn(e)}}Y.checkStrictMode=Sf});var We=w(la=>{"use strict";Object.defineProperty(la,"__esModule",{value:!0});var Ce=z(),Ov={data:new Ce.Name("data"),valCxt:new Ce.Name("valCxt"),instancePath:new Ce.Name("instancePath"),parentData:new Ce.Name("parentData"),parentDataProperty:new Ce.Name("parentDataProperty"),rootData:new Ce.Name("rootData"),dynamicAnchors:new Ce.Name("dynamicAnchors"),vErrors:new Ce.Name("vErrors"),errors:new Ce.Name("errors"),this:new Ce.Name("this"),self:new Ce.Name("self"),scope:new Ce.Name("scope"),json:new Ce.Name("json"),jsonPos:new Ce.Name("jsonPos"),jsonLen:new Ce.Name("jsonLen"),jsonPart:new Ce.Name("jsonPart")};la.default=Ov});var Sn=w(Pe=>{"use strict";Object.defineProperty(Pe,"__esModule",{value:!0});Pe.extendErrors=Pe.resetErrorsCount=Pe.reportExtraError=Pe.reportError=Pe.keyword$DataError=Pe.keywordError=void 0;var te=z(),Vi=X(),Re=We();Pe.keywordError={message:({keyword:t})=>(0,te.str)`must pass "${t}" keyword validation`};Pe.keyword$DataError={message:({keyword:t,schemaType:e})=>e?(0,te.str)`"${t}" keyword must be ${e} ($data)`:(0,te.str)`"${t}" keyword is invalid ($data)`};function Rv(t,e=Pe.keywordError,r,n){let{it:i}=t,{gen:o,compositeRule:s,allErrors:a}=i,l=xf(t,e,r);n??(s||a)?Ef(o,l):$f(i,(0,te._)`[${l}]`)}Pe.reportError=Rv;function Iv(t,e=Pe.keywordError,r){let{it:n}=t,{gen:i,compositeRule:o,allErrors:s}=n,a=xf(t,e,r);Ef(i,a),o||s||$f(n,Re.default.vErrors)}Pe.reportExtraError=Iv;function Tv(t,e){t.assign(Re.default.errors,e),t.if((0,te._)`${Re.default.vErrors} !== null`,()=>t.if(e,()=>t.assign((0,te._)`${Re.default.vErrors}.length`,e),()=>t.assign(Re.default.vErrors,null)))}Pe.resetErrorsCount=Tv;function Nv({gen:t,keyword:e,schemaValue:r,data:n,errsCount:i,it:o}){if(i===void 0)throw new Error("ajv implementation error");let s=t.name("err");t.forRange("i",i,Re.default.errors,a=>{t.const(s,(0,te._)`${Re.default.vErrors}[${a}]`),t.if((0,te._)`${s}.instancePath === undefined`,()=>t.assign((0,te._)`${s}.instancePath`,(0,te.strConcat)(Re.default.instancePath,o.errorPath))),t.assign((0,te._)`${s}.schemaPath`,(0,te.str)`${o.errSchemaPath}/${e}`),o.opts.verbose&&(t.assign((0,te._)`${s}.schema`,r),t.assign((0,te._)`${s}.data`,n))})}Pe.extendErrors=Nv;function Ef(t,e){let r=t.const("err",e);t.if((0,te._)`${Re.default.vErrors} === null`,()=>t.assign(Re.default.vErrors,(0,te._)`[${r}]`),(0,te._)`${Re.default.vErrors}.push(${r})`),t.code((0,te._)`${Re.default.errors}++`)}function $f(t,e){let{gen:r,validateName:n,schemaEnv:i}=t;i.$async?r.throw((0,te._)`new ${t.ValidationError}(${e})`):(r.assign((0,te._)`${n}.errors`,e),r.return(!1))}var rr={keyword:new te.Name("keyword"),schemaPath:new te.Name("schemaPath"),params:new te.Name("params"),propertyName:new te.Name("propertyName"),message:new te.Name("message"),schema:new te.Name("schema"),parentSchema:new te.Name("parentSchema")};function xf(t,e,r){let{createErrors:n}=t.it;return n===!1?(0,te._)`{}`:Mv(t,e,r)}function Mv(t,e,r={}){let{gen:n,it:i}=t,o=[Lv(i,r),jv(t,r)];return Dv(t,e,o),n.object(...o)}function Lv({errorPath:t},{instancePath:e}){let r=e?(0,te.str)`${t}${(0,Vi.getErrorPath)(e,Vi.Type.Str)}`:t;return[Re.default.instancePath,(0,te.strConcat)(Re.default.instancePath,r)]}function jv({keyword:t,it:{errSchemaPath:e}},{schemaPath:r,parentSchema:n}){let i=n?e:(0,te.str)`${e}/${t}`;return r&&(i=(0,te.str)`${i}${(0,Vi.getErrorPath)(r,Vi.Type.Str)}`),[rr.schemaPath,i]}function Dv(t,{params:e,message:r},n){let{keyword:i,data:o,schemaValue:s,it:a}=t,{opts:l,propertyName:u,topSchemaRef:p,schemaPath:f}=a;n.push([rr.keyword,i],[rr.params,typeof e=="function"?e(t):e||(0,te._)`{}`]),l.messages&&n.push([rr.message,typeof r=="function"?r(t):r]),l.verbose&&n.push([rr.schema,s],[rr.parentSchema,(0,te._)`${p}${f}`],[Re.default.data,o]),u&&n.push([rr.propertyName,u])}});var Pf=w(Cr=>{"use strict";Object.defineProperty(Cr,"__esModule",{value:!0});Cr.boolOrEmptySchema=Cr.topBoolOrEmptySchema=void 0;var Vv=Sn(),qv=z(),Fv=We(),Hv={message:"boolean schema is false"};function Bv(t){let{gen:e,schema:r,validateName:n}=t;r===!1?Cf(t,!1):typeof r=="object"&&r.$async===!0?e.return(Fv.default.data):(e.assign((0,qv._)`${n}.errors`,null),e.return(!0))}Cr.topBoolOrEmptySchema=Bv;function Uv(t,e){let{gen:r,schema:n}=t;n===!1?(r.var(e,!1),Cf(t)):r.var(e,!0)}Cr.boolOrEmptySchema=Uv;function Cf(t,e){let{gen:r,data:n}=t,i={gen:r,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:t};(0,Vv.reportError)(i,Hv,void 0,e)}});var ua=w(Pr=>{"use strict";Object.defineProperty(Pr,"__esModule",{value:!0});Pr.getRules=Pr.isJSONType=void 0;var Gv=["string","number","integer","boolean","null","object","array"],Wv=new Set(Gv);function zv(t){return typeof t=="string"&&Wv.has(t)}Pr.isJSONType=zv;function Kv(){let t={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...t,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},t.number,t.string,t.array,t.object],post:{rules:[]},all:{},keywords:{}}}Pr.getRules=Kv});var fa=w(jt=>{"use strict";Object.defineProperty(jt,"__esModule",{value:!0});jt.shouldUseRule=jt.shouldUseGroup=jt.schemaHasRulesForType=void 0;function Jv({schema:t,self:e},r){let n=e.RULES.types[r];return n&&n!==!0&&kf(t,n)}jt.schemaHasRulesForType=Jv;function kf(t,e){return e.rules.some(r=>Af(t,r))}jt.shouldUseGroup=kf;function Af(t,e){var r;return t[e.keyword]!==void 0||((r=e.definition.implements)===null||r===void 0?void 0:r.some(n=>t[n]!==void 0))}jt.shouldUseRule=Af});var En=w(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke.reportTypeError=ke.checkDataTypes=ke.checkDataType=ke.coerceAndCheckDataType=ke.getJSONTypes=ke.getSchemaTypes=ke.DataType=void 0;var Yv=ua(),Xv=fa(),Qv=Sn(),K=z(),Of=X(),kr;(function(t){t[t.Correct=0]="Correct",t[t.Wrong=1]="Wrong"})(kr||(ke.DataType=kr={}));function Zv(t){let e=Rf(t.type);if(e.includes("null")){if(t.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!e.length&&t.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');t.nullable===!0&&e.push("null")}return e}ke.getSchemaTypes=Zv;function Rf(t){let e=Array.isArray(t)?t:t?[t]:[];if(e.every(Yv.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}ke.getJSONTypes=Rf;function e_(t,e){let{gen:r,data:n,opts:i}=t,o=t_(e,i.coerceTypes),s=e.length>0&&!(o.length===0&&e.length===1&&(0,Xv.schemaHasRulesForType)(t,e[0]));if(s){let a=da(e,n,i.strictNumbers,kr.Wrong);r.if(a,()=>{o.length?r_(t,e,o):ha(t)})}return s}ke.coerceAndCheckDataType=e_;var If=new Set(["string","number","integer","boolean","null"]);function t_(t,e){return e?t.filter(r=>If.has(r)||e==="array"&&r==="array"):[]}function r_(t,e,r){let{gen:n,data:i,opts:o}=t,s=n.let("dataType",(0,K._)`typeof ${i}`),a=n.let("coerced",(0,K._)`undefined`);o.coerceTypes==="array"&&n.if((0,K._)`${s} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>n.assign(i,(0,K._)`${i}[0]`).assign(s,(0,K._)`typeof ${i}`).if(da(e,i,o.strictNumbers),()=>n.assign(a,i))),n.if((0,K._)`${a} !== undefined`);for(let u of r)(If.has(u)||u==="array"&&o.coerceTypes==="array")&&l(u);n.else(),ha(t),n.endIf(),n.if((0,K._)`${a} !== undefined`,()=>{n.assign(i,a),n_(t,a)});function l(u){switch(u){case"string":n.elseIf((0,K._)`${s} == "number" || ${s} == "boolean"`).assign(a,(0,K._)`"" + ${i}`).elseIf((0,K._)`${i} === null`).assign(a,(0,K._)`""`);return;case"number":n.elseIf((0,K._)`${s} == "boolean" || ${i} === null
|
|
31
|
+
|| (${s} == "string" && ${i} && ${i} == +${i})`).assign(a,(0,K._)`+${i}`);return;case"integer":n.elseIf((0,K._)`${s} === "boolean" || ${i} === null
|
|
32
|
+
|| (${s} === "string" && ${i} && ${i} == +${i} && !(${i} % 1))`).assign(a,(0,K._)`+${i}`);return;case"boolean":n.elseIf((0,K._)`${i} === "false" || ${i} === 0 || ${i} === null`).assign(a,!1).elseIf((0,K._)`${i} === "true" || ${i} === 1`).assign(a,!0);return;case"null":n.elseIf((0,K._)`${i} === "" || ${i} === 0 || ${i} === false`),n.assign(a,null);return;case"array":n.elseIf((0,K._)`${s} === "string" || ${s} === "number"
|
|
33
|
+
|| ${s} === "boolean" || ${i} === null`).assign(a,(0,K._)`[${i}]`)}}}function n_({gen:t,parentData:e,parentDataProperty:r},n){t.if((0,K._)`${e} !== undefined`,()=>t.assign((0,K._)`${e}[${r}]`,n))}function pa(t,e,r,n=kr.Correct){let i=n===kr.Correct?K.operators.EQ:K.operators.NEQ,o;switch(t){case"null":return(0,K._)`${e} ${i} null`;case"array":o=(0,K._)`Array.isArray(${e})`;break;case"object":o=(0,K._)`${e} && typeof ${e} == "object" && !Array.isArray(${e})`;break;case"integer":o=s((0,K._)`!(${e} % 1) && !isNaN(${e})`);break;case"number":o=s();break;default:return(0,K._)`typeof ${e} ${i} ${t}`}return n===kr.Correct?o:(0,K.not)(o);function s(a=K.nil){return(0,K.and)((0,K._)`typeof ${e} == "number"`,a,r?(0,K._)`isFinite(${e})`:K.nil)}}ke.checkDataType=pa;function da(t,e,r,n){if(t.length===1)return pa(t[0],e,r,n);let i,o=(0,Of.toHash)(t);if(o.array&&o.object){let s=(0,K._)`typeof ${e} != "object"`;i=o.null?s:(0,K._)`!${e} || ${s}`,delete o.null,delete o.array,delete o.object}else i=K.nil;o.number&&delete o.integer;for(let s in o)i=(0,K.and)(i,pa(s,e,r,n));return i}ke.checkDataTypes=da;var i_={message:({schema:t})=>`must be ${t}`,params:({schema:t,schemaValue:e})=>typeof t=="string"?(0,K._)`{type: ${t}}`:(0,K._)`{type: ${e}}`};function ha(t){let e=o_(t);(0,Qv.reportError)(e,i_)}ke.reportTypeError=ha;function o_(t){let{gen:e,data:r,schema:n}=t,i=(0,Of.schemaRefOrVal)(t,n,"type");return{gen:e,keyword:"type",data:r,schema:n.type,schemaCode:i,schemaValue:i,parentSchema:n,params:{},it:t}}});var Nf=w(qi=>{"use strict";Object.defineProperty(qi,"__esModule",{value:!0});qi.assignDefaults=void 0;var Ar=z(),s_=X();function a_(t,e){let{properties:r,items:n}=t.schema;if(e==="object"&&r)for(let i in r)Tf(t,i,r[i].default);else e==="array"&&Array.isArray(n)&&n.forEach((i,o)=>Tf(t,o,i.default))}qi.assignDefaults=a_;function Tf(t,e,r){let{gen:n,compositeRule:i,data:o,opts:s}=t;if(r===void 0)return;let a=(0,Ar._)`${o}${(0,Ar.getProperty)(e)}`;if(i){(0,s_.checkStrictMode)(t,`default is ignored for: ${a}`);return}let l=(0,Ar._)`${a} === undefined`;s.useDefaults==="empty"&&(l=(0,Ar._)`${l} || ${a} === null || ${a} === ""`),n.if(l,(0,Ar._)`${a} = ${(0,Ar.stringify)(r)}`)}});var ze=w(ae=>{"use strict";Object.defineProperty(ae,"__esModule",{value:!0});ae.validateUnion=ae.validateArray=ae.usePattern=ae.callValidateCode=ae.schemaProperties=ae.allSchemaProperties=ae.noPropertyInData=ae.propertyInData=ae.isOwnProperty=ae.hasPropFunc=ae.reportMissingProp=ae.checkMissingProp=ae.checkReportMissingProp=void 0;var ue=z(),ma=X(),Dt=We(),c_=X();function l_(t,e){let{gen:r,data:n,it:i}=t;r.if(ya(r,n,e,i.opts.ownProperties),()=>{t.setParams({missingProperty:(0,ue._)`${e}`},!0),t.error()})}ae.checkReportMissingProp=l_;function u_({gen:t,data:e,it:{opts:r}},n,i){return(0,ue.or)(...n.map(o=>(0,ue.and)(ya(t,e,o,r.ownProperties),(0,ue._)`${i} = ${o}`)))}ae.checkMissingProp=u_;function f_(t,e){t.setParams({missingProperty:e},!0),t.error()}ae.reportMissingProp=f_;function Mf(t){return t.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,ue._)`Object.prototype.hasOwnProperty`})}ae.hasPropFunc=Mf;function ga(t,e,r){return(0,ue._)`${Mf(t)}.call(${e}, ${r})`}ae.isOwnProperty=ga;function p_(t,e,r,n){let i=(0,ue._)`${e}${(0,ue.getProperty)(r)} !== undefined`;return n?(0,ue._)`${i} && ${ga(t,e,r)}`:i}ae.propertyInData=p_;function ya(t,e,r,n){let i=(0,ue._)`${e}${(0,ue.getProperty)(r)} === undefined`;return n?(0,ue.or)(i,(0,ue.not)(ga(t,e,r))):i}ae.noPropertyInData=ya;function Lf(t){return t?Object.keys(t).filter(e=>e!=="__proto__"):[]}ae.allSchemaProperties=Lf;function d_(t,e){return Lf(e).filter(r=>!(0,ma.alwaysValidSchema)(t,e[r]))}ae.schemaProperties=d_;function h_({schemaCode:t,data:e,it:{gen:r,topSchemaRef:n,schemaPath:i,errorPath:o},it:s},a,l,u){let p=u?(0,ue._)`${t}, ${e}, ${n}${i}`:e,f=[[Dt.default.instancePath,(0,ue.strConcat)(Dt.default.instancePath,o)],[Dt.default.parentData,s.parentData],[Dt.default.parentDataProperty,s.parentDataProperty],[Dt.default.rootData,Dt.default.rootData]];s.opts.dynamicRef&&f.push([Dt.default.dynamicAnchors,Dt.default.dynamicAnchors]);let h=(0,ue._)`${p}, ${r.object(...f)}`;return l!==ue.nil?(0,ue._)`${a}.call(${l}, ${h})`:(0,ue._)`${a}(${h})`}ae.callValidateCode=h_;var m_=(0,ue._)`new RegExp`;function g_({gen:t,it:{opts:e}},r){let n=e.unicodeRegExp?"u":"",{regExp:i}=e.code,o=i(r,n);return t.scopeValue("pattern",{key:o.toString(),ref:o,code:(0,ue._)`${i.code==="new RegExp"?m_:(0,c_.useFunc)(t,i)}(${r}, ${n})`})}ae.usePattern=g_;function y_(t){let{gen:e,data:r,keyword:n,it:i}=t,o=e.name("valid");if(i.allErrors){let a=e.let("valid",!0);return s(()=>e.assign(a,!1)),a}return e.var(o,!0),s(()=>e.break()),o;function s(a){let l=e.const("len",(0,ue._)`${r}.length`);e.forRange("i",0,l,u=>{t.subschema({keyword:n,dataProp:u,dataPropType:ma.Type.Num},o),e.if((0,ue.not)(o),a)})}}ae.validateArray=y_;function v_(t){let{gen:e,schema:r,keyword:n,it:i}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(l=>(0,ma.alwaysValidSchema)(i,l))&&!i.opts.unevaluated)return;let s=e.let("valid",!1),a=e.name("_valid");e.block(()=>r.forEach((l,u)=>{let p=t.subschema({keyword:n,schemaProp:u,compositeRule:!0},a);e.assign(s,(0,ue._)`${s} || ${a}`),t.mergeValidEvaluated(p,a)||e.if((0,ue.not)(s))})),t.result(s,()=>t.reset(),()=>t.error(!0))}ae.validateUnion=v_});var Vf=w(ft=>{"use strict";Object.defineProperty(ft,"__esModule",{value:!0});ft.validateKeywordUsage=ft.validSchemaType=ft.funcKeywordCode=ft.macroKeywordCode=void 0;var Ie=z(),nr=We(),__=ze(),w_=Sn();function b_(t,e){let{gen:r,keyword:n,schema:i,parentSchema:o,it:s}=t,a=e.macro.call(s.self,i,o,s),l=Df(r,n,a);s.opts.validateSchema!==!1&&s.self.validateSchema(a,!0);let u=r.name("valid");t.subschema({schema:a,schemaPath:Ie.nil,errSchemaPath:`${s.errSchemaPath}/${n}`,topSchemaRef:l,compositeRule:!0},u),t.pass(u,()=>t.error(!0))}ft.macroKeywordCode=b_;function S_(t,e){var r;let{gen:n,keyword:i,schema:o,parentSchema:s,$data:a,it:l}=t;$_(l,e);let u=!a&&e.compile?e.compile.call(l.self,o,s,l):e.validate,p=Df(n,i,u),f=n.let("valid");t.block$data(f,h),t.ok((r=e.valid)!==null&&r!==void 0?r:f);function h(){if(e.errors===!1)v(),e.modifying&&jf(t),P(()=>t.error());else{let b=e.async?m():g();e.modifying&&jf(t),P(()=>E_(t,b))}}function m(){let b=n.let("ruleErrs",null);return n.try(()=>v((0,Ie._)`await `),j=>n.assign(f,!1).if((0,Ie._)`${j} instanceof ${l.ValidationError}`,()=>n.assign(b,(0,Ie._)`${j}.errors`),()=>n.throw(j))),b}function g(){let b=(0,Ie._)`${p}.errors`;return n.assign(b,null),v(Ie.nil),b}function v(b=e.async?(0,Ie._)`await `:Ie.nil){let j=l.opts.passContext?nr.default.this:nr.default.self,B=!("compile"in e&&!a||e.schema===!1);n.assign(f,(0,Ie._)`${b}${(0,__.callValidateCode)(t,p,j,B)}`,e.modifying)}function P(b){var j;n.if((0,Ie.not)((j=e.valid)!==null&&j!==void 0?j:f),b)}}ft.funcKeywordCode=S_;function jf(t){let{gen:e,data:r,it:n}=t;e.if(n.parentData,()=>e.assign(r,(0,Ie._)`${n.parentData}[${n.parentDataProperty}]`))}function E_(t,e){let{gen:r}=t;r.if((0,Ie._)`Array.isArray(${e})`,()=>{r.assign(nr.default.vErrors,(0,Ie._)`${nr.default.vErrors} === null ? ${e} : ${nr.default.vErrors}.concat(${e})`).assign(nr.default.errors,(0,Ie._)`${nr.default.vErrors}.length`),(0,w_.extendErrors)(t)},()=>t.error())}function $_({schemaEnv:t},e){if(e.async&&!t.$async)throw new Error("async keyword in sync schema")}function Df(t,e,r){if(r===void 0)throw new Error(`keyword "${e}" failed to compile`);return t.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,Ie.stringify)(r)})}function x_(t,e,r=!1){return!e.length||e.some(n=>n==="array"?Array.isArray(t):n==="object"?t&&typeof t=="object"&&!Array.isArray(t):typeof t==n||r&&typeof t>"u")}ft.validSchemaType=x_;function C_({schema:t,opts:e,self:r,errSchemaPath:n},i,o){if(Array.isArray(i.keyword)?!i.keyword.includes(o):i.keyword!==o)throw new Error("ajv implementation error");let s=i.dependencies;if(s?.some(a=>!Object.prototype.hasOwnProperty.call(t,a)))throw new Error(`parent schema must have dependencies of ${o}: ${s.join(",")}`);if(i.validateSchema&&!i.validateSchema(t[o])){let l=`keyword "${o}" value is invalid at path "${n}": `+r.errorsText(i.validateSchema.errors);if(e.validateSchema==="log")r.logger.error(l);else throw new Error(l)}}ft.validateKeywordUsage=C_});var Ff=w(Vt=>{"use strict";Object.defineProperty(Vt,"__esModule",{value:!0});Vt.extendSubschemaMode=Vt.extendSubschemaData=Vt.getSubschema=void 0;var pt=z(),qf=X();function P_(t,{keyword:e,schemaProp:r,schema:n,schemaPath:i,errSchemaPath:o,topSchemaRef:s}){if(e!==void 0&&n!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(e!==void 0){let a=t.schema[e];return r===void 0?{schema:a,schemaPath:(0,pt._)`${t.schemaPath}${(0,pt.getProperty)(e)}`,errSchemaPath:`${t.errSchemaPath}/${e}`}:{schema:a[r],schemaPath:(0,pt._)`${t.schemaPath}${(0,pt.getProperty)(e)}${(0,pt.getProperty)(r)}`,errSchemaPath:`${t.errSchemaPath}/${e}/${(0,qf.escapeFragment)(r)}`}}if(n!==void 0){if(i===void 0||o===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:i,topSchemaRef:s,errSchemaPath:o}}throw new Error('either "keyword" or "schema" must be passed')}Vt.getSubschema=P_;function k_(t,e,{dataProp:r,dataPropType:n,data:i,dataTypes:o,propertyName:s}){if(i!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=e;if(r!==void 0){let{errorPath:u,dataPathArr:p,opts:f}=e,h=a.let("data",(0,pt._)`${e.data}${(0,pt.getProperty)(r)}`,!0);l(h),t.errorPath=(0,pt.str)`${u}${(0,qf.getErrorPath)(r,n,f.jsPropertySyntax)}`,t.parentDataProperty=(0,pt._)`${r}`,t.dataPathArr=[...p,t.parentDataProperty]}if(i!==void 0){let u=i instanceof pt.Name?i:a.let("data",i,!0);l(u),s!==void 0&&(t.propertyName=s)}o&&(t.dataTypes=o);function l(u){t.data=u,t.dataLevel=e.dataLevel+1,t.dataTypes=[],e.definedProperties=new Set,t.parentData=e.data,t.dataNames=[...e.dataNames,u]}}Vt.extendSubschemaData=k_;function A_(t,{jtdDiscriminator:e,jtdMetadata:r,compositeRule:n,createErrors:i,allErrors:o}){n!==void 0&&(t.compositeRule=n),i!==void 0&&(t.createErrors=i),o!==void 0&&(t.allErrors=o),t.jtdDiscriminator=e,t.jtdMetadata=r}Vt.extendSubschemaMode=A_});var va=w((XP,Hf)=>{"use strict";Hf.exports=function t(e,r){if(e===r)return!0;if(e&&r&&typeof e=="object"&&typeof r=="object"){if(e.constructor!==r.constructor)return!1;var n,i,o;if(Array.isArray(e)){if(n=e.length,n!=r.length)return!1;for(i=n;i--!==0;)if(!t(e[i],r[i]))return!1;return!0}if(e.constructor===RegExp)return e.source===r.source&&e.flags===r.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===r.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===r.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(r).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(r,o[i]))return!1;for(i=n;i--!==0;){var s=o[i];if(!t(e[s],r[s]))return!1}return!0}return e!==e&&r!==r}});var Uf=w((QP,Bf)=>{"use strict";var qt=Bf.exports=function(t,e,r){typeof e=="function"&&(r=e,e={}),r=e.cb||r;var n=typeof r=="function"?r:r.pre||function(){},i=r.post||function(){};Fi(e,n,i,t,"",t)};qt.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};qt.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};qt.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};qt.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function Fi(t,e,r,n,i,o,s,a,l,u){if(n&&typeof n=="object"&&!Array.isArray(n)){e(n,i,o,s,a,l,u);for(var p in n){var f=n[p];if(Array.isArray(f)){if(p in qt.arrayKeywords)for(var h=0;h<f.length;h++)Fi(t,e,r,f[h],i+"/"+p+"/"+h,o,i,p,n,h)}else if(p in qt.propsKeywords){if(f&&typeof f=="object")for(var m in f)Fi(t,e,r,f[m],i+"/"+p+"/"+O_(m),o,i,p,n,m)}else(p in qt.keywords||t.allKeys&&!(p in qt.skipKeywords))&&Fi(t,e,r,f,i+"/"+p,o,i,p,n)}r(n,i,o,s,a,l,u)}}function O_(t){return t.replace(/~/g,"~0").replace(/\//g,"~1")}});var $n=w(je=>{"use strict";Object.defineProperty(je,"__esModule",{value:!0});je.getSchemaRefs=je.resolveUrl=je.normalizeId=je._getFullPath=je.getFullPath=je.inlineRef=void 0;var R_=X(),I_=va(),T_=Uf(),N_=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function M_(t,e=!0){return typeof t=="boolean"?!0:e===!0?!_a(t):e?Gf(t)<=e:!1}je.inlineRef=M_;var L_=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function _a(t){for(let e in t){if(L_.has(e))return!0;let r=t[e];if(Array.isArray(r)&&r.some(_a)||typeof r=="object"&&_a(r))return!0}return!1}function Gf(t){let e=0;for(let r in t){if(r==="$ref")return 1/0;if(e++,!N_.has(r)&&(typeof t[r]=="object"&&(0,R_.eachItem)(t[r],n=>e+=Gf(n)),e===1/0))return 1/0}return e}function Wf(t,e="",r){r!==!1&&(e=Or(e));let n=t.parse(e);return zf(t,n)}je.getFullPath=Wf;function zf(t,e){return t.serialize(e).split("#")[0]+"#"}je._getFullPath=zf;var j_=/#\/?$/;function Or(t){return t?t.replace(j_,""):""}je.normalizeId=Or;function D_(t,e,r){return r=Or(r),t.resolve(e,r)}je.resolveUrl=D_;var V_=/^[a-z_][-a-z0-9._]*$/i;function q_(t,e){if(typeof t=="boolean")return{};let{schemaId:r,uriResolver:n}=this.opts,i=Or(t[r]||e),o={"":i},s=Wf(n,i,!1),a={},l=new Set;return T_(t,{allKeys:!0},(f,h,m,g)=>{if(g===void 0)return;let v=s+h,P=o[g];typeof f[r]=="string"&&(P=b.call(this,f[r])),j.call(this,f.$anchor),j.call(this,f.$dynamicAnchor),o[h]=P;function b(B){let L=this.opts.uriResolver.resolve;if(B=Or(P?L(P,B):B),l.has(B))throw p(B);l.add(B);let T=this.refs[B];return typeof T=="string"&&(T=this.refs[T]),typeof T=="object"?u(f,T.schema,B):B!==Or(v)&&(B[0]==="#"?(u(f,a[B],B),a[B]=f):this.refs[B]=v),B}function j(B){if(typeof B=="string"){if(!V_.test(B))throw new Error(`invalid anchor "${B}"`);b.call(this,`#${B}`)}}}),a;function u(f,h,m){if(h!==void 0&&!I_(f,h))throw p(m)}function p(f){return new Error(`reference "${f}" resolves to more than one schema`)}}je.getSchemaRefs=q_});var Pn=w(Ft=>{"use strict";Object.defineProperty(Ft,"__esModule",{value:!0});Ft.getData=Ft.KeywordCxt=Ft.validateFunctionCode=void 0;var Qf=Pf(),Kf=En(),ba=fa(),Hi=En(),F_=Nf(),Cn=Vf(),wa=Ff(),q=z(),W=We(),H_=$n(),At=X(),xn=Sn();function B_(t){if(tp(t)&&(rp(t),ep(t))){W_(t);return}Zf(t,()=>(0,Qf.topBoolOrEmptySchema)(t))}Ft.validateFunctionCode=B_;function Zf({gen:t,validateName:e,schema:r,schemaEnv:n,opts:i},o){i.code.es5?t.func(e,(0,q._)`${W.default.data}, ${W.default.valCxt}`,n.$async,()=>{t.code((0,q._)`"use strict"; ${Jf(r,i)}`),G_(t,i),t.code(o)}):t.func(e,(0,q._)`${W.default.data}, ${U_(i)}`,n.$async,()=>t.code(Jf(r,i)).code(o))}function U_(t){return(0,q._)`{${W.default.instancePath}="", ${W.default.parentData}, ${W.default.parentDataProperty}, ${W.default.rootData}=${W.default.data}${t.dynamicRef?(0,q._)`, ${W.default.dynamicAnchors}={}`:q.nil}}={}`}function G_(t,e){t.if(W.default.valCxt,()=>{t.var(W.default.instancePath,(0,q._)`${W.default.valCxt}.${W.default.instancePath}`),t.var(W.default.parentData,(0,q._)`${W.default.valCxt}.${W.default.parentData}`),t.var(W.default.parentDataProperty,(0,q._)`${W.default.valCxt}.${W.default.parentDataProperty}`),t.var(W.default.rootData,(0,q._)`${W.default.valCxt}.${W.default.rootData}`),e.dynamicRef&&t.var(W.default.dynamicAnchors,(0,q._)`${W.default.valCxt}.${W.default.dynamicAnchors}`)},()=>{t.var(W.default.instancePath,(0,q._)`""`),t.var(W.default.parentData,(0,q._)`undefined`),t.var(W.default.parentDataProperty,(0,q._)`undefined`),t.var(W.default.rootData,W.default.data),e.dynamicRef&&t.var(W.default.dynamicAnchors,(0,q._)`{}`)})}function W_(t){let{schema:e,opts:r,gen:n}=t;Zf(t,()=>{r.$comment&&e.$comment&&ip(t),X_(t),n.let(W.default.vErrors,null),n.let(W.default.errors,0),r.unevaluated&&z_(t),np(t),ew(t)})}function z_(t){let{gen:e,validateName:r}=t;t.evaluated=e.const("evaluated",(0,q._)`${r}.evaluated`),e.if((0,q._)`${t.evaluated}.dynamicProps`,()=>e.assign((0,q._)`${t.evaluated}.props`,(0,q._)`undefined`)),e.if((0,q._)`${t.evaluated}.dynamicItems`,()=>e.assign((0,q._)`${t.evaluated}.items`,(0,q._)`undefined`))}function Jf(t,e){let r=typeof t=="object"&&t[e.schemaId];return r&&(e.code.source||e.code.process)?(0,q._)`/*# sourceURL=${r} */`:q.nil}function K_(t,e){if(tp(t)&&(rp(t),ep(t))){J_(t,e);return}(0,Qf.boolOrEmptySchema)(t,e)}function ep({schema:t,self:e}){if(typeof t=="boolean")return!t;for(let r in t)if(e.RULES.all[r])return!0;return!1}function tp(t){return typeof t.schema!="boolean"}function J_(t,e){let{schema:r,gen:n,opts:i}=t;i.$comment&&r.$comment&&ip(t),Q_(t),Z_(t);let o=n.const("_errs",W.default.errors);np(t,o),n.var(e,(0,q._)`${o} === ${W.default.errors}`)}function rp(t){(0,At.checkUnknownRules)(t),Y_(t)}function np(t,e){if(t.opts.jtd)return Yf(t,[],!1,e);let r=(0,Kf.getSchemaTypes)(t.schema),n=(0,Kf.coerceAndCheckDataType)(t,r);Yf(t,r,!n,e)}function Y_(t){let{schema:e,errSchemaPath:r,opts:n,self:i}=t;e.$ref&&n.ignoreKeywordsWithRef&&(0,At.schemaHasRulesButRef)(e,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function X_(t){let{schema:e,opts:r}=t;e.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,At.checkStrictMode)(t,"default is ignored in the schema root")}function Q_(t){let e=t.schema[t.opts.schemaId];e&&(t.baseId=(0,H_.resolveUrl)(t.opts.uriResolver,t.baseId,e))}function Z_(t){if(t.schema.$async&&!t.schemaEnv.$async)throw new Error("async schema in sync schema")}function ip({gen:t,schemaEnv:e,schema:r,errSchemaPath:n,opts:i}){let o=r.$comment;if(i.$comment===!0)t.code((0,q._)`${W.default.self}.logger.log(${o})`);else if(typeof i.$comment=="function"){let s=(0,q.str)`${n}/$comment`,a=t.scopeValue("root",{ref:e.root});t.code((0,q._)`${W.default.self}.opts.$comment(${o}, ${s}, ${a}.schema)`)}}function ew(t){let{gen:e,schemaEnv:r,validateName:n,ValidationError:i,opts:o}=t;r.$async?e.if((0,q._)`${W.default.errors} === 0`,()=>e.return(W.default.data),()=>e.throw((0,q._)`new ${i}(${W.default.vErrors})`)):(e.assign((0,q._)`${n}.errors`,W.default.vErrors),o.unevaluated&&tw(t),e.return((0,q._)`${W.default.errors} === 0`))}function tw({gen:t,evaluated:e,props:r,items:n}){r instanceof q.Name&&t.assign((0,q._)`${e}.props`,r),n instanceof q.Name&&t.assign((0,q._)`${e}.items`,n)}function Yf(t,e,r,n){let{gen:i,schema:o,data:s,allErrors:a,opts:l,self:u}=t,{RULES:p}=u;if(o.$ref&&(l.ignoreKeywordsWithRef||!(0,At.schemaHasRulesButRef)(o,p))){i.block(()=>sp(t,"$ref",p.all.$ref.definition));return}l.jtd||rw(t,e),i.block(()=>{for(let h of p.rules)f(h);f(p.post)});function f(h){(0,ba.shouldUseGroup)(o,h)&&(h.type?(i.if((0,Hi.checkDataType)(h.type,s,l.strictNumbers)),Xf(t,h),e.length===1&&e[0]===h.type&&r&&(i.else(),(0,Hi.reportTypeError)(t)),i.endIf()):Xf(t,h),a||i.if((0,q._)`${W.default.errors} === ${n||0}`))}}function Xf(t,e){let{gen:r,schema:n,opts:{useDefaults:i}}=t;i&&(0,F_.assignDefaults)(t,e.type),r.block(()=>{for(let o of e.rules)(0,ba.shouldUseRule)(n,o)&&sp(t,o.keyword,o.definition,e.type)})}function rw(t,e){t.schemaEnv.meta||!t.opts.strictTypes||(nw(t,e),t.opts.allowUnionTypes||iw(t,e),ow(t,t.dataTypes))}function nw(t,e){if(e.length){if(!t.dataTypes.length){t.dataTypes=e;return}e.forEach(r=>{op(t.dataTypes,r)||Sa(t,`type "${r}" not allowed by context "${t.dataTypes.join(",")}"`)}),aw(t,e)}}function iw(t,e){e.length>1&&!(e.length===2&&e.includes("null"))&&Sa(t,"use allowUnionTypes to allow union type keyword")}function ow(t,e){let r=t.self.RULES.all;for(let n in r){let i=r[n];if(typeof i=="object"&&(0,ba.shouldUseRule)(t.schema,i)){let{type:o}=i.definition;o.length&&!o.some(s=>sw(e,s))&&Sa(t,`missing type "${o.join(",")}" for keyword "${n}"`)}}}function sw(t,e){return t.includes(e)||e==="number"&&t.includes("integer")}function op(t,e){return t.includes(e)||e==="integer"&&t.includes("number")}function aw(t,e){let r=[];for(let n of t.dataTypes)op(e,n)?r.push(n):e.includes("integer")&&n==="number"&&r.push("integer");t.dataTypes=r}function Sa(t,e){let r=t.schemaEnv.baseId+t.errSchemaPath;e+=` at "${r}" (strictTypes)`,(0,At.checkStrictMode)(t,e,t.opts.strictTypes)}var Bi=class{constructor(e,r,n){if((0,Cn.validateKeywordUsage)(e,r,n),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=n,this.data=e.data,this.schema=e.schema[n],this.$data=r.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,At.schemaRefOrVal)(e,this.schema,n,this.$data),this.schemaType=r.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=r,this.$data)this.schemaCode=e.gen.const("vSchema",ap(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,Cn.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${n} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=e.gen.const("_errs",W.default.errors))}result(e,r,n){this.failResult((0,q.not)(e),r,n)}failResult(e,r,n){this.gen.if(e),n?n():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,r){this.failResult((0,q.not)(e),void 0,r)}fail(e){if(e===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:r}=this;this.fail((0,q._)`${r} !== undefined && (${(0,q.or)(this.invalid$data(),e)})`)}error(e,r,n){if(r){this.setParams(r),this._error(e,n),this.setParams({});return}this._error(e,n)}_error(e,r){(e?xn.reportExtraError:xn.reportError)(this,this.def.error,r)}$dataError(){(0,xn.reportError)(this,this.def.$dataError||xn.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,xn.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,r){r?Object.assign(this.params,e):this.params=e}block$data(e,r,n=q.nil){this.gen.block(()=>{this.check$data(e,n),r()})}check$data(e=q.nil,r=q.nil){if(!this.$data)return;let{gen:n,schemaCode:i,schemaType:o,def:s}=this;n.if((0,q.or)((0,q._)`${i} === undefined`,r)),e!==q.nil&&n.assign(e,!0),(o.length||s.validateSchema)&&(n.elseIf(this.invalid$data()),this.$dataError(),e!==q.nil&&n.assign(e,!1)),n.else()}invalid$data(){let{gen:e,schemaCode:r,schemaType:n,def:i,it:o}=this;return(0,q.or)(s(),a());function s(){if(n.length){if(!(r instanceof q.Name))throw new Error("ajv implementation error");let l=Array.isArray(n)?n:[n];return(0,q._)`${(0,Hi.checkDataTypes)(l,r,o.opts.strictNumbers,Hi.DataType.Wrong)}`}return q.nil}function a(){if(i.validateSchema){let l=e.scopeValue("validate$data",{ref:i.validateSchema});return(0,q._)`!${l}(${r})`}return q.nil}}subschema(e,r){let n=(0,wa.getSubschema)(this.it,e);(0,wa.extendSubschemaData)(n,this.it,e),(0,wa.extendSubschemaMode)(n,e);let i={...this.it,...n,items:void 0,props:void 0};return K_(i,r),i}mergeEvaluated(e,r){let{it:n,gen:i}=this;n.opts.unevaluated&&(n.props!==!0&&e.props!==void 0&&(n.props=At.mergeEvaluated.props(i,e.props,n.props,r)),n.items!==!0&&e.items!==void 0&&(n.items=At.mergeEvaluated.items(i,e.items,n.items,r)))}mergeValidEvaluated(e,r){let{it:n,gen:i}=this;if(n.opts.unevaluated&&(n.props!==!0||n.items!==!0))return i.if(r,()=>this.mergeEvaluated(e,q.Name)),!0}};Ft.KeywordCxt=Bi;function sp(t,e,r,n){let i=new Bi(t,r,e);"code"in r?r.code(i,n):i.$data&&r.validate?(0,Cn.funcKeywordCode)(i,r):"macro"in r?(0,Cn.macroKeywordCode)(i,r):(r.compile||r.validate)&&(0,Cn.funcKeywordCode)(i,r)}var cw=/^\/(?:[^~]|~0|~1)*$/,lw=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function ap(t,{dataLevel:e,dataNames:r,dataPathArr:n}){let i,o;if(t==="")return W.default.rootData;if(t[0]==="/"){if(!cw.test(t))throw new Error(`Invalid JSON-pointer: ${t}`);i=t,o=W.default.rootData}else{let u=lw.exec(t);if(!u)throw new Error(`Invalid JSON-pointer: ${t}`);let p=+u[1];if(i=u[2],i==="#"){if(p>=e)throw new Error(l("property/index",p));return n[e-p]}if(p>e)throw new Error(l("data",p));if(o=r[e-p],!i)return o}let s=o,a=i.split("/");for(let u of a)u&&(o=(0,q._)`${o}${(0,q.getProperty)((0,At.unescapeJsonPointer)(u))}`,s=(0,q._)`${s} && ${o}`);return s;function l(u,p){return`Cannot access ${u} ${p} levels up, current level is ${e}`}}Ft.getData=ap});var Ui=w($a=>{"use strict";Object.defineProperty($a,"__esModule",{value:!0});var Ea=class extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}};$a.default=Ea});var kn=w(Pa=>{"use strict";Object.defineProperty(Pa,"__esModule",{value:!0});var xa=$n(),Ca=class extends Error{constructor(e,r,n,i){super(i||`can't resolve reference ${n} from id ${r}`),this.missingRef=(0,xa.resolveUrl)(e,r,n),this.missingSchema=(0,xa.normalizeId)((0,xa.getFullPath)(e,this.missingRef))}};Pa.default=Ca});var An=w(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});Ke.resolveSchema=Ke.getCompilingSchema=Ke.resolveRef=Ke.compileSchema=Ke.SchemaEnv=void 0;var ot=z(),uw=Ui(),ir=We(),st=$n(),cp=X(),fw=Pn(),Rr=class{constructor(e){var r;this.refs={},this.dynamicAnchors={};let n;typeof e.schema=="object"&&(n=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(r=e.baseId)!==null&&r!==void 0?r:(0,st.normalizeId)(n?.[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=n?.$async,this.refs={}}};Ke.SchemaEnv=Rr;function Aa(t){let e=lp.call(this,t);if(e)return e;let r=(0,st.getFullPath)(this.opts.uriResolver,t.root.baseId),{es5:n,lines:i}=this.opts.code,{ownProperties:o}=this.opts,s=new ot.CodeGen(this.scope,{es5:n,lines:i,ownProperties:o}),a;t.$async&&(a=s.scopeValue("Error",{ref:uw.default,code:(0,ot._)`require("ajv/dist/runtime/validation_error").default`}));let l=s.scopeName("validate");t.validateName=l;let u={gen:s,allErrors:this.opts.allErrors,data:ir.default.data,parentData:ir.default.parentData,parentDataProperty:ir.default.parentDataProperty,dataNames:[ir.default.data],dataPathArr:[ot.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:t.schema,code:(0,ot.stringify)(t.schema)}:{ref:t.schema}),validateName:l,ValidationError:a,schema:t.schema,schemaEnv:t,rootId:r,baseId:t.baseId||r,schemaPath:ot.nil,errSchemaPath:t.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,ot._)`""`,opts:this.opts,self:this},p;try{this._compilations.add(t),(0,fw.validateFunctionCode)(u),s.optimize(this.opts.code.optimize);let f=s.toString();p=`${s.scopeRefs(ir.default.scope)}return ${f}`,this.opts.code.process&&(p=this.opts.code.process(p,t));let m=new Function(`${ir.default.self}`,`${ir.default.scope}`,p)(this,this.scope.get());if(this.scope.value(l,{ref:m}),m.errors=null,m.schema=t.schema,m.schemaEnv=t,t.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:l,validateCode:f,scopeValues:s._values}),this.opts.unevaluated){let{props:g,items:v}=u;m.evaluated={props:g instanceof ot.Name?void 0:g,items:v instanceof ot.Name?void 0:v,dynamicProps:g instanceof ot.Name,dynamicItems:v instanceof ot.Name},m.source&&(m.source.evaluated=(0,ot.stringify)(m.evaluated))}return t.validate=m,t}catch(f){throw delete t.validate,delete t.validateName,p&&this.logger.error("Error compiling schema, function code:",p),f}finally{this._compilations.delete(t)}}Ke.compileSchema=Aa;function pw(t,e,r){var n;r=(0,st.resolveUrl)(this.opts.uriResolver,e,r);let i=t.refs[r];if(i)return i;let o=mw.call(this,t,r);if(o===void 0){let s=(n=t.localRefs)===null||n===void 0?void 0:n[r],{schemaId:a}=this.opts;s&&(o=new Rr({schema:s,schemaId:a,root:t,baseId:e}))}if(o!==void 0)return t.refs[r]=dw.call(this,o)}Ke.resolveRef=pw;function dw(t){return(0,st.inlineRef)(t.schema,this.opts.inlineRefs)?t.schema:t.validate?t:Aa.call(this,t)}function lp(t){for(let e of this._compilations)if(hw(e,t))return e}Ke.getCompilingSchema=lp;function hw(t,e){return t.schema===e.schema&&t.root===e.root&&t.baseId===e.baseId}function mw(t,e){let r;for(;typeof(r=this.refs[e])=="string";)e=r;return r||this.schemas[e]||Gi.call(this,t,e)}function Gi(t,e){let r=this.opts.uriResolver.parse(e),n=(0,st._getFullPath)(this.opts.uriResolver,r),i=(0,st.getFullPath)(this.opts.uriResolver,t.baseId,void 0);if(Object.keys(t.schema).length>0&&n===i)return ka.call(this,r,t);let o=(0,st.normalizeId)(n),s=this.refs[o]||this.schemas[o];if(typeof s=="string"){let a=Gi.call(this,t,s);return typeof a?.schema!="object"?void 0:ka.call(this,r,a)}if(typeof s?.schema=="object"){if(s.validate||Aa.call(this,s),o===(0,st.normalizeId)(e)){let{schema:a}=s,{schemaId:l}=this.opts,u=a[l];return u&&(i=(0,st.resolveUrl)(this.opts.uriResolver,i,u)),new Rr({schema:a,schemaId:l,root:t,baseId:i})}return ka.call(this,r,s)}}Ke.resolveSchema=Gi;var gw=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function ka(t,{baseId:e,schema:r,root:n}){var i;if(((i=t.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(let a of t.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let l=r[(0,cp.unescapeFragment)(a)];if(l===void 0)return;r=l;let u=typeof r=="object"&&r[this.opts.schemaId];!gw.has(a)&&u&&(e=(0,st.resolveUrl)(this.opts.uriResolver,e,u))}let o;if(typeof r!="boolean"&&r.$ref&&!(0,cp.schemaHasRulesButRef)(r,this.RULES)){let a=(0,st.resolveUrl)(this.opts.uriResolver,e,r.$ref);o=Gi.call(this,n,a)}let{schemaId:s}=this.opts;if(o=o||new Rr({schema:r,schemaId:s,root:n,baseId:e}),o.schema!==o.root.schema)return o}});var up=w((ik,yw)=>{yw.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var Ia=w((ok,gp)=>{"use strict";var vw=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),pp=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),Oa=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),dp=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),_w=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function Ra(t){let e="",r=0,n=0;for(n=0;n<t.length;n++)if(r=t[n].charCodeAt(0),r!==48){if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";e+=t[n];break}for(n+=1;n<t.length;n++){if(r=t[n].charCodeAt(0),!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";e+=t[n]}return e}var ww=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function fp(t){return t.length=0,!0}function bw(t,e,r){if(t.length){let n=Ra(t);if(n!=="")e.push(n);else return r.error=!0,!1;t.length=0}return!0}function Sw(t){let e=0,r={error:!1,address:"",zone:""},n=[],i=[],o=!1,s=!1,a=bw;for(let l=0;l<t.length;l++){let u=t[l];if(!(u==="["||u==="]"))if(u===":"){if(o===!0&&(s=!0),!a(i,n,r))break;if(++e>7){r.error=!0;break}l>0&&t[l-1]===":"&&(o=!0),n.push(":");continue}else if(u==="%"){if(!a(i,n,r))break;a=fp}else{i.push(u);continue}}return i.length&&(a===fp?r.zone=i.join(""):s?n.push(i.join("")):n.push(Ra(i))),r.address=n.join(""),r}function hp(t){if(Ew(t,":")<2)return{host:t,isIPV6:!1};let e=Sw(t);if(e.error)return{host:t,isIPV6:!1};{let r=e.address,n=e.address;return e.zone&&(r+="%"+e.zone,n+="%25"+e.zone),{host:r,isIPV6:!0,escapedHost:n}}}function Ew(t,e){let r=0;for(let n=0;n<t.length;n++)t[n]===e&&r++;return r}function $w(t){let e=t,r=[],n=-1,i=0;for(;i=e.length;){if(i===1){if(e===".")break;if(e==="/"){r.push("/");break}else{r.push(e);break}}else if(i===2){if(e[0]==="."){if(e[1]===".")break;if(e[1]==="/"){e=e.slice(2);continue}}else if(e[0]==="/"&&(e[1]==="."||e[1]==="/")){r.push("/");break}}else if(i===3&&e==="/.."){r.length!==0&&r.pop(),r.push("/");break}if(e[0]==="."){if(e[1]==="."){if(e[2]==="/"){e=e.slice(3);continue}}else if(e[1]==="/"){e=e.slice(2);continue}}else if(e[0]==="/"&&e[1]==="."){if(e[2]==="/"){e=e.slice(2);continue}else if(e[2]==="."&&e[3]==="/"){e=e.slice(3),r.length!==0&&r.pop();continue}}if((n=e.indexOf("/",1))===-1){r.push(e);break}else r.push(e.slice(0,n)),e=e.slice(n)}return r.join("")}var xw={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},Cw=/[@/?#:]/g,Pw=/[@/?#]/g;function mp(t,e){let r=e?Pw:Cw;return r.lastIndex=0,t.replace(r,n=>xw[n])}function kw(t,e=!1){if(t.indexOf("%")===-1)return t;let r="";for(let n=0;n<t.length;n++){if(t[n]==="%"&&n+2<t.length){let i=t.slice(n+1,n+3);if(Oa(i)){let o=i.toUpperCase(),s=String.fromCharCode(parseInt(o,16));e&&dp(s)?r+=s:r+="%"+o,n+=2;continue}}r+=t[n]}return r}function Aw(t){let e="";for(let r=0;r<t.length;r++){if(t[r]==="%"&&r+2<t.length){let n=t.slice(r+1,r+3);if(Oa(n)){let i=n.toUpperCase(),o=String.fromCharCode(parseInt(i,16));o!=="."&&dp(o)?e+=o:e+="%"+i,r+=2;continue}}_w(t[r])?e+=t[r]:e+=escape(t[r])}return e}function Ow(t){let e="";for(let r=0;r<t.length;r++){if(t[r]==="%"&&r+2<t.length){let n=t.slice(r+1,r+3);if(Oa(n)){e+="%"+n.toUpperCase(),r+=2;continue}}e+=escape(t[r])}return e}function Rw(t){let e=[];if(t.userinfo!==void 0&&(e.push(t.userinfo),e.push("@")),t.host!==void 0){let r=unescape(t.host);if(!pp(r)){let n=hp(r);n.isIPV6===!0?r=`[${n.escapedHost}]`:r=mp(r,!1)}e.push(r)}return(typeof t.port=="number"||typeof t.port=="string")&&(e.push(":"),e.push(String(t.port))),e.length?e.join(""):void 0}gp.exports={nonSimpleDomain:ww,recomposeAuthority:Rw,reescapeHostDelimiters:mp,normalizePercentEncoding:kw,normalizePathEncoding:Aw,escapePreservingEscapes:Ow,removeDotSegments:$w,isIPv4:pp,isUUID:vw,normalizeIPv6:hp,stringArrayToHexStripped:Ra}});var bp=w((sk,wp)=>{"use strict";var{isUUID:Iw}=Ia(),Tw=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,Nw=["http","https","ws","wss","urn","urn:uuid"];function Mw(t){return Nw.indexOf(t)!==-1}function Ta(t){return t.secure===!0?!0:t.secure===!1?!1:t.scheme?t.scheme.length===3&&(t.scheme[0]==="w"||t.scheme[0]==="W")&&(t.scheme[1]==="s"||t.scheme[1]==="S")&&(t.scheme[2]==="s"||t.scheme[2]==="S"):!1}function yp(t){return t.host||(t.error=t.error||"HTTP URIs must have a host."),t}function vp(t){let e=String(t.scheme).toLowerCase()==="https";return(t.port===(e?443:80)||t.port==="")&&(t.port=void 0),t.path||(t.path="/"),t}function Lw(t){return t.secure=Ta(t),t.resourceName=(t.path||"/")+(t.query?"?"+t.query:""),t.path=void 0,t.query=void 0,t}function jw(t){if((t.port===(Ta(t)?443:80)||t.port==="")&&(t.port=void 0),typeof t.secure=="boolean"&&(t.scheme=t.secure?"wss":"ws",t.secure=void 0),t.resourceName){let[e,r]=t.resourceName.split("?");t.path=e&&e!=="/"?e:void 0,t.query=r,t.resourceName=void 0}return t.fragment=void 0,t}function Dw(t,e){if(!t.path)return t.error="URN can not be parsed",t;let r=t.path.match(Tw);if(r){let n=e.scheme||t.scheme||"urn";t.nid=r[1].toLowerCase(),t.nss=r[2];let i=`${n}:${e.nid||t.nid}`,o=Na(i);t.path=void 0,o&&(t=o.parse(t,e))}else t.error=t.error||"URN can not be parsed.";return t}function Vw(t,e){if(t.nid===void 0)throw new Error("URN without nid cannot be serialized");let r=e.scheme||t.scheme||"urn",n=t.nid.toLowerCase(),i=`${r}:${e.nid||n}`,o=Na(i);o&&(t=o.serialize(t,e));let s=t,a=t.nss;return s.path=`${n||e.nid}:${a}`,e.skipEscape=!0,s}function qw(t,e){let r=t;return r.uuid=r.nss,r.nss=void 0,!e.tolerant&&(!r.uuid||!Iw(r.uuid))&&(r.error=r.error||"UUID is not valid."),r}function Fw(t){let e=t;return e.nss=(t.uuid||"").toLowerCase(),e}var _p={scheme:"http",domainHost:!0,parse:yp,serialize:vp},Hw={scheme:"https",domainHost:_p.domainHost,parse:yp,serialize:vp},Wi={scheme:"ws",domainHost:!0,parse:Lw,serialize:jw},Bw={scheme:"wss",domainHost:Wi.domainHost,parse:Wi.parse,serialize:Wi.serialize},Uw={scheme:"urn",parse:Dw,serialize:Vw,skipNormalize:!0},Gw={scheme:"urn:uuid",parse:qw,serialize:Fw,skipNormalize:!0},zi={http:_p,https:Hw,ws:Wi,wss:Bw,urn:Uw,"urn:uuid":Gw};Object.setPrototypeOf(zi,null);function Na(t){return t&&(zi[t]||zi[t.toLowerCase()])||void 0}wp.exports={wsIsSecure:Ta,SCHEMES:zi,isValidSchemeName:Mw,getSchemeHandler:Na}});var Pp=w((ak,Ki)=>{"use strict";var{normalizeIPv6:Ww,removeDotSegments:On,recomposeAuthority:zw,normalizePercentEncoding:Kw,normalizePathEncoding:Jw,escapePreservingEscapes:Yw,reescapeHostDelimiters:Xw,isIPv4:Qw,nonSimpleDomain:Zw}=Ia(),{SCHEMES:e0,getSchemeHandler:Ep}=bp();function t0(t,e){return typeof t=="string"?t=s0(t,e):typeof t=="object"&&(t=Ir(or(t,e),e)),t}function r0(t,e,r){let n=r?Object.assign({scheme:"null"},r):{scheme:"null"},i=$p(Ir(t,n),Ir(e,n),n,!0);return n.skipEscape=!0,or(i,n)}function $p(t,e,r,n){let i={};return n||(t=Ir(or(t,r),r),e=Ir(or(e,r),r)),r=r||{},!r.tolerant&&e.scheme?(i.scheme=e.scheme,i.userinfo=e.userinfo,i.host=e.host,i.port=e.port,i.path=On(e.path||""),i.query=e.query):(e.userinfo!==void 0||e.host!==void 0||e.port!==void 0?(i.userinfo=e.userinfo,i.host=e.host,i.port=e.port,i.path=On(e.path||""),i.query=e.query):(e.path?(e.path[0]==="/"?i.path=On(e.path):((t.userinfo!==void 0||t.host!==void 0||t.port!==void 0)&&!t.path?i.path="/"+e.path:t.path?i.path=t.path.slice(0,t.path.lastIndexOf("/")+1)+e.path:i.path=e.path,i.path=On(i.path)),i.query=e.query):(i.path=t.path,e.query!==void 0?i.query=e.query:i.query=t.query),i.userinfo=t.userinfo,i.host=t.host,i.port=t.port),i.scheme=t.scheme),i.fragment=e.fragment,i}function n0(t,e,r){let n=Sp(t,r),i=Sp(e,r);return n!==void 0&&i!==void 0&&n.toLowerCase()===i.toLowerCase()}function or(t,e){let r={host:t.host,scheme:t.scheme,userinfo:t.userinfo,port:t.port,path:t.path,query:t.query,nid:t.nid,nss:t.nss,uuid:t.uuid,fragment:t.fragment,reference:t.reference,resourceName:t.resourceName,secure:t.secure,error:""},n=Object.assign({},e),i=[],o=Ep(n.scheme||r.scheme);o&&o.serialize&&o.serialize(r,n),r.path!==void 0&&(n.skipEscape?r.path=Kw(r.path):(r.path=Yw(r.path),r.scheme!==void 0&&(r.path=r.path.split("%3A").join(":")))),n.reference!=="suffix"&&r.scheme&&i.push(r.scheme,":");let s=zw(r);if(s!==void 0&&(n.reference!=="suffix"&&i.push("//"),i.push(s),r.path&&r.path[0]!=="/"&&i.push("/")),r.path!==void 0){let a=r.path;!n.absolutePath&&(!o||!o.absolutePath)&&(a=On(a)),s===void 0&&a[0]==="/"&&a[1]==="/"&&(a="/%2F"+a.slice(2)),i.push(a)}return r.query!==void 0&&i.push("?",r.query),r.fragment!==void 0&&i.push("#",r.fragment),i.join("")}var i0=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function o0(t,e){if(e[2]!==void 0&&t.path&&t.path[0]!=="/")return'URI path must start with "/" when authority is present.';if(typeof t.port=="number"&&(t.port<0||t.port>65535))return"URI port is malformed."}function xp(t,e){let r=Object.assign({},e),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},i=!1,o=!1;r.reference==="suffix"&&(r.scheme?t=r.scheme+":"+t:t="//"+t);let s=t.match(i0);if(s){n.scheme=s[1],n.userinfo=s[3],n.host=s[4],n.port=parseInt(s[5],10),n.path=s[6]||"",n.query=s[7],n.fragment=s[8],isNaN(n.port)&&(n.port=s[5]);let a=o0(n,s);if(a!==void 0&&(n.error=n.error||a,i=!0),n.host)if(Qw(n.host)===!1){let p=Ww(n.host);n.host=p.host.toLowerCase(),o=p.isIPV6}else o=!0;n.scheme===void 0&&n.userinfo===void 0&&n.host===void 0&&n.port===void 0&&n.query===void 0&&!n.path?n.reference="same-document":n.scheme===void 0?n.reference="relative":n.fragment===void 0?n.reference="absolute":n.reference="uri",r.reference&&r.reference!=="suffix"&&r.reference!==n.reference&&(n.error=n.error||"URI is not a "+r.reference+" reference.");let l=Ep(r.scheme||n.scheme);if(!r.unicodeSupport&&(!l||!l.unicodeSupport)&&n.host&&(r.domainHost||l&&l.domainHost)&&o===!1&&Zw(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(u){n.error=n.error||"Host's domain name can not be converted to ASCII: "+u}if((!l||l&&!l.skipNormalize)&&(t.indexOf("%")!==-1&&(n.scheme!==void 0&&(n.scheme=unescape(n.scheme)),n.host!==void 0&&(n.host=Xw(unescape(n.host),o))),n.path&&(n.path=Jw(n.path)),n.fragment))try{n.fragment=encodeURI(decodeURIComponent(n.fragment))}catch{n.error=n.error||"URI malformed"}l&&l.parse&&l.parse(n,r)}else n.error=n.error||"URI can not be parsed.";return{parsed:n,malformedAuthorityOrPort:i}}function Ir(t,e){return xp(t,e).parsed}function s0(t,e){return Cp(t,e).normalized}function Cp(t,e){let{parsed:r,malformedAuthorityOrPort:n}=xp(t,e);return{normalized:n?t:or(r,e),malformedAuthorityOrPort:n}}function Sp(t,e){if(typeof t=="string"){let{normalized:r,malformedAuthorityOrPort:n}=Cp(t,e);return n?void 0:r}if(typeof t=="object")return or(t,e)}var Ma={SCHEMES:e0,normalize:t0,resolve:r0,resolveComponent:$p,equal:n0,serialize:or,parse:Ir};Ki.exports=Ma;Ki.exports.default=Ma;Ki.exports.fastUri=Ma});var Ap=w(La=>{"use strict";Object.defineProperty(La,"__esModule",{value:!0});var kp=Pp();kp.code='require("ajv/dist/runtime/uri").default';La.default=kp});var jp=w(Se=>{"use strict";Object.defineProperty(Se,"__esModule",{value:!0});Se.CodeGen=Se.Name=Se.nil=Se.stringify=Se.str=Se._=Se.KeywordCxt=void 0;var a0=Pn();Object.defineProperty(Se,"KeywordCxt",{enumerable:!0,get:function(){return a0.KeywordCxt}});var Tr=z();Object.defineProperty(Se,"_",{enumerable:!0,get:function(){return Tr._}});Object.defineProperty(Se,"str",{enumerable:!0,get:function(){return Tr.str}});Object.defineProperty(Se,"stringify",{enumerable:!0,get:function(){return Tr.stringify}});Object.defineProperty(Se,"nil",{enumerable:!0,get:function(){return Tr.nil}});Object.defineProperty(Se,"Name",{enumerable:!0,get:function(){return Tr.Name}});Object.defineProperty(Se,"CodeGen",{enumerable:!0,get:function(){return Tr.CodeGen}});var c0=Ui(),Np=kn(),l0=ua(),Rn=An(),u0=z(),In=$n(),Ji=En(),Da=X(),Op=up(),f0=Ap(),Mp=(t,e)=>new RegExp(t,e);Mp.code="new RegExp";var p0=["removeAdditional","useDefaults","coerceTypes"],d0=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),h0={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},m0={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},Rp=200;function g0(t){var e,r,n,i,o,s,a,l,u,p,f,h,m,g,v,P,b,j,B,L,T,Q,ne,Nt,et;let be=t.strict,Ne=(e=t.code)===null||e===void 0?void 0:e.optimize,xe=Ne===!0||Ne===void 0?1:Ne||0,tt=(n=(r=t.code)===null||r===void 0?void 0:r.regExp)!==null&&n!==void 0?n:Mp,rt=(i=t.uriResolver)!==null&&i!==void 0?i:f0.default;return{strictSchema:(s=(o=t.strictSchema)!==null&&o!==void 0?o:be)!==null&&s!==void 0?s:!0,strictNumbers:(l=(a=t.strictNumbers)!==null&&a!==void 0?a:be)!==null&&l!==void 0?l:!0,strictTypes:(p=(u=t.strictTypes)!==null&&u!==void 0?u:be)!==null&&p!==void 0?p:"log",strictTuples:(h=(f=t.strictTuples)!==null&&f!==void 0?f:be)!==null&&h!==void 0?h:"log",strictRequired:(g=(m=t.strictRequired)!==null&&m!==void 0?m:be)!==null&&g!==void 0?g:!1,code:t.code?{...t.code,optimize:xe,regExp:tt}:{optimize:xe,regExp:tt},loopRequired:(v=t.loopRequired)!==null&&v!==void 0?v:Rp,loopEnum:(P=t.loopEnum)!==null&&P!==void 0?P:Rp,meta:(b=t.meta)!==null&&b!==void 0?b:!0,messages:(j=t.messages)!==null&&j!==void 0?j:!0,inlineRefs:(B=t.inlineRefs)!==null&&B!==void 0?B:!0,schemaId:(L=t.schemaId)!==null&&L!==void 0?L:"$id",addUsedSchema:(T=t.addUsedSchema)!==null&&T!==void 0?T:!0,validateSchema:(Q=t.validateSchema)!==null&&Q!==void 0?Q:!0,validateFormats:(ne=t.validateFormats)!==null&&ne!==void 0?ne:!0,unicodeRegExp:(Nt=t.unicodeRegExp)!==null&&Nt!==void 0?Nt:!0,int32range:(et=t.int32range)!==null&&et!==void 0?et:!0,uriResolver:rt}}var Tn=class{constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...g0(e)};let{es5:r,lines:n}=this.opts.code;this.scope=new u0.ValueScope({scope:{},prefixes:d0,es5:r,lines:n}),this.logger=S0(e.logger);let i=e.validateFormats;e.validateFormats=!1,this.RULES=(0,l0.getRules)(),Ip.call(this,h0,e,"NOT SUPPORTED"),Ip.call(this,m0,e,"DEPRECATED","warn"),this._metaOpts=w0.call(this),e.formats&&v0.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&_0.call(this,e.keywords),typeof e.meta=="object"&&this.addMetaSchema(e.meta),y0.call(this),e.validateFormats=i}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:r,schemaId:n}=this.opts,i=Op;n==="id"&&(i={...Op},i.id=i.$id,delete i.$id),r&&e&&this.addMetaSchema(i,i[n],!1)}defaultMeta(){let{meta:e,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[r]||e:void 0}validate(e,r){let n;if(typeof e=="string"){if(n=this.getSchema(e),!n)throw new Error(`no schema with key or ref "${e}"`)}else n=this.compile(e);let i=n(r);return"$async"in n||(this.errors=n.errors),i}compile(e,r){let n=this._addSchema(e,r);return n.validate||this._compileSchemaEnv(n)}compileAsync(e,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:n}=this.opts;return i.call(this,e,r);async function i(p,f){await o.call(this,p.$schema);let h=this._addSchema(p,f);return h.validate||s.call(this,h)}async function o(p){p&&!this.getSchema(p)&&await i.call(this,{$ref:p},!0)}async function s(p){try{return this._compileSchemaEnv(p)}catch(f){if(!(f instanceof Np.default))throw f;return a.call(this,f),await l.call(this,f.missingSchema),s.call(this,p)}}function a({missingSchema:p,missingRef:f}){if(this.refs[p])throw new Error(`AnySchema ${p} is loaded but ${f} cannot be resolved`)}async function l(p){let f=await u.call(this,p);this.refs[p]||await o.call(this,f.$schema),this.refs[p]||this.addSchema(f,p,r)}async function u(p){let f=this._loading[p];if(f)return f;try{return await(this._loading[p]=n(p))}finally{delete this._loading[p]}}}addSchema(e,r,n,i=this.opts.validateSchema){if(Array.isArray(e)){for(let s of e)this.addSchema(s,void 0,n,i);return this}let o;if(typeof e=="object"){let{schemaId:s}=this.opts;if(o=e[s],o!==void 0&&typeof o!="string")throw new Error(`schema ${s} must be string`)}return r=(0,In.normalizeId)(r||o),this._checkUnique(r),this.schemas[r]=this._addSchema(e,n,r,i,!0),this}addMetaSchema(e,r,n=this.opts.validateSchema){return this.addSchema(e,r,!0,n),this}validateSchema(e,r){if(typeof e=="boolean")return!0;let n;if(n=e.$schema,n!==void 0&&typeof n!="string")throw new Error("$schema must be a string");if(n=n||this.opts.defaultMeta||this.defaultMeta(),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let i=this.validate(n,e);if(!i&&r){let o="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(o);else throw new Error(o)}return i}getSchema(e){let r;for(;typeof(r=Tp.call(this,e))=="string";)e=r;if(r===void 0){let{schemaId:n}=this.opts,i=new Rn.SchemaEnv({schema:{},schemaId:n});if(r=Rn.resolveSchema.call(this,i,e),!r)return;this.refs[e]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=Tp.call(this,e);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{let r=e;this._cache.delete(r);let n=e[this.opts.schemaId];return n&&(n=(0,In.normalizeId)(n),delete this.schemas[n],delete this.refs[n]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let r of e)this.addKeyword(r);return this}addKeyword(e,r){let n;if(typeof e=="string")n=e,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=n);else if(typeof e=="object"&&r===void 0){if(r=e,n=r.keyword,Array.isArray(n)&&!n.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if($0.call(this,n,r),!r)return(0,Da.eachItem)(n,o=>ja.call(this,o)),this;C0.call(this,r);let i={...r,type:(0,Ji.getJSONTypes)(r.type),schemaType:(0,Ji.getJSONTypes)(r.schemaType)};return(0,Da.eachItem)(n,i.type.length===0?o=>ja.call(this,o,i):o=>i.type.forEach(s=>ja.call(this,o,i,s))),this}getKeyword(e){let r=this.RULES.all[e];return typeof r=="object"?r.definition:!!r}removeKeyword(e){let{RULES:r}=this;delete r.keywords[e],delete r.all[e];for(let n of r.rules){let i=n.rules.findIndex(o=>o.keyword===e);i>=0&&n.rules.splice(i,1)}return this}addFormat(e,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[e]=r,this}errorsText(e=this.errors,{separator:r=", ",dataVar:n="data"}={}){return!e||e.length===0?"No errors":e.map(i=>`${n}${i.instancePath} ${i.message}`).reduce((i,o)=>i+r+o)}$dataMetaSchema(e,r){let n=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let i of r){let o=i.split("/").slice(1),s=e;for(let a of o)s=s[a];for(let a in n){let l=n[a];if(typeof l!="object")continue;let{$data:u}=l.definition,p=s[a];u&&p&&(s[a]=Lp(p))}}return e}_removeAllSchemas(e,r){for(let n in e){let i=e[n];(!r||r.test(n))&&(typeof i=="string"?delete e[n]:i&&!i.meta&&(this._cache.delete(i.schema),delete e[n]))}}_addSchema(e,r,n,i=this.opts.validateSchema,o=this.opts.addUsedSchema){let s,{schemaId:a}=this.opts;if(typeof e=="object")s=e[a];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof e!="boolean")throw new Error("schema must be object or boolean")}let l=this._cache.get(e);if(l!==void 0)return l;n=(0,In.normalizeId)(s||n);let u=In.getSchemaRefs.call(this,e,n);return l=new Rn.SchemaEnv({schema:e,schemaId:a,meta:r,baseId:n,localRefs:u}),this._cache.set(l.schema,l),o&&!n.startsWith("#")&&(n&&this._checkUnique(n),this.refs[n]=l),i&&this.validateSchema(e,!0),l}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):Rn.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let r=this.opts;this.opts=this._metaOpts;try{Rn.compileSchema.call(this,e)}finally{this.opts=r}}};Tn.ValidationError=c0.default;Tn.MissingRefError=Np.default;Se.default=Tn;function Ip(t,e,r,n="error"){for(let i in t){let o=i;o in e&&this.logger[n](`${r}: option ${i}. ${t[o]}`)}}function Tp(t){return t=(0,In.normalizeId)(t),this.schemas[t]||this.refs[t]}function y0(){let t=this.opts.schemas;if(t)if(Array.isArray(t))this.addSchema(t);else for(let e in t)this.addSchema(t[e],e)}function v0(){for(let t in this.opts.formats){let e=this.opts.formats[t];e&&this.addFormat(t,e)}}function _0(t){if(Array.isArray(t)){this.addVocabulary(t);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let e in t){let r=t[e];r.keyword||(r.keyword=e),this.addKeyword(r)}}function w0(){let t={...this.opts};for(let e of p0)delete t[e];return t}var b0={log(){},warn(){},error(){}};function S0(t){if(t===!1)return b0;if(t===void 0)return console;if(t.log&&t.warn&&t.error)return t;throw new Error("logger must implement log, warn and error methods")}var E0=/^[a-z_$][a-z0-9_$:-]*$/i;function $0(t,e){let{RULES:r}=this;if((0,Da.eachItem)(t,n=>{if(r.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!E0.test(n))throw new Error(`Keyword ${n} has invalid name`)}),!!e&&e.$data&&!("code"in e||"validate"in e))throw new Error('$data keyword must have "code" or "validate" function')}function ja(t,e,r){var n;let i=e?.post;if(r&&i)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:o}=this,s=i?o.post:o.rules.find(({type:l})=>l===r);if(s||(s={type:r,rules:[]},o.rules.push(s)),o.keywords[t]=!0,!e)return;let a={keyword:t,definition:{...e,type:(0,Ji.getJSONTypes)(e.type),schemaType:(0,Ji.getJSONTypes)(e.schemaType)}};e.before?x0.call(this,s,a,e.before):s.rules.push(a),o.all[t]=a,(n=e.implements)===null||n===void 0||n.forEach(l=>this.addKeyword(l))}function x0(t,e,r){let n=t.rules.findIndex(i=>i.keyword===r);n>=0?t.rules.splice(n,0,e):(t.rules.push(e),this.logger.warn(`rule ${r} is not defined`))}function C0(t){let{metaSchema:e}=t;e!==void 0&&(t.$data&&this.opts.$data&&(e=Lp(e)),t.validateSchema=this.compile(e,!0))}var P0={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function Lp(t){return{anyOf:[t,P0]}}});var Dp=w(Va=>{"use strict";Object.defineProperty(Va,"__esModule",{value:!0});var k0={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};Va.default=k0});var Qi=w(sr=>{"use strict";Object.defineProperty(sr,"__esModule",{value:!0});sr.callRef=sr.getValidate=void 0;var A0=kn(),Vp=ze(),De=z(),Nr=We(),qp=An(),Yi=X(),O0={keyword:"$ref",schemaType:"string",code(t){let{gen:e,schema:r,it:n}=t,{baseId:i,schemaEnv:o,validateName:s,opts:a,self:l}=n,{root:u}=o;if((r==="#"||r==="#/")&&i===u.baseId)return f();let p=qp.resolveRef.call(l,u,i,r);if(p===void 0)throw new A0.default(n.opts.uriResolver,i,r);if(p instanceof qp.SchemaEnv)return h(p);return m(p);function f(){if(o===u)return Xi(t,s,o,o.$async);let g=e.scopeValue("root",{ref:u});return Xi(t,(0,De._)`${g}.validate`,u,u.$async)}function h(g){let v=Fp(t,g);Xi(t,v,g,g.$async)}function m(g){let v=e.scopeValue("schema",a.code.source===!0?{ref:g,code:(0,De.stringify)(g)}:{ref:g}),P=e.name("valid"),b=t.subschema({schema:g,dataTypes:[],schemaPath:De.nil,topSchemaRef:v,errSchemaPath:r},P);t.mergeEvaluated(b),t.ok(P)}}};function Fp(t,e){let{gen:r}=t;return e.validate?r.scopeValue("validate",{ref:e.validate}):(0,De._)`${r.scopeValue("wrapper",{ref:e})}.validate`}sr.getValidate=Fp;function Xi(t,e,r,n){let{gen:i,it:o}=t,{allErrors:s,schemaEnv:a,opts:l}=o,u=l.passContext?Nr.default.this:De.nil;n?p():f();function p(){if(!a.$async)throw new Error("async schema referenced by sync schema");let g=i.let("valid");i.try(()=>{i.code((0,De._)`await ${(0,Vp.callValidateCode)(t,e,u)}`),m(e),s||i.assign(g,!0)},v=>{i.if((0,De._)`!(${v} instanceof ${o.ValidationError})`,()=>i.throw(v)),h(v),s||i.assign(g,!1)}),t.ok(g)}function f(){t.result((0,Vp.callValidateCode)(t,e,u),()=>m(e),()=>h(e))}function h(g){let v=(0,De._)`${g}.errors`;i.assign(Nr.default.vErrors,(0,De._)`${Nr.default.vErrors} === null ? ${v} : ${Nr.default.vErrors}.concat(${v})`),i.assign(Nr.default.errors,(0,De._)`${Nr.default.vErrors}.length`)}function m(g){var v;if(!o.opts.unevaluated)return;let P=(v=r?.validate)===null||v===void 0?void 0:v.evaluated;if(o.props!==!0)if(P&&!P.dynamicProps)P.props!==void 0&&(o.props=Yi.mergeEvaluated.props(i,P.props,o.props));else{let b=i.var("props",(0,De._)`${g}.evaluated.props`);o.props=Yi.mergeEvaluated.props(i,b,o.props,De.Name)}if(o.items!==!0)if(P&&!P.dynamicItems)P.items!==void 0&&(o.items=Yi.mergeEvaluated.items(i,P.items,o.items));else{let b=i.var("items",(0,De._)`${g}.evaluated.items`);o.items=Yi.mergeEvaluated.items(i,b,o.items,De.Name)}}}sr.callRef=Xi;sr.default=O0});var Hp=w(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});var R0=Dp(),I0=Qi(),T0=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",R0.default,I0.default];qa.default=T0});var Bp=w(Fa=>{"use strict";Object.defineProperty(Fa,"__esModule",{value:!0});var Zi=z(),Ht=Zi.operators,eo={maximum:{okStr:"<=",ok:Ht.LTE,fail:Ht.GT},minimum:{okStr:">=",ok:Ht.GTE,fail:Ht.LT},exclusiveMaximum:{okStr:"<",ok:Ht.LT,fail:Ht.GTE},exclusiveMinimum:{okStr:">",ok:Ht.GT,fail:Ht.LTE}},N0={message:({keyword:t,schemaCode:e})=>(0,Zi.str)`must be ${eo[t].okStr} ${e}`,params:({keyword:t,schemaCode:e})=>(0,Zi._)`{comparison: ${eo[t].okStr}, limit: ${e}}`},M0={keyword:Object.keys(eo),type:"number",schemaType:"number",$data:!0,error:N0,code(t){let{keyword:e,data:r,schemaCode:n}=t;t.fail$data((0,Zi._)`${r} ${eo[e].fail} ${n} || isNaN(${r})`)}};Fa.default=M0});var Up=w(Ha=>{"use strict";Object.defineProperty(Ha,"__esModule",{value:!0});var Nn=z(),L0={message:({schemaCode:t})=>(0,Nn.str)`must be multiple of ${t}`,params:({schemaCode:t})=>(0,Nn._)`{multipleOf: ${t}}`},j0={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:L0,code(t){let{gen:e,data:r,schemaCode:n,it:i}=t,o=i.opts.multipleOfPrecision,s=e.let("res"),a=o?(0,Nn._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${o}`:(0,Nn._)`${s} !== parseInt(${s})`;t.fail$data((0,Nn._)`(${n} === 0 || (${s} = ${r}/${n}, ${a}))`)}};Ha.default=j0});var Wp=w(Ba=>{"use strict";Object.defineProperty(Ba,"__esModule",{value:!0});function Gp(t){let e=t.length,r=0,n=0,i;for(;n<e;)r++,i=t.charCodeAt(n++),i>=55296&&i<=56319&&n<e&&(i=t.charCodeAt(n),(i&64512)===56320&&n++);return r}Ba.default=Gp;Gp.code='require("ajv/dist/runtime/ucs2length").default'});var zp=w(Ua=>{"use strict";Object.defineProperty(Ua,"__esModule",{value:!0});var ar=z(),D0=X(),V0=Wp(),q0={message({keyword:t,schemaCode:e}){let r=t==="maxLength"?"more":"fewer";return(0,ar.str)`must NOT have ${r} than ${e} characters`},params:({schemaCode:t})=>(0,ar._)`{limit: ${t}}`},F0={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:q0,code(t){let{keyword:e,data:r,schemaCode:n,it:i}=t,o=e==="maxLength"?ar.operators.GT:ar.operators.LT,s=i.opts.unicode===!1?(0,ar._)`${r}.length`:(0,ar._)`${(0,D0.useFunc)(t.gen,V0.default)}(${r})`;t.fail$data((0,ar._)`${s} ${o} ${n}`)}};Ua.default=F0});var Kp=w(Ga=>{"use strict";Object.defineProperty(Ga,"__esModule",{value:!0});var H0=ze(),B0=X(),Mr=z(),U0={message:({schemaCode:t})=>(0,Mr.str)`must match pattern "${t}"`,params:({schemaCode:t})=>(0,Mr._)`{pattern: ${t}}`},G0={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:U0,code(t){let{gen:e,data:r,$data:n,schema:i,schemaCode:o,it:s}=t,a=s.opts.unicodeRegExp?"u":"";if(n){let{regExp:l}=s.opts.code,u=l.code==="new RegExp"?(0,Mr._)`new RegExp`:(0,B0.useFunc)(e,l),p=e.let("valid");e.try(()=>e.assign(p,(0,Mr._)`${u}(${o}, ${a}).test(${r})`),()=>e.assign(p,!1)),t.fail$data((0,Mr._)`!${p}`)}else{let l=(0,H0.usePattern)(t,i);t.fail$data((0,Mr._)`!${l}.test(${r})`)}}};Ga.default=G0});var Jp=w(Wa=>{"use strict";Object.defineProperty(Wa,"__esModule",{value:!0});var Mn=z(),W0={message({keyword:t,schemaCode:e}){let r=t==="maxProperties"?"more":"fewer";return(0,Mn.str)`must NOT have ${r} than ${e} properties`},params:({schemaCode:t})=>(0,Mn._)`{limit: ${t}}`},z0={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:W0,code(t){let{keyword:e,data:r,schemaCode:n}=t,i=e==="maxProperties"?Mn.operators.GT:Mn.operators.LT;t.fail$data((0,Mn._)`Object.keys(${r}).length ${i} ${n}`)}};Wa.default=z0});var Yp=w(za=>{"use strict";Object.defineProperty(za,"__esModule",{value:!0});var Ln=ze(),jn=z(),K0=X(),J0={message:({params:{missingProperty:t}})=>(0,jn.str)`must have required property '${t}'`,params:({params:{missingProperty:t}})=>(0,jn._)`{missingProperty: ${t}}`},Y0={keyword:"required",type:"object",schemaType:"array",$data:!0,error:J0,code(t){let{gen:e,schema:r,schemaCode:n,data:i,$data:o,it:s}=t,{opts:a}=s;if(!o&&r.length===0)return;let l=r.length>=a.loopRequired;if(s.allErrors?u():p(),a.strictRequired){let m=t.parentSchema.properties,{definedProperties:g}=t.it;for(let v of r)if(m?.[v]===void 0&&!g.has(v)){let P=s.schemaEnv.baseId+s.errSchemaPath,b=`required property "${v}" is not defined at "${P}" (strictRequired)`;(0,K0.checkStrictMode)(s,b,s.opts.strictRequired)}}function u(){if(l||o)t.block$data(jn.nil,f);else for(let m of r)(0,Ln.checkReportMissingProp)(t,m)}function p(){let m=e.let("missing");if(l||o){let g=e.let("valid",!0);t.block$data(g,()=>h(m,g)),t.ok(g)}else e.if((0,Ln.checkMissingProp)(t,r,m)),(0,Ln.reportMissingProp)(t,m),e.else()}function f(){e.forOf("prop",n,m=>{t.setParams({missingProperty:m}),e.if((0,Ln.noPropertyInData)(e,i,m,a.ownProperties),()=>t.error())})}function h(m,g){t.setParams({missingProperty:m}),e.forOf(m,n,()=>{e.assign(g,(0,Ln.propertyInData)(e,i,m,a.ownProperties)),e.if((0,jn.not)(g),()=>{t.error(),e.break()})},jn.nil)}}};za.default=Y0});var Xp=w(Ka=>{"use strict";Object.defineProperty(Ka,"__esModule",{value:!0});var Dn=z(),X0={message({keyword:t,schemaCode:e}){let r=t==="maxItems"?"more":"fewer";return(0,Dn.str)`must NOT have ${r} than ${e} items`},params:({schemaCode:t})=>(0,Dn._)`{limit: ${t}}`},Q0={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:X0,code(t){let{keyword:e,data:r,schemaCode:n}=t,i=e==="maxItems"?Dn.operators.GT:Dn.operators.LT;t.fail$data((0,Dn._)`${r}.length ${i} ${n}`)}};Ka.default=Q0});var to=w(Ja=>{"use strict";Object.defineProperty(Ja,"__esModule",{value:!0});var Qp=va();Qp.code='require("ajv/dist/runtime/equal").default';Ja.default=Qp});var Zp=w(Xa=>{"use strict";Object.defineProperty(Xa,"__esModule",{value:!0});var Ya=En(),Ee=z(),Z0=X(),e2=to(),t2={message:({params:{i:t,j:e}})=>(0,Ee.str)`must NOT have duplicate items (items ## ${e} and ${t} are identical)`,params:({params:{i:t,j:e}})=>(0,Ee._)`{i: ${t}, j: ${e}}`},r2={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:t2,code(t){let{gen:e,data:r,$data:n,schema:i,parentSchema:o,schemaCode:s,it:a}=t;if(!n&&!i)return;let l=e.let("valid"),u=o.items?(0,Ya.getSchemaTypes)(o.items):[];t.block$data(l,p,(0,Ee._)`${s} === false`),t.ok(l);function p(){let g=e.let("i",(0,Ee._)`${r}.length`),v=e.let("j");t.setParams({i:g,j:v}),e.assign(l,!0),e.if((0,Ee._)`${g} > 1`,()=>(f()?h:m)(g,v))}function f(){return u.length>0&&!u.some(g=>g==="object"||g==="array")}function h(g,v){let P=e.name("item"),b=(0,Ya.checkDataTypes)(u,P,a.opts.strictNumbers,Ya.DataType.Wrong),j=e.const("indices",(0,Ee._)`{}`);e.for((0,Ee._)`;${g}--;`,()=>{e.let(P,(0,Ee._)`${r}[${g}]`),e.if(b,(0,Ee._)`continue`),u.length>1&&e.if((0,Ee._)`typeof ${P} == "string"`,(0,Ee._)`${P} += "_"`),e.if((0,Ee._)`typeof ${j}[${P}] == "number"`,()=>{e.assign(v,(0,Ee._)`${j}[${P}]`),t.error(),e.assign(l,!1).break()}).code((0,Ee._)`${j}[${P}] = ${g}`)})}function m(g,v){let P=(0,Z0.useFunc)(e,e2.default),b=e.name("outer");e.label(b).for((0,Ee._)`;${g}--;`,()=>e.for((0,Ee._)`${v} = ${g}; ${v}--;`,()=>e.if((0,Ee._)`${P}(${r}[${g}], ${r}[${v}])`,()=>{t.error(),e.assign(l,!1).break(b)})))}}};Xa.default=r2});var ed=w(Za=>{"use strict";Object.defineProperty(Za,"__esModule",{value:!0});var Qa=z(),n2=X(),i2=to(),o2={message:"must be equal to constant",params:({schemaCode:t})=>(0,Qa._)`{allowedValue: ${t}}`},s2={keyword:"const",$data:!0,error:o2,code(t){let{gen:e,data:r,$data:n,schemaCode:i,schema:o}=t;n||o&&typeof o=="object"?t.fail$data((0,Qa._)`!${(0,n2.useFunc)(e,i2.default)}(${r}, ${i})`):t.fail((0,Qa._)`${o} !== ${r}`)}};Za.default=s2});var td=w(ec=>{"use strict";Object.defineProperty(ec,"__esModule",{value:!0});var Vn=z(),a2=X(),c2=to(),l2={message:"must be equal to one of the allowed values",params:({schemaCode:t})=>(0,Vn._)`{allowedValues: ${t}}`},u2={keyword:"enum",schemaType:"array",$data:!0,error:l2,code(t){let{gen:e,data:r,$data:n,schema:i,schemaCode:o,it:s}=t;if(!n&&i.length===0)throw new Error("enum must have non-empty array");let a=i.length>=s.opts.loopEnum,l,u=()=>l??(l=(0,a2.useFunc)(e,c2.default)),p;if(a||n)p=e.let("valid"),t.block$data(p,f);else{if(!Array.isArray(i))throw new Error("ajv implementation error");let m=e.const("vSchema",o);p=(0,Vn.or)(...i.map((g,v)=>h(m,v)))}t.pass(p);function f(){e.assign(p,!1),e.forOf("v",o,m=>e.if((0,Vn._)`${u()}(${r}, ${m})`,()=>e.assign(p,!0).break()))}function h(m,g){let v=i[g];return typeof v=="object"&&v!==null?(0,Vn._)`${u()}(${r}, ${m}[${g}])`:(0,Vn._)`${r} === ${v}`}}};ec.default=u2});var rd=w(tc=>{"use strict";Object.defineProperty(tc,"__esModule",{value:!0});var f2=Bp(),p2=Up(),d2=zp(),h2=Kp(),m2=Jp(),g2=Yp(),y2=Xp(),v2=Zp(),_2=ed(),w2=td(),b2=[f2.default,p2.default,d2.default,h2.default,m2.default,g2.default,y2.default,v2.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},_2.default,w2.default];tc.default=b2});var nc=w(qn=>{"use strict";Object.defineProperty(qn,"__esModule",{value:!0});qn.validateAdditionalItems=void 0;var cr=z(),rc=X(),S2={message:({params:{len:t}})=>(0,cr.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,cr._)`{limit: ${t}}`},E2={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:S2,code(t){let{parentSchema:e,it:r}=t,{items:n}=e;if(!Array.isArray(n)){(0,rc.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}nd(t,n)}};function nd(t,e){let{gen:r,schema:n,data:i,keyword:o,it:s}=t;s.items=!0;let a=r.const("len",(0,cr._)`${i}.length`);if(n===!1)t.setParams({len:e.length}),t.pass((0,cr._)`${a} <= ${e.length}`);else if(typeof n=="object"&&!(0,rc.alwaysValidSchema)(s,n)){let u=r.var("valid",(0,cr._)`${a} <= ${e.length}`);r.if((0,cr.not)(u),()=>l(u)),t.ok(u)}function l(u){r.forRange("i",e.length,a,p=>{t.subschema({keyword:o,dataProp:p,dataPropType:rc.Type.Num},u),s.allErrors||r.if((0,cr.not)(u),()=>r.break())})}}qn.validateAdditionalItems=nd;qn.default=E2});var ic=w(Fn=>{"use strict";Object.defineProperty(Fn,"__esModule",{value:!0});Fn.validateTuple=void 0;var id=z(),ro=X(),$2=ze(),x2={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(t){let{schema:e,it:r}=t;if(Array.isArray(e))return od(t,"additionalItems",e);r.items=!0,!(0,ro.alwaysValidSchema)(r,e)&&t.ok((0,$2.validateArray)(t))}};function od(t,e,r=t.schema){let{gen:n,parentSchema:i,data:o,keyword:s,it:a}=t;p(i),a.opts.unevaluated&&r.length&&a.items!==!0&&(a.items=ro.mergeEvaluated.items(n,r.length,a.items));let l=n.name("valid"),u=n.const("len",(0,id._)`${o}.length`);r.forEach((f,h)=>{(0,ro.alwaysValidSchema)(a,f)||(n.if((0,id._)`${u} > ${h}`,()=>t.subschema({keyword:s,schemaProp:h,dataProp:h},l)),t.ok(l))});function p(f){let{opts:h,errSchemaPath:m}=a,g=r.length,v=g===f.minItems&&(g===f.maxItems||f[e]===!1);if(h.strictTuples&&!v){let P=`"${s}" is ${g}-tuple, but minItems or maxItems/${e} are not specified or different at path "${m}"`;(0,ro.checkStrictMode)(a,P,h.strictTuples)}}}Fn.validateTuple=od;Fn.default=x2});var sd=w(oc=>{"use strict";Object.defineProperty(oc,"__esModule",{value:!0});var C2=ic(),P2={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:t=>(0,C2.validateTuple)(t,"items")};oc.default=P2});var cd=w(sc=>{"use strict";Object.defineProperty(sc,"__esModule",{value:!0});var ad=z(),k2=X(),A2=ze(),O2=nc(),R2={message:({params:{len:t}})=>(0,ad.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,ad._)`{limit: ${t}}`},I2={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:R2,code(t){let{schema:e,parentSchema:r,it:n}=t,{prefixItems:i}=r;n.items=!0,!(0,k2.alwaysValidSchema)(n,e)&&(i?(0,O2.validateAdditionalItems)(t,i):t.ok((0,A2.validateArray)(t)))}};sc.default=I2});var ld=w(ac=>{"use strict";Object.defineProperty(ac,"__esModule",{value:!0});var Je=z(),no=X(),T2={message:({params:{min:t,max:e}})=>e===void 0?(0,Je.str)`must contain at least ${t} valid item(s)`:(0,Je.str)`must contain at least ${t} and no more than ${e} valid item(s)`,params:({params:{min:t,max:e}})=>e===void 0?(0,Je._)`{minContains: ${t}}`:(0,Je._)`{minContains: ${t}, maxContains: ${e}}`},N2={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:T2,code(t){let{gen:e,schema:r,parentSchema:n,data:i,it:o}=t,s,a,{minContains:l,maxContains:u}=n;o.opts.next?(s=l===void 0?1:l,a=u):s=1;let p=e.const("len",(0,Je._)`${i}.length`);if(t.setParams({min:s,max:a}),a===void 0&&s===0){(0,no.checkStrictMode)(o,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){(0,no.checkStrictMode)(o,'"minContains" > "maxContains" is always invalid'),t.fail();return}if((0,no.alwaysValidSchema)(o,r)){let v=(0,Je._)`${p} >= ${s}`;a!==void 0&&(v=(0,Je._)`${v} && ${p} <= ${a}`),t.pass(v);return}o.items=!0;let f=e.name("valid");a===void 0&&s===1?m(f,()=>e.if(f,()=>e.break())):s===0?(e.let(f,!0),a!==void 0&&e.if((0,Je._)`${i}.length > 0`,h)):(e.let(f,!1),h()),t.result(f,()=>t.reset());function h(){let v=e.name("_valid"),P=e.let("count",0);m(v,()=>e.if(v,()=>g(P)))}function m(v,P){e.forRange("i",0,p,b=>{t.subschema({keyword:"contains",dataProp:b,dataPropType:no.Type.Num,compositeRule:!0},v),P()})}function g(v){e.code((0,Je._)`${v}++`),a===void 0?e.if((0,Je._)`${v} >= ${s}`,()=>e.assign(f,!0).break()):(e.if((0,Je._)`${v} > ${a}`,()=>e.assign(f,!1).break()),s===1?e.assign(f,!0):e.if((0,Je._)`${v} >= ${s}`,()=>e.assign(f,!0)))}}};ac.default=N2});var io=w(dt=>{"use strict";Object.defineProperty(dt,"__esModule",{value:!0});dt.validateSchemaDeps=dt.validatePropertyDeps=dt.error=void 0;var cc=z(),M2=X(),Hn=ze();dt.error={message:({params:{property:t,depsCount:e,deps:r}})=>{let n=e===1?"property":"properties";return(0,cc.str)`must have ${n} ${r} when property ${t} is present`},params:({params:{property:t,depsCount:e,deps:r,missingProperty:n}})=>(0,cc._)`{property: ${t},
|
|
34
34
|
missingProperty: ${n},
|
|
35
35
|
depsCount: ${e},
|
|
36
|
-
deps: ${r}}`};var i2={keyword:"dependencies",type:"object",schemaType:"object",error:gt.error,code(t){let[e,r]=s2(t);Ld(t,e),jd(t,r)}};function s2({schema:t}){let e={},r={};for(let n in t){if(n==="__proto__")continue;let i=Array.isArray(t[n])?e:r;i[n]=t[n]}return[e,r]}function Ld(t,e=t.schema){let{gen:r,data:n,it:i}=t;if(Object.keys(e).length===0)return;let s=r.let("missing");for(let o in e){let a=e[o];if(a.length===0)continue;let l=(0,qn.propertyInData)(r,n,o,i.opts.ownProperties);t.setParams({property:o,depsCount:a.length,deps:a.join(", ")}),i.allErrors?r.if(l,()=>{for(let u of a)(0,qn.checkReportMissingProp)(t,u)}):(r.if((0,Wa._)`${l} && (${(0,qn.checkMissingProp)(t,a,s)})`),(0,qn.reportMissingProp)(t,s),r.else())}}gt.validatePropertyDeps=Ld;function jd(t,e=t.schema){let{gen:r,data:n,keyword:i,it:s}=t,o=r.name("valid");for(let a in e)(0,n2.alwaysValidSchema)(s,e[a])||(r.if((0,qn.propertyInData)(r,n,a,s.opts.ownProperties),()=>{let l=t.subschema({keyword:i,schemaProp:a},o);t.mergeValidEvaluated(l,o)},()=>r.var(o,!0)),t.ok(o))}gt.validateSchemaDeps=jd;gt.default=i2});var qd=w(Ka=>{"use strict";Object.defineProperty(Ka,"__esModule",{value:!0});var Dd=W(),o2=X(),a2={message:"property name must be valid",params:({params:t})=>(0,Dd._)`{propertyName: ${t.propertyName}}`},c2={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:a2,code(t){let{gen:e,schema:r,data:n,it:i}=t;if((0,o2.alwaysValidSchema)(i,r))return;let s=e.name("valid");e.forIn("key",n,o=>{t.setParams({propertyName:o}),t.subschema({keyword:"propertyNames",data:o,dataTypes:["string"],propertyName:o,compositeRule:!0},s),e.if((0,Dd.not)(s),()=>{t.error(!0),i.allErrors||e.break()})}),t.ok(s)}};Ka.default=c2});var Ya=w(Ja=>{"use strict";Object.defineProperty(Ja,"__esModule",{value:!0});var Qi=Ke(),ut=W(),l2=We(),Zi=X(),u2={message:"must NOT have additional properties",params:({params:t})=>(0,ut._)`{additionalProperty: ${t.additionalProperty}}`},f2={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:u2,code(t){let{gen:e,schema:r,parentSchema:n,data:i,errsCount:s,it:o}=t;if(!s)throw new Error("ajv implementation error");let{allErrors:a,opts:l}=o;if(o.props=!0,l.removeAdditional!=="all"&&(0,Zi.alwaysValidSchema)(o,r))return;let u=(0,Qi.allSchemaProperties)(n.properties),d=(0,Qi.allSchemaProperties)(n.patternProperties);f(),t.ok((0,ut._)`${s} === ${l2.default.errors}`);function f(){e.forIn("key",i,x=>{!u.length&&!d.length?g(x):e.if(h(x),()=>g(x))})}function h(x){let E;if(u.length>8){let V=(0,Zi.schemaRefOrVal)(o,n.properties,"properties");E=(0,Qi.isOwnProperty)(e,V,x)}else u.length?E=(0,ut.or)(...u.map(V=>(0,ut._)`${x} === ${V}`)):E=ut.nil;return d.length&&(E=(0,ut.or)(E,...d.map(V=>(0,ut._)`${(0,Qi.usePattern)(t,V)}.test(${x})`))),(0,ut.not)(E)}function m(x){e.code((0,ut._)`delete ${i}[${x}]`)}function g(x){if(l.removeAdditional==="all"||l.removeAdditional&&r===!1){m(x);return}if(r===!1){t.setParams({additionalProperty:x}),t.error(),a||e.break();return}if(typeof r=="object"&&!(0,Zi.alwaysValidSchema)(o,r)){let E=e.name("valid");l.removeAdditional==="failing"?(_(x,E,!1),e.if((0,ut.not)(E),()=>{t.reset(),m(x)})):(_(x,E),a||e.if((0,ut.not)(E),()=>e.break()))}}function _(x,E,V){let G={keyword:"additionalProperties",dataProp:x,dataPropType:Zi.Type.Str};V===!1&&Object.assign(G,{compositeRule:!0,createErrors:!1,allErrors:!1}),t.subschema(G,E)}}};Ja.default=f2});var Hd=w(Qa=>{"use strict";Object.defineProperty(Qa,"__esModule",{value:!0});var d2=$n(),Vd=Ke(),Xa=X(),Fd=Ya(),p2={keyword:"properties",type:"object",schemaType:"object",code(t){let{gen:e,schema:r,parentSchema:n,data:i,it:s}=t;s.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&Fd.default.code(new d2.KeywordCxt(s,Fd.default,"additionalProperties"));let o=(0,Vd.allSchemaProperties)(r);for(let f of o)s.definedProperties.add(f);s.opts.unevaluated&&o.length&&s.props!==!0&&(s.props=Xa.mergeEvaluated.props(e,(0,Xa.toHash)(o),s.props));let a=o.filter(f=>!(0,Xa.alwaysValidSchema)(s,r[f]));if(a.length===0)return;let l=e.name("valid");for(let f of a)u(f)?d(f):(e.if((0,Vd.propertyInData)(e,i,f,s.opts.ownProperties)),d(f),s.allErrors||e.else().var(l,!0),e.endIf()),t.it.definedProperties.add(f),t.ok(l);function u(f){return s.opts.useDefaults&&!s.compositeRule&&r[f].default!==void 0}function d(f){t.subschema({keyword:"properties",schemaProp:f,dataProp:f},l)}}};Qa.default=p2});var zd=w(Za=>{"use strict";Object.defineProperty(Za,"__esModule",{value:!0});var Bd=Ke(),es=W(),Ud=X(),Gd=X(),h2={keyword:"patternProperties",type:"object",schemaType:"object",code(t){let{gen:e,schema:r,data:n,parentSchema:i,it:s}=t,{opts:o}=s,a=(0,Bd.allSchemaProperties)(r),l=a.filter(_=>(0,Ud.alwaysValidSchema)(s,r[_]));if(a.length===0||l.length===a.length&&(!s.opts.unevaluated||s.props===!0))return;let u=o.strictSchema&&!o.allowMatchingProperties&&i.properties,d=e.name("valid");s.props!==!0&&!(s.props instanceof es.Name)&&(s.props=(0,Gd.evaluatedPropsToName)(e,s.props));let{props:f}=s;h();function h(){for(let _ of a)u&&m(_),s.allErrors?g(_):(e.var(d,!0),g(_),e.if(d))}function m(_){for(let x in u)new RegExp(_).test(x)&&(0,Ud.checkStrictMode)(s,`property ${x} matches pattern ${_} (use allowMatchingProperties)`)}function g(_){e.forIn("key",n,x=>{e.if((0,es._)`${(0,Bd.usePattern)(t,_)}.test(${x})`,()=>{let E=l.includes(_);E||t.subschema({keyword:"patternProperties",schemaProp:_,dataProp:x,dataPropType:Gd.Type.Str},d),s.opts.unevaluated&&f!==!0?e.assign((0,es._)`${f}[${x}]`,!0):!E&&!s.allErrors&&e.if((0,es.not)(d),()=>e.break())})})}}};Za.default=h2});var Wd=w(ec=>{"use strict";Object.defineProperty(ec,"__esModule",{value:!0});var m2=X(),g2={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(t){let{gen:e,schema:r,it:n}=t;if((0,m2.alwaysValidSchema)(n,r)){t.fail();return}let i=e.name("valid");t.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),t.failResult(i,()=>t.reset(),()=>t.error())},error:{message:"must NOT be valid"}};ec.default=g2});var Kd=w(tc=>{"use strict";Object.defineProperty(tc,"__esModule",{value:!0});var y2=Ke(),v2={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:y2.validateUnion,error:{message:"must match a schema in anyOf"}};tc.default=v2});var Jd=w(rc=>{"use strict";Object.defineProperty(rc,"__esModule",{value:!0});var ts=W(),_2=X(),w2={message:"must match exactly one schema in oneOf",params:({params:t})=>(0,ts._)`{passingSchemas: ${t.passing}}`},b2={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:w2,code(t){let{gen:e,schema:r,parentSchema:n,it:i}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(i.opts.discriminator&&n.discriminator)return;let s=r,o=e.let("valid",!1),a=e.let("passing",null),l=e.name("_valid");t.setParams({passing:a}),e.block(u),t.result(o,()=>t.reset(),()=>t.error(!0));function u(){s.forEach((d,f)=>{let h;(0,_2.alwaysValidSchema)(i,d)?e.var(l,!0):h=t.subschema({keyword:"oneOf",schemaProp:f,compositeRule:!0},l),f>0&&e.if((0,ts._)`${l} && ${o}`).assign(o,!1).assign(a,(0,ts._)`[${a}, ${f}]`).else(),e.if(l,()=>{e.assign(o,!0),e.assign(a,f),h&&t.mergeEvaluated(h,ts.Name)})})}}};rc.default=b2});var Yd=w(nc=>{"use strict";Object.defineProperty(nc,"__esModule",{value:!0});var S2=X(),E2={keyword:"allOf",schemaType:"array",code(t){let{gen:e,schema:r,it:n}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");let i=e.name("valid");r.forEach((s,o)=>{if((0,S2.alwaysValidSchema)(n,s))return;let a=t.subschema({keyword:"allOf",schemaProp:o},i);t.ok(i),t.mergeEvaluated(a)})}};nc.default=E2});var Zd=w(ic=>{"use strict";Object.defineProperty(ic,"__esModule",{value:!0});var rs=W(),Qd=X(),$2={message:({params:t})=>(0,rs.str)`must match "${t.ifClause}" schema`,params:({params:t})=>(0,rs._)`{failingKeyword: ${t.ifClause}}`},C2={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:$2,code(t){let{gen:e,parentSchema:r,it:n}=t;r.then===void 0&&r.else===void 0&&(0,Qd.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let i=Xd(n,"then"),s=Xd(n,"else");if(!i&&!s)return;let o=e.let("valid",!0),a=e.name("_valid");if(l(),t.reset(),i&&s){let d=e.let("ifClause");t.setParams({ifClause:d}),e.if(a,u("then",d),u("else",d))}else i?e.if(a,u("then")):e.if((0,rs.not)(a),u("else"));t.pass(o,()=>t.error(!0));function l(){let d=t.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);t.mergeEvaluated(d)}function u(d,f){return()=>{let h=t.subschema({keyword:d},a);e.assign(o,a),t.mergeValidEvaluated(h,o),f?e.assign(f,(0,rs._)`${d}`):t.setParams({ifClause:d})}}}};function Xd(t,e){let r=t.schema[e];return r!==void 0&&!(0,Qd.alwaysValidSchema)(t,r)}ic.default=C2});var ep=w(sc=>{"use strict";Object.defineProperty(sc,"__esModule",{value:!0});var k2=X(),x2={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:t,parentSchema:e,it:r}){e.if===void 0&&(0,k2.checkStrictMode)(r,`"${t}" without "if" is ignored`)}};sc.default=x2});var tp=w(oc=>{"use strict";Object.defineProperty(oc,"__esModule",{value:!0});var P2=Ha(),O2=Id(),A2=Ba(),R2=Nd(),I2=Md(),T2=Xi(),N2=qd(),M2=Ya(),L2=Hd(),j2=zd(),D2=Wd(),q2=Kd(),V2=Jd(),F2=Yd(),H2=Zd(),B2=ep();function U2(t=!1){let e=[D2.default,q2.default,V2.default,F2.default,H2.default,B2.default,N2.default,M2.default,T2.default,L2.default,j2.default];return t?e.push(O2.default,R2.default):e.push(P2.default,A2.default),e.push(I2.default),e}oc.default=U2});var cc=w(Vn=>{"use strict";Object.defineProperty(Vn,"__esModule",{value:!0});Vn.dynamicAnchor=void 0;var ac=W(),G2=We(),rp=kn(),z2=Gi(),W2={keyword:"$dynamicAnchor",schemaType:"string",code:t=>np(t,t.schema)};function np(t,e){let{gen:r,it:n}=t;n.schemaEnv.root.dynamicAnchors[e]=!0;let i=(0,ac._)`${G2.default.dynamicAnchors}${(0,ac.getProperty)(e)}`,s=n.errSchemaPath==="#"?n.validateName:K2(t);r.if((0,ac._)`!${i}`,()=>r.assign(i,s))}Vn.dynamicAnchor=np;function K2(t){let{schemaEnv:e,schema:r,self:n}=t.it,{root:i,baseId:s,localRefs:o,meta:a}=e.root,{schemaId:l}=n.opts,u=new rp.SchemaEnv({schema:r,schemaId:l,root:i,baseId:s,localRefs:o,meta:a});return rp.compileSchema.call(n,u),(0,z2.getValidate)(t,u)}Vn.default=W2});var lc=w(Fn=>{"use strict";Object.defineProperty(Fn,"__esModule",{value:!0});Fn.dynamicRef=void 0;var ip=W(),J2=We(),sp=Gi(),Y2={keyword:"$dynamicRef",schemaType:"string",code:t=>op(t,t.schema)};function op(t,e){let{gen:r,keyword:n,it:i}=t;if(e[0]!=="#")throw new Error(`"${n}" only supports hash fragment reference`);let s=e.slice(1);if(i.allErrors)o();else{let l=r.let("valid",!1);o(l),t.ok(l)}function o(l){if(i.schemaEnv.root.dynamicAnchors[s]){let u=r.let("_v",(0,ip._)`${J2.default.dynamicAnchors}${(0,ip.getProperty)(s)}`);r.if(u,a(u,l),a(i.validateName,l))}else a(i.validateName,l)()}function a(l,u){return u?()=>r.block(()=>{(0,sp.callRef)(t,l),r.let(u,!0)}):()=>(0,sp.callRef)(t,l)}}Fn.dynamicRef=op;Fn.default=Y2});var ap=w(uc=>{"use strict";Object.defineProperty(uc,"__esModule",{value:!0});var X2=cc(),Q2=X(),Z2={keyword:"$recursiveAnchor",schemaType:"boolean",code(t){t.schema?(0,X2.dynamicAnchor)(t,""):(0,Q2.checkStrictMode)(t.it,"$recursiveAnchor: false is ignored")}};uc.default=Z2});var cp=w(fc=>{"use strict";Object.defineProperty(fc,"__esModule",{value:!0});var e1=lc(),t1={keyword:"$recursiveRef",schemaType:"string",code:t=>(0,e1.dynamicRef)(t,t.schema)};fc.default=t1});var lp=w(dc=>{"use strict";Object.defineProperty(dc,"__esModule",{value:!0});var r1=cc(),n1=lc(),i1=ap(),s1=cp(),o1=[r1.default,n1.default,i1.default,s1.default];dc.default=o1});var fp=w(pc=>{"use strict";Object.defineProperty(pc,"__esModule",{value:!0});var up=Xi(),a1={keyword:"dependentRequired",type:"object",schemaType:"object",error:up.error,code:t=>(0,up.validatePropertyDeps)(t)};pc.default=a1});var dp=w(hc=>{"use strict";Object.defineProperty(hc,"__esModule",{value:!0});var c1=Xi(),l1={keyword:"dependentSchemas",type:"object",schemaType:"object",code:t=>(0,c1.validateSchemaDeps)(t)};hc.default=l1});var pp=w(mc=>{"use strict";Object.defineProperty(mc,"__esModule",{value:!0});var u1=X(),f1={keyword:["maxContains","minContains"],type:"array",schemaType:"number",code({keyword:t,parentSchema:e,it:r}){e.contains===void 0&&(0,u1.checkStrictMode)(r,`"${t}" without "contains" is ignored`)}};mc.default=f1});var hp=w(gc=>{"use strict";Object.defineProperty(gc,"__esModule",{value:!0});var d1=fp(),p1=dp(),h1=pp(),m1=[d1.default,p1.default,h1.default];gc.default=m1});var gp=w(yc=>{"use strict";Object.defineProperty(yc,"__esModule",{value:!0});var Ut=W(),mp=X(),g1=We(),y1={message:"must NOT have unevaluated properties",params:({params:t})=>(0,Ut._)`{unevaluatedProperty: ${t.unevaluatedProperty}}`},v1={keyword:"unevaluatedProperties",type:"object",schemaType:["boolean","object"],trackErrors:!0,error:y1,code(t){let{gen:e,schema:r,data:n,errsCount:i,it:s}=t;if(!i)throw new Error("ajv implementation error");let{allErrors:o,props:a}=s;a instanceof Ut.Name?e.if((0,Ut._)`${a} !== true`,()=>e.forIn("key",n,f=>e.if(u(a,f),()=>l(f)))):a!==!0&&e.forIn("key",n,f=>a===void 0?l(f):e.if(d(a,f),()=>l(f))),s.props=!0,t.ok((0,Ut._)`${i} === ${g1.default.errors}`);function l(f){if(r===!1){t.setParams({unevaluatedProperty:f}),t.error(),o||e.break();return}if(!(0,mp.alwaysValidSchema)(s,r)){let h=e.name("valid");t.subschema({keyword:"unevaluatedProperties",dataProp:f,dataPropType:mp.Type.Str},h),o||e.if((0,Ut.not)(h),()=>e.break())}}function u(f,h){return(0,Ut._)`!${f} || !${f}[${h}]`}function d(f,h){let m=[];for(let g in f)f[g]===!0&&m.push((0,Ut._)`${h} !== ${g}`);return(0,Ut.and)(...m)}}};yc.default=v1});var vp=w(vc=>{"use strict";Object.defineProperty(vc,"__esModule",{value:!0});var ar=W(),yp=X(),_1={message:({params:{len:t}})=>(0,ar.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,ar._)`{limit: ${t}}`},w1={keyword:"unevaluatedItems",type:"array",schemaType:["boolean","object"],error:_1,code(t){let{gen:e,schema:r,data:n,it:i}=t,s=i.items||0;if(s===!0)return;let o=e.const("len",(0,ar._)`${n}.length`);if(r===!1)t.setParams({len:s}),t.fail((0,ar._)`${o} > ${s}`);else if(typeof r=="object"&&!(0,yp.alwaysValidSchema)(i,r)){let l=e.var("valid",(0,ar._)`${o} <= ${s}`);e.if((0,ar.not)(l),()=>a(l,s)),t.ok(l)}i.items=!0;function a(l,u){e.forRange("i",u,o,d=>{t.subschema({keyword:"unevaluatedItems",dataProp:d,dataPropType:yp.Type.Num},l),i.allErrors||e.if((0,ar.not)(l),()=>e.break())})}}};vc.default=w1});var _p=w(_c=>{"use strict";Object.defineProperty(_c,"__esModule",{value:!0});var b1=gp(),S1=vp(),E1=[b1.default,S1.default];_c.default=E1});var wp=w(wc=>{"use strict";Object.defineProperty(wc,"__esModule",{value:!0});var ye=W(),$1={message:({schemaCode:t})=>(0,ye.str)`must match format "${t}"`,params:({schemaCode:t})=>(0,ye._)`{format: ${t}}`},C1={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:$1,code(t,e){let{gen:r,data:n,$data:i,schema:s,schemaCode:o,it:a}=t,{opts:l,errSchemaPath:u,schemaEnv:d,self:f}=a;if(!l.validateFormats)return;i?h():m();function h(){let g=r.scopeValue("formats",{ref:f.formats,code:l.code.formats}),_=r.const("fDef",(0,ye._)`${g}[${o}]`),x=r.let("fType"),E=r.let("format");r.if((0,ye._)`typeof ${_} == "object" && !(${_} instanceof RegExp)`,()=>r.assign(x,(0,ye._)`${_}.type || "string"`).assign(E,(0,ye._)`${_}.validate`),()=>r.assign(x,(0,ye._)`"string"`).assign(E,_)),t.fail$data((0,ye.or)(V(),G()));function V(){return l.strictSchema===!1?ye.nil:(0,ye._)`${o} && !${E}`}function G(){let j=d.$async?(0,ye._)`(${_}.async ? await ${E}(${n}) : ${E}(${n}))`:(0,ye._)`${E}(${n})`,L=(0,ye._)`(typeof ${E} == "function" ? ${j} : ${E}.test(${n}))`;return(0,ye._)`${E} && ${E} !== true && ${x} === ${e} && !${L}`}}function m(){let g=f.formats[s];if(!g){V();return}if(g===!0)return;let[_,x,E]=G(g);_===e&&t.pass(j());function V(){if(l.strictSchema===!1){f.logger.warn(L());return}throw new Error(L());function L(){return`unknown format "${s}" ignored in schema at path "${u}"`}}function G(L){let Q=L instanceof RegExp?(0,ye.regexpCode)(L):l.code.formats?(0,ye._)`${l.code.formats}${(0,ye.getProperty)(s)}`:void 0,ne=r.scopeValue("formats",{key:s,ref:L,code:Q});return typeof L=="object"&&!(L instanceof RegExp)?[L.type||"string",L.validate,(0,ye._)`${ne}.validate`]:["string",L,ne]}function j(){if(typeof g=="object"&&!(g instanceof RegExp)&&g.async){if(!d.$async)throw new Error("async format in sync schema");return(0,ye._)`await ${E}(${n})`}return typeof x=="function"?(0,ye._)`${E}(${n})`:(0,ye._)`${E}.test(${n})`}}}};wc.default=C1});var bp=w(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});var k1=wp(),x1=[k1.default];bc.default=x1});var Sp=w(Tr=>{"use strict";Object.defineProperty(Tr,"__esModule",{value:!0});Tr.contentVocabulary=Tr.metadataVocabulary=void 0;Tr.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Tr.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var $p=w(Sc=>{"use strict";Object.defineProperty(Sc,"__esModule",{value:!0});var P1=hd(),O1=Pd(),A1=tp(),R1=lp(),I1=hp(),T1=_p(),N1=bp(),Ep=Sp(),M1=[R1.default,P1.default,O1.default,(0,A1.default)(!0),N1.default,Ep.metadataVocabulary,Ep.contentVocabulary,I1.default,T1.default];Sc.default=M1});var kp=w(ns=>{"use strict";Object.defineProperty(ns,"__esModule",{value:!0});ns.DiscrError=void 0;var Cp;(function(t){t.Tag="tag",t.Mapping="mapping"})(Cp||(ns.DiscrError=Cp={}))});var Pp=w($c=>{"use strict";Object.defineProperty($c,"__esModule",{value:!0});var Nr=W(),Ec=kp(),xp=kn(),L1=Cn(),j1=X(),D1={message:({params:{discrError:t,tagName:e}})=>t===Ec.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:t,tag:e,tagName:r}})=>(0,Nr._)`{error: ${t}, tag: ${r}, tagValue: ${e}}`},q1={keyword:"discriminator",type:"object",schemaType:"object",error:D1,code(t){let{gen:e,data:r,schema:n,parentSchema:i,it:s}=t,{oneOf:o}=i;if(!s.opts.discriminator)throw new Error("discriminator: requires discriminator option");let a=n.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!o)throw new Error("discriminator: requires oneOf keyword");let l=e.let("valid",!1),u=e.const("tag",(0,Nr._)`${r}${(0,Nr.getProperty)(a)}`);e.if((0,Nr._)`typeof ${u} == "string"`,()=>d(),()=>t.error(!1,{discrError:Ec.DiscrError.Tag,tag:u,tagName:a})),t.ok(l);function d(){let m=h();e.if(!1);for(let g in m)e.elseIf((0,Nr._)`${u} === ${g}`),e.assign(l,f(m[g]));e.else(),t.error(!1,{discrError:Ec.DiscrError.Mapping,tag:u,tagName:a}),e.endIf()}function f(m){let g=e.name("valid"),_=t.subschema({keyword:"oneOf",schemaProp:m},g);return t.mergeEvaluated(_,Nr.Name),g}function h(){var m;let g={},_=E(i),x=!0;for(let j=0;j<o.length;j++){let L=o[j];if(L?.$ref&&!(0,j1.schemaHasRulesButRef)(L,s.self.RULES)){let ne=L.$ref;if(L=xp.resolveRef.call(s.self,s.schemaEnv.root,s.baseId,ne),L instanceof xp.SchemaEnv&&(L=L.schema),L===void 0)throw new L1.default(s.opts.uriResolver,s.baseId,ne)}let Q=(m=L?.properties)===null||m===void 0?void 0:m[a];if(typeof Q!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);x=x&&(_||E(L)),V(Q,j)}if(!x)throw new Error(`discriminator: "${a}" must be required`);return g;function E({required:j}){return Array.isArray(j)&&j.includes(a)}function V(j,L){if(j.const)G(j.const,L);else if(j.enum)for(let Q of j.enum)G(Q,L);else throw new Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function G(j,L){if(typeof j!="string"||j in g)throw new Error(`discriminator: "${a}" values must be unique strings`);g[j]=L}}}};$c.default=q1});var Op=w((dP,V1)=>{V1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/schema",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/core":!0,"https://json-schema.org/draft/2020-12/vocab/applicator":!0,"https://json-schema.org/draft/2020-12/vocab/unevaluated":!0,"https://json-schema.org/draft/2020-12/vocab/validation":!0,"https://json-schema.org/draft/2020-12/vocab/meta-data":!0,"https://json-schema.org/draft/2020-12/vocab/format-annotation":!0,"https://json-schema.org/draft/2020-12/vocab/content":!0},$dynamicAnchor:"meta",title:"Core and Validation specifications meta-schema",allOf:[{$ref:"meta/core"},{$ref:"meta/applicator"},{$ref:"meta/unevaluated"},{$ref:"meta/validation"},{$ref:"meta/meta-data"},{$ref:"meta/format-annotation"},{$ref:"meta/content"}],type:["object","boolean"],$comment:"This meta-schema also defines keywords that have appeared in previous drafts in order to prevent incompatible extensions as they remain in common use.",properties:{definitions:{$comment:'"definitions" has been replaced by "$defs".',type:"object",additionalProperties:{$dynamicRef:"#meta"},deprecated:!0,default:{}},dependencies:{$comment:'"dependencies" has been split and replaced by "dependentSchemas" and "dependentRequired" in order to serve their differing semantics.',type:"object",additionalProperties:{anyOf:[{$dynamicRef:"#meta"},{$ref:"meta/validation#/$defs/stringArray"}]},deprecated:!0,default:{}},$recursiveAnchor:{$comment:'"$recursiveAnchor" has been replaced by "$dynamicAnchor".',$ref:"meta/core#/$defs/anchorString",deprecated:!0},$recursiveRef:{$comment:'"$recursiveRef" has been replaced by "$dynamicRef".',$ref:"meta/core#/$defs/uriReferenceString",deprecated:!0}}}});var Ap=w((pP,F1)=>{F1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/applicator",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/applicator":!0},$dynamicAnchor:"meta",title:"Applicator vocabulary meta-schema",type:["object","boolean"],properties:{prefixItems:{$ref:"#/$defs/schemaArray"},items:{$dynamicRef:"#meta"},contains:{$dynamicRef:"#meta"},additionalProperties:{$dynamicRef:"#meta"},properties:{type:"object",additionalProperties:{$dynamicRef:"#meta"},default:{}},patternProperties:{type:"object",additionalProperties:{$dynamicRef:"#meta"},propertyNames:{format:"regex"},default:{}},dependentSchemas:{type:"object",additionalProperties:{$dynamicRef:"#meta"},default:{}},propertyNames:{$dynamicRef:"#meta"},if:{$dynamicRef:"#meta"},then:{$dynamicRef:"#meta"},else:{$dynamicRef:"#meta"},allOf:{$ref:"#/$defs/schemaArray"},anyOf:{$ref:"#/$defs/schemaArray"},oneOf:{$ref:"#/$defs/schemaArray"},not:{$dynamicRef:"#meta"}},$defs:{schemaArray:{type:"array",minItems:1,items:{$dynamicRef:"#meta"}}}}});var Rp=w((hP,H1)=>{H1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/unevaluated",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/unevaluated":!0},$dynamicAnchor:"meta",title:"Unevaluated applicator vocabulary meta-schema",type:["object","boolean"],properties:{unevaluatedItems:{$dynamicRef:"#meta"},unevaluatedProperties:{$dynamicRef:"#meta"}}}});var Ip=w((mP,B1)=>{B1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/content",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/content":!0},$dynamicAnchor:"meta",title:"Content vocabulary meta-schema",type:["object","boolean"],properties:{contentEncoding:{type:"string"},contentMediaType:{type:"string"},contentSchema:{$dynamicRef:"#meta"}}}});var Tp=w((gP,U1)=>{U1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/core",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/core":!0},$dynamicAnchor:"meta",title:"Core vocabulary meta-schema",type:["object","boolean"],properties:{$id:{$ref:"#/$defs/uriReferenceString",$comment:"Non-empty fragments not allowed.",pattern:"^[^#]*#?$"},$schema:{$ref:"#/$defs/uriString"},$ref:{$ref:"#/$defs/uriReferenceString"},$anchor:{$ref:"#/$defs/anchorString"},$dynamicRef:{$ref:"#/$defs/uriReferenceString"},$dynamicAnchor:{$ref:"#/$defs/anchorString"},$vocabulary:{type:"object",propertyNames:{$ref:"#/$defs/uriString"},additionalProperties:{type:"boolean"}},$comment:{type:"string"},$defs:{type:"object",additionalProperties:{$dynamicRef:"#meta"}}},$defs:{anchorString:{type:"string",pattern:"^[A-Za-z_][-A-Za-z0-9._]*$"},uriString:{type:"string",format:"uri"},uriReferenceString:{type:"string",format:"uri-reference"}}}});var Np=w((yP,G1)=>{G1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/format-annotation",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/format-annotation":!0},$dynamicAnchor:"meta",title:"Format vocabulary meta-schema for annotation results",type:["object","boolean"],properties:{format:{type:"string"}}}});var Mp=w((vP,z1)=>{z1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/meta-data",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/meta-data":!0},$dynamicAnchor:"meta",title:"Meta-data vocabulary meta-schema",type:["object","boolean"],properties:{title:{type:"string"},description:{type:"string"},default:!0,deprecated:{type:"boolean",default:!1},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0}}}});var Lp=w((_P,W1)=>{W1.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/validation",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/validation":!0},$dynamicAnchor:"meta",title:"Validation vocabulary meta-schema",type:["object","boolean"],properties:{type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]},const:!0,enum:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}}},$defs:{nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}}});var jp=w(Cc=>{"use strict";Object.defineProperty(Cc,"__esModule",{value:!0});var K1=Op(),J1=Ap(),Y1=Rp(),X1=Ip(),Q1=Tp(),Z1=Np(),eb=Mp(),tb=Lp(),rb=["/properties"];function nb(t){return[K1,J1,Y1,X1,Q1,e(this,Z1),eb,e(this,tb)].forEach(r=>this.addMetaSchema(r,void 0,!1)),this;function e(r,n){return t?r.$dataMetaSchema(n,rb):n}}Cc.default=nb});var Dp=w((fe,xc)=>{"use strict";Object.defineProperty(fe,"__esModule",{value:!0});fe.MissingRefError=fe.ValidationError=fe.CodeGen=fe.Name=fe.nil=fe.stringify=fe.str=fe._=fe.KeywordCxt=fe.Ajv2020=void 0;var ib=ld(),sb=$p(),ob=Pp(),ab=jp(),kc="https://json-schema.org/draft/2020-12/schema",Mr=class extends ib.default{constructor(e={}){super({...e,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){super._addVocabularies(),sb.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(ob.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();let{$data:e,meta:r}=this.opts;r&&(ab.default.call(this,e),this.refs["http://json-schema.org/schema"]=kc)}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(kc)?kc:void 0)}};fe.Ajv2020=Mr;xc.exports=fe=Mr;xc.exports.Ajv2020=Mr;Object.defineProperty(fe,"__esModule",{value:!0});fe.default=Mr;var cb=$n();Object.defineProperty(fe,"KeywordCxt",{enumerable:!0,get:function(){return cb.KeywordCxt}});var Lr=W();Object.defineProperty(fe,"_",{enumerable:!0,get:function(){return Lr._}});Object.defineProperty(fe,"str",{enumerable:!0,get:function(){return Lr.str}});Object.defineProperty(fe,"stringify",{enumerable:!0,get:function(){return Lr.stringify}});Object.defineProperty(fe,"nil",{enumerable:!0,get:function(){return Lr.nil}});Object.defineProperty(fe,"Name",{enumerable:!0,get:function(){return Lr.Name}});Object.defineProperty(fe,"CodeGen",{enumerable:!0,get:function(){return Lr.CodeGen}});var lb=ji();Object.defineProperty(fe,"ValidationError",{enumerable:!0,get:function(){return lb.default}});var ub=Cn();Object.defineProperty(fe,"MissingRefError",{enumerable:!0,get:function(){return ub.default}})});var Te=w(Ve=>{"use strict";Ve.__esModule=!0;Ve.extend=gh;Ve.indexOf=yS;Ve.escapeExpression=vS;Ve.isEmpty=_S;Ve.createFrame=wS;Ve.blockParams=bS;Ve.appendContextPath=SS;var pS={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`","=":"="},hS=/[&<>"'`=]/g,mS=/[&<>"'`=]/;function gS(t){return pS[t]}function gh(t){for(var e=1;e<arguments.length;e++)for(var r in arguments[e])Object.prototype.hasOwnProperty.call(arguments[e],r)&&(t[r]=arguments[e][r]);return t}var Gc=Object.prototype.toString;Ve.toString=Gc;var Uc=function(e){return typeof e=="function"};Uc(/x/)&&(Ve.isFunction=Uc=function(t){return typeof t=="function"&&Gc.call(t)==="[object Function]"});Ve.isFunction=Uc;var yh=Array.isArray||function(t){return t&&typeof t=="object"?Gc.call(t)==="[object Array]":!1};Ve.isArray=yh;function yS(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}function vS(t){if(typeof t!="string"){if(t&&t.toHTML)return t.toHTML();if(t==null)return"";if(!t)return t+"";t=""+t}return mS.test(t)?t.replace(hS,gS):t}function _S(t){return!t&&t!==0?!0:!!(yh(t)&&t.length===0)}function wS(t){var e=gh({},t);return e._parent=t,e}function bS(t,e){return t.path=e,t}function SS(t,e){return(t?t+".":"")+e}});var Fe=w((ps,vh)=>{"use strict";ps.__esModule=!0;var zc=["description","fileName","lineNumber","endLineNumber","message","name","number","stack"];function Wc(t,e){var r=e&&e.loc,n=void 0,i=void 0,s=void 0,o=void 0;r&&(n=r.start.line,i=r.end.line,s=r.start.column,o=r.end.column,t+=" - "+n+":"+s);for(var a=Error.prototype.constructor.call(this,t),l=0;l<zc.length;l++)this[zc[l]]=a[zc[l]];Error.captureStackTrace&&Error.captureStackTrace(this,Wc);try{r&&(this.lineNumber=n,this.endLineNumber=i,Object.defineProperty?(Object.defineProperty(this,"column",{value:s,enumerable:!0}),Object.defineProperty(this,"endColumn",{value:o,enumerable:!0})):(this.column=s,this.endColumn=o))}catch{}}Wc.prototype=new Error;ps.default=Wc;vh.exports=ps.default});var wh=w((hs,_h)=>{"use strict";hs.__esModule=!0;var Kc=Te();hs.default=function(t){t.registerHelper("blockHelperMissing",function(e,r){var n=r.inverse,i=r.fn;if(e===!0)return i(this);if(e===!1||e==null)return n(this);if(Kc.isArray(e))return e.length>0?(r.ids&&(r.ids=[r.name]),t.helpers.each(e,r)):n(this);if(r.data&&r.ids){var s=Kc.createFrame(r.data);s.contextPath=Kc.appendContextPath(r.data.contextPath,r.name),r={data:s}}return i(e,r)})};_h.exports=hs.default});var Sh=w((ms,bh)=>{"use strict";ms.__esModule=!0;function ES(t){return t&&t.__esModule?t:{default:t}}var Wn=Te(),$S=Fe(),CS=ES($S);ms.default=function(t){t.registerHelper("each",function(e,r){if(!r)throw new CS.default("Must pass iterator to #each");var n=r.fn,i=r.inverse,s=0,o="",a=void 0,l=void 0;r.data&&r.ids&&(l=Wn.appendContextPath(r.data.contextPath,r.ids[0])+"."),Wn.isFunction(e)&&(e=e.call(this)),r.data&&(a=Wn.createFrame(r.data));function u(g,_,x){a&&(a.key=g,a.index=_,a.first=_===0,a.last=!!x,l&&(a.contextPath=l+g)),o=o+n(e[g],{data:a,blockParams:Wn.blockParams([e[g],g],[l+g,null])})}if(e&&typeof e=="object")if(Wn.isArray(e))for(var d=e.length;s<d;s++)s in e&&u(s,s,s===e.length-1);else if(typeof Symbol=="function"&&e[Symbol.iterator]){for(var f=[],h=e[Symbol.iterator](),m=h.next();!m.done;m=h.next())f.push(m.value);e=f;for(var d=e.length;s<d;s++)u(s,s,s===e.length-1)}else(function(){var g=void 0;Object.keys(e).forEach(function(_){g!==void 0&&u(g,s-1),g=_,s++}),g!==void 0&&u(g,s-1,!0)})();return s===0&&(o=i(this)),o})};bh.exports=ms.default});var $h=w((gs,Eh)=>{"use strict";gs.__esModule=!0;function kS(t){return t&&t.__esModule?t:{default:t}}var xS=Fe(),PS=kS(xS);gs.default=function(t){t.registerHelper("helperMissing",function(){if(arguments.length!==1)throw new PS.default('Missing helper: "'+arguments[arguments.length-1].name+'"')})};Eh.exports=gs.default});var Ph=w((ys,xh)=>{"use strict";ys.__esModule=!0;function OS(t){return t&&t.__esModule?t:{default:t}}var Ch=Te(),AS=Fe(),kh=OS(AS);ys.default=function(t){t.registerHelper("if",function(e,r){if(arguments.length!=2)throw new kh.default("#if requires exactly one argument");return Ch.isFunction(e)&&(e=e.call(this)),!r.hash.includeZero&&!e||Ch.isEmpty(e)?r.inverse(this):r.fn(this)}),t.registerHelper("unless",function(e,r){if(arguments.length!=2)throw new kh.default("#unless requires exactly one argument");return t.helpers.if.call(this,e,{fn:r.inverse,inverse:r.fn,hash:r.hash})})};xh.exports=ys.default});var Ah=w((vs,Oh)=>{"use strict";vs.__esModule=!0;vs.default=function(t){t.registerHelper("log",function(){for(var e=[void 0],r=arguments[arguments.length-1],n=0;n<arguments.length-1;n++)e.push(arguments[n]);var i=1;r.hash.level!=null?i=r.hash.level:r.data&&r.data.level!=null&&(i=r.data.level),e[0]=i,t.log.apply(t,e)})};Oh.exports=vs.default});var Ih=w((_s,Rh)=>{"use strict";_s.__esModule=!0;_s.default=function(t){t.registerHelper("lookup",function(e,r,n){return e&&n.lookupProperty(e,r)})};Rh.exports=_s.default});var Nh=w((ws,Th)=>{"use strict";ws.__esModule=!0;function RS(t){return t&&t.__esModule?t:{default:t}}var Kn=Te(),IS=Fe(),TS=RS(IS);ws.default=function(t){t.registerHelper("with",function(e,r){if(arguments.length!=2)throw new TS.default("#with requires exactly one argument");Kn.isFunction(e)&&(e=e.call(this));var n=r.fn;if(Kn.isEmpty(e))return r.inverse(this);var i=r.data;return r.data&&r.ids&&(i=Kn.createFrame(r.data),i.contextPath=Kn.appendContextPath(r.data.contextPath,r.ids[0])),n(e,{data:i,blockParams:Kn.blockParams([e],[i&&i.contextPath])})})};Th.exports=ws.default});var Jc=w(bs=>{"use strict";bs.__esModule=!0;bs.registerDefaultHelpers=KS;bs.moveHelperToHooks=JS;function cr(t){return t&&t.__esModule?t:{default:t}}var NS=wh(),MS=cr(NS),LS=Sh(),jS=cr(LS),DS=$h(),qS=cr(DS),VS=Ph(),FS=cr(VS),HS=Ah(),BS=cr(HS),US=Ih(),GS=cr(US),zS=Nh(),WS=cr(zS);function KS(t){MS.default(t),jS.default(t),qS.default(t),FS.default(t),BS.default(t),GS.default(t),WS.default(t)}function JS(t,e,r){t.helpers[e]&&(t.hooks[e]=t.helpers[e],r||(t.helpers[e]=void 0))}});var Lh=w((Ss,Mh)=>{"use strict";Ss.__esModule=!0;var YS=Te();Ss.default=function(t){t.registerDecorator("inline",function(e,r,n,i){var s=e;return r.partials||(r.partials={},s=function(o,a){var l=n.partials;n.partials=YS.extend({},l,r.partials);var u=e(o,a);return n.partials=l,u}),r.partials[i.args[0]]=i.fn,s})};Mh.exports=Ss.default});var jh=w(Yc=>{"use strict";Yc.__esModule=!0;Yc.registerDefaultDecorators=eE;function XS(t){return t&&t.__esModule?t:{default:t}}var QS=Lh(),ZS=XS(QS);function eE(t){ZS.default(t)}});var Xc=w((Es,Dh)=>{"use strict";Es.__esModule=!0;var tE=Te(),Br={methodMap:["debug","info","warn","error"],level:"info",lookupLevel:function(e){if(typeof e=="string"){var r=tE.indexOf(Br.methodMap,e.toLowerCase());r>=0?e=r:e=parseInt(e,10)}return e},log:function(e){if(e=Br.lookupLevel(e),typeof console<"u"&&Br.lookupLevel(Br.level)<=e){var r=Br.methodMap[e];console[r]||(r="log");for(var n=arguments.length,i=Array(n>1?n-1:0),s=1;s<n;s++)i[s-1]=arguments[s];console[r].apply(console,i)}}};Es.default=Br;Dh.exports=Es.default});var Qc=w(Jn=>{"use strict";Jn.__esModule=!0;Jn.createProtoAccessControl=sE;Jn.resultIsAllowed=oE;Jn.resetLoggedProperties=cE;function rE(t){return t&&t.__esModule?t:{default:t}}var qh=Te(),nE=Xc(),iE=rE(nE),$s=Object.create(null);function sE(t){var e=Object.create(null);e.__proto__=!1,qh.extend(e,t.allowedProtoProperties);var r=Object.create(null);return r.constructor=!1,r.__defineGetter__=!1,r.__defineSetter__=!1,r.__lookupGetter__=!1,r.__lookupSetter__=!1,qh.extend(r,t.allowedProtoMethods),{properties:{whitelist:e,defaultValue:t.allowProtoPropertiesByDefault},methods:{whitelist:r,defaultValue:t.allowProtoMethodsByDefault}}}function oE(t,e,r){return Vh(typeof t=="function"?e.methods:e.properties,r)}function Vh(t,e){return t.whitelist[e]!==void 0?t.whitelist[e]===!0:t.defaultValue!==void 0?t.defaultValue:(aE(e),!1)}function aE(t){$s[t]!==!0&&($s[t]=!0,iE.default.log("error",'Handlebars: Access has been denied to resolve the property "'+t+`" because it is not an "own property" of its parent.
|
|
36
|
+
deps: ${r}}`};var L2={keyword:"dependencies",type:"object",schemaType:"object",error:dt.error,code(t){let[e,r]=j2(t);ud(t,e),fd(t,r)}};function j2({schema:t}){let e={},r={};for(let n in t){if(n==="__proto__")continue;let i=Array.isArray(t[n])?e:r;i[n]=t[n]}return[e,r]}function ud(t,e=t.schema){let{gen:r,data:n,it:i}=t;if(Object.keys(e).length===0)return;let o=r.let("missing");for(let s in e){let a=e[s];if(a.length===0)continue;let l=(0,Hn.propertyInData)(r,n,s,i.opts.ownProperties);t.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),i.allErrors?r.if(l,()=>{for(let u of a)(0,Hn.checkReportMissingProp)(t,u)}):(r.if((0,cc._)`${l} && (${(0,Hn.checkMissingProp)(t,a,o)})`),(0,Hn.reportMissingProp)(t,o),r.else())}}dt.validatePropertyDeps=ud;function fd(t,e=t.schema){let{gen:r,data:n,keyword:i,it:o}=t,s=r.name("valid");for(let a in e)(0,M2.alwaysValidSchema)(o,e[a])||(r.if((0,Hn.propertyInData)(r,n,a,o.opts.ownProperties),()=>{let l=t.subschema({keyword:i,schemaProp:a},s);t.mergeValidEvaluated(l,s)},()=>r.var(s,!0)),t.ok(s))}dt.validateSchemaDeps=fd;dt.default=L2});var dd=w(lc=>{"use strict";Object.defineProperty(lc,"__esModule",{value:!0});var pd=z(),D2=X(),V2={message:"property name must be valid",params:({params:t})=>(0,pd._)`{propertyName: ${t.propertyName}}`},q2={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:V2,code(t){let{gen:e,schema:r,data:n,it:i}=t;if((0,D2.alwaysValidSchema)(i,r))return;let o=e.name("valid");e.forIn("key",n,s=>{t.setParams({propertyName:s}),t.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},o),e.if((0,pd.not)(o),()=>{t.error(!0),i.allErrors||e.break()})}),t.ok(o)}};lc.default=q2});var fc=w(uc=>{"use strict";Object.defineProperty(uc,"__esModule",{value:!0});var oo=ze(),at=z(),F2=We(),so=X(),H2={message:"must NOT have additional properties",params:({params:t})=>(0,at._)`{additionalProperty: ${t.additionalProperty}}`},B2={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:H2,code(t){let{gen:e,schema:r,parentSchema:n,data:i,errsCount:o,it:s}=t;if(!o)throw new Error("ajv implementation error");let{allErrors:a,opts:l}=s;if(s.props=!0,l.removeAdditional!=="all"&&(0,so.alwaysValidSchema)(s,r))return;let u=(0,oo.allSchemaProperties)(n.properties),p=(0,oo.allSchemaProperties)(n.patternProperties);f(),t.ok((0,at._)`${o} === ${F2.default.errors}`);function f(){e.forIn("key",i,P=>{!u.length&&!p.length?g(P):e.if(h(P),()=>g(P))})}function h(P){let b;if(u.length>8){let j=(0,so.schemaRefOrVal)(s,n.properties,"properties");b=(0,oo.isOwnProperty)(e,j,P)}else u.length?b=(0,at.or)(...u.map(j=>(0,at._)`${P} === ${j}`)):b=at.nil;return p.length&&(b=(0,at.or)(b,...p.map(j=>(0,at._)`${(0,oo.usePattern)(t,j)}.test(${P})`))),(0,at.not)(b)}function m(P){e.code((0,at._)`delete ${i}[${P}]`)}function g(P){if(l.removeAdditional==="all"||l.removeAdditional&&r===!1){m(P);return}if(r===!1){t.setParams({additionalProperty:P}),t.error(),a||e.break();return}if(typeof r=="object"&&!(0,so.alwaysValidSchema)(s,r)){let b=e.name("valid");l.removeAdditional==="failing"?(v(P,b,!1),e.if((0,at.not)(b),()=>{t.reset(),m(P)})):(v(P,b),a||e.if((0,at.not)(b),()=>e.break()))}}function v(P,b,j){let B={keyword:"additionalProperties",dataProp:P,dataPropType:so.Type.Str};j===!1&&Object.assign(B,{compositeRule:!0,createErrors:!1,allErrors:!1}),t.subschema(B,b)}}};uc.default=B2});var gd=w(dc=>{"use strict";Object.defineProperty(dc,"__esModule",{value:!0});var U2=Pn(),hd=ze(),pc=X(),md=fc(),G2={keyword:"properties",type:"object",schemaType:"object",code(t){let{gen:e,schema:r,parentSchema:n,data:i,it:o}=t;o.opts.removeAdditional==="all"&&n.additionalProperties===void 0&&md.default.code(new U2.KeywordCxt(o,md.default,"additionalProperties"));let s=(0,hd.allSchemaProperties)(r);for(let f of s)o.definedProperties.add(f);o.opts.unevaluated&&s.length&&o.props!==!0&&(o.props=pc.mergeEvaluated.props(e,(0,pc.toHash)(s),o.props));let a=s.filter(f=>!(0,pc.alwaysValidSchema)(o,r[f]));if(a.length===0)return;let l=e.name("valid");for(let f of a)u(f)?p(f):(e.if((0,hd.propertyInData)(e,i,f,o.opts.ownProperties)),p(f),o.allErrors||e.else().var(l,!0),e.endIf()),t.it.definedProperties.add(f),t.ok(l);function u(f){return o.opts.useDefaults&&!o.compositeRule&&r[f].default!==void 0}function p(f){t.subschema({keyword:"properties",schemaProp:f,dataProp:f},l)}}};dc.default=G2});var wd=w(hc=>{"use strict";Object.defineProperty(hc,"__esModule",{value:!0});var yd=ze(),ao=z(),vd=X(),_d=X(),W2={keyword:"patternProperties",type:"object",schemaType:"object",code(t){let{gen:e,schema:r,data:n,parentSchema:i,it:o}=t,{opts:s}=o,a=(0,yd.allSchemaProperties)(r),l=a.filter(v=>(0,vd.alwaysValidSchema)(o,r[v]));if(a.length===0||l.length===a.length&&(!o.opts.unevaluated||o.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&i.properties,p=e.name("valid");o.props!==!0&&!(o.props instanceof ao.Name)&&(o.props=(0,_d.evaluatedPropsToName)(e,o.props));let{props:f}=o;h();function h(){for(let v of a)u&&m(v),o.allErrors?g(v):(e.var(p,!0),g(v),e.if(p))}function m(v){for(let P in u)new RegExp(v).test(P)&&(0,vd.checkStrictMode)(o,`property ${P} matches pattern ${v} (use allowMatchingProperties)`)}function g(v){e.forIn("key",n,P=>{e.if((0,ao._)`${(0,yd.usePattern)(t,v)}.test(${P})`,()=>{let b=l.includes(v);b||t.subschema({keyword:"patternProperties",schemaProp:v,dataProp:P,dataPropType:_d.Type.Str},p),o.opts.unevaluated&&f!==!0?e.assign((0,ao._)`${f}[${P}]`,!0):!b&&!o.allErrors&&e.if((0,ao.not)(p),()=>e.break())})})}}};hc.default=W2});var bd=w(mc=>{"use strict";Object.defineProperty(mc,"__esModule",{value:!0});var z2=X(),K2={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(t){let{gen:e,schema:r,it:n}=t;if((0,z2.alwaysValidSchema)(n,r)){t.fail();return}let i=e.name("valid");t.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},i),t.failResult(i,()=>t.reset(),()=>t.error())},error:{message:"must NOT be valid"}};mc.default=K2});var Sd=w(gc=>{"use strict";Object.defineProperty(gc,"__esModule",{value:!0});var J2=ze(),Y2={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:J2.validateUnion,error:{message:"must match a schema in anyOf"}};gc.default=Y2});var Ed=w(yc=>{"use strict";Object.defineProperty(yc,"__esModule",{value:!0});var co=z(),X2=X(),Q2={message:"must match exactly one schema in oneOf",params:({params:t})=>(0,co._)`{passingSchemas: ${t.passing}}`},Z2={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:Q2,code(t){let{gen:e,schema:r,parentSchema:n,it:i}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(i.opts.discriminator&&n.discriminator)return;let o=r,s=e.let("valid",!1),a=e.let("passing",null),l=e.name("_valid");t.setParams({passing:a}),e.block(u),t.result(s,()=>t.reset(),()=>t.error(!0));function u(){o.forEach((p,f)=>{let h;(0,X2.alwaysValidSchema)(i,p)?e.var(l,!0):h=t.subschema({keyword:"oneOf",schemaProp:f,compositeRule:!0},l),f>0&&e.if((0,co._)`${l} && ${s}`).assign(s,!1).assign(a,(0,co._)`[${a}, ${f}]`).else(),e.if(l,()=>{e.assign(s,!0),e.assign(a,f),h&&t.mergeEvaluated(h,co.Name)})})}}};yc.default=Z2});var $d=w(vc=>{"use strict";Object.defineProperty(vc,"__esModule",{value:!0});var e1=X(),t1={keyword:"allOf",schemaType:"array",code(t){let{gen:e,schema:r,it:n}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");let i=e.name("valid");r.forEach((o,s)=>{if((0,e1.alwaysValidSchema)(n,o))return;let a=t.subschema({keyword:"allOf",schemaProp:s},i);t.ok(i),t.mergeEvaluated(a)})}};vc.default=t1});var Pd=w(_c=>{"use strict";Object.defineProperty(_c,"__esModule",{value:!0});var lo=z(),Cd=X(),r1={message:({params:t})=>(0,lo.str)`must match "${t.ifClause}" schema`,params:({params:t})=>(0,lo._)`{failingKeyword: ${t.ifClause}}`},n1={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:r1,code(t){let{gen:e,parentSchema:r,it:n}=t;r.then===void 0&&r.else===void 0&&(0,Cd.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let i=xd(n,"then"),o=xd(n,"else");if(!i&&!o)return;let s=e.let("valid",!0),a=e.name("_valid");if(l(),t.reset(),i&&o){let p=e.let("ifClause");t.setParams({ifClause:p}),e.if(a,u("then",p),u("else",p))}else i?e.if(a,u("then")):e.if((0,lo.not)(a),u("else"));t.pass(s,()=>t.error(!0));function l(){let p=t.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);t.mergeEvaluated(p)}function u(p,f){return()=>{let h=t.subschema({keyword:p},a);e.assign(s,a),t.mergeValidEvaluated(h,s),f?e.assign(f,(0,lo._)`${p}`):t.setParams({ifClause:p})}}}};function xd(t,e){let r=t.schema[e];return r!==void 0&&!(0,Cd.alwaysValidSchema)(t,r)}_c.default=n1});var kd=w(wc=>{"use strict";Object.defineProperty(wc,"__esModule",{value:!0});var i1=X(),o1={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:t,parentSchema:e,it:r}){e.if===void 0&&(0,i1.checkStrictMode)(r,`"${t}" without "if" is ignored`)}};wc.default=o1});var Ad=w(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});var s1=nc(),a1=sd(),c1=ic(),l1=cd(),u1=ld(),f1=io(),p1=dd(),d1=fc(),h1=gd(),m1=wd(),g1=bd(),y1=Sd(),v1=Ed(),_1=$d(),w1=Pd(),b1=kd();function S1(t=!1){let e=[g1.default,y1.default,v1.default,_1.default,w1.default,b1.default,p1.default,d1.default,f1.default,h1.default,m1.default];return t?e.push(a1.default,l1.default):e.push(s1.default,c1.default),e.push(u1.default),e}bc.default=S1});var Ec=w(Bn=>{"use strict";Object.defineProperty(Bn,"__esModule",{value:!0});Bn.dynamicAnchor=void 0;var Sc=z(),E1=We(),Od=An(),$1=Qi(),x1={keyword:"$dynamicAnchor",schemaType:"string",code:t=>Rd(t,t.schema)};function Rd(t,e){let{gen:r,it:n}=t;n.schemaEnv.root.dynamicAnchors[e]=!0;let i=(0,Sc._)`${E1.default.dynamicAnchors}${(0,Sc.getProperty)(e)}`,o=n.errSchemaPath==="#"?n.validateName:C1(t);r.if((0,Sc._)`!${i}`,()=>r.assign(i,o))}Bn.dynamicAnchor=Rd;function C1(t){let{schemaEnv:e,schema:r,self:n}=t.it,{root:i,baseId:o,localRefs:s,meta:a}=e.root,{schemaId:l}=n.opts,u=new Od.SchemaEnv({schema:r,schemaId:l,root:i,baseId:o,localRefs:s,meta:a});return Od.compileSchema.call(n,u),(0,$1.getValidate)(t,u)}Bn.default=x1});var $c=w(Un=>{"use strict";Object.defineProperty(Un,"__esModule",{value:!0});Un.dynamicRef=void 0;var Id=z(),P1=We(),Td=Qi(),k1={keyword:"$dynamicRef",schemaType:"string",code:t=>Nd(t,t.schema)};function Nd(t,e){let{gen:r,keyword:n,it:i}=t;if(e[0]!=="#")throw new Error(`"${n}" only supports hash fragment reference`);let o=e.slice(1);if(i.allErrors)s();else{let l=r.let("valid",!1);s(l),t.ok(l)}function s(l){if(i.schemaEnv.root.dynamicAnchors[o]){let u=r.let("_v",(0,Id._)`${P1.default.dynamicAnchors}${(0,Id.getProperty)(o)}`);r.if(u,a(u,l),a(i.validateName,l))}else a(i.validateName,l)()}function a(l,u){return u?()=>r.block(()=>{(0,Td.callRef)(t,l),r.let(u,!0)}):()=>(0,Td.callRef)(t,l)}}Un.dynamicRef=Nd;Un.default=k1});var Md=w(xc=>{"use strict";Object.defineProperty(xc,"__esModule",{value:!0});var A1=Ec(),O1=X(),R1={keyword:"$recursiveAnchor",schemaType:"boolean",code(t){t.schema?(0,A1.dynamicAnchor)(t,""):(0,O1.checkStrictMode)(t.it,"$recursiveAnchor: false is ignored")}};xc.default=R1});var Ld=w(Cc=>{"use strict";Object.defineProperty(Cc,"__esModule",{value:!0});var I1=$c(),T1={keyword:"$recursiveRef",schemaType:"string",code:t=>(0,I1.dynamicRef)(t,t.schema)};Cc.default=T1});var jd=w(Pc=>{"use strict";Object.defineProperty(Pc,"__esModule",{value:!0});var N1=Ec(),M1=$c(),L1=Md(),j1=Ld(),D1=[N1.default,M1.default,L1.default,j1.default];Pc.default=D1});var Vd=w(kc=>{"use strict";Object.defineProperty(kc,"__esModule",{value:!0});var Dd=io(),V1={keyword:"dependentRequired",type:"object",schemaType:"object",error:Dd.error,code:t=>(0,Dd.validatePropertyDeps)(t)};kc.default=V1});var qd=w(Ac=>{"use strict";Object.defineProperty(Ac,"__esModule",{value:!0});var q1=io(),F1={keyword:"dependentSchemas",type:"object",schemaType:"object",code:t=>(0,q1.validateSchemaDeps)(t)};Ac.default=F1});var Fd=w(Oc=>{"use strict";Object.defineProperty(Oc,"__esModule",{value:!0});var H1=X(),B1={keyword:["maxContains","minContains"],type:"array",schemaType:"number",code({keyword:t,parentSchema:e,it:r}){e.contains===void 0&&(0,H1.checkStrictMode)(r,`"${t}" without "contains" is ignored`)}};Oc.default=B1});var Hd=w(Rc=>{"use strict";Object.defineProperty(Rc,"__esModule",{value:!0});var U1=Vd(),G1=qd(),W1=Fd(),z1=[U1.default,G1.default,W1.default];Rc.default=z1});var Ud=w(Ic=>{"use strict";Object.defineProperty(Ic,"__esModule",{value:!0});var Bt=z(),Bd=X(),K1=We(),J1={message:"must NOT have unevaluated properties",params:({params:t})=>(0,Bt._)`{unevaluatedProperty: ${t.unevaluatedProperty}}`},Y1={keyword:"unevaluatedProperties",type:"object",schemaType:["boolean","object"],trackErrors:!0,error:J1,code(t){let{gen:e,schema:r,data:n,errsCount:i,it:o}=t;if(!i)throw new Error("ajv implementation error");let{allErrors:s,props:a}=o;a instanceof Bt.Name?e.if((0,Bt._)`${a} !== true`,()=>e.forIn("key",n,f=>e.if(u(a,f),()=>l(f)))):a!==!0&&e.forIn("key",n,f=>a===void 0?l(f):e.if(p(a,f),()=>l(f))),o.props=!0,t.ok((0,Bt._)`${i} === ${K1.default.errors}`);function l(f){if(r===!1){t.setParams({unevaluatedProperty:f}),t.error(),s||e.break();return}if(!(0,Bd.alwaysValidSchema)(o,r)){let h=e.name("valid");t.subschema({keyword:"unevaluatedProperties",dataProp:f,dataPropType:Bd.Type.Str},h),s||e.if((0,Bt.not)(h),()=>e.break())}}function u(f,h){return(0,Bt._)`!${f} || !${f}[${h}]`}function p(f,h){let m=[];for(let g in f)f[g]===!0&&m.push((0,Bt._)`${h} !== ${g}`);return(0,Bt.and)(...m)}}};Ic.default=Y1});var Wd=w(Tc=>{"use strict";Object.defineProperty(Tc,"__esModule",{value:!0});var lr=z(),Gd=X(),X1={message:({params:{len:t}})=>(0,lr.str)`must NOT have more than ${t} items`,params:({params:{len:t}})=>(0,lr._)`{limit: ${t}}`},Q1={keyword:"unevaluatedItems",type:"array",schemaType:["boolean","object"],error:X1,code(t){let{gen:e,schema:r,data:n,it:i}=t,o=i.items||0;if(o===!0)return;let s=e.const("len",(0,lr._)`${n}.length`);if(r===!1)t.setParams({len:o}),t.fail((0,lr._)`${s} > ${o}`);else if(typeof r=="object"&&!(0,Gd.alwaysValidSchema)(i,r)){let l=e.var("valid",(0,lr._)`${s} <= ${o}`);e.if((0,lr.not)(l),()=>a(l,o)),t.ok(l)}i.items=!0;function a(l,u){e.forRange("i",u,s,p=>{t.subschema({keyword:"unevaluatedItems",dataProp:p,dataPropType:Gd.Type.Num},l),i.allErrors||e.if((0,lr.not)(l),()=>e.break())})}}};Tc.default=Q1});var zd=w(Nc=>{"use strict";Object.defineProperty(Nc,"__esModule",{value:!0});var Z1=Ud(),eb=Wd(),tb=[Z1.default,eb.default];Nc.default=tb});var Kd=w(Mc=>{"use strict";Object.defineProperty(Mc,"__esModule",{value:!0});var ye=z(),rb={message:({schemaCode:t})=>(0,ye.str)`must match format "${t}"`,params:({schemaCode:t})=>(0,ye._)`{format: ${t}}`},nb={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:rb,code(t,e){let{gen:r,data:n,$data:i,schema:o,schemaCode:s,it:a}=t,{opts:l,errSchemaPath:u,schemaEnv:p,self:f}=a;if(!l.validateFormats)return;i?h():m();function h(){let g=r.scopeValue("formats",{ref:f.formats,code:l.code.formats}),v=r.const("fDef",(0,ye._)`${g}[${s}]`),P=r.let("fType"),b=r.let("format");r.if((0,ye._)`typeof ${v} == "object" && !(${v} instanceof RegExp)`,()=>r.assign(P,(0,ye._)`${v}.type || "string"`).assign(b,(0,ye._)`${v}.validate`),()=>r.assign(P,(0,ye._)`"string"`).assign(b,v)),t.fail$data((0,ye.or)(j(),B()));function j(){return l.strictSchema===!1?ye.nil:(0,ye._)`${s} && !${b}`}function B(){let L=p.$async?(0,ye._)`(${v}.async ? await ${b}(${n}) : ${b}(${n}))`:(0,ye._)`${b}(${n})`,T=(0,ye._)`(typeof ${b} == "function" ? ${L} : ${b}.test(${n}))`;return(0,ye._)`${b} && ${b} !== true && ${P} === ${e} && !${T}`}}function m(){let g=f.formats[o];if(!g){j();return}if(g===!0)return;let[v,P,b]=B(g);v===e&&t.pass(L());function j(){if(l.strictSchema===!1){f.logger.warn(T());return}throw new Error(T());function T(){return`unknown format "${o}" ignored in schema at path "${u}"`}}function B(T){let Q=T instanceof RegExp?(0,ye.regexpCode)(T):l.code.formats?(0,ye._)`${l.code.formats}${(0,ye.getProperty)(o)}`:void 0,ne=r.scopeValue("formats",{key:o,ref:T,code:Q});return typeof T=="object"&&!(T instanceof RegExp)?[T.type||"string",T.validate,(0,ye._)`${ne}.validate`]:["string",T,ne]}function L(){if(typeof g=="object"&&!(g instanceof RegExp)&&g.async){if(!p.$async)throw new Error("async format in sync schema");return(0,ye._)`await ${b}(${n})`}return typeof P=="function"?(0,ye._)`${b}(${n})`:(0,ye._)`${b}.test(${n})`}}}};Mc.default=nb});var Jd=w(Lc=>{"use strict";Object.defineProperty(Lc,"__esModule",{value:!0});var ib=Kd(),ob=[ib.default];Lc.default=ob});var Yd=w(Lr=>{"use strict";Object.defineProperty(Lr,"__esModule",{value:!0});Lr.contentVocabulary=Lr.metadataVocabulary=void 0;Lr.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Lr.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var Qd=w(jc=>{"use strict";Object.defineProperty(jc,"__esModule",{value:!0});var sb=Hp(),ab=rd(),cb=Ad(),lb=jd(),ub=Hd(),fb=zd(),pb=Jd(),Xd=Yd(),db=[lb.default,sb.default,ab.default,(0,cb.default)(!0),pb.default,Xd.metadataVocabulary,Xd.contentVocabulary,ub.default,fb.default];jc.default=db});var eh=w(uo=>{"use strict";Object.defineProperty(uo,"__esModule",{value:!0});uo.DiscrError=void 0;var Zd;(function(t){t.Tag="tag",t.Mapping="mapping"})(Zd||(uo.DiscrError=Zd={}))});var rh=w(Vc=>{"use strict";Object.defineProperty(Vc,"__esModule",{value:!0});var jr=z(),Dc=eh(),th=An(),hb=kn(),mb=X(),gb={message:({params:{discrError:t,tagName:e}})=>t===Dc.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:t,tag:e,tagName:r}})=>(0,jr._)`{error: ${t}, tag: ${r}, tagValue: ${e}}`},yb={keyword:"discriminator",type:"object",schemaType:"object",error:gb,code(t){let{gen:e,data:r,schema:n,parentSchema:i,it:o}=t,{oneOf:s}=i;if(!o.opts.discriminator)throw new Error("discriminator: requires discriminator option");let a=n.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(n.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");let l=e.let("valid",!1),u=e.const("tag",(0,jr._)`${r}${(0,jr.getProperty)(a)}`);e.if((0,jr._)`typeof ${u} == "string"`,()=>p(),()=>t.error(!1,{discrError:Dc.DiscrError.Tag,tag:u,tagName:a})),t.ok(l);function p(){let m=h();e.if(!1);for(let g in m)e.elseIf((0,jr._)`${u} === ${g}`),e.assign(l,f(m[g]));e.else(),t.error(!1,{discrError:Dc.DiscrError.Mapping,tag:u,tagName:a}),e.endIf()}function f(m){let g=e.name("valid"),v=t.subschema({keyword:"oneOf",schemaProp:m},g);return t.mergeEvaluated(v,jr.Name),g}function h(){var m;let g={},v=b(i),P=!0;for(let L=0;L<s.length;L++){let T=s[L];if(T?.$ref&&!(0,mb.schemaHasRulesButRef)(T,o.self.RULES)){let ne=T.$ref;if(T=th.resolveRef.call(o.self,o.schemaEnv.root,o.baseId,ne),T instanceof th.SchemaEnv&&(T=T.schema),T===void 0)throw new hb.default(o.opts.uriResolver,o.baseId,ne)}let Q=(m=T?.properties)===null||m===void 0?void 0:m[a];if(typeof Q!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);P=P&&(v||b(T)),j(Q,L)}if(!P)throw new Error(`discriminator: "${a}" must be required`);return g;function b({required:L}){return Array.isArray(L)&&L.includes(a)}function j(L,T){if(L.const)B(L.const,T);else if(L.enum)for(let Q of L.enum)B(Q,T);else throw new Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function B(L,T){if(typeof L!="string"||L in g)throw new Error(`discriminator: "${a}" values must be unique strings`);g[L]=T}}}};Vc.default=yb});var nh=w((aA,vb)=>{vb.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/schema",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/core":!0,"https://json-schema.org/draft/2020-12/vocab/applicator":!0,"https://json-schema.org/draft/2020-12/vocab/unevaluated":!0,"https://json-schema.org/draft/2020-12/vocab/validation":!0,"https://json-schema.org/draft/2020-12/vocab/meta-data":!0,"https://json-schema.org/draft/2020-12/vocab/format-annotation":!0,"https://json-schema.org/draft/2020-12/vocab/content":!0},$dynamicAnchor:"meta",title:"Core and Validation specifications meta-schema",allOf:[{$ref:"meta/core"},{$ref:"meta/applicator"},{$ref:"meta/unevaluated"},{$ref:"meta/validation"},{$ref:"meta/meta-data"},{$ref:"meta/format-annotation"},{$ref:"meta/content"}],type:["object","boolean"],$comment:"This meta-schema also defines keywords that have appeared in previous drafts in order to prevent incompatible extensions as they remain in common use.",properties:{definitions:{$comment:'"definitions" has been replaced by "$defs".',type:"object",additionalProperties:{$dynamicRef:"#meta"},deprecated:!0,default:{}},dependencies:{$comment:'"dependencies" has been split and replaced by "dependentSchemas" and "dependentRequired" in order to serve their differing semantics.',type:"object",additionalProperties:{anyOf:[{$dynamicRef:"#meta"},{$ref:"meta/validation#/$defs/stringArray"}]},deprecated:!0,default:{}},$recursiveAnchor:{$comment:'"$recursiveAnchor" has been replaced by "$dynamicAnchor".',$ref:"meta/core#/$defs/anchorString",deprecated:!0},$recursiveRef:{$comment:'"$recursiveRef" has been replaced by "$dynamicRef".',$ref:"meta/core#/$defs/uriReferenceString",deprecated:!0}}}});var ih=w((cA,_b)=>{_b.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/applicator",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/applicator":!0},$dynamicAnchor:"meta",title:"Applicator vocabulary meta-schema",type:["object","boolean"],properties:{prefixItems:{$ref:"#/$defs/schemaArray"},items:{$dynamicRef:"#meta"},contains:{$dynamicRef:"#meta"},additionalProperties:{$dynamicRef:"#meta"},properties:{type:"object",additionalProperties:{$dynamicRef:"#meta"},default:{}},patternProperties:{type:"object",additionalProperties:{$dynamicRef:"#meta"},propertyNames:{format:"regex"},default:{}},dependentSchemas:{type:"object",additionalProperties:{$dynamicRef:"#meta"},default:{}},propertyNames:{$dynamicRef:"#meta"},if:{$dynamicRef:"#meta"},then:{$dynamicRef:"#meta"},else:{$dynamicRef:"#meta"},allOf:{$ref:"#/$defs/schemaArray"},anyOf:{$ref:"#/$defs/schemaArray"},oneOf:{$ref:"#/$defs/schemaArray"},not:{$dynamicRef:"#meta"}},$defs:{schemaArray:{type:"array",minItems:1,items:{$dynamicRef:"#meta"}}}}});var oh=w((lA,wb)=>{wb.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/unevaluated",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/unevaluated":!0},$dynamicAnchor:"meta",title:"Unevaluated applicator vocabulary meta-schema",type:["object","boolean"],properties:{unevaluatedItems:{$dynamicRef:"#meta"},unevaluatedProperties:{$dynamicRef:"#meta"}}}});var sh=w((uA,bb)=>{bb.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/content",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/content":!0},$dynamicAnchor:"meta",title:"Content vocabulary meta-schema",type:["object","boolean"],properties:{contentEncoding:{type:"string"},contentMediaType:{type:"string"},contentSchema:{$dynamicRef:"#meta"}}}});var ah=w((fA,Sb)=>{Sb.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/core",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/core":!0},$dynamicAnchor:"meta",title:"Core vocabulary meta-schema",type:["object","boolean"],properties:{$id:{$ref:"#/$defs/uriReferenceString",$comment:"Non-empty fragments not allowed.",pattern:"^[^#]*#?$"},$schema:{$ref:"#/$defs/uriString"},$ref:{$ref:"#/$defs/uriReferenceString"},$anchor:{$ref:"#/$defs/anchorString"},$dynamicRef:{$ref:"#/$defs/uriReferenceString"},$dynamicAnchor:{$ref:"#/$defs/anchorString"},$vocabulary:{type:"object",propertyNames:{$ref:"#/$defs/uriString"},additionalProperties:{type:"boolean"}},$comment:{type:"string"},$defs:{type:"object",additionalProperties:{$dynamicRef:"#meta"}}},$defs:{anchorString:{type:"string",pattern:"^[A-Za-z_][-A-Za-z0-9._]*$"},uriString:{type:"string",format:"uri"},uriReferenceString:{type:"string",format:"uri-reference"}}}});var ch=w((pA,Eb)=>{Eb.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/format-annotation",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/format-annotation":!0},$dynamicAnchor:"meta",title:"Format vocabulary meta-schema for annotation results",type:["object","boolean"],properties:{format:{type:"string"}}}});var lh=w((dA,$b)=>{$b.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/meta-data",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/meta-data":!0},$dynamicAnchor:"meta",title:"Meta-data vocabulary meta-schema",type:["object","boolean"],properties:{title:{type:"string"},description:{type:"string"},default:!0,deprecated:{type:"boolean",default:!1},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0}}}});var uh=w((hA,xb)=>{xb.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/validation",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/validation":!0},$dynamicAnchor:"meta",title:"Validation vocabulary meta-schema",type:["object","boolean"],properties:{type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]},const:!0,enum:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}}},$defs:{nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}}});var fh=w(qc=>{"use strict";Object.defineProperty(qc,"__esModule",{value:!0});var Cb=nh(),Pb=ih(),kb=oh(),Ab=sh(),Ob=ah(),Rb=ch(),Ib=lh(),Tb=uh(),Nb=["/properties"];function Mb(t){return[Cb,Pb,kb,Ab,Ob,e(this,Rb),Ib,e(this,Tb)].forEach(r=>this.addMetaSchema(r,void 0,!1)),this;function e(r,n){return t?r.$dataMetaSchema(n,Nb):n}}qc.default=Mb});var Bc=w((fe,Hc)=>{"use strict";Object.defineProperty(fe,"__esModule",{value:!0});fe.MissingRefError=fe.ValidationError=fe.CodeGen=fe.Name=fe.nil=fe.stringify=fe.str=fe._=fe.KeywordCxt=fe.Ajv2020=void 0;var Lb=jp(),jb=Qd(),Db=rh(),Vb=fh(),Fc="https://json-schema.org/draft/2020-12/schema",Dr=class extends Lb.default{constructor(e={}){super({...e,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){super._addVocabularies(),jb.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(Db.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();let{$data:e,meta:r}=this.opts;r&&(Vb.default.call(this,e),this.refs["http://json-schema.org/schema"]=Fc)}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Fc)?Fc:void 0)}};fe.Ajv2020=Dr;Hc.exports=fe=Dr;Hc.exports.Ajv2020=Dr;Object.defineProperty(fe,"__esModule",{value:!0});fe.default=Dr;var qb=Pn();Object.defineProperty(fe,"KeywordCxt",{enumerable:!0,get:function(){return qb.KeywordCxt}});var Vr=z();Object.defineProperty(fe,"_",{enumerable:!0,get:function(){return Vr._}});Object.defineProperty(fe,"str",{enumerable:!0,get:function(){return Vr.str}});Object.defineProperty(fe,"stringify",{enumerable:!0,get:function(){return Vr.stringify}});Object.defineProperty(fe,"nil",{enumerable:!0,get:function(){return Vr.nil}});Object.defineProperty(fe,"Name",{enumerable:!0,get:function(){return Vr.Name}});Object.defineProperty(fe,"CodeGen",{enumerable:!0,get:function(){return Vr.CodeGen}});var Fb=Ui();Object.defineProperty(fe,"ValidationError",{enumerable:!0,get:function(){return Fb.default}});var Hb=kn();Object.defineProperty(fe,"MissingRefError",{enumerable:!0,get:function(){return Hb.default}})});var Te=w(qe=>{"use strict";qe.__esModule=!0;qe.extend=Qh;qe.indexOf=sE;qe.escapeExpression=aE;qe.isEmpty=cE;qe.createFrame=lE;qe.blockParams=uE;qe.appendContextPath=fE;var rE={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`","=":"="},nE=/[&<>"'`=]/g,iE=/[&<>"'`=]/;function oE(t){return rE[t]}function Qh(t){for(var e=1;e<arguments.length;e++)for(var r in arguments[e])Object.prototype.hasOwnProperty.call(arguments[e],r)&&(t[r]=arguments[e][r]);return t}var dl=Object.prototype.toString;qe.toString=dl;var pl=function(e){return typeof e=="function"};pl(/x/)&&(qe.isFunction=pl=function(t){return typeof t=="function"&&dl.call(t)==="[object Function]"});qe.isFunction=pl;var Zh=Array.isArray||function(t){return t&&typeof t=="object"?dl.call(t)==="[object Array]":!1};qe.isArray=Zh;function sE(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}function aE(t){if(typeof t!="string"){if(t&&t.toHTML)return t.toHTML();if(t==null)return"";if(!t)return t+"";t=""+t}return iE.test(t)?t.replace(nE,oE):t}function cE(t){return!t&&t!==0?!0:!!(Zh(t)&&t.length===0)}function lE(t){var e=Qh({},t);return e._parent=t,e}function uE(t,e){return t.path=e,t}function fE(t,e){return(t?t+".":"")+e}});var Fe=w((Po,em)=>{"use strict";Po.__esModule=!0;var hl=["description","fileName","lineNumber","endLineNumber","message","name","number","stack"];function ml(t,e){var r=e&&e.loc,n=void 0,i=void 0,o=void 0,s=void 0;r&&(n=r.start.line,i=r.end.line,o=r.start.column,s=r.end.column,t+=" - "+n+":"+o);for(var a=Error.prototype.constructor.call(this,t),l=0;l<hl.length;l++)this[hl[l]]=a[hl[l]];Error.captureStackTrace&&Error.captureStackTrace(this,ml);try{r&&(this.lineNumber=n,this.endLineNumber=i,Object.defineProperty?(Object.defineProperty(this,"column",{value:o,enumerable:!0}),Object.defineProperty(this,"endColumn",{value:s,enumerable:!0})):(this.column=o,this.endColumn=s))}catch{}}ml.prototype=new Error;Po.default=ml;em.exports=Po.default});var rm=w((ko,tm)=>{"use strict";ko.__esModule=!0;var gl=Te();ko.default=function(t){t.registerHelper("blockHelperMissing",function(e,r){var n=r.inverse,i=r.fn;if(e===!0)return i(this);if(e===!1||e==null)return n(this);if(gl.isArray(e))return e.length>0?(r.ids&&(r.ids=[r.name]),t.helpers.each(e,r)):n(this);if(r.data&&r.ids){var o=gl.createFrame(r.data);o.contextPath=gl.appendContextPath(r.data.contextPath,r.name),r={data:o}}return i(e,r)})};tm.exports=ko.default});var im=w((Ao,nm)=>{"use strict";Ao.__esModule=!0;function pE(t){return t&&t.__esModule?t:{default:t}}var Zn=Te(),dE=Fe(),hE=pE(dE);Ao.default=function(t){t.registerHelper("each",function(e,r){if(!r)throw new hE.default("Must pass iterator to #each");var n=r.fn,i=r.inverse,o=0,s="",a=void 0,l=void 0;r.data&&r.ids&&(l=Zn.appendContextPath(r.data.contextPath,r.ids[0])+"."),Zn.isFunction(e)&&(e=e.call(this)),r.data&&(a=Zn.createFrame(r.data));function u(g,v,P){a&&(a.key=g,a.index=v,a.first=v===0,a.last=!!P,l&&(a.contextPath=l+g)),s=s+n(e[g],{data:a,blockParams:Zn.blockParams([e[g],g],[l+g,null])})}if(e&&typeof e=="object")if(Zn.isArray(e))for(var p=e.length;o<p;o++)o in e&&u(o,o,o===e.length-1);else if(typeof Symbol=="function"&&e[Symbol.iterator]){for(var f=[],h=e[Symbol.iterator](),m=h.next();!m.done;m=h.next())f.push(m.value);e=f;for(var p=e.length;o<p;o++)u(o,o,o===e.length-1)}else(function(){var g=void 0;Object.keys(e).forEach(function(v){g!==void 0&&u(g,o-1),g=v,o++}),g!==void 0&&u(g,o-1,!0)})();return o===0&&(s=i(this)),s})};nm.exports=Ao.default});var sm=w((Oo,om)=>{"use strict";Oo.__esModule=!0;function mE(t){return t&&t.__esModule?t:{default:t}}var gE=Fe(),yE=mE(gE);Oo.default=function(t){t.registerHelper("helperMissing",function(){if(arguments.length!==1)throw new yE.default('Missing helper: "'+arguments[arguments.length-1].name+'"')})};om.exports=Oo.default});var um=w((Ro,lm)=>{"use strict";Ro.__esModule=!0;function vE(t){return t&&t.__esModule?t:{default:t}}var am=Te(),_E=Fe(),cm=vE(_E);Ro.default=function(t){t.registerHelper("if",function(e,r){if(arguments.length!=2)throw new cm.default("#if requires exactly one argument");return am.isFunction(e)&&(e=e.call(this)),!r.hash.includeZero&&!e||am.isEmpty(e)?r.inverse(this):r.fn(this)}),t.registerHelper("unless",function(e,r){if(arguments.length!=2)throw new cm.default("#unless requires exactly one argument");return t.helpers.if.call(this,e,{fn:r.inverse,inverse:r.fn,hash:r.hash})})};lm.exports=Ro.default});var pm=w((Io,fm)=>{"use strict";Io.__esModule=!0;Io.default=function(t){t.registerHelper("log",function(){for(var e=[void 0],r=arguments[arguments.length-1],n=0;n<arguments.length-1;n++)e.push(arguments[n]);var i=1;r.hash.level!=null?i=r.hash.level:r.data&&r.data.level!=null&&(i=r.data.level),e[0]=i,t.log.apply(t,e)})};fm.exports=Io.default});var hm=w((To,dm)=>{"use strict";To.__esModule=!0;To.default=function(t){t.registerHelper("lookup",function(e,r,n){return e&&n.lookupProperty(e,r)})};dm.exports=To.default});var gm=w((No,mm)=>{"use strict";No.__esModule=!0;function wE(t){return t&&t.__esModule?t:{default:t}}var ei=Te(),bE=Fe(),SE=wE(bE);No.default=function(t){t.registerHelper("with",function(e,r){if(arguments.length!=2)throw new SE.default("#with requires exactly one argument");ei.isFunction(e)&&(e=e.call(this));var n=r.fn;if(ei.isEmpty(e))return r.inverse(this);var i=r.data;return r.data&&r.ids&&(i=ei.createFrame(r.data),i.contextPath=ei.appendContextPath(r.data.contextPath,r.ids[0])),n(e,{data:i,blockParams:ei.blockParams([e],[i&&i.contextPath])})})};mm.exports=No.default});var yl=w(Mo=>{"use strict";Mo.__esModule=!0;Mo.registerDefaultHelpers=jE;Mo.moveHelperToHooks=DE;function pr(t){return t&&t.__esModule?t:{default:t}}var EE=rm(),$E=pr(EE),xE=im(),CE=pr(xE),PE=sm(),kE=pr(PE),AE=um(),OE=pr(AE),RE=pm(),IE=pr(RE),TE=hm(),NE=pr(TE),ME=gm(),LE=pr(ME);function jE(t){$E.default(t),CE.default(t),kE.default(t),OE.default(t),IE.default(t),NE.default(t),LE.default(t)}function DE(t,e,r){t.helpers[e]&&(t.hooks[e]=t.helpers[e],r||(t.helpers[e]=void 0))}});var vm=w((Lo,ym)=>{"use strict";Lo.__esModule=!0;var VE=Te();Lo.default=function(t){t.registerDecorator("inline",function(e,r,n,i){var o=e;return r.partials||(r.partials={},o=function(s,a){var l=n.partials;n.partials=VE.extend({},l,r.partials);var u=e(s,a);return n.partials=l,u}),r.partials[i.args[0]]=i.fn,o})};ym.exports=Lo.default});var _m=w(vl=>{"use strict";vl.__esModule=!0;vl.registerDefaultDecorators=BE;function qE(t){return t&&t.__esModule?t:{default:t}}var FE=vm(),HE=qE(FE);function BE(t){HE.default(t)}});var _l=w((jo,wm)=>{"use strict";jo.__esModule=!0;var UE=Te(),Wr={methodMap:["debug","info","warn","error"],level:"info",lookupLevel:function(e){if(typeof e=="string"){var r=UE.indexOf(Wr.methodMap,e.toLowerCase());r>=0?e=r:e=parseInt(e,10)}return e},log:function(e){if(e=Wr.lookupLevel(e),typeof console<"u"&&Wr.lookupLevel(Wr.level)<=e){var r=Wr.methodMap[e];console[r]||(r="log");for(var n=arguments.length,i=Array(n>1?n-1:0),o=1;o<n;o++)i[o-1]=arguments[o];console[r].apply(console,i)}}};jo.default=Wr;wm.exports=jo.default});var wl=w(ti=>{"use strict";ti.__esModule=!0;ti.createProtoAccessControl=KE;ti.resultIsAllowed=JE;ti.resetLoggedProperties=XE;function GE(t){return t&&t.__esModule?t:{default:t}}var bm=Te(),WE=_l(),zE=GE(WE),Do=Object.create(null);function KE(t){var e=Object.create(null);e.__proto__=!1,bm.extend(e,t.allowedProtoProperties);var r=Object.create(null);return r.constructor=!1,r.__defineGetter__=!1,r.__defineSetter__=!1,r.__lookupGetter__=!1,r.__lookupSetter__=!1,bm.extend(r,t.allowedProtoMethods),{properties:{whitelist:e,defaultValue:t.allowProtoPropertiesByDefault},methods:{whitelist:r,defaultValue:t.allowProtoMethodsByDefault}}}function JE(t,e,r){return Sm(typeof t=="function"?e.methods:e.properties,r)}function Sm(t,e){return t.whitelist[e]!==void 0?t.whitelist[e]===!0:t.defaultValue!==void 0?t.defaultValue:(YE(e),!1)}function YE(t){Do[t]!==!0&&(Do[t]=!0,zE.default.log("error",'Handlebars: Access has been denied to resolve the property "'+t+`" because it is not an "own property" of its parent.
|
|
37
37
|
You can add a runtime option to disable the check or this warning:
|
|
38
|
-
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}function
|
|
39
|
-
`),f=0,h=
|
|
40
|
-
`)}return u}else throw new It.default("The partial "+l.name+" could not be compiled when running in runtime-only mode")}var i={strict:function(a,l,u){if(!a||!(l in a))throw new It.default('"'+l+'" not defined in '+a,{loc:u});return i.lookupProperty(a,l)},lookupProperty:function(a,l){var u=a[l];if(u==null||Object.prototype.hasOwnProperty.call(a,l)||zh.resultIsAllowed(u,i.protoAccessControl,l))return u},lookup:function(a,l){for(var u=a.length,d=0;d<u;d++){var f=a[d]&&i.lookupProperty(a[d],l);if(f!=null)return f}},lambda:function(a,l){return typeof a=="function"?a.call(l):a},escapeExpression:Ur.escapeExpression,invokePartial:n,fn:function(a){var l=t[a];return l.decorator=t[a+"_d"],l},programs:[],program:function(a,l,u,d,f){var h=this.programs[a],m=this.fn(a);return l||f||d||u?h=Ps(this,a,m,l,u,d,f):h||(h=this.programs[a]=Ps(this,a,m)),h},data:function(a,l){for(;a&&l--;)a=a._parent;return a},mergeIfNeeded:function(a,l){var u=a||l;return a&&l&&a!==l&&(u=Ur.extend({},l,a)),u},nullContext:Object.seal({}),noop:e.VM.noop,compilerInfo:t.compiler};function s(o){var a=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],l=a.data;s._setup(a),!a.partial&&t.useData&&(l=OE(o,l));var u=void 0,d=t.useBlockParams?[]:void 0;t.useDepths&&(a.depths?u=o!=a.depths[0]?[o].concat(a.depths):a.depths:u=[o]);function f(h){return""+t.main(i,h,i.helpers,i.partials,l,d,u)}return f=Jh(t.main,f,i,a.depths||[],l,d),f(o,a)}return s.isTop=!0,s._setup=function(o){if(o.partial)i.protoAccessControl=o.protoAccessControl,i.helpers=o.helpers,i.partials=o.partials,i.decorators=o.decorators,i.hooks=o.hooks;else{var a={};Wh(a,e.helpers,i),Wh(a,o.helpers,i),i.helpers=a,t.usePartial&&(i.partials=i.mergeIfNeeded(o.partials,e.partials)),(t.usePartial||t.useDecorators)&&(i.decorators=Ur.extend({},e.decorators,o.decorators)),i.hooks={},i.protoAccessControl=zh.createProtoAccessControl(o);var l=o.allowCallsToHelperMissing||r;Gh.moveHelperToHooks(i,"helperMissing",l),Gh.moveHelperToHooks(i,"blockHelperMissing",l)}},s._child=function(o,a,l,u){if(t.useBlockParams&&!l)throw new It.default("must pass block params");if(t.useDepths&&!u)throw new It.default("must pass parent depths");return Ps(i,o,t[o],a,0,l,u)},s}function Ps(t,e,r,n,i,s,o){function a(l){var u=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],d=o;return o&&l!=o[0]&&!(l===t.nullContext&&o[0]===null)&&(d=[l].concat(o)),r(t,l,t.helpers,t.partials,u.data||n,s&&[u.blockParams].concat(s),d)}return a=Jh(r,a,t,o,n,s),a.program=e,a.depth=o?o.length:0,a.blockParams=i||0,a}function xE(t,e,r){return t?!t.call&&!r.name&&(r.name=t,t=Os(r.partials,t)):r.name==="@partial-block"?t=Os(r.data,"partial-block"):t=Os(r.partials,r.name),t}function PE(t,e,r){var n=Os(r.data,"partial-block");r.partial=!0,r.ids&&(r.data.contextPath=r.ids[0]||r.data.contextPath);var i=void 0;if(r.fn&&r.fn!==Kh&&(function(){r.data=Tt.createFrame(r.data);var s=r.fn;i=r.data["partial-block"]=function(a){var l=arguments.length<=1||arguments[1]===void 0?{}:arguments[1];return l.data=Tt.createFrame(l.data),l.data["partial-block"]=n,s(a,l)},s.partials&&(r.partials=Ur.extend({},r.partials,s.partials))})(),t===void 0&&i&&(t=i),t===void 0)throw new It.default("The partial "+r.name+" could not be found");if(t instanceof Function)return t(e,r)}function Kh(){return""}function Os(t,e){if(t&&Object.prototype.hasOwnProperty.call(t,e))return t[e]}function OE(t,e){return(!e||!("root"in e))&&(e=e?Tt.createFrame(e):{},e.root=t),e}function Jh(t,e,r,n,i,s){if(t.decorator){var o={};e=t.decorator(e,o,r,n&&n[0],i,s,n),Ur.extend(e,o)}return e}function Wh(t,e,r){e&&Object.keys(e).forEach(function(n){var i=e[n];t[n]=AE(i,r)})}function AE(t,e){var r=e.lookupProperty;return $E.wrapHelper(t,function(n){return n.lookupProperty=r,n})}});var il=w((As,Xh)=>{"use strict";As.__esModule=!0;As.default=function(t){(function(){typeof globalThis!="object"&&(Object.prototype.__defineGetter__("__magic__",function(){return this}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__)})();var e=globalThis.Handlebars;t.noConflict=function(){return globalThis.Handlebars===t&&(globalThis.Handlebars=e),t}};Xh.exports=As.default});var rm=w((Rs,tm)=>{"use strict";Rs.__esModule=!0;function ol(t){return t&&t.__esModule?t:{default:t}}function al(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var RE=ks(),Qh=al(RE),IE=Bh(),TE=ol(IE),NE=Fe(),ME=ol(NE),LE=Te(),sl=al(LE),jE=Yh(),Zh=al(jE),DE=il(),qE=ol(DE);function em(){var t=new Qh.HandlebarsEnvironment;return sl.extend(t,Qh),t.SafeString=TE.default,t.Exception=ME.default,t.Utils=sl,t.escapeExpression=sl.escapeExpression,t.VM=Zh,t.template=function(e){return Zh.template(e,t)},t}var Yn=em();Yn.create=em;qE.default(Yn);Yn.default=Yn;Rs.default=Yn;tm.exports=Rs.default});var cl=w((Is,im)=>{"use strict";Is.__esModule=!0;var nm={helpers:{helperExpression:function(e){return e.type==="SubExpression"||(e.type==="MustacheStatement"||e.type==="BlockStatement")&&!!(e.params&&e.params.length||e.hash)},scopedId:function(e){return/^\.|this\b/.test(e.original)},simpleId:function(e){return e.parts.length===1&&!nm.helpers.scopedId(e)&&!e.depth}}};Is.default=nm;im.exports=Is.default});var om=w((Ts,sm)=>{"use strict";Ts.__esModule=!0;var VE=(function(){var t={trace:function(){},yy:{},symbols_:{error:2,root:3,program:4,EOF:5,program_repetition0:6,statement:7,mustache:8,block:9,rawBlock:10,partial:11,partialBlock:12,content:13,COMMENT:14,CONTENT:15,openRawBlock:16,rawBlock_repetition0:17,END_RAW_BLOCK:18,OPEN_RAW_BLOCK:19,helperName:20,openRawBlock_repetition0:21,openRawBlock_option0:22,CLOSE_RAW_BLOCK:23,openBlock:24,block_option0:25,closeBlock:26,openInverse:27,block_option1:28,OPEN_BLOCK:29,openBlock_repetition0:30,openBlock_option0:31,openBlock_option1:32,CLOSE:33,OPEN_INVERSE:34,openInverse_repetition0:35,openInverse_option0:36,openInverse_option1:37,openInverseChain:38,OPEN_INVERSE_CHAIN:39,openInverseChain_repetition0:40,openInverseChain_option0:41,openInverseChain_option1:42,inverseAndProgram:43,INVERSE:44,inverseChain:45,inverseChain_option0:46,OPEN_ENDBLOCK:47,OPEN:48,mustache_repetition0:49,mustache_option0:50,OPEN_UNESCAPED:51,mustache_repetition1:52,mustache_option1:53,CLOSE_UNESCAPED:54,OPEN_PARTIAL:55,partialName:56,partial_repetition0:57,partial_option0:58,openPartialBlock:59,OPEN_PARTIAL_BLOCK:60,openPartialBlock_repetition0:61,openPartialBlock_option0:62,param:63,sexpr:64,OPEN_SEXPR:65,sexpr_repetition0:66,sexpr_option0:67,CLOSE_SEXPR:68,hash:69,hash_repetition_plus0:70,hashSegment:71,ID:72,EQUALS:73,blockParams:74,OPEN_BLOCK_PARAMS:75,blockParams_repetition_plus0:76,CLOSE_BLOCK_PARAMS:77,path:78,dataName:79,STRING:80,NUMBER:81,BOOLEAN:82,UNDEFINED:83,NULL:84,DATA:85,pathSegments:86,SEP:87,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",14:"COMMENT",15:"CONTENT",18:"END_RAW_BLOCK",19:"OPEN_RAW_BLOCK",23:"CLOSE_RAW_BLOCK",29:"OPEN_BLOCK",33:"CLOSE",34:"OPEN_INVERSE",39:"OPEN_INVERSE_CHAIN",44:"INVERSE",47:"OPEN_ENDBLOCK",48:"OPEN",51:"OPEN_UNESCAPED",54:"CLOSE_UNESCAPED",55:"OPEN_PARTIAL",60:"OPEN_PARTIAL_BLOCK",65:"OPEN_SEXPR",68:"CLOSE_SEXPR",72:"ID",73:"EQUALS",75:"OPEN_BLOCK_PARAMS",77:"CLOSE_BLOCK_PARAMS",80:"STRING",81:"NUMBER",82:"BOOLEAN",83:"UNDEFINED",84:"NULL",85:"DATA",87:"SEP"},productions_:[0,[3,2],[4,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[13,1],[10,3],[16,5],[9,4],[9,4],[24,6],[27,6],[38,6],[43,2],[45,3],[45,1],[26,3],[8,5],[8,5],[11,5],[12,3],[59,5],[63,1],[63,1],[64,5],[69,1],[71,3],[74,3],[20,1],[20,1],[20,1],[20,1],[20,1],[20,1],[20,1],[56,1],[56,1],[79,2],[78,1],[86,3],[86,1],[6,0],[6,2],[17,0],[17,2],[21,0],[21,2],[22,0],[22,1],[25,0],[25,1],[28,0],[28,1],[30,0],[30,2],[31,0],[31,1],[32,0],[32,1],[35,0],[35,2],[36,0],[36,1],[37,0],[37,1],[40,0],[40,2],[41,0],[41,1],[42,0],[42,1],[46,0],[46,1],[49,0],[49,2],[50,0],[50,1],[52,0],[52,2],[53,0],[53,1],[57,0],[57,2],[58,0],[58,1],[61,0],[61,2],[62,0],[62,1],[66,0],[66,2],[67,0],[67,1],[70,1],[70,2],[76,1],[76,2]],performAction:function(i,s,o,a,l,u,d){var f=u.length-1;switch(l){case 1:return u[f-1];case 2:this.$=a.prepareProgram(u[f]);break;case 3:this.$=u[f];break;case 4:this.$=u[f];break;case 5:this.$=u[f];break;case 6:this.$=u[f];break;case 7:this.$=u[f];break;case 8:this.$=u[f];break;case 9:this.$={type:"CommentStatement",value:a.stripComment(u[f]),strip:a.stripFlags(u[f],u[f]),loc:a.locInfo(this._$)};break;case 10:this.$={type:"ContentStatement",original:u[f],value:u[f],loc:a.locInfo(this._$)};break;case 11:this.$=a.prepareRawBlock(u[f-2],u[f-1],u[f],this._$);break;case 12:this.$={path:u[f-3],params:u[f-2],hash:u[f-1]};break;case 13:this.$=a.prepareBlock(u[f-3],u[f-2],u[f-1],u[f],!1,this._$);break;case 14:this.$=a.prepareBlock(u[f-3],u[f-2],u[f-1],u[f],!0,this._$);break;case 15:this.$={open:u[f-5],path:u[f-4],params:u[f-3],hash:u[f-2],blockParams:u[f-1],strip:a.stripFlags(u[f-5],u[f])};break;case 16:this.$={path:u[f-4],params:u[f-3],hash:u[f-2],blockParams:u[f-1],strip:a.stripFlags(u[f-5],u[f])};break;case 17:this.$={path:u[f-4],params:u[f-3],hash:u[f-2],blockParams:u[f-1],strip:a.stripFlags(u[f-5],u[f])};break;case 18:this.$={strip:a.stripFlags(u[f-1],u[f-1]),program:u[f]};break;case 19:var h=a.prepareBlock(u[f-2],u[f-1],u[f],u[f],!1,this._$),m=a.prepareProgram([h],u[f-1].loc);m.chained=!0,this.$={strip:u[f-2].strip,program:m,chain:!0};break;case 20:this.$=u[f];break;case 21:this.$={path:u[f-1],strip:a.stripFlags(u[f-2],u[f])};break;case 22:this.$=a.prepareMustache(u[f-3],u[f-2],u[f-1],u[f-4],a.stripFlags(u[f-4],u[f]),this._$);break;case 23:this.$=a.prepareMustache(u[f-3],u[f-2],u[f-1],u[f-4],a.stripFlags(u[f-4],u[f]),this._$);break;case 24:this.$={type:"PartialStatement",name:u[f-3],params:u[f-2],hash:u[f-1],indent:"",strip:a.stripFlags(u[f-4],u[f]),loc:a.locInfo(this._$)};break;case 25:this.$=a.preparePartialBlock(u[f-2],u[f-1],u[f],this._$);break;case 26:this.$={path:u[f-3],params:u[f-2],hash:u[f-1],strip:a.stripFlags(u[f-4],u[f])};break;case 27:this.$=u[f];break;case 28:this.$=u[f];break;case 29:this.$={type:"SubExpression",path:u[f-3],params:u[f-2],hash:u[f-1],loc:a.locInfo(this._$)};break;case 30:this.$={type:"Hash",pairs:u[f],loc:a.locInfo(this._$)};break;case 31:this.$={type:"HashPair",key:a.id(u[f-2]),value:u[f],loc:a.locInfo(this._$)};break;case 32:this.$=a.id(u[f-1]);break;case 33:this.$=u[f];break;case 34:this.$=u[f];break;case 35:this.$={type:"StringLiteral",value:u[f],original:u[f],loc:a.locInfo(this._$)};break;case 36:this.$={type:"NumberLiteral",value:Number(u[f]),original:Number(u[f]),loc:a.locInfo(this._$)};break;case 37:this.$={type:"BooleanLiteral",value:u[f]==="true",original:u[f]==="true",loc:a.locInfo(this._$)};break;case 38:this.$={type:"UndefinedLiteral",original:void 0,value:void 0,loc:a.locInfo(this._$)};break;case 39:this.$={type:"NullLiteral",original:null,value:null,loc:a.locInfo(this._$)};break;case 40:this.$=u[f];break;case 41:this.$=u[f];break;case 42:this.$=a.preparePath(!0,u[f],this._$);break;case 43:this.$=a.preparePath(!1,u[f],this._$);break;case 44:u[f-2].push({part:a.id(u[f]),original:u[f],separator:u[f-1]}),this.$=u[f-2];break;case 45:this.$=[{part:a.id(u[f]),original:u[f]}];break;case 46:this.$=[];break;case 47:u[f-1].push(u[f]);break;case 48:this.$=[];break;case 49:u[f-1].push(u[f]);break;case 50:this.$=[];break;case 51:u[f-1].push(u[f]);break;case 58:this.$=[];break;case 59:u[f-1].push(u[f]);break;case 64:this.$=[];break;case 65:u[f-1].push(u[f]);break;case 70:this.$=[];break;case 71:u[f-1].push(u[f]);break;case 78:this.$=[];break;case 79:u[f-1].push(u[f]);break;case 82:this.$=[];break;case 83:u[f-1].push(u[f]);break;case 86:this.$=[];break;case 87:u[f-1].push(u[f]);break;case 90:this.$=[];break;case 91:u[f-1].push(u[f]);break;case 94:this.$=[];break;case 95:u[f-1].push(u[f]);break;case 98:this.$=[u[f]];break;case 99:u[f-1].push(u[f]);break;case 100:this.$=[u[f]];break;case 101:u[f-1].push(u[f]);break}},table:[{3:1,4:2,5:[2,46],6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{1:[3]},{5:[1,4]},{5:[2,2],7:5,8:6,9:7,10:8,11:9,12:10,13:11,14:[1,12],15:[1,20],16:17,19:[1,23],24:15,27:16,29:[1,21],34:[1,22],39:[2,2],44:[2,2],47:[2,2],48:[1,13],51:[1,14],55:[1,18],59:19,60:[1,24]},{1:[2,1]},{5:[2,47],14:[2,47],15:[2,47],19:[2,47],29:[2,47],34:[2,47],39:[2,47],44:[2,47],47:[2,47],48:[2,47],51:[2,47],55:[2,47],60:[2,47]},{5:[2,3],14:[2,3],15:[2,3],19:[2,3],29:[2,3],34:[2,3],39:[2,3],44:[2,3],47:[2,3],48:[2,3],51:[2,3],55:[2,3],60:[2,3]},{5:[2,4],14:[2,4],15:[2,4],19:[2,4],29:[2,4],34:[2,4],39:[2,4],44:[2,4],47:[2,4],48:[2,4],51:[2,4],55:[2,4],60:[2,4]},{5:[2,5],14:[2,5],15:[2,5],19:[2,5],29:[2,5],34:[2,5],39:[2,5],44:[2,5],47:[2,5],48:[2,5],51:[2,5],55:[2,5],60:[2,5]},{5:[2,6],14:[2,6],15:[2,6],19:[2,6],29:[2,6],34:[2,6],39:[2,6],44:[2,6],47:[2,6],48:[2,6],51:[2,6],55:[2,6],60:[2,6]},{5:[2,7],14:[2,7],15:[2,7],19:[2,7],29:[2,7],34:[2,7],39:[2,7],44:[2,7],47:[2,7],48:[2,7],51:[2,7],55:[2,7],60:[2,7]},{5:[2,8],14:[2,8],15:[2,8],19:[2,8],29:[2,8],34:[2,8],39:[2,8],44:[2,8],47:[2,8],48:[2,8],51:[2,8],55:[2,8],60:[2,8]},{5:[2,9],14:[2,9],15:[2,9],19:[2,9],29:[2,9],34:[2,9],39:[2,9],44:[2,9],47:[2,9],48:[2,9],51:[2,9],55:[2,9],60:[2,9]},{20:25,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:36,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{4:37,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],39:[2,46],44:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{4:38,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],44:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{15:[2,48],17:39,18:[2,48]},{20:41,56:40,64:42,65:[1,43],72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{4:44,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{5:[2,10],14:[2,10],15:[2,10],18:[2,10],19:[2,10],29:[2,10],34:[2,10],39:[2,10],44:[2,10],47:[2,10],48:[2,10],51:[2,10],55:[2,10],60:[2,10]},{20:45,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:46,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:47,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:41,56:48,64:42,65:[1,43],72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{33:[2,78],49:49,65:[2,78],72:[2,78],80:[2,78],81:[2,78],82:[2,78],83:[2,78],84:[2,78],85:[2,78]},{23:[2,33],33:[2,33],54:[2,33],65:[2,33],68:[2,33],72:[2,33],75:[2,33],80:[2,33],81:[2,33],82:[2,33],83:[2,33],84:[2,33],85:[2,33]},{23:[2,34],33:[2,34],54:[2,34],65:[2,34],68:[2,34],72:[2,34],75:[2,34],80:[2,34],81:[2,34],82:[2,34],83:[2,34],84:[2,34],85:[2,34]},{23:[2,35],33:[2,35],54:[2,35],65:[2,35],68:[2,35],72:[2,35],75:[2,35],80:[2,35],81:[2,35],82:[2,35],83:[2,35],84:[2,35],85:[2,35]},{23:[2,36],33:[2,36],54:[2,36],65:[2,36],68:[2,36],72:[2,36],75:[2,36],80:[2,36],81:[2,36],82:[2,36],83:[2,36],84:[2,36],85:[2,36]},{23:[2,37],33:[2,37],54:[2,37],65:[2,37],68:[2,37],72:[2,37],75:[2,37],80:[2,37],81:[2,37],82:[2,37],83:[2,37],84:[2,37],85:[2,37]},{23:[2,38],33:[2,38],54:[2,38],65:[2,38],68:[2,38],72:[2,38],75:[2,38],80:[2,38],81:[2,38],82:[2,38],83:[2,38],84:[2,38],85:[2,38]},{23:[2,39],33:[2,39],54:[2,39],65:[2,39],68:[2,39],72:[2,39],75:[2,39],80:[2,39],81:[2,39],82:[2,39],83:[2,39],84:[2,39],85:[2,39]},{23:[2,43],33:[2,43],54:[2,43],65:[2,43],68:[2,43],72:[2,43],75:[2,43],80:[2,43],81:[2,43],82:[2,43],83:[2,43],84:[2,43],85:[2,43],87:[1,50]},{72:[1,35],86:51},{23:[2,45],33:[2,45],54:[2,45],65:[2,45],68:[2,45],72:[2,45],75:[2,45],80:[2,45],81:[2,45],82:[2,45],83:[2,45],84:[2,45],85:[2,45],87:[2,45]},{52:52,54:[2,82],65:[2,82],72:[2,82],80:[2,82],81:[2,82],82:[2,82],83:[2,82],84:[2,82],85:[2,82]},{25:53,38:55,39:[1,57],43:56,44:[1,58],45:54,47:[2,54]},{28:59,43:60,44:[1,58],47:[2,56]},{13:62,15:[1,20],18:[1,61]},{33:[2,86],57:63,65:[2,86],72:[2,86],80:[2,86],81:[2,86],82:[2,86],83:[2,86],84:[2,86],85:[2,86]},{33:[2,40],65:[2,40],72:[2,40],80:[2,40],81:[2,40],82:[2,40],83:[2,40],84:[2,40],85:[2,40]},{33:[2,41],65:[2,41],72:[2,41],80:[2,41],81:[2,41],82:[2,41],83:[2,41],84:[2,41],85:[2,41]},{20:64,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{26:65,47:[1,66]},{30:67,33:[2,58],65:[2,58],72:[2,58],75:[2,58],80:[2,58],81:[2,58],82:[2,58],83:[2,58],84:[2,58],85:[2,58]},{33:[2,64],35:68,65:[2,64],72:[2,64],75:[2,64],80:[2,64],81:[2,64],82:[2,64],83:[2,64],84:[2,64],85:[2,64]},{21:69,23:[2,50],65:[2,50],72:[2,50],80:[2,50],81:[2,50],82:[2,50],83:[2,50],84:[2,50],85:[2,50]},{33:[2,90],61:70,65:[2,90],72:[2,90],80:[2,90],81:[2,90],82:[2,90],83:[2,90],84:[2,90],85:[2,90]},{20:74,33:[2,80],50:71,63:72,64:75,65:[1,43],69:73,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{72:[1,79]},{23:[2,42],33:[2,42],54:[2,42],65:[2,42],68:[2,42],72:[2,42],75:[2,42],80:[2,42],81:[2,42],82:[2,42],83:[2,42],84:[2,42],85:[2,42],87:[1,50]},{20:74,53:80,54:[2,84],63:81,64:75,65:[1,43],69:82,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{26:83,47:[1,66]},{47:[2,55]},{4:84,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],39:[2,46],44:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{47:[2,20]},{20:85,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{4:86,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{26:87,47:[1,66]},{47:[2,57]},{5:[2,11],14:[2,11],15:[2,11],19:[2,11],29:[2,11],34:[2,11],39:[2,11],44:[2,11],47:[2,11],48:[2,11],51:[2,11],55:[2,11],60:[2,11]},{15:[2,49],18:[2,49]},{20:74,33:[2,88],58:88,63:89,64:75,65:[1,43],69:90,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{65:[2,94],66:91,68:[2,94],72:[2,94],80:[2,94],81:[2,94],82:[2,94],83:[2,94],84:[2,94],85:[2,94]},{5:[2,25],14:[2,25],15:[2,25],19:[2,25],29:[2,25],34:[2,25],39:[2,25],44:[2,25],47:[2,25],48:[2,25],51:[2,25],55:[2,25],60:[2,25]},{20:92,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,31:93,33:[2,60],63:94,64:75,65:[1,43],69:95,70:76,71:77,72:[1,78],75:[2,60],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,33:[2,66],36:96,63:97,64:75,65:[1,43],69:98,70:76,71:77,72:[1,78],75:[2,66],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,22:99,23:[2,52],63:100,64:75,65:[1,43],69:101,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,33:[2,92],62:102,63:103,64:75,65:[1,43],69:104,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{33:[1,105]},{33:[2,79],65:[2,79],72:[2,79],80:[2,79],81:[2,79],82:[2,79],83:[2,79],84:[2,79],85:[2,79]},{33:[2,81]},{23:[2,27],33:[2,27],54:[2,27],65:[2,27],68:[2,27],72:[2,27],75:[2,27],80:[2,27],81:[2,27],82:[2,27],83:[2,27],84:[2,27],85:[2,27]},{23:[2,28],33:[2,28],54:[2,28],65:[2,28],68:[2,28],72:[2,28],75:[2,28],80:[2,28],81:[2,28],82:[2,28],83:[2,28],84:[2,28],85:[2,28]},{23:[2,30],33:[2,30],54:[2,30],68:[2,30],71:106,72:[1,107],75:[2,30]},{23:[2,98],33:[2,98],54:[2,98],68:[2,98],72:[2,98],75:[2,98]},{23:[2,45],33:[2,45],54:[2,45],65:[2,45],68:[2,45],72:[2,45],73:[1,108],75:[2,45],80:[2,45],81:[2,45],82:[2,45],83:[2,45],84:[2,45],85:[2,45],87:[2,45]},{23:[2,44],33:[2,44],54:[2,44],65:[2,44],68:[2,44],72:[2,44],75:[2,44],80:[2,44],81:[2,44],82:[2,44],83:[2,44],84:[2,44],85:[2,44],87:[2,44]},{54:[1,109]},{54:[2,83],65:[2,83],72:[2,83],80:[2,83],81:[2,83],82:[2,83],83:[2,83],84:[2,83],85:[2,83]},{54:[2,85]},{5:[2,13],14:[2,13],15:[2,13],19:[2,13],29:[2,13],34:[2,13],39:[2,13],44:[2,13],47:[2,13],48:[2,13],51:[2,13],55:[2,13],60:[2,13]},{38:55,39:[1,57],43:56,44:[1,58],45:111,46:110,47:[2,76]},{33:[2,70],40:112,65:[2,70],72:[2,70],75:[2,70],80:[2,70],81:[2,70],82:[2,70],83:[2,70],84:[2,70],85:[2,70]},{47:[2,18]},{5:[2,14],14:[2,14],15:[2,14],19:[2,14],29:[2,14],34:[2,14],39:[2,14],44:[2,14],47:[2,14],48:[2,14],51:[2,14],55:[2,14],60:[2,14]},{33:[1,113]},{33:[2,87],65:[2,87],72:[2,87],80:[2,87],81:[2,87],82:[2,87],83:[2,87],84:[2,87],85:[2,87]},{33:[2,89]},{20:74,63:115,64:75,65:[1,43],67:114,68:[2,96],69:116,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{33:[1,117]},{32:118,33:[2,62],74:119,75:[1,120]},{33:[2,59],65:[2,59],72:[2,59],75:[2,59],80:[2,59],81:[2,59],82:[2,59],83:[2,59],84:[2,59],85:[2,59]},{33:[2,61],75:[2,61]},{33:[2,68],37:121,74:122,75:[1,120]},{33:[2,65],65:[2,65],72:[2,65],75:[2,65],80:[2,65],81:[2,65],82:[2,65],83:[2,65],84:[2,65],85:[2,65]},{33:[2,67],75:[2,67]},{23:[1,123]},{23:[2,51],65:[2,51],72:[2,51],80:[2,51],81:[2,51],82:[2,51],83:[2,51],84:[2,51],85:[2,51]},{23:[2,53]},{33:[1,124]},{33:[2,91],65:[2,91],72:[2,91],80:[2,91],81:[2,91],82:[2,91],83:[2,91],84:[2,91],85:[2,91]},{33:[2,93]},{5:[2,22],14:[2,22],15:[2,22],19:[2,22],29:[2,22],34:[2,22],39:[2,22],44:[2,22],47:[2,22],48:[2,22],51:[2,22],55:[2,22],60:[2,22]},{23:[2,99],33:[2,99],54:[2,99],68:[2,99],72:[2,99],75:[2,99]},{73:[1,108]},{20:74,63:125,64:75,65:[1,43],72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{5:[2,23],14:[2,23],15:[2,23],19:[2,23],29:[2,23],34:[2,23],39:[2,23],44:[2,23],47:[2,23],48:[2,23],51:[2,23],55:[2,23],60:[2,23]},{47:[2,19]},{47:[2,77]},{20:74,33:[2,72],41:126,63:127,64:75,65:[1,43],69:128,70:76,71:77,72:[1,78],75:[2,72],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{5:[2,24],14:[2,24],15:[2,24],19:[2,24],29:[2,24],34:[2,24],39:[2,24],44:[2,24],47:[2,24],48:[2,24],51:[2,24],55:[2,24],60:[2,24]},{68:[1,129]},{65:[2,95],68:[2,95],72:[2,95],80:[2,95],81:[2,95],82:[2,95],83:[2,95],84:[2,95],85:[2,95]},{68:[2,97]},{5:[2,21],14:[2,21],15:[2,21],19:[2,21],29:[2,21],34:[2,21],39:[2,21],44:[2,21],47:[2,21],48:[2,21],51:[2,21],55:[2,21],60:[2,21]},{33:[1,130]},{33:[2,63]},{72:[1,132],76:131},{33:[1,133]},{33:[2,69]},{15:[2,12],18:[2,12]},{14:[2,26],15:[2,26],19:[2,26],29:[2,26],34:[2,26],47:[2,26],48:[2,26],51:[2,26],55:[2,26],60:[2,26]},{23:[2,31],33:[2,31],54:[2,31],68:[2,31],72:[2,31],75:[2,31]},{33:[2,74],42:134,74:135,75:[1,120]},{33:[2,71],65:[2,71],72:[2,71],75:[2,71],80:[2,71],81:[2,71],82:[2,71],83:[2,71],84:[2,71],85:[2,71]},{33:[2,73],75:[2,73]},{23:[2,29],33:[2,29],54:[2,29],65:[2,29],68:[2,29],72:[2,29],75:[2,29],80:[2,29],81:[2,29],82:[2,29],83:[2,29],84:[2,29],85:[2,29]},{14:[2,15],15:[2,15],19:[2,15],29:[2,15],34:[2,15],39:[2,15],44:[2,15],47:[2,15],48:[2,15],51:[2,15],55:[2,15],60:[2,15]},{72:[1,137],77:[1,136]},{72:[2,100],77:[2,100]},{14:[2,16],15:[2,16],19:[2,16],29:[2,16],34:[2,16],44:[2,16],47:[2,16],48:[2,16],51:[2,16],55:[2,16],60:[2,16]},{33:[1,138]},{33:[2,75]},{33:[2,32]},{72:[2,101],77:[2,101]},{14:[2,17],15:[2,17],19:[2,17],29:[2,17],34:[2,17],39:[2,17],44:[2,17],47:[2,17],48:[2,17],51:[2,17],55:[2,17],60:[2,17]}],defaultActions:{4:[2,1],54:[2,55],56:[2,20],60:[2,57],73:[2,81],82:[2,85],86:[2,18],90:[2,89],101:[2,53],104:[2,93],110:[2,19],111:[2,77],116:[2,97],119:[2,63],122:[2,69],135:[2,75],136:[2,32]},parseError:function(i,s){throw new Error(i)},parse:function(i){var s=this,o=[0],a=[null],l=[],u=this.table,d="",f=0,h=0,m=0,g=2,_=1;this.lexer.setInput(i),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.yy.parser=this,typeof this.lexer.yylloc>"u"&&(this.lexer.yylloc={});var x=this.lexer.yylloc;l.push(x);var E=this.lexer.options&&this.lexer.options.ranges;typeof this.yy.parseError=="function"&&(this.parseError=this.yy.parseError);function V(se){o.length=o.length-2*se,a.length=a.length-se,l.length=l.length-se}function G(){var se;return se=s.lexer.lex()||1,typeof se!="number"&&(se=s.symbols_[se]||se),se}for(var j,L,Q,ne,Mt,nt,_e={},Ne,Ee,it,st;;){if(Q=o[o.length-1],this.defaultActions[Q]?ne=this.defaultActions[Q]:((j===null||typeof j>"u")&&(j=G()),ne=u[Q]&&u[Q][j]),typeof ne>"u"||!ne.length||!ne[0]){var bt="";if(!m){st=[];for(Ne in u[Q])this.terminals_[Ne]&&Ne>2&&st.push("'"+this.terminals_[Ne]+"'");this.lexer.showPosition?bt="Parse error on line "+(f+1)+`:
|
|
38
|
+
See https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details`))}function XE(){Object.keys(Do).forEach(function(t){delete Do[t]})}});var qo=w(mt=>{"use strict";mt.__esModule=!0;mt.HandlebarsEnvironment=El;function Em(t){return t&&t.__esModule?t:{default:t}}var dr=Te(),QE=Fe(),bl=Em(QE),ZE=yl(),e$=_m(),t$=_l(),Vo=Em(t$),r$=wl(),n$="4.7.9";mt.VERSION=n$;var i$=8;mt.COMPILER_REVISION=i$;var o$=7;mt.LAST_COMPATIBLE_COMPILER_REVISION=o$;var s$={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1",7:">= 4.0.0 <4.3.0",8:">= 4.3.0"};mt.REVISION_CHANGES=s$;var Sl="[object Object]";function El(t,e,r){this.helpers=t||{},this.partials=e||{},this.decorators=r||{},ZE.registerDefaultHelpers(this),e$.registerDefaultDecorators(this)}El.prototype={constructor:El,logger:Vo.default,log:Vo.default.log,registerHelper:function(e,r){if(dr.toString.call(e)===Sl){if(r)throw new bl.default("Arg not supported with multiple helpers");dr.extend(this.helpers,e)}else this.helpers[e]=r},unregisterHelper:function(e){delete this.helpers[e]},registerPartial:function(e,r){if(dr.toString.call(e)===Sl)dr.extend(this.partials,e);else{if(typeof r>"u")throw new bl.default('Attempting to register a partial called "'+e+'" as undefined');this.partials[e]=r}},unregisterPartial:function(e){delete this.partials[e]},registerDecorator:function(e,r){if(dr.toString.call(e)===Sl){if(r)throw new bl.default("Arg not supported with multiple decorators");dr.extend(this.decorators,e)}else this.decorators[e]=r},unregisterDecorator:function(e){delete this.decorators[e]},resetLoggedPropertyAccesses:function(){r$.resetLoggedProperties()}};var a$=Vo.default.log;mt.log=a$;mt.createFrame=dr.createFrame;mt.logger=Vo.default});var xm=w((Fo,$m)=>{"use strict";Fo.__esModule=!0;function $l(t){this.string=t}$l.prototype.toString=$l.prototype.toHTML=function(){return""+this.string};Fo.default=$l;$m.exports=Fo.default});var Cm=w(xl=>{"use strict";xl.__esModule=!0;xl.wrapHelper=c$;function c$(t,e){if(typeof t!="function")return t;var r=function(){var i=arguments[arguments.length-1];return arguments[arguments.length-1]=e(i),t.apply(this,arguments)};return r}});var Im=w(Gt=>{"use strict";Gt.__esModule=!0;Gt.checkRevision=h$;Gt.template=m$;Gt.wrapProgram=Ho;Gt.resolvePartial=g$;Gt.invokePartial=y$;Gt.noop=Om;function l$(t){return t&&t.__esModule?t:{default:t}}function u$(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var f$=Te(),zr=u$(f$),p$=Fe(),Ot=l$(p$),Rt=qo(),Pm=yl(),d$=Cm(),km=wl();function h$(t){var e=t&&t[0]||1,r=Rt.COMPILER_REVISION;if(!(e>=Rt.LAST_COMPATIBLE_COMPILER_REVISION&&e<=Rt.COMPILER_REVISION))if(e<Rt.LAST_COMPATIBLE_COMPILER_REVISION){var n=Rt.REVISION_CHANGES[r],i=Rt.REVISION_CHANGES[e];throw new Ot.default("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+n+") or downgrade your runtime to an older version ("+i+").")}else throw new Ot.default("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+t[1]+").")}function m$(t,e){if(!e)throw new Ot.default("No environment passed to template");if(!t||!t.main)throw new Ot.default("Unknown template object: "+typeof t);t.main.decorator=t.main_d,e.VM.checkRevision(t.compiler);var r=t.compiler&&t.compiler[0]===7;function n(s,a,l){l.hash&&(a=zr.extend({},a,l.hash),l.ids&&(l.ids[0]=!0)),s=e.VM.resolvePartial.call(this,s,a,l),l.hooks=this.hooks,l.protoAccessControl=this.protoAccessControl;var u=e.VM.invokePartial.call(this,s,a,l);if(u==null&&e.compile&&(l.partials[l.name]=e.compile(s,t.compilerOptions,e),u=l.partials[l.name](a,l)),u!=null){if(l.indent){for(var p=u.split(`
|
|
39
|
+
`),f=0,h=p.length;f<h&&!(!p[f]&&f+1===h);f++)p[f]=l.indent+p[f];u=p.join(`
|
|
40
|
+
`)}return u}else throw new Ot.default("The partial "+l.name+" could not be compiled when running in runtime-only mode")}var i={strict:function(a,l,u){if(!a||!(l in a))throw new Ot.default('"'+l+'" not defined in '+a,{loc:u});return i.lookupProperty(a,l)},lookupProperty:function(a,l){var u=a[l];if(u==null||Object.prototype.hasOwnProperty.call(a,l)||km.resultIsAllowed(u,i.protoAccessControl,l))return u},lookup:function(a,l){for(var u=a.length,p=0;p<u;p++){var f=a[p]&&i.lookupProperty(a[p],l);if(f!=null)return f}},lambda:function(a,l){return typeof a=="function"?a.call(l):a},escapeExpression:zr.escapeExpression,invokePartial:n,fn:function(a){var l=t[a];return l.decorator=t[a+"_d"],l},programs:[],program:function(a,l,u,p,f){var h=this.programs[a],m=this.fn(a);return l||f||p||u?h=Ho(this,a,m,l,u,p,f):h||(h=this.programs[a]=Ho(this,a,m)),h},data:function(a,l){for(;a&&l--;)a=a._parent;return a},mergeIfNeeded:function(a,l){var u=a||l;return a&&l&&a!==l&&(u=zr.extend({},l,a)),u},nullContext:Object.seal({}),noop:e.VM.noop,compilerInfo:t.compiler};function o(s){var a=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],l=a.data;o._setup(a),!a.partial&&t.useData&&(l=v$(s,l));var u=void 0,p=t.useBlockParams?[]:void 0;t.useDepths&&(a.depths?u=s!=a.depths[0]?[s].concat(a.depths):a.depths:u=[s]);function f(h){return""+t.main(i,h,i.helpers,i.partials,l,p,u)}return f=Rm(t.main,f,i,a.depths||[],l,p),f(s,a)}return o.isTop=!0,o._setup=function(s){if(s.partial)i.protoAccessControl=s.protoAccessControl,i.helpers=s.helpers,i.partials=s.partials,i.decorators=s.decorators,i.hooks=s.hooks;else{var a={};Am(a,e.helpers,i),Am(a,s.helpers,i),i.helpers=a,t.usePartial&&(i.partials=i.mergeIfNeeded(s.partials,e.partials)),(t.usePartial||t.useDecorators)&&(i.decorators=zr.extend({},e.decorators,s.decorators)),i.hooks={},i.protoAccessControl=km.createProtoAccessControl(s);var l=s.allowCallsToHelperMissing||r;Pm.moveHelperToHooks(i,"helperMissing",l),Pm.moveHelperToHooks(i,"blockHelperMissing",l)}},o._child=function(s,a,l,u){if(t.useBlockParams&&!l)throw new Ot.default("must pass block params");if(t.useDepths&&!u)throw new Ot.default("must pass parent depths");return Ho(i,s,t[s],a,0,l,u)},o}function Ho(t,e,r,n,i,o,s){function a(l){var u=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],p=s;return s&&l!=s[0]&&!(l===t.nullContext&&s[0]===null)&&(p=[l].concat(s)),r(t,l,t.helpers,t.partials,u.data||n,o&&[u.blockParams].concat(o),p)}return a=Rm(r,a,t,s,n,o),a.program=e,a.depth=s?s.length:0,a.blockParams=i||0,a}function g$(t,e,r){return t?!t.call&&!r.name&&(r.name=t,t=Bo(r.partials,t)):r.name==="@partial-block"?t=Bo(r.data,"partial-block"):t=Bo(r.partials,r.name),t}function y$(t,e,r){var n=Bo(r.data,"partial-block");r.partial=!0,r.ids&&(r.data.contextPath=r.ids[0]||r.data.contextPath);var i=void 0;if(r.fn&&r.fn!==Om&&(function(){r.data=Rt.createFrame(r.data);var o=r.fn;i=r.data["partial-block"]=function(a){var l=arguments.length<=1||arguments[1]===void 0?{}:arguments[1];return l.data=Rt.createFrame(l.data),l.data["partial-block"]=n,o(a,l)},o.partials&&(r.partials=zr.extend({},r.partials,o.partials))})(),t===void 0&&i&&(t=i),t===void 0)throw new Ot.default("The partial "+r.name+" could not be found");if(t instanceof Function)return t(e,r)}function Om(){return""}function Bo(t,e){if(t&&Object.prototype.hasOwnProperty.call(t,e))return t[e]}function v$(t,e){return(!e||!("root"in e))&&(e=e?Rt.createFrame(e):{},e.root=t),e}function Rm(t,e,r,n,i,o){if(t.decorator){var s={};e=t.decorator(e,s,r,n&&n[0],i,o,n),zr.extend(e,s)}return e}function Am(t,e,r){e&&Object.keys(e).forEach(function(n){var i=e[n];t[n]=_$(i,r)})}function _$(t,e){var r=e.lookupProperty;return d$.wrapHelper(t,function(n){return n.lookupProperty=r,n})}});var Cl=w((Uo,Tm)=>{"use strict";Uo.__esModule=!0;Uo.default=function(t){(function(){typeof globalThis!="object"&&(Object.prototype.__defineGetter__("__magic__",function(){return this}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__)})();var e=globalThis.Handlebars;t.noConflict=function(){return globalThis.Handlebars===t&&(globalThis.Handlebars=e),t}};Tm.exports=Uo.default});var Dm=w((Go,jm)=>{"use strict";Go.__esModule=!0;function kl(t){return t&&t.__esModule?t:{default:t}}function Al(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}var w$=qo(),Nm=Al(w$),b$=xm(),S$=kl(b$),E$=Fe(),$$=kl(E$),x$=Te(),Pl=Al(x$),C$=Im(),Mm=Al(C$),P$=Cl(),k$=kl(P$);function Lm(){var t=new Nm.HandlebarsEnvironment;return Pl.extend(t,Nm),t.SafeString=S$.default,t.Exception=$$.default,t.Utils=Pl,t.escapeExpression=Pl.escapeExpression,t.VM=Mm,t.template=function(e){return Mm.template(e,t)},t}var ri=Lm();ri.create=Lm;k$.default(ri);ri.default=ri;Go.default=ri;jm.exports=Go.default});var Ol=w((Wo,qm)=>{"use strict";Wo.__esModule=!0;var Vm={helpers:{helperExpression:function(e){return e.type==="SubExpression"||(e.type==="MustacheStatement"||e.type==="BlockStatement")&&!!(e.params&&e.params.length||e.hash)},scopedId:function(e){return/^\.|this\b/.test(e.original)},simpleId:function(e){return e.parts.length===1&&!Vm.helpers.scopedId(e)&&!e.depth}}};Wo.default=Vm;qm.exports=Wo.default});var Hm=w((zo,Fm)=>{"use strict";zo.__esModule=!0;var A$=(function(){var t={trace:function(){},yy:{},symbols_:{error:2,root:3,program:4,EOF:5,program_repetition0:6,statement:7,mustache:8,block:9,rawBlock:10,partial:11,partialBlock:12,content:13,COMMENT:14,CONTENT:15,openRawBlock:16,rawBlock_repetition0:17,END_RAW_BLOCK:18,OPEN_RAW_BLOCK:19,helperName:20,openRawBlock_repetition0:21,openRawBlock_option0:22,CLOSE_RAW_BLOCK:23,openBlock:24,block_option0:25,closeBlock:26,openInverse:27,block_option1:28,OPEN_BLOCK:29,openBlock_repetition0:30,openBlock_option0:31,openBlock_option1:32,CLOSE:33,OPEN_INVERSE:34,openInverse_repetition0:35,openInverse_option0:36,openInverse_option1:37,openInverseChain:38,OPEN_INVERSE_CHAIN:39,openInverseChain_repetition0:40,openInverseChain_option0:41,openInverseChain_option1:42,inverseAndProgram:43,INVERSE:44,inverseChain:45,inverseChain_option0:46,OPEN_ENDBLOCK:47,OPEN:48,mustache_repetition0:49,mustache_option0:50,OPEN_UNESCAPED:51,mustache_repetition1:52,mustache_option1:53,CLOSE_UNESCAPED:54,OPEN_PARTIAL:55,partialName:56,partial_repetition0:57,partial_option0:58,openPartialBlock:59,OPEN_PARTIAL_BLOCK:60,openPartialBlock_repetition0:61,openPartialBlock_option0:62,param:63,sexpr:64,OPEN_SEXPR:65,sexpr_repetition0:66,sexpr_option0:67,CLOSE_SEXPR:68,hash:69,hash_repetition_plus0:70,hashSegment:71,ID:72,EQUALS:73,blockParams:74,OPEN_BLOCK_PARAMS:75,blockParams_repetition_plus0:76,CLOSE_BLOCK_PARAMS:77,path:78,dataName:79,STRING:80,NUMBER:81,BOOLEAN:82,UNDEFINED:83,NULL:84,DATA:85,pathSegments:86,SEP:87,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",14:"COMMENT",15:"CONTENT",18:"END_RAW_BLOCK",19:"OPEN_RAW_BLOCK",23:"CLOSE_RAW_BLOCK",29:"OPEN_BLOCK",33:"CLOSE",34:"OPEN_INVERSE",39:"OPEN_INVERSE_CHAIN",44:"INVERSE",47:"OPEN_ENDBLOCK",48:"OPEN",51:"OPEN_UNESCAPED",54:"CLOSE_UNESCAPED",55:"OPEN_PARTIAL",60:"OPEN_PARTIAL_BLOCK",65:"OPEN_SEXPR",68:"CLOSE_SEXPR",72:"ID",73:"EQUALS",75:"OPEN_BLOCK_PARAMS",77:"CLOSE_BLOCK_PARAMS",80:"STRING",81:"NUMBER",82:"BOOLEAN",83:"UNDEFINED",84:"NULL",85:"DATA",87:"SEP"},productions_:[0,[3,2],[4,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[13,1],[10,3],[16,5],[9,4],[9,4],[24,6],[27,6],[38,6],[43,2],[45,3],[45,1],[26,3],[8,5],[8,5],[11,5],[12,3],[59,5],[63,1],[63,1],[64,5],[69,1],[71,3],[74,3],[20,1],[20,1],[20,1],[20,1],[20,1],[20,1],[20,1],[56,1],[56,1],[79,2],[78,1],[86,3],[86,1],[6,0],[6,2],[17,0],[17,2],[21,0],[21,2],[22,0],[22,1],[25,0],[25,1],[28,0],[28,1],[30,0],[30,2],[31,0],[31,1],[32,0],[32,1],[35,0],[35,2],[36,0],[36,1],[37,0],[37,1],[40,0],[40,2],[41,0],[41,1],[42,0],[42,1],[46,0],[46,1],[49,0],[49,2],[50,0],[50,1],[52,0],[52,2],[53,0],[53,1],[57,0],[57,2],[58,0],[58,1],[61,0],[61,2],[62,0],[62,1],[66,0],[66,2],[67,0],[67,1],[70,1],[70,2],[76,1],[76,2]],performAction:function(i,o,s,a,l,u,p){var f=u.length-1;switch(l){case 1:return u[f-1];case 2:this.$=a.prepareProgram(u[f]);break;case 3:this.$=u[f];break;case 4:this.$=u[f];break;case 5:this.$=u[f];break;case 6:this.$=u[f];break;case 7:this.$=u[f];break;case 8:this.$=u[f];break;case 9:this.$={type:"CommentStatement",value:a.stripComment(u[f]),strip:a.stripFlags(u[f],u[f]),loc:a.locInfo(this._$)};break;case 10:this.$={type:"ContentStatement",original:u[f],value:u[f],loc:a.locInfo(this._$)};break;case 11:this.$=a.prepareRawBlock(u[f-2],u[f-1],u[f],this._$);break;case 12:this.$={path:u[f-3],params:u[f-2],hash:u[f-1]};break;case 13:this.$=a.prepareBlock(u[f-3],u[f-2],u[f-1],u[f],!1,this._$);break;case 14:this.$=a.prepareBlock(u[f-3],u[f-2],u[f-1],u[f],!0,this._$);break;case 15:this.$={open:u[f-5],path:u[f-4],params:u[f-3],hash:u[f-2],blockParams:u[f-1],strip:a.stripFlags(u[f-5],u[f])};break;case 16:this.$={path:u[f-4],params:u[f-3],hash:u[f-2],blockParams:u[f-1],strip:a.stripFlags(u[f-5],u[f])};break;case 17:this.$={path:u[f-4],params:u[f-3],hash:u[f-2],blockParams:u[f-1],strip:a.stripFlags(u[f-5],u[f])};break;case 18:this.$={strip:a.stripFlags(u[f-1],u[f-1]),program:u[f]};break;case 19:var h=a.prepareBlock(u[f-2],u[f-1],u[f],u[f],!1,this._$),m=a.prepareProgram([h],u[f-1].loc);m.chained=!0,this.$={strip:u[f-2].strip,program:m,chain:!0};break;case 20:this.$=u[f];break;case 21:this.$={path:u[f-1],strip:a.stripFlags(u[f-2],u[f])};break;case 22:this.$=a.prepareMustache(u[f-3],u[f-2],u[f-1],u[f-4],a.stripFlags(u[f-4],u[f]),this._$);break;case 23:this.$=a.prepareMustache(u[f-3],u[f-2],u[f-1],u[f-4],a.stripFlags(u[f-4],u[f]),this._$);break;case 24:this.$={type:"PartialStatement",name:u[f-3],params:u[f-2],hash:u[f-1],indent:"",strip:a.stripFlags(u[f-4],u[f]),loc:a.locInfo(this._$)};break;case 25:this.$=a.preparePartialBlock(u[f-2],u[f-1],u[f],this._$);break;case 26:this.$={path:u[f-3],params:u[f-2],hash:u[f-1],strip:a.stripFlags(u[f-4],u[f])};break;case 27:this.$=u[f];break;case 28:this.$=u[f];break;case 29:this.$={type:"SubExpression",path:u[f-3],params:u[f-2],hash:u[f-1],loc:a.locInfo(this._$)};break;case 30:this.$={type:"Hash",pairs:u[f],loc:a.locInfo(this._$)};break;case 31:this.$={type:"HashPair",key:a.id(u[f-2]),value:u[f],loc:a.locInfo(this._$)};break;case 32:this.$=a.id(u[f-1]);break;case 33:this.$=u[f];break;case 34:this.$=u[f];break;case 35:this.$={type:"StringLiteral",value:u[f],original:u[f],loc:a.locInfo(this._$)};break;case 36:this.$={type:"NumberLiteral",value:Number(u[f]),original:Number(u[f]),loc:a.locInfo(this._$)};break;case 37:this.$={type:"BooleanLiteral",value:u[f]==="true",original:u[f]==="true",loc:a.locInfo(this._$)};break;case 38:this.$={type:"UndefinedLiteral",original:void 0,value:void 0,loc:a.locInfo(this._$)};break;case 39:this.$={type:"NullLiteral",original:null,value:null,loc:a.locInfo(this._$)};break;case 40:this.$=u[f];break;case 41:this.$=u[f];break;case 42:this.$=a.preparePath(!0,u[f],this._$);break;case 43:this.$=a.preparePath(!1,u[f],this._$);break;case 44:u[f-2].push({part:a.id(u[f]),original:u[f],separator:u[f-1]}),this.$=u[f-2];break;case 45:this.$=[{part:a.id(u[f]),original:u[f]}];break;case 46:this.$=[];break;case 47:u[f-1].push(u[f]);break;case 48:this.$=[];break;case 49:u[f-1].push(u[f]);break;case 50:this.$=[];break;case 51:u[f-1].push(u[f]);break;case 58:this.$=[];break;case 59:u[f-1].push(u[f]);break;case 64:this.$=[];break;case 65:u[f-1].push(u[f]);break;case 70:this.$=[];break;case 71:u[f-1].push(u[f]);break;case 78:this.$=[];break;case 79:u[f-1].push(u[f]);break;case 82:this.$=[];break;case 83:u[f-1].push(u[f]);break;case 86:this.$=[];break;case 87:u[f-1].push(u[f]);break;case 90:this.$=[];break;case 91:u[f-1].push(u[f]);break;case 94:this.$=[];break;case 95:u[f-1].push(u[f]);break;case 98:this.$=[u[f]];break;case 99:u[f-1].push(u[f]);break;case 100:this.$=[u[f]];break;case 101:u[f-1].push(u[f]);break}},table:[{3:1,4:2,5:[2,46],6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{1:[3]},{5:[1,4]},{5:[2,2],7:5,8:6,9:7,10:8,11:9,12:10,13:11,14:[1,12],15:[1,20],16:17,19:[1,23],24:15,27:16,29:[1,21],34:[1,22],39:[2,2],44:[2,2],47:[2,2],48:[1,13],51:[1,14],55:[1,18],59:19,60:[1,24]},{1:[2,1]},{5:[2,47],14:[2,47],15:[2,47],19:[2,47],29:[2,47],34:[2,47],39:[2,47],44:[2,47],47:[2,47],48:[2,47],51:[2,47],55:[2,47],60:[2,47]},{5:[2,3],14:[2,3],15:[2,3],19:[2,3],29:[2,3],34:[2,3],39:[2,3],44:[2,3],47:[2,3],48:[2,3],51:[2,3],55:[2,3],60:[2,3]},{5:[2,4],14:[2,4],15:[2,4],19:[2,4],29:[2,4],34:[2,4],39:[2,4],44:[2,4],47:[2,4],48:[2,4],51:[2,4],55:[2,4],60:[2,4]},{5:[2,5],14:[2,5],15:[2,5],19:[2,5],29:[2,5],34:[2,5],39:[2,5],44:[2,5],47:[2,5],48:[2,5],51:[2,5],55:[2,5],60:[2,5]},{5:[2,6],14:[2,6],15:[2,6],19:[2,6],29:[2,6],34:[2,6],39:[2,6],44:[2,6],47:[2,6],48:[2,6],51:[2,6],55:[2,6],60:[2,6]},{5:[2,7],14:[2,7],15:[2,7],19:[2,7],29:[2,7],34:[2,7],39:[2,7],44:[2,7],47:[2,7],48:[2,7],51:[2,7],55:[2,7],60:[2,7]},{5:[2,8],14:[2,8],15:[2,8],19:[2,8],29:[2,8],34:[2,8],39:[2,8],44:[2,8],47:[2,8],48:[2,8],51:[2,8],55:[2,8],60:[2,8]},{5:[2,9],14:[2,9],15:[2,9],19:[2,9],29:[2,9],34:[2,9],39:[2,9],44:[2,9],47:[2,9],48:[2,9],51:[2,9],55:[2,9],60:[2,9]},{20:25,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:36,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{4:37,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],39:[2,46],44:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{4:38,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],44:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{15:[2,48],17:39,18:[2,48]},{20:41,56:40,64:42,65:[1,43],72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{4:44,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{5:[2,10],14:[2,10],15:[2,10],18:[2,10],19:[2,10],29:[2,10],34:[2,10],39:[2,10],44:[2,10],47:[2,10],48:[2,10],51:[2,10],55:[2,10],60:[2,10]},{20:45,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:46,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:47,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:41,56:48,64:42,65:[1,43],72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{33:[2,78],49:49,65:[2,78],72:[2,78],80:[2,78],81:[2,78],82:[2,78],83:[2,78],84:[2,78],85:[2,78]},{23:[2,33],33:[2,33],54:[2,33],65:[2,33],68:[2,33],72:[2,33],75:[2,33],80:[2,33],81:[2,33],82:[2,33],83:[2,33],84:[2,33],85:[2,33]},{23:[2,34],33:[2,34],54:[2,34],65:[2,34],68:[2,34],72:[2,34],75:[2,34],80:[2,34],81:[2,34],82:[2,34],83:[2,34],84:[2,34],85:[2,34]},{23:[2,35],33:[2,35],54:[2,35],65:[2,35],68:[2,35],72:[2,35],75:[2,35],80:[2,35],81:[2,35],82:[2,35],83:[2,35],84:[2,35],85:[2,35]},{23:[2,36],33:[2,36],54:[2,36],65:[2,36],68:[2,36],72:[2,36],75:[2,36],80:[2,36],81:[2,36],82:[2,36],83:[2,36],84:[2,36],85:[2,36]},{23:[2,37],33:[2,37],54:[2,37],65:[2,37],68:[2,37],72:[2,37],75:[2,37],80:[2,37],81:[2,37],82:[2,37],83:[2,37],84:[2,37],85:[2,37]},{23:[2,38],33:[2,38],54:[2,38],65:[2,38],68:[2,38],72:[2,38],75:[2,38],80:[2,38],81:[2,38],82:[2,38],83:[2,38],84:[2,38],85:[2,38]},{23:[2,39],33:[2,39],54:[2,39],65:[2,39],68:[2,39],72:[2,39],75:[2,39],80:[2,39],81:[2,39],82:[2,39],83:[2,39],84:[2,39],85:[2,39]},{23:[2,43],33:[2,43],54:[2,43],65:[2,43],68:[2,43],72:[2,43],75:[2,43],80:[2,43],81:[2,43],82:[2,43],83:[2,43],84:[2,43],85:[2,43],87:[1,50]},{72:[1,35],86:51},{23:[2,45],33:[2,45],54:[2,45],65:[2,45],68:[2,45],72:[2,45],75:[2,45],80:[2,45],81:[2,45],82:[2,45],83:[2,45],84:[2,45],85:[2,45],87:[2,45]},{52:52,54:[2,82],65:[2,82],72:[2,82],80:[2,82],81:[2,82],82:[2,82],83:[2,82],84:[2,82],85:[2,82]},{25:53,38:55,39:[1,57],43:56,44:[1,58],45:54,47:[2,54]},{28:59,43:60,44:[1,58],47:[2,56]},{13:62,15:[1,20],18:[1,61]},{33:[2,86],57:63,65:[2,86],72:[2,86],80:[2,86],81:[2,86],82:[2,86],83:[2,86],84:[2,86],85:[2,86]},{33:[2,40],65:[2,40],72:[2,40],80:[2,40],81:[2,40],82:[2,40],83:[2,40],84:[2,40],85:[2,40]},{33:[2,41],65:[2,41],72:[2,41],80:[2,41],81:[2,41],82:[2,41],83:[2,41],84:[2,41],85:[2,41]},{20:64,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{26:65,47:[1,66]},{30:67,33:[2,58],65:[2,58],72:[2,58],75:[2,58],80:[2,58],81:[2,58],82:[2,58],83:[2,58],84:[2,58],85:[2,58]},{33:[2,64],35:68,65:[2,64],72:[2,64],75:[2,64],80:[2,64],81:[2,64],82:[2,64],83:[2,64],84:[2,64],85:[2,64]},{21:69,23:[2,50],65:[2,50],72:[2,50],80:[2,50],81:[2,50],82:[2,50],83:[2,50],84:[2,50],85:[2,50]},{33:[2,90],61:70,65:[2,90],72:[2,90],80:[2,90],81:[2,90],82:[2,90],83:[2,90],84:[2,90],85:[2,90]},{20:74,33:[2,80],50:71,63:72,64:75,65:[1,43],69:73,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{72:[1,79]},{23:[2,42],33:[2,42],54:[2,42],65:[2,42],68:[2,42],72:[2,42],75:[2,42],80:[2,42],81:[2,42],82:[2,42],83:[2,42],84:[2,42],85:[2,42],87:[1,50]},{20:74,53:80,54:[2,84],63:81,64:75,65:[1,43],69:82,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{26:83,47:[1,66]},{47:[2,55]},{4:84,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],39:[2,46],44:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{47:[2,20]},{20:85,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{4:86,6:3,14:[2,46],15:[2,46],19:[2,46],29:[2,46],34:[2,46],47:[2,46],48:[2,46],51:[2,46],55:[2,46],60:[2,46]},{26:87,47:[1,66]},{47:[2,57]},{5:[2,11],14:[2,11],15:[2,11],19:[2,11],29:[2,11],34:[2,11],39:[2,11],44:[2,11],47:[2,11],48:[2,11],51:[2,11],55:[2,11],60:[2,11]},{15:[2,49],18:[2,49]},{20:74,33:[2,88],58:88,63:89,64:75,65:[1,43],69:90,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{65:[2,94],66:91,68:[2,94],72:[2,94],80:[2,94],81:[2,94],82:[2,94],83:[2,94],84:[2,94],85:[2,94]},{5:[2,25],14:[2,25],15:[2,25],19:[2,25],29:[2,25],34:[2,25],39:[2,25],44:[2,25],47:[2,25],48:[2,25],51:[2,25],55:[2,25],60:[2,25]},{20:92,72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,31:93,33:[2,60],63:94,64:75,65:[1,43],69:95,70:76,71:77,72:[1,78],75:[2,60],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,33:[2,66],36:96,63:97,64:75,65:[1,43],69:98,70:76,71:77,72:[1,78],75:[2,66],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,22:99,23:[2,52],63:100,64:75,65:[1,43],69:101,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{20:74,33:[2,92],62:102,63:103,64:75,65:[1,43],69:104,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{33:[1,105]},{33:[2,79],65:[2,79],72:[2,79],80:[2,79],81:[2,79],82:[2,79],83:[2,79],84:[2,79],85:[2,79]},{33:[2,81]},{23:[2,27],33:[2,27],54:[2,27],65:[2,27],68:[2,27],72:[2,27],75:[2,27],80:[2,27],81:[2,27],82:[2,27],83:[2,27],84:[2,27],85:[2,27]},{23:[2,28],33:[2,28],54:[2,28],65:[2,28],68:[2,28],72:[2,28],75:[2,28],80:[2,28],81:[2,28],82:[2,28],83:[2,28],84:[2,28],85:[2,28]},{23:[2,30],33:[2,30],54:[2,30],68:[2,30],71:106,72:[1,107],75:[2,30]},{23:[2,98],33:[2,98],54:[2,98],68:[2,98],72:[2,98],75:[2,98]},{23:[2,45],33:[2,45],54:[2,45],65:[2,45],68:[2,45],72:[2,45],73:[1,108],75:[2,45],80:[2,45],81:[2,45],82:[2,45],83:[2,45],84:[2,45],85:[2,45],87:[2,45]},{23:[2,44],33:[2,44],54:[2,44],65:[2,44],68:[2,44],72:[2,44],75:[2,44],80:[2,44],81:[2,44],82:[2,44],83:[2,44],84:[2,44],85:[2,44],87:[2,44]},{54:[1,109]},{54:[2,83],65:[2,83],72:[2,83],80:[2,83],81:[2,83],82:[2,83],83:[2,83],84:[2,83],85:[2,83]},{54:[2,85]},{5:[2,13],14:[2,13],15:[2,13],19:[2,13],29:[2,13],34:[2,13],39:[2,13],44:[2,13],47:[2,13],48:[2,13],51:[2,13],55:[2,13],60:[2,13]},{38:55,39:[1,57],43:56,44:[1,58],45:111,46:110,47:[2,76]},{33:[2,70],40:112,65:[2,70],72:[2,70],75:[2,70],80:[2,70],81:[2,70],82:[2,70],83:[2,70],84:[2,70],85:[2,70]},{47:[2,18]},{5:[2,14],14:[2,14],15:[2,14],19:[2,14],29:[2,14],34:[2,14],39:[2,14],44:[2,14],47:[2,14],48:[2,14],51:[2,14],55:[2,14],60:[2,14]},{33:[1,113]},{33:[2,87],65:[2,87],72:[2,87],80:[2,87],81:[2,87],82:[2,87],83:[2,87],84:[2,87],85:[2,87]},{33:[2,89]},{20:74,63:115,64:75,65:[1,43],67:114,68:[2,96],69:116,70:76,71:77,72:[1,78],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{33:[1,117]},{32:118,33:[2,62],74:119,75:[1,120]},{33:[2,59],65:[2,59],72:[2,59],75:[2,59],80:[2,59],81:[2,59],82:[2,59],83:[2,59],84:[2,59],85:[2,59]},{33:[2,61],75:[2,61]},{33:[2,68],37:121,74:122,75:[1,120]},{33:[2,65],65:[2,65],72:[2,65],75:[2,65],80:[2,65],81:[2,65],82:[2,65],83:[2,65],84:[2,65],85:[2,65]},{33:[2,67],75:[2,67]},{23:[1,123]},{23:[2,51],65:[2,51],72:[2,51],80:[2,51],81:[2,51],82:[2,51],83:[2,51],84:[2,51],85:[2,51]},{23:[2,53]},{33:[1,124]},{33:[2,91],65:[2,91],72:[2,91],80:[2,91],81:[2,91],82:[2,91],83:[2,91],84:[2,91],85:[2,91]},{33:[2,93]},{5:[2,22],14:[2,22],15:[2,22],19:[2,22],29:[2,22],34:[2,22],39:[2,22],44:[2,22],47:[2,22],48:[2,22],51:[2,22],55:[2,22],60:[2,22]},{23:[2,99],33:[2,99],54:[2,99],68:[2,99],72:[2,99],75:[2,99]},{73:[1,108]},{20:74,63:125,64:75,65:[1,43],72:[1,35],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{5:[2,23],14:[2,23],15:[2,23],19:[2,23],29:[2,23],34:[2,23],39:[2,23],44:[2,23],47:[2,23],48:[2,23],51:[2,23],55:[2,23],60:[2,23]},{47:[2,19]},{47:[2,77]},{20:74,33:[2,72],41:126,63:127,64:75,65:[1,43],69:128,70:76,71:77,72:[1,78],75:[2,72],78:26,79:27,80:[1,28],81:[1,29],82:[1,30],83:[1,31],84:[1,32],85:[1,34],86:33},{5:[2,24],14:[2,24],15:[2,24],19:[2,24],29:[2,24],34:[2,24],39:[2,24],44:[2,24],47:[2,24],48:[2,24],51:[2,24],55:[2,24],60:[2,24]},{68:[1,129]},{65:[2,95],68:[2,95],72:[2,95],80:[2,95],81:[2,95],82:[2,95],83:[2,95],84:[2,95],85:[2,95]},{68:[2,97]},{5:[2,21],14:[2,21],15:[2,21],19:[2,21],29:[2,21],34:[2,21],39:[2,21],44:[2,21],47:[2,21],48:[2,21],51:[2,21],55:[2,21],60:[2,21]},{33:[1,130]},{33:[2,63]},{72:[1,132],76:131},{33:[1,133]},{33:[2,69]},{15:[2,12],18:[2,12]},{14:[2,26],15:[2,26],19:[2,26],29:[2,26],34:[2,26],47:[2,26],48:[2,26],51:[2,26],55:[2,26],60:[2,26]},{23:[2,31],33:[2,31],54:[2,31],68:[2,31],72:[2,31],75:[2,31]},{33:[2,74],42:134,74:135,75:[1,120]},{33:[2,71],65:[2,71],72:[2,71],75:[2,71],80:[2,71],81:[2,71],82:[2,71],83:[2,71],84:[2,71],85:[2,71]},{33:[2,73],75:[2,73]},{23:[2,29],33:[2,29],54:[2,29],65:[2,29],68:[2,29],72:[2,29],75:[2,29],80:[2,29],81:[2,29],82:[2,29],83:[2,29],84:[2,29],85:[2,29]},{14:[2,15],15:[2,15],19:[2,15],29:[2,15],34:[2,15],39:[2,15],44:[2,15],47:[2,15],48:[2,15],51:[2,15],55:[2,15],60:[2,15]},{72:[1,137],77:[1,136]},{72:[2,100],77:[2,100]},{14:[2,16],15:[2,16],19:[2,16],29:[2,16],34:[2,16],44:[2,16],47:[2,16],48:[2,16],51:[2,16],55:[2,16],60:[2,16]},{33:[1,138]},{33:[2,75]},{33:[2,32]},{72:[2,101],77:[2,101]},{14:[2,17],15:[2,17],19:[2,17],29:[2,17],34:[2,17],39:[2,17],44:[2,17],47:[2,17],48:[2,17],51:[2,17],55:[2,17],60:[2,17]}],defaultActions:{4:[2,1],54:[2,55],56:[2,20],60:[2,57],73:[2,81],82:[2,85],86:[2,18],90:[2,89],101:[2,53],104:[2,93],110:[2,19],111:[2,77],116:[2,97],119:[2,63],122:[2,69],135:[2,75],136:[2,32]},parseError:function(i,o){throw new Error(i)},parse:function(i){var o=this,s=[0],a=[null],l=[],u=this.table,p="",f=0,h=0,m=0,g=2,v=1;this.lexer.setInput(i),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.yy.parser=this,typeof this.lexer.yylloc>"u"&&(this.lexer.yylloc={});var P=this.lexer.yylloc;l.push(P);var b=this.lexer.options&&this.lexer.options.ranges;typeof this.yy.parseError=="function"&&(this.parseError=this.yy.parseError);function j(se){s.length=s.length-2*se,a.length=a.length-se,l.length=l.length-se}function B(){var se;return se=o.lexer.lex()||1,typeof se!="number"&&(se=o.symbols_[se]||se),se}for(var L,T,Q,ne,Nt,et,be={},Ne,xe,tt,rt;;){if(Q=s[s.length-1],this.defaultActions[Q]?ne=this.defaultActions[Q]:((L===null||typeof L>"u")&&(L=B()),ne=u[Q]&&u[Q][L]),typeof ne>"u"||!ne.length||!ne[0]){var _t="";if(!m){rt=[];for(Ne in u[Q])this.terminals_[Ne]&&Ne>2&&rt.push("'"+this.terminals_[Ne]+"'");this.lexer.showPosition?_t="Parse error on line "+(f+1)+`:
|
|
41
41
|
`+this.lexer.showPosition()+`
|
|
42
|
-
Expecting `+
|
|
43
|
-
`+
|
|
44
|
-
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var s=this.next();return typeof s<"u"?s:this.lex()},begin:function(s){this.conditionStack.push(s)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(s){this.begin(s)}};return n.options={},n.performAction=function(s,o,a,l){function u(f,h){return o.yytext=o.yytext.substring(f,o.yyleng-h+f)}var d=l;switch(a){case 0:if(o.yytext.slice(-2)==="\\\\"?(u(0,1),this.begin("mu")):o.yytext.slice(-1)==="\\"?(u(0,1),this.begin("emu")):this.begin("mu"),o.yytext)return 15;break;case 1:return 15;case 2:return this.popState(),15;break;case 3:return this.begin("raw"),15;break;case 4:return this.popState(),this.conditionStack[this.conditionStack.length-1]==="raw"?15:(u(5,9),"END_RAW_BLOCK");case 5:return 15;case 6:return this.popState(),14;break;case 7:return 65;case 8:return 68;case 9:return 19;case 10:return this.popState(),this.begin("raw"),23;break;case 11:return 55;case 12:return 60;case 13:return 29;case 14:return 47;case 15:return this.popState(),44;break;case 16:return this.popState(),44;break;case 17:return 34;case 18:return 39;case 19:return 51;case 20:return 48;case 21:this.unput(o.yytext),this.popState(),this.begin("com");break;case 22:return this.popState(),14;break;case 23:return 48;case 24:return 73;case 25:return 72;case 26:return 72;case 27:return 87;case 28:break;case 29:return this.popState(),54;break;case 30:return this.popState(),33;break;case 31:return o.yytext=u(1,2).replace(/\\"/g,'"'),80;break;case 32:return o.yytext=u(1,2).replace(/\\'/g,"'"),80;break;case 33:return 85;case 34:return 82;case 35:return 82;case 36:return 83;case 37:return 84;case 38:return 81;case 39:return 75;case 40:return 77;case 41:return 72;case 42:return o.yytext=o.yytext.replace(/\\([\\\]])/g,"$1"),72;break;case 43:return"INVALID";case 44:return 5}},n.rules=[/^(?:[^\x00]*?(?=(\{\{)))/,/^(?:[^\x00]+)/,/^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/,/^(?:\{\{\{\{(?=[^\/]))/,/^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/,/^(?:[^\x00]+?(?=(\{\{\{\{)))/,/^(?:[\s\S]*?--(~)?\}\})/,/^(?:\()/,/^(?:\))/,/^(?:\{\{\{\{)/,/^(?:\}\}\}\})/,/^(?:\{\{(~)?>)/,/^(?:\{\{(~)?#>)/,/^(?:\{\{(~)?#\*?)/,/^(?:\{\{(~)?\/)/,/^(?:\{\{(~)?\^\s*(~)?\}\})/,/^(?:\{\{(~)?\s*else\s*(~)?\}\})/,/^(?:\{\{(~)?\^)/,/^(?:\{\{(~)?\s*else\b)/,/^(?:\{\{(~)?\{)/,/^(?:\{\{(~)?&)/,/^(?:\{\{(~)?!--)/,/^(?:\{\{(~)?![\s\S]*?\}\})/,/^(?:\{\{(~)?\*?)/,/^(?:=)/,/^(?:\.\.)/,/^(?:\.(?=([=~}\s\/.)|])))/,/^(?:[\/.])/,/^(?:\s+)/,/^(?:\}(~)?\}\})/,/^(?:(~)?\}\})/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:@)/,/^(?:true(?=([~}\s)])))/,/^(?:false(?=([~}\s)])))/,/^(?:undefined(?=([~}\s)])))/,/^(?:null(?=([~}\s)])))/,/^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/,/^(?:as\s+\|)/,/^(?:\|)/,/^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/,/^(?:\[(\\\]|[^\]])*\])/,/^(?:.)/,/^(?:$)/],n.conditions={mu:{rules:[7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44],inclusive:!1},emu:{rules:[2],inclusive:!1},com:{rules:[6],inclusive:!1},raw:{rules:[3,4,5],inclusive:!1},INITIAL:{rules:[0,1,44],inclusive:!0}},n})();t.lexer=e;function r(){this.yy={}}return r.prototype=t,t.Parser=r,new r})();Ts.default=VE;sm.exports=Ts.default});var js=w((Ls,lm)=>{"use strict";Ls.__esModule=!0;function FE(t){return t&&t.__esModule?t:{default:t}}var HE=Fe(),ll=FE(HE);function Ns(){this.parents=[]}Ns.prototype={constructor:Ns,mutating:!1,acceptKey:function(e,r){var n=this.accept(e[r]);if(this.mutating){if(n&&!Ns.prototype[n.type])throw new ll.default('Unexpected node type "'+n.type+'" found when accepting '+r+" on "+e.type);e[r]=n}},acceptRequired:function(e,r){if(this.acceptKey(e,r),!e[r])throw new ll.default(e.type+" requires "+r)},acceptArray:function(e){for(var r=0,n=e.length;r<n;r++)this.acceptKey(e,r),e[r]||(e.splice(r,1),r--,n--)},accept:function(e){if(e){if(!this[e.type])throw new ll.default("Unknown type: "+e.type,e);this.current&&this.parents.unshift(this.current),this.current=e;var r=this[e.type](e);if(this.current=this.parents.shift(),!this.mutating||r)return r;if(r!==!1)return e}},Program:function(e){this.acceptArray(e.body)},MustacheStatement:Ms,Decorator:Ms,BlockStatement:am,DecoratorBlock:am,PartialStatement:cm,PartialBlockStatement:function(e){cm.call(this,e),this.acceptKey(e,"program")},ContentStatement:function(){},CommentStatement:function(){},SubExpression:Ms,PathExpression:function(){},StringLiteral:function(){},NumberLiteral:function(){},BooleanLiteral:function(){},UndefinedLiteral:function(){},NullLiteral:function(){},Hash:function(e){this.acceptArray(e.pairs)},HashPair:function(e){this.acceptRequired(e,"value")}};function Ms(t){this.acceptRequired(t,"path"),this.acceptArray(t.params),this.acceptKey(t,"hash")}function am(t){Ms.call(this,t),this.acceptKey(t,"program"),this.acceptKey(t,"inverse")}function cm(t){this.acceptRequired(t,"name"),this.acceptArray(t.params),this.acceptKey(t,"hash")}Ls.default=Ns;lm.exports=Ls.default});var fm=w((Ds,um)=>{"use strict";Ds.__esModule=!0;function BE(t){return t&&t.__esModule?t:{default:t}}var UE=js(),GE=BE(UE);function wt(){var t=arguments.length<=0||arguments[0]===void 0?{}:arguments[0];this.options=t}wt.prototype=new GE.default;wt.prototype.Program=function(t){var e=!this.options.ignoreStandalone,r=!this.isRootSeen;this.isRootSeen=!0;for(var n=t.body,i=0,s=n.length;i<s;i++){var o=n[i],a=this.accept(o);if(a){var l=ul(n,i,r),u=fl(n,i,r),d=a.openStandalone&&l,f=a.closeStandalone&&u,h=a.inlineStandalone&&l&&u;a.close&&ur(n,i,!0),a.open&&zt(n,i,!0),e&&h&&(ur(n,i),zt(n,i)&&o.type==="PartialStatement"&&(o.indent=/([ \t]+$)/.exec(n[i-1].original)[1])),e&&d&&(ur((o.program||o.inverse).body),zt(n,i)),e&&f&&(ur(n,i),zt((o.inverse||o.program).body))}}return t};wt.prototype.BlockStatement=wt.prototype.DecoratorBlock=wt.prototype.PartialBlockStatement=function(t){this.accept(t.program),this.accept(t.inverse);var e=t.program||t.inverse,r=t.program&&t.inverse,n=r,i=r;if(r&&r.chained)for(n=r.body[0].program;i.chained;)i=i.body[i.body.length-1].program;var s={open:t.openStrip.open,close:t.closeStrip.close,openStandalone:fl(e.body),closeStandalone:ul((n||e).body)};if(t.openStrip.close&&ur(e.body,null,!0),r){var o=t.inverseStrip;o.open&&zt(e.body,null,!0),o.close&&ur(n.body,null,!0),t.closeStrip.open&&zt(i.body,null,!0),!this.options.ignoreStandalone&&ul(e.body)&&fl(n.body)&&(zt(e.body),ur(n.body))}else t.closeStrip.open&&zt(e.body,null,!0);return s};wt.prototype.Decorator=wt.prototype.MustacheStatement=function(t){return t.strip};wt.prototype.PartialStatement=wt.prototype.CommentStatement=function(t){var e=t.strip||{};return{inlineStandalone:!0,open:e.open,close:e.close}};function ul(t,e,r){e===void 0&&(e=t.length);var n=t[e-1],i=t[e-2];if(!n)return r;if(n.type==="ContentStatement")return(i||!r?/\r?\n\s*?$/:/(^|\r?\n)\s*?$/).test(n.original)}function fl(t,e,r){e===void 0&&(e=-1);var n=t[e+1],i=t[e+2];if(!n)return r;if(n.type==="ContentStatement")return(i||!r?/^\s*?\r?\n/:/^\s*?(\r?\n|$)/).test(n.original)}function ur(t,e,r){var n=t[e==null?0:e+1];if(!(!n||n.type!=="ContentStatement"||!r&&n.rightStripped)){var i=n.value;n.value=n.value.replace(r?/^\s+/:/^[ \t]*\r?\n?/,""),n.rightStripped=n.value!==i}}function zt(t,e,r){var n=t[e==null?t.length-1:e-1];if(!(!n||n.type!=="ContentStatement"||!r&&n.leftStripped)){var i=n.value;return n.value=n.value.replace(r?/\s+$/:/[ \t]+$/,""),n.leftStripped=n.value!==i,n.leftStripped}}Ds.default=wt;um.exports=Ds.default});var dm=w(Qe=>{"use strict";Qe.__esModule=!0;Qe.SourceLocation=KE;Qe.id=JE;Qe.stripFlags=YE;Qe.stripComment=XE;Qe.preparePath=QE;Qe.prepareMustache=ZE;Qe.prepareRawBlock=e$;Qe.prepareBlock=t$;Qe.prepareProgram=r$;Qe.preparePartialBlock=n$;function zE(t){return t&&t.__esModule?t:{default:t}}var WE=Fe(),dl=zE(WE);function pl(t,e){if(e=e.path?e.path.original:e,t.path.original!==e){var r={loc:t.path.loc};throw new dl.default(t.path.original+" doesn't match "+e,r)}}function KE(t,e){this.source=t,this.start={line:e.first_line,column:e.first_column},this.end={line:e.last_line,column:e.last_column}}function JE(t){return/^\[.*\]$/.test(t)?t.substring(1,t.length-1):t}function YE(t,e){return{open:t.charAt(2)==="~",close:e.charAt(e.length-3)==="~"}}function XE(t){return t.replace(/^\{\{~?!-?-?/,"").replace(/-?-?~?\}\}$/,"")}function QE(t,e,r){r=this.locInfo(r);for(var n=t?"@":"",i=[],s=0,o=0,a=e.length;o<a;o++){var l=e[o].part,u=e[o].original!==l;if(n+=(e[o].separator||"")+l,!u&&(l===".."||l==="."||l==="this")){if(i.length>0)throw new dl.default("Invalid path: "+n,{loc:r});l===".."&&s++}else i.push(l)}return{type:"PathExpression",data:t,depth:s,parts:i,original:n,loc:r}}function ZE(t,e,r,n,i,s){var o=n.charAt(3)||n.charAt(2),a=o!=="{"&&o!=="&",l=/\*/.test(n);return{type:l?"Decorator":"MustacheStatement",path:t,params:e,hash:r,escaped:a,strip:i,loc:this.locInfo(s)}}function e$(t,e,r,n){pl(t,r),n=this.locInfo(n);var i={type:"Program",body:e,strip:{},loc:n};return{type:"BlockStatement",path:t.path,params:t.params,hash:t.hash,program:i,openStrip:{},inverseStrip:{},closeStrip:{},loc:n}}function t$(t,e,r,n,i,s){n&&n.path&&pl(t,n);var o=/\*/.test(t.open);e.blockParams=t.blockParams;var a=void 0,l=void 0;if(r){if(o)throw new dl.default("Unexpected inverse block on decorator",r);r.chain&&(r.program.body[0].closeStrip=n.strip),l=r.strip,a=r.program}return i&&(i=a,a=e,e=i),{type:o?"DecoratorBlock":"BlockStatement",path:t.path,params:t.params,hash:t.hash,program:e,inverse:a,openStrip:t.strip,inverseStrip:l,closeStrip:n&&n.strip,loc:this.locInfo(s)}}function r$(t,e){if(!e&&t.length){var r=t[0].loc,n=t[t.length-1].loc;r&&n&&(e={source:r.source,start:{line:r.start.line,column:r.start.column},end:{line:n.end.line,column:n.end.column}})}return{type:"Program",body:t,strip:{},loc:e}}function n$(t,e,r,n){return pl(t,r),{type:"PartialBlockStatement",name:t.path,params:t.params,hash:t.hash,program:e,openStrip:t.strip,closeStrip:r&&r.strip,loc:this.locInfo(n)}}});var hm=w(Qn=>{"use strict";Qn.__esModule=!0;Qn.parseWithoutProcessing=pm;Qn.parse=d$;function i$(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}function gl(t){return t&&t.__esModule?t:{default:t}}var s$=om(),hl=gl(s$),o$=fm(),a$=gl(o$),c$=dm(),l$=i$(c$),u$=Fe(),Xn=gl(u$),f$=Te();Qn.parser=hl.default;var qs={};f$.extend(qs,l$);function pm(t,e){if(t.type==="Program")return p$(t),t;hl.default.yy=qs,qs.locInfo=function(n){return new qs.SourceLocation(e&&e.srcName,n)};var r=hl.default.parse(t);return r}function d$(t,e){var r=pm(t,e),n=new a$.default(e);return n.accept(r)}function p$(t){ml(t)}function ml(t){if(t!=null){if(Array.isArray(t)){t.forEach(ml);return}if(typeof t=="object"){if(t.type==="PathExpression"){if(!h$(t.depth))throw new Xn.default("Invalid AST: PathExpression.depth must be an integer");if(!Array.isArray(t.parts))throw new Xn.default("Invalid AST: PathExpression.parts must be an array");for(var e=0;e<t.parts.length;e++)if(typeof t.parts[e]!="string")throw new Xn.default("Invalid AST: PathExpression.parts must only contain strings")}else if(t.type==="NumberLiteral"){if(typeof t.value!="number"||!isFinite(t.value))throw new Xn.default("Invalid AST: NumberLiteral.value must be a number")}else if(t.type==="BooleanLiteral"&&typeof t.value!="boolean")throw new Xn.default("Invalid AST: BooleanLiteral.value must be a boolean");Object.keys(t).forEach(function(r){r!=="loc"&&ml(t[r])})}}}function h$(t){return typeof t=="number"&&isFinite(t)&&Math.floor(t)===t&&t>=0}});var vm=w(ri=>{"use strict";ri.__esModule=!0;ri.Compiler=yl;ri.precompile=v$;ri.compile=_$;function gm(t){return t&&t.__esModule?t:{default:t}}var m$=Fe(),ei=gm(m$),ti=Te(),g$=cl(),Zn=gm(g$),y$=[].slice;function yl(){}yl.prototype={compiler:yl,equals:function(e){var r=this.opcodes.length;if(e.opcodes.length!==r)return!1;for(var n=0;n<r;n++){var i=this.opcodes[n],s=e.opcodes[n];if(i.opcode!==s.opcode||!ym(i.args,s.args))return!1}r=this.children.length;for(var n=0;n<r;n++)if(!this.children[n].equals(e.children[n]))return!1;return!0},guid:0,compile:function(e,r){return this.sourceNode=[],this.opcodes=[],this.children=[],this.options=r,this.stringParams=r.stringParams,this.trackIds=r.trackIds,r.blockParams=r.blockParams||[],r.knownHelpers=ti.extend(Object.create(null),{helperMissing:!0,blockHelperMissing:!0,each:!0,if:!0,unless:!0,with:!0,log:!0,lookup:!0},r.knownHelpers),this.accept(e)},compileProgram:function(e){var r=new this.compiler,n=r.compile(e,this.options),i=this.guid++;return this.usePartial=this.usePartial||n.usePartial,this.children[i]=n,this.useDepths=this.useDepths||n.useDepths,i},accept:function(e){if(!this[e.type])throw new ei.default("Unknown type: "+e.type,e);this.sourceNode.unshift(e);var r=this[e.type](e);return this.sourceNode.shift(),r},Program:function(e){this.options.blockParams.unshift(e.blockParams);for(var r=e.body,n=r.length,i=0;i<n;i++)this.accept(r[i]);return this.options.blockParams.shift(),this.isSimple=n===1,this.blockParams=e.blockParams?e.blockParams.length:0,this},BlockStatement:function(e){mm(e);var r=e.program,n=e.inverse;r=r&&this.compileProgram(r),n=n&&this.compileProgram(n);var i=this.classifySexpr(e);i==="helper"?this.helperSexpr(e,r,n):i==="simple"?(this.simpleSexpr(e),this.opcode("pushProgram",r),this.opcode("pushProgram",n),this.opcode("emptyHash"),this.opcode("blockValue",e.path.original)):(this.ambiguousSexpr(e,r,n),this.opcode("pushProgram",r),this.opcode("pushProgram",n),this.opcode("emptyHash"),this.opcode("ambiguousBlockValue")),this.opcode("append")},DecoratorBlock:function(e){var r=e.program&&this.compileProgram(e.program),n=this.setupFullMustacheParams(e,r,void 0),i=e.path;this.useDecorators=!0,this.opcode("registerDecorator",n.length,i.original)},PartialStatement:function(e){this.usePartial=!0;var r=e.program;r&&(r=this.compileProgram(e.program));var n=e.params;if(n.length>1)throw new ei.default("Unsupported number of partial arguments: "+n.length,e);n.length||(this.options.explicitPartialContext?this.opcode("pushLiteral","undefined"):n.push({type:"PathExpression",parts:[],depth:0}));var i=e.name.original,s=e.name.type==="SubExpression";s&&this.accept(e.name),this.setupFullMustacheParams(e,r,void 0,!0);var o=e.indent||"";this.options.preventIndent&&o&&(this.opcode("appendContent",o),o=""),this.opcode("invokePartial",s,i,o),this.opcode("append")},PartialBlockStatement:function(e){this.PartialStatement(e)},MustacheStatement:function(e){this.SubExpression(e),e.escaped&&!this.options.noEscape?this.opcode("appendEscaped"):this.opcode("append")},Decorator:function(e){this.DecoratorBlock(e)},ContentStatement:function(e){e.value&&this.opcode("appendContent",e.value)},CommentStatement:function(){},SubExpression:function(e){mm(e);var r=this.classifySexpr(e);r==="simple"?this.simpleSexpr(e):r==="helper"?this.helperSexpr(e):this.ambiguousSexpr(e)},ambiguousSexpr:function(e,r,n){var i=e.path,s=i.parts[0],o=r!=null||n!=null;this.opcode("getContext",i.depth),this.opcode("pushProgram",r),this.opcode("pushProgram",n),i.strict=!0,this.accept(i),this.opcode("invokeAmbiguous",s,o)},simpleSexpr:function(e){var r=e.path;r.strict=!0,this.accept(r),this.opcode("resolvePossibleLambda")},helperSexpr:function(e,r,n){var i=this.setupFullMustacheParams(e,r,n),s=e.path,o=s.parts[0];if(this.options.knownHelpers[o])this.opcode("invokeKnownHelper",i.length,o);else{if(this.options.knownHelpersOnly)throw new ei.default("You specified knownHelpersOnly, but used the unknown helper "+o,e);s.strict=!0,s.falsy=!0,this.accept(s),this.opcode("invokeHelper",i.length,s.original,Zn.default.helpers.simpleId(s))}},PathExpression:function(e){this.addDepth(e.depth),this.opcode("getContext",e.depth);var r=e.parts[0],n=Zn.default.helpers.scopedId(e),i=!e.depth&&!n&&this.blockParamIndex(r);i?this.opcode("lookupBlockParam",i,e.parts):r?e.data?(this.options.data=!0,this.opcode("lookupData",e.depth,e.parts,e.strict)):this.opcode("lookupOnContext",e.parts,e.falsy,e.strict,n):this.opcode("pushContext")},StringLiteral:function(e){this.opcode("pushString",e.value)},NumberLiteral:function(e){this.opcode("pushLiteral",e.value)},BooleanLiteral:function(e){this.opcode("pushLiteral",e.value)},UndefinedLiteral:function(){this.opcode("pushLiteral","undefined")},NullLiteral:function(){this.opcode("pushLiteral","null")},Hash:function(e){var r=e.pairs,n=0,i=r.length;for(this.opcode("pushHash");n<i;n++)this.pushParam(r[n].value);for(;n--;)this.opcode("assignToHash",r[n].key);this.opcode("popHash")},opcode:function(e){this.opcodes.push({opcode:e,args:y$.call(arguments,1),loc:this.sourceNode[0].loc})},addDepth:function(e){e&&(this.useDepths=!0)},classifySexpr:function(e){var r=Zn.default.helpers.simpleId(e.path),n=r&&!!this.blockParamIndex(e.path.parts[0]),i=!n&&Zn.default.helpers.helperExpression(e),s=!n&&(i||r);if(s&&!i){var o=e.path.parts[0],a=this.options;a.knownHelpers[o]?i=!0:a.knownHelpersOnly&&(s=!1)}return i?"helper":s?"ambiguous":"simple"},pushParams:function(e){for(var r=0,n=e.length;r<n;r++)this.pushParam(e[r])},pushParam:function(e){var r=e.value!=null?e.value:e.original||"";if(this.stringParams)r.replace&&(r=r.replace(/^(\.?\.\/)*/g,"").replace(/\//g,".")),e.depth&&this.addDepth(e.depth),this.opcode("getContext",e.depth||0),this.opcode("pushStringParam",r,e.type),e.type==="SubExpression"&&this.accept(e);else{if(this.trackIds){var n=void 0;if(e.parts&&!Zn.default.helpers.scopedId(e)&&!e.depth&&(n=this.blockParamIndex(e.parts[0])),n){var i=e.parts.slice(1).join(".");this.opcode("pushId","BlockParam",n,i)}else r=e.original||r,r.replace&&(r=r.replace(/^this(?:\.|$)/,"").replace(/^\.\//,"").replace(/^\.$/,"")),this.opcode("pushId",e.type,r)}this.accept(e)}},setupFullMustacheParams:function(e,r,n,i){var s=e.params;return this.pushParams(s),this.opcode("pushProgram",r),this.opcode("pushProgram",n),e.hash?this.accept(e.hash):this.opcode("emptyHash",i),s},blockParamIndex:function(e){for(var r=0,n=this.options.blockParams.length;r<n;r++){var i=this.options.blockParams[r],s=i&&ti.indexOf(i,e);if(i&&s>=0)return[r,s]}}};function v$(t,e,r){if(t==null||typeof t!="string"&&t.type!=="Program")throw new ei.default("You must pass a string or Handlebars AST to Handlebars.precompile. You passed "+t);e=e||{},"data"in e||(e.data=!0),e.compat&&(e.useDepths=!0);var n=r.parse(t,e),i=new r.Compiler().compile(n,e);return new r.JavaScriptCompiler().compile(i,e)}function _$(t,e,r){if(e===void 0&&(e={}),t==null||typeof t!="string"&&t.type!=="Program")throw new ei.default("You must pass a string or Handlebars AST to Handlebars.compile. You passed "+t);e=ti.extend({},e),"data"in e||(e.data=!0),e.compat&&(e.useDepths=!0);var n=void 0;function i(){var o=r.parse(t,e),a=new r.Compiler().compile(o,e),l=new r.JavaScriptCompiler().compile(a,e,void 0,!0);return r.template(l)}function s(o,a){return n||(n=i()),n.call(this,o,a)}return s._setup=function(o){return n||(n=i()),n._setup(o)},s._child=function(o,a,l,u){return n||(n=i()),n._child(o,a,l,u)},s}function ym(t,e){if(t===e)return!0;if(ti.isArray(t)&&ti.isArray(e)&&t.length===e.length){for(var r=0;r<t.length;r++)if(!ym(t[r],e[r]))return!1;return!0}}function mm(t){if(!t.path.parts){var e=t.path;t.path={type:"PathExpression",data:!1,depth:0,parts:[e.original+""],original:e.original+"",loc:e.loc}}}});var wm=w(vl=>{var _m="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");vl.encode=function(t){if(0<=t&&t<_m.length)return _m[t];throw new TypeError("Must be between 0 and 63: "+t)};vl.decode=function(t){var e=65,r=90,n=97,i=122,s=48,o=57,a=43,l=47,u=26,d=52;return e<=t&&t<=r?t-e:n<=t&&t<=i?t-n+u:s<=t&&t<=o?t-s+d:t==a?62:t==l?63:-1}});var bl=w(wl=>{var bm=wm(),_l=5,Sm=1<<_l,Em=Sm-1,$m=Sm;function w$(t){return t<0?(-t<<1)+1:(t<<1)+0}function b$(t){var e=(t&1)===1,r=t>>1;return e?-r:r}wl.encode=function(e){var r="",n,i=w$(e);do n=i&Em,i>>>=_l,i>0&&(n|=$m),r+=bm.encode(n);while(i>0);return r};wl.decode=function(e,r,n){var i=e.length,s=0,o=0,a,l;do{if(r>=i)throw new Error("Expected more digits in base 64 VLQ value.");if(l=bm.decode(e.charCodeAt(r++)),l===-1)throw new Error("Invalid base64 digit: "+e.charAt(r-1));a=!!(l&$m),l&=Em,s=s+(l<<o),o+=_l}while(a);n.value=b$(s),n.rest=r}});var Wr=w(Pe=>{function S$(t,e,r){if(e in t)return t[e];if(arguments.length===3)return r;throw new Error('"'+e+'" is a required argument.')}Pe.getArg=S$;var Cm=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,E$=/^data:.+\,.+$/;function ni(t){var e=t.match(Cm);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}Pe.urlParse=ni;function Gr(t){var e="";return t.scheme&&(e+=t.scheme+":"),e+="//",t.auth&&(e+=t.auth+"@"),t.host&&(e+=t.host),t.port&&(e+=":"+t.port),t.path&&(e+=t.path),e}Pe.urlGenerate=Gr;function Sl(t){var e=t,r=ni(t);if(r){if(!r.path)return t;e=r.path}for(var n=Pe.isAbsolute(e),i=e.split(/\/+/),s,o=0,a=i.length-1;a>=0;a--)s=i[a],s==="."?i.splice(a,1):s===".."?o++:o>0&&(s===""?(i.splice(a+1,o),o=0):(i.splice(a,2),o--));return e=i.join("/"),e===""&&(e=n?"/":"."),r?(r.path=e,Gr(r)):e}Pe.normalize=Sl;function km(t,e){t===""&&(t="."),e===""&&(e=".");var r=ni(e),n=ni(t);if(n&&(t=n.path||"/"),r&&!r.scheme)return n&&(r.scheme=n.scheme),Gr(r);if(r||e.match(E$))return e;if(n&&!n.host&&!n.path)return n.host=e,Gr(n);var i=e.charAt(0)==="/"?e:Sl(t.replace(/\/+$/,"")+"/"+e);return n?(n.path=i,Gr(n)):i}Pe.join=km;Pe.isAbsolute=function(t){return t.charAt(0)==="/"||Cm.test(t)};function $$(t,e){t===""&&(t="."),t=t.replace(/\/$/,"");for(var r=0;e.indexOf(t+"/")!==0;){var n=t.lastIndexOf("/");if(n<0||(t=t.slice(0,n),t.match(/^([^\/]+:\/)?\/*$/)))return e;++r}return Array(r+1).join("../")+e.substr(t.length+1)}Pe.relative=$$;var xm=(function(){var t=Object.create(null);return!("__proto__"in t)})();function Pm(t){return t}function C$(t){return Om(t)?"$"+t:t}Pe.toSetString=xm?Pm:C$;function k$(t){return Om(t)?t.slice(1):t}Pe.fromSetString=xm?Pm:k$;function Om(t){if(!t)return!1;var e=t.length;if(e<9||t.charCodeAt(e-1)!==95||t.charCodeAt(e-2)!==95||t.charCodeAt(e-3)!==111||t.charCodeAt(e-4)!==116||t.charCodeAt(e-5)!==111||t.charCodeAt(e-6)!==114||t.charCodeAt(e-7)!==112||t.charCodeAt(e-8)!==95||t.charCodeAt(e-9)!==95)return!1;for(var r=e-10;r>=0;r--)if(t.charCodeAt(r)!==36)return!1;return!0}function x$(t,e,r){var n=zr(t.source,e.source);return n!==0||(n=t.originalLine-e.originalLine,n!==0)||(n=t.originalColumn-e.originalColumn,n!==0||r)||(n=t.generatedColumn-e.generatedColumn,n!==0)||(n=t.generatedLine-e.generatedLine,n!==0)?n:zr(t.name,e.name)}Pe.compareByOriginalPositions=x$;function P$(t,e,r){var n=t.generatedLine-e.generatedLine;return n!==0||(n=t.generatedColumn-e.generatedColumn,n!==0||r)||(n=zr(t.source,e.source),n!==0)||(n=t.originalLine-e.originalLine,n!==0)||(n=t.originalColumn-e.originalColumn,n!==0)?n:zr(t.name,e.name)}Pe.compareByGeneratedPositionsDeflated=P$;function zr(t,e){return t===e?0:t===null?1:e===null?-1:t>e?1:-1}function O$(t,e){var r=t.generatedLine-e.generatedLine;return r!==0||(r=t.generatedColumn-e.generatedColumn,r!==0)||(r=zr(t.source,e.source),r!==0)||(r=t.originalLine-e.originalLine,r!==0)||(r=t.originalColumn-e.originalColumn,r!==0)?r:zr(t.name,e.name)}Pe.compareByGeneratedPositionsInflated=O$;function A$(t){return JSON.parse(t.replace(/^\)]}'[^\n]*\n/,""))}Pe.parseSourceMapInput=A$;function R$(t,e,r){if(e=e||"",t&&(t[t.length-1]!=="/"&&e[0]!=="/"&&(t+="/"),e=t+e),r){var n=ni(r);if(!n)throw new Error("sourceMapURL could not be parsed");if(n.path){var i=n.path.lastIndexOf("/");i>=0&&(n.path=n.path.substring(0,i+1))}e=km(Gr(n),e)}return Sl(e)}Pe.computeSourceURL=R$});var Cl=w(Am=>{var El=Wr(),$l=Object.prototype.hasOwnProperty,fr=typeof Map<"u";function Nt(){this._array=[],this._set=fr?new Map:Object.create(null)}Nt.fromArray=function(e,r){for(var n=new Nt,i=0,s=e.length;i<s;i++)n.add(e[i],r);return n};Nt.prototype.size=function(){return fr?this._set.size:Object.getOwnPropertyNames(this._set).length};Nt.prototype.add=function(e,r){var n=fr?e:El.toSetString(e),i=fr?this.has(e):$l.call(this._set,n),s=this._array.length;(!i||r)&&this._array.push(e),i||(fr?this._set.set(e,s):this._set[n]=s)};Nt.prototype.has=function(e){if(fr)return this._set.has(e);var r=El.toSetString(e);return $l.call(this._set,r)};Nt.prototype.indexOf=function(e){if(fr){var r=this._set.get(e);if(r>=0)return r}else{var n=El.toSetString(e);if($l.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')};Nt.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)};Nt.prototype.toArray=function(){return this._array.slice()};Am.ArraySet=Nt});var Tm=w(Im=>{var Rm=Wr();function I$(t,e){var r=t.generatedLine,n=e.generatedLine,i=t.generatedColumn,s=e.generatedColumn;return n>r||n==r&&s>=i||Rm.compareByGeneratedPositionsInflated(t,e)<=0}function Vs(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}Vs.prototype.unsortedForEach=function(e,r){this._array.forEach(e,r)};Vs.prototype.add=function(e){I$(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))};Vs.prototype.toArray=function(){return this._sorted||(this._array.sort(Rm.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};Im.MappingList=Vs});var kl=w(Nm=>{var ii=bl(),ve=Wr(),Fs=Cl().ArraySet,T$=Tm().MappingList;function Ze(t){t||(t={}),this._file=ve.getArg(t,"file",null),this._sourceRoot=ve.getArg(t,"sourceRoot",null),this._skipValidation=ve.getArg(t,"skipValidation",!1),this._sources=new Fs,this._names=new Fs,this._mappings=new T$,this._sourcesContents=null}Ze.prototype._version=3;Ze.fromSourceMap=function(e){var r=e.sourceRoot,n=new Ze({file:e.file,sourceRoot:r});return e.eachMapping(function(i){var s={generated:{line:i.generatedLine,column:i.generatedColumn}};i.source!=null&&(s.source=i.source,r!=null&&(s.source=ve.relative(r,s.source)),s.original={line:i.originalLine,column:i.originalColumn},i.name!=null&&(s.name=i.name)),n.addMapping(s)}),e.sources.forEach(function(i){var s=i;r!==null&&(s=ve.relative(r,i)),n._sources.has(s)||n._sources.add(s);var o=e.sourceContentFor(i);o!=null&&n.setSourceContent(i,o)}),n};Ze.prototype.addMapping=function(e){var r=ve.getArg(e,"generated"),n=ve.getArg(e,"original",null),i=ve.getArg(e,"source",null),s=ve.getArg(e,"name",null);this._skipValidation||this._validateMapping(r,n,i,s),i!=null&&(i=String(i),this._sources.has(i)||this._sources.add(i)),s!=null&&(s=String(s),this._names.has(s)||this._names.add(s)),this._mappings.add({generatedLine:r.line,generatedColumn:r.column,originalLine:n!=null&&n.line,originalColumn:n!=null&&n.column,source:i,name:s})};Ze.prototype.setSourceContent=function(e,r){var n=e;this._sourceRoot!=null&&(n=ve.relative(this._sourceRoot,n)),r!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[ve.toSetString(n)]=r):this._sourcesContents&&(delete this._sourcesContents[ve.toSetString(n)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};Ze.prototype.applySourceMap=function(e,r,n){var i=r;if(r==null){if(e.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);i=e.file}var s=this._sourceRoot;s!=null&&(i=ve.relative(s,i));var o=new Fs,a=new Fs;this._mappings.unsortedForEach(function(l){if(l.source===i&&l.originalLine!=null){var u=e.originalPositionFor({line:l.originalLine,column:l.originalColumn});u.source!=null&&(l.source=u.source,n!=null&&(l.source=ve.join(n,l.source)),s!=null&&(l.source=ve.relative(s,l.source)),l.originalLine=u.line,l.originalColumn=u.column,u.name!=null&&(l.name=u.name))}var d=l.source;d!=null&&!o.has(d)&&o.add(d);var f=l.name;f!=null&&!a.has(f)&&a.add(f)},this),this._sources=o,this._names=a,e.sources.forEach(function(l){var u=e.sourceContentFor(l);u!=null&&(n!=null&&(l=ve.join(n,l)),s!=null&&(l=ve.relative(s,l)),this.setSourceContent(l,u))},this)};Ze.prototype._validateMapping=function(e,r,n,i){if(r&&typeof r.line!="number"&&typeof r.column!="number")throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if(!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0&&!r&&!n&&!i)){if(e&&"line"in e&&"column"in e&&r&&"line"in r&&"column"in r&&e.line>0&&e.column>=0&&r.line>0&&r.column>=0&&n)return;throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:r,name:i}))}};Ze.prototype._serializeMappings=function(){for(var e=0,r=1,n=0,i=0,s=0,o=0,a="",l,u,d,f,h=this._mappings.toArray(),m=0,g=h.length;m<g;m++){if(u=h[m],l="",u.generatedLine!==r)for(e=0;u.generatedLine!==r;)l+=";",r++;else if(m>0){if(!ve.compareByGeneratedPositionsInflated(u,h[m-1]))continue;l+=","}l+=ii.encode(u.generatedColumn-e),e=u.generatedColumn,u.source!=null&&(f=this._sources.indexOf(u.source),l+=ii.encode(f-o),o=f,l+=ii.encode(u.originalLine-1-i),i=u.originalLine-1,l+=ii.encode(u.originalColumn-n),n=u.originalColumn,u.name!=null&&(d=this._names.indexOf(u.name),l+=ii.encode(d-s),s=d)),a+=l}return a};Ze.prototype._generateSourcesContent=function(e,r){return e.map(function(n){if(!this._sourcesContents)return null;r!=null&&(n=ve.relative(r,n));var i=ve.toSetString(n);return Object.prototype.hasOwnProperty.call(this._sourcesContents,i)?this._sourcesContents[i]:null},this)};Ze.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(e.file=this._file),this._sourceRoot!=null&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e};Ze.prototype.toString=function(){return JSON.stringify(this.toJSON())};Nm.SourceMapGenerator=Ze});var Mm=w(dr=>{dr.GREATEST_LOWER_BOUND=1;dr.LEAST_UPPER_BOUND=2;function xl(t,e,r,n,i,s){var o=Math.floor((e-t)/2)+t,a=i(r,n[o],!0);return a===0?o:a>0?e-o>1?xl(o,e,r,n,i,s):s==dr.LEAST_UPPER_BOUND?e<n.length?e:-1:o:o-t>1?xl(t,o,r,n,i,s):s==dr.LEAST_UPPER_BOUND?o:t<0?-1:t}dr.search=function(e,r,n,i){if(r.length===0)return-1;var s=xl(-1,r.length,e,r,n,i||dr.GREATEST_LOWER_BOUND);if(s<0)return-1;for(;s-1>=0&&n(r[s],r[s-1],!0)===0;)--s;return s}});var jm=w(Lm=>{function Pl(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function N$(t,e){return Math.round(t+Math.random()*(e-t))}function Ol(t,e,r,n){if(r<n){var i=N$(r,n),s=r-1;Pl(t,i,n);for(var o=t[n],a=r;a<n;a++)e(t[a],o)<=0&&(s+=1,Pl(t,s,a));Pl(t,s+1,a);var l=s+1;Ol(t,e,r,l-1),Ol(t,e,l+1,n)}}Lm.quickSort=function(t,e){Ol(t,e,0,t.length-1)}});var qm=w(Hs=>{var M=Wr(),Al=Mm(),Kr=Cl().ArraySet,M$=bl(),si=jm().quickSort;function de(t,e){var r=t;return typeof t=="string"&&(r=M.parseSourceMapInput(t)),r.sections!=null?new dt(r,e):new Se(r,e)}de.fromSourceMap=function(t,e){return Se.fromSourceMap(t,e)};de.prototype._version=3;de.prototype.__generatedMappings=null;Object.defineProperty(de.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});de.prototype.__originalMappings=null;Object.defineProperty(de.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});de.prototype._charIsMappingSeparator=function(e,r){var n=e.charAt(r);return n===";"||n===","};de.prototype._parseMappings=function(e,r){throw new Error("Subclasses must implement _parseMappings")};de.GENERATED_ORDER=1;de.ORIGINAL_ORDER=2;de.GREATEST_LOWER_BOUND=1;de.LEAST_UPPER_BOUND=2;de.prototype.eachMapping=function(e,r,n){var i=r||null,s=n||de.GENERATED_ORDER,o;switch(s){case de.GENERATED_ORDER:o=this._generatedMappings;break;case de.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}var a=this.sourceRoot;o.map(function(l){var u=l.source===null?null:this._sources.at(l.source);return u=M.computeSourceURL(a,u,this._sourceMapURL),{source:u,generatedLine:l.generatedLine,generatedColumn:l.generatedColumn,originalLine:l.originalLine,originalColumn:l.originalColumn,name:l.name===null?null:this._names.at(l.name)}},this).forEach(e,i)};de.prototype.allGeneratedPositionsFor=function(e){var r=M.getArg(e,"line"),n={source:M.getArg(e,"source"),originalLine:r,originalColumn:M.getArg(e,"column",0)};if(n.source=this._findSourceIndex(n.source),n.source<0)return[];var i=[],s=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",M.compareByOriginalPositions,Al.LEAST_UPPER_BOUND);if(s>=0){var o=this._originalMappings[s];if(e.column===void 0)for(var a=o.originalLine;o&&o.originalLine===a;)i.push({line:M.getArg(o,"generatedLine",null),column:M.getArg(o,"generatedColumn",null),lastColumn:M.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++s];else for(var l=o.originalColumn;o&&o.originalLine===r&&o.originalColumn==l;)i.push({line:M.getArg(o,"generatedLine",null),column:M.getArg(o,"generatedColumn",null),lastColumn:M.getArg(o,"lastGeneratedColumn",null)}),o=this._originalMappings[++s]}return i};Hs.SourceMapConsumer=de;function Se(t,e){var r=t;typeof t=="string"&&(r=M.parseSourceMapInput(t));var n=M.getArg(r,"version"),i=M.getArg(r,"sources"),s=M.getArg(r,"names",[]),o=M.getArg(r,"sourceRoot",null),a=M.getArg(r,"sourcesContent",null),l=M.getArg(r,"mappings"),u=M.getArg(r,"file",null);if(n!=this._version)throw new Error("Unsupported version: "+n);o&&(o=M.normalize(o)),i=i.map(String).map(M.normalize).map(function(d){return o&&M.isAbsolute(o)&&M.isAbsolute(d)?M.relative(o,d):d}),this._names=Kr.fromArray(s.map(String),!0),this._sources=Kr.fromArray(i,!0),this._absoluteSources=this._sources.toArray().map(function(d){return M.computeSourceURL(o,d,e)}),this.sourceRoot=o,this.sourcesContent=a,this._mappings=l,this._sourceMapURL=e,this.file=u}Se.prototype=Object.create(de.prototype);Se.prototype.consumer=de;Se.prototype._findSourceIndex=function(t){var e=t;if(this.sourceRoot!=null&&(e=M.relative(this.sourceRoot,e)),this._sources.has(e))return this._sources.indexOf(e);var r;for(r=0;r<this._absoluteSources.length;++r)if(this._absoluteSources[r]==t)return r;return-1};Se.fromSourceMap=function(e,r){var n=Object.create(Se.prototype),i=n._names=Kr.fromArray(e._names.toArray(),!0),s=n._sources=Kr.fromArray(e._sources.toArray(),!0);n.sourceRoot=e._sourceRoot,n.sourcesContent=e._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=e._file,n._sourceMapURL=r,n._absoluteSources=n._sources.toArray().map(function(m){return M.computeSourceURL(n.sourceRoot,m,r)});for(var o=e._mappings.toArray().slice(),a=n.__generatedMappings=[],l=n.__originalMappings=[],u=0,d=o.length;u<d;u++){var f=o[u],h=new Dm;h.generatedLine=f.generatedLine,h.generatedColumn=f.generatedColumn,f.source&&(h.source=s.indexOf(f.source),h.originalLine=f.originalLine,h.originalColumn=f.originalColumn,f.name&&(h.name=i.indexOf(f.name)),l.push(h)),a.push(h)}return si(n.__originalMappings,M.compareByOriginalPositions),n};Se.prototype._version=3;Object.defineProperty(Se.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function Dm(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}Se.prototype._parseMappings=function(e,r){for(var n=1,i=0,s=0,o=0,a=0,l=0,u=e.length,d=0,f={},h={},m=[],g=[],_,x,E,V,G;d<u;)if(e.charAt(d)===";")n++,d++,i=0;else if(e.charAt(d)===",")d++;else{for(_=new Dm,_.generatedLine=n,V=d;V<u&&!this._charIsMappingSeparator(e,V);V++);if(x=e.slice(d,V),E=f[x],E)d+=x.length;else{for(E=[];d<V;)M$.decode(e,d,h),G=h.value,d=h.rest,E.push(G);if(E.length===2)throw new Error("Found a source, but no line and column");if(E.length===3)throw new Error("Found a source and line, but no column");f[x]=E}_.generatedColumn=i+E[0],i=_.generatedColumn,E.length>1&&(_.source=a+E[1],a+=E[1],_.originalLine=s+E[2],s=_.originalLine,_.originalLine+=1,_.originalColumn=o+E[3],o=_.originalColumn,E.length>4&&(_.name=l+E[4],l+=E[4])),g.push(_),typeof _.originalLine=="number"&&m.push(_)}si(g,M.compareByGeneratedPositionsDeflated),this.__generatedMappings=g,si(m,M.compareByOriginalPositions),this.__originalMappings=m};Se.prototype._findMapping=function(e,r,n,i,s,o){if(e[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[n]);if(e[i]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[i]);return Al.search(e,r,s,o)};Se.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var r=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var n=this._generatedMappings[e+1];if(r.generatedLine===n.generatedLine){r.lastGeneratedColumn=n.generatedColumn-1;continue}}r.lastGeneratedColumn=1/0}};Se.prototype.originalPositionFor=function(e){var r={generatedLine:M.getArg(e,"line"),generatedColumn:M.getArg(e,"column")},n=this._findMapping(r,this._generatedMappings,"generatedLine","generatedColumn",M.compareByGeneratedPositionsDeflated,M.getArg(e,"bias",de.GREATEST_LOWER_BOUND));if(n>=0){var i=this._generatedMappings[n];if(i.generatedLine===r.generatedLine){var s=M.getArg(i,"source",null);s!==null&&(s=this._sources.at(s),s=M.computeSourceURL(this.sourceRoot,s,this._sourceMapURL));var o=M.getArg(i,"name",null);return o!==null&&(o=this._names.at(o)),{source:s,line:M.getArg(i,"originalLine",null),column:M.getArg(i,"originalColumn",null),name:o}}}return{source:null,line:null,column:null,name:null}};Se.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return e==null}):!1};Se.prototype.sourceContentFor=function(e,r){if(!this.sourcesContent)return null;var n=this._findSourceIndex(e);if(n>=0)return this.sourcesContent[n];var i=e;this.sourceRoot!=null&&(i=M.relative(this.sourceRoot,i));var s;if(this.sourceRoot!=null&&(s=M.urlParse(this.sourceRoot))){var o=i.replace(/^file:\/\//,"");if(s.scheme=="file"&&this._sources.has(o))return this.sourcesContent[this._sources.indexOf(o)];if((!s.path||s.path=="/")&&this._sources.has("/"+i))return this.sourcesContent[this._sources.indexOf("/"+i)]}if(r)return null;throw new Error('"'+i+'" is not in the SourceMap.')};Se.prototype.generatedPositionFor=function(e){var r=M.getArg(e,"source");if(r=this._findSourceIndex(r),r<0)return{line:null,column:null,lastColumn:null};var n={source:r,originalLine:M.getArg(e,"line"),originalColumn:M.getArg(e,"column")},i=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",M.compareByOriginalPositions,M.getArg(e,"bias",de.GREATEST_LOWER_BOUND));if(i>=0){var s=this._originalMappings[i];if(s.source===n.source)return{line:M.getArg(s,"generatedLine",null),column:M.getArg(s,"generatedColumn",null),lastColumn:M.getArg(s,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};Hs.BasicSourceMapConsumer=Se;function dt(t,e){var r=t;typeof t=="string"&&(r=M.parseSourceMapInput(t));var n=M.getArg(r,"version"),i=M.getArg(r,"sections");if(n!=this._version)throw new Error("Unsupported version: "+n);this._sources=new Kr,this._names=new Kr;var s={line:-1,column:0};this._sections=i.map(function(o){if(o.url)throw new Error("Support for url field in sections not implemented.");var a=M.getArg(o,"offset"),l=M.getArg(a,"line"),u=M.getArg(a,"column");if(l<s.line||l===s.line&&u<s.column)throw new Error("Section offsets must be ordered and non-overlapping.");return s=a,{generatedOffset:{generatedLine:l+1,generatedColumn:u+1},consumer:new de(M.getArg(o,"map"),e)}})}dt.prototype=Object.create(de.prototype);dt.prototype.constructor=de;dt.prototype._version=3;Object.defineProperty(dt.prototype,"sources",{get:function(){for(var t=[],e=0;e<this._sections.length;e++)for(var r=0;r<this._sections[e].consumer.sources.length;r++)t.push(this._sections[e].consumer.sources[r]);return t}});dt.prototype.originalPositionFor=function(e){var r={generatedLine:M.getArg(e,"line"),generatedColumn:M.getArg(e,"column")},n=Al.search(r,this._sections,function(s,o){var a=s.generatedLine-o.generatedOffset.generatedLine;return a||s.generatedColumn-o.generatedOffset.generatedColumn}),i=this._sections[n];return i?i.consumer.originalPositionFor({line:r.generatedLine-(i.generatedOffset.generatedLine-1),column:r.generatedColumn-(i.generatedOffset.generatedLine===r.generatedLine?i.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}};dt.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})};dt.prototype.sourceContentFor=function(e,r){for(var n=0;n<this._sections.length;n++){var i=this._sections[n],s=i.consumer.sourceContentFor(e,!0);if(s)return s}if(r)return null;throw new Error('"'+e+'" is not in the SourceMap.')};dt.prototype.generatedPositionFor=function(e){for(var r=0;r<this._sections.length;r++){var n=this._sections[r];if(n.consumer._findSourceIndex(M.getArg(e,"source"))!==-1){var i=n.consumer.generatedPositionFor(e);if(i){var s={line:i.line+(n.generatedOffset.generatedLine-1),column:i.column+(n.generatedOffset.generatedLine===i.line?n.generatedOffset.generatedColumn-1:0)};return s}}}return{line:null,column:null}};dt.prototype._parseMappings=function(e,r){this.__generatedMappings=[],this.__originalMappings=[];for(var n=0;n<this._sections.length;n++)for(var i=this._sections[n],s=i.consumer._generatedMappings,o=0;o<s.length;o++){var a=s[o],l=i.consumer._sources.at(a.source);l=M.computeSourceURL(i.consumer.sourceRoot,l,this._sourceMapURL),this._sources.add(l),l=this._sources.indexOf(l);var u=null;a.name&&(u=i.consumer._names.at(a.name),this._names.add(u),u=this._names.indexOf(u));var d={source:l,generatedLine:a.generatedLine+(i.generatedOffset.generatedLine-1),generatedColumn:a.generatedColumn+(i.generatedOffset.generatedLine===a.generatedLine?i.generatedOffset.generatedColumn-1:0),originalLine:a.originalLine,originalColumn:a.originalColumn,name:u};this.__generatedMappings.push(d),typeof d.originalLine=="number"&&this.__originalMappings.push(d)}si(this.__generatedMappings,M.compareByGeneratedPositionsDeflated),si(this.__originalMappings,M.compareByOriginalPositions)};Hs.IndexedSourceMapConsumer=dt});var Fm=w(Vm=>{var L$=kl().SourceMapGenerator,Bs=Wr(),j$=/(\r?\n)/,D$=10,Jr="$$$isSourceNode$$$";function He(t,e,r,n,i){this.children=[],this.sourceContents={},this.line=t??null,this.column=e??null,this.source=r??null,this.name=i??null,this[Jr]=!0,n!=null&&this.add(n)}He.fromStringWithSourceMap=function(e,r,n){var i=new He,s=e.split(j$),o=0,a=function(){var h=g(),m=g()||"";return h+m;function g(){return o<s.length?s[o++]:void 0}},l=1,u=0,d=null;return r.eachMapping(function(h){if(d!==null)if(l<h.generatedLine)f(d,a()),l++,u=0;else{var m=s[o]||"",g=m.substr(0,h.generatedColumn-u);s[o]=m.substr(h.generatedColumn-u),u=h.generatedColumn,f(d,g),d=h;return}for(;l<h.generatedLine;)i.add(a()),l++;if(u<h.generatedColumn){var m=s[o]||"";i.add(m.substr(0,h.generatedColumn)),s[o]=m.substr(h.generatedColumn),u=h.generatedColumn}d=h},this),o<s.length&&(d&&f(d,a()),i.add(s.splice(o).join(""))),r.sources.forEach(function(h){var m=r.sourceContentFor(h);m!=null&&(n!=null&&(h=Bs.join(n,h)),i.setSourceContent(h,m))}),i;function f(h,m){if(h===null||h.source===void 0)i.add(m);else{var g=n?Bs.join(n,h.source):h.source;i.add(new He(h.originalLine,h.originalColumn,g,m,h.name))}}};He.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(r){this.add(r)},this);else if(e[Jr]||typeof e=="string")e&&this.children.push(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};He.prototype.prepend=function(e){if(Array.isArray(e))for(var r=e.length-1;r>=0;r--)this.prepend(e[r]);else if(e[Jr]||typeof e=="string")this.children.unshift(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};He.prototype.walk=function(e){for(var r,n=0,i=this.children.length;n<i;n++)r=this.children[n],r[Jr]?r.walk(e):r!==""&&e(r,{source:this.source,line:this.line,column:this.column,name:this.name})};He.prototype.join=function(e){var r,n,i=this.children.length;if(i>0){for(r=[],n=0;n<i-1;n++)r.push(this.children[n]),r.push(e);r.push(this.children[n]),this.children=r}return this};He.prototype.replaceRight=function(e,r){var n=this.children[this.children.length-1];return n[Jr]?n.replaceRight(e,r):typeof n=="string"?this.children[this.children.length-1]=n.replace(e,r):this.children.push("".replace(e,r)),this};He.prototype.setSourceContent=function(e,r){this.sourceContents[Bs.toSetString(e)]=r};He.prototype.walkSourceContents=function(e){for(var r=0,n=this.children.length;r<n;r++)this.children[r][Jr]&&this.children[r].walkSourceContents(e);for(var i=Object.keys(this.sourceContents),r=0,n=i.length;r<n;r++)e(Bs.fromSetString(i[r]),this.sourceContents[i[r]])};He.prototype.toString=function(){var e="";return this.walk(function(r){e+=r}),e};He.prototype.toStringWithSourceMap=function(e){var r={code:"",line:1,column:0},n=new L$(e),i=!1,s=null,o=null,a=null,l=null;return this.walk(function(u,d){r.code+=u,d.source!==null&&d.line!==null&&d.column!==null?((s!==d.source||o!==d.line||a!==d.column||l!==d.name)&&n.addMapping({source:d.source,original:{line:d.line,column:d.column},generated:{line:r.line,column:r.column},name:d.name}),s=d.source,o=d.line,a=d.column,l=d.name,i=!0):i&&(n.addMapping({generated:{line:r.line,column:r.column}}),s=null,i=!1);for(var f=0,h=u.length;f<h;f++)u.charCodeAt(f)===D$?(r.line++,r.column=0,f+1===h?(s=null,i=!1):i&&n.addMapping({source:d.source,original:{line:d.line,column:d.column},generated:{line:r.line,column:r.column},name:d.name})):r.column++}),this.walkSourceContents(function(u,d){n.setSourceContent(u,d)}),{code:r.code,map:n}};Vm.SourceNode=He});var Hm=w(Us=>{Us.SourceMapGenerator=kl().SourceMapGenerator;Us.SourceMapConsumer=qm().SourceMapConsumer;Us.SourceNode=Fm().SourceNode});var zm=w((Gs,Gm)=>{"use strict";Gs.__esModule=!0;var Il=Te(),pr=void 0;try{(typeof define!="function"||!define.amd)&&(Bm=Hm(),pr=Bm.SourceNode)}catch{}var Bm;pr||(pr=function(t,e,r,n){this.src="",n&&this.add(n)},pr.prototype={add:function(e){Il.isArray(e)&&(e=e.join("")),this.src+=e},prepend:function(e){Il.isArray(e)&&(e=e.join("")),this.src=e+this.src},toStringWithSourceMap:function(){return{code:this.toString()}},toString:function(){return this.src}});function Rl(t,e,r){if(Il.isArray(t)){for(var n=[],i=0,s=t.length;i<s;i++)n.push(e.wrap(t[i],r));return n}else if(typeof t=="boolean"||typeof t=="number")return t+"";return t}function Um(t){this.srcFile=t,this.source=[]}Um.prototype={isEmpty:function(){return!this.source.length},prepend:function(e,r){this.source.unshift(this.wrap(e,r))},push:function(e,r){this.source.push(this.wrap(e,r))},merge:function(){var e=this.empty();return this.each(function(r){e.add([" ",r,`
|
|
45
|
-
`])}),e},each:function(e){for(var r=0,n=this.source.length;r<n;r++)e(this.source[r])},empty:function(){var e=this.currentLocation||{start:{}};return new
|
|
42
|
+
Expecting `+rt.join(", ")+", got '"+(this.terminals_[L]||L)+"'":_t="Parse error on line "+(f+1)+": Unexpected "+(L==1?"end of input":"'"+(this.terminals_[L]||L)+"'"),this.parseError(_t,{text:this.lexer.match,token:this.terminals_[L]||L,line:this.lexer.yylineno,loc:P,expected:rt})}}if(ne[0]instanceof Array&&ne.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Q+", token: "+L);switch(ne[0]){case 1:s.push(L),a.push(this.lexer.yytext),l.push(this.lexer.yylloc),s.push(ne[1]),L=null,T?(L=T,T=null):(h=this.lexer.yyleng,p=this.lexer.yytext,f=this.lexer.yylineno,P=this.lexer.yylloc,m>0&&m--);break;case 2:if(xe=this.productions_[ne[1]][1],be.$=a[a.length-xe],be._$={first_line:l[l.length-(xe||1)].first_line,last_line:l[l.length-1].last_line,first_column:l[l.length-(xe||1)].first_column,last_column:l[l.length-1].last_column},b&&(be._$.range=[l[l.length-(xe||1)].range[0],l[l.length-1].range[1]]),et=this.performAction.call(be,p,h,f,this.yy,ne[1],a,l),typeof et<"u")return et;xe&&(s=s.slice(0,-1*xe*2),a=a.slice(0,-1*xe),l=l.slice(0,-1*xe)),s.push(this.productions_[ne[1]][0]),a.push(be.$),l.push(be._$),tt=u[s[s.length-2]][s[s.length-1]],s.push(tt);break;case 3:return!0}}return!0}},e=(function(){var n={EOF:1,parseError:function(o,s){if(this.yy.parser)this.yy.parser.parseError(o,s);else throw new Error(o)},setInput:function(o){return this._input=o,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var o=this._input[0];this.yytext+=o,this.yyleng++,this.offset++,this.match+=o,this.matched+=o;var s=o.match(/(?:\r\n?|\n).*/g);return s?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),o},unput:function(o){var s=o.length,a=o.split(/(?:\r\n?|\n)/g);this._input=o+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-s-1),this.offset-=s;var l=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),a.length-1&&(this.yylineno-=a.length-1);var u=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:a?(a.length===l.length?this.yylloc.first_column:0)+l[l.length-a.length].length-a[0].length:this.yylloc.first_column-s},this.options.ranges&&(this.yylloc.range=[u[0],u[0]+this.yyleng-s]),this},more:function(){return this._more=!0,this},less:function(o){this.unput(this.match.slice(o))},pastInput:function(){var o=this.matched.substr(0,this.matched.length-this.match.length);return(o.length>20?"...":"")+o.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var o=this.match;return o.length<20&&(o+=this._input.substr(0,20-o.length)),(o.substr(0,20)+(o.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var o=this.pastInput(),s=new Array(o.length+1).join("-");return o+this.upcomingInput()+`
|
|
43
|
+
`+s+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var o,s,a,l,u,p;this._more||(this.yytext="",this.match="");for(var f=this._currentRules(),h=0;h<f.length&&(a=this._input.match(this.rules[f[h]]),!(a&&(!s||a[0].length>s[0].length)&&(s=a,l=h,!this.options.flex)));h++);return s?(p=s[0].match(/(?:\r\n?|\n).*/g),p&&(this.yylineno+=p.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:p?p[p.length-1].length-p[p.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+s[0].length},this.yytext+=s[0],this.match+=s[0],this.matches=s,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._input=this._input.slice(s[0].length),this.matched+=s[0],o=this.performAction.call(this,this.yy,this,f[l],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),o||void 0):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
|
44
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var o=this.next();return typeof o<"u"?o:this.lex()},begin:function(o){this.conditionStack.push(o)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(o){this.begin(o)}};return n.options={},n.performAction=function(o,s,a,l){function u(f,h){return s.yytext=s.yytext.substring(f,s.yyleng-h+f)}var p=l;switch(a){case 0:if(s.yytext.slice(-2)==="\\\\"?(u(0,1),this.begin("mu")):s.yytext.slice(-1)==="\\"?(u(0,1),this.begin("emu")):this.begin("mu"),s.yytext)return 15;break;case 1:return 15;case 2:return this.popState(),15;break;case 3:return this.begin("raw"),15;break;case 4:return this.popState(),this.conditionStack[this.conditionStack.length-1]==="raw"?15:(u(5,9),"END_RAW_BLOCK");case 5:return 15;case 6:return this.popState(),14;break;case 7:return 65;case 8:return 68;case 9:return 19;case 10:return this.popState(),this.begin("raw"),23;break;case 11:return 55;case 12:return 60;case 13:return 29;case 14:return 47;case 15:return this.popState(),44;break;case 16:return this.popState(),44;break;case 17:return 34;case 18:return 39;case 19:return 51;case 20:return 48;case 21:this.unput(s.yytext),this.popState(),this.begin("com");break;case 22:return this.popState(),14;break;case 23:return 48;case 24:return 73;case 25:return 72;case 26:return 72;case 27:return 87;case 28:break;case 29:return this.popState(),54;break;case 30:return this.popState(),33;break;case 31:return s.yytext=u(1,2).replace(/\\"/g,'"'),80;break;case 32:return s.yytext=u(1,2).replace(/\\'/g,"'"),80;break;case 33:return 85;case 34:return 82;case 35:return 82;case 36:return 83;case 37:return 84;case 38:return 81;case 39:return 75;case 40:return 77;case 41:return 72;case 42:return s.yytext=s.yytext.replace(/\\([\\\]])/g,"$1"),72;break;case 43:return"INVALID";case 44:return 5}},n.rules=[/^(?:[^\x00]*?(?=(\{\{)))/,/^(?:[^\x00]+)/,/^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/,/^(?:\{\{\{\{(?=[^\/]))/,/^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/,/^(?:[^\x00]+?(?=(\{\{\{\{)))/,/^(?:[\s\S]*?--(~)?\}\})/,/^(?:\()/,/^(?:\))/,/^(?:\{\{\{\{)/,/^(?:\}\}\}\})/,/^(?:\{\{(~)?>)/,/^(?:\{\{(~)?#>)/,/^(?:\{\{(~)?#\*?)/,/^(?:\{\{(~)?\/)/,/^(?:\{\{(~)?\^\s*(~)?\}\})/,/^(?:\{\{(~)?\s*else\s*(~)?\}\})/,/^(?:\{\{(~)?\^)/,/^(?:\{\{(~)?\s*else\b)/,/^(?:\{\{(~)?\{)/,/^(?:\{\{(~)?&)/,/^(?:\{\{(~)?!--)/,/^(?:\{\{(~)?![\s\S]*?\}\})/,/^(?:\{\{(~)?\*?)/,/^(?:=)/,/^(?:\.\.)/,/^(?:\.(?=([=~}\s\/.)|])))/,/^(?:[\/.])/,/^(?:\s+)/,/^(?:\}(~)?\}\})/,/^(?:(~)?\}\})/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:@)/,/^(?:true(?=([~}\s)])))/,/^(?:false(?=([~}\s)])))/,/^(?:undefined(?=([~}\s)])))/,/^(?:null(?=([~}\s)])))/,/^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/,/^(?:as\s+\|)/,/^(?:\|)/,/^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/,/^(?:\[(\\\]|[^\]])*\])/,/^(?:.)/,/^(?:$)/],n.conditions={mu:{rules:[7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44],inclusive:!1},emu:{rules:[2],inclusive:!1},com:{rules:[6],inclusive:!1},raw:{rules:[3,4,5],inclusive:!1},INITIAL:{rules:[0,1,44],inclusive:!0}},n})();t.lexer=e;function r(){this.yy={}}return r.prototype=t,t.Parser=r,new r})();zo.default=A$;Fm.exports=zo.default});var Xo=w((Yo,Gm)=>{"use strict";Yo.__esModule=!0;function O$(t){return t&&t.__esModule?t:{default:t}}var R$=Fe(),Rl=O$(R$);function Ko(){this.parents=[]}Ko.prototype={constructor:Ko,mutating:!1,acceptKey:function(e,r){var n=this.accept(e[r]);if(this.mutating){if(n&&!Ko.prototype[n.type])throw new Rl.default('Unexpected node type "'+n.type+'" found when accepting '+r+" on "+e.type);e[r]=n}},acceptRequired:function(e,r){if(this.acceptKey(e,r),!e[r])throw new Rl.default(e.type+" requires "+r)},acceptArray:function(e){for(var r=0,n=e.length;r<n;r++)this.acceptKey(e,r),e[r]||(e.splice(r,1),r--,n--)},accept:function(e){if(e){if(!this[e.type])throw new Rl.default("Unknown type: "+e.type,e);this.current&&this.parents.unshift(this.current),this.current=e;var r=this[e.type](e);if(this.current=this.parents.shift(),!this.mutating||r)return r;if(r!==!1)return e}},Program:function(e){this.acceptArray(e.body)},MustacheStatement:Jo,Decorator:Jo,BlockStatement:Bm,DecoratorBlock:Bm,PartialStatement:Um,PartialBlockStatement:function(e){Um.call(this,e),this.acceptKey(e,"program")},ContentStatement:function(){},CommentStatement:function(){},SubExpression:Jo,PathExpression:function(){},StringLiteral:function(){},NumberLiteral:function(){},BooleanLiteral:function(){},UndefinedLiteral:function(){},NullLiteral:function(){},Hash:function(e){this.acceptArray(e.pairs)},HashPair:function(e){this.acceptRequired(e,"value")}};function Jo(t){this.acceptRequired(t,"path"),this.acceptArray(t.params),this.acceptKey(t,"hash")}function Bm(t){Jo.call(this,t),this.acceptKey(t,"program"),this.acceptKey(t,"inverse")}function Um(t){this.acceptRequired(t,"name"),this.acceptArray(t.params),this.acceptKey(t,"hash")}Yo.default=Ko;Gm.exports=Yo.default});var zm=w((Qo,Wm)=>{"use strict";Qo.__esModule=!0;function I$(t){return t&&t.__esModule?t:{default:t}}var T$=Xo(),N$=I$(T$);function gt(){var t=arguments.length<=0||arguments[0]===void 0?{}:arguments[0];this.options=t}gt.prototype=new N$.default;gt.prototype.Program=function(t){var e=!this.options.ignoreStandalone,r=!this.isRootSeen;this.isRootSeen=!0;for(var n=t.body,i=0,o=n.length;i<o;i++){var s=n[i],a=this.accept(s);if(a){var l=Il(n,i,r),u=Tl(n,i,r),p=a.openStandalone&&l,f=a.closeStandalone&&u,h=a.inlineStandalone&&l&&u;a.close&&hr(n,i,!0),a.open&&Wt(n,i,!0),e&&h&&(hr(n,i),Wt(n,i)&&s.type==="PartialStatement"&&(s.indent=/([ \t]+$)/.exec(n[i-1].original)[1])),e&&p&&(hr((s.program||s.inverse).body),Wt(n,i)),e&&f&&(hr(n,i),Wt((s.inverse||s.program).body))}}return t};gt.prototype.BlockStatement=gt.prototype.DecoratorBlock=gt.prototype.PartialBlockStatement=function(t){this.accept(t.program),this.accept(t.inverse);var e=t.program||t.inverse,r=t.program&&t.inverse,n=r,i=r;if(r&&r.chained)for(n=r.body[0].program;i.chained;)i=i.body[i.body.length-1].program;var o={open:t.openStrip.open,close:t.closeStrip.close,openStandalone:Tl(e.body),closeStandalone:Il((n||e).body)};if(t.openStrip.close&&hr(e.body,null,!0),r){var s=t.inverseStrip;s.open&&Wt(e.body,null,!0),s.close&&hr(n.body,null,!0),t.closeStrip.open&&Wt(i.body,null,!0),!this.options.ignoreStandalone&&Il(e.body)&&Tl(n.body)&&(Wt(e.body),hr(n.body))}else t.closeStrip.open&&Wt(e.body,null,!0);return o};gt.prototype.Decorator=gt.prototype.MustacheStatement=function(t){return t.strip};gt.prototype.PartialStatement=gt.prototype.CommentStatement=function(t){var e=t.strip||{};return{inlineStandalone:!0,open:e.open,close:e.close}};function Il(t,e,r){e===void 0&&(e=t.length);var n=t[e-1],i=t[e-2];if(!n)return r;if(n.type==="ContentStatement")return(i||!r?/\r?\n\s*?$/:/(^|\r?\n)\s*?$/).test(n.original)}function Tl(t,e,r){e===void 0&&(e=-1);var n=t[e+1],i=t[e+2];if(!n)return r;if(n.type==="ContentStatement")return(i||!r?/^\s*?\r?\n/:/^\s*?(\r?\n|$)/).test(n.original)}function hr(t,e,r){var n=t[e==null?0:e+1];if(!(!n||n.type!=="ContentStatement"||!r&&n.rightStripped)){var i=n.value;n.value=n.value.replace(r?/^\s+/:/^[ \t]*\r?\n?/,""),n.rightStripped=n.value!==i}}function Wt(t,e,r){var n=t[e==null?t.length-1:e-1];if(!(!n||n.type!=="ContentStatement"||!r&&n.leftStripped)){var i=n.value;return n.value=n.value.replace(r?/\s+$/:/[ \t]+$/,""),n.leftStripped=n.value!==i,n.leftStripped}}Qo.default=gt;Wm.exports=Qo.default});var Km=w(Xe=>{"use strict";Xe.__esModule=!0;Xe.SourceLocation=j$;Xe.id=D$;Xe.stripFlags=V$;Xe.stripComment=q$;Xe.preparePath=F$;Xe.prepareMustache=H$;Xe.prepareRawBlock=B$;Xe.prepareBlock=U$;Xe.prepareProgram=G$;Xe.preparePartialBlock=W$;function M$(t){return t&&t.__esModule?t:{default:t}}var L$=Fe(),Nl=M$(L$);function Ml(t,e){if(e=e.path?e.path.original:e,t.path.original!==e){var r={loc:t.path.loc};throw new Nl.default(t.path.original+" doesn't match "+e,r)}}function j$(t,e){this.source=t,this.start={line:e.first_line,column:e.first_column},this.end={line:e.last_line,column:e.last_column}}function D$(t){return/^\[.*\]$/.test(t)?t.substring(1,t.length-1):t}function V$(t,e){return{open:t.charAt(2)==="~",close:e.charAt(e.length-3)==="~"}}function q$(t){return t.replace(/^\{\{~?!-?-?/,"").replace(/-?-?~?\}\}$/,"")}function F$(t,e,r){r=this.locInfo(r);for(var n=t?"@":"",i=[],o=0,s=0,a=e.length;s<a;s++){var l=e[s].part,u=e[s].original!==l;if(n+=(e[s].separator||"")+l,!u&&(l===".."||l==="."||l==="this")){if(i.length>0)throw new Nl.default("Invalid path: "+n,{loc:r});l===".."&&o++}else i.push(l)}return{type:"PathExpression",data:t,depth:o,parts:i,original:n,loc:r}}function H$(t,e,r,n,i,o){var s=n.charAt(3)||n.charAt(2),a=s!=="{"&&s!=="&",l=/\*/.test(n);return{type:l?"Decorator":"MustacheStatement",path:t,params:e,hash:r,escaped:a,strip:i,loc:this.locInfo(o)}}function B$(t,e,r,n){Ml(t,r),n=this.locInfo(n);var i={type:"Program",body:e,strip:{},loc:n};return{type:"BlockStatement",path:t.path,params:t.params,hash:t.hash,program:i,openStrip:{},inverseStrip:{},closeStrip:{},loc:n}}function U$(t,e,r,n,i,o){n&&n.path&&Ml(t,n);var s=/\*/.test(t.open);e.blockParams=t.blockParams;var a=void 0,l=void 0;if(r){if(s)throw new Nl.default("Unexpected inverse block on decorator",r);r.chain&&(r.program.body[0].closeStrip=n.strip),l=r.strip,a=r.program}return i&&(i=a,a=e,e=i),{type:s?"DecoratorBlock":"BlockStatement",path:t.path,params:t.params,hash:t.hash,program:e,inverse:a,openStrip:t.strip,inverseStrip:l,closeStrip:n&&n.strip,loc:this.locInfo(o)}}function G$(t,e){if(!e&&t.length){var r=t[0].loc,n=t[t.length-1].loc;r&&n&&(e={source:r.source,start:{line:r.start.line,column:r.start.column},end:{line:n.end.line,column:n.end.column}})}return{type:"Program",body:t,strip:{},loc:e}}function W$(t,e,r,n){return Ml(t,r),{type:"PartialBlockStatement",name:t.path,params:t.params,hash:t.hash,program:e,openStrip:t.strip,closeStrip:r&&r.strip,loc:this.locInfo(n)}}});var Ym=w(ii=>{"use strict";ii.__esModule=!0;ii.parseWithoutProcessing=Jm;ii.parse=tx;function z$(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}function Dl(t){return t&&t.__esModule?t:{default:t}}var K$=Hm(),Ll=Dl(K$),J$=zm(),Y$=Dl(J$),X$=Km(),Q$=z$(X$),Z$=Fe(),ni=Dl(Z$),ex=Te();ii.parser=Ll.default;var Zo={};ex.extend(Zo,Q$);function Jm(t,e){if(t.type==="Program")return rx(t),t;Ll.default.yy=Zo,Zo.locInfo=function(n){return new Zo.SourceLocation(e&&e.srcName,n)};var r=Ll.default.parse(t);return r}function tx(t,e){var r=Jm(t,e),n=new Y$.default(e);return n.accept(r)}function rx(t){jl(t)}function jl(t){if(t!=null){if(Array.isArray(t)){t.forEach(jl);return}if(typeof t=="object"){if(t.type==="PathExpression"){if(!nx(t.depth))throw new ni.default("Invalid AST: PathExpression.depth must be an integer");if(!Array.isArray(t.parts))throw new ni.default("Invalid AST: PathExpression.parts must be an array");for(var e=0;e<t.parts.length;e++)if(typeof t.parts[e]!="string")throw new ni.default("Invalid AST: PathExpression.parts must only contain strings")}else if(t.type==="NumberLiteral"){if(typeof t.value!="number"||!isFinite(t.value))throw new ni.default("Invalid AST: NumberLiteral.value must be a number")}else if(t.type==="BooleanLiteral"&&typeof t.value!="boolean")throw new ni.default("Invalid AST: BooleanLiteral.value must be a boolean");Object.keys(t).forEach(function(r){r!=="loc"&&jl(t[r])})}}}function nx(t){return typeof t=="number"&&isFinite(t)&&Math.floor(t)===t&&t>=0}});var eg=w(ci=>{"use strict";ci.__esModule=!0;ci.Compiler=Vl;ci.precompile=ax;ci.compile=cx;function Qm(t){return t&&t.__esModule?t:{default:t}}var ix=Fe(),si=Qm(ix),ai=Te(),ox=Ol(),oi=Qm(ox),sx=[].slice;function Vl(){}Vl.prototype={compiler:Vl,equals:function(e){var r=this.opcodes.length;if(e.opcodes.length!==r)return!1;for(var n=0;n<r;n++){var i=this.opcodes[n],o=e.opcodes[n];if(i.opcode!==o.opcode||!Zm(i.args,o.args))return!1}r=this.children.length;for(var n=0;n<r;n++)if(!this.children[n].equals(e.children[n]))return!1;return!0},guid:0,compile:function(e,r){return this.sourceNode=[],this.opcodes=[],this.children=[],this.options=r,this.stringParams=r.stringParams,this.trackIds=r.trackIds,r.blockParams=r.blockParams||[],r.knownHelpers=ai.extend(Object.create(null),{helperMissing:!0,blockHelperMissing:!0,each:!0,if:!0,unless:!0,with:!0,log:!0,lookup:!0},r.knownHelpers),this.accept(e)},compileProgram:function(e){var r=new this.compiler,n=r.compile(e,this.options),i=this.guid++;return this.usePartial=this.usePartial||n.usePartial,this.children[i]=n,this.useDepths=this.useDepths||n.useDepths,i},accept:function(e){if(!this[e.type])throw new si.default("Unknown type: "+e.type,e);this.sourceNode.unshift(e);var r=this[e.type](e);return this.sourceNode.shift(),r},Program:function(e){this.options.blockParams.unshift(e.blockParams);for(var r=e.body,n=r.length,i=0;i<n;i++)this.accept(r[i]);return this.options.blockParams.shift(),this.isSimple=n===1,this.blockParams=e.blockParams?e.blockParams.length:0,this},BlockStatement:function(e){Xm(e);var r=e.program,n=e.inverse;r=r&&this.compileProgram(r),n=n&&this.compileProgram(n);var i=this.classifySexpr(e);i==="helper"?this.helperSexpr(e,r,n):i==="simple"?(this.simpleSexpr(e),this.opcode("pushProgram",r),this.opcode("pushProgram",n),this.opcode("emptyHash"),this.opcode("blockValue",e.path.original)):(this.ambiguousSexpr(e,r,n),this.opcode("pushProgram",r),this.opcode("pushProgram",n),this.opcode("emptyHash"),this.opcode("ambiguousBlockValue")),this.opcode("append")},DecoratorBlock:function(e){var r=e.program&&this.compileProgram(e.program),n=this.setupFullMustacheParams(e,r,void 0),i=e.path;this.useDecorators=!0,this.opcode("registerDecorator",n.length,i.original)},PartialStatement:function(e){this.usePartial=!0;var r=e.program;r&&(r=this.compileProgram(e.program));var n=e.params;if(n.length>1)throw new si.default("Unsupported number of partial arguments: "+n.length,e);n.length||(this.options.explicitPartialContext?this.opcode("pushLiteral","undefined"):n.push({type:"PathExpression",parts:[],depth:0}));var i=e.name.original,o=e.name.type==="SubExpression";o&&this.accept(e.name),this.setupFullMustacheParams(e,r,void 0,!0);var s=e.indent||"";this.options.preventIndent&&s&&(this.opcode("appendContent",s),s=""),this.opcode("invokePartial",o,i,s),this.opcode("append")},PartialBlockStatement:function(e){this.PartialStatement(e)},MustacheStatement:function(e){this.SubExpression(e),e.escaped&&!this.options.noEscape?this.opcode("appendEscaped"):this.opcode("append")},Decorator:function(e){this.DecoratorBlock(e)},ContentStatement:function(e){e.value&&this.opcode("appendContent",e.value)},CommentStatement:function(){},SubExpression:function(e){Xm(e);var r=this.classifySexpr(e);r==="simple"?this.simpleSexpr(e):r==="helper"?this.helperSexpr(e):this.ambiguousSexpr(e)},ambiguousSexpr:function(e,r,n){var i=e.path,o=i.parts[0],s=r!=null||n!=null;this.opcode("getContext",i.depth),this.opcode("pushProgram",r),this.opcode("pushProgram",n),i.strict=!0,this.accept(i),this.opcode("invokeAmbiguous",o,s)},simpleSexpr:function(e){var r=e.path;r.strict=!0,this.accept(r),this.opcode("resolvePossibleLambda")},helperSexpr:function(e,r,n){var i=this.setupFullMustacheParams(e,r,n),o=e.path,s=o.parts[0];if(this.options.knownHelpers[s])this.opcode("invokeKnownHelper",i.length,s);else{if(this.options.knownHelpersOnly)throw new si.default("You specified knownHelpersOnly, but used the unknown helper "+s,e);o.strict=!0,o.falsy=!0,this.accept(o),this.opcode("invokeHelper",i.length,o.original,oi.default.helpers.simpleId(o))}},PathExpression:function(e){this.addDepth(e.depth),this.opcode("getContext",e.depth);var r=e.parts[0],n=oi.default.helpers.scopedId(e),i=!e.depth&&!n&&this.blockParamIndex(r);i?this.opcode("lookupBlockParam",i,e.parts):r?e.data?(this.options.data=!0,this.opcode("lookupData",e.depth,e.parts,e.strict)):this.opcode("lookupOnContext",e.parts,e.falsy,e.strict,n):this.opcode("pushContext")},StringLiteral:function(e){this.opcode("pushString",e.value)},NumberLiteral:function(e){this.opcode("pushLiteral",e.value)},BooleanLiteral:function(e){this.opcode("pushLiteral",e.value)},UndefinedLiteral:function(){this.opcode("pushLiteral","undefined")},NullLiteral:function(){this.opcode("pushLiteral","null")},Hash:function(e){var r=e.pairs,n=0,i=r.length;for(this.opcode("pushHash");n<i;n++)this.pushParam(r[n].value);for(;n--;)this.opcode("assignToHash",r[n].key);this.opcode("popHash")},opcode:function(e){this.opcodes.push({opcode:e,args:sx.call(arguments,1),loc:this.sourceNode[0].loc})},addDepth:function(e){e&&(this.useDepths=!0)},classifySexpr:function(e){var r=oi.default.helpers.simpleId(e.path),n=r&&!!this.blockParamIndex(e.path.parts[0]),i=!n&&oi.default.helpers.helperExpression(e),o=!n&&(i||r);if(o&&!i){var s=e.path.parts[0],a=this.options;a.knownHelpers[s]?i=!0:a.knownHelpersOnly&&(o=!1)}return i?"helper":o?"ambiguous":"simple"},pushParams:function(e){for(var r=0,n=e.length;r<n;r++)this.pushParam(e[r])},pushParam:function(e){var r=e.value!=null?e.value:e.original||"";if(this.stringParams)r.replace&&(r=r.replace(/^(\.?\.\/)*/g,"").replace(/\//g,".")),e.depth&&this.addDepth(e.depth),this.opcode("getContext",e.depth||0),this.opcode("pushStringParam",r,e.type),e.type==="SubExpression"&&this.accept(e);else{if(this.trackIds){var n=void 0;if(e.parts&&!oi.default.helpers.scopedId(e)&&!e.depth&&(n=this.blockParamIndex(e.parts[0])),n){var i=e.parts.slice(1).join(".");this.opcode("pushId","BlockParam",n,i)}else r=e.original||r,r.replace&&(r=r.replace(/^this(?:\.|$)/,"").replace(/^\.\//,"").replace(/^\.$/,"")),this.opcode("pushId",e.type,r)}this.accept(e)}},setupFullMustacheParams:function(e,r,n,i){var o=e.params;return this.pushParams(o),this.opcode("pushProgram",r),this.opcode("pushProgram",n),e.hash?this.accept(e.hash):this.opcode("emptyHash",i),o},blockParamIndex:function(e){for(var r=0,n=this.options.blockParams.length;r<n;r++){var i=this.options.blockParams[r],o=i&&ai.indexOf(i,e);if(i&&o>=0)return[r,o]}}};function ax(t,e,r){if(t==null||typeof t!="string"&&t.type!=="Program")throw new si.default("You must pass a string or Handlebars AST to Handlebars.precompile. You passed "+t);e=e||{},"data"in e||(e.data=!0),e.compat&&(e.useDepths=!0);var n=r.parse(t,e),i=new r.Compiler().compile(n,e);return new r.JavaScriptCompiler().compile(i,e)}function cx(t,e,r){if(e===void 0&&(e={}),t==null||typeof t!="string"&&t.type!=="Program")throw new si.default("You must pass a string or Handlebars AST to Handlebars.compile. You passed "+t);e=ai.extend({},e),"data"in e||(e.data=!0),e.compat&&(e.useDepths=!0);var n=void 0;function i(){var s=r.parse(t,e),a=new r.Compiler().compile(s,e),l=new r.JavaScriptCompiler().compile(a,e,void 0,!0);return r.template(l)}function o(s,a){return n||(n=i()),n.call(this,s,a)}return o._setup=function(s){return n||(n=i()),n._setup(s)},o._child=function(s,a,l,u){return n||(n=i()),n._child(s,a,l,u)},o}function Zm(t,e){if(t===e)return!0;if(ai.isArray(t)&&ai.isArray(e)&&t.length===e.length){for(var r=0;r<t.length;r++)if(!Zm(t[r],e[r]))return!1;return!0}}function Xm(t){if(!t.path.parts){var e=t.path;t.path={type:"PathExpression",data:!1,depth:0,parts:[e.original+""],original:e.original+"",loc:e.loc}}}});var rg=w(ql=>{var tg="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");ql.encode=function(t){if(0<=t&&t<tg.length)return tg[t];throw new TypeError("Must be between 0 and 63: "+t)};ql.decode=function(t){var e=65,r=90,n=97,i=122,o=48,s=57,a=43,l=47,u=26,p=52;return e<=t&&t<=r?t-e:n<=t&&t<=i?t-n+u:o<=t&&t<=s?t-o+p:t==a?62:t==l?63:-1}});var Bl=w(Hl=>{var ng=rg(),Fl=5,ig=1<<Fl,og=ig-1,sg=ig;function lx(t){return t<0?(-t<<1)+1:(t<<1)+0}function ux(t){var e=(t&1)===1,r=t>>1;return e?-r:r}Hl.encode=function(e){var r="",n,i=lx(e);do n=i&og,i>>>=Fl,i>0&&(n|=sg),r+=ng.encode(n);while(i>0);return r};Hl.decode=function(e,r,n){var i=e.length,o=0,s=0,a,l;do{if(r>=i)throw new Error("Expected more digits in base 64 VLQ value.");if(l=ng.decode(e.charCodeAt(r++)),l===-1)throw new Error("Invalid base64 digit: "+e.charAt(r-1));a=!!(l&sg),l&=og,o=o+(l<<s),s+=Fl}while(a);n.value=ux(o),n.rest=r}});var Yr=w(Ae=>{function fx(t,e,r){if(e in t)return t[e];if(arguments.length===3)return r;throw new Error('"'+e+'" is a required argument.')}Ae.getArg=fx;var ag=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,px=/^data:.+\,.+$/;function li(t){var e=t.match(ag);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}Ae.urlParse=li;function Kr(t){var e="";return t.scheme&&(e+=t.scheme+":"),e+="//",t.auth&&(e+=t.auth+"@"),t.host&&(e+=t.host),t.port&&(e+=":"+t.port),t.path&&(e+=t.path),e}Ae.urlGenerate=Kr;function Ul(t){var e=t,r=li(t);if(r){if(!r.path)return t;e=r.path}for(var n=Ae.isAbsolute(e),i=e.split(/\/+/),o,s=0,a=i.length-1;a>=0;a--)o=i[a],o==="."?i.splice(a,1):o===".."?s++:s>0&&(o===""?(i.splice(a+1,s),s=0):(i.splice(a,2),s--));return e=i.join("/"),e===""&&(e=n?"/":"."),r?(r.path=e,Kr(r)):e}Ae.normalize=Ul;function cg(t,e){t===""&&(t="."),e===""&&(e=".");var r=li(e),n=li(t);if(n&&(t=n.path||"/"),r&&!r.scheme)return n&&(r.scheme=n.scheme),Kr(r);if(r||e.match(px))return e;if(n&&!n.host&&!n.path)return n.host=e,Kr(n);var i=e.charAt(0)==="/"?e:Ul(t.replace(/\/+$/,"")+"/"+e);return n?(n.path=i,Kr(n)):i}Ae.join=cg;Ae.isAbsolute=function(t){return t.charAt(0)==="/"||ag.test(t)};function dx(t,e){t===""&&(t="."),t=t.replace(/\/$/,"");for(var r=0;e.indexOf(t+"/")!==0;){var n=t.lastIndexOf("/");if(n<0||(t=t.slice(0,n),t.match(/^([^\/]+:\/)?\/*$/)))return e;++r}return Array(r+1).join("../")+e.substr(t.length+1)}Ae.relative=dx;var lg=(function(){var t=Object.create(null);return!("__proto__"in t)})();function ug(t){return t}function hx(t){return fg(t)?"$"+t:t}Ae.toSetString=lg?ug:hx;function mx(t){return fg(t)?t.slice(1):t}Ae.fromSetString=lg?ug:mx;function fg(t){if(!t)return!1;var e=t.length;if(e<9||t.charCodeAt(e-1)!==95||t.charCodeAt(e-2)!==95||t.charCodeAt(e-3)!==111||t.charCodeAt(e-4)!==116||t.charCodeAt(e-5)!==111||t.charCodeAt(e-6)!==114||t.charCodeAt(e-7)!==112||t.charCodeAt(e-8)!==95||t.charCodeAt(e-9)!==95)return!1;for(var r=e-10;r>=0;r--)if(t.charCodeAt(r)!==36)return!1;return!0}function gx(t,e,r){var n=Jr(t.source,e.source);return n!==0||(n=t.originalLine-e.originalLine,n!==0)||(n=t.originalColumn-e.originalColumn,n!==0||r)||(n=t.generatedColumn-e.generatedColumn,n!==0)||(n=t.generatedLine-e.generatedLine,n!==0)?n:Jr(t.name,e.name)}Ae.compareByOriginalPositions=gx;function yx(t,e,r){var n=t.generatedLine-e.generatedLine;return n!==0||(n=t.generatedColumn-e.generatedColumn,n!==0||r)||(n=Jr(t.source,e.source),n!==0)||(n=t.originalLine-e.originalLine,n!==0)||(n=t.originalColumn-e.originalColumn,n!==0)?n:Jr(t.name,e.name)}Ae.compareByGeneratedPositionsDeflated=yx;function Jr(t,e){return t===e?0:t===null?1:e===null?-1:t>e?1:-1}function vx(t,e){var r=t.generatedLine-e.generatedLine;return r!==0||(r=t.generatedColumn-e.generatedColumn,r!==0)||(r=Jr(t.source,e.source),r!==0)||(r=t.originalLine-e.originalLine,r!==0)||(r=t.originalColumn-e.originalColumn,r!==0)?r:Jr(t.name,e.name)}Ae.compareByGeneratedPositionsInflated=vx;function _x(t){return JSON.parse(t.replace(/^\)]}'[^\n]*\n/,""))}Ae.parseSourceMapInput=_x;function wx(t,e,r){if(e=e||"",t&&(t[t.length-1]!=="/"&&e[0]!=="/"&&(t+="/"),e=t+e),r){var n=li(r);if(!n)throw new Error("sourceMapURL could not be parsed");if(n.path){var i=n.path.lastIndexOf("/");i>=0&&(n.path=n.path.substring(0,i+1))}e=cg(Kr(n),e)}return Ul(e)}Ae.computeSourceURL=wx});var zl=w(pg=>{var Gl=Yr(),Wl=Object.prototype.hasOwnProperty,mr=typeof Map<"u";function It(){this._array=[],this._set=mr?new Map:Object.create(null)}It.fromArray=function(e,r){for(var n=new It,i=0,o=e.length;i<o;i++)n.add(e[i],r);return n};It.prototype.size=function(){return mr?this._set.size:Object.getOwnPropertyNames(this._set).length};It.prototype.add=function(e,r){var n=mr?e:Gl.toSetString(e),i=mr?this.has(e):Wl.call(this._set,n),o=this._array.length;(!i||r)&&this._array.push(e),i||(mr?this._set.set(e,o):this._set[n]=o)};It.prototype.has=function(e){if(mr)return this._set.has(e);var r=Gl.toSetString(e);return Wl.call(this._set,r)};It.prototype.indexOf=function(e){if(mr){var r=this._set.get(e);if(r>=0)return r}else{var n=Gl.toSetString(e);if(Wl.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')};It.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)};It.prototype.toArray=function(){return this._array.slice()};pg.ArraySet=It});var mg=w(hg=>{var dg=Yr();function bx(t,e){var r=t.generatedLine,n=e.generatedLine,i=t.generatedColumn,o=e.generatedColumn;return n>r||n==r&&o>=i||dg.compareByGeneratedPositionsInflated(t,e)<=0}function es(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}es.prototype.unsortedForEach=function(e,r){this._array.forEach(e,r)};es.prototype.add=function(e){bx(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))};es.prototype.toArray=function(){return this._sorted||(this._array.sort(dg.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};hg.MappingList=es});var Kl=w(gg=>{var ui=Bl(),ve=Yr(),ts=zl().ArraySet,Sx=mg().MappingList;function Qe(t){t||(t={}),this._file=ve.getArg(t,"file",null),this._sourceRoot=ve.getArg(t,"sourceRoot",null),this._skipValidation=ve.getArg(t,"skipValidation",!1),this._sources=new ts,this._names=new ts,this._mappings=new Sx,this._sourcesContents=null}Qe.prototype._version=3;Qe.fromSourceMap=function(e){var r=e.sourceRoot,n=new Qe({file:e.file,sourceRoot:r});return e.eachMapping(function(i){var o={generated:{line:i.generatedLine,column:i.generatedColumn}};i.source!=null&&(o.source=i.source,r!=null&&(o.source=ve.relative(r,o.source)),o.original={line:i.originalLine,column:i.originalColumn},i.name!=null&&(o.name=i.name)),n.addMapping(o)}),e.sources.forEach(function(i){var o=i;r!==null&&(o=ve.relative(r,i)),n._sources.has(o)||n._sources.add(o);var s=e.sourceContentFor(i);s!=null&&n.setSourceContent(i,s)}),n};Qe.prototype.addMapping=function(e){var r=ve.getArg(e,"generated"),n=ve.getArg(e,"original",null),i=ve.getArg(e,"source",null),o=ve.getArg(e,"name",null);this._skipValidation||this._validateMapping(r,n,i,o),i!=null&&(i=String(i),this._sources.has(i)||this._sources.add(i)),o!=null&&(o=String(o),this._names.has(o)||this._names.add(o)),this._mappings.add({generatedLine:r.line,generatedColumn:r.column,originalLine:n!=null&&n.line,originalColumn:n!=null&&n.column,source:i,name:o})};Qe.prototype.setSourceContent=function(e,r){var n=e;this._sourceRoot!=null&&(n=ve.relative(this._sourceRoot,n)),r!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[ve.toSetString(n)]=r):this._sourcesContents&&(delete this._sourcesContents[ve.toSetString(n)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};Qe.prototype.applySourceMap=function(e,r,n){var i=r;if(r==null){if(e.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);i=e.file}var o=this._sourceRoot;o!=null&&(i=ve.relative(o,i));var s=new ts,a=new ts;this._mappings.unsortedForEach(function(l){if(l.source===i&&l.originalLine!=null){var u=e.originalPositionFor({line:l.originalLine,column:l.originalColumn});u.source!=null&&(l.source=u.source,n!=null&&(l.source=ve.join(n,l.source)),o!=null&&(l.source=ve.relative(o,l.source)),l.originalLine=u.line,l.originalColumn=u.column,u.name!=null&&(l.name=u.name))}var p=l.source;p!=null&&!s.has(p)&&s.add(p);var f=l.name;f!=null&&!a.has(f)&&a.add(f)},this),this._sources=s,this._names=a,e.sources.forEach(function(l){var u=e.sourceContentFor(l);u!=null&&(n!=null&&(l=ve.join(n,l)),o!=null&&(l=ve.relative(o,l)),this.setSourceContent(l,u))},this)};Qe.prototype._validateMapping=function(e,r,n,i){if(r&&typeof r.line!="number"&&typeof r.column!="number")throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if(!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0&&!r&&!n&&!i)){if(e&&"line"in e&&"column"in e&&r&&"line"in r&&"column"in r&&e.line>0&&e.column>=0&&r.line>0&&r.column>=0&&n)return;throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:r,name:i}))}};Qe.prototype._serializeMappings=function(){for(var e=0,r=1,n=0,i=0,o=0,s=0,a="",l,u,p,f,h=this._mappings.toArray(),m=0,g=h.length;m<g;m++){if(u=h[m],l="",u.generatedLine!==r)for(e=0;u.generatedLine!==r;)l+=";",r++;else if(m>0){if(!ve.compareByGeneratedPositionsInflated(u,h[m-1]))continue;l+=","}l+=ui.encode(u.generatedColumn-e),e=u.generatedColumn,u.source!=null&&(f=this._sources.indexOf(u.source),l+=ui.encode(f-s),s=f,l+=ui.encode(u.originalLine-1-i),i=u.originalLine-1,l+=ui.encode(u.originalColumn-n),n=u.originalColumn,u.name!=null&&(p=this._names.indexOf(u.name),l+=ui.encode(p-o),o=p)),a+=l}return a};Qe.prototype._generateSourcesContent=function(e,r){return e.map(function(n){if(!this._sourcesContents)return null;r!=null&&(n=ve.relative(r,n));var i=ve.toSetString(n);return Object.prototype.hasOwnProperty.call(this._sourcesContents,i)?this._sourcesContents[i]:null},this)};Qe.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(e.file=this._file),this._sourceRoot!=null&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e};Qe.prototype.toString=function(){return JSON.stringify(this.toJSON())};gg.SourceMapGenerator=Qe});var yg=w(gr=>{gr.GREATEST_LOWER_BOUND=1;gr.LEAST_UPPER_BOUND=2;function Jl(t,e,r,n,i,o){var s=Math.floor((e-t)/2)+t,a=i(r,n[s],!0);return a===0?s:a>0?e-s>1?Jl(s,e,r,n,i,o):o==gr.LEAST_UPPER_BOUND?e<n.length?e:-1:s:s-t>1?Jl(t,s,r,n,i,o):o==gr.LEAST_UPPER_BOUND?s:t<0?-1:t}gr.search=function(e,r,n,i){if(r.length===0)return-1;var o=Jl(-1,r.length,e,r,n,i||gr.GREATEST_LOWER_BOUND);if(o<0)return-1;for(;o-1>=0&&n(r[o],r[o-1],!0)===0;)--o;return o}});var _g=w(vg=>{function Yl(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function Ex(t,e){return Math.round(t+Math.random()*(e-t))}function Xl(t,e,r,n){if(r<n){var i=Ex(r,n),o=r-1;Yl(t,i,n);for(var s=t[n],a=r;a<n;a++)e(t[a],s)<=0&&(o+=1,Yl(t,o,a));Yl(t,o+1,a);var l=o+1;Xl(t,e,r,l-1),Xl(t,e,l+1,n)}}vg.quickSort=function(t,e){Xl(t,e,0,t.length-1)}});var bg=w(rs=>{var D=Yr(),Ql=yg(),Xr=zl().ArraySet,$x=Bl(),fi=_g().quickSort;function pe(t,e){var r=t;return typeof t=="string"&&(r=D.parseSourceMapInput(t)),r.sections!=null?new ut(r,e):new $e(r,e)}pe.fromSourceMap=function(t,e){return $e.fromSourceMap(t,e)};pe.prototype._version=3;pe.prototype.__generatedMappings=null;Object.defineProperty(pe.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});pe.prototype.__originalMappings=null;Object.defineProperty(pe.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});pe.prototype._charIsMappingSeparator=function(e,r){var n=e.charAt(r);return n===";"||n===","};pe.prototype._parseMappings=function(e,r){throw new Error("Subclasses must implement _parseMappings")};pe.GENERATED_ORDER=1;pe.ORIGINAL_ORDER=2;pe.GREATEST_LOWER_BOUND=1;pe.LEAST_UPPER_BOUND=2;pe.prototype.eachMapping=function(e,r,n){var i=r||null,o=n||pe.GENERATED_ORDER,s;switch(o){case pe.GENERATED_ORDER:s=this._generatedMappings;break;case pe.ORIGINAL_ORDER:s=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}var a=this.sourceRoot;s.map(function(l){var u=l.source===null?null:this._sources.at(l.source);return u=D.computeSourceURL(a,u,this._sourceMapURL),{source:u,generatedLine:l.generatedLine,generatedColumn:l.generatedColumn,originalLine:l.originalLine,originalColumn:l.originalColumn,name:l.name===null?null:this._names.at(l.name)}},this).forEach(e,i)};pe.prototype.allGeneratedPositionsFor=function(e){var r=D.getArg(e,"line"),n={source:D.getArg(e,"source"),originalLine:r,originalColumn:D.getArg(e,"column",0)};if(n.source=this._findSourceIndex(n.source),n.source<0)return[];var i=[],o=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",D.compareByOriginalPositions,Ql.LEAST_UPPER_BOUND);if(o>=0){var s=this._originalMappings[o];if(e.column===void 0)for(var a=s.originalLine;s&&s.originalLine===a;)i.push({line:D.getArg(s,"generatedLine",null),column:D.getArg(s,"generatedColumn",null),lastColumn:D.getArg(s,"lastGeneratedColumn",null)}),s=this._originalMappings[++o];else for(var l=s.originalColumn;s&&s.originalLine===r&&s.originalColumn==l;)i.push({line:D.getArg(s,"generatedLine",null),column:D.getArg(s,"generatedColumn",null),lastColumn:D.getArg(s,"lastGeneratedColumn",null)}),s=this._originalMappings[++o]}return i};rs.SourceMapConsumer=pe;function $e(t,e){var r=t;typeof t=="string"&&(r=D.parseSourceMapInput(t));var n=D.getArg(r,"version"),i=D.getArg(r,"sources"),o=D.getArg(r,"names",[]),s=D.getArg(r,"sourceRoot",null),a=D.getArg(r,"sourcesContent",null),l=D.getArg(r,"mappings"),u=D.getArg(r,"file",null);if(n!=this._version)throw new Error("Unsupported version: "+n);s&&(s=D.normalize(s)),i=i.map(String).map(D.normalize).map(function(p){return s&&D.isAbsolute(s)&&D.isAbsolute(p)?D.relative(s,p):p}),this._names=Xr.fromArray(o.map(String),!0),this._sources=Xr.fromArray(i,!0),this._absoluteSources=this._sources.toArray().map(function(p){return D.computeSourceURL(s,p,e)}),this.sourceRoot=s,this.sourcesContent=a,this._mappings=l,this._sourceMapURL=e,this.file=u}$e.prototype=Object.create(pe.prototype);$e.prototype.consumer=pe;$e.prototype._findSourceIndex=function(t){var e=t;if(this.sourceRoot!=null&&(e=D.relative(this.sourceRoot,e)),this._sources.has(e))return this._sources.indexOf(e);var r;for(r=0;r<this._absoluteSources.length;++r)if(this._absoluteSources[r]==t)return r;return-1};$e.fromSourceMap=function(e,r){var n=Object.create($e.prototype),i=n._names=Xr.fromArray(e._names.toArray(),!0),o=n._sources=Xr.fromArray(e._sources.toArray(),!0);n.sourceRoot=e._sourceRoot,n.sourcesContent=e._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=e._file,n._sourceMapURL=r,n._absoluteSources=n._sources.toArray().map(function(m){return D.computeSourceURL(n.sourceRoot,m,r)});for(var s=e._mappings.toArray().slice(),a=n.__generatedMappings=[],l=n.__originalMappings=[],u=0,p=s.length;u<p;u++){var f=s[u],h=new wg;h.generatedLine=f.generatedLine,h.generatedColumn=f.generatedColumn,f.source&&(h.source=o.indexOf(f.source),h.originalLine=f.originalLine,h.originalColumn=f.originalColumn,f.name&&(h.name=i.indexOf(f.name)),l.push(h)),a.push(h)}return fi(n.__originalMappings,D.compareByOriginalPositions),n};$e.prototype._version=3;Object.defineProperty($e.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function wg(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}$e.prototype._parseMappings=function(e,r){for(var n=1,i=0,o=0,s=0,a=0,l=0,u=e.length,p=0,f={},h={},m=[],g=[],v,P,b,j,B;p<u;)if(e.charAt(p)===";")n++,p++,i=0;else if(e.charAt(p)===",")p++;else{for(v=new wg,v.generatedLine=n,j=p;j<u&&!this._charIsMappingSeparator(e,j);j++);if(P=e.slice(p,j),b=f[P],b)p+=P.length;else{for(b=[];p<j;)$x.decode(e,p,h),B=h.value,p=h.rest,b.push(B);if(b.length===2)throw new Error("Found a source, but no line and column");if(b.length===3)throw new Error("Found a source and line, but no column");f[P]=b}v.generatedColumn=i+b[0],i=v.generatedColumn,b.length>1&&(v.source=a+b[1],a+=b[1],v.originalLine=o+b[2],o=v.originalLine,v.originalLine+=1,v.originalColumn=s+b[3],s=v.originalColumn,b.length>4&&(v.name=l+b[4],l+=b[4])),g.push(v),typeof v.originalLine=="number"&&m.push(v)}fi(g,D.compareByGeneratedPositionsDeflated),this.__generatedMappings=g,fi(m,D.compareByOriginalPositions),this.__originalMappings=m};$e.prototype._findMapping=function(e,r,n,i,o,s){if(e[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[n]);if(e[i]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[i]);return Ql.search(e,r,o,s)};$e.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var r=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var n=this._generatedMappings[e+1];if(r.generatedLine===n.generatedLine){r.lastGeneratedColumn=n.generatedColumn-1;continue}}r.lastGeneratedColumn=1/0}};$e.prototype.originalPositionFor=function(e){var r={generatedLine:D.getArg(e,"line"),generatedColumn:D.getArg(e,"column")},n=this._findMapping(r,this._generatedMappings,"generatedLine","generatedColumn",D.compareByGeneratedPositionsDeflated,D.getArg(e,"bias",pe.GREATEST_LOWER_BOUND));if(n>=0){var i=this._generatedMappings[n];if(i.generatedLine===r.generatedLine){var o=D.getArg(i,"source",null);o!==null&&(o=this._sources.at(o),o=D.computeSourceURL(this.sourceRoot,o,this._sourceMapURL));var s=D.getArg(i,"name",null);return s!==null&&(s=this._names.at(s)),{source:o,line:D.getArg(i,"originalLine",null),column:D.getArg(i,"originalColumn",null),name:s}}}return{source:null,line:null,column:null,name:null}};$e.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return e==null}):!1};$e.prototype.sourceContentFor=function(e,r){if(!this.sourcesContent)return null;var n=this._findSourceIndex(e);if(n>=0)return this.sourcesContent[n];var i=e;this.sourceRoot!=null&&(i=D.relative(this.sourceRoot,i));var o;if(this.sourceRoot!=null&&(o=D.urlParse(this.sourceRoot))){var s=i.replace(/^file:\/\//,"");if(o.scheme=="file"&&this._sources.has(s))return this.sourcesContent[this._sources.indexOf(s)];if((!o.path||o.path=="/")&&this._sources.has("/"+i))return this.sourcesContent[this._sources.indexOf("/"+i)]}if(r)return null;throw new Error('"'+i+'" is not in the SourceMap.')};$e.prototype.generatedPositionFor=function(e){var r=D.getArg(e,"source");if(r=this._findSourceIndex(r),r<0)return{line:null,column:null,lastColumn:null};var n={source:r,originalLine:D.getArg(e,"line"),originalColumn:D.getArg(e,"column")},i=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",D.compareByOriginalPositions,D.getArg(e,"bias",pe.GREATEST_LOWER_BOUND));if(i>=0){var o=this._originalMappings[i];if(o.source===n.source)return{line:D.getArg(o,"generatedLine",null),column:D.getArg(o,"generatedColumn",null),lastColumn:D.getArg(o,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};rs.BasicSourceMapConsumer=$e;function ut(t,e){var r=t;typeof t=="string"&&(r=D.parseSourceMapInput(t));var n=D.getArg(r,"version"),i=D.getArg(r,"sections");if(n!=this._version)throw new Error("Unsupported version: "+n);this._sources=new Xr,this._names=new Xr;var o={line:-1,column:0};this._sections=i.map(function(s){if(s.url)throw new Error("Support for url field in sections not implemented.");var a=D.getArg(s,"offset"),l=D.getArg(a,"line"),u=D.getArg(a,"column");if(l<o.line||l===o.line&&u<o.column)throw new Error("Section offsets must be ordered and non-overlapping.");return o=a,{generatedOffset:{generatedLine:l+1,generatedColumn:u+1},consumer:new pe(D.getArg(s,"map"),e)}})}ut.prototype=Object.create(pe.prototype);ut.prototype.constructor=pe;ut.prototype._version=3;Object.defineProperty(ut.prototype,"sources",{get:function(){for(var t=[],e=0;e<this._sections.length;e++)for(var r=0;r<this._sections[e].consumer.sources.length;r++)t.push(this._sections[e].consumer.sources[r]);return t}});ut.prototype.originalPositionFor=function(e){var r={generatedLine:D.getArg(e,"line"),generatedColumn:D.getArg(e,"column")},n=Ql.search(r,this._sections,function(o,s){var a=o.generatedLine-s.generatedOffset.generatedLine;return a||o.generatedColumn-s.generatedOffset.generatedColumn}),i=this._sections[n];return i?i.consumer.originalPositionFor({line:r.generatedLine-(i.generatedOffset.generatedLine-1),column:r.generatedColumn-(i.generatedOffset.generatedLine===r.generatedLine?i.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}};ut.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})};ut.prototype.sourceContentFor=function(e,r){for(var n=0;n<this._sections.length;n++){var i=this._sections[n],o=i.consumer.sourceContentFor(e,!0);if(o)return o}if(r)return null;throw new Error('"'+e+'" is not in the SourceMap.')};ut.prototype.generatedPositionFor=function(e){for(var r=0;r<this._sections.length;r++){var n=this._sections[r];if(n.consumer._findSourceIndex(D.getArg(e,"source"))!==-1){var i=n.consumer.generatedPositionFor(e);if(i){var o={line:i.line+(n.generatedOffset.generatedLine-1),column:i.column+(n.generatedOffset.generatedLine===i.line?n.generatedOffset.generatedColumn-1:0)};return o}}}return{line:null,column:null}};ut.prototype._parseMappings=function(e,r){this.__generatedMappings=[],this.__originalMappings=[];for(var n=0;n<this._sections.length;n++)for(var i=this._sections[n],o=i.consumer._generatedMappings,s=0;s<o.length;s++){var a=o[s],l=i.consumer._sources.at(a.source);l=D.computeSourceURL(i.consumer.sourceRoot,l,this._sourceMapURL),this._sources.add(l),l=this._sources.indexOf(l);var u=null;a.name&&(u=i.consumer._names.at(a.name),this._names.add(u),u=this._names.indexOf(u));var p={source:l,generatedLine:a.generatedLine+(i.generatedOffset.generatedLine-1),generatedColumn:a.generatedColumn+(i.generatedOffset.generatedLine===a.generatedLine?i.generatedOffset.generatedColumn-1:0),originalLine:a.originalLine,originalColumn:a.originalColumn,name:u};this.__generatedMappings.push(p),typeof p.originalLine=="number"&&this.__originalMappings.push(p)}fi(this.__generatedMappings,D.compareByGeneratedPositionsDeflated),fi(this.__originalMappings,D.compareByOriginalPositions)};rs.IndexedSourceMapConsumer=ut});var Eg=w(Sg=>{var xx=Kl().SourceMapGenerator,ns=Yr(),Cx=/(\r?\n)/,Px=10,Qr="$$$isSourceNode$$$";function He(t,e,r,n,i){this.children=[],this.sourceContents={},this.line=t??null,this.column=e??null,this.source=r??null,this.name=i??null,this[Qr]=!0,n!=null&&this.add(n)}He.fromStringWithSourceMap=function(e,r,n){var i=new He,o=e.split(Cx),s=0,a=function(){var h=g(),m=g()||"";return h+m;function g(){return s<o.length?o[s++]:void 0}},l=1,u=0,p=null;return r.eachMapping(function(h){if(p!==null)if(l<h.generatedLine)f(p,a()),l++,u=0;else{var m=o[s]||"",g=m.substr(0,h.generatedColumn-u);o[s]=m.substr(h.generatedColumn-u),u=h.generatedColumn,f(p,g),p=h;return}for(;l<h.generatedLine;)i.add(a()),l++;if(u<h.generatedColumn){var m=o[s]||"";i.add(m.substr(0,h.generatedColumn)),o[s]=m.substr(h.generatedColumn),u=h.generatedColumn}p=h},this),s<o.length&&(p&&f(p,a()),i.add(o.splice(s).join(""))),r.sources.forEach(function(h){var m=r.sourceContentFor(h);m!=null&&(n!=null&&(h=ns.join(n,h)),i.setSourceContent(h,m))}),i;function f(h,m){if(h===null||h.source===void 0)i.add(m);else{var g=n?ns.join(n,h.source):h.source;i.add(new He(h.originalLine,h.originalColumn,g,m,h.name))}}};He.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(r){this.add(r)},this);else if(e[Qr]||typeof e=="string")e&&this.children.push(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};He.prototype.prepend=function(e){if(Array.isArray(e))for(var r=e.length-1;r>=0;r--)this.prepend(e[r]);else if(e[Qr]||typeof e=="string")this.children.unshift(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};He.prototype.walk=function(e){for(var r,n=0,i=this.children.length;n<i;n++)r=this.children[n],r[Qr]?r.walk(e):r!==""&&e(r,{source:this.source,line:this.line,column:this.column,name:this.name})};He.prototype.join=function(e){var r,n,i=this.children.length;if(i>0){for(r=[],n=0;n<i-1;n++)r.push(this.children[n]),r.push(e);r.push(this.children[n]),this.children=r}return this};He.prototype.replaceRight=function(e,r){var n=this.children[this.children.length-1];return n[Qr]?n.replaceRight(e,r):typeof n=="string"?this.children[this.children.length-1]=n.replace(e,r):this.children.push("".replace(e,r)),this};He.prototype.setSourceContent=function(e,r){this.sourceContents[ns.toSetString(e)]=r};He.prototype.walkSourceContents=function(e){for(var r=0,n=this.children.length;r<n;r++)this.children[r][Qr]&&this.children[r].walkSourceContents(e);for(var i=Object.keys(this.sourceContents),r=0,n=i.length;r<n;r++)e(ns.fromSetString(i[r]),this.sourceContents[i[r]])};He.prototype.toString=function(){var e="";return this.walk(function(r){e+=r}),e};He.prototype.toStringWithSourceMap=function(e){var r={code:"",line:1,column:0},n=new xx(e),i=!1,o=null,s=null,a=null,l=null;return this.walk(function(u,p){r.code+=u,p.source!==null&&p.line!==null&&p.column!==null?((o!==p.source||s!==p.line||a!==p.column||l!==p.name)&&n.addMapping({source:p.source,original:{line:p.line,column:p.column},generated:{line:r.line,column:r.column},name:p.name}),o=p.source,s=p.line,a=p.column,l=p.name,i=!0):i&&(n.addMapping({generated:{line:r.line,column:r.column}}),o=null,i=!1);for(var f=0,h=u.length;f<h;f++)u.charCodeAt(f)===Px?(r.line++,r.column=0,f+1===h?(o=null,i=!1):i&&n.addMapping({source:p.source,original:{line:p.line,column:p.column},generated:{line:r.line,column:r.column},name:p.name})):r.column++}),this.walkSourceContents(function(u,p){n.setSourceContent(u,p)}),{code:r.code,map:n}};Sg.SourceNode=He});var $g=w(is=>{is.SourceMapGenerator=Kl().SourceMapGenerator;is.SourceMapConsumer=bg().SourceMapConsumer;is.SourceNode=Eg().SourceNode});var kg=w((os,Pg)=>{"use strict";os.__esModule=!0;var eu=Te(),yr=void 0;try{(typeof define!="function"||!define.amd)&&(xg=$g(),yr=xg.SourceNode)}catch{}var xg;yr||(yr=function(t,e,r,n){this.src="",n&&this.add(n)},yr.prototype={add:function(e){eu.isArray(e)&&(e=e.join("")),this.src+=e},prepend:function(e){eu.isArray(e)&&(e=e.join("")),this.src=e+this.src},toStringWithSourceMap:function(){return{code:this.toString()}},toString:function(){return this.src}});function Zl(t,e,r){if(eu.isArray(t)){for(var n=[],i=0,o=t.length;i<o;i++)n.push(e.wrap(t[i],r));return n}else if(typeof t=="boolean"||typeof t=="number")return t+"";return t}function Cg(t){this.srcFile=t,this.source=[]}Cg.prototype={isEmpty:function(){return!this.source.length},prepend:function(e,r){this.source.unshift(this.wrap(e,r))},push:function(e,r){this.source.push(this.wrap(e,r))},merge:function(){var e=this.empty();return this.each(function(r){e.add([" ",r,`
|
|
45
|
+
`])}),e},each:function(e){for(var r=0,n=this.source.length;r<n;r++)e(this.source[r])},empty:function(){var e=this.currentLocation||{start:{}};return new yr(e.start.line,e.start.column,this.srcFile)},wrap:function(e){var r=arguments.length<=1||arguments[1]===void 0?this.currentLocation||{start:{}}:arguments[1];return e instanceof yr?e:(e=Zl(e,this,r),new yr(r.start.line,r.start.column,this.srcFile,e))},functionCall:function(e,r,n){return n=this.generateList(n),this.wrap([e,r?"."+r+"(":"(",n,")"])},quotedString:function(e){return'"'+(e+"").replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")+'"'},objectLiteral:function(e){var r=this,n=[];Object.keys(e).forEach(function(o){var s=Zl(e[o],r);s!=="undefined"&&n.push([r.quotedString(o),":",s])});var i=this.generateList(n);return i.prepend("{"),i.add("}"),i},generateList:function(e){for(var r=this.empty(),n=0,i=e.length;n<i;n++)n&&r.add(","),r.add(Zl(e[n],this));return r},generateArray:function(e){var r=this.generateList(e);return r.prepend("["),r.add("]"),r}};os.default=Cg;Pg.exports=os.default});var Tg=w((ss,Ig)=>{"use strict";ss.__esModule=!0;function Rg(t){return t&&t.__esModule?t:{default:t}}var Ag=qo(),kx=Fe(),tu=Rg(kx),Ax=Te(),Ox=kg(),Og=Rg(Ox);function Zr(t){this.value=t}function en(){}en.prototype={nameLookup:function(e,r){return this.internalNameLookup(e,r)},depthedLookup:function(e){return[this.aliasable("container.lookup"),"(depths, ",JSON.stringify(e),")"]},compilerInfo:function(){var e=Ag.COMPILER_REVISION,r=Ag.REVISION_CHANGES[e];return[e,r]},appendToBuffer:function(e,r,n){return Ax.isArray(e)||(e=[e]),e=this.source.wrap(e,r),this.environment.isSimple?["return ",e,";"]:n?["buffer += ",e,";"]:(e.appendToBuffer=!0,e)},initializeBuffer:function(){return this.quotedString("")},internalNameLookup:function(e,r){return this.lookupPropertyFunctionIsUsed=!0,["lookupProperty(",e,",",JSON.stringify(r),")"]},lookupPropertyFunctionIsUsed:!1,compile:function(e,r,n,i){this.environment=e,this.options=r,this.stringParams=this.options.stringParams,this.trackIds=this.options.trackIds,this.precompile=!i,this.name=this.environment.name,this.isChild=!!n,this.context=n||{decorators:[],programs:[],environments:[]},this.preamble(),this.stackSlot=0,this.stackVars=[],this.aliases={},this.registers={list:[]},this.hashes=[],this.compileStack=[],this.inlineStack=[],this.blockParams=[],this.compileChildren(e,r),this.useDepths=this.useDepths||e.useDepths||e.useDecorators||this.options.compat,this.useBlockParams=this.useBlockParams||e.useBlockParams;var o=e.opcodes,s=void 0,a=void 0,l=void 0,u=void 0;for(l=0,u=o.length;l<u;l++)s=o[l],this.source.currentLocation=s.loc,a=a||s.loc,this[s.opcode].apply(this,s.args);if(this.source.currentLocation=a,this.pushSource(""),this.stackSlot||this.inlineStack.length||this.compileStack.length)throw new tu.default("Compile completed with content left on stack");this.decorators.isEmpty()?this.decorators=void 0:(this.useDecorators=!0,this.decorators.prepend(["var decorators = container.decorators, ",this.lookupPropertyFunctionVarDeclaration(),`;
|
|
46
46
|
`]),this.decorators.push("return fn;"),i?this.decorators=Function.apply(this,["fn","props","container","depth0","data","blockParams","depths",this.decorators.merge()]):(this.decorators.prepend(`function(fn, props, container, depth0, data, blockParams, depths) {
|
|
47
47
|
`),this.decorators.push(`}
|
|
48
|
-
`),this.decorators=this.decorators.merge()));var
|
|
49
|
-
`,a,"}"])},mergeSource:function(e){var r=this.environment.isSimple,n=!this.forceBuffer,i=void 0,
|
|
48
|
+
`),this.decorators=this.decorators.merge()));var p=this.createFunctionContext(i);if(this.isChild)return p;var f={compiler:this.compilerInfo(),main:p};this.decorators&&(f.main_d=this.decorators,f.useDecorators=!0);var h=this.context,m=h.programs,g=h.decorators;for(l=0,u=m.length;l<u;l++)f[l]=m[l],g[l]&&(f[l+"_d"]=g[l],f.useDecorators=!0);return this.environment.usePartial&&(f.usePartial=!0),this.options.data&&(f.useData=!0),this.useDepths&&(f.useDepths=!0),this.useBlockParams&&(f.useBlockParams=!0),this.options.compat&&(f.compat=!0),i?f.compilerOptions=this.options:(f.compiler=JSON.stringify(f.compiler),this.source.currentLocation={start:{line:1,column:0}},f=this.objectLiteral(f),r.srcName?(f=f.toStringWithSourceMap({file:r.destName}),f.map=f.map&&f.map.toString()):f=f.toString()),f},preamble:function(){this.lastContext=0,this.source=new Og.default(this.options.srcName),this.decorators=new Og.default(this.options.srcName)},createFunctionContext:function(e){var r=this,n="",i=this.stackVars.concat(this.registers.list);i.length>0&&(n+=", "+i.join(", "));var o=0;Object.keys(this.aliases).forEach(function(l){var u=r.aliases[l];u.children&&u.referenceCount>1&&(n+=", alias"+ ++o+"="+l,u.children[0]="alias"+o)}),this.lookupPropertyFunctionIsUsed&&(n+=", "+this.lookupPropertyFunctionVarDeclaration());var s=["container","depth0","helpers","partials","data"];(this.useBlockParams||this.useDepths)&&s.push("blockParams"),this.useDepths&&s.push("depths");var a=this.mergeSource(n);return e?(s.push(a),Function.apply(this,s)):this.source.wrap(["function(",s.join(","),`) {
|
|
49
|
+
`,a,"}"])},mergeSource:function(e){var r=this.environment.isSimple,n=!this.forceBuffer,i=void 0,o=void 0,s=void 0,a=void 0;return this.source.each(function(l){l.appendToBuffer?(s?l.prepend(" + "):s=l,a=l):(s&&(o?s.prepend("buffer += "):i=!0,a.add(";"),s=a=void 0),o=!0,r||(n=!1))}),n?s?(s.prepend("return "),a.add(";")):o||this.source.push('return "";'):(e+=", buffer = "+(i?"":this.initializeBuffer()),s?(s.prepend("return buffer + "),a.add(";")):this.source.push("return buffer;")),e&&this.source.prepend("var "+e.substring(2)+(i?"":`;
|
|
50
50
|
`)),this.source.merge()},lookupPropertyFunctionVarDeclaration:function(){return`
|
|
51
51
|
lookupProperty = container.lookupProperty || function(parent, propertyName) {
|
|
52
52
|
if (Object.prototype.hasOwnProperty.call(parent, propertyName)) {
|
|
@@ -54,13 +54,13 @@ Expecting `+st.join(", ")+", got '"+(this.terminals_[j]||j)+"'":bt="Parse error
|
|
|
54
54
|
}
|
|
55
55
|
return undefined
|
|
56
56
|
}
|
|
57
|
-
`.trim()},blockValue:function(e){var r=this.aliasable("container.hooks.blockHelperMissing"),n=[this.contextName(0)];this.setupHelperArgs(e,0,n);var i=this.popStack();n.splice(1,0,i),this.push(this.source.functionCall(r,"call",n))},ambiguousBlockValue:function(){var e=this.aliasable("container.hooks.blockHelperMissing"),r=[this.contextName(0)];this.setupHelperArgs("",0,r,!0),this.flushInline();var n=this.topStack();r.splice(1,0,n),this.pushSource(["if (!",this.lastHelper,") { ",n," = ",this.source.functionCall(e,"call",r),"}"])},appendContent:function(e){this.pendingContent?e=this.pendingContent+e:this.pendingLocation=this.source.currentLocation,this.pendingContent=e},append:function(){if(this.isInline())this.replaceStack(function(r){return[" != null ? ",r,' : ""']}),this.pushSource(this.appendToBuffer(this.popStack()));else{var e=this.popStack();this.pushSource(["if (",e," != null) { ",this.appendToBuffer(e,void 0,!0)," }"]),this.environment.isSimple&&this.pushSource(["else { ",this.appendToBuffer("''",void 0,!0)," }"])}},appendEscaped:function(){this.pushSource(this.appendToBuffer([this.aliasable("container.escapeExpression"),"(",this.popStack(),")"]))},getContext:function(e){this.lastContext=e},pushContext:function(){this.pushStackLiteral(this.contextName(this.lastContext))},lookupOnContext:function(e,r,n,i){var s=0;!i&&this.options.compat&&!this.lastContext?this.push(this.depthedLookup(e[s++])):this.pushContext(),this.resolvePath("context",e,s,r,n)},lookupBlockParam:function(e,r){this.useBlockParams=!0,this.push(["blockParams[",e[0],"][",e[1],"]"]),this.resolvePath("context",r,1)},lookupData:function(e,r,n){e?this.pushStackLiteral("container.data(data, "+e+")"):this.pushStackLiteral("data"),this.resolvePath("data",r,0,!0,n)},resolvePath:function(e,r,n,i,s){var o=this;if(this.options.strict||this.options.assumeObjects){this.push(H$(this.options.strict&&s,this,r,n,e));return}for(var a=r.length,l=function(d){o.replaceStack(function(f){var h=o.nameLookup(f,r[d],e);return i?[" && ",h]:[" != null ? ",h," : ",f]})},u=n;u<a;u++)l(u)},resolvePossibleLambda:function(){this.push([this.aliasable("container.lambda"),"(",this.popStack(),", ",this.contextName(0),")"])},pushStringParam:function(e,r){this.pushContext(),this.pushString(r),r!=="SubExpression"&&(typeof e=="string"?this.pushString(e):this.pushStackLiteral(e))},emptyHash:function(e){this.trackIds&&this.push("{}"),this.stringParams&&(this.push("{}"),this.push("{}")),this.pushStackLiteral(e?"undefined":"{}")},pushHash:function(){this.hash&&this.hashes.push(this.hash),this.hash={values:{},types:[],contexts:[],ids:[]}},popHash:function(){var e=this.hash;this.hash=this.hashes.pop(),this.trackIds&&this.push(this.objectLiteral(e.ids)),this.stringParams&&(this.push(this.objectLiteral(e.contexts)),this.push(this.objectLiteral(e.types))),this.push(this.objectLiteral(e.values))},pushString:function(e){this.pushStackLiteral(this.quotedString(e))},pushLiteral:function(e){this.pushStackLiteral(e)},pushProgram:function(e){e!=null?this.pushStackLiteral(this.programExpression(e)):this.pushStackLiteral(null)},registerDecorator:function(e,r){var n=this.nameLookup("decorators",r,"decorator"),i=this.setupHelperArgs(r,e);this.decorators.push(["var decorator = ",n,";"]),this.decorators.push(['if (typeof decorator !== "function") { throw new Error(',this.quotedString('Missing decorator: "'+r+'"'),"); }"]),this.decorators.push(["fn = ",this.decorators.functionCall("decorator","",["fn","props","container",i])," || fn;"])},invokeHelper:function(e,r,n){var i=this.popStack(),s=this.setupHelper(e,r),o=[];n&&o.push(s.name),o.push(i),this.options.strict||o.push(this.aliasable("container.hooks.helperMissing"));var a=["(",this.itemsSeparatedBy(o,"||"),")"],l=this.source.functionCall(a,"call",s.callParams);this.push(l)},itemsSeparatedBy:function(e,r){var n=[];n.push(e[0]);for(var i=1;i<e.length;i++)n.push(r,e[i]);return n},invokeKnownHelper:function(e,r){var n=this.setupHelper(e,r);this.push(this.source.functionCall(n.name,"call",n.callParams))},invokeAmbiguous:function(e,r){this.useRegister("helper");var n=this.popStack();this.emptyHash();var i=this.setupHelper(0,e,r),s=this.lastHelper=this.nameLookup("helpers",e,"helper"),o=["(","(helper = ",s," || ",n,")"];this.options.strict||(o[0]="(helper = ",o.push(" != null ? helper : ",this.aliasable("container.hooks.helperMissing"))),this.push(["(",o,i.paramsInit?["),(",i.paramsInit]:[],"),","(typeof helper === ",this.aliasable('"function"')," ? ",this.source.functionCall("helper","call",i.callParams)," : helper))"])},invokePartial:function(e,r,n){var i=[],s=this.setupParams(r,1,i);e&&(r=this.popStack(),delete s.name),n&&(s.indent=JSON.stringify(n)),s.helpers="helpers",s.partials="partials",s.decorators="container.decorators",e?i.unshift(r):i.unshift(this.nameLookup("partials",r,"partial")),this.options.compat&&(s.depths="depths"),s=this.objectLiteral(s),i.push(s),this.push(this.source.functionCall("container.invokePartial","",i))},assignToHash:function(e){var r=this.popStack(),n=void 0,i=void 0,s=void 0;this.trackIds&&(s=this.popStack()),this.stringParams&&(i=this.popStack(),n=this.popStack());var o=this.hash;n&&(o.contexts[e]=n),i&&(o.types[e]=i),s&&(o.ids[e]=s),o.values[e]=r},pushId:function(e,r,n){e==="BlockParam"?this.pushStackLiteral("blockParams["+r[0]+"].path["+r[1]+"]"+(n?" + "+JSON.stringify("."+n):"")):e==="PathExpression"?this.pushString(r):e==="SubExpression"?this.pushStackLiteral("true"):this.pushStackLiteral("null")},compiler:Xr,compileChildren:function(e,r){for(var n=e.children,i=void 0,s=void 0,o=0,a=n.length;o<a;o++){i=n[o],s=new this.compiler;var l=this.matchExistingProgram(i);if(l==null){var u=this.context.programs.push("")-1;i.index=u,i.name="program"+u,this.context.programs[u]=s.compile(i,r,this.context,!this.precompile),this.context.decorators[u]=s.decorators,this.context.environments[u]=i,this.useDepths=this.useDepths||s.useDepths,this.useBlockParams=this.useBlockParams||s.useBlockParams,i.useDepths=this.useDepths,i.useBlockParams=this.useBlockParams}else i.index=l.index,i.name="program"+l.index,this.useDepths=this.useDepths||l.useDepths,this.useBlockParams=this.useBlockParams||l.useBlockParams}},matchExistingProgram:function(e){for(var r=0,n=this.context.environments.length;r<n;r++){var i=this.context.environments[r];if(i&&i.equals(e))return i}},programExpression:function(e){var r=this.environment.children[e],n=[r.index,"data",r.blockParams];return(this.useBlockParams||this.useDepths)&&n.push("blockParams"),this.useDepths&&n.push("depths"),"container.program("+n.join(", ")+")"},useRegister:function(e){this.registers[e]||(this.registers[e]=!0,this.registers.list.push(e))},push:function(e){return e instanceof Yr||(e=this.source.wrap(e)),this.inlineStack.push(e),e},pushStackLiteral:function(e){this.push(new Yr(e))},pushSource:function(e){this.pendingContent&&(this.source.push(this.appendToBuffer(this.source.quotedString(this.pendingContent),this.pendingLocation)),this.pendingContent=void 0),e&&this.source.push(e)},replaceStack:function(e){var r=["("],n=void 0,i=void 0,s=void 0;if(!this.isInline())throw new Tl.default("replaceStack on non-inline");var o=this.popStack(!0);if(o instanceof Yr)n=[o.value],r=["(",n],s=!0;else{i=!0;var a=this.incrStack();r=["((",this.push(a)," = ",o,")"],n=this.topStack()}var l=e.call(this,n);s||this.popStack(),i&&this.stackSlot--,this.push(r.concat(l,")"))},incrStack:function(){return this.stackSlot++,this.stackSlot>this.stackVars.length&&this.stackVars.push("stack"+this.stackSlot),this.topStackName()},topStackName:function(){return"stack"+this.stackSlot},flushInline:function(){var e=this.inlineStack;this.inlineStack=[];for(var r=0,n=e.length;r<n;r++){var i=e[r];if(i instanceof Yr)this.compileStack.push(i);else{var s=this.incrStack();this.pushSource([s," = ",i,";"]),this.compileStack.push(s)}}},isInline:function(){return this.inlineStack.length},popStack:function(e){var r=this.isInline(),n=(r?this.inlineStack:this.compileStack).pop();if(!e&&n instanceof Yr)return n.value;if(!r){if(!this.stackSlot)throw new Tl.default("Invalid stack pop");this.stackSlot--}return n},topStack:function(){var e=this.isInline()?this.inlineStack:this.compileStack,r=e[e.length-1];return r instanceof Yr?r.value:r},contextName:function(e){return this.useDepths&&e?"depths["+e+"]":"depth"+e},quotedString:function(e){return this.source.quotedString(e)},objectLiteral:function(e){return this.source.objectLiteral(e)},aliasable:function(e){var r=this.aliases[e];return r?(r.referenceCount++,r):(r=this.aliases[e]=this.source.wrap(e),r.aliasable=!0,r.referenceCount=1,r)},setupHelper:function(e,r,n){var i=[],s=this.setupHelperArgs(r,e,i,n),o=this.nameLookup("helpers",r,"helper"),a=this.aliasable(this.contextName(0)+" != null ? "+this.contextName(0)+" : (container.nullContext || {})");return{params:i,paramsInit:s,name:o,callParams:[a].concat(i)}},setupParams:function(e,r,n){var i={},s=[],o=[],a=[],l=!n,u=void 0;l&&(n=[]),i.name=this.quotedString(e),i.hash=this.popStack(),this.trackIds&&(i.hashIds=this.popStack()),this.stringParams&&(i.hashTypes=this.popStack(),i.hashContexts=this.popStack());var d=this.popStack(),f=this.popStack();(f||d)&&(i.fn=f||"container.noop",i.inverse=d||"container.noop");for(var h=r;h--;)u=this.popStack(),n[h]=u,this.trackIds&&(a[h]=this.popStack()),this.stringParams&&(o[h]=this.popStack(),s[h]=this.popStack());return l&&(i.args=this.source.generateArray(n)),this.trackIds&&(i.ids=this.source.generateArray(a)),this.stringParams&&(i.types=this.source.generateArray(o),i.contexts=this.source.generateArray(s)),this.options.data&&(i.data="data"),this.useBlockParams&&(i.blockParams="blockParams"),i},setupHelperArgs:function(e,r,n,i){var s=this.setupParams(e,r,n);return s.loc=JSON.stringify(this.source.currentLocation),s=this.objectLiteral(s),i?(this.useRegister("options"),n.push("options"),["options=",s]):n?(n.push(s),""):s}};(function(){for(var t="break else new var case finally return void catch for switch while continue function this with default if throw delete in try do instanceof typeof abstract enum int short boolean export interface static byte extends long super char final native synchronized class float package throws const goto private transient debugger implements protected volatile double import public let yield await null true false".split(" "),e=Xr.RESERVED_WORDS={},r=0,n=t.length;r<n;r++)e[t[r]]=!0})();Xr.isValidJavaScriptVariableName=function(t){return!Xr.RESERVED_WORDS[t]&&/^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(t)};function H$(t,e,r,n,i){var s=e.popStack(),o=r.length;t&&o--;for(var a=n;a<o;a++)s=e.nameLookup(s,r[a],i);return t?[e.aliasable("container.strict"),"(",s,", ",e.quotedString(r[o]),", ",JSON.stringify(e.source.currentLocation)," )"]:s}zs.default=Xr;Ym.exports=zs.default});var eg=w((Ws,Zm)=>{"use strict";Ws.__esModule=!0;function oi(t){return t&&t.__esModule?t:{default:t}}var B$=rm(),U$=oi(B$),G$=cl(),z$=oi(G$),Nl=hm(),Ml=vm(),W$=Xm(),K$=oi(W$),J$=js(),Y$=oi(J$),X$=il(),Q$=oi(X$),Z$=U$.default.create;function Qm(){var t=Z$();return t.compile=function(e,r){return Ml.compile(e,r,t)},t.precompile=function(e,r){return Ml.precompile(e,r,t)},t.AST=z$.default,t.Compiler=Ml.Compiler,t.JavaScriptCompiler=K$.default,t.Parser=Nl.parser,t.parse=Nl.parse,t.parseWithoutProcessing=Nl.parseWithoutProcessing,t}var Qr=Qm();Qr.create=Qm;Q$.default(Qr);Qr.Visitor=Y$.default;Qr.default=Qr;Ws.default=Qr;Zm.exports=Ws.default});var tg=w(Ks=>{"use strict";Ks.__esModule=!0;Ks.print=nC;Ks.PrintVisitor=ge;function eC(t){return t&&t.__esModule?t:{default:t}}var tC=js(),rC=eC(tC);function nC(t){return new ge().accept(t)}function ge(){this.padding=0}ge.prototype=new rC.default;ge.prototype.pad=function(t){for(var e="",r=0,n=this.padding;r<n;r++)e+=" ";return e+=t+`
|
|
58
|
-
`,e};ge.prototype.Program=function(t){var e="",r=t.body,n=void 0,i=void 0;if(t.blockParams){var
|
|
57
|
+
`.trim()},blockValue:function(e){var r=this.aliasable("container.hooks.blockHelperMissing"),n=[this.contextName(0)];this.setupHelperArgs(e,0,n);var i=this.popStack();n.splice(1,0,i),this.push(this.source.functionCall(r,"call",n))},ambiguousBlockValue:function(){var e=this.aliasable("container.hooks.blockHelperMissing"),r=[this.contextName(0)];this.setupHelperArgs("",0,r,!0),this.flushInline();var n=this.topStack();r.splice(1,0,n),this.pushSource(["if (!",this.lastHelper,") { ",n," = ",this.source.functionCall(e,"call",r),"}"])},appendContent:function(e){this.pendingContent?e=this.pendingContent+e:this.pendingLocation=this.source.currentLocation,this.pendingContent=e},append:function(){if(this.isInline())this.replaceStack(function(r){return[" != null ? ",r,' : ""']}),this.pushSource(this.appendToBuffer(this.popStack()));else{var e=this.popStack();this.pushSource(["if (",e," != null) { ",this.appendToBuffer(e,void 0,!0)," }"]),this.environment.isSimple&&this.pushSource(["else { ",this.appendToBuffer("''",void 0,!0)," }"])}},appendEscaped:function(){this.pushSource(this.appendToBuffer([this.aliasable("container.escapeExpression"),"(",this.popStack(),")"]))},getContext:function(e){this.lastContext=e},pushContext:function(){this.pushStackLiteral(this.contextName(this.lastContext))},lookupOnContext:function(e,r,n,i){var o=0;!i&&this.options.compat&&!this.lastContext?this.push(this.depthedLookup(e[o++])):this.pushContext(),this.resolvePath("context",e,o,r,n)},lookupBlockParam:function(e,r){this.useBlockParams=!0,this.push(["blockParams[",e[0],"][",e[1],"]"]),this.resolvePath("context",r,1)},lookupData:function(e,r,n){e?this.pushStackLiteral("container.data(data, "+e+")"):this.pushStackLiteral("data"),this.resolvePath("data",r,0,!0,n)},resolvePath:function(e,r,n,i,o){var s=this;if(this.options.strict||this.options.assumeObjects){this.push(Rx(this.options.strict&&o,this,r,n,e));return}for(var a=r.length,l=function(p){s.replaceStack(function(f){var h=s.nameLookup(f,r[p],e);return i?[" && ",h]:[" != null ? ",h," : ",f]})},u=n;u<a;u++)l(u)},resolvePossibleLambda:function(){this.push([this.aliasable("container.lambda"),"(",this.popStack(),", ",this.contextName(0),")"])},pushStringParam:function(e,r){this.pushContext(),this.pushString(r),r!=="SubExpression"&&(typeof e=="string"?this.pushString(e):this.pushStackLiteral(e))},emptyHash:function(e){this.trackIds&&this.push("{}"),this.stringParams&&(this.push("{}"),this.push("{}")),this.pushStackLiteral(e?"undefined":"{}")},pushHash:function(){this.hash&&this.hashes.push(this.hash),this.hash={values:{},types:[],contexts:[],ids:[]}},popHash:function(){var e=this.hash;this.hash=this.hashes.pop(),this.trackIds&&this.push(this.objectLiteral(e.ids)),this.stringParams&&(this.push(this.objectLiteral(e.contexts)),this.push(this.objectLiteral(e.types))),this.push(this.objectLiteral(e.values))},pushString:function(e){this.pushStackLiteral(this.quotedString(e))},pushLiteral:function(e){this.pushStackLiteral(e)},pushProgram:function(e){e!=null?this.pushStackLiteral(this.programExpression(e)):this.pushStackLiteral(null)},registerDecorator:function(e,r){var n=this.nameLookup("decorators",r,"decorator"),i=this.setupHelperArgs(r,e);this.decorators.push(["var decorator = ",n,";"]),this.decorators.push(['if (typeof decorator !== "function") { throw new Error(',this.quotedString('Missing decorator: "'+r+'"'),"); }"]),this.decorators.push(["fn = ",this.decorators.functionCall("decorator","",["fn","props","container",i])," || fn;"])},invokeHelper:function(e,r,n){var i=this.popStack(),o=this.setupHelper(e,r),s=[];n&&s.push(o.name),s.push(i),this.options.strict||s.push(this.aliasable("container.hooks.helperMissing"));var a=["(",this.itemsSeparatedBy(s,"||"),")"],l=this.source.functionCall(a,"call",o.callParams);this.push(l)},itemsSeparatedBy:function(e,r){var n=[];n.push(e[0]);for(var i=1;i<e.length;i++)n.push(r,e[i]);return n},invokeKnownHelper:function(e,r){var n=this.setupHelper(e,r);this.push(this.source.functionCall(n.name,"call",n.callParams))},invokeAmbiguous:function(e,r){this.useRegister("helper");var n=this.popStack();this.emptyHash();var i=this.setupHelper(0,e,r),o=this.lastHelper=this.nameLookup("helpers",e,"helper"),s=["(","(helper = ",o," || ",n,")"];this.options.strict||(s[0]="(helper = ",s.push(" != null ? helper : ",this.aliasable("container.hooks.helperMissing"))),this.push(["(",s,i.paramsInit?["),(",i.paramsInit]:[],"),","(typeof helper === ",this.aliasable('"function"')," ? ",this.source.functionCall("helper","call",i.callParams)," : helper))"])},invokePartial:function(e,r,n){var i=[],o=this.setupParams(r,1,i);e&&(r=this.popStack(),delete o.name),n&&(o.indent=JSON.stringify(n)),o.helpers="helpers",o.partials="partials",o.decorators="container.decorators",e?i.unshift(r):i.unshift(this.nameLookup("partials",r,"partial")),this.options.compat&&(o.depths="depths"),o=this.objectLiteral(o),i.push(o),this.push(this.source.functionCall("container.invokePartial","",i))},assignToHash:function(e){var r=this.popStack(),n=void 0,i=void 0,o=void 0;this.trackIds&&(o=this.popStack()),this.stringParams&&(i=this.popStack(),n=this.popStack());var s=this.hash;n&&(s.contexts[e]=n),i&&(s.types[e]=i),o&&(s.ids[e]=o),s.values[e]=r},pushId:function(e,r,n){e==="BlockParam"?this.pushStackLiteral("blockParams["+r[0]+"].path["+r[1]+"]"+(n?" + "+JSON.stringify("."+n):"")):e==="PathExpression"?this.pushString(r):e==="SubExpression"?this.pushStackLiteral("true"):this.pushStackLiteral("null")},compiler:en,compileChildren:function(e,r){for(var n=e.children,i=void 0,o=void 0,s=0,a=n.length;s<a;s++){i=n[s],o=new this.compiler;var l=this.matchExistingProgram(i);if(l==null){var u=this.context.programs.push("")-1;i.index=u,i.name="program"+u,this.context.programs[u]=o.compile(i,r,this.context,!this.precompile),this.context.decorators[u]=o.decorators,this.context.environments[u]=i,this.useDepths=this.useDepths||o.useDepths,this.useBlockParams=this.useBlockParams||o.useBlockParams,i.useDepths=this.useDepths,i.useBlockParams=this.useBlockParams}else i.index=l.index,i.name="program"+l.index,this.useDepths=this.useDepths||l.useDepths,this.useBlockParams=this.useBlockParams||l.useBlockParams}},matchExistingProgram:function(e){for(var r=0,n=this.context.environments.length;r<n;r++){var i=this.context.environments[r];if(i&&i.equals(e))return i}},programExpression:function(e){var r=this.environment.children[e],n=[r.index,"data",r.blockParams];return(this.useBlockParams||this.useDepths)&&n.push("blockParams"),this.useDepths&&n.push("depths"),"container.program("+n.join(", ")+")"},useRegister:function(e){this.registers[e]||(this.registers[e]=!0,this.registers.list.push(e))},push:function(e){return e instanceof Zr||(e=this.source.wrap(e)),this.inlineStack.push(e),e},pushStackLiteral:function(e){this.push(new Zr(e))},pushSource:function(e){this.pendingContent&&(this.source.push(this.appendToBuffer(this.source.quotedString(this.pendingContent),this.pendingLocation)),this.pendingContent=void 0),e&&this.source.push(e)},replaceStack:function(e){var r=["("],n=void 0,i=void 0,o=void 0;if(!this.isInline())throw new tu.default("replaceStack on non-inline");var s=this.popStack(!0);if(s instanceof Zr)n=[s.value],r=["(",n],o=!0;else{i=!0;var a=this.incrStack();r=["((",this.push(a)," = ",s,")"],n=this.topStack()}var l=e.call(this,n);o||this.popStack(),i&&this.stackSlot--,this.push(r.concat(l,")"))},incrStack:function(){return this.stackSlot++,this.stackSlot>this.stackVars.length&&this.stackVars.push("stack"+this.stackSlot),this.topStackName()},topStackName:function(){return"stack"+this.stackSlot},flushInline:function(){var e=this.inlineStack;this.inlineStack=[];for(var r=0,n=e.length;r<n;r++){var i=e[r];if(i instanceof Zr)this.compileStack.push(i);else{var o=this.incrStack();this.pushSource([o," = ",i,";"]),this.compileStack.push(o)}}},isInline:function(){return this.inlineStack.length},popStack:function(e){var r=this.isInline(),n=(r?this.inlineStack:this.compileStack).pop();if(!e&&n instanceof Zr)return n.value;if(!r){if(!this.stackSlot)throw new tu.default("Invalid stack pop");this.stackSlot--}return n},topStack:function(){var e=this.isInline()?this.inlineStack:this.compileStack,r=e[e.length-1];return r instanceof Zr?r.value:r},contextName:function(e){return this.useDepths&&e?"depths["+e+"]":"depth"+e},quotedString:function(e){return this.source.quotedString(e)},objectLiteral:function(e){return this.source.objectLiteral(e)},aliasable:function(e){var r=this.aliases[e];return r?(r.referenceCount++,r):(r=this.aliases[e]=this.source.wrap(e),r.aliasable=!0,r.referenceCount=1,r)},setupHelper:function(e,r,n){var i=[],o=this.setupHelperArgs(r,e,i,n),s=this.nameLookup("helpers",r,"helper"),a=this.aliasable(this.contextName(0)+" != null ? "+this.contextName(0)+" : (container.nullContext || {})");return{params:i,paramsInit:o,name:s,callParams:[a].concat(i)}},setupParams:function(e,r,n){var i={},o=[],s=[],a=[],l=!n,u=void 0;l&&(n=[]),i.name=this.quotedString(e),i.hash=this.popStack(),this.trackIds&&(i.hashIds=this.popStack()),this.stringParams&&(i.hashTypes=this.popStack(),i.hashContexts=this.popStack());var p=this.popStack(),f=this.popStack();(f||p)&&(i.fn=f||"container.noop",i.inverse=p||"container.noop");for(var h=r;h--;)u=this.popStack(),n[h]=u,this.trackIds&&(a[h]=this.popStack()),this.stringParams&&(s[h]=this.popStack(),o[h]=this.popStack());return l&&(i.args=this.source.generateArray(n)),this.trackIds&&(i.ids=this.source.generateArray(a)),this.stringParams&&(i.types=this.source.generateArray(s),i.contexts=this.source.generateArray(o)),this.options.data&&(i.data="data"),this.useBlockParams&&(i.blockParams="blockParams"),i},setupHelperArgs:function(e,r,n,i){var o=this.setupParams(e,r,n);return o.loc=JSON.stringify(this.source.currentLocation),o=this.objectLiteral(o),i?(this.useRegister("options"),n.push("options"),["options=",o]):n?(n.push(o),""):o}};(function(){for(var t="break else new var case finally return void catch for switch while continue function this with default if throw delete in try do instanceof typeof abstract enum int short boolean export interface static byte extends long super char final native synchronized class float package throws const goto private transient debugger implements protected volatile double import public let yield await null true false".split(" "),e=en.RESERVED_WORDS={},r=0,n=t.length;r<n;r++)e[t[r]]=!0})();en.isValidJavaScriptVariableName=function(t){return!en.RESERVED_WORDS[t]&&/^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(t)};function Rx(t,e,r,n,i){var o=e.popStack(),s=r.length;t&&s--;for(var a=n;a<s;a++)o=e.nameLookup(o,r[a],i);return t?[e.aliasable("container.strict"),"(",o,", ",e.quotedString(r[s]),", ",JSON.stringify(e.source.currentLocation)," )"]:o}ss.default=en;Ig.exports=ss.default});var Lg=w((as,Mg)=>{"use strict";as.__esModule=!0;function pi(t){return t&&t.__esModule?t:{default:t}}var Ix=Dm(),Tx=pi(Ix),Nx=Ol(),Mx=pi(Nx),ru=Ym(),nu=eg(),Lx=Tg(),jx=pi(Lx),Dx=Xo(),Vx=pi(Dx),qx=Cl(),Fx=pi(qx),Hx=Tx.default.create;function Ng(){var t=Hx();return t.compile=function(e,r){return nu.compile(e,r,t)},t.precompile=function(e,r){return nu.precompile(e,r,t)},t.AST=Mx.default,t.Compiler=nu.Compiler,t.JavaScriptCompiler=jx.default,t.Parser=ru.parser,t.parse=ru.parse,t.parseWithoutProcessing=ru.parseWithoutProcessing,t}var tn=Ng();tn.create=Ng;Fx.default(tn);tn.Visitor=Vx.default;tn.default=tn;as.default=tn;Mg.exports=as.default});var jg=w(cs=>{"use strict";cs.__esModule=!0;cs.print=Wx;cs.PrintVisitor=ge;function Bx(t){return t&&t.__esModule?t:{default:t}}var Ux=Xo(),Gx=Bx(Ux);function Wx(t){return new ge().accept(t)}function ge(){this.padding=0}ge.prototype=new Gx.default;ge.prototype.pad=function(t){for(var e="",r=0,n=this.padding;r<n;r++)e+=" ";return e+=t+`
|
|
58
|
+
`,e};ge.prototype.Program=function(t){var e="",r=t.body,n=void 0,i=void 0;if(t.blockParams){var o="BLOCK PARAMS: [";for(n=0,i=t.blockParams.length;n<i;n++)o+=" "+t.blockParams[n];o+=" ]",e+=this.pad(o)}for(n=0,i=r.length;n<i;n++)e+=this.accept(r[n]);return this.padding--,e};ge.prototype.MustacheStatement=function(t){return this.pad("{{ "+this.SubExpression(t)+" }}")};ge.prototype.Decorator=function(t){return this.pad("{{ DIRECTIVE "+this.SubExpression(t)+" }}")};ge.prototype.BlockStatement=ge.prototype.DecoratorBlock=function(t){var e="";return e+=this.pad((t.type==="DecoratorBlock"?"DIRECTIVE ":"")+"BLOCK:"),this.padding++,e+=this.pad(this.SubExpression(t)),t.program&&(e+=this.pad("PROGRAM:"),this.padding++,e+=this.accept(t.program),this.padding--),t.inverse&&(t.program&&this.padding++,e+=this.pad("{{^}}"),this.padding++,e+=this.accept(t.inverse),this.padding--,t.program&&this.padding--),this.padding--,e};ge.prototype.PartialStatement=function(t){var e="PARTIAL:"+t.name.original;return t.params[0]&&(e+=" "+this.accept(t.params[0])),t.hash&&(e+=" "+this.accept(t.hash)),this.pad("{{> "+e+" }}")};ge.prototype.PartialBlockStatement=function(t){var e="PARTIAL BLOCK:"+t.name.original;return t.params[0]&&(e+=" "+this.accept(t.params[0])),t.hash&&(e+=" "+this.accept(t.hash)),e+=" "+this.pad("PROGRAM:"),this.padding++,e+=this.accept(t.program),this.padding--,this.pad("{{> "+e+" }}")};ge.prototype.ContentStatement=function(t){return this.pad("CONTENT[ '"+t.value+"' ]")};ge.prototype.CommentStatement=function(t){return this.pad("{{! '"+t.value+"' }}")};ge.prototype.SubExpression=function(t){for(var e=t.params,r=[],n=void 0,i=0,o=e.length;i<o;i++)r.push(this.accept(e[i]));return e="["+r.join(", ")+"]",n=t.hash?" "+this.accept(t.hash):"",this.accept(t.path)+" "+e+n};ge.prototype.PathExpression=function(t){var e=t.parts.join("/");return(t.data?"@":"")+"PATH:"+e};ge.prototype.StringLiteral=function(t){return'"'+t.value+'"'};ge.prototype.NumberLiteral=function(t){return"NUMBER{"+t.value+"}"};ge.prototype.BooleanLiteral=function(t){return"BOOLEAN{"+t.value+"}"};ge.prototype.UndefinedLiteral=function(){return"UNDEFINED"};ge.prototype.NullLiteral=function(){return"NULL"};ge.prototype.Hash=function(t){for(var e=t.pairs,r=[],n=0,i=e.length;n<i;n++)r.push(this.accept(e[n]));return"HASH{"+r.join(", ")+"}"};ge.prototype.HashPair=function(t){return t.key+"="+this.accept(t.value)}});var Fg=w((RR,qg)=>{var ls=Lg().default,Vg=jg();ls.PrintVisitor=Vg.PrintVisitor;ls.print=Vg.print;qg.exports=ls;function Dg(t,e){var r=nt("fs"),n=r.readFileSync(e,"utf8");t.exports=ls.compile(n)}typeof nt<"u"&&nt.extensions&&(nt.extensions[".handlebars"]=Dg,nt.extensions[".hbs"]=Dg)});var Su=xi(bu(),1),{program:NC,createCommand:MC,createArgument:LC,createOption:jC,CommanderError:DC,InvalidArgumentError:VC,InvalidOptionArgumentError:qC,Command:Eu,Argument:FC,Option:HC,Help:BC}=Su.default;var $u=`# yaml-language-server: $schema=./node_modules/cli-contracts/schemas/cli-contract.schema.json
|
|
59
59
|
cli_contracts: 0.1.0
|
|
60
60
|
|
|
61
61
|
info:
|
|
62
62
|
title: view-contracts CLI
|
|
63
|
-
version: 0.3.
|
|
63
|
+
version: 0.3.5
|
|
64
64
|
description: >-
|
|
65
65
|
Contract-first UI design toolchain. Compiles restricted view-contract TSX
|
|
66
66
|
to language-neutral View IR and renders platform targets (React, SwiftUI, Compose).
|
|
@@ -219,11 +219,11 @@ command_sets:
|
|
|
219
219
|
description: Lint passed.
|
|
220
220
|
'1':
|
|
221
221
|
description: Lint failed.
|
|
222
|
-
`,
|
|
222
|
+
`,xu=`{
|
|
223
223
|
"cli_contracts": "0.1.0",
|
|
224
224
|
"info": {
|
|
225
225
|
"title": "view-contracts CLI",
|
|
226
|
-
"version": "0.3.
|
|
226
|
+
"version": "0.3.5",
|
|
227
227
|
"description": "Contract-first UI design toolchain. Compiles restricted view-contract TSX to language-neutral View IR and renders platform targets (React, SwiftUI, Compose)."
|
|
228
228
|
},
|
|
229
229
|
"artifact_slots": {
|
|
@@ -453,123 +453,140 @@ command_sets:
|
|
|
453
453
|
}
|
|
454
454
|
}
|
|
455
455
|
}
|
|
456
|
-
}`;function
|
|
457
|
-
`),process.exit(2));let l=
|
|
458
|
-
`)}else{let f=[];if(f.push("# view-contracts extract"),f.push("# source: embedded"),f.push("# type: cli-contracts/command-extract"),
|
|
456
|
+
}`;function Cu(t,e){let r=new Eu;r.name("view-contracts").version(e,"-V, --version").description("View contract compiler and renderer toolchain."),r.command("compile").description("Compile .view.tsx files to View IR.").option("-c, --config <path>","Path to view-contracts.config.yaml (discovered upward from cwd when omitted).").action(async(o,s)=>{await t.compile(o,s.optsWithGlobals())});let n=r.command("render");n.command("react").description("Generate React components from View IR.").option("-c, --config <path>","Path to view-contracts.config.yaml (discovered upward from cwd when omitted).").action(async(o,s)=>{await t.renderReact(o,s.optsWithGlobals())}),n.command("bridge").description("Generate view \u2194 ViewModel bridge registry.").option("-c, --config <path>","Path to view-contracts.config.yaml (discovered upward from cwd when omitted).").action(async(o,s)=>{await t.renderBridge(o,s.optsWithGlobals())}),r.command("build").description("Full view pipeline (compile + render runtime + render react + bridge).").option("-c, --config <path>","Path to view-contracts.config.yaml (discovered upward from cwd when omitted).").action(async(o,s)=>{await t.build(o,s.optsWithGlobals())});let i=r.command("contracts");return i.command("generate").description("Generate ViewModel types from OpenAPI via micro-contracts.").option("-c, --config <path>","Path to view-contracts.config.yaml (discovered upward from cwd when omitted).").action(async(o,s)=>{await t.contractsGenerate(o,s.optsWithGlobals())}),i.command("check").description("Lint OpenAPI screen contracts via micro-contracts.").option("-c, --config <path>","Path to view-contracts.config.yaml (discovered upward from cwd when omitted).").action(async(o,s)=>{await t.contractsCheck(o,s.optsWithGlobals())}),r.command("extract").description("Extract contract specification for this CLI tool.").argument("[commands...]","Command IDs to extract. Use dot notation.").option("-a, --all","Extract all commands.",!1).option("--include-meta","Include extraction metadata.",!0).option("-F, --format <format>","Output format (yaml or json).","yaml").action(async(o,s,a)=>{o.length===0&&!s.all&&(process.stderr.write(JSON.stringify({code:"INVALID_ARGS",message:"Specify command IDs or use --all"})+`
|
|
457
|
+
`),process.exit(2));let l=s.format||"yaml",u=JSON.parse(xu),p=s.all?[]:o;if(p.length===0)if(l==="json"){let f={};s.includeMeta&&(f._meta={source:"embedded",type:"cli-contracts/extract",extractedAt:new Date().toISOString(),specVersion:u.cli_contracts??"0.1.0",commands:["view-contracts.compile","view-contracts.render.react","view-contracts.render.bridge","view-contracts.build","view-contracts.contracts.generate","view-contracts.contracts.check"]}),Object.assign(f,u),process.stdout.write(JSON.stringify(f,null,2)+`
|
|
458
|
+
`)}else{let f=[];if(f.push("# view-contracts extract"),f.push("# source: embedded"),f.push("# type: cli-contracts/command-extract"),s.includeMeta){f.push("---"),f.push("source: embedded"),f.push("type: cli-contracts/command-extract"),f.push("extractedAt: "+new Date().toISOString()),f.push("spec_version: "+(u.cli_contracts??"0.1.0")),f.push("commands:");for(let h of["view-contracts.compile","view-contracts.render.react","view-contracts.render.bridge","view-contracts.build","view-contracts.contracts.generate","view-contracts.contracts.check"])f.push(" - "+h)}f.push("---"),f.push($u),process.stdout.write(f.join(`
|
|
459
459
|
`)+`
|
|
460
|
-
`)}else{let f={cli_contracts:u.cli_contracts,info:u.info,command_sets:{}},h=f.command_sets;for(let[m,g]of Object.entries(u.command_sets??{})){let
|
|
461
|
-
`)}process.exit(0)}),r}import{writeFile as PC,mkdir as OC}from"node:fs/promises";import{resolve as Dl,dirname as AC}from"node:path";import{spawn as RC}from"node:child_process";import{readFile as cy}from"node:fs/promises";import{basename as ly,relative as uy,resolve as fy}from"node:path";import{readFileSync as Qg}from"node:fs";import{dirname as ou,resolve as Zg}from"node:path";import I from"typescript";var vr=new Set(["App","Box","Button","Checkbox","Column","Divider","Drawer","Field","Form","Heading","Icon","IconButton","Image","Link","List","ListItem","Modal","Page","Popover","Progress","Radio","Row","SafeArea","ScrollArea","Select","Spacer","Spinner","Stack","Switch","Text","TextArea","TextInput","Tooltip"]);import{readFileSync as Kg}from"node:fs";import{resolve as Jg}from"node:path";import ce from"typescript";function Eo(t,e){let r=new Map;for(let n of t.statements){if(!ce.isImportDeclaration(n)||!n.importClause?.namedBindings||!ce.isStringLiteral(n.moduleSpecifier)||!ce.isNamedImports(n.importClause.namedBindings))continue;let i=n.moduleSpecifier.text;i.endsWith(".tsx")||(i=`${i}.tsx`);let s=Jg(e,i);for(let o of n.importClause.namedBindings.elements)r.set(o.name.text,s)}return r}function Yg(t){if(!ce.isObjectBindingPattern(t.name)||t.name.elements.length===0)return null;let e=t.name.elements[0];return!ce.isBindingElement(e)||!ce.isIdentifier(e.name)?null:e.name.text}function Xg(t){if(ce.isParenthesizedExpression(t))return t.expression;if(ce.isJsxElement(t)||ce.isJsxSelfClosingElement(t)||ce.isJsxFragment(t))return t;if(ce.isBlock(t)&&t.statements.length===1){let e=t.statements[0];if(ce.isReturnStatement(e)&&e.expression)return ce.isParenthesizedExpression(e.expression)?e.expression.expression:e.expression}return null}function iu(t){if(!ce.isIdentifier(t.expression)||t.expression.text!=="view"||t.arguments.length!==1)return null;let e=t.arguments[0];if(!ce.isArrowFunction(e)&&!ce.isFunctionExpression(e))return null;let r="__noop";if(e.parameters.length===1){let i=Yg(e.parameters[0]);if(i)r=i;else if(ce.isIdentifier(e.parameters[0].name))r=e.parameters[0].name.text;else return null}else if(e.parameters.length>1)return null;let n=Xg(e.body);return n?{paramName:r,jsxRoot:n}:null}function su(t,e){let r=Kg(t,"utf-8"),n=ce.createSourceFile(t,r,ce.ScriptTarget.Latest,!0,ce.ScriptKind.TSX),i=null;function s(o){if(ce.isVariableStatement(o))for(let a of o.declarationList.declarations){if(!ce.isIdentifier(a.name)||a.name.text!==e||!a.initializer||!ce.isCallExpression(a.initializer))continue;let l=iu(a.initializer);l&&(i=l)}if(ce.isExportAssignment(o)&&o.isExportEquals===!1&&o.expression&&ce.isCallExpression(o.expression)){let a=iu(o.expression);a&&e==="default"&&(i=a)}ce.forEachChild(o,s)}return s(n),i}var ey=new Set(["Text","Heading"]);function ty(t,e,r){if(ey.has(t)){if("tone"in e){let n=e.tone;delete e.tone,"variant"in e||(e.variant=n),r.warnings.push(`"tone" on <${t}> is deprecated; use variant instead (mapped automatically)`)}if("textStyle"in e){let n=e.textStyle;delete e.textStyle,"variant"in e||(e.variant=n),r.warnings.push(`"textStyle" on <${t}> is deprecated; use variant instead (mapped automatically)`)}}}function $o(t){return t.join(".")}function _r(t){let e=t.getText().replace(/\s+/g," ").trim();return e.length>100?`${e.slice(0,97)}...`:e}function Co(t){if(I.isIdentifier(t))return[t.text];if(I.isPropertyAccessExpression(t)){let e=Co(t.expression);return e?[...e,t.name.text]:null}return null}function ry(t){return typeof t=="object"&&t!==null&&"kind"in t&&t.kind==="binding"}function au(t,e){if(e.length===0)return t;let r=e.join(".");return{kind:"binding",path:t.path?`${t.path}.${r}`:r,scope:t.scope}}function Si(t,e){let r=Co(t);if(!r)return null;if(r[0]in e.propBindings)return au(e.propBindings[r[0]],r.slice(1));if(r[0]===e.vmName)return{kind:"binding",path:$o(r.slice(1))};let n=e.scopes[e.scopes.length-1];return n&&r[0]===n?{kind:"binding",path:$o(r.slice(1)),scope:n}:null}function ny(t,e){let r,n={};for(let i of t.properties){if(!I.isPropertyAssignment(i)||!I.isIdentifier(i.name))continue;let s=i.name.text;if(s==="name"&&I.isStringLiteral(i.initializer)){r=i.initializer.text;continue}if(s==="params"&&I.isObjectLiteralExpression(i.initializer))for(let o of i.initializer.properties){if(!I.isPropertyAssignment(o)||!I.isIdentifier(o.name))continue;let a=Ei(o.initializer,e);a!==null?n[o.name.text]=a:e.errors.push(`Unsupported action param expression for "${o.name.text}": ${_r(o.initializer)}`)}}return r?Object.keys(n).length>0?{kind:"action",name:r,params:n}:{kind:"action",name:r}:null}function Ei(t,e){if(I.isStringLiteral(t)||I.isNoSubstitutionTemplateLiteral(t))return t.text;if(t.kind===I.SyntaxKind.TrueKeyword)return!0;if(t.kind===I.SyntaxKind.FalseKeyword)return!1;if(I.isNumericLiteral(t))return Number(t.text);if(t.kind===I.SyntaxKind.NullKeyword)return null;let r=Si(t,e);if(r)return r;if(I.isObjectLiteralExpression(t)){let n=ny(t,e);if(n)return n;let i={};for(let s of t.properties){if(!I.isPropertyAssignment(s)||!I.isIdentifier(s.name))continue;let o=Ei(s.initializer,e);o!==null?i[s.name.text]=o:e.errors.push(`Unsupported object literal property "${s.name.text}": ${_r(s.initializer)}`)}return{kind:"literal",value:i}}if(I.isArrayLiteralExpression(t)){let n=[];for(let i of t.elements){if(!I.isExpression(i))continue;let s=Ei(i,e);s!==null?n.push(s):e.errors.push(`Unsupported array element expression: ${_r(i)}`)}return n}return null}function iy(t){return I.isIdentifier(t)?t.text:I.isPropertyAccessExpression(t)&&I.isIdentifier(t.name)?t.name.text:null}function cu(t){return t.getText()}function lu(t,e){let r=[];for(let n of t){if(I.isJsxText(n)){let i=n.getText().trim();i&&r.push({kind:"text",value:i});continue}if(I.isJsxExpression(n)&&n.expression){let i=Si(n.expression,e);if(i){r.push(i);continue}let s=uu(n.expression,e);s?Array.isArray(s)?r.push(...s):r.push(s):e.errors.push(`Unsupported JSX child expression: ${_r(n.expression)}`);continue}if(I.isJsxElement(n)||I.isJsxSelfClosingElement(n)){let i=an(n,e);i&&r.push(i)}}return r}function sy(t,e){if(t.length===0)return null;let r=t[0];return r in e.propBindings?au(e.propBindings[r],t.slice(1)):r===e.vmName?{kind:"binding",path:$o(t.slice(1))}:null}function uu(t,e){if(I.isParenthesizedExpression(t))return uu(t.expression,e);if(I.isCallExpression(t)&&I.isPropertyAccessExpression(t.expression)){let n=Co(t.expression.expression),i=t.expression.name.text;if(n&&i==="map"&&t.arguments.length>=1){let s=sy(n,e);if(!s)return null;let o=t.arguments[0];if(!I.isArrowFunction(o)&&!I.isFunctionExpression(o))return e.errors.push("map callback must be an arrow function"),null;let a=o.parameters;if(a.length!==1||!I.isIdentifier(a[0].name))return e.errors.push("map callback must have a single item parameter"),null;let l=a[0].name.text,u={...e,scopes:[...e.scopes,l]},d=null,f=I.isParenthesizedExpression(o.body)?o.body.expression:o.body;if(I.isBlock(o.body))return e.errors.push("map callback body must be a JSX expression, not a block"),null;if(I.isJsxElement(f)||I.isJsxSelfClosingElement(f)?d=an(f,u):I.isJsxFragment(f)&&(d=ko(f,u)),!d)return null;let h;if(I.isJsxElement(f)||I.isJsxSelfClosingElement(f)){let m=I.isJsxElement(f)?f.openingElement.attributes:f.attributes;for(let g of m.properties)if(!(!I.isJsxAttribute(g)||cu(g.name)!=="key"||!g.initializer)&&I.isJsxExpression(g.initializer)&&g.initializer.expression){let _=Si(g.initializer.expression,u);_&&(h=_)}}return{kind:"map",source:s,item:l,key:h,body:d}}}if(I.isJsxElement(t)||I.isJsxSelfClosingElement(t))return an(t,e);let r=Si(t,e);return r||null}function ko(t,e){return{kind:"fragment",children:lu(t.children,e)}}function oy(t,e,r){let n=r.viewImports.get(t);if(!n)return null;let i=su(n,t);if(!i)return r.errors.push(`View component "${t}" is imported but has no view() export`),null;let s=Qg(n,"utf-8"),o=I.createSourceFile(n,s,I.ScriptTarget.Latest,!0,I.ScriptKind.TSX),a=Eo(o,ou(n)),l=new Map([...r.viewImports,...a]),u={...r.propBindings};for(let[f,h]of Object.entries(e))ry(h)&&(u[f]=h);let d={...r,vmName:i.paramName,propBindings:u,scopes:[],viewImports:l};return I.isJsxElement(i.jsxRoot)||I.isJsxSelfClosingElement(i.jsxRoot)?an(i.jsxRoot,d):I.isJsxFragment(i.jsxRoot)?ko(i.jsxRoot,d):I.isConditionalExpression(i.jsxRoot)?(r.errors.push("view() partial root must be a JSX element or fragment; conditional expressions are not supported"),null):I.isExpression(i.jsxRoot)?(r.errors.push(`view() partial root must be a JSX element or fragment; unsupported expression: ${_r(i.jsxRoot)}`),null):(r.errors.push(`view() partial root must be a JSX element or fragment; unsupported syntax kind: ${I.SyntaxKind[i.jsxRoot.kind]}`),null)}function an(t,e){let r=I.isJsxElement(t)?t.openingElement:t,n=iy(r.tagName);if(!n)return e.errors.push("Unsupported JSX tag expression"),null;let i={};for(let o of r.attributes.properties){if(!I.isJsxAttribute(o))continue;let a=cu(o.name);if(a!=="key"){if(!o.initializer){i[a]=!0;continue}if(I.isStringLiteral(o.initializer)){i[a]=o.initializer.text;continue}if(I.isJsxExpression(o.initializer)&&o.initializer.expression){let l=Ei(o.initializer.expression,e);l!==null?i[a]=l:e.errors.push(`Unsupported JSX prop expression for "${a}" on <${n}>: ${_r(o.initializer.expression)}`)}}}if(!e.allowedComponents.has(n)){let o=oy(n,i,e);return o||(e.errors.push(`Component "${n}" is not in the allowed registry`),null)}ty(n,i,e);let s=I.isJsxElement(t)?lu(t.children,e):[];return{kind:"component",name:n,props:i,children:s}}function ay(t){let e=null;function r(n){if(I.isCallExpression(n)&&I.isIdentifier(n.expression)&&n.expression.text==="screen"&&n.arguments.length===1&&(I.isArrowFunction(n.arguments[0])||I.isFunctionExpression(n.arguments[0]))){let i=n.arguments[0],s="unknown";if(n.typeArguments&&n.typeArguments.length===1){let a=n.typeArguments[0];I.isTypeReferenceNode(a)&&I.isIdentifier(a.typeName)&&(s=a.typeName.text)}let o=i.body;if(I.isParenthesizedExpression(o))(I.isJsxElement(o.expression)||I.isJsxSelfClosingElement(o.expression))&&(e={viewModel:s,jsxRoot:o.expression});else if(I.isJsxElement(o)||I.isJsxSelfClosingElement(o))e={viewModel:s,jsxRoot:o};else if(I.isBlock(o)&&o.statements.length===1){let a=o.statements[0];I.isReturnStatement(a)&&a.expression&&(I.isParenthesizedExpression(a.expression)?e={viewModel:s,jsxRoot:a.expression.expression}:e={viewModel:s,jsxRoot:a.expression})}}I.forEachChild(n,r)}return r(t),e}function fu(t,e,r,n={}){let i=new Set(vr);for(let f of n.allowlistExtra??[])i.add(f);let s=Zg(e),o=ou(s),a=I.createSourceFile(s,t,I.ScriptTarget.Latest,!0,I.ScriptKind.TSX),l={vmName:"vm",scopes:[],propBindings:{},errors:[],warnings:[],viewImports:Eo(a,o),allowedComponents:i},u=ay(a);if(!u)return{viewModel:"unknown",exportName:r,root:{kind:"fragment",children:[]},errors:["No screen<T>() default export found"],warnings:[]};let d=I.isJsxElement(u.jsxRoot)||I.isJsxSelfClosingElement(u.jsxRoot)?an(u.jsxRoot,l):I.isJsxFragment(u.jsxRoot)?ko(u.jsxRoot,l):null;return d?{viewModel:u.viewModel,exportName:r,root:d,errors:l.errors,warnings:l.warnings}:(l.errors.push("screen() callback must return a single JSX root element"),{viewModel:u.viewModel,exportName:r,root:{kind:"fragment",children:[]},errors:l.errors,warnings:l.warnings})}function du(t,e){let r=[],n=[],i=s=>{if(s.kind==="component"){!vr.has(s.name)&&!(s.name in e.extensions)&&r.push(`Extension component "${s.name}" is not registered in extensions.yaml`);for(let o of s.children)i(o);return}if(s.kind==="map"){i(s.body);return}if(s.kind==="fragment")for(let o of s.children)i(o)};return i(t),{errors:r,warnings:n}}async function dy(t,e={}){let r=await cy(t.sourcePath,"utf-8"),n=t.exportName??ly(t.sourcePath,".view.tsx"),i=fu(r,t.sourcePath,n,{allowlistExtra:e.allowlistExtra});if(i.errors.length>0)throw new Error(`Compile errors in ${t.sourcePath}:
|
|
462
|
-
${i.errors.map(
|
|
463
|
-
`)}`);if(
|
|
464
|
-
${
|
|
465
|
-
`)}`);i.warnings.push(...
|
|
460
|
+
`)}else{let f={cli_contracts:u.cli_contracts,info:u.info,command_sets:{}},h=f.command_sets;for(let[m,g]of Object.entries(u.command_sets??{})){let v=g.commands;if(!v)continue;let P={};for(let[b,j]of Object.entries(v)){let B=m+"."+b;p.some(L=>L===b||L===B||b.startsWith(L+"."))&&(P[b]=j)}if(Object.keys(P).length>0){let b={...g};b.commands=P,h[m]=b}}u.components&&(f.components=u.components),process.stdout.write(JSON.stringify(f,null,2)+`
|
|
461
|
+
`)}process.exit(0)}),r}import{writeFile as bC,mkdir as SC}from"node:fs/promises";import{resolve as vt,dirname as sy,relative as EC}from"node:path";import{spawn as $C}from"node:child_process";import{readFile as Du}from"node:fs/promises";import{basename as Hy,relative as Vu,resolve as qu}from"node:path";import{dirname as Au,resolve as Ou}from"node:path";import I from"typescript";var Jt=new Set(["App","Box","Button","Checkbox","Column","Divider","Drawer","Field","Form","Heading","Icon","IconButton","Image","Link","List","ListItem","Modal","Page","Popover","Progress","Radio","Row","SafeArea","ScrollArea","Select","Spacer","Spinner","Stack","Switch","Text","TextArea","TextInput","Tooltip"]);import{readFileSync as Ay}from"node:fs";import{resolve as Oy}from"node:path";import oe from"typescript";function Ms(t,e){let r=new Map;for(let n of t.statements){if(!oe.isImportDeclaration(n)||!n.importClause?.namedBindings||!oe.isStringLiteral(n.moduleSpecifier)||!oe.isNamedImports(n.importClause.namedBindings))continue;let i=n.moduleSpecifier.text;i.endsWith(".tsx")||(i=`${i}.tsx`);let o=Oy(e,i);for(let s of n.importClause.namedBindings.elements)r.set(s.name.text,o)}return r}function Ry(t){if(oe.isObjectBindingPattern(t.name)){let e=[];for(let r of t.name.elements)oe.isBindingElement(r)&&oe.isIdentifier(r.name)&&e.push(r.name.text);return e}return oe.isIdentifier(t.name)?[t.name.text]:[]}function Iy(t){if(!oe.isObjectBindingPattern(t.name)||t.name.elements.length===0)return null;let e=t.name.elements[0];return!oe.isBindingElement(e)||!oe.isIdentifier(e.name)?null:e.name.text}function Ty(t){if(oe.isParenthesizedExpression(t))return t.expression;if(oe.isJsxElement(t)||oe.isJsxSelfClosingElement(t)||oe.isJsxFragment(t))return t;if(oe.isBlock(t)&&t.statements.length===1){let e=t.statements[0];if(oe.isReturnStatement(e)&&e.expression)return oe.isParenthesizedExpression(e.expression)?e.expression.expression:e.expression}return null}function Pu(t){if(!oe.isIdentifier(t.expression)||t.expression.text!=="view"||t.arguments.length!==1)return null;let e=t.arguments[0];if(!oe.isArrowFunction(e)&&!oe.isFunctionExpression(e))return null;let r="__noop",n=[];if(e.parameters.length===1){let s=Iy(e.parameters[0]);if(n=Ry(e.parameters[0]),s)r=s;else if(oe.isIdentifier(e.parameters[0].name))r=e.parameters[0].name.text,n=[r];else return null}else if(e.parameters.length>1)return null;let i=Ty(e.body);if(!i)return null;let o;return t.typeArguments&&t.typeArguments.length===1&&(o=t.typeArguments[0].getText()),{paramName:r,jsxRoot:i,propNames:n,propsType:o}}function Ls(t,e){let r=null;function n(i){if(oe.isVariableStatement(i))for(let o of i.declarationList.declarations){if(!oe.isIdentifier(o.name)||o.name.text!==e||!o.initializer||!oe.isCallExpression(o.initializer))continue;let s=Pu(o.initializer);s&&(r=s)}if(oe.isExportAssignment(i)&&i.isExportEquals===!1&&i.expression&&oe.isCallExpression(i.expression)){let o=Pu(i.expression);o&&e==="default"&&(r=o)}oe.forEachChild(i,n)}return n(t),r}function ku(t,e){let r=Ay(t,"utf-8"),n=oe.createSourceFile(t,r,oe.ScriptTarget.Latest,!0,oe.ScriptKind.TSX);return Ls(n,e)}var Ny=new Set(["Text","Heading"]);function My(t,e,r){if(Ny.has(t)){if("tone"in e){let n=e.tone;delete e.tone,"variant"in e||(e.variant=n),r.warnings.push(`"tone" on <${t}> is deprecated; use variant instead (mapped automatically)`)}if("textStyle"in e){let n=e.textStyle;delete e.textStyle,"variant"in e||(e.variant=n),r.warnings.push(`"textStyle" on <${t}> is deprecated; use variant instead (mapped automatically)`)}}}function js(t){return t.join(".")}function Er(t){let e=t.getText().replace(/\s+/g," ").trim();return e.length>100?`${e.slice(0,97)}...`:e}function Ds(t){if(I.isIdentifier(t))return[t.text];if(I.isPropertyAccessExpression(t)){let e=Ds(t.expression);return e?[...e,t.name.text]:null}return null}function Ru(t,e){if(e.length===0)return t;let r=e.join(".");return{kind:"binding",path:t.path?`${t.path}.${r}`:r,scope:t.scope}}function Ai(t,e){let r=Ds(t);if(!r)return null;if(r[0]in e.propBindings)return Ru(e.propBindings[r[0]],r.slice(1));if(r[0]===e.vmName)return{kind:"binding",path:js(r.slice(1))};let n=e.scopes[e.scopes.length-1];return n&&r[0]===n?{kind:"binding",path:js(r.slice(1)),scope:n}:null}function Ly(t,e){let r,n={};for(let i of t.properties){if(!I.isPropertyAssignment(i)||!I.isIdentifier(i.name))continue;let o=i.name.text;if(o==="name"&&I.isStringLiteral(i.initializer)){r=i.initializer.text;continue}if(o==="params"&&I.isObjectLiteralExpression(i.initializer))for(let s of i.initializer.properties){if(!I.isPropertyAssignment(s)||!I.isIdentifier(s.name))continue;let a=Oi(s.initializer,e);a!==null?n[s.name.text]=a:e.errors.push(`Unsupported action param expression for "${s.name.text}": ${Er(s.initializer)}`)}}return r?Object.keys(n).length>0?{kind:"action",name:r,params:n}:{kind:"action",name:r}:null}function Oi(t,e){if(I.isStringLiteral(t)||I.isNoSubstitutionTemplateLiteral(t))return t.text;if(t.kind===I.SyntaxKind.TrueKeyword)return!0;if(t.kind===I.SyntaxKind.FalseKeyword)return!1;if(I.isNumericLiteral(t))return Number(t.text);if(t.kind===I.SyntaxKind.NullKeyword)return null;let r=Ai(t,e);if(r)return r;if(I.isObjectLiteralExpression(t)){let n=Ly(t,e);if(n)return n;let i={};for(let o of t.properties){if(!I.isPropertyAssignment(o)||!I.isIdentifier(o.name))continue;let s=Oi(o.initializer,e);s!==null?i[o.name.text]=s:e.errors.push(`Unsupported object literal property "${o.name.text}": ${Er(o.initializer)}`)}return{kind:"literal",value:i}}if(I.isArrayLiteralExpression(t)){let n=[];for(let i of t.elements){if(!I.isExpression(i))continue;let o=Oi(i,e);o!==null?n.push(o):e.errors.push(`Unsupported array element expression: ${Er(i)}`)}return n}return null}function jy(t){return I.isIdentifier(t)?t.text:I.isPropertyAccessExpression(t)&&I.isIdentifier(t.name)?t.name.text:null}function Iu(t){return t.getText()}function Tu(t,e){let r=[];for(let n of t){if(I.isJsxText(n)){let i=n.getText().trim();i&&r.push({kind:"text",value:i});continue}if(I.isJsxExpression(n)&&n.expression){let i=Ai(n.expression,e);if(i){r.push(i);continue}let o=Nu(n.expression,e);o?Array.isArray(o)?r.push(...o):r.push(o):e.errors.push(`Unsupported JSX child expression: ${Er(n.expression)}`);continue}if(I.isJsxElement(n)||I.isJsxSelfClosingElement(n)){let i=un(n,e);i&&r.push(i)}}return r}function Dy(t,e){if(t.length===0)return null;let r=t[0];return r in e.propBindings?Ru(e.propBindings[r],t.slice(1)):r===e.vmName?{kind:"binding",path:js(t.slice(1))}:null}function Nu(t,e){if(I.isParenthesizedExpression(t))return Nu(t.expression,e);if(I.isCallExpression(t)&&I.isPropertyAccessExpression(t.expression)){let n=Ds(t.expression.expression),i=t.expression.name.text;if(n&&i==="map"&&t.arguments.length>=1){let o=Dy(n,e);if(!o)return null;let s=t.arguments[0];if(!I.isArrowFunction(s)&&!I.isFunctionExpression(s))return e.errors.push("map callback must be an arrow function"),null;let a=s.parameters;if(a.length!==1||!I.isIdentifier(a[0].name))return e.errors.push("map callback must have a single item parameter"),null;let l=a[0].name.text,u={...e,scopes:[...e.scopes,l]},p=null,f=I.isParenthesizedExpression(s.body)?s.body.expression:s.body;if(I.isBlock(s.body))return e.errors.push("map callback body must be a JSX expression, not a block"),null;if(I.isJsxElement(f)||I.isJsxSelfClosingElement(f)?p=un(f,u):I.isJsxFragment(f)&&(p=Vs(f,u)),!p)return null;let h;if(I.isJsxElement(f)||I.isJsxSelfClosingElement(f)){let m=I.isJsxElement(f)?f.openingElement.attributes:f.attributes;for(let g of m.properties)if(!(!I.isJsxAttribute(g)||Iu(g.name)!=="key"||!g.initializer)&&I.isJsxExpression(g.initializer)&&g.initializer.expression){let v=Ai(g.initializer.expression,u);v&&(h=v)}}return{kind:"map",source:o,item:l,key:h,body:p}}}if(I.isJsxElement(t)||I.isJsxSelfClosingElement(t))return un(t,e);let r=Ai(t,e);return r||null}function Vs(t,e){return{kind:"fragment",children:Tu(t.children,e)}}function Vy(t,e,r){let n=r.viewImports.get(t);return n?ku(n,t)?{kind:"viewRef",name:t,sourcePath:n,props:e}:(r.errors.push(`View component "${t}" is imported but has no view() export`),null):null}function un(t,e){let r=I.isJsxElement(t)?t.openingElement:t,n=jy(r.tagName);if(!n)return e.errors.push("Unsupported JSX tag expression"),null;let i={};for(let s of r.attributes.properties){if(!I.isJsxAttribute(s))continue;let a=Iu(s.name);if(a!=="key"){if(!s.initializer){i[a]=!0;continue}if(I.isStringLiteral(s.initializer)){i[a]=s.initializer.text;continue}if(I.isJsxExpression(s.initializer)&&s.initializer.expression){let l=Oi(s.initializer.expression,e);l!==null?i[a]=l:e.errors.push(`Unsupported JSX prop expression for "${a}" on <${n}>: ${Er(s.initializer.expression)}`)}}}if(!e.allowedComponents.has(n)){let s=Vy(n,i,e);return s||(e.errors.push(`Component "${n}" is not in the allowed registry`),null)}My(n,i,e);let o=I.isJsxElement(t)?Tu(t.children,e):[];return{kind:"component",name:n,props:i,children:o}}function qy(t){let e=null;function r(n){if(I.isCallExpression(n)&&I.isIdentifier(n.expression)&&n.expression.text==="screen"&&n.arguments.length===1&&(I.isArrowFunction(n.arguments[0])||I.isFunctionExpression(n.arguments[0]))){let i=n.arguments[0],o="unknown";if(n.typeArguments&&n.typeArguments.length===1){let a=n.typeArguments[0];I.isTypeReferenceNode(a)&&I.isIdentifier(a.typeName)&&(o=a.typeName.text)}let s=i.body;if(I.isParenthesizedExpression(s))(I.isJsxElement(s.expression)||I.isJsxSelfClosingElement(s.expression))&&(e={viewModel:o,jsxRoot:s.expression});else if(I.isJsxElement(s)||I.isJsxSelfClosingElement(s))e={viewModel:o,jsxRoot:s};else if(I.isBlock(s)&&s.statements.length===1){let a=s.statements[0];I.isReturnStatement(a)&&a.expression&&(I.isParenthesizedExpression(a.expression)?e={viewModel:o,jsxRoot:a.expression.expression}:e={viewModel:o,jsxRoot:a.expression})}}I.forEachChild(n,r)}return r(t),e}function Mu(t,e,r,n={}){let i=new Set(Jt);for(let f of n.allowlistExtra??[])i.add(f);let o=Ou(e),s=Au(o),a=I.createSourceFile(o,t,I.ScriptTarget.Latest,!0,I.ScriptKind.TSX),l={vmName:"vm",scopes:[],propBindings:{},errors:[],warnings:[],viewImports:Ms(a,s),allowedComponents:i},u=qy(a);if(!u)return{viewModel:"unknown",exportName:r,root:{kind:"fragment",children:[]},errors:["No screen<T>() default export found"],warnings:[]};let p=I.isJsxElement(u.jsxRoot)||I.isJsxSelfClosingElement(u.jsxRoot)?un(u.jsxRoot,l):I.isJsxFragment(u.jsxRoot)?Vs(u.jsxRoot,l):null;return p?{viewModel:u.viewModel,exportName:r,root:p,errors:l.errors,warnings:l.warnings}:(l.errors.push("screen() callback must return a single JSX root element"),{viewModel:u.viewModel,exportName:r,root:{kind:"fragment",children:[]},errors:l.errors,warnings:l.warnings})}function Fy(t,e){let r={...e.propBindings};for(let i of t.propNames)r[i]={kind:"binding",path:"",scope:i};let n={...e,vmName:t.paramName,propBindings:r,scopes:[]};return I.isJsxElement(t.jsxRoot)||I.isJsxSelfClosingElement(t.jsxRoot)?un(t.jsxRoot,n):I.isJsxFragment(t.jsxRoot)?Vs(t.jsxRoot,n):I.isConditionalExpression(t.jsxRoot)?(e.errors.push("view() partial root must be a JSX element or fragment; conditional expressions are not supported"),null):I.isExpression(t.jsxRoot)?(e.errors.push(`view() partial root must be a JSX element or fragment; unsupported expression: ${Er(t.jsxRoot)}`),null):(e.errors.push(`view() partial root must be a JSX element or fragment; unsupported syntax kind: ${I.SyntaxKind[t.jsxRoot.kind]}`),null)}function Lu(t,e,r,n={}){let i=new Set(Jt);for(let f of n.allowlistExtra??[])i.add(f);let o=Ou(e),s=Au(o),a=I.createSourceFile(o,t,I.ScriptTarget.Latest,!0,I.ScriptKind.TSX),l=Ls(a,r),u={vmName:l?.paramName??"__noop",scopes:[],propBindings:{},errors:[],warnings:[],viewImports:Ms(a,s),allowedComponents:i};if(!l)return{exportName:r,propNames:[],root:{kind:"fragment",children:[]},errors:[`No view() export "${r}" found in ${e}`],warnings:[]};let p=Fy(l,u);return p?{exportName:r,propsType:l.propsType,propNames:l.propNames,root:p,errors:u.errors,warnings:u.warnings}:{exportName:r,propsType:l.propsType,propNames:l.propNames,root:{kind:"fragment",children:[]},errors:u.errors,warnings:u.warnings}}function qs(t){let e=[];function r(n){if(n.kind==="viewRef"){e.push(n);return}if(n.kind==="component"){for(let i of n.children)r(i);return}if(n.kind==="map"){r(n.body);return}if(n.kind==="fragment")for(let i of n.children)r(i)}return r(t),e}function ju(t){return`${t.sourcePath}:${t.name}`}function Fs(t,e){let r=[],n=[],i=o=>{if(o.kind!=="viewRef"){if(o.kind==="component"){!Jt.has(o.name)&&!(o.name in e.extensions)&&r.push(`Extension component "${o.name}" is not registered in extensions.yaml`);for(let s of o.children)i(s);return}if(o.kind==="map"){i(o.body);return}if(o.kind==="fragment")for(let s of o.children)i(s)}};return i(t),{errors:r,warnings:n}}async function By(t,e,r){let n=await Du(t,"utf-8"),i=Lu(n,t,e,{allowlistExtra:r.allowlistExtra});if(i.errors.length>0)throw new Error(`Compile errors in ${t} (${e}):
|
|
462
|
+
${i.errors.map(o=>` - ${o}`).join(`
|
|
463
|
+
`)}`);if(r.extensionRegistry){let o=Fs(i.root,r.extensionRegistry);if(o.errors.length>0)throw new Error(`Extension validation errors in ${t} (${e}):
|
|
464
|
+
${o.errors.map(s=>` - ${s}`).join(`
|
|
465
|
+
`)}`);i.warnings.push(...o.warnings)}for(let o of i.warnings)console.warn(`Warning in ${t} (${e}): ${o}`);return{version:1,source:Vu(process.cwd(),qu(t)),viewModel:i.propsType??"Record<string, unknown>",exportName:i.exportName,root:i.root,isPartial:!0,propsType:i.propsType}}async function Uy(t,e){let r=new Map,n=qs(t);for(;n.length>0;){let i=n.shift(),o=ju(i);if(r.has(o))continue;let s=await By(i.sourcePath,i.name,e);r.set(o,s),n.push(...qs(s.root))}return[...r.values()]}async function Gy(t,e={}){let r=await Du(t.sourcePath,"utf-8"),n=t.exportName??Hy(t.sourcePath,".view.tsx"),i=Mu(r,t.sourcePath,n,{allowlistExtra:e.allowlistExtra});if(i.errors.length>0)throw new Error(`Compile errors in ${t.sourcePath}:
|
|
466
|
+
${i.errors.map(a=>` - ${a}`).join(`
|
|
467
|
+
`)}`);if(e.extensionRegistry){let a=Fs(i.root,e.extensionRegistry);if(a.errors.length>0)throw new Error(`Extension validation errors in ${t.sourcePath}:
|
|
468
|
+
${a.errors.map(l=>` - ${l}`).join(`
|
|
469
|
+
`)}`);i.warnings.push(...a.warnings)}for(let a of i.warnings)console.warn(`Warning in ${t.sourcePath}: ${a}`);let o={version:1,source:Vu(process.cwd(),qu(t.sourcePath)),viewModel:i.viewModel,exportName:i.exportName,root:i.root},s=await Uy(o.root,e);return{screen:o,partials:s}}async function Fu(t,e={}){let r=[],n=new Map;for(let i of t){let o=await Gy(i,e);r.push(o.screen);for(let s of o.partials){let a=`${s.source}:${s.exportName}`;n.set(a,s)}}return{screens:r,partials:[...n.values()]}}import{access as rv,readFile as cf}from"node:fs/promises";import{dirname as lf,relative as IP,resolve as me}from"node:path";var Wy=Object.create,Hu=Object.defineProperty,zy=Object.getOwnPropertyDescriptor,Ky=Object.getOwnPropertyNames,Jy=Object.getPrototypeOf,Yy=Object.prototype.hasOwnProperty,le=(t,e)=>()=>(e||(t((e={exports:{}}).exports,e),t=null),e.exports),Xy=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(var i=Ky(e),o=0,s=i.length,a;o<s;o++)a=i[o],!Yy.call(t,a)&&a!==r&&Hu(t,a,{get:(l=>e[l]).bind(null,a),enumerable:!(n=zy(e,a))||n.enumerable});return t},Qy=(t,e,r)=>(r=t!=null?Wy(Jy(t)):{},Xy(e||!t||!t.__esModule?Hu(r,"default",{value:t,enumerable:!0}):r,t)),fn=le(((t,e)=>{function r(l){return typeof l>"u"||l===null}function n(l){return typeof l=="object"&&l!==null}function i(l){return Array.isArray(l)?l:r(l)?[]:[l]}function o(l,u){if(u){let p=Object.keys(u);for(let f=0,h=p.length;f<h;f+=1){let m=p[f];l[m]=u[m]}}return l}function s(l,u){let p="";for(let f=0;f<u;f+=1)p+=l;return p}function a(l){return l===0&&Number.NEGATIVE_INFINITY===1/l}e.exports.isNothing=r,e.exports.isObject=n,e.exports.toArray=i,e.exports.repeat=s,e.exports.isNegativeZero=a,e.exports.extend=o})),pn=le(((t,e)=>{function r(i,o){let s="",a=i.reason||"(unknown reason)";return i.mark?(i.mark.name&&(s+='in "'+i.mark.name+'" '),s+="("+(i.mark.line+1)+":"+(i.mark.column+1)+")",!o&&i.mark.snippet&&(s+=`
|
|
466
470
|
|
|
467
|
-
`+i.mark.snippet),a+" "+
|
|
468
|
-
`+m}let
|
|
469
|
-
`,m+=r.repeat("-",a.indent+g+3+
|
|
470
|
-
`;for(let
|
|
471
|
-
`}return m.replace(/\n$/,"")}e.exports=
|
|
472
|
-
\r`;function i(l){if(l===null)return!1;let u=0,
|
|
473
|
-
`;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"\x85";case 95:return"\xA0";case 76:return"\u2028";case 80:return"\u2029";default:return""}}function
|
|
474
|
-
`,y-1))}function
|
|
475
|
-
`,
|
|
476
|
-
`);break}
|
|
477
|
-
`,
|
|
478
|
-
`,
|
|
479
|
-
`,
|
|
480
|
-
`,
|
|
481
|
-
`),c.charCodeAt(0)===65279&&(c=c.slice(1)));let
|
|
482
|
-
`,$);
|
|
483
|
-
`&&(
|
|
484
|
-
`+r.repeat(" ",
|
|
485
|
-
`;return
|
|
486
|
-
`||
|
|
471
|
+
`+i.mark.snippet),a+" "+s):a}function n(i,o){Error.call(this),this.name="YAMLException",this.reason=i,this.mark=o,this.message=r(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n.prototype.toString=function(o){return this.name+": "+r(this,o)},e.exports=n})),Zy=le(((t,e)=>{var r=fn();function n(s,a,l,u,p){let f="",h="",m=Math.floor(p/2)-1;return u-a>m&&(f=" ... ",a=u-m+f.length),l-u>m&&(h=" ...",l=u+m-h.length),{str:f+s.slice(a,l).replace(/\t/g,"\u2192")+h,pos:u-a+f.length}}function i(s,a){return r.repeat(" ",a-s.length)+s}function o(s,a){if(a=Object.create(a||null),!s.buffer)return null;a.maxLength||(a.maxLength=79),typeof a.indent!="number"&&(a.indent=1),typeof a.linesBefore!="number"&&(a.linesBefore=3),typeof a.linesAfter!="number"&&(a.linesAfter=2);let l=/\r?\n|\r|\0/g,u=[0],p=[],f,h=-1;for(;f=l.exec(s.buffer);)p.push(f.index),u.push(f.index+f[0].length),s.position<=f.index&&h<0&&(h=u.length-2);h<0&&(h=u.length-1);let m="",g=Math.min(s.line+a.linesAfter,p.length).toString().length,v=a.maxLength-(a.indent+g+3);for(let b=1;b<=a.linesBefore&&!(h-b<0);b++){let j=n(s.buffer,u[h-b],p[h-b],s.position-(u[h]-u[h-b]),v);m=r.repeat(" ",a.indent)+i((s.line-b+1).toString(),g)+" | "+j.str+`
|
|
472
|
+
`+m}let P=n(s.buffer,u[h],p[h],s.position,v);m+=r.repeat(" ",a.indent)+i((s.line+1).toString(),g)+" | "+P.str+`
|
|
473
|
+
`,m+=r.repeat("-",a.indent+g+3+P.pos)+`^
|
|
474
|
+
`;for(let b=1;b<=a.linesAfter&&!(h+b>=p.length);b++){let j=n(s.buffer,u[h+b],p[h+b],s.position-(u[h]-u[h+b]),v);m+=r.repeat(" ",a.indent)+i((s.line+b+1).toString(),g)+" | "+j.str+`
|
|
475
|
+
`}return m.replace(/\n$/,"")}e.exports=o})),Oe=le(((t,e)=>{var r=pn(),n=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],i=["scalar","sequence","mapping"];function o(a){let l={};return a!==null&&Object.keys(a).forEach(function(u){a[u].forEach(function(p){l[String(p)]=u})}),l}function s(a,l){if(l=l||{},Object.keys(l).forEach(function(u){if(n.indexOf(u)===-1)throw new r('Unknown option "'+u+'" is met in definition of "'+a+'" YAML type.')}),this.options=l,this.tag=a,this.kind=l.kind||null,this.resolve=l.resolve||function(){return!0},this.construct=l.construct||function(u){return u},this.instanceOf=l.instanceOf||null,this.predicate=l.predicate||null,this.represent=l.represent||null,this.representName=l.representName||null,this.defaultStyle=l.defaultStyle||null,this.multi=l.multi||!1,this.styleAliases=o(l.styleAliases||null),i.indexOf(this.kind)===-1)throw new r('Unknown kind "'+this.kind+'" is specified for "'+a+'" YAML type.')}e.exports=s})),Bu=le(((t,e)=>{var r=pn(),n=Oe();function i(a,l){let u=[];return a[l].forEach(function(p){let f=u.length;u.forEach(function(h,m){h.tag===p.tag&&h.kind===p.kind&&h.multi===p.multi&&(f=m)}),u[f]=p}),u}function o(){let a={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function l(u){u.multi?(a.multi[u.kind].push(u),a.multi.fallback.push(u)):a[u.kind][u.tag]=a.fallback[u.tag]=u}for(let u=0,p=arguments.length;u<p;u+=1)arguments[u].forEach(l);return a}function s(a){return this.extend(a)}s.prototype.extend=function(l){let u=[],p=[];if(l instanceof n)p.push(l);else if(Array.isArray(l))p=p.concat(l);else if(l&&(Array.isArray(l.implicit)||Array.isArray(l.explicit)))l.implicit&&(u=u.concat(l.implicit)),l.explicit&&(p=p.concat(l.explicit));else throw new r("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");u.forEach(function(h){if(!(h instanceof n))throw new r("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(h.loadKind&&h.loadKind!=="scalar")throw new r("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(h.multi)throw new r("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),p.forEach(function(h){if(!(h instanceof n))throw new r("Specified list of YAML types (or a single Type object) contains a non-Type object.")});let f=Object.create(s.prototype);return f.implicit=(this.implicit||[]).concat(u),f.explicit=(this.explicit||[]).concat(p),f.compiledImplicit=i(f,"implicit"),f.compiledExplicit=i(f,"explicit"),f.compiledTypeMap=o(f.compiledImplicit,f.compiledExplicit),f},e.exports=s})),Uu=le(((t,e)=>{e.exports=new(Oe())("tag:yaml.org,2002:str",{kind:"scalar",construct:function(r){return r!==null?r:""}})})),Gu=le(((t,e)=>{e.exports=new(Oe())("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(r){return r!==null?r:[]}})})),Wu=le(((t,e)=>{e.exports=new(Oe())("tag:yaml.org,2002:map",{kind:"mapping",construct:function(r){return r!==null?r:{}}})})),zu=le(((t,e)=>{e.exports=new(Bu())({explicit:[Uu(),Gu(),Wu()]})})),Ku=le(((t,e)=>{var r=Oe();function n(s){if(s===null)return!0;let a=s.length;return a===1&&s==="~"||a===4&&(s==="null"||s==="Null"||s==="NULL")}function i(){return null}function o(s){return s===null}e.exports=new r("tag:yaml.org,2002:null",{kind:"scalar",resolve:n,construct:i,predicate:o,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"})})),Ju=le(((t,e)=>{var r=Oe();function n(s){if(s===null)return!1;let a=s.length;return a===4&&(s==="true"||s==="True"||s==="TRUE")||a===5&&(s==="false"||s==="False"||s==="FALSE")}function i(s){return s==="true"||s==="True"||s==="TRUE"}function o(s){return Object.prototype.toString.call(s)==="[object Boolean]"}e.exports=new r("tag:yaml.org,2002:bool",{kind:"scalar",resolve:n,construct:i,predicate:o,represent:{lowercase:function(s){return s?"true":"false"},uppercase:function(s){return s?"TRUE":"FALSE"},camelcase:function(s){return s?"True":"False"}},defaultStyle:"lowercase"})})),Yu=le(((t,e)=>{var r=fn(),n=Oe();function i(f){return f>=48&&f<=57||f>=65&&f<=70||f>=97&&f<=102}function o(f){return f>=48&&f<=55}function s(f){return f>=48&&f<=57}function a(f){if(f===null)return!1;let h=f.length,m=0,g=!1;if(!h)return!1;let v=f[m];if((v==="-"||v==="+")&&(v=f[++m]),v==="0"){if(m+1===h)return!0;if(v=f[++m],v==="b"){for(m++;m<h;m++){if(v=f[m],v!=="0"&&v!=="1")return!1;g=!0}return g&&Number.isFinite(l(f))}if(v==="x"){for(m++;m<h;m++){if(!i(f.charCodeAt(m)))return!1;g=!0}return g&&Number.isFinite(l(f))}if(v==="o"){for(m++;m<h;m++){if(!o(f.charCodeAt(m)))return!1;g=!0}return g&&Number.isFinite(l(f))}}for(;m<h;m++){if(!s(f.charCodeAt(m)))return!1;g=!0}return g?Number.isFinite(l(f)):!1}function l(f){let h=f,m=1,g=h[0];if((g==="-"||g==="+")&&(g==="-"&&(m=-1),h=h.slice(1),g=h[0]),h==="0")return 0;if(g==="0"){if(h[1]==="b")return m*parseInt(h.slice(2),2);if(h[1]==="x")return m*parseInt(h.slice(2),16);if(h[1]==="o")return m*parseInt(h.slice(2),8)}return m*parseInt(h,10)}function u(f){return l(f)}function p(f){return Object.prototype.toString.call(f)==="[object Number]"&&f%1===0&&!r.isNegativeZero(f)}e.exports=new n("tag:yaml.org,2002:int",{kind:"scalar",resolve:a,construct:u,predicate:p,represent:{binary:function(f){return f>=0?"0b"+f.toString(2):"-0b"+f.toString(2).slice(1)},octal:function(f){return f>=0?"0o"+f.toString(8):"-0o"+f.toString(8).slice(1)},decimal:function(f){return f.toString(10)},hexadecimal:function(f){return f>=0?"0x"+f.toString(16).toUpperCase():"-0x"+f.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})})),Xu=le(((t,e)=>{var r=fn(),n=Oe(),i=new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),o=new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function s(f){return f===null||!i.test(f)?!1:Number.isFinite(parseFloat(f,10))?!0:o.test(f)}function a(f){let h=f.toLowerCase(),m=h[0]==="-"?-1:1;return"+-".indexOf(h[0])>=0&&(h=h.slice(1)),h===".inf"?m===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:h===".nan"?NaN:m*parseFloat(h,10)}var l=/^[-+]?[0-9]+e/;function u(f,h){if(isNaN(f))switch(h){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===f)switch(h){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===f)switch(h){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(r.isNegativeZero(f))return"-0.0";let m=f.toString(10);return l.test(m)?m.replace("e",".e"):m}function p(f){return Object.prototype.toString.call(f)==="[object Number]"&&(f%1!==0||r.isNegativeZero(f))}e.exports=new n("tag:yaml.org,2002:float",{kind:"scalar",resolve:s,construct:a,predicate:p,represent:u,defaultStyle:"lowercase"})})),Qu=le(((t,e)=>{e.exports=zu().extend({implicit:[Ku(),Ju(),Yu(),Xu()]})})),Zu=le(((t,e)=>{e.exports=Qu()})),ef=le(((t,e)=>{var r=Oe(),n=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),i=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function o(l){return l===null?!1:n.exec(l)!==null||i.exec(l)!==null}function s(l){let u=0,p=null,f=n.exec(l);if(f===null&&(f=i.exec(l)),f===null)throw new Error("Date resolve error");let h=+f[1],m=+f[2]-1,g=+f[3];if(!f[4])return new Date(Date.UTC(h,m,g));let v=+f[4],P=+f[5],b=+f[6];if(f[7]){for(u=f[7].slice(0,3);u.length<3;)u+="0";u=+u}if(f[9]){let B=+f[10],L=+(f[11]||0);p=(B*60+L)*6e4,f[9]==="-"&&(p=-p)}let j=new Date(Date.UTC(h,m,g,v,P,b,u));return p&&j.setTime(j.getTime()-p),j}function a(l){return l.toISOString()}e.exports=new r("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:o,construct:s,instanceOf:Date,represent:a})})),tf=le(((t,e)=>{var r=Oe();function n(i){return i==="<<"||i===null}e.exports=new r("tag:yaml.org,2002:merge",{kind:"scalar",resolve:n})})),rf=le(((t,e)=>{var r=Oe(),n=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
476
|
+
\r`;function i(l){if(l===null)return!1;let u=0,p=l.length,f=n;for(let h=0;h<p;h++){let m=f.indexOf(l.charAt(h));if(!(m>64)){if(m<0)return!1;u+=6}}return u%8===0}function o(l){let u=l.replace(/[\r\n=]/g,""),p=u.length,f=n,h=0,m=[];for(let v=0;v<p;v++)v%4===0&&v&&(m.push(h>>16&255),m.push(h>>8&255),m.push(h&255)),h=h<<6|f.indexOf(u.charAt(v));let g=p%4*6;return g===0?(m.push(h>>16&255),m.push(h>>8&255),m.push(h&255)):g===18?(m.push(h>>10&255),m.push(h>>2&255)):g===12&&m.push(h>>4&255),new Uint8Array(m)}function s(l){let u="",p=0,f=l.length,h=n;for(let g=0;g<f;g++)g%3===0&&g&&(u+=h[p>>18&63],u+=h[p>>12&63],u+=h[p>>6&63],u+=h[p&63]),p=(p<<8)+l[g];let m=f%3;return m===0?(u+=h[p>>18&63],u+=h[p>>12&63],u+=h[p>>6&63],u+=h[p&63]):m===2?(u+=h[p>>10&63],u+=h[p>>4&63],u+=h[p<<2&63],u+=h[64]):m===1&&(u+=h[p>>2&63],u+=h[p<<4&63],u+=h[64],u+=h[64]),u}function a(l){return Object.prototype.toString.call(l)==="[object Uint8Array]"}e.exports=new r("tag:yaml.org,2002:binary",{kind:"scalar",resolve:i,construct:o,predicate:a,represent:s})})),nf=le(((t,e)=>{var r=Oe(),n=Object.prototype.hasOwnProperty,i=Object.prototype.toString;function o(a){if(a===null)return!0;let l=[],u=a;for(let p=0,f=u.length;p<f;p+=1){let h=u[p],m=!1;if(i.call(h)!=="[object Object]")return!1;let g;for(g in h)if(n.call(h,g))if(!m)m=!0;else return!1;if(!m)return!1;if(l.indexOf(g)===-1)l.push(g);else return!1}return!0}function s(a){return a!==null?a:[]}e.exports=new r("tag:yaml.org,2002:omap",{kind:"sequence",resolve:o,construct:s})})),of=le(((t,e)=>{var r=Oe(),n=Object.prototype.toString;function i(s){if(s===null)return!0;let a=s,l=new Array(a.length);for(let u=0,p=a.length;u<p;u+=1){let f=a[u];if(n.call(f)!=="[object Object]")return!1;let h=Object.keys(f);if(h.length!==1)return!1;l[u]=[h[0],f[h[0]]]}return!0}function o(s){if(s===null)return[];let a=s,l=new Array(a.length);for(let u=0,p=a.length;u<p;u+=1){let f=a[u],h=Object.keys(f);l[u]=[h[0],f[h[0]]]}return l}e.exports=new r("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:i,construct:o})})),sf=le(((t,e)=>{var r=Oe(),n=Object.prototype.hasOwnProperty;function i(s){if(s===null)return!0;let a=s;for(let l in a)if(n.call(a,l)&&a[l]!==null)return!1;return!0}function o(s){return s!==null?s:{}}e.exports=new r("tag:yaml.org,2002:set",{kind:"mapping",resolve:i,construct:o})})),Hs=le(((t,e)=>{e.exports=Zu().extend({implicit:[ef(),tf()],explicit:[rf(),nf(),of(),sf()]})})),ev=le(((t,e)=>{var r=fn(),n=pn(),i=Zy(),o=Hs(),s=Object.prototype.hasOwnProperty,a=1,l=2,u=3,p=4,f=1,h=2,m=3,g=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,v=/[\x85\u2028\u2029]/,P=/[,\[\]{}]/,b=/^(?:!|!!|![0-9A-Za-z-]+!)$/,j=/^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;function B(c){return Object.prototype.toString.call(c)}function L(c){return c===10||c===13}function T(c){return c===9||c===32}function Q(c){return c===9||c===32||c===10||c===13}function ne(c){return c===44||c===91||c===93||c===123||c===125}function Nt(c){if(c>=48&&c<=57)return c-48;let y=c|32;return y>=97&&y<=102?y-97+10:-1}function et(c){return c===120?2:c===117?4:c===85?8:0}function be(c){return c>=48&&c<=57?c-48:-1}function Ne(c){switch(c){case 48:return"\0";case 97:return"\x07";case 98:return"\b";case 116:return" ";case 9:return" ";case 110:return`
|
|
477
|
+
`;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"\x85";case 95:return"\xA0";case 76:return"\u2028";case 80:return"\u2029";default:return""}}function xe(c){return c<=65535?String.fromCharCode(c):String.fromCharCode((c-65536>>10)+55296,(c-65536&1023)+56320)}function tt(c,y,E){y==="__proto__"?Object.defineProperty(c,y,{configurable:!0,enumerable:!0,writable:!0,value:E}):c[y]=E}var rt=new Array(256),_t=new Array(256);for(let c=0;c<256;c++)rt[c]=Ne(c)?1:0,_t[c]=Ne(c);function se(c,y){this.input=c,this.filename=y.filename||null,this.schema=y.schema||o,this.onWarning=y.onWarning||null,this.legacy=y.legacy||!1,this.json=y.json||!1,this.listener=y.listener||null,this.maxDepth=typeof y.maxDepth=="number"?y.maxDepth:100,this.maxMergeSeqLength=typeof y.maxMergeSeqLength=="number"?y.maxMergeSeqLength:20,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=c.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}function hi(c,y){let E={name:c.filename,buffer:c.input.slice(0,-1),position:c.position,line:c.line,column:c.position-c.lineStart};return E.snippet=i(E),new n(y,E)}function V(c,y){throw hi(c,y)}function _r(c,y){c.onWarning&&c.onWarning.call(null,hi(c,y))}function wt(c,y,E){let C=c.anchorMapTransactions;if(C.length!==0){let S=C[C.length-1];s.call(S,y)||(S[y]={existed:s.call(c.anchorMap,y),value:c.anchorMap[y]})}c.anchorMap[y]=E}function ps(c){c.anchorMapTransactions.push(Object.create(null))}function Kt(c){let y=c.anchorMapTransactions.pop(),E=c.anchorMapTransactions;if(E.length===0)return;let C=E[E.length-1],S=Object.keys(y);for(let R=0,d=S.length;R<d;R+=1){let _=S[R];s.call(C,_)||(C[_]=y[_])}}function ds(c){let y=c.anchorMapTransactions.pop(),E=Object.keys(y);for(let C=E.length-1;C>=0;C-=1){let S=y[E[C]];S.existed?c.anchorMap[E[C]]=S.value:delete c.anchorMap[E[C]]}}function on(c){return{position:c.position,line:c.line,lineStart:c.lineStart,lineIndent:c.lineIndent,firstTabInLine:c.firstTabInLine,tag:c.tag,anchor:c.anchor,kind:c.kind,result:c.result}}function wr(c,y){c.position=y.position,c.line=y.line,c.lineStart=y.lineStart,c.lineIndent=y.lineIndent,c.firstTabInLine=y.firstTabInLine,c.tag=y.tag,c.anchor=y.anchor,c.kind=y.kind,c.result=y.result}var mi={YAML:function(y,E,C){y.version!==null&&V(y,"duplication of %YAML directive"),C.length!==1&&V(y,"YAML directive accepts exactly one argument");let S=/^([0-9]+)\.([0-9]+)$/.exec(C[0]);S===null&&V(y,"ill-formed argument of the YAML directive");let R=parseInt(S[1],10),d=parseInt(S[2],10);R!==1&&V(y,"unacceptable YAML version of the document"),y.version=C[0],y.checkLineBreaks=d<2,d!==1&&d!==2&&_r(y,"unsupported YAML version of the document")},TAG:function(y,E,C){let S;C.length!==2&&V(y,"TAG directive accepts exactly two arguments");let R=C[0];S=C[1],b.test(R)||V(y,"ill-formed tag handle (first argument) of the TAG directive"),s.call(y.tagMap,R)&&V(y,'there is a previously declared suffix for "'+R+'" tag handle'),j.test(S)||V(y,"ill-formed tag prefix (second argument) of the TAG directive");try{S=decodeURIComponent(S)}catch{V(y,"tag prefix is malformed: "+S)}y.tagMap[R]=S}};function Ve(c,y,E,C){if(y<E){let S=c.input.slice(y,E);if(C)for(let R=0,d=S.length;R<d;R+=1){let _=S.charCodeAt(R);_===9||_>=32&&_<=1114111||V(c,"expected valid JSON character")}else g.test(S)&&V(c,"the stream contains non-printable characters");c.result+=S}}function Mt(c,y,E,C){r.isObject(E)||V(c,"cannot merge mappings; the provided source object is unacceptable");let S=Object.keys(E);for(let R=0,d=S.length;R<d;R+=1){let _=S[R];s.call(y,_)||(tt(y,_,E[_]),C[_]=!0)}}function bt(c,y,E,C,S,R,d,_,O){if(Array.isArray(S)){S=Array.prototype.slice.call(S);for(let $=0,x=S.length;$<x;$+=1)Array.isArray(S[$])&&V(c,"nested arrays are not supported inside keys"),typeof S=="object"&&B(S[$])==="[object Object]"&&(S[$]="[object Object]")}if(typeof S=="object"&&B(S)==="[object Object]"&&(S="[object Object]"),S=String(S),y===null&&(y={}),C==="tag:yaml.org,2002:merge")if(Array.isArray(R)){R.length>c.maxMergeSeqLength&&V(c,"merge sequence length exceeded maxMergeSeqLength ("+c.maxMergeSeqLength+")");let $=new Set;for(let x=0,A=R.length;x<A;x+=1){let k=R[x];$.has(k)||($.add(k),Mt(c,y,k,E))}}else Mt(c,y,R,E);else!c.json&&!s.call(E,S)&&s.call(y,S)&&(c.line=d||c.line,c.lineStart=_||c.lineStart,c.position=O||c.position,V(c,"duplicated mapping key")),tt(y,S,R),delete E[S];return y}function br(c){let y=c.input.charCodeAt(c.position);y===10?c.position++:y===13?(c.position++,c.input.charCodeAt(c.position)===10&&c.position++):V(c,"a line break is expected"),c.line+=1,c.lineStart=c.position,c.firstTabInLine=-1}function he(c,y,E){let C=0,S=c.input.charCodeAt(c.position);for(;S!==0;){for(;T(S);)S===9&&c.firstTabInLine===-1&&(c.firstTabInLine=c.position),S=c.input.charCodeAt(++c.position);if(y&&S===35)do S=c.input.charCodeAt(++c.position);while(S!==10&&S!==13&&S!==0);if(L(S))for(br(c),S=c.input.charCodeAt(c.position),C++,c.lineIndent=0;S===32;)c.lineIndent++,S=c.input.charCodeAt(++c.position);else break}return E!==-1&&C!==0&&c.lineIndent<E&&_r(c,"deficient indentation"),C}function Sr(c){let y=c.position,E=c.input.charCodeAt(y);return!!((E===45||E===46)&&E===c.input.charCodeAt(y+1)&&E===c.input.charCodeAt(y+2)&&(y+=3,E=c.input.charCodeAt(y),E===0||Q(E)))}function St(c,y){y===1?c.result+=" ":y>1&&(c.result+=r.repeat(`
|
|
478
|
+
`,y-1))}function gi(c,y,E){let C,S,R,d,_,O,$=c.kind,x=c.result,A=c.input.charCodeAt(c.position);if(Q(A)||ne(A)||A===35||A===38||A===42||A===33||A===124||A===62||A===39||A===34||A===37||A===64||A===96)return!1;if(A===63||A===45){let k=c.input.charCodeAt(c.position+1);if(Q(k)||E&&ne(k))return!1}for(c.kind="scalar",c.result="",C=S=c.position,R=!1;A!==0;){if(A===58){let k=c.input.charCodeAt(c.position+1);if(Q(k)||E&&ne(k))break}else if(A===35){if(Q(c.input.charCodeAt(c.position-1)))break}else{if(c.position===c.lineStart&&Sr(c)||E&&ne(A))break;if(L(A))if(d=c.line,_=c.lineStart,O=c.lineIndent,he(c,!1,-1),c.lineIndent>=y){R=!0,A=c.input.charCodeAt(c.position);continue}else{c.position=S,c.line=d,c.lineStart=_,c.lineIndent=O;break}}R&&(Ve(c,C,S,!1),St(c,c.line-d),C=S=c.position,R=!1),T(A)||(S=c.position+1),A=c.input.charCodeAt(++c.position)}return Ve(c,C,S,!1),c.result?!0:(c.kind=$,c.result=x,!1)}function yi(c,y){let E,C,S=c.input.charCodeAt(c.position);if(S!==39)return!1;for(c.kind="scalar",c.result="",c.position++,E=C=c.position;(S=c.input.charCodeAt(c.position))!==0;)if(S===39)if(Ve(c,E,c.position,!0),S=c.input.charCodeAt(++c.position),S===39)E=c.position,c.position++,C=c.position;else return!0;else L(S)?(Ve(c,E,C,!0),St(c,he(c,!1,y)),E=C=c.position):c.position===c.lineStart&&Sr(c)?V(c,"unexpected end of the document within a single quoted scalar"):(c.position++,T(S)||(C=c.position));V(c,"unexpected end of the stream within a single quoted scalar")}function sn(c,y){let E,C,S,R=c.input.charCodeAt(c.position);if(R!==34)return!1;for(c.kind="scalar",c.result="",c.position++,E=C=c.position;(R=c.input.charCodeAt(c.position))!==0;){if(R===34)return Ve(c,E,c.position,!0),c.position++,!0;if(R===92){if(Ve(c,E,c.position,!0),R=c.input.charCodeAt(++c.position),L(R))he(c,!1,y);else if(R<256&&rt[R])c.result+=_t[R],c.position++;else if((S=et(R))>0){let d=S,_=0;for(;d>0;d--)R=c.input.charCodeAt(++c.position),(S=Nt(R))>=0?_=(_<<4)+S:V(c,"expected hexadecimal character");c.result+=xe(_),c.position++}else V(c,"unknown escape sequence");E=C=c.position}else L(R)?(Ve(c,E,C,!0),St(c,he(c,!1,y)),E=C=c.position):c.position===c.lineStart&&Sr(c)?V(c,"unexpected end of the document within a double quoted scalar"):(c.position++,T(R)||(C=c.position))}V(c,"unexpected end of the stream within a double quoted scalar")}function vi(c,y){let E=!0,C,S,R,d=c.tag,_,O=c.anchor,$,x,A,k,M=Object.create(null),N,F,U,Z=c.input.charCodeAt(c.position);if(Z===91)$=93,k=!1,_=[];else if(Z===123)$=125,k=!0,_={};else return!1;for(c.anchor!==null&&wt(c,c.anchor,_),Z=c.input.charCodeAt(++c.position);Z!==0;){if(he(c,!0,y),Z=c.input.charCodeAt(c.position),Z===$)return c.position++,c.tag=d,c.anchor=O,c.kind=k?"mapping":"sequence",c.result=_,!0;E?Z===44&&V(c,"expected the node content, but found ','"):V(c,"missed comma between flow collection entries"),F=N=U=null,x=A=!1,Z===63&&Q(c.input.charCodeAt(c.position+1))&&(x=A=!0,c.position++,he(c,!0,y)),C=c.line,S=c.lineStart,R=c.position,$t(c,y,a,!1,!0),F=c.tag,N=c.result,he(c,!0,y),Z=c.input.charCodeAt(c.position),(A||c.line===C)&&Z===58&&(x=!0,Z=c.input.charCodeAt(++c.position),he(c,!0,y),$t(c,y,a,!1,!0),U=c.result),k?bt(c,_,M,F,N,U,C,S,R):x?_.push(bt(c,null,M,F,N,U,C,S,R)):_.push(N),he(c,!0,y),Z=c.input.charCodeAt(c.position),Z===44?(E=!0,Z=c.input.charCodeAt(++c.position)):E=!1}V(c,"unexpected end of the stream within a flow collection")}function _i(c,y){let E,C=f,S=!1,R=!1,d=y,_=0,O=!1,$,x=c.input.charCodeAt(c.position);if(x===124)E=!1;else if(x===62)E=!0;else return!1;for(c.kind="scalar",c.result="";x!==0;)if(x=c.input.charCodeAt(++c.position),x===43||x===45)f===C?C=x===43?m:h:V(c,"repeat of a chomping mode identifier");else if(($=be(x))>=0)$===0?V(c,"bad explicit indentation width of a block scalar; it cannot be less than one"):R?V(c,"repeat of an indentation width identifier"):(d=y+$-1,R=!0);else break;if(T(x)){do x=c.input.charCodeAt(++c.position);while(T(x));if(x===35)do x=c.input.charCodeAt(++c.position);while(!L(x)&&x!==0)}for(;x!==0;){for(br(c),c.lineIndent=0,x=c.input.charCodeAt(c.position);(!R||c.lineIndent<d)&&x===32;)c.lineIndent++,x=c.input.charCodeAt(++c.position);if(!R&&c.lineIndent>d&&(d=c.lineIndent),L(x)){_++;continue}if(!R&&d===0&&V(c,"missing indentation for block scalar"),c.lineIndent<d){C===m?c.result+=r.repeat(`
|
|
479
|
+
`,S?1+_:_):C===f&&S&&(c.result+=`
|
|
480
|
+
`);break}E?T(x)?(O=!0,c.result+=r.repeat(`
|
|
481
|
+
`,S?1+_:_)):O?(O=!1,c.result+=r.repeat(`
|
|
482
|
+
`,_+1)):_===0?S&&(c.result+=" "):c.result+=r.repeat(`
|
|
483
|
+
`,_):c.result+=r.repeat(`
|
|
484
|
+
`,S?1+_:_),S=!0,R=!0,_=0;let A=c.position;for(;!L(x)&&x!==0;)x=c.input.charCodeAt(++c.position);Ve(c,A,c.position,!1)}return!0}function Et(c,y){let E=c.tag,C=c.anchor,S=[],R=!1;if(c.firstTabInLine!==-1)return!1;c.anchor!==null&&wt(c,c.anchor,S);let d=c.input.charCodeAt(c.position);for(;d!==0&&(c.firstTabInLine!==-1&&(c.position=c.firstTabInLine,V(c,"tab characters must not be used in indentation")),!(d!==45||!Q(c.input.charCodeAt(c.position+1))));){if(R=!0,c.position++,he(c,!0,-1)&&c.lineIndent<=y){S.push(null),d=c.input.charCodeAt(c.position);continue}let _=c.line;if($t(c,y,u,!1,!0),S.push(c.result),he(c,!0,-1),d=c.input.charCodeAt(c.position),(c.line===_||c.lineIndent>y)&&d!==0)V(c,"bad indentation of a sequence entry");else if(c.lineIndent<y)break}return R?(c.tag=E,c.anchor=C,c.kind="sequence",c.result=S,!0):!1}function wi(c,y,E){let C,S,R,d,_=c.tag,O=c.anchor,$={},x=Object.create(null),A=null,k=null,M=null,N=!1,F=!1;if(c.firstTabInLine!==-1)return!1;c.anchor!==null&&wt(c,c.anchor,$);let U=c.input.charCodeAt(c.position);for(;U!==0;){!N&&c.firstTabInLine!==-1&&(c.position=c.firstTabInLine,V(c,"tab characters must not be used in indentation"));let Z=c.input.charCodeAt(c.position+1),de=c.line;if((U===63||U===58)&&Q(Z))U===63?(N&&(bt(c,$,x,A,k,null,S,R,d),A=k=M=null),F=!0,N=!0,C=!0):N?(N=!1,C=!0):V(c,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),c.position+=1,U=Z;else{if(S=c.line,R=c.lineStart,d=c.position,!$t(c,E,l,!1,!0))break;if(c.line===de){for(U=c.input.charCodeAt(c.position);T(U);)U=c.input.charCodeAt(++c.position);if(U===58)U=c.input.charCodeAt(++c.position),Q(U)||V(c,"a whitespace character is expected after the key-value separator within a block mapping"),N&&(bt(c,$,x,A,k,null,S,R,d),A=k=M=null),F=!0,N=!1,C=!1,A=c.tag,k=c.result;else if(F)V(c,"can not read an implicit mapping pair; a colon is missed");else return c.tag=_,c.anchor=O,!0}else if(F)V(c,"can not read a block mapping entry; a multiline key may not be an implicit key");else return c.tag=_,c.anchor=O,!0}if((c.line===de||c.lineIndent>y)&&(N&&(S=c.line,R=c.lineStart,d=c.position),$t(c,y,p,!0,C)&&(N?k=c.result:M=c.result),N||(bt(c,$,x,A,k,M,S,R,d),A=k=M=null),he(c,!0,-1),U=c.input.charCodeAt(c.position)),(c.line===de||c.lineIndent>y)&&U!==0)V(c,"bad indentation of a mapping entry");else if(c.lineIndent<y)break}return N&&bt(c,$,x,A,k,null,S,R,d),F&&(c.tag=_,c.anchor=O,c.kind="mapping",c.result=$),F}function hs(c){let y=!1,E=!1,C,S,R=c.input.charCodeAt(c.position);if(R!==33)return!1;c.tag!==null&&V(c,"duplication of a tag property"),R=c.input.charCodeAt(++c.position),R===60?(y=!0,R=c.input.charCodeAt(++c.position)):R===33?(E=!0,C="!!",R=c.input.charCodeAt(++c.position)):C="!";let d=c.position;if(y){do R=c.input.charCodeAt(++c.position);while(R!==0&&R!==62);c.position<c.length?(S=c.input.slice(d,c.position),R=c.input.charCodeAt(++c.position)):V(c,"unexpected end of the stream within a verbatim tag")}else{for(;R!==0&&!Q(R);)R===33&&(E?V(c,"tag suffix cannot contain exclamation marks"):(C=c.input.slice(d-1,c.position+1),b.test(C)||V(c,"named tag handle cannot contain such characters"),E=!0,d=c.position+1)),R=c.input.charCodeAt(++c.position);S=c.input.slice(d,c.position),P.test(S)&&V(c,"tag suffix cannot contain flow indicator characters")}S&&!j.test(S)&&V(c,"tag name cannot contain such characters: "+S);try{S=decodeURIComponent(S)}catch{V(c,"tag name is malformed: "+S)}return y?c.tag=S:s.call(c.tagMap,C)?c.tag=c.tagMap[C]+S:C==="!"?c.tag="!"+S:C==="!!"?c.tag="tag:yaml.org,2002:"+S:V(c,'undeclared tag handle "'+C+'"'),!0}function bi(c){let y=c.input.charCodeAt(c.position);if(y!==38)return!1;c.anchor!==null&&V(c,"duplication of an anchor property"),y=c.input.charCodeAt(++c.position);let E=c.position;for(;y!==0&&!Q(y)&&!ne(y);)y=c.input.charCodeAt(++c.position);return c.position===E&&V(c,"name of an anchor node must contain at least one character"),c.anchor=c.input.slice(E,c.position),!0}function Si(c){let y=c.input.charCodeAt(c.position);if(y!==42)return!1;y=c.input.charCodeAt(++c.position);let E=c.position;for(;y!==0&&!Q(y)&&!ne(y);)y=c.input.charCodeAt(++c.position);c.position===E&&V(c,"name of an alias node must contain at least one character");let C=c.input.slice(E,c.position);return s.call(c.anchorMap,C)||V(c,'unidentified alias "'+C+'"'),c.result=c.anchorMap[C],he(c,!0,-1),!0}function ms(c,y,E,C){let S=on(c);return ps(c),wr(c,y),c.tag=null,c.anchor=null,c.kind=null,c.result=null,wi(c,E,C)&&c.kind==="mapping"?(Kt(c),!0):(ds(c),wr(c,S),!1)}function $t(c,y,E,C,S){let R,d,_=1,O=!1,$=!1,x=null,A,k,M;c.depth>=c.maxDepth&&V(c,"nesting exceeded maxDepth ("+c.maxDepth+")"),c.depth+=1,c.listener!==null&&c.listener("open",c),c.tag=null,c.anchor=null,c.kind=null,c.result=null;let N=R=d=p===E||u===E;if(C&&he(c,!0,-1)&&(O=!0,c.lineIndent>y?_=1:c.lineIndent===y?_=0:c.lineIndent<y&&(_=-1)),_===1)for(;;){let F=c.input.charCodeAt(c.position),U=on(c);if(O&&(F===33&&c.tag!==null||F===38&&c.anchor!==null)||!hs(c)&&!bi(c))break;x===null&&(x=U),he(c,!0,-1)?(O=!0,d=N,c.lineIndent>y?_=1:c.lineIndent===y?_=0:c.lineIndent<y&&(_=-1)):d=!1}if(d&&(d=O||S),_===1||p===E)if(a===E||l===E?k=y:k=y+1,M=c.position-c.lineStart,_===1)if(d&&(Et(c,M)||wi(c,M,k))||vi(c,k))$=!0;else{let F=c.input.charCodeAt(c.position);x!==null&&N&&!d&&F!==124&&F!==62&&ms(c,x,x.position-x.lineStart,k)||R&&_i(c,k)||yi(c,k)||sn(c,k)?$=!0:Si(c)?($=!0,(c.tag!==null||c.anchor!==null)&&V(c,"alias node should not have any properties")):gi(c,k,a===E)&&($=!0,c.tag===null&&(c.tag="?")),c.anchor!==null&&wt(c,c.anchor,c.result)}else _===0&&($=d&&Et(c,M));if(c.tag===null)c.anchor!==null&&wt(c,c.anchor,c.result);else if(c.tag==="?"){c.result!==null&&c.kind!=="scalar"&&V(c,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+c.kind+'"');for(let F=0,U=c.implicitTypes.length;F<U;F+=1)if(A=c.implicitTypes[F],A.resolve(c.result)){c.result=A.construct(c.result),c.tag=A.tag,c.anchor!==null&&wt(c,c.anchor,c.result);break}}else if(c.tag!=="!"){if(s.call(c.typeMap[c.kind||"fallback"],c.tag))A=c.typeMap[c.kind||"fallback"][c.tag];else{A=null;let F=c.typeMap.multi[c.kind||"fallback"];for(let U=0,Z=F.length;U<Z;U+=1)if(c.tag.slice(0,F[U].tag.length)===F[U].tag){A=F[U];break}}A||V(c,"unknown tag !<"+c.tag+">"),c.result!==null&&A.kind!==c.kind&&V(c,"unacceptable node kind for !<"+c.tag+'> tag; it should be "'+A.kind+'", not "'+c.kind+'"'),A.resolve(c.result,c.tag)?(c.result=A.construct(c.result,c.tag),c.anchor!==null&&wt(c,c.anchor,c.result)):V(c,"cannot resolve a node with !<"+c.tag+"> explicit tag")}return c.listener!==null&&c.listener("close",c),c.depth-=1,c.tag!==null||c.anchor!==null||$}function gs(c){let y=c.position,E=!1,C;for(c.version=null,c.checkLineBreaks=c.legacy,c.tagMap=Object.create(null),c.anchorMap=Object.create(null);(C=c.input.charCodeAt(c.position))!==0&&(he(c,!0,-1),C=c.input.charCodeAt(c.position),!(c.lineIndent>0||C!==37));){E=!0,C=c.input.charCodeAt(++c.position);let S=c.position;for(;C!==0&&!Q(C);)C=c.input.charCodeAt(++c.position);let R=c.input.slice(S,c.position),d=[];for(R.length<1&&V(c,"directive name must not be less than one character in length");C!==0;){for(;T(C);)C=c.input.charCodeAt(++c.position);if(C===35){do C=c.input.charCodeAt(++c.position);while(C!==0&&!L(C));break}if(L(C))break;for(S=c.position;C!==0&&!Q(C);)C=c.input.charCodeAt(++c.position);d.push(c.input.slice(S,c.position))}C!==0&&br(c),s.call(mi,R)?mi[R](c,R,d):_r(c,'unknown document directive "'+R+'"')}if(he(c,!0,-1),c.lineIndent===0&&c.input.charCodeAt(c.position)===45&&c.input.charCodeAt(c.position+1)===45&&c.input.charCodeAt(c.position+2)===45?(c.position+=3,he(c,!0,-1)):E&&V(c,"directives end mark is expected"),$t(c,c.lineIndent-1,p,!1,!0),he(c,!0,-1),c.checkLineBreaks&&v.test(c.input.slice(y,c.position))&&_r(c,"non-ASCII line breaks are interpreted as content"),c.documents.push(c.result),c.position===c.lineStart&&Sr(c)){c.input.charCodeAt(c.position)===46&&(c.position+=3,he(c,!0,-1));return}c.position<c.length-1&&V(c,"end of the stream or a document separator is expected")}function Ei(c,y){c=String(c),y=y||{},c.length!==0&&(c.charCodeAt(c.length-1)!==10&&c.charCodeAt(c.length-1)!==13&&(c+=`
|
|
485
|
+
`),c.charCodeAt(0)===65279&&(c=c.slice(1)));let E=new se(c,y),C=c.indexOf("\0");for(C!==-1&&(E.position=C,V(E,"null byte is not allowed in input")),E.input+="\0";E.input.charCodeAt(E.position)===32;)E.lineIndent+=1,E.position+=1;for(;E.position<E.length-1;)gs(E);return E.documents}function $i(c,y,E){y!==null&&typeof y=="object"&&typeof E>"u"&&(E=y,y=null);let C=Ei(c,E);if(typeof y!="function")return C;for(let S=0,R=C.length;S<R;S+=1)y(C[S])}function ys(c,y){let E=Ei(c,y);if(E.length!==0){if(E.length===1)return E[0];throw new n("expected a single document in the stream, but found more")}}e.exports.loadAll=$i,e.exports.load=ys})),tv=le(((t,e)=>{var r=fn(),n=pn(),i=Hs(),o=Object.prototype.toString,s=Object.prototype.hasOwnProperty,a=65279,l=9,u=10,p=13,f=32,h=33,m=34,g=35,v=37,P=38,b=39,j=42,B=44,L=45,T=58,Q=61,ne=62,Nt=63,et=64,be=91,Ne=93,xe=96,tt=123,rt=124,_t=125,se={};se[0]="\\0",se[7]="\\a",se[8]="\\b",se[9]="\\t",se[10]="\\n",se[11]="\\v",se[12]="\\f",se[13]="\\r",se[27]="\\e",se[34]='\\"',se[92]="\\\\",se[133]="\\N",se[160]="\\_",se[8232]="\\L",se[8233]="\\P";var hi=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],V=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function _r(d,_){if(_===null)return{};let O={},$=Object.keys(_);for(let x=0,A=$.length;x<A;x+=1){let k=$[x],M=String(_[k]);k.slice(0,2)==="!!"&&(k="tag:yaml.org,2002:"+k.slice(2));let N=d.compiledTypeMap.fallback[k];N&&s.call(N.styleAliases,M)&&(M=N.styleAliases[M]),O[k]=M}return O}function wt(d){let _,O,$=d.toString(16).toUpperCase();if(d<=255)_="x",O=2;else if(d<=65535)_="u",O=4;else if(d<=4294967295)_="U",O=8;else throw new n("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+_+r.repeat("0",O-$.length)+$}var ps=1,Kt=2;function ds(d){this.schema=d.schema||i,this.indent=Math.max(1,d.indent||2),this.noArrayIndent=d.noArrayIndent||!1,this.skipInvalid=d.skipInvalid||!1,this.flowLevel=r.isNothing(d.flowLevel)?-1:d.flowLevel,this.styleMap=_r(this.schema,d.styles||null),this.sortKeys=d.sortKeys||!1,this.lineWidth=d.lineWidth||80,this.noRefs=d.noRefs||!1,this.noCompatMode=d.noCompatMode||!1,this.condenseFlow=d.condenseFlow||!1,this.quotingType=d.quotingType==='"'?Kt:ps,this.forceQuotes=d.forceQuotes||!1,this.replacer=typeof d.replacer=="function"?d.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function on(d,_){let O=r.repeat(" ",_),$=0,x="",A=d.length;for(;$<A;){let k,M=d.indexOf(`
|
|
486
|
+
`,$);M===-1?(k=d.slice($),$=A):(k=d.slice($,M+1),$=M+1),k.length&&k!==`
|
|
487
|
+
`&&(x+=O),x+=k}return x}function wr(d,_){return`
|
|
488
|
+
`+r.repeat(" ",d.indent*_)}function mi(d,_){for(let O=0,$=d.implicitTypes.length;O<$;O+=1)if(d.implicitTypes[O].resolve(_))return!0;return!1}function Ve(d){return d===f||d===l}function Mt(d){return d>=32&&d<=126||d>=161&&d<=55295&&d!==8232&&d!==8233||d>=57344&&d<=65533&&d!==a||d>=65536&&d<=1114111}function bt(d){return Mt(d)&&d!==a&&d!==p&&d!==u}function br(d,_,O){let $=bt(d),x=$&&!Ve(d);return(O?$:$&&d!==B&&d!==be&&d!==Ne&&d!==tt&&d!==_t)&&d!==g&&!(_===T&&!x)||bt(_)&&!Ve(_)&&d===g||_===T&&x}function he(d){return Mt(d)&&d!==a&&!Ve(d)&&d!==L&&d!==Nt&&d!==T&&d!==B&&d!==be&&d!==Ne&&d!==tt&&d!==_t&&d!==g&&d!==P&&d!==j&&d!==h&&d!==rt&&d!==Q&&d!==ne&&d!==b&&d!==m&&d!==v&&d!==et&&d!==xe}function Sr(d){return!Ve(d)&&d!==T}function St(d,_){let O=d.charCodeAt(_),$;return O>=55296&&O<=56319&&_+1<d.length&&($=d.charCodeAt(_+1),$>=56320&&$<=57343)?(O-55296)*1024+$-56320+65536:O}function gi(d){return/^\n* /.test(d)}var yi=1,sn=2,vi=3,_i=4,Et=5;function wi(d,_,O,$,x,A,k,M){let N,F=0,U=null,Z=!1,de=!1,cu=$!==-1,an=-1,cn=he(St(d,0))&&Sr(St(d,d.length-1));if(_||k)for(N=0;N<d.length;F>=65536?N+=2:N++){if(F=St(d,N),!Mt(F))return Et;cn=cn&&br(F,U,M),U=F}else{for(N=0;N<d.length;F>=65536?N+=2:N++){if(F=St(d,N),F===u)Z=!0,cu&&(de=de||N-an-1>$&&d[an+1]!==" ",an=N);else if(!Mt(F))return Et;cn=cn&&br(F,U,M),U=F}de=de||cu&&N-an-1>$&&d[an+1]!==" "}return!Z&&!de?cn&&!k&&!x(d)?yi:A===Kt?Et:sn:O>9&&gi(d)?Et:k?A===Kt?Et:sn:de?_i:vi}function hs(d,_,O,$,x){d.dump=(function(){if(_.length===0)return d.quotingType===Kt?'""':"''";if(!d.noCompatMode&&(hi.indexOf(_)!==-1||V.test(_)))return d.quotingType===Kt?'"'+_+'"':"'"+_+"'";let A=d.indent*Math.max(1,O),k=d.lineWidth===-1?-1:Math.max(Math.min(d.lineWidth,40),d.lineWidth-A),M=$||d.flowLevel>-1&&O>=d.flowLevel;function N(F){return mi(d,F)}switch(wi(_,M,d.indent,k,N,d.quotingType,d.forceQuotes&&!$,x)){case yi:return _;case sn:return"'"+_.replace(/'/g,"''")+"'";case vi:return"|"+bi(_,d.indent)+Si(on(_,A));case _i:return">"+bi(_,d.indent)+Si(on(ms(_,k),A));case Et:return'"'+gs(_,k)+'"';default:throw new n("impossible error: invalid scalar style")}})()}function bi(d,_){let O=gi(d)?String(_):"",$=d[d.length-1]===`
|
|
489
|
+
`;return O+($&&(d[d.length-2]===`
|
|
490
|
+
`||d===`
|
|
487
491
|
`)?"+":$?"":"-")+`
|
|
488
|
-
`}function
|
|
489
|
-
`?
|
|
490
|
-
`);return
|
|
491
|
-
`||
|
|
492
|
-
`:"")
|
|
493
|
-
`+
|
|
494
|
-
`,
|
|
495
|
-
`+
|
|
496
|
-
`:""}e.exports.dump=R})),Iu=_y(le(((t,e)=>{var r=by(),n=Sy();function i(s,o){return function(){throw new Error("Function yaml."+s+" is removed in js-yaml 4. Use yaml."+o+" instead, which is now safe by default.")}}e.exports.Type=Oe(),e.exports.Schema=mu(),e.exports.FAILSAFE_SCHEMA=_u(),e.exports.JSON_SCHEMA=$u(),e.exports.CORE_SCHEMA=Cu(),e.exports.DEFAULT_SCHEMA=xo(),e.exports.load=r.load,e.exports.loadAll=r.loadAll,e.exports.dump=n.dump,e.exports.YAMLException=ln(),e.exports.types={binary:Pu(),float:Eu(),map:vu(),null:wu(),pairs:Au(),set:Ru(),timestamp:ku(),bool:bu(),int:Su(),merge:xu(),omap:Ou(),seq:yu(),str:gu()},e.exports.safeLoad=i("safeLoad","load"),e.exports.safeLoadAll=i("safeLoadAll","loadAll"),e.exports.safeDump=i("safeDump","dump")}))(),1),{Type:bk,Schema:Sk,FAILSAFE_SCHEMA:Ek,JSON_SCHEMA:$k,CORE_SCHEMA:Ck,DEFAULT_SCHEMA:kk,load:xk,loadAll:Pk,dump:Ok,YAMLException:Ak,types:Rk,safeLoad:Ik,safeLoadAll:Tk,safeDump:Nk}=Iu.default,Pt=Iu.default;async function Cy(t=process.cwd()){let e=he(t);for(;;){let r=he(e,"view-contracts.config.yaml");try{return await Ey(r),r}catch{let n=$i(e);if(n===e)return null;e=n}}}async function Kt(t){if(t)return he(t);let e=await Cy();if(!e)throw new Error("view-contracts.config.yaml not found. Pass -c <path> or run from a project directory.");return e}async function Jt(t){let e=he(t),r=await Tu(e,"utf-8"),n=Pt.load(r);return ky(e,n)}function ky(t,e){let r=$e(t);return{...e,openapi:he(r,e.openapi),bindings:he(r,e.bindings),microContractsConfig:he(r,e.microContractsConfig),viewsDir:he(r,e.viewsDir),generated:{contractDir:he(r,e.generated.contractDir),actions:he(r,e.generated.actions),bridge:he(r,e.generated.bridge),reactDir:he(r,e.generated.reactDir)},componentsModule:e.componentsModule?he(r,e.componentsModule):void 0,themeModule:e.themeModule?he(r,e.themeModule):void 0,design:e.design?{tokens:e.design.tokens?he(r,e.design.tokens):void 0,theme:e.design.theme?he(r,e.design.theme):void 0,extensionsCss:e.design.extensionsCss?he(r,e.design.extensionsCss):void 0}:void 0,extensions:e.extensions?he(r,e.extensions):void 0}}async function un(t){let e=await Tu(he(t),"utf-8");return Pt.load(e)}function Nu(t,e){return he(t.generated.reactDir,`${e.screenName}.generated.tsx`)}function $e(t){return $i(he(t))}function wr(t){let e=t.design?.tokens,r=t.design?.theme;if(!e)throw new Error("view-contracts.config.yaml must define design.tokens (project tokens file path).");if(!r)throw new Error("view-contracts.config.yaml must define design.theme (project theme file path).");return{tokensPath:e,themePath:r}}function Mu(t,e,r){let n=he($i(r),"../components/index.ts"),i=$y($i(he(r)),n);return i.startsWith(".")||(i=`./${i}`),i.replace(/\.tsx?$/,".js")}import{relative as xy}from"node:path";function Lu(t,e){return xy(t,e).split("\\").join("/")}var qp=io(Dp(),1);import{readFile as Vp}from"node:fs/promises";import{resolve as Fp}from"node:path";import{readFileSync as fb}from"node:fs";import{createRequire as db}from"node:module";import{dirname as Pc,resolve as pb}from"node:path";import{fileURLToPath as hb}from"node:url";var jr;function Xe(){if(jr)return jr;let t=db(import.meta.url);try{return jr=Pc(t.resolve("view-contracts/package.json")),jr}catch{let e=Pc(hb(import.meta.url));for(;;){try{let n=pb(e,"package.json");if(JSON.parse(fb(n,"utf8")).name==="view-contracts")return jr=e,jr}catch{}let r=Pc(e);if(r===e)break;e=r}throw new Error("view-contracts package root not found")}}var mb=qp.default,gb=Fp(Xe(),"spec/ui-dsl-extensions.meta.json"),is;async function yb(){if(is)return is;let t=JSON.parse(await Vp(gb,"utf-8"));return is=new mb({allErrors:!0,strict:!1}).compile(t),is}async function Hp(t){if(!t)return{extensions:{}};let e=Fp(t),r=await Vp(e,"utf-8"),n=Pt.load(r),i=await yb();if(!i(n)){let s=i.errors?.map(o=>`${o.instancePath||"/"} ${o.message??""}`).join("; ")??"unknown";throw new Error(`Extension registry validation failed (${e}): ${s}`)}return n}import{resolve as _b}from"node:path";import{readFile as vb}from"node:fs/promises";async function Bp(t){return Pt.load(await vb(t,"utf-8"))}function Up(t,e,r){for(let n of t)if(!e.has(n))throw new Error(`${r}: unknown element "${n}" \u2014 not in spec/ui-dsl.schema.json vocabulary`)}function Gp(t,e,r){for(let[n,i]of Object.entries(t))for(let s of e)if(i[s]===void 0||i[s]===null||i[s]==="")throw new Error(`${r}: element "${n}" is missing required "${String(s)}"`)}var MP=Xe();var zp="renderers/react/elements.yaml",Oc=null;function wb(t){Up(Object.keys(t.elements),vr,zp),Gp(t.elements,["tag"],zp)}async function Wp(t){if(!t&&Oc)return Oc;let e=t??_b(Xe(),"renderers/react/elements.yaml"),r=await Bp(e);return wb(r),t||(Oc=r),r}var Kp=new Set(["align","aspectRatio","axis","contentAlign","direction","fontWeight","gap","headingLevel","height","justify","lineLimit","maxHeight","maxWidth","minHeight","minWidth","padding","scroll","selfAlign","textAlign","textOverflow","textStyle","weight","width","size"]);function B(t){return" ".repeat(t)}function Bn(t,e="vm"){let r=t.scope??e;return t.path?`${r}.${t.path}`:r}function ss(t,e=!1){let r=e?" as ActionDescriptor":"";if(!t.params||Object.keys(t.params).length===0)return`{ name: ${JSON.stringify(t.name)} }${r}`;let n=Object.entries(t.params).map(([i,s])=>`${i}: ${Vr(s,0)}`).join(", ");return`{ name: ${JSON.stringify(t.name)}, params: { ${n} } }${r}`}function Rc(t,e,r=!1){if(t===null)return"null";if(typeof t=="string")return JSON.stringify(t);if(typeof t=="number"||typeof t=="boolean")return String(t);if(Array.isArray(t))return`[
|
|
497
|
-
${t.map(n=>`${
|
|
492
|
+
`}function Si(d){return d[d.length-1]===`
|
|
493
|
+
`?d.slice(0,-1):d}function ms(d,_){let O=/(\n+)([^\n]*)/g,$=(function(){let M=d.indexOf(`
|
|
494
|
+
`);return M=M!==-1?M:d.length,O.lastIndex=M,$t(d.slice(0,M),_)})(),x=d[0]===`
|
|
495
|
+
`||d[0]===" ",A,k;for(;k=O.exec(d);){let M=k[1],N=k[2];A=N[0]===" ",$+=M+(!x&&!A&&N!==""?`
|
|
496
|
+
`:"")+$t(N,_),x=A}return $}function $t(d,_){if(d===""||d[0]===" ")return d;let O=/ [^ ]/g,$,x=0,A,k=0,M=0,N="";for(;$=O.exec(d);)M=$.index,M-x>_&&(A=k>x?k:M,N+=`
|
|
497
|
+
`+d.slice(x,A),x=A+1),k=M;return N+=`
|
|
498
|
+
`,d.length-x>_&&k>x?N+=d.slice(x,k)+`
|
|
499
|
+
`+d.slice(k+1):N+=d.slice(x),N.slice(1)}function gs(d){let _="",O=0;for(let $=0;$<d.length;O>=65536?$+=2:$++){O=St(d,$);let x=se[O];!x&&Mt(O)?(_+=d[$],O>=65536&&(_+=d[$+1])):_+=x||wt(O)}return _}function Ei(d,_,O){let $="",x=d.tag;for(let A=0,k=O.length;A<k;A+=1){let M=O[A];d.replacer&&(M=d.replacer.call(O,String(A),M)),(E(d,_,M,!1,!1)||typeof M>"u"&&E(d,_,null,!1,!1))&&($!==""&&($+=","+(d.condenseFlow?"":" ")),$+=d.dump)}d.tag=x,d.dump="["+$+"]"}function $i(d,_,O,$){let x="",A=d.tag;for(let k=0,M=O.length;k<M;k+=1){let N=O[k];d.replacer&&(N=d.replacer.call(O,String(k),N)),(E(d,_+1,N,!0,!0,!1,!0)||typeof N>"u"&&E(d,_+1,null,!0,!0,!1,!0))&&((!$||x!=="")&&(x+=wr(d,_)),d.dump&&u===d.dump.charCodeAt(0)?x+="-":x+="- ",x+=d.dump)}d.tag=A,d.dump=x||"[]"}function ys(d,_,O){let $="",x=d.tag,A=Object.keys(O);for(let k=0,M=A.length;k<M;k+=1){let N="";$!==""&&(N+=", "),d.condenseFlow&&(N+='"');let F=A[k],U=O[F];d.replacer&&(U=d.replacer.call(O,F,U)),E(d,_,F,!1,!1)&&(d.dump.length>1024&&(N+="? "),N+=d.dump+(d.condenseFlow?'"':"")+":"+(d.condenseFlow?"":" "),E(d,_,U,!1,!1)&&(N+=d.dump,$+=N))}d.tag=x,d.dump="{"+$+"}"}function c(d,_,O,$){let x="",A=d.tag,k=Object.keys(O);if(d.sortKeys===!0)k.sort();else if(typeof d.sortKeys=="function")k.sort(d.sortKeys);else if(d.sortKeys)throw new n("sortKeys must be a boolean or a function");for(let M=0,N=k.length;M<N;M+=1){let F="";(!$||x!=="")&&(F+=wr(d,_));let U=k[M],Z=O[U];if(d.replacer&&(Z=d.replacer.call(O,U,Z)),!E(d,_+1,U,!0,!0,!0))continue;let de=d.tag!==null&&d.tag!=="?"||d.dump&&d.dump.length>1024;de&&(d.dump&&u===d.dump.charCodeAt(0)?F+="?":F+="? "),F+=d.dump,de&&(F+=wr(d,_)),E(d,_+1,Z,!0,de)&&(d.dump&&u===d.dump.charCodeAt(0)?F+=":":F+=": ",F+=d.dump,x+=F)}d.tag=A,d.dump=x||"{}"}function y(d,_,O){let $=O?d.explicitTypes:d.implicitTypes;for(let x=0,A=$.length;x<A;x+=1){let k=$[x];if((k.instanceOf||k.predicate)&&(!k.instanceOf||typeof _=="object"&&_ instanceof k.instanceOf)&&(!k.predicate||k.predicate(_))){if(O?k.multi&&k.representName?d.tag=k.representName(_):d.tag=k.tag:d.tag="?",k.represent){let M=d.styleMap[k.tag]||k.defaultStyle,N;if(o.call(k.represent)==="[object Function]")N=k.represent(_,M);else if(s.call(k.represent,M))N=k.represent[M](_,M);else throw new n("!<"+k.tag+'> tag resolver accepts not "'+M+'" style');d.dump=N}return!0}}return!1}function E(d,_,O,$,x,A,k){d.tag=null,d.dump=O,y(d,O,!1)||y(d,O,!0);let M=o.call(d.dump),N=$;$&&($=d.flowLevel<0||d.flowLevel>_);let F=M==="[object Object]"||M==="[object Array]",U,Z;if(F&&(U=d.duplicates.indexOf(O),Z=U!==-1),(d.tag!==null&&d.tag!=="?"||Z||d.indent!==2&&_>0)&&(x=!1),Z&&d.usedDuplicates[U])d.dump="*ref_"+U;else{if(F&&Z&&!d.usedDuplicates[U]&&(d.usedDuplicates[U]=!0),M==="[object Object]")$&&Object.keys(d.dump).length!==0?(c(d,_,d.dump,x),Z&&(d.dump="&ref_"+U+d.dump)):(ys(d,_,d.dump),Z&&(d.dump="&ref_"+U+" "+d.dump));else if(M==="[object Array]")$&&d.dump.length!==0?(d.noArrayIndent&&!k&&_>0?$i(d,_-1,d.dump,x):$i(d,_,d.dump,x),Z&&(d.dump="&ref_"+U+d.dump)):(Ei(d,_,d.dump),Z&&(d.dump="&ref_"+U+" "+d.dump));else if(M==="[object String]")d.tag!=="?"&&hs(d,d.dump,_,A,N);else{if(M==="[object Undefined]")return!1;if(d.skipInvalid)return!1;throw new n("unacceptable kind of an object to dump "+M)}if(d.tag!==null&&d.tag!=="?"){let de=encodeURI(d.tag[0]==="!"?d.tag.slice(1):d.tag).replace(/!/g,"%21");d.tag[0]==="!"?de="!"+de:de.slice(0,18)==="tag:yaml.org,2002:"?de="!!"+de.slice(18):de="!<"+de+">",d.dump=de+" "+d.dump}}return!0}function C(d,_){let O=[],$=[];S(d,O,$);let x=$.length;for(let A=0;A<x;A+=1)_.duplicates.push(O[$[A]]);_.usedDuplicates=new Array(x)}function S(d,_,O){if(d!==null&&typeof d=="object"){let $=_.indexOf(d);if($!==-1)O.indexOf($)===-1&&O.push($);else if(_.push(d),Array.isArray(d))for(let x=0,A=d.length;x<A;x+=1)S(d[x],_,O);else{let x=Object.keys(d);for(let A=0,k=x.length;A<k;A+=1)S(d[x[A]],_,O)}}}function R(d,_){_=_||{};let O=new ds(_);O.noRefs||C(d,O);let $=d;return O.replacer&&($=O.replacer.call({"":$},"",$)),E(O,0,$,!0,!0)?O.dump+`
|
|
500
|
+
`:""}e.exports.dump=R})),af=Qy(le(((t,e)=>{var r=ev(),n=tv();function i(o,s){return function(){throw new Error("Function yaml."+o+" is removed in js-yaml 4. Use yaml."+s+" instead, which is now safe by default.")}}e.exports.Type=Oe(),e.exports.Schema=Bu(),e.exports.FAILSAFE_SCHEMA=zu(),e.exports.JSON_SCHEMA=Qu(),e.exports.CORE_SCHEMA=Zu(),e.exports.DEFAULT_SCHEMA=Hs(),e.exports.load=r.load,e.exports.loadAll=r.loadAll,e.exports.dump=n.dump,e.exports.YAMLException=pn(),e.exports.types={binary:rf(),float:Xu(),map:Wu(),null:Ku(),pairs:of(),set:sf(),timestamp:ef(),bool:Ju(),int:Yu(),merge:tf(),omap:nf(),seq:Gu(),str:Uu()},e.exports.safeLoad=i("safeLoad","load"),e.exports.safeLoadAll=i("safeLoadAll","loadAll"),e.exports.safeDump=i("safeDump","dump")}))(),1),{Type:mP,Schema:gP,FAILSAFE_SCHEMA:yP,JSON_SCHEMA:vP,CORE_SCHEMA:_P,DEFAULT_SCHEMA:wP,load:bP,loadAll:SP,dump:EP,YAMLException:$P,types:xP,safeLoad:CP,safeLoadAll:PP,safeDump:kP}=af.default,Ct=af.default;async function nv(t=process.cwd()){let e=me(t);for(;;){let r=me(e,"view-contracts.config.yaml");try{return await rv(r),r}catch{let n=lf(e);if(n===e)return null;e=n}}}async function Yt(t){if(t)return me(t);let e=await nv();if(!e)throw new Error("view-contracts.config.yaml not found. Pass -c <path> or run from a project directory.");return e}async function Xt(t){let e=me(t),r=await cf(e,"utf-8"),n=Ct.load(r);return iv(e,n)}function iv(t,e){let r=_e(t);return{...e,openapi:me(r,e.openapi),bindings:me(r,e.bindings),microContractsConfig:me(r,e.microContractsConfig),viewsDir:me(r,e.viewsDir),generated:{contractDir:me(r,e.generated.contractDir),actions:me(r,e.generated.actions),bridge:me(r,e.generated.bridge),reactDir:me(r,e.generated.reactDir)},runtimeModule:e.runtimeModule?me(r,e.runtimeModule):e.componentsModule?me(r,e.componentsModule):void 0,themeModule:e.themeModule?me(r,e.themeModule):void 0,design:e.design?{tokens:e.design.tokens?me(r,e.design.tokens):void 0,theme:e.design.theme?me(r,e.design.theme):void 0,extensionsCss:e.design.extensionsCss?me(r,e.design.extensionsCss):void 0}:void 0,extensions:e.extensions?me(r,e.extensions):void 0}}async function dn(t){let e=await cf(me(t),"utf-8");return Ct.load(e)}function uf(t,e){return me(t.generated.reactDir,"components",`${e.screenName}.generated.tsx`)}function _e(t){return lf(me(t))}function Ri(t){let e=t.design?.tokens,r=t.design?.theme;if(!e)throw new Error("view-contracts.config.yaml must define design.tokens (project tokens file path).");if(!r)throw new Error("view-contracts.config.yaml must define design.theme (project theme file path).");return{tokensPath:e,themePath:r}}import{relative as ov}from"node:path";function ff(t,e){return ov(t,e).split("\\").join("/")}var ph=xi(Bc(),1);import{readFile as dh}from"node:fs/promises";import{resolve as hh}from"node:path";import{readFileSync as Bb}from"node:fs";import{createRequire as Ub}from"node:module";import{dirname as Uc,resolve as Gb}from"node:path";import{fileURLToPath as Wb}from"node:url";var qr;function Ye(){if(qr)return qr;let t=Ub(import.meta.url);try{return qr=Uc(t.resolve("view-contracts/package.json")),qr}catch{let e=Uc(Wb(import.meta.url));for(;;){try{let n=Gb(e,"package.json");if(JSON.parse(Bb(n,"utf8")).name==="view-contracts")return qr=e,qr}catch{}let r=Uc(e);if(r===e)break;e=r}throw new Error("view-contracts package root not found")}}var zb=ph.default,Kb=hh(Ye(),"spec/ui-dsl-extensions.meta.json"),fo;async function Jb(){if(fo)return fo;let t=JSON.parse(await dh(Kb,"utf-8"));return fo=new zb({allErrors:!0,strict:!1}).compile(t),fo}async function mh(t){if(!t)return{extensions:{}};let e=hh(t),r=await dh(e,"utf-8"),n=Ct.load(r),i=await Jb();if(!i(n)){let o=i.errors?.map(s=>`${s.instancePath||"/"} ${s.message??""}`).join("; ")??"unknown";throw new Error(`Extension registry validation failed (${e}): ${o}`)}return n}import{resolve as wS}from"node:path";import{resolve as nS}from"node:path";import{readFile as Yb}from"node:fs/promises";async function gh(t){return Ct.load(await Yb(t,"utf-8"))}function yh(t,e,r){for(let n of t)if(!e.has(n))throw new Error(`${r}: unknown element "${n}" \u2014 not in spec/ui-dsl.schema.json vocabulary`)}function vh(t,e,r){for(let[n,i]of Object.entries(t))for(let o of e)if(i[o]===void 0||i[o]===null||i[o]==="")throw new Error(`${r}: element "${n}" is missing required "${String(o)}"`)}var _h=xi(Bc(),1);import{readFile as wh}from"node:fs/promises";import{dirname as Xb,resolve as Gc}from"node:path";var Qb=_h.default,Zb="spec/ui-dsl.schema.json",eS=Ye(),po;async function tS(t,e){if(!po){let r=Gc(Xb(Gc(e)),"ui-dsl.meta.json"),n=JSON.parse(await wh(r,"utf-8"));po=new Qb({allErrors:!0,strict:!1}).compile(n)}if(!po(t)){let r=po.errors?.map(n=>`${n.instancePath||"/"} ${n.message??""}`).join("; ")??"unknown";throw new Error(`UI DSL schema validation failed (${e}): ${r}`)}}async function Gn(t=Zb){let e=Gc(eS,t),r=await wh(e,"utf-8"),n=JSON.parse(r);return await tS(n,e),n}function rS(t,e){if("$ref"in e){let r=e.$ref;if(!r)return;let n=r.replace("#/properties/","");return t.properties[n]}return e}function ho(t,e){let r=t.elements[e];return r?Object.keys(r.properties):[]}function bh(t,e,r){let n=t.properties[e];if(!n){let i=t.elements[r];if(!i?.properties[e])return!1;let o=rS(t,i.properties[e]);return o?.["x-appliesTo"]?o["x-appliesTo"].includes(r):!0}return!n["x-appliesTo"]||n["x-appliesTo"].length===0?!0:n["x-appliesTo"].includes(r)}var Sh="renderers/react/elements.yaml",Wc=null;function iS(t){yh(Object.keys(t.elements),Jt,Sh),vh(t.elements,["tag"],Sh)}async function Eh(t){if(!t&&Wc)return Wc;let e=t??nS(Ye(),"renderers/react/elements.yaml"),r=await gh(e);return iS(r),t||(Wc=r),r}var $h=new Set(["align","aspectRatio","axis","background","border","clip","contentAlign","direction","fontWeight","foreground","gap","headingLevel","height","justify","lineLimit","maxHeight","maxWidth","minHeight","minWidth","opacity","padding","radius","scroll","selfAlign","shadow","textAlign","textOverflow","textStyle","weight","width","size"]);function xh(t){if(t)return t==="start"?"flex-start":t==="end"?"flex-end":t}function Ch(t){if(t)return t==="start"?"flex-start":t==="end"?"flex-end":t==="between"||t==="spaceBetween"?"space-between":t==="around"||t==="spaceAround"?"space-around":t==="spaceEvenly"?"space-evenly":t}function ct(t){return`${t}px`}var Ph={topStart:"start start",top:"center start",topEnd:"end start",start:"start center",center:"center center",end:"end center",bottomStart:"start end",bottom:"center end",bottomEnd:"end end"},oS={none:"none",sm:"var(--ui-shadow-sm, 0 1px 2px rgba(0,0,0,0.05))",md:"var(--ui-shadow)",lg:"var(--ui-shadow-lg, 0 10px 15px rgba(0,0,0,0.1))"};function Wn(t){let e=t.match(/^\{([^}]+)\}$/);if(e)return`var(--${e[1].replace(/\./g,"-")})`}function zn(t){let e={},r=t.width;typeof r=="number"?e.width=ct(r):typeof r=="string"&&r!=="wrap"&&r!=="fill"&&(e.width=r),typeof t.minWidth=="number"&&(e.minWidth=ct(t.minWidth)),typeof t.maxWidth=="number"&&(e.maxWidth=ct(t.maxWidth)),typeof t.height=="number"&&(e.height=ct(t.height)),typeof t.minHeight=="number"&&(e.minHeight=ct(t.minHeight)),typeof t.maxHeight=="number"&&(e.maxHeight=ct(t.maxHeight)),t.aspectRatio!==void 0&&(e.aspectRatio=String(t.aspectRatio));let n=t.weight;typeof n=="number"&&(e.flexGrow=n),typeof t.padding=="number"&&(e.padding=ct(t.padding)),typeof t.margin=="number"&&(e.margin=ct(t.margin)),typeof t.gap=="number"&&(e.gap=ct(t.gap));let i=t.textAlign;typeof i=="string"&&(e.textAlign=i==="start"?"left":i==="end"?"right":i);let o=t.contentAlign;typeof o=="string"&&o in Ph&&(e.placeItems=Ph[o]),typeof t.overflow=="string"&&(e.overflow=t.overflow);let s=t.selfAlign;typeof s=="string"&&(e.alignSelf=s==="start"?"flex-start":s==="end"?"flex-end":s);let a=t.size;typeof a=="number"?e.fontSize=ct(a):typeof a=="string"&&(e.fontSize=a);let l=typeof n=="string"?n:t.fontWeight;typeof l=="string"&&(e.fontWeight=l);let u=t.background;typeof u=="string"&&(e.background=Wn(u)??u);let p=t.foreground;typeof p=="string"&&(e.color=Wn(p)??p);let f=t.radius;typeof f=="number"?e.borderRadius=ct(f):typeof f=="string"&&(e.borderRadius=Wn(f)??f);let h=t.shadow;h===!0?e.boxShadow="var(--ui-shadow)":h===!1?e.boxShadow="none":typeof h=="string"&&(e.boxShadow=oS[h]??Wn(h)??h);let m=t.border;typeof m=="string"&&(e.border=Wn(m)??m),typeof t.opacity=="number"&&(e.opacity=t.opacity);let g=t.clip;typeof g=="string"&&(e.overflow=g==="hidden"?"hidden":g);let v=t.align;if(typeof v=="string"){let b=xh(v);b&&(e.alignItems=b)}let P=t.justify;if(typeof P=="string"){let b=Ch(P);b&&(e.justifyContent=b)}return e}function ur(t){let e=Object.entries(t);return e.length===0?"":`style={{ ${e.map(([n,i])=>typeof i=="number"?`${n}: ${i}`:`${n}: ${JSON.stringify(i)}`).join(", ")} }}`}function mo(t,e){let r=t[e];if(r!=null){if(typeof r=="string"||typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="object"&&"kind"in r&&r.kind==="literal")return r.value}}function sS(t,e){if(e!=null&&!(typeof e=="string"||typeof e=="number"||typeof e=="boolean")&&!(typeof e=="object"&&"kind"in e&&e.kind==="literal"))throw new Error(`Style property "${t}" must be a compile-time literal; ViewModel bindings are not allowed on layout/visual props`)}function zc(t){let e={};for(let[r,n]of Object.entries(t)){if(!$h.has(r))continue;sS(r,n);let i=mo(t,r);i!==void 0&&(e[r]=i)}return e}function aS(t){return t.flex?{display:"flex",flexDirection:t.flex==="column"?"column":"row"}:{}}function cS(t){return t==="horizontal"?{overflowX:"auto",overflowY:"hidden"}:t==="both"?{overflowX:"auto",overflowY:"auto"}:t==="none"?{overflowX:"hidden",overflowY:"hidden"}:{overflowX:"hidden",overflowY:"auto"}}function Kc(t,e){let r=zc(e),n=zn(r);if(n={...n,...aS(t)},t.scrollContainer){let i=mo(e,"scroll"),o=mo(e,"axis"),s=typeof i=="string"?i:typeof o=="string"?o==="horizontal"?"horizontal":"vertical":void 0;if(s)return n={...n,...cS(s)},ur(n);throw new Error("ScrollArea scroll/axis must be compile-time literals")}if(t.flexGrowProp&&e[t.flexGrowProp]){let i=mo(e,t.flexGrowProp);if(typeof i=="number")return n.flexGrow=i,ur(n);throw new Error(`"${t.flexGrowProp}" on <Spacer> must be a compile-time literal`)}return ur(n)}function H(t){return" ".repeat(t)}function Fr(t,e="vm"){let r=t.scope??e;return t.path?`${r}.${t.path}`:r}function go(t,e=!1){let r=e?" as ActionDescriptor":"";if(!t.params||Object.keys(t.params).length===0)return`{ name: ${JSON.stringify(t.name)} }${r}`;let n=Object.entries(t.params).map(([i,o])=>`${i}: ${Br(o,0)}`).join(", ");return`{ name: ${JSON.stringify(t.name)}, params: { ${n} } }${r}`}function Yc(t,e,r=!1){if(t===null)return"null";if(typeof t=="string")return JSON.stringify(t);if(typeof t=="number"||typeof t=="boolean")return String(t);if(Array.isArray(t))return`[
|
|
501
|
+
${t.map(n=>`${H(e+1)}${Yc(n,e+1,r)}`).join(`,
|
|
498
502
|
`)}
|
|
499
|
-
${
|
|
500
|
-
${Object.entries(n).map(([s
|
|
503
|
+
${H(e)}]`;if(typeof t=="object"&&t!==null){let n=t;return"kind"in n&&n.kind==="action"?go(n,r):`{
|
|
504
|
+
${Object.entries(n).map(([o,s])=>`${o}: ${Yc(s,e+1,r)}`).map(o=>`${H(e+1)}${o}`).join(`,
|
|
501
505
|
`)}
|
|
502
|
-
${
|
|
503
|
-
${t.map(n=>`${
|
|
506
|
+
${H(e)}}`}return"undefined"}function Br(t,e,r=!1){if(t===null)return"null";if(typeof t=="string")return JSON.stringify(t);if(typeof t=="number"||typeof t=="boolean")return String(t);if(Array.isArray(t))return`[
|
|
507
|
+
${t.map(n=>`${H(e+1)}${Br(n,e+1,r)}`).join(`,
|
|
504
508
|
`)}
|
|
505
|
-
${
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
${
|
|
514
|
-
${
|
|
515
|
-
${
|
|
516
|
-
|
|
517
|
-
${B(e+1)}<span>{${i}}</span>
|
|
518
|
-
${B(e)}</label>`}function kb(t,e){let r=H(t,"binding")??H(t,"name")??'""',n=H(t,"label")??'""',i=t.checked?`defaultChecked={${H(t,"checked")}}`:"",s=t.enabled?`disabled={${H(t,"enabled")} === false}`:"";return`${B(e)}<label className="vc-switch">
|
|
519
|
-
${B(e+1)}<input type="checkbox" role="switch" name={${r}} ${i} ${s} />
|
|
520
|
-
${B(e+1)}<span>{${n}}</span>
|
|
521
|
-
${B(e)}</label>`}function xb(t,e,r){let n=t.props;if(n.alt!==void 0){let o=[qr(t.name,e,n),Dr(e,n),`src={${H(n,"name")??'""'}}`,`alt={${H(n,"alt")??'""'}}`];return n.id&&o.push(`id={${H(n,"id")}}`),`${B(r)}<img ${o.join(" ")} />`}let s=[qr(t.name,e,n),Dr(e,n),"aria-hidden"];return n.id&&s.push(`id={${H(n,"id")}}`),n.name&&s.push(`data-icon={${H(n,"name")}}`),`${B(r)}<span ${s.join(" ")} />`}function Qp(t,e){let r=t.options;if(!r||typeof r!="object"||!("kind"in r))return"";if(r.kind==="literal"&&Array.isArray(r.value))return r.value.map(s=>`${B(e+1)}<option key={${JSON.stringify(s.value)}} value={${JSON.stringify(s.value)}}>{${JSON.stringify(s.label)}}</option>`).join(`
|
|
522
|
-
`);let n=Vr(r,0);return`${B(e+1)}{${n}.map((option) => <option key={option.value} value={option.value}>{option.label}</option>)}`}function Zp(t,e,r,n){let i=[qr(t,e,r),Dr(e,r)];return e.ariaHidden&&i.push("aria-hidden"),r.id&&i.push(`id={${H(r,"id")}}`),r.role?i.push(`role={${H(r,"role")}}`):e.defaultRole&&i.push(`role="${e.defaultRole}"`),e.ariaLabel&&(r.ariaLabel?i.push(`aria-label={${H(r,"ariaLabel")}}`):r.label?i.push(`aria-label={${H(r,"label")}}`):r.title&&i.push(`aria-label={${H(r,"title")}}`)),r.name&&i.push(`name={${H(r,"name")}}`),r.placeholder&&i.push(`placeholder={${H(r,"placeholder")}}`),e.inputType&&i.push(`type={${H(r,"type")??JSON.stringify(e.inputType)}}`),r.required&&i.push(`required={${H(r,"required")}}`),r.readonly&&i.push(`readOnly={${H(r,"readonly")}}`),r.enabled&&i.push(`disabled={${H(r,"enabled")} === false}`),e.tag==="img"&&r.src&&i.push(`src={${H(r,"src")}}`),e.tag==="img"&&r.alt&&i.push(`alt={${H(r,"alt")}}`),e.tag==="progress"&&r.value&&i.push(`value={${H(r,"value")}}`),r.rows&&i.push(`rows={${H(r,"rows")??"4"}}`),`${B(n)}<${e.tag} ${i.join(" ")} />`}function Ac(t,e,r,n,i){let s=[];if(e.ariaHidden&&s.push("aria-hidden"),r.id&&s.push(`id={${H(r,"id")}}`),r.role?s.push(`role={${H(r,"role")}}`):e.defaultRole&&s.push(`role="${e.defaultRole}"`),e.ariaLabel&&(r.ariaLabel?s.push(`aria-label={${H(r,"ariaLabel")}}`):r.label?s.push(`aria-label={${H(r,"label")}}`):r.title&&s.push(`aria-label={${H(r,"title")}}`)),e.actionEvent){let o=Eb(r,e.actionEvent);o&&s.push(o)}return e.tag==="button"&&r.enabled&&s.push(`disabled={${H(r,"enabled")} === false}`),e.tag==="a"&&r.href&&s.push(`href={${H(r,"href")}}`),e.tag==="button"&&s.push(`type={${H(r,"type")??'"button"'}}`),s.push(qr(t,e,r,i)),s.push(Dr(e,r)),`<${n} ${s.join(" ")}`}function ft(t,e,r){if(e.visible===void 0)return t;let n=H(e,"visible");return`${B(r)}{${n} !== false ? (
|
|
509
|
+
${H(e)}]`;if(typeof t=="object"&&t!==null&&"kind"in t){if(t.kind==="binding")return Fr(t);if(t.kind==="action")return go(t,r);if(t.kind==="literal")return Yc(t.value,e,r)}return"undefined"}function Ut(t,e){let r=t[e];if(r!=null){if(typeof r=="string"||typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="object"&&"kind"in r&&r.kind==="literal")return r.value}}function G(t,e){let r=t[e];if(r!=null)return Br(r,0)}function Yn(t,e,r){let n=Kc(e,r);n&&t.push(n)}function lS(t,e){let r=t.action??t[e==="onClick"?"onClick":"onSubmit"];if(!r||typeof r!="object"||!("kind"in r)||r.kind!=="action")return;let n=go(r,!0);return e==="onSubmit"?`onSubmit={(e) => { e.preventDefault(); void dispatchAction(${n}); }}`:`onClick={() => { void dispatchAction(${n}); }}`}function kh(t){return t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function Ah(t,e){let r=Ut(e,"variant");if(typeof r=="string")return` vc-${kh(t)}--${r}`;let n=G(e,"variant");if(n)return` vc-${kh(t)}--\${${n}}`}function Hr(t,e,r,n){let i=e.className??"";if(e.tag==="dynamic-heading"&&n!==void 0){let s=`${i} vc-heading-${n}`,a=Ah(t,r);return a?typeof Ut(r,"variant")=="string"?`className="${s}${a}"`:`className={\`${s}${a}\`}`:`className="${s}"`}let o=Ah(t,r);if(o)return typeof Ut(r,"variant")=="string"?`className="${i}${o}"`:`className={\`${i}${o}\`}`;if(e.wrapProp&&Ut(r,e.wrapProp)===!0)return`className="${i} vc-wrap"`;if(e.sizeClass&&r.size){let s=G(r,"size");return`className={\`${e.className} ${e.sizeClass}-\${${s} ?? 'md'}\`}`}return`className="${i}"`}function Oh(t,e,r){let n=Ut(e,"label"),i=Ut(e,"help"),o=Ut(e,"error"),s=G(e,"label"),a=G(e,"help"),l=G(e,"error"),u=[`${H(r)}<label className="vc-field">`];return typeof n=="string"?u.push(`${H(r+1)}<span className="vc-field-label">{${JSON.stringify(n)}}</span>`):s&&u.push(`${H(r+1)}{${s} ? <span className="vc-field-label">{${s}}</span> : null}`),u.push(`${H(r+1)}${t}`),typeof i=="string"?u.push(`${H(r+1)}<span className="vc-field-help">{${JSON.stringify(i)}}</span>`):a&&u.push(`${H(r+1)}{${a} ? <span className="vc-field-help">{${a}}</span> : null}`),typeof o=="string"?u.push(`${H(r+1)}<span className="vc-field-error">{${JSON.stringify(o)}}</span>`):l&&u.push(`${H(r+1)}{${l} ? <span className="vc-field-error">{${l}}</span> : null}`),u.push(`${H(r)}</label>`),u.join(`
|
|
510
|
+
`)}function uS(t,e){let r=G(t,"name")??'""',n=G(t,"label")??'""',i=t.checked?`defaultChecked={${G(t,"checked")}}`:"",o=t.enabled?`disabled={${G(t,"enabled")} === false}`:"";return`${H(e)}<label className="vc-checkbox">
|
|
511
|
+
${H(e+1)}<input type="checkbox" name={${r}} ${i} ${o} />
|
|
512
|
+
${H(e+1)}<span>{${n}}</span>
|
|
513
|
+
${H(e)}</label>`}function fS(t,e){let r=G(t,"binding")??G(t,"name")??'""',n=G(t,"value")??'""',i=G(t,"label")??'""',o=t.checked?`defaultChecked={${G(t,"checked")}}`:"",s=t.enabled?`disabled={${G(t,"enabled")} === false}`:"";return`${H(e)}<label className="vc-radio">
|
|
514
|
+
${H(e+1)}<input type="radio" name={${r}} value={${n}} ${o} ${s} />
|
|
515
|
+
${H(e+1)}<span>{${i}}</span>
|
|
516
|
+
${H(e)}</label>`}function pS(t,e){let r=G(t,"binding")??G(t,"name")??'""',n=G(t,"label")??'""',i=t.checked?`defaultChecked={${G(t,"checked")}}`:"",o=t.enabled?`disabled={${G(t,"enabled")} === false}`:"";return`${H(e)}<label className="vc-switch">
|
|
517
|
+
${H(e+1)}<input type="checkbox" role="switch" name={${r}} ${i} ${o} />
|
|
518
|
+
${H(e+1)}<span>{${n}}</span>
|
|
519
|
+
${H(e)}</label>`}function dS(t,e,r){let n=t.props;if(n.alt!==void 0){let s=[Hr(t.name,e,n),`src={${G(n,"name")??'""'}}`,`alt={${G(n,"alt")??'""'}}`];return Yn(s,e,n),n.id&&s.push(`id={${G(n,"id")}}`),`${H(r)}<img ${s.join(" ")} />`}let o=[Hr(t.name,e,n),"aria-hidden"];return Yn(o,e,n),n.id&&o.push(`id={${G(n,"id")}}`),n.name&&o.push(`data-icon={${G(n,"name")}}`),`${H(r)}<span ${o.join(" ")} />`}function Rh(t,e){let r=t.options;if(!r||typeof r!="object"||!("kind"in r))return"";if(r.kind==="literal"&&Array.isArray(r.value))return r.value.map(o=>`${H(e+1)}<option key={${JSON.stringify(o.value)}} value={${JSON.stringify(o.value)}}>{${JSON.stringify(o.label)}}</option>`).join(`
|
|
520
|
+
`);let n=Br(r,0);return`${H(e+1)}{${n}.map((option) => <option key={option.value} value={option.value}>{option.label}</option>)}`}function Ih(t,e,r,n){let i=[Hr(t,e,r)];return Yn(i,e,r),e.ariaHidden&&i.push("aria-hidden"),r.id&&i.push(`id={${G(r,"id")}}`),r.role?i.push(`role={${G(r,"role")}}`):e.defaultRole&&i.push(`role="${e.defaultRole}"`),e.ariaLabel&&(r.ariaLabel?i.push(`aria-label={${G(r,"ariaLabel")}}`):r.label?i.push(`aria-label={${G(r,"label")}}`):r.title&&i.push(`aria-label={${G(r,"title")}}`)),r.name&&i.push(`name={${G(r,"name")}}`),r.placeholder&&i.push(`placeholder={${G(r,"placeholder")}}`),e.inputType&&i.push(`type={${G(r,"type")??JSON.stringify(e.inputType)}}`),r.required&&i.push(`required={${G(r,"required")}}`),r.readonly&&i.push(`readOnly={${G(r,"readonly")}}`),r.enabled&&i.push(`disabled={${G(r,"enabled")} === false}`),e.tag==="img"&&r.src&&i.push(`src={${G(r,"src")}}`),e.tag==="img"&&r.alt&&i.push(`alt={${G(r,"alt")}}`),e.tag==="progress"&&r.value&&i.push(`value={${G(r,"value")}}`),r.rows&&i.push(`rows={${G(r,"rows")??"4"}}`),`${H(n)}<${e.tag} ${i.join(" ")} />`}function Jc(t,e,r,n,i){let o=[];if(e.ariaHidden&&o.push("aria-hidden"),r.id&&o.push(`id={${G(r,"id")}}`),r.role?o.push(`role={${G(r,"role")}}`):e.defaultRole&&o.push(`role="${e.defaultRole}"`),e.ariaLabel&&(r.ariaLabel?o.push(`aria-label={${G(r,"ariaLabel")}}`):r.label?o.push(`aria-label={${G(r,"label")}}`):r.title&&o.push(`aria-label={${G(r,"title")}}`)),e.actionEvent){let s=lS(r,e.actionEvent);s&&o.push(s)}return e.tag==="button"&&r.enabled&&o.push(`disabled={${G(r,"enabled")} === false}`),e.tag==="a"&&r.href&&o.push(`href={${G(r,"href")}}`),e.tag==="button"&&o.push(`type={${G(r,"type")??'"button"'}}`),o.push(Hr(t,e,r,i)),Yn(o,e,r),`<${n} ${o.join(" ")}`}function lt(t,e,r){if(e.visible===void 0)return t;let n=G(e,"visible");return`${H(r)}{${n} !== false ? (
|
|
523
521
|
${t}
|
|
524
|
-
${
|
|
525
|
-
`)}function
|
|
522
|
+
${H(r)}) : null}`}function Xc(t,e,r,n){if(t.length===0)return"";let i=n??"vm";return t.map(s=>{if(s.kind==="text"){let a=s.value;return a?`${H(e)}{${JSON.stringify(a)}}`:""}return s.kind==="binding"?`${H(e)}{${Fr(s,i)}}`:s.kind==="map"?hS(s,e,r):s.kind==="fragment"?Xc(s.children,e,r,n):r(s,e,n)}).filter(Boolean).join(`
|
|
523
|
+
`)}function hS(t,e,r){let n=t.item,i=r(t.body,e+1,n);if(t.key){let o=` key={${Fr(t.key,n)}}`;i=i.replace(/^( +)<(\w+)/,`$1<$2${o}`)}return`${H(e)}{${Fr(t.source)}.map((${n}) => (
|
|
526
524
|
${i}
|
|
527
|
-
${
|
|
528
|
-
${
|
|
529
|
-
${
|
|
530
|
-
${
|
|
531
|
-
${
|
|
532
|
-
${
|
|
533
|
-
${
|
|
534
|
-
${
|
|
535
|
-
${
|
|
536
|
-
${
|
|
537
|
-
${
|
|
525
|
+
${H(e)}))}`}function mS(t,e,r,n,i){let o=t.props,s=Xc(t.children,r+1,i,n);if(e.checkbox)return lt(uS(o,r),o,r);if(t.name==="Radio")return lt(fS(o,r),o,r);if(t.name==="Switch")return lt(pS(o,r),o,r);if(t.name==="Icon")return lt(dS(t,e,r),o,r);if(t.name==="Spinner"){let p=[Hr(t.name,e,o),'aria-busy="true"'];return Yn(p,e,o),o.id&&p.push(`id={${G(o,"id")}}`),o.role?p.push(`role={${G(o,"role")}}`):e.defaultRole&&p.push(`role="${e.defaultRole}"`),lt(`${H(r)}<div ${p.join(" ")} />`,o,r)}if(e.fieldContainer){let p=s||`${H(r+1)}<div />`;return lt(Oh(p,o,r),o,r)}if(e.fieldWrap){let p=e.tag,f;if(e.optionsProp&&o[e.optionsProp]){let h=Jc(t.name,e,o,p);f=`${H(r+1)}${h}>
|
|
526
|
+
${Rh(o,r+2)}
|
|
527
|
+
${H(r+1)}</${p}>`}else f=Ih(t.name,e,o,r+1);return lt(Oh(f,o,r),o,r)}if(e.tag==="dynamic-heading"){let p=Ut(o,"level");if(typeof p=="number"){let P=Math.min(6,Math.max(1,p)),b=`h${P}`,j=Jc(t.name,e,o,b,P),B=s?`${H(r)}${j}>
|
|
528
|
+
${s}
|
|
529
|
+
${H(r)}</${b}>`:`${H(r)}${j} />`;return lt(B,o,r)}let f=G(o,"level")??"2",h=ur(zn(zc(o))),m=h?` ${h}`:"",g=s?`${H(r+1)}{(() => { const __level = Math.min(6, Math.max(1, ${f} ?? 2)); const Tag = ('h' + __level) as keyof JSX.IntrinsicElements; return <Tag className={\`vc-heading vc-heading-\${__level}\`}${m}>{/* children below */}</Tag>; })()}`:"",v=Kc(e,o);return lt(g||`${H(r)}<h2 ${Hr(t.name,e,o,2)}${v?` ${v}`:""} />`,o,r)}let a=e.tag;if(e.void)return lt(Ih(t.name,e,o,r),o,r);let l=Jc(t.name,e,o,a),u;return!s&&e.optionsProp&&o[e.optionsProp]?u=`${H(r)}${l}>
|
|
530
|
+
${Rh(o,r+1)}
|
|
531
|
+
${H(r)}</${a}>`:s?u=`${H(r)}${l}>
|
|
532
|
+
${s}
|
|
533
|
+
${H(r)}</${a}>`:u=`${H(r)}${l} />`,lt(u,o,r)}function gS(t,e){let r=e??"vm";return Object.entries(t).map(([n,i])=>typeof i=="object"&&i!==null&&"kind"in i&&i.kind==="binding"?`${n}={${Fr(i,r)}}`:`${n}={${Br(i,0)}}`).join(" ")}function yS(t,e,r){let n=gS(t.props,r),i=n?` ${n}`:"";return`${H(e)}<${t.name}${i} />`}function vS(t,e){let r=e??"vm";return Object.entries(t).map(([n,i])=>n==="action"&&typeof i=="object"&&i!==null&&"kind"in i&&i.kind==="action"?`${n}={${go(i,!0)}}`:typeof i=="object"&&i!==null&&"kind"in i&&i.kind==="binding"?`${n}={${Fr(i,r)}}`:n==="children"?"":`${n}={${Br(i,0,n==="columns")}}`).join(" ")}function _S(t,e,r,n){let i=vS(t.props,r),o=i?` ${i}`:"",s=Xc(t.children,e+1,n,r);return s?`${H(e)}<${t.name}${o}>
|
|
534
|
+
${s}
|
|
535
|
+
${H(e)}</${t.name}>`:`${H(e)}<${t.name}${o} />`}function Th(t,e,r){return t in e.elements&&!r.includes(t)}function Kn(t,e){if(t.kind==="viewRef"){e.add(t.name);return}if(t.kind==="component"){for(let r of t.children)Kn(r,e);return}if(t.kind==="map"&&Kn(t.body,e),t.kind==="fragment")for(let r of t.children)Kn(r,e)}function Jn(t,e,r,n){if(t.kind==="component"){Th(t.name,e,r)||n.add(t.name);for(let i of t.children)Jn(i,e,r,n);return}if(t.kind==="map"&&Jn(t.body,e,r,n),t.kind==="fragment")for(let i of t.children)Jn(i,e,r,n)}function Nh(t,e){let r=(n,i,o)=>n.kind==="viewRef"?yS(n,i,o):n.kind!=="component"?"":Th(n.name,t,e)?mS(n,t.elements[n.name],i,o,r):_S(n,i,o,r);return(n,i,o)=>r(n,i,o)}function bS(t){if(t.isPartial)return t.exportName;let e=t.exportName.replace(/View$/,"")||t.exportName;return e.charAt(0).toUpperCase()+e.slice(1)}function SS(t,e){if(t.kind!=="component")throw new Error(`View IR root must be a component node (${e})`);return t}function ES(t){if(!t)return[];let e=t.match(/\b[A-Z][A-Za-z0-9]*ViewModel\b/g);return e?[...new Set(e)]:[]}function $S(t){if(!t.propsType)return"";let e=t.propsType.match(/^\{\s*([^}]+)\s*\}$/);return e?`{ ${e[1].trim().split(",").map(i=>i.split(":")[0].trim()).join(", ")} }: ${t.propsType}`:`props: ${t.propsType}`}function Mh(t){return t.trimStart().startsWith("{")?`return (
|
|
536
|
+
<>${t}
|
|
537
|
+
</>
|
|
538
|
+
);`:`return (
|
|
539
|
+
${t}
|
|
540
|
+
);`}async function xS(t,e){let r=await Eh(e.elementMapPath),n=e.allowlistExtra??[],i=bS(t),o=SS(t.root,t.source),a=Nh(r,n)(o,2),l=new Set;Jn(t.root,r,n,l);let u=[...l].sort(),p=new Set;Kn(t.root,p);let f=[...p].sort(),h=e.previewImports,m=h?.dispatch??e.runtimeImportFrom,g=h?.contracts??e.contractsImportFrom,v=h?.extensions??e.extensionsImportFrom,P=new Set;if(t.isPartial)for(let T of ES(t.propsType))P.add(T);else P.add(t.viewModel);let b=["import type { ReactElement } from 'react';"];b.push(`import { dispatchAction } from '${m}';`);let j=[...P].sort(),B=j.length>0?`${j.join(", ")}, ActionDescriptor`:"ActionDescriptor";b.push(`import type { ${B} } from '${g}';`),u.length>0&&b.push(`import { ${u.join(", ")} } from '${v}';`);for(let T of f){if(e.inlineViewRefs)continue;let Q=e.viewRefImportFrom?.get(T)??`./${T}.generated.js`;b.push(`import { ${T} } from '${Q}';`)}let L=h?`/**
|
|
538
541
|
* Preview module \u2014 compiled live from ${t.source}
|
|
539
542
|
* Same lowering as generated/; not written to disk.
|
|
540
543
|
*/`:`/**
|
|
541
544
|
* Auto-generated React component from ${t.source}
|
|
542
545
|
* DO NOT EDIT \u2014 regenerate with: view-contracts render react
|
|
543
|
-
|
|
544
|
-
${
|
|
546
|
+
*/`;if(t.isPartial){let T=$S(t);return`${L}
|
|
547
|
+
${b.join(`
|
|
548
|
+
`)}
|
|
549
|
+
|
|
550
|
+
export function ${i}(${T}): ReactElement {
|
|
551
|
+
${Mh(a)}
|
|
552
|
+
}
|
|
553
|
+
`}return`${L}
|
|
554
|
+
${b.join(`
|
|
545
555
|
`)}
|
|
546
556
|
|
|
547
|
-
export function ${
|
|
548
|
-
|
|
549
|
-
${l}
|
|
550
|
-
);
|
|
557
|
+
export function ${i}({ vm }: { vm: ${t.viewModel} }): ReactElement {
|
|
558
|
+
${Mh(a)}
|
|
551
559
|
}
|
|
552
|
-
`}async function
|
|
553
|
-
`)}return r.replace(
|
|
554
|
-
`)}function
|
|
560
|
+
`}async function Qc(t,e,r){let{writeFile:n,mkdir:i}=await import("node:fs/promises"),{dirname:o}=await import("node:path"),s=await xS(t,r);await i(o(e),{recursive:!0}),await n(e,s,"utf-8")}function Lh(t,e){return wS(t,"components",`${e.exportName}.generated.tsx`)}import{writeFile as zg,stat as tC,unlink as rC}from"node:fs/promises";import{relative as nC,resolve as rn}from"node:path";import{readFile as QS,stat as ZS}from"node:fs/promises";import{resolve as eE}from"node:path";import{readFile as jh}from"node:fs/promises";import{createRequire as CS}from"node:module";import{dirname as PS,resolve as Vh}from"node:path";var Dh=/^@import\s+['"](.+?)['"]\s*;/gm,kS=CS(import.meta.url);async function AS(t,e){return t.startsWith("@")||!t.startsWith(".")&&!t.startsWith("/")?kS.resolve(t):Vh(e,t)}async function qh(t){let e=Vh(t),r=await jh(e,"utf-8"),n=PS(e);for(let i of r.matchAll(Dh)){let o=i[0],s=i[1];if(!s)continue;let a=await AS(s,n),l=await jh(a,"utf-8");r=r.replace(o,`${l}
|
|
561
|
+
`)}return r.replace(Dh,"").trim()}import{resolve as Fh}from"node:path";function yo(t){return t??Fh(Ye(),"renderers/react/templates")}function vo(){return Fh(Ye(),"renderers/react/runtime")}import{readFile as OS}from"node:fs/promises";import{extname as RS,resolve as IS}from"node:path";async function _o(t){let e=IS(t),r=await OS(e,"utf-8"),n=RS(e).toLowerCase();if(n===".json")return JSON.parse(r);if(n===".yaml"||n===".yml")return Ct.load(r);throw new Error(`Unsupported design file extension "${n}" (expected .yaml, .yml, or .json): ${e}`)}var wo=["color","dimension","shadow","typography","layout"],ht=class extends Error{constructor(e){super(e),this.name="DesignTokenError"}},fr=["background","foreground","radius","padding","shadow","typography","display","gridTemplateColumns","minHeight","maxWidth","width","margin","border","borderColor","flexDirection","fontWeight","fontSize","alignItems","justifyContent"],bo={background:["color"],foreground:["color"],radius:["dimension","layout"],padding:["dimension","layout"],shadow:["shadow"],typography:["typography"],display:["layout"],gridTemplateColumns:["layout"],minHeight:["dimension","layout"],maxWidth:["dimension","layout"],width:["dimension","layout"],margin:["dimension","layout"],border:["layout"],borderColor:["color"],flexDirection:["layout"],fontWeight:["layout"],fontSize:["dimension","layout"],alignItems:["layout"],justifyContent:["layout"]},we=class extends Error{constructor(e){super(e),this.name="DesignThemeError"}},Ur=class extends Error{constructor(e){super(e),this.name="DesignConstraintError"}};var TS=/^\{([^}]+)\}$/;function Gr(t){return typeof t=="object"&&t!==null&&!Array.isArray(t)}function NS(t){if(!fr.includes(t))throw new we(`Unknown variant property "${t}" (expected ${fr.join(", ")})`);return t}function MS(t,e,r){if(typeof t!="string")throw new we(`${e}.${r} must be a token reference string like "{ui.primary}"`);let n=t.match(TS);if(!n)throw new we(`${e}.${r} must be a token reference like "{ui.primary}", got "${t}"`);return n[1]}function Hh(t,e){let r={};for(let[n,i]of Object.entries(e)){let o=NS(n),s=MS(i,t,n);r[o]={ref:s,accepts:[...bo[o]]}}return r}function LS(t){if(t===void 0)return{};if(!Gr(t))throw new we('Theme "defaults" must be an object');let e={};for(let[r,n]of Object.entries(t)){if(!Gr(n))throw new we(`Theme defaults for "${r}" must be an object`);e[r]=Hh(`defaults.${r}`,n)}return e}function Zc(t){if(!Gr(t))throw new we("Theme document must be a YAML/JSON object");let e=t.variants;if(!Gr(e))throw new we('Theme document must contain a "variants" object');let r={};for(let[n,i]of Object.entries(e)){if(!Gr(i))throw new we(`Theme variants for "${n}" must be an object`);let o={};for(let[s,a]of Object.entries(i)){if(!Gr(a))throw new we(`Theme variant "${n}.${s}" must be an object`);o[s]=Hh(`${n}.${s}`,a)}r[n]=o}return{defaults:LS(t.defaults),variants:r}}var jS=/^\{([^}]+)\}$/;function Xn(t){return typeof t=="object"&&t!==null&&!Array.isArray(t)}function DS(t){return`--${t.replace(/\./g,"-")}`}function VS(t,e){if(typeof t!="string"||!wo.includes(t))throw new ht(`Token "${e}" has unsupported $type "${String(t)}" (expected ${wo.join(", ")})`);return t}function Bh(t,e,r){if(Xn(t)){if("$type"in t&&"$value"in t){r.push({path:e,type:VS(t.$type,e),rawValue:t.$value});return}for(let[n,i]of Object.entries(t)){if(n.startsWith("$"))continue;let o=e?`${e}.${n}`:n;Bh(i,o,r)}}}function qS(t,e){if(typeof e=="string")return e;if(t==="typography"&&Xn(e)){if(typeof e.fontFamily=="string")return e.fontFamily;let r=[e.fontWeight,e.fontStyle,e.fontSize,e.lineHeight,e.fontFamily].filter(n=>n!=null);if(r.length>0)return r.map(String).join(" ")}if(t==="shadow"&&Array.isArray(e))return e.map(r=>Xn(r)?`${r.offsetX??0} ${r.offsetY??0} ${r.blur??0} ${r.color??"transparent"}`:String(r)).join(", ");if(t==="shadow"&&Xn(e))return`${e.offsetX??0} ${e.offsetY??0} ${e.blur??0} ${e.color??"transparent"}`;throw new ht(`Token value for "${t}" must be a string or supported object`)}function FS(t){return typeof t!="string"?null:t.match(jS)?.[1]??null}function Uh(t,e,r,n,i){let o=FS(e);if(!o){let l=r.get(t);if(!l)throw new ht(`Unknown token path "${t}"`);return{value:qS(l.type,e)}}if(n.has(t))throw new ht(`Circular token reference detected at "${t}"`);let s=r.get(o);if(!s)throw new ht(`Token "${t}" references unknown token "{${o}}"`);if(i.has(o))return{value:i.get(o),ref:o};n.add(t);let a=Uh(o,s.rawValue,r,n,i);return n.delete(t),i.set(o,a.value),{value:a.value,ref:o}}function el(t){if(!Xn(t))throw new ht("Token document must be a YAML/JSON object");let e=[];Bh(t,"",e);let r=new Map(e.map(o=>[o.path,o])),n=new Map,i=[];for(let o of e){let{value:s,ref:a}=Uh(o.path,o.rawValue,r,new Set,n);n.set(o.path,s),i.push({path:o.path,type:o.type,value:s,cssVar:DS(o.path),ref:a})}return{entries:i}}var HS=new Set(["App","Box","Button","Column","Field","Form","Heading","IconButton","Image","Link","List","ListItem","Modal","Page","Row","SafeArea","Stack","Text"]);function tl(t,e){let r=new Set;if(HS.has(e)){for(let n of fr)r.add(n);return r}for(let n of ho(t,e))fr.includes(n)&&r.add(n);return r}function BS(t){return new Map(t.entries.map(e=>[e.path,e]))}function Gh(t,e,r,n,i){for(let[o,s]of Object.entries(r)){let a=bo[o];if(!a)throw new we(`Unknown variant property "${o}" on ${t}`);if(!n.has(o))throw new we(`Property "${o}" is not allowed for ${e} in ${t}`);let l=i.get(s.ref);if(!l)throw new we(`${t}.${o} references unknown token "{${s.ref}}"`);if(!a.includes(l.type))throw new we(`${t}.${o} requires a ${a.join(" or ")} token, but "{${s.ref}}" is ${l.type}`)}}async function Wh(t,e){let r=await Gn(),n=BS(t);for(let[i,o]of Object.entries(e.defaults)){let s=tl(r,i);Gh(`defaults.${i}`,i,o,s,n)}for(let[i,o]of Object.entries(e.variants)){let s=tl(r,i);for(let[a,l]of Object.entries(o))Gh(`variants.${i}.${a}`,i,l,s,n)}}async function rl(t,e){await Wh(t,e)}function nl(t){let e=[":root {"];for(let r of t.entries)e.push(` ${r.cssVar}: ${r.value};`);return e.push("}"),e.join(`
|
|
562
|
+
`)}function il(t){return t.replace(/:root\s*\{[\s\S]*?\}\s*/m,"").trim()}var So={background:"background",foreground:"color",radius:"border-radius",padding:"padding",shadow:"box-shadow",typography:"font",display:"display",gridTemplateColumns:"grid-template-columns",minHeight:"min-height",maxWidth:"max-width",width:"width",margin:"margin",border:"border",borderColor:"border-color",flexDirection:"flex-direction",fontWeight:"font-weight",fontSize:"font-size",alignItems:"align-items",justifyContent:"justify-content"};function Eo(t){return t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function $o(t,e){let r=t.entries.find(n=>n.path===e);if(!r)throw new Error(`Token reference "${e}" not found while emitting theme CSS`);return r.cssVar}function ol(t,e){let r=[];for(let[n,i]of Object.entries(e.defaults)){let o=Eo(n),s=[];for(let[a,l]of Object.entries(i)){let u=So[a],p=$o(t,l.ref);s.push(` ${u}: var(${p});`)}s.length!==0&&r.push(`.vc-${o} {
|
|
563
|
+
${s.join(`
|
|
564
|
+
`)}
|
|
565
|
+
}`)}return r.join(`
|
|
566
|
+
|
|
567
|
+
`)}function sl(t,e){let r=[];for(let[n,i]of Object.entries(e.variants)){let o=Eo(n);for(let[s,a]of Object.entries(i)){let l=[];for(let[u,p]of Object.entries(a)){let f=So[u],h=$o(t,p.ref);l.push(` ${f}: var(${h});`)}l.length!==0&&r.push(`.vc-${o}--${s} {
|
|
555
568
|
${l.join(`
|
|
556
569
|
`)}
|
|
557
570
|
}`)}}return r.join(`
|
|
558
571
|
|
|
559
|
-
`)}
|
|
572
|
+
`)}function zh(t){return typeof t=="object"&&t!==null&&"kind"in t&&t.kind==="binding"}function US(t){if(t.variant!==void 0)return t.variant;if(t.tone!==void 0)return t.tone}function Kh(t,e,r,n,i,o){let s=r.variants[t];if(!s){e!==void 0&&!zh(e)&&typeof e=="string"&&i.push(`${n}: <${t}> references variant "${e}" but no variants are defined for ${t} in theme.yaml`);return}if(e===void 0||zh(e)||typeof e!="string")return;(o?.mapMutedToDefault&&e==="muted"?"default":e)in s||i.push(`${n}: <${t}> references unknown variant "${e}" (not defined in theme.yaml)`)}function xo(t,e,r,n){if(t.kind==="component"){let i=US(t.props);t.props.variant!==void 0?Kh(t.name,t.props.variant,e,r,n):i!==void 0&&t.name in e.variants&&Kh(t.name,i,e,r,n,{mapMutedToDefault:!0});for(let o of t.children)xo(o,e,r,n);return}if(t.kind==="map"){xo(t.body,e,r,n);return}if(t.kind==="fragment"){for(let i of t.children)xo(i,e,r,n);return}t.kind}function al(t,e){let r=[];for(let n of t)xo(n.root,e,n.source,r);if(r.length>0)throw new Error(`View variant validation failed:
|
|
560
573
|
${r.map(n=>` - ${n}`).join(`
|
|
561
|
-
`)}`)}var
|
|
574
|
+
`)}`)}var GS=/\.vc-[a-z][\w-]*/g,WS=/(?:className\s*=\s*(?:"vc-[^"]*"|'vc-[^']*'|\{`[^`]*\bvc-[^`]*`\}|\{"vc-[^"]*"\}|\{'vc-[^']*'\})|["'`]vc-[a-z][\w-]*["'`])/g,zS=/\bextensionClassName\s*\(/g;function cl(t,e){return[...new Set([...t.matchAll(e)].map(r=>r[0]))]}function Jh(t,e,r){let n=e.slice(0,5).map(o=>` - ${t}: ${o}`).join(`
|
|
562
575
|
`),i=e.length>5?`
|
|
563
576
|
\u2026 and ${e.length-5} more`:"";return`${r}
|
|
564
|
-
${n}${i}`}function
|
|
577
|
+
${n}${i}`}function ll(t,e){let r=cl(t,GS);if(r.length!==0)throw new Ur(Jh(e,r,".vc-* selectors are reserved for DSL output (theme.yaml variants + package structural CSS). Use project-owned class names (e.g. ext-*) in extension CSS."))}function ul(t,e){let r=cl(t,WS),n=cl(t,zS),i=[...r,...n];if(i.length!==0)throw new Ur(Jh(e,i,".vc-* class names are reserved for DSL lowering output. Extension components must use project-owned class names (e.g. ext-*) in src/components/."))}import{readFile as Yh,stat as KS}from"node:fs/promises";import{resolve as JS}from"node:path";async function Xh(t){try{return await KS(t),!0}catch{return!1}}async function Qn(t,e){let r=t.design?.extensionsCss;r&&await Xh(r)&&ll(await Yh(r,"utf-8"),r);let n=_e(e);for(let i of["extensions.tsx","extensions.ts"]){let o=JS(n,"src/components",i);await Xh(o)&&ul(await Yh(o,"utf-8"),o)}}async function YS(t){let e=await _o(t);return el(e)}async function XS(t){let e=await _o(t);return Zc(e)}async function Co(t,e){let r=await YS(t),n=await XS(e);return await rl(r,n),{tokenIR:r,themeIR:n}}async function tE(t){try{return await ZS(t),!0}catch{return!1}}async function fl(t,e){let r=_e(e),{tokensPath:n,themePath:i}=Ri(t),{tokenIR:o,themeIR:s}=await Co(n,i);await Qn(t,e);let a=await qh(eE(vo(),"theme.css")),l=il(a),u=ol(o,s),p=sl(o,s),f=`${nl(o)}
|
|
578
|
+
|
|
579
|
+
${l}`;u&&(f+=`
|
|
565
580
|
|
|
566
|
-
${
|
|
581
|
+
${u}`),f+=`
|
|
567
582
|
|
|
568
|
-
${
|
|
583
|
+
${p}`;let h=t.design?.extensionsCss;return h&&await tE(h)&&(f+=`
|
|
569
584
|
|
|
570
|
-
${await
|
|
571
|
-
|
|
572
|
-
`,"utf-8")
|
|
585
|
+
${await QS(h,"utf-8")}`),f}var Bg=xi(Fg(),1);import{readFile as zx}from"node:fs/promises";import{resolve as Kx}from"node:path";var Hg=new Map;async function yt(t,e,r){let n=Kx(t,e),i=Hg.get(n);if(!i){let o=await zx(n,"utf-8");i=Bg.default.compile(o,{noEscape:!0}),Hg.set(n,i)}return i(r)}import{readFile as Ug,writeFile as Jx,mkdir as Yx,stat as Xx,rm as Qx,unlink as Zx}from"node:fs/promises";import{resolve as Tt}from"node:path";async function Gg(t){try{return await Xx(t),!0}catch{return!1}}async function iu(t){let e=Tt(t,"..");for(let r of[Tt(t,"runtime"),Tt(e,"components"),Tt(e,"runtime")])await Gg(r)&&await Qx(r,{recursive:!0,force:!0});for(let r of["extensions.tsx","extensions.ts","contracts.ts"]){let n=Tt(t,r);await Gg(n)&&await Zx(n)}}function eC(t){return t.replace(/^import type \{ DispatchableAction \} from [^;]+;\n/gm,"")}async function Wg(t,e,r){let n=_e(t),i=e.generated.reactDir,o=yo(r??(e.rendererTemplatesDir?Tt(n,e.rendererTemplatesDir):void 0)),s=vo();await Yx(i,{recursive:!0}),await iu(i);let a=await Ug(Tt(s,"types.ts"),"utf-8"),l=await Ug(Tt(s,"style.ts"),"utf-8"),u=await yt(o,"dispatch.ts.hbs",{}),p=eC(u),f=await yt(o,"runtime.ts.hbs",{typesBody:a.trim(),styleBody:l.trim(),dispatchBody:p.trim()}),h=Tt(i,"runtime.ts");return await Jx(h,f,"utf-8"),{runtimePath:h}}async function iC(t){try{return await tC(t),!0}catch{return!1}}async function oC(t,e,r,n){let i=await fl(r,t),o=await yt(yo(n),"theme.css.hbs",{themeCss:i});await zg(e,o,"utf-8")}async function sC(t){let e=rn(t,"..");for(let r of["theme.css","contracts.ts","view-bridge.generated.ts"]){let n=rn(e,r);await iC(n)&&await rC(n)}}async function aC(t,e){let r=_e(t),n=e.generated.reactDir,i=rn(r,"src/components/extensions.tsx"),o=nC(n,i).replace(/\\/g,"/");o.startsWith(".")||(o=`./${o}`);let s=o.replace(/\.tsx?$/,".js"),a=rn(n,"extensions.generated.ts");return await zg(a,`/** Auto-generated extension re-export \u2014 DO NOT EDIT */
|
|
586
|
+
export * from '${s}';
|
|
587
|
+
`,"utf-8"),a}async function Kg(t,e){let r=_e(t),n=e.rendererTemplatesDir?rn(r,e.rendererTemplatesDir):void 0,i=e.generated.reactDir;await sC(i),await iu(i);let{runtimePath:o}=await Wg(t,e,n),s=await aC(t,e),a=rn(i,"theme.css");await oC(t,a,e,n),console.log(` react/runtime \u2192 ${o}`),console.log(` react/extensions \u2192 ${s}`),console.log(` react/theme \u2192 ${a}`)}var cC=new Set(["children","action","onClick","onSubmit","onChange","level","headingLevel"]);function lC(t,e){return e==="variant"||e==="theme"?!0:t.properties[e]?.["x-category"]==="visual"}function di(t,e,r,n,i){if(t.kind==="component"){let{name:o,props:s}=t;if(n.has(o)||!(o in e.elements)){for(let l of t.children)di(l,e,r,n,i);return}let a=new Set(ho(e,o));for(let l of Object.keys(s))if(!cC.has(l)&&lC(e,l)){if(!a.has(l)){i.push(`${r}: <${o}> does not accept property "${l}"`);continue}bh(e,l,o)||i.push(`${r}: property "${l}" does not apply to <${o}>`)}for(let l of t.children)di(l,e,r,n,i);return}if(t.kind==="map"){di(t.body,e,r,n,i);return}if(t.kind==="fragment"){for(let o of t.children)di(o,e,r,n,i);return}t.kind}async function Jg(t,e=[]){let r=await Gn(),n=new Set(e),i=[];for(let o of t)di(o.root,r,o.source,n,i);if(i.length>0)throw new Error(`View property validation failed:
|
|
588
|
+
${i.map(o=>` - ${o}`).join(`
|
|
589
|
+
`)}`)}import{access as uC,writeFile as Ze,mkdir as us}from"node:fs/promises";import{resolve as Be,dirname as Yg}from"node:path";async function ou(t){try{return await uC(t),!0}catch{return!1}}var nn={preview:5173,app:5174,built:4174},Xg=`{
|
|
573
590
|
"name": "admin-dashboard",
|
|
574
591
|
"private": true,
|
|
575
592
|
"type": "module",
|
|
@@ -596,8 +613,8 @@ ${await lS(f,"utf-8")}`),d}var ag=io(sg(),1);import{readFile as iC}from"node:fs/
|
|
|
596
613
|
"vite": "^6.4.1"
|
|
597
614
|
}
|
|
598
615
|
}
|
|
599
|
-
`,
|
|
600
|
-
`,
|
|
616
|
+
`,fC=`import '../src/main.tsx';
|
|
617
|
+
`,pC=`<!doctype html>
|
|
601
618
|
<html lang="en">
|
|
602
619
|
<head>
|
|
603
620
|
<meta charset="UTF-8" />
|
|
@@ -609,7 +626,7 @@ ${await lS(f,"utf-8")}`),d}var ag=io(sg(),1);import{readFile as iC}from"node:fs/
|
|
|
609
626
|
<script type="module" src="./app-main.tsx"></script>
|
|
610
627
|
</body>
|
|
611
628
|
</html>
|
|
612
|
-
`,
|
|
629
|
+
`,dC=`<!doctype html>
|
|
613
630
|
<html lang="en">
|
|
614
631
|
<head>
|
|
615
632
|
<meta charset="UTF-8" />
|
|
@@ -621,7 +638,7 @@ ${await lS(f,"utf-8")}`),d}var ag=io(sg(),1);import{readFile as iC}from"node:fs/
|
|
|
621
638
|
<script type="module" src="./preview-main.tsx"></script>
|
|
622
639
|
</body>
|
|
623
640
|
</html>
|
|
624
|
-
`;function
|
|
641
|
+
`;function hC(t){let r=t.views.filter(o=>o.targets.includes("react"))[0];if(!r)throw new Error("No react target views in bindings \u2014 cannot scaffold preview entry.");let n=r.screenName,i=`${n.charAt(0).toLowerCase()}${n.slice(1)}Mock`;return`import React from 'react';
|
|
625
642
|
import ReactDOM from 'react-dom/client';
|
|
626
643
|
import 'view-contracts:theme.css';
|
|
627
644
|
import { ${n} } from 'view-contracts:screen/${n}.tsx';
|
|
@@ -637,40 +654,39 @@ ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
|
|
|
637
654
|
<${n} vm={${i}} />
|
|
638
655
|
</React.StrictMode>,
|
|
639
656
|
);
|
|
640
|
-
`}function
|
|
657
|
+
`}function mC(t){let r=t.views.filter(s=>s.targets.includes("react"))[0];if(!r)throw new Error("No react target views in bindings \u2014 cannot scaffold app entry.");let n=r.screenName,i=r.viewModel,o=`${n.charAt(0).toLowerCase()}${n.slice(1)}Mock`;return`import React from 'react';
|
|
641
658
|
import ReactDOM from 'react-dom/client';
|
|
642
|
-
import '../generated/theme.css';
|
|
659
|
+
import '../generated/react/theme.css';
|
|
643
660
|
import type { ${i} } from '../contracts/view-models';
|
|
644
661
|
import { ${n} } from '../generated/react/${n}.generated';
|
|
645
|
-
import { ${
|
|
646
|
-
import { registerActionHandler } from '../generated/runtime
|
|
647
|
-
import { handleAppAction } from '../generated/runtime/handlers';
|
|
662
|
+
import { ${o} } from 'view-contracts:preview/mock/${n}';
|
|
663
|
+
import { registerActionHandler, handleAppAction } from '../generated/react/runtime';
|
|
648
664
|
|
|
649
665
|
registerActionHandler(handleAppAction);
|
|
650
666
|
|
|
651
667
|
/** Example bootstrap only \u2014 production loads ViewModels from the API (operationId in view-bindings). */
|
|
652
|
-
const vm = ${
|
|
668
|
+
const vm = ${o} as ${i};
|
|
653
669
|
|
|
654
670
|
ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
|
|
655
671
|
<React.StrictMode>
|
|
656
672
|
<${n} vm={vm} />
|
|
657
673
|
</React.StrictMode>,
|
|
658
674
|
);
|
|
659
|
-
`}var
|
|
675
|
+
`}var gC=`/** Hand-written action handlers \u2014 edit src/runtime/handlers.ts */
|
|
660
676
|
import type { DispatchableAction } from './types.js';
|
|
661
677
|
|
|
662
678
|
export async function handleAppAction(action: DispatchableAction): Promise<void> {
|
|
663
679
|
console.log('[app action]', action);
|
|
664
680
|
}
|
|
665
|
-
`;function
|
|
666
|
-
export const PREVIEW_PORT = ${
|
|
667
|
-
export const APP_PORT = ${
|
|
668
|
-
export const BUILT_PORT = ${
|
|
669
|
-
`}function
|
|
670
|
-
PREVIEW_PORT=${
|
|
671
|
-
APP_PORT=${
|
|
672
|
-
BUILT_PORT=${
|
|
673
|
-
`}function
|
|
681
|
+
`;function yC(){return`/** Fixed dev server ports \u2014 single source of truth for this example. */
|
|
682
|
+
export const PREVIEW_PORT = ${nn.preview};
|
|
683
|
+
export const APP_PORT = ${nn.app};
|
|
684
|
+
export const BUILT_PORT = ${nn.built};
|
|
685
|
+
`}function vC(){return`# Fixed dev server ports \u2014 keep in sync with dev.ports.ts
|
|
686
|
+
PREVIEW_PORT=${nn.preview}
|
|
687
|
+
APP_PORT=${nn.app}
|
|
688
|
+
BUILT_PORT=${nn.built}
|
|
689
|
+
`}function _C(){return`import { defineConfig } from 'vite';
|
|
674
690
|
import react from '@vitejs/plugin-react';
|
|
675
691
|
import path from 'node:path';
|
|
676
692
|
import { fileURLToPath } from 'node:url';
|
|
@@ -707,7 +723,7 @@ export default defineConfig({
|
|
|
707
723
|
},
|
|
708
724
|
},
|
|
709
725
|
});
|
|
710
|
-
`}function
|
|
726
|
+
`}function wC(){return`import path from 'node:path';
|
|
711
727
|
import { defineConfig } from 'vite';
|
|
712
728
|
import react from '@vitejs/plugin-react';
|
|
713
729
|
import { fileURLToPath } from 'node:url';
|
|
@@ -745,10 +761,10 @@ export default defineConfig({
|
|
|
745
761
|
},
|
|
746
762
|
},
|
|
747
763
|
});
|
|
748
|
-
`}async function
|
|
749
|
-
`,"utf-8"):await
|
|
750
|
-
`,"utf-8"),await
|
|
751
|
-
`),"utf-8"),console.log(`Bridge registry \u2192 ${e.generated.bridge} (${r.views.length} view(s))`)}var
|
|
764
|
+
`}async function Qg(t,e,r){let n=_e(t),i=Be(n,".vite");await us(i,{recursive:!0});let o=Be(n,"package.json");await ou(o)?await Ze(o,`${Xg}
|
|
765
|
+
`,"utf-8"):await Ze(o,`${Xg}
|
|
766
|
+
`,"utf-8"),await Ze(Be(i,"index.html"),pC,"utf-8"),await Ze(Be(i,"preview.html"),dC,"utf-8"),await Ze(Be(i,"preview-main.tsx"),hC(r),"utf-8"),await Ze(Be(i,"app-main.tsx"),fC,"utf-8"),await Ze(Be(i,"vite.config.ts"),_C(),"utf-8"),await Ze(Be(i,"vite.preview.config.ts"),wC(),"utf-8"),await Ze(Be(n,"dev.ports.ts"),yC(),"utf-8");let s=Be(n,"scripts");await us(s,{recursive:!0}),await Ze(Be(s,"ports.sh"),vC(),"utf-8");let a=Be(n,"src/main.tsx");await ou(a)||(await us(Yg(a),{recursive:!0}),await Ze(a,mC(r),"utf-8"));let l=Be(n,"src/runtime/handlers.ts");await ou(l)||(await us(Yg(l),{recursive:!0}),await Ze(l,gC,"utf-8")),console.log(` scaffold \u2192 ${i}/`)}import{mkdir as Zg,writeFile as fs}from"node:fs/promises";import{resolve as zt}from"node:path";function ey(){return zt(Ye(),"renderers/swiftui/templates")}function ty(){return zt(Ye(),"renderers/compose/templates")}async function ry(t,e,r){let n=_e(t),i=zt(e.generated.reactDir,"../swiftui"),o=zt(e.generated.reactDir,"../compose");await Zg(i,{recursive:!0}),await Zg(o,{recursive:!0}),await fs(zt(i,"VcTheme.swift"),await yt(ey(),"VcTheme.swift.hbs",{}),"utf-8"),await fs(zt(o,"VcTheme.kt"),await yt(ty(),"VcTheme.kt.hbs",{packageName:"generated.compose"}),"utf-8");for(let s of r.views){if(s.targets.includes("swiftui")){let a=zt(i,`${s.screenName}.swift`);await fs(a,await yt(ey(),"Screen.swift.hbs",{screenName:s.screenName}),"utf-8"),console.log(` swiftui \u2192 ${a}`)}if(s.targets.includes("compose")){let a=zt(o,`${s.screenName}Screen.kt`);await fs(a,await yt(ty(),"Screen.kt.hbs",{screenName:s.screenName,packageName:"generated.compose"}),"utf-8"),console.log(` compose \u2192 ${a}`)}}console.log(` native scaffold \u2192 ${i}/, ${o}/`)}async function au(t){if(!t.extensions)return{allowlistExtra:t.allowlistExtra??[]};let e=await mh(t.extensions),r=[...new Set([...t.allowlistExtra??[],...Object.keys(e.extensions)])];return{extensionRegistry:e,allowlistExtra:r}}async function ny(t){await new Promise((e,r)=>{let n=$C("npx",["micro-contracts",...t],{stdio:"inherit"});n.on("error",r),n.on("close",i=>{i===0?e():r(new Error(`micro-contracts exited with code ${i}`))})})}async function su(t){let e=await Xt(t),r=await dn(e.bindings),{extensionRegistry:n,allowlistExtra:i}=await au(e),o=_e(t),{screens:s,partials:a}=await Fu(r.views.map(l=>({sourcePath:vt(o,l.source),exportName:l.exportName,screenName:l.screenName})),{allowlistExtra:i,extensionRegistry:n});return{screens:new Map(r.views.map((l,u)=>[l.screenName,s[u]])),partials:a}}function vr(t,e){let r=EC(sy(t),e).replace(/\\/g,"/");return r.startsWith(".")||(r=`./${r}`),r.replace(/\.tsx?$/,".js")}async function iy(t,e,r){let n=await Xt(t),i=_e(t),{allowlistExtra:o}=await au(n),s=await dn(n.bindings);for(let a of r){let l=vt(n.generated.reactDir,"components",`${a.exportName}.generated.tsx`),u=vr(l,vt(n.generated.reactDir,"runtime.ts")),p=vr(l,vt(n.generated.reactDir,"extensions.generated.ts")),f=vr(l,vt(i,"contracts/view-models.ts"));await Qc(a,l,{runtimeImportFrom:u,extensionsImportFrom:p,contractsImportFrom:f,allowlistExtra:o}),console.log(` ${a.exportName} \u2192 ${l}`)}for(let a of s.views){if(!a.targets.includes("react"))continue;let l=e.get(a.screenName);if(!l)throw new Error(`Missing View IR for ${a.screenName}`);let u=uf(n,a),p=vr(u,vt(n.generated.reactDir,"runtime.ts")),f=vr(u,vt(n.generated.reactDir,"extensions.generated.ts")),h=vr(u,vt(i,"contracts/view-models.ts")),m=new Map;for(let g of r){let v=Lh(n.generated.reactDir,g);m.set(g.exportName,vr(u,v))}await Qc(l,u,{runtimeImportFrom:p,extensionsImportFrom:f,contractsImportFrom:h,allowlistExtra:o,viewRefImportFrom:m}),console.log(` ${a.exportName} \u2192 ${u}`)}}async function oy(t){let e=await Xt(t),r=await dn(e.bindings),n=_e(t),o=["// Auto-generated view bridge registry \u2014 DO NOT EDIT",`// Generated from ${ff(n,e.bindings)}`,"","export const viewBridgeRegistry = {"];for(let s of r.views)o.push(` ${s.screenConst}: {`),o.push(` id: ${JSON.stringify(s.id)},`),o.push(` screenId: ${JSON.stringify(s.screenId)},`),o.push(` screenName: ${JSON.stringify(s.screenName)},`),o.push(` route: ${JSON.stringify(s.route)},`),o.push(` operationId: ${JSON.stringify(s.operationId)},`),o.push(` viewModel: ${JSON.stringify(s.viewModel)},`),o.push(` source: ${JSON.stringify(s.source)},`),o.push(` targets: ${JSON.stringify(s.targets)},`),o.push(" },");o.push("} as const;",""),o.push("export type ViewBridgeKey = keyof typeof viewBridgeRegistry;",""),await SC(sy(vt(e.generated.bridge)),{recursive:!0}),await bC(vt(e.generated.bridge),o.join(`
|
|
767
|
+
`),"utf-8"),console.log(`Bridge registry \u2192 ${e.generated.bridge} (${r.views.length} view(s))`)}var ay={compile:async(t,e)=>{let{screens:r,partials:n}=await su(await Yt(t.config));console.log(`Compiled ${r.size} screen(s) and ${n.length} partial(s) to View IR (in-memory)`)},renderReact:async(t,e)=>{let r=await Yt(t.config),{screens:n,partials:i}=await su(r);await iy(r,n,i)},renderBridge:async(t,e)=>{await oy(await Yt(t.config))},build:async(t,e)=>{let r=await Yt(t.config),n=await Xt(r),i=await dn(n.bindings),{screens:o,partials:s}=await su(r);console.log(`Compiled ${o.size} screen(s) and ${s.length} partial(s) to View IR (in-memory)`);let{tokensPath:a,themePath:l}=Ri(n),{themeIR:u}=await Co(a,l);await Qn(n,r);let{allowlistExtra:p}=await au(n),f=[...o.values(),...s];await Jg(f,p),al(f,u),await Kg(r,n),await iy(r,o,s),await oy(r),await ry(r,n,i),await Qg(r,n,i)},contractsGenerate:async(t,e)=>{let r=await Xt(await Yt(t.config));await ny(["generate","-c",r.microContractsConfig]),console.log("Contracts generated via micro-contracts")},contractsCheck:async(t,e)=>{let r=await Xt(await Yt(t.config));await ny(["lint","-c",r.microContractsConfig])}};var xC={version:"0.3.5"};Cu(ay,xC.version).parseAsync(process.argv).catch(t=>{console.error(t instanceof Error?t.message:t),process.exit(1)});
|
|
752
768
|
/*! Bundled license information:
|
|
753
769
|
|
|
754
770
|
js-yaml/dist/js-yaml.mjs:
|