orval 6.15.0 → 6.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/orval.js +1 -1
- package/dist/{chunk-OBXGMXMG.js → chunk-L4BGJ5OZ.js} +12 -12
- package/dist/index.js +1 -1
- package/package.json +10 -9
package/dist/bin/orval.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var
|
|
2
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var _chunkL4BGJ5OZjs = require('../chunk-L4BGJ5OZ.js');var _core = require('@orval/core');var _cac = require('cac');var _chalk = require('chalk'); var _chalk2 = _interopRequireDefault(_chalk);var j=_chunkL4BGJ5OZjs.a.call(void 0, ()=>{_chunkL4BGJ5OZjs.k.call(void 0, );var e=_chunkL4BGJ5OZjs.b.call(void 0, _chunkL4BGJ5OZjs.c.call(void 0, ));_chunkL4BGJ5OZjs.f.call(void 0, );_chunkL4BGJ5OZjs.h.call(void 0, );var o=_cac.cac.call(void 0, "orval");_core.startMessage.call(void 0, {name:e.default.name,version:e.default.version,description:e.default.description});o.version(e.default.version);o.command("[config]","generate client with appropriate type-signatures from OpenAPI specs",{ignoreOptionDefaultValue:!0}).option("-o, --output <path>","output file destination").option("-i, --input <path>","input file (yaml or json openapi specs)").option("-c, --config <path>","override flags by a config file").option("-p, --project <name>","focus a project of the config").option("-m, --mode <name>","default mode that will be used").option("-c, --client <name>","default client that will be used").option("--mock","activate the mock").option("-w, --watch [path]","Watch mode, if path is not specified, it watches the input target").option("--clean [path]","Clean output directory").option("--prettier [path]","Prettier generated files").option("--tslint [path]","tslint generated files").option("--tsconfig [path]","path to your tsconfig file").action(async(b,t)=>{if(!t.config&&_core.isString.call(void 0, t.input)&&_core.isString.call(void 0, t.output)){let i=await _chunkL4BGJ5OZjs.e.call(void 0, {input:t.input,output:{target:t.output,clean:t.clean,prettier:t.prettier,tslint:t.tslint,mock:t.mock,client:t.client,mode:t.mode,tsconfig:t.tsconfig}});if(t.watch)_chunkL4BGJ5OZjs.g.call(void 0, t.watch,async()=>{try{await _chunkL4BGJ5OZjs.i.call(void 0, process.cwd(),i)}catch(n){_core.log.call(void 0, _chalk2.default.red(`\u{1F6D1} ${n}`))}},i.input.target);else try{await _chunkL4BGJ5OZjs.i.call(void 0, process.cwd(),i)}catch(n){_core.log.call(void 0, _chalk2.default.red(`\u{1F6D1} ${n}`))}}else await _chunkL4BGJ5OZjs.j.call(void 0, t.config,{projectName:t.project,watch:t.watch,clean:t.clean,prettier:t.prettier,tslint:t.tslint,mock:t.mock,client:t.client,mode:t.mode,tsconfig:t.tsconfig,input:t.input,output:t.output})});o.help();o.parse(process.argv)});exports. default = j();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var So=Object.create;var _n=Object.defineProperty;var bo=Object.getOwnPropertyDescriptor;var _o=Object.getOwnPropertyNames;var Oo=Object.getPrototypeOf,Fo=Object.prototype.hasOwnProperty;var T=(e=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(e,{get:(r,n)=>(typeof require!="undefined"?require:r)[n]}):e)(function(e){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var S=(e,r)=>()=>(e&&(r=e(e=0)),r);var y=(e,r)=>()=>(r||e((r={exports:{}}).exports,r),r.exports);var Eo=(e,r,n,i)=>{if(r&&typeof r=="object"||typeof r=="function")for(let t of _o(r))!Fo.call(e,t)&&t!==n&&_n(e,t,{get:()=>r[t],enumerable:!(i=bo(r,t))||i.enumerable});return e};var M=(e,r,n)=>(n=e!=null?So(Oo(e)):{},Eo(r||!e||!e.__esModule?_n(n,"default",{value:e,enumerable:!0}):n,e));var On=y((
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var So=Object.create;var _n=Object.defineProperty;var bo=Object.getOwnPropertyDescriptor;var _o=Object.getOwnPropertyNames;var Oo=Object.getPrototypeOf,Fo=Object.prototype.hasOwnProperty;var T=(e=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(e,{get:(r,n)=>(typeof require!="undefined"?require:r)[n]}):e)(function(e){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var S=(e,r)=>()=>(e&&(r=e(e=0)),r);var y=(e,r)=>()=>(r||e((r={exports:{}}).exports,r),r.exports);var Eo=(e,r,n,i)=>{if(r&&typeof r=="object"||typeof r=="function")for(let t of _o(r))!Fo.call(e,t)&&t!==n&&_n(e,t,{get:()=>r[t],enumerable:!(i=bo(r,t))||i.enumerable});return e};var M=(e,r,n)=>(n=e!=null?So(Oo(e)):{},Eo(r||!e||!e.__esModule?_n(n,"default",{value:e,enumerable:!0}):n,e));var On=y((zc,ko)=>{ko.exports={name:"orval",description:"A swagger client generator for typescript",version:"6.17.0",license:"MIT",files:["dist"],bin:{orval:"dist/bin/orval.js"},type:"commonjs",main:"dist/index.js",keywords:["rest","client","swagger","open-api","fetch","data fetching","code-generation","angular","react","react-query","svelte","svelte-query","vue","vue-query","msw","mock","axios","vue-query","vue","swr","zod"],author:{name:"Victor Bury",email:"victor@anymaniax.com"},repository:{type:"git",url:"https://github.com/anymaniax/orval"},scripts:{build:"tsup ./src/bin/orval.ts ./src/index.ts --target node12 --minify --clean --dts --splitting",dev:"tsup ./src/bin/orval.ts ./src/index.ts --target node12 --clean --watch ./src --onSuccess 'yarn generate-api'",lint:"eslint src/**/*.ts","generate-api":"node ./dist/bin/orval.js --config ../../samples/react-query/basic/orval.config.ts"},devDependencies:{"@types/chalk":"^2.2.0","@types/inquirer":"^8.2.2","@types/js-yaml":"^4.0.5","@types/lodash.uniq":"^4.5.7"},dependencies:{"@apidevtools/swagger-parser":"^10.1.0","@orval/angular":"6.17.0","@orval/axios":"6.17.0","@orval/core":"6.17.0","@orval/msw":"6.17.0","@orval/query":"6.17.0","@orval/swr":"6.17.0","@orval/zod":"6.17.0",ajv:"^8.11.0",cac:"^6.7.12",chalk:"^4.1.2",chokidar:"^3.5.3",enquirer:"^2.3.6",execa:"^5.1.1","find-up":"5.0.0","fs-extra":"^10.1.0","lodash.uniq":"^4.5.0","openapi3-ts":"^3.0.0","string-argv":"^0.3.1",tsconfck:"^2.0.1"}}});var _https = require('https'); var _https2 = _interopRequireDefault(_https);var Fn,Me=S(()=>{"use strict";Fn=(e,r)=>new Promise((n,i)=>{let t=_https2.default.request(e,o=>{let a="";o.on("data",l=>a+=l.toString()),o.on("error",i),o.on("end",()=>{let l={status:o.statusCode,headers:o.headers,body:JSON.parse(a)};o.statusCode&&o.statusCode>=200&&o.statusCode<=299?n(l):i(l)})});t.on("error",i),r&&t.write(r,"binary"),t.end()})});var _core = require('@orval/core');var _enquirer = require('enquirer');var _fsextra = require('fs-extra'); var _fsextra2 = _interopRequireDefault(_fsextra);var No,Le,Mo,Lo,En,Re=S(()=>{"use strict";Me();No=({accessToken:e,repo:r,owner:n,branch:i,path:t})=>{let o=JSON.stringify({query:`query {
|
|
2
2
|
repository(name: "${r}", owner: "${n}") {
|
|
3
3
|
object(expression: "${i}:${t}") {
|
|
4
4
|
... on Blob {
|
|
@@ -6,24 +6,24 @@
|
|
|
6
6
|
}
|
|
7
7
|
}
|
|
8
8
|
}
|
|
9
|
-
}`});return[{method:"POST",hostname:"api.github.com",path:"/graphql",headers:{"content-type":"application/json","user-agent":"orval-importer",authorization:`bearer ${e}`,"Content-Length":o.length}},o]},Me=null,Mo=async e=>{if(Me)return Me;if(await _fsextra2.default.pathExists(e))return _fsextra2.default.readFile(e,"utf-8");{let r=await _enquirer.prompt.call(void 0, [{type:"input",name:"githubToken",message:"Please provide a GitHub token with `repo` rules checked (https://help.github.com/articles/creating-a-personal-access-token-for-the-command-line/)"},{type:"confirm",name:"saveToken",message:"Would you like to store your token for the next time? (stored in your node_modules)"}]);return Me=r.githubToken,r.saveToken&&await _fsextra2.default.outputFile(e,r.githubToken),r.githubToken}},Lo=async e=>{var u,p,c,d;let r=_core.upath.join(__dirname,".githubToken"),n=await Mo(r),[i]=e.split("github.com/").slice(-1),[t,o,,a,...l]=i.split("/"),s=l.join("/");try{let{body:f}=await Fn(...No({accessToken:n,repo:o,owner:t,branch:a,path:s}));return(u=f.errors)!=null&&u.length&&((p=f.errors)==null?void 0:p.some(x=>(x==null?void 0:x.type)==="NOT_FOUND"))&&(await _enquirer.prompt.call(void 0, [{type:"confirm",name:"removeToken",message:"Your token doesn't have the correct permissions, should we remove it?"}])).removeToken&&await _fsextra2.default.unlink(r),(d=(c=f.data)==null?void 0:c.repository)==null?void 0:d.object.text}catch(f){throw f.body?(f.body.message==="Bad credentials"&&(await _enquirer.prompt.call(void 0, [{type:"confirm",name:"removeToken",message:"Your token doesn't have the correct permissions, should we remove it?"}])).removeToken&&await _fsextra2.default.unlink(r),f.body.message||`Oups... \u{1F37B}. ${f}`):`Oups... \u{1F37B}. ${f}`}},En={order:199,canRead(e){return e.url.includes("github.com")},read(e){return Lo(e.url)}}});var _findup = require('find-up'); var _findup2 = _interopRequireDefault(_findup);var kn,Re=S(()=>{"use strict";ie();kn=async(e,r=process.cwd())=>{if(!e){let i=await _findup2.default.call(void 0, ["package.json"],{cwd:r});return i?await Promise.resolve().then(()=>M(T(i))):void 0}let n=_(e,r);if(_fsextra2.default.existsSync(n))return await Promise.resolve().then(()=>M(T(n)))}});var _tsconfck = require('tsconfck');var In,De=S(()=>{"use strict";ie();In=async(e,r=process.cwd())=>{var n,i;if(_core.isUndefined.call(void 0, e)){let t=await _findup2.default.call(void 0, ["tsconfig.json","jsconfig.json"],{cwd:r});return t?(await _tsconfck.parse.call(void 0, t)).tsconfig:void 0}if(_core.isString.call(void 0, e)){let t=_(e,r);if(_fsextra2.default.existsSync(t)){let o=await _tsconfck.parse.call(void 0, t);return((i=(n=o.referenced)==null?void 0:n.find(({tsconfigFile:l})=>l===t))==null?void 0:i.tsconfig)||o.tsconfig}return}if(_core.isObject.call(void 0, e))return e}});var _chalk = require('chalk'); var _chalk2 = _interopRequireDefault(_chalk);function If(e){return e}var Ge,Ln,zo,F,Nn,_,Mn,Wo,Ko,Pn,Jo,ie= exports.f =S(()=>{"use strict";Ge=M(On());Pe();Re();De();Ln= exports.e =async(e,r=process.cwd(),n={})=>{var m,G,k,vr,Ar,wr,Cr,Sr,br,_r,Or,Fr,Er,kr,Tr,Ir,Nr,Mr,Lr,Pr,Rr,Dr,jr,qr,Hr,Br,Gr,Ur,Yr,$r,zr,Wr,Kr,Jr,Qr,Vr,Xr,Zr,en,rn,nn,tn,on,an,ln,sn,un,cn,fn,pn,dn,hn,mn,gn,xn,yn,vn,An,wn,Cn,Sn,bn;let i=await(_core.isFunction.call(void 0, e)?e():e);i.input||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an input")),process.exit(1)),i.output||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an output")),process.exit(1));let t=_core.isString.call(void 0, i.input)?{target:i.input}:i.input,o=_core.isString.call(void 0, i.output)?{target:i.output}:i.output,a=_(o.workspace||"",r),{clean:l,prettier:s,client:u,mode:p,mock:c,tslint:d}=n,f=await In(o.tsconfig||n.tsconfig,r),h=await kn(o.packageJson||n.packageJson,r),x={input:{target:n.input?Nn(n.input,process.cwd()):Nn(t.target,r),validation:t.validation||!1,override:{transformer:_((m=t.override)==null?void 0:m.transformer,r)},converterOptions:(G=t.converterOptions)!=null?G:{},parserOptions:_core.mergeDeep.call(void 0, zo,(k=t.parserOptions)!=null?k:{}),filters:t.filters},output:{target:n.output?_(n.output,process.cwd()):_(o.target,a),schemas:_(o.schemas,a),workspace:o.workspace?a:void 0,client:(Ar=(vr=o.client)!=null?vr:u)!=null?Ar:_core.OutputClient.AXIOS_FUNCTIONS,mode:Wo((wr=o.mode)!=null?wr:p),mock:(Sr=(Cr=o.mock)!=null?Cr:c)!=null?Sr:!1,clean:(_r=(br=o.clean)!=null?br:l)!=null?_r:!1,prettier:(Fr=(Or=o.prettier)!=null?Or:s)!=null?Fr:!1,tslint:(kr=(Er=o.tslint)!=null?Er:d)!=null?kr:!1,tsconfig:f,packageJson:h,headers:(Tr=o.headers)!=null?Tr:!1,override:{...o.override,mock:{arrayMin:(Mr=(Nr=(Ir=o.override)==null?void 0:Ir.mock)==null?void 0:Nr.arrayMin)!=null?Mr:1,arrayMax:(Rr=(Pr=(Lr=o.override)==null?void 0:Lr.mock)==null?void 0:Pr.arrayMax)!=null?Rr:10,...(jr=(Dr=o.override)==null?void 0:Dr.mock)!=null?jr:{}},operations:Mn((Hr=(qr=o.override)==null?void 0:qr.operations)!=null?Hr:{},a),tags:Mn((Gr=(Br=o.override)==null?void 0:Br.tags)!=null?Gr:{},a),mutator:F(a,(Ur=o.override)==null?void 0:Ur.mutator),formData:(Wr=_core.isBoolean.call(void 0, (Yr=o.override)==null?void 0:Yr.formData)?(zr=o.override)==null?void 0:zr.formData:F(a,($r=o.override)==null?void 0:$r.formData))!=null?Wr:!0,formUrlEncoded:(Vr=_core.isBoolean.call(void 0, (Kr=o.override)==null?void 0:Kr.formUrlEncoded)?(Qr=o.override)==null?void 0:Qr.formUrlEncoded:F(a,(Jr=o.override)==null?void 0:Jr.formUrlEncoded))!=null?Vr:!0,header:((Xr=o.override)==null?void 0:Xr.header)===!1?!1:_core.isFunction.call(void 0, (Zr=o.override)==null?void 0:Zr.header)?(en=o.override)==null?void 0:en.header:Jo,requestOptions:(nn=(rn=o.override)==null?void 0:rn.requestOptions)!=null?nn:!0,components:{schemas:{suffix:_core.RefComponentSuffix.schemas,...(an=(on=(tn=o.override)==null?void 0:tn.components)==null?void 0:on.schemas)!=null?an:{}},responses:{suffix:_core.RefComponentSuffix.responses,...(un=(sn=(ln=o.override)==null?void 0:ln.components)==null?void 0:sn.responses)!=null?un:{}},parameters:{suffix:_core.RefComponentSuffix.parameters,...(pn=(fn=(cn=o.override)==null?void 0:cn.components)==null?void 0:fn.parameters)!=null?pn:{}},requestBodies:{suffix:_core.RefComponentSuffix.requestBodies,...(mn=(hn=(dn=o.override)==null?void 0:dn.components)==null?void 0:hn.requestBodies)!=null?mn:{}}},query:{useQuery:!0,signal:!0,...Pn((gn=o.override)==null?void 0:gn.query,r)},swr:{...(yn=(xn=o.override)==null?void 0:xn.swr)!=null?yn:{}},angular:{provideIn:(wn=(An=(vn=o.override)==null?void 0:vn.angular)==null?void 0:An.provideIn)!=null?wn:"root"},useDates:((Cn=o.override)==null?void 0:Cn.useDates)||!1,useDeprecatedOperations:(bn=(Sn=o.override)==null?void 0:Sn.useDeprecatedOperations)!=null?bn:!0}},hooks:i.hooks?Ko(i.hooks):{}};return x.input.target||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an input target")),process.exit(1)),!x.output.target&&!x.output.schemas&&(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an output target or schemas")),process.exit(1)),x},zo={validate:!0,resolve:{github:En}},F=(e,r)=>{var n;return _core.isObject.call(void 0, r)?(r.path||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Mutator need a path")),process.exit(1)),{...r,path:_core.upath.resolve(e,r.path),default:(n=r.default||!r.name)!=null?n:!1}):_core.isString.call(void 0, r)?{path:_core.upath.resolve(e,r),default:!0}:r},Nn=(e,r)=>_core.isString.call(void 0, e)&&!_core.isUrl.call(void 0, e)?_(e,r):e,_=(e,r)=>_core.isString.call(void 0, e)?_core.upath.resolve(r,e):e,Mn=(e,r)=>Object.fromEntries(Object.entries(e).map(([n,{transformer:i,mutator:t,formData:o,formUrlEncoded:a,query:l,...s}])=>[n,{...s,...l?{query:Pn(l,r)}:{},...i?{transformer:_(i,r)}:{},...t?{mutator:F(r,t)}:{},...o?{formData:_core.isBoolean.call(void 0, o)?o:F(r,o)}:{},...a?{formUrlEncoded:_core.isBoolean.call(void 0, a)?a:F(r,a)}:{}}])),Wo=e=>e?Object.values(_core.OutputMode).includes(e)?e:(_core.createLogger.call(void 0, ).warn(_chalk2.default.yellow(`Unknown the provided mode => ${e}`)),_core.OutputMode.SINGLE):_core.OutputMode.SINGLE,Ko=e=>Object.keys(e).reduce((n,i)=>_core.isString.call(void 0, e[i])?{...n,[i]:[e[i]]}:Array.isArray(e[i])?{...n,[i]:e[i]}:_core.isFunction.call(void 0, e[i])?{...n,[i]:[e[i]]}:n,{}),Pn=(e={},r)=>(e.options&&console.warn("[WARN] Using query options is deprecated and will be removed in a future major release. Please use queryOptions or mutationOptions instead."),{..._core.isUndefined.call(void 0, e.useQuery)?{}:{useQuery:e.useQuery},..._core.isUndefined.call(void 0, e.useInfinite)?{}:{useInfinite:e.useInfinite},...e.useInfiniteQueryParam?{useInfiniteQueryParam:e.useInfiniteQueryParam}:{},...e.options?{options:e.options}:{},...e!=null&&e.queryKey?{queryKey:F(r,e==null?void 0:e.queryKey)}:{},...e!=null&&e.queryOptions?{queryOptions:F(r,e==null?void 0:e.queryOptions)}:{},...e!=null&&e.mutationOptions?{mutationOptions:F(r,e==null?void 0:e.mutationOptions)}:{},..._core.isUndefined.call(void 0, e.signal)?{}:{signal:e.signal}}),Jo=({title:e,description:r,version:n})=>[`Generated by ${Ge.default.name} v${Ge.default.version} \u{1F37A}`,"Do not edit manually.",...e?[e]:[],...r?[r]:[],...n?[`OpenAPI spec version: ${n}`]:[]]});var Rn,Ye= exports.h =S(()=>{"use strict";Rn= exports.g =async(e,r,n=".")=>{if(!e)return;let{watch:i}=await Promise.resolve().then(()=>M(T("chokidar"))),t=["**/{.git,node_modules}/**"],o=typeof e=="boolean"?n:Array.isArray(e)?e.filter(l=>typeof l=="string"):e;_core.log.call(void 0, `Watching for changes in ${Array.isArray(o)?o.map(l=>'"'+l+'"').join(" | "):'"'+o+'"'}`),i(o,{ignorePermissionErrors:!0,ignored:t}).on("all",async(l,s)=>{_core.log.call(void 0, `Change detected: ${l} ${s}`);try{await r()}catch(u){_core.log.call(void 0, _chalk2.default.red(u))}})}});var P=y((Rf,L)=>{"use strict";function Dn(e){return typeof e>"u"||e===null}function Vo(e){return typeof e=="object"&&e!==null}function Xo(e){return Array.isArray(e)?e:Dn(e)?[]:[e]}function Zo(e,r){var n,i,t,o;if(r)for(o=Object.keys(r),n=0,i=o.length;n<i;n+=1)t=o[n],e[t]=r[t];return e}function ea(e,r){var n="",i;for(i=0;i<r;i+=1)n+=e;return n}function ra(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}L.exports.isNothing=Dn;L.exports.isObject=Vo;L.exports.toArray=Xo;L.exports.repeat=ea;L.exports.isNegativeZero=ra;L.exports.extend=Zo});var z=y((Df,jn)=>{"use strict";function te(e,r){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=r,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}te.prototype=Object.create(Error.prototype);te.prototype.constructor=te;te.prototype.toString=function(r){var n=this.name+": ";return n+=this.reason||"(unknown reason)",!r&&this.mark&&(n+=" "+this.mark.toString()),n};jn.exports=te});var Bn=y((jf,Hn)=>{"use strict";var qn=P();function $e(e,r,n,i,t){this.name=e,this.buffer=r,this.position=n,this.line=i,this.column=t}$e.prototype.getSnippet=function(r,n){var i,t,o,a,l;if(!this.buffer)return null;for(r=r||4,n=n||75,i="",t=this.position;t>0&&`\0\r
|
|
9
|
+
}`});return[{method:"POST",hostname:"api.github.com",path:"/graphql",headers:{"content-type":"application/json","user-agent":"orval-importer",authorization:`bearer ${e}`,"Content-Length":o.length}},o]},Le=null,Mo=async e=>{if(Le)return Le;if(await _fsextra2.default.pathExists(e))return _fsextra2.default.readFile(e,"utf-8");{let r=await _enquirer.prompt.call(void 0, [{type:"input",name:"githubToken",message:"Please provide a GitHub token with `repo` rules checked (https://help.github.com/articles/creating-a-personal-access-token-for-the-command-line/)"},{type:"confirm",name:"saveToken",message:"Would you like to store your token for the next time? (stored in your node_modules)"}]);return Le=r.githubToken,r.saveToken&&await _fsextra2.default.outputFile(e,r.githubToken),r.githubToken}},Lo=async e=>{var u,p,c,d;let r=_core.upath.join(__dirname,".githubToken"),n=await Mo(r),[i]=e.split("github.com/").slice(-1),[t,o,,a,...l]=i.split("/"),s=l.join("/");try{let{body:f}=await Fn(...No({accessToken:n,repo:o,owner:t,branch:a,path:s}));return(u=f.errors)!=null&&u.length&&((p=f.errors)==null?void 0:p.some(x=>(x==null?void 0:x.type)==="NOT_FOUND"))&&(await _enquirer.prompt.call(void 0, [{type:"confirm",name:"removeToken",message:"Your token doesn't have the correct permissions, should we remove it?"}])).removeToken&&await _fsextra2.default.unlink(r),(d=(c=f.data)==null?void 0:c.repository)==null?void 0:d.object.text}catch(f){throw f.body?(f.body.message==="Bad credentials"&&(await _enquirer.prompt.call(void 0, [{type:"confirm",name:"removeToken",message:"Your token doesn't have the correct permissions, should we remove it?"}])).removeToken&&await _fsextra2.default.unlink(r),f.body.message||`Oups... \u{1F37B}. ${f}`):`Oups... \u{1F37B}. ${f}`}},En={order:199,canRead(e){return e.url.includes("github.com")},read(e){return Lo(e.url)}}});var _findup = require('find-up'); var _findup2 = _interopRequireDefault(_findup);var kn,De=S(()=>{"use strict";ie();kn=async(e,r=process.cwd())=>{if(!e){let i=await _findup2.default.call(void 0, ["package.json"],{cwd:r});return i?await Promise.resolve().then(()=>M(T(i))):void 0}let n=_(e,r);if(_fsextra2.default.existsSync(n))return await Promise.resolve().then(()=>M(T(n)))}});var _tsconfck = require('tsconfck');var In,je=S(()=>{"use strict";ie();In=async(e,r=process.cwd())=>{var n,i;if(_core.isUndefined.call(void 0, e)){let t=await _findup2.default.call(void 0, ["tsconfig.json","jsconfig.json"],{cwd:r});return t?(await _tsconfck.parse.call(void 0, t)).tsconfig:void 0}if(_core.isString.call(void 0, e)){let t=_(e,r);if(_fsextra2.default.existsSync(t)){let o=await _tsconfck.parse.call(void 0, t);return((i=(n=o.referenced)==null?void 0:n.find(({tsconfigFile:l})=>l===t))==null?void 0:i.tsconfig)||o.tsconfig}return}if(_core.isObject.call(void 0, e))return e}});var _chalk = require('chalk'); var _chalk2 = _interopRequireDefault(_chalk);function If(e){return e}var Ge,Ln,$o,F,Nn,_,Mn,Wo,Ko,Pn,Jo,ie= exports.f =S(()=>{"use strict";Ge=M(On());Re();De();je();Ln= exports.e =async(e,r=process.cwd(),n={})=>{var m,G,k,vr,Ar,wr,Cr,Sr,br,_r,Or,Fr,Er,kr,Tr,Ir,Nr,Mr,Lr,Pr,Rr,Dr,jr,qr,Hr,Br,Gr,Ur,Yr,zr,$r,Wr,Kr,Jr,Qr,Vr,Xr,Zr,en,rn,nn,tn,on,an,ln,sn,un,cn,fn,pn,dn,hn,mn,gn,xn,yn,vn,An,wn,Cn,Sn,bn;let i=await(_core.isFunction.call(void 0, e)?e():e);i.input||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an input")),process.exit(1)),i.output||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an output")),process.exit(1));let t=_core.isString.call(void 0, i.input)?{target:i.input}:i.input,o=_core.isString.call(void 0, i.output)?{target:i.output}:i.output,a=_(o.workspace||"",r),{clean:l,prettier:s,client:u,mode:p,mock:c,tslint:d}=n,f=await In(o.tsconfig||n.tsconfig,r),h=await kn(o.packageJson||n.packageJson,r),x={input:{target:n.input?Nn(n.input,process.cwd()):Nn(t.target,r),validation:t.validation||!1,override:{transformer:_((m=t.override)==null?void 0:m.transformer,r)},converterOptions:(G=t.converterOptions)!=null?G:{},parserOptions:_core.mergeDeep.call(void 0, $o,(k=t.parserOptions)!=null?k:{}),filters:t.filters},output:{target:n.output?_(n.output,process.cwd()):_(o.target,a),schemas:_(o.schemas,a),workspace:o.workspace?a:void 0,client:(Ar=(vr=o.client)!=null?vr:u)!=null?Ar:_core.OutputClient.AXIOS_FUNCTIONS,mode:Wo((wr=o.mode)!=null?wr:p),mock:(Sr=(Cr=o.mock)!=null?Cr:c)!=null?Sr:!1,clean:(_r=(br=o.clean)!=null?br:l)!=null?_r:!1,prettier:(Fr=(Or=o.prettier)!=null?Or:s)!=null?Fr:!1,tslint:(kr=(Er=o.tslint)!=null?Er:d)!=null?kr:!1,tsconfig:f,packageJson:h,headers:(Tr=o.headers)!=null?Tr:!1,override:{...o.override,mock:{arrayMin:(Mr=(Nr=(Ir=o.override)==null?void 0:Ir.mock)==null?void 0:Nr.arrayMin)!=null?Mr:1,arrayMax:(Rr=(Pr=(Lr=o.override)==null?void 0:Lr.mock)==null?void 0:Pr.arrayMax)!=null?Rr:10,...(jr=(Dr=o.override)==null?void 0:Dr.mock)!=null?jr:{}},operations:Mn((Hr=(qr=o.override)==null?void 0:qr.operations)!=null?Hr:{},a),tags:Mn((Gr=(Br=o.override)==null?void 0:Br.tags)!=null?Gr:{},a),mutator:F(a,(Ur=o.override)==null?void 0:Ur.mutator),formData:(Wr=_core.isBoolean.call(void 0, (Yr=o.override)==null?void 0:Yr.formData)?($r=o.override)==null?void 0:$r.formData:F(a,(zr=o.override)==null?void 0:zr.formData))!=null?Wr:!0,formUrlEncoded:(Vr=_core.isBoolean.call(void 0, (Kr=o.override)==null?void 0:Kr.formUrlEncoded)?(Qr=o.override)==null?void 0:Qr.formUrlEncoded:F(a,(Jr=o.override)==null?void 0:Jr.formUrlEncoded))!=null?Vr:!0,header:((Xr=o.override)==null?void 0:Xr.header)===!1?!1:_core.isFunction.call(void 0, (Zr=o.override)==null?void 0:Zr.header)?(en=o.override)==null?void 0:en.header:Jo,requestOptions:(nn=(rn=o.override)==null?void 0:rn.requestOptions)!=null?nn:!0,components:{schemas:{suffix:_core.RefComponentSuffix.schemas,...(an=(on=(tn=o.override)==null?void 0:tn.components)==null?void 0:on.schemas)!=null?an:{}},responses:{suffix:_core.RefComponentSuffix.responses,...(un=(sn=(ln=o.override)==null?void 0:ln.components)==null?void 0:sn.responses)!=null?un:{}},parameters:{suffix:_core.RefComponentSuffix.parameters,...(pn=(fn=(cn=o.override)==null?void 0:cn.components)==null?void 0:fn.parameters)!=null?pn:{}},requestBodies:{suffix:_core.RefComponentSuffix.requestBodies,...(mn=(hn=(dn=o.override)==null?void 0:dn.components)==null?void 0:hn.requestBodies)!=null?mn:{}}},query:{useQuery:!0,useMutation:!0,signal:!0,...Pn((gn=o.override)==null?void 0:gn.query,r)},swr:{...(yn=(xn=o.override)==null?void 0:xn.swr)!=null?yn:{}},angular:{provideIn:(wn=(An=(vn=o.override)==null?void 0:vn.angular)==null?void 0:An.provideIn)!=null?wn:"root"},useDates:((Cn=o.override)==null?void 0:Cn.useDates)||!1,useDeprecatedOperations:(bn=(Sn=o.override)==null?void 0:Sn.useDeprecatedOperations)!=null?bn:!0}},hooks:i.hooks?Ko(i.hooks):{}};return x.input.target||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an input target")),process.exit(1)),!x.output.target&&!x.output.schemas&&(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Config require an output target or schemas")),process.exit(1)),x},$o={validate:!0,resolve:{github:En}},F=(e,r)=>{var n;return _core.isObject.call(void 0, r)?(r.path||(_core.createLogger.call(void 0, ).error(_chalk2.default.red("Mutator need a path")),process.exit(1)),{...r,path:_core.upath.resolve(e,r.path),default:(n=r.default||!r.name)!=null?n:!1}):_core.isString.call(void 0, r)?{path:_core.upath.resolve(e,r),default:!0}:r},Nn=(e,r)=>_core.isString.call(void 0, e)&&!_core.isUrl.call(void 0, e)?_(e,r):e,_=(e,r)=>_core.isString.call(void 0, e)?_core.upath.resolve(r,e):e,Mn=(e,r)=>Object.fromEntries(Object.entries(e).map(([n,{transformer:i,mutator:t,formData:o,formUrlEncoded:a,query:l,...s}])=>[n,{...s,...l?{query:Pn(l,r)}:{},...i?{transformer:_(i,r)}:{},...t?{mutator:F(r,t)}:{},...o?{formData:_core.isBoolean.call(void 0, o)?o:F(r,o)}:{},...a?{formUrlEncoded:_core.isBoolean.call(void 0, a)?a:F(r,a)}:{}}])),Wo=e=>e?Object.values(_core.OutputMode).includes(e)?e:(_core.createLogger.call(void 0, ).warn(_chalk2.default.yellow(`Unknown the provided mode => ${e}`)),_core.OutputMode.SINGLE):_core.OutputMode.SINGLE,Ko=e=>Object.keys(e).reduce((n,i)=>_core.isString.call(void 0, e[i])?{...n,[i]:[e[i]]}:Array.isArray(e[i])?{...n,[i]:e[i]}:_core.isFunction.call(void 0, e[i])?{...n,[i]:[e[i]]}:n,{}),Pn=(e={},r)=>(e.options&&console.warn("[WARN] Using query options is deprecated and will be removed in a future major release. Please use queryOptions or mutationOptions instead."),{..._core.isUndefined.call(void 0, e.useQuery)?{}:{useQuery:e.useQuery},..._core.isUndefined.call(void 0, e.useMutation)?{}:{useMutation:e.useMutation},..._core.isUndefined.call(void 0, e.useInfinite)?{}:{useInfinite:e.useInfinite},...e.useInfiniteQueryParam?{useInfiniteQueryParam:e.useInfiniteQueryParam}:{},...e.options?{options:e.options}:{},...e!=null&&e.queryKey?{queryKey:F(r,e==null?void 0:e.queryKey)}:{},...e!=null&&e.queryOptions?{queryOptions:F(r,e==null?void 0:e.queryOptions)}:{},...e!=null&&e.mutationOptions?{mutationOptions:F(r,e==null?void 0:e.mutationOptions)}:{},..._core.isUndefined.call(void 0, e.signal)?{}:{signal:e.signal}}),Jo=({title:e,description:r,version:n})=>[`Generated by ${Ge.default.name} v${Ge.default.version} \u{1F37A}`,"Do not edit manually.",...e?[e]:[],...r?[r]:[],...n?[`OpenAPI spec version: ${n}`]:[]]});var Rn,Ye= exports.h =S(()=>{"use strict";Rn= exports.g =async(e,r,n=".")=>{if(!e)return;let{watch:i}=await Promise.resolve().then(()=>M(T("chokidar"))),t=["**/{.git,node_modules}/**"],o=typeof e=="boolean"?n:Array.isArray(e)?e.filter(l=>typeof l=="string"):e;_core.log.call(void 0, `Watching for changes in ${Array.isArray(o)?o.map(l=>'"'+l+'"').join(" | "):'"'+o+'"'}`),i(o,{ignorePermissionErrors:!0,ignored:t}).on("all",async(l,s)=>{_core.log.call(void 0, `Change detected: ${l} ${s}`);try{await r()}catch(u){_core.log.call(void 0, _chalk2.default.red(u))}})}});var P=y((Rf,L)=>{"use strict";function Dn(e){return typeof e>"u"||e===null}function Vo(e){return typeof e=="object"&&e!==null}function Xo(e){return Array.isArray(e)?e:Dn(e)?[]:[e]}function Zo(e,r){var n,i,t,o;if(r)for(o=Object.keys(r),n=0,i=o.length;n<i;n+=1)t=o[n],e[t]=r[t];return e}function ea(e,r){var n="",i;for(i=0;i<r;i+=1)n+=e;return n}function ra(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}L.exports.isNothing=Dn;L.exports.isObject=Vo;L.exports.toArray=Xo;L.exports.repeat=ea;L.exports.isNegativeZero=ra;L.exports.extend=Zo});var $=y((Df,jn)=>{"use strict";function te(e,r){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=r,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}te.prototype=Object.create(Error.prototype);te.prototype.constructor=te;te.prototype.toString=function(r){var n=this.name+": ";return n+=this.reason||"(unknown reason)",!r&&this.mark&&(n+=" "+this.mark.toString()),n};jn.exports=te});var Bn=y((jf,Hn)=>{"use strict";var qn=P();function ze(e,r,n,i,t){this.name=e,this.buffer=r,this.position=n,this.line=i,this.column=t}ze.prototype.getSnippet=function(r,n){var i,t,o,a,l;if(!this.buffer)return null;for(r=r||4,n=n||75,i="",t=this.position;t>0&&`\0\r
|
|
10
10
|
\x85\u2028\u2029`.indexOf(this.buffer.charAt(t-1))===-1;)if(t-=1,this.position-t>n/2-1){i=" ... ",t+=5;break}for(o="",a=this.position;a<this.buffer.length&&`\0\r
|
|
11
11
|
\x85\u2028\u2029`.indexOf(this.buffer.charAt(a))===-1;)if(a+=1,a-this.position>n/2-1){o=" ... ",a-=5;break}return l=this.buffer.slice(t,a),qn.repeat(" ",r)+i+l+o+`
|
|
12
|
-
`+qn.repeat(" ",r+this.position-t+i.length)+"^"}
|
|
13
|
-
`+n)),i};Hn.exports
|
|
14
|
-
\r`;function Ya(e){if(e===null)return!1;var r,n,i=0,t=e.length,o=Je;for(n=0;n<t;n++)if(r=o.indexOf(e.charAt(n)),!(r>64)){if(r<0)return!1;i+=6}return i%8===0}function
|
|
15
|
-
`:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"\x85":e===95?"\xA0":e===76?"\u2028":e===80?"\u2029":""}function Nl(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}var Wi=new Array(256),Ki=new Array(256);for(j=0;j<256;j++)Wi[j]=Di(j)?1:0,Ki[j]=Di(j);var j;function Ml(e,r){this.input=e,this.filename=r.filename||null,this.schema=r.schema||bl,this.onWarning=r.onWarning||null,this.legacy=r.legacy||!1,this.json=r.json||!1,this.listener=r.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function Ji(e,r){return new Bi(r,new Sl(e.filename,e.input,e.position,e.line,e.position-e.lineStart))}function g(e,r){throw Ji(e,r)}function
|
|
16
|
-
`,r-1))}function Ll(e,r,n){var i,t,o,a,l,s,u,p,c=e.kind,d=e.result,f;if(f=e.input.charCodeAt(e.position),b(f)||J(f)||f===35||f===38||f===42||f===33||f===124||f===62||f===39||f===34||f===37||f===64||f===96||(f===63||f===45)&&(t=e.input.charCodeAt(e.position+1),b(t)||n&&J(t)))return!1;for(e.kind="scalar",e.result="",o=a=e.position,l=!1;f!==0;){if(f===58){if(t=e.input.charCodeAt(e.position+1),b(t)||n&&J(t))break}else if(f===35){if(i=e.input.charCodeAt(e.position-1),b(i))break}else{if(e.position===e.lineStart&&
|
|
12
|
+
`+qn.repeat(" ",r+this.position-t+i.length)+"^"};ze.prototype.toString=function(r){var n,i="";return this.name&&(i+='in "'+this.name+'" '),i+="at line "+(this.line+1)+", column "+(this.column+1),r||(n=this.getSnippet(),n&&(i+=`:
|
|
13
|
+
`+n)),i};Hn.exports=ze});var w=y((qf,Un)=>{"use strict";var Gn=$(),na=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],ia=["scalar","sequence","mapping"];function ta(e){var r={};return e!==null&&Object.keys(e).forEach(function(n){e[n].forEach(function(i){r[String(i)]=n})}),r}function oa(e,r){if(r=r||{},Object.keys(r).forEach(function(n){if(na.indexOf(n)===-1)throw new Gn('Unknown option "'+n+'" is met in definition of "'+e+'" YAML type.')}),this.tag=e,this.kind=r.kind||null,this.resolve=r.resolve||function(){return!0},this.construct=r.construct||function(n){return n},this.instanceOf=r.instanceOf||null,this.predicate=r.predicate||null,this.represent=r.represent||null,this.defaultStyle=r.defaultStyle||null,this.styleAliases=ta(r.styleAliases||null),ia.indexOf(this.kind)===-1)throw new Gn('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}Un.exports=oa});var R=y((Hf,zn)=>{"use strict";var Yn=P(),xe=$(),aa=w();function $e(e,r,n){var i=[];return e.include.forEach(function(t){n=$e(t,r,n)}),e[r].forEach(function(t){n.forEach(function(o,a){o.tag===t.tag&&o.kind===t.kind&&i.push(a)}),n.push(t)}),n.filter(function(t,o){return i.indexOf(o)===-1})}function la(){var e={scalar:{},sequence:{},mapping:{},fallback:{}},r,n;function i(t){e[t.kind][t.tag]=e.fallback[t.tag]=t}for(r=0,n=arguments.length;r<n;r+=1)arguments[r].forEach(i);return e}function W(e){this.include=e.include||[],this.implicit=e.implicit||[],this.explicit=e.explicit||[],this.implicit.forEach(function(r){if(r.loadKind&&r.loadKind!=="scalar")throw new xe("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}),this.compiledImplicit=$e(this,"implicit",[]),this.compiledExplicit=$e(this,"explicit",[]),this.compiledTypeMap=la(this.compiledImplicit,this.compiledExplicit)}W.DEFAULT=null;W.create=function(){var r,n;switch(arguments.length){case 1:r=W.DEFAULT,n=arguments[0];break;case 2:r=arguments[0],n=arguments[1];break;default:throw new xe("Wrong number of arguments for Schema.create function")}if(r=Yn.toArray(r),n=Yn.toArray(n),!r.every(function(i){return i instanceof W}))throw new xe("Specified list of super schemas (or a single Schema object) contains a non-Schema object.");if(!n.every(function(i){return i instanceof aa}))throw new xe("Specified list of YAML types (or a single Type object) contains a non-Type object.");return new W({include:r,explicit:n})};zn.exports=W});var Wn=y((Bf,$n)=>{"use strict";var sa=w();$n.exports=new sa("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}})});var Jn=y((Gf,Kn)=>{"use strict";var ua=w();Kn.exports=new ua("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}})});var Vn=y((Uf,Qn)=>{"use strict";var ca=w();Qn.exports=new ca("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}})});var ye=y((Yf,Xn)=>{"use strict";var fa=R();Xn.exports=new fa({explicit:[Wn(),Jn(),Vn()]})});var ei=y((zf,Zn)=>{"use strict";var pa=w();function da(e){if(e===null)return!0;var r=e.length;return r===1&&e==="~"||r===4&&(e==="null"||e==="Null"||e==="NULL")}function ha(){return null}function ma(e){return e===null}Zn.exports=new pa("tag:yaml.org,2002:null",{kind:"scalar",resolve:da,construct:ha,predicate:ma,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var ni=y(($f,ri)=>{"use strict";var ga=w();function xa(e){if(e===null)return!1;var r=e.length;return r===4&&(e==="true"||e==="True"||e==="TRUE")||r===5&&(e==="false"||e==="False"||e==="FALSE")}function ya(e){return e==="true"||e==="True"||e==="TRUE"}function va(e){return Object.prototype.toString.call(e)==="[object Boolean]"}ri.exports=new ga("tag:yaml.org,2002:bool",{kind:"scalar",resolve:xa,construct:ya,predicate:va,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"})});var ti=y((Wf,ii)=>{"use strict";var Aa=P(),wa=w();function Ca(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function Sa(e){return 48<=e&&e<=55}function ba(e){return 48<=e&&e<=57}function _a(e){if(e===null)return!1;var r=e.length,n=0,i=!1,t;if(!r)return!1;if(t=e[n],(t==="-"||t==="+")&&(t=e[++n]),t==="0"){if(n+1===r)return!0;if(t=e[++n],t==="b"){for(n++;n<r;n++)if(t=e[n],t!=="_"){if(t!=="0"&&t!=="1")return!1;i=!0}return i&&t!=="_"}if(t==="x"){for(n++;n<r;n++)if(t=e[n],t!=="_"){if(!Ca(e.charCodeAt(n)))return!1;i=!0}return i&&t!=="_"}for(;n<r;n++)if(t=e[n],t!=="_"){if(!Sa(e.charCodeAt(n)))return!1;i=!0}return i&&t!=="_"}if(t==="_")return!1;for(;n<r;n++)if(t=e[n],t!=="_"){if(t===":")break;if(!ba(e.charCodeAt(n)))return!1;i=!0}return!i||t==="_"?!1:t!==":"?!0:/^(:[0-5]?[0-9])+$/.test(e.slice(n))}function Oa(e){var r=e,n=1,i,t,o=[];return r.indexOf("_")!==-1&&(r=r.replace(/_/g,"")),i=r[0],(i==="-"||i==="+")&&(i==="-"&&(n=-1),r=r.slice(1),i=r[0]),r==="0"?0:i==="0"?r[1]==="b"?n*parseInt(r.slice(2),2):r[1]==="x"?n*parseInt(r,16):n*parseInt(r,8):r.indexOf(":")!==-1?(r.split(":").forEach(function(a){o.unshift(parseInt(a,10))}),r=0,t=1,o.forEach(function(a){r+=a*t,t*=60}),n*r):n*parseInt(r,10)}function Fa(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!Aa.isNegativeZero(e)}ii.exports=new wa("tag:yaml.org,2002:int",{kind:"scalar",resolve:_a,construct:Oa,predicate:Fa,represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0"+e.toString(8):"-0"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})});var li=y((Kf,ai)=>{"use strict";var oi=P(),Ea=w(),ka=new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Ta(e){return!(e===null||!ka.test(e)||e[e.length-1]==="_")}function Ia(e){var r,n,i,t;return r=e.replace(/_/g,"").toLowerCase(),n=r[0]==="-"?-1:1,t=[],"+-".indexOf(r[0])>=0&&(r=r.slice(1)),r===".inf"?n===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:r===".nan"?NaN:r.indexOf(":")>=0?(r.split(":").forEach(function(o){t.unshift(parseFloat(o,10))}),r=0,i=1,t.forEach(function(o){r+=o*i,i*=60}),n*r):n*parseFloat(r,10)}var Na=/^[-+]?[0-9]+e/;function Ma(e,r){var n;if(isNaN(e))switch(r){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(r){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(r){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(oi.isNegativeZero(e))return"-0.0";return n=e.toString(10),Na.test(n)?n.replace("e",".e"):n}function La(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||oi.isNegativeZero(e))}ai.exports=new Ea("tag:yaml.org,2002:float",{kind:"scalar",resolve:Ta,construct:Ia,predicate:La,represent:Ma,defaultStyle:"lowercase"})});var We=y((Jf,si)=>{"use strict";var Pa=R();si.exports=new Pa({include:[ye()],implicit:[ei(),ni(),ti(),li()]})});var Ke=y((Qf,ui)=>{"use strict";var Ra=R();ui.exports=new Ra({include:[We()]})});var di=y((Vf,pi)=>{"use strict";var Da=w(),ci=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),fi=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 ja(e){return e===null?!1:ci.exec(e)!==null||fi.exec(e)!==null}function qa(e){var r,n,i,t,o,a,l,s=0,u=null,p,c,d;if(r=ci.exec(e),r===null&&(r=fi.exec(e)),r===null)throw new Error("Date resolve error");if(n=+r[1],i=+r[2]-1,t=+r[3],!r[4])return new Date(Date.UTC(n,i,t));if(o=+r[4],a=+r[5],l=+r[6],r[7]){for(s=r[7].slice(0,3);s.length<3;)s+="0";s=+s}return r[9]&&(p=+r[10],c=+(r[11]||0),u=(p*60+c)*6e4,r[9]==="-"&&(u=-u)),d=new Date(Date.UTC(n,i,t,o,a,l,s)),u&&d.setTime(d.getTime()-u),d}function Ha(e){return e.toISOString()}pi.exports=new Da("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:ja,construct:qa,instanceOf:Date,represent:Ha})});var mi=y((Xf,hi)=>{"use strict";var Ba=w();function Ga(e){return e==="<<"||e===null}hi.exports=new Ba("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Ga})});var yi=y((Zf,xi)=>{"use strict";var D;try{gi=T,D=gi("buffer").Buffer}catch (e2){}var gi,Ua=w(),Je=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
14
|
+
\r`;function Ya(e){if(e===null)return!1;var r,n,i=0,t=e.length,o=Je;for(n=0;n<t;n++)if(r=o.indexOf(e.charAt(n)),!(r>64)){if(r<0)return!1;i+=6}return i%8===0}function za(e){var r,n,i=e.replace(/[\r\n=]/g,""),t=i.length,o=Je,a=0,l=[];for(r=0;r<t;r++)r%4===0&&r&&(l.push(a>>16&255),l.push(a>>8&255),l.push(a&255)),a=a<<6|o.indexOf(i.charAt(r));return n=t%4*6,n===0?(l.push(a>>16&255),l.push(a>>8&255),l.push(a&255)):n===18?(l.push(a>>10&255),l.push(a>>2&255)):n===12&&l.push(a>>4&255),D?D.from?D.from(l):new D(l):l}function $a(e){var r="",n=0,i,t,o=e.length,a=Je;for(i=0;i<o;i++)i%3===0&&i&&(r+=a[n>>18&63],r+=a[n>>12&63],r+=a[n>>6&63],r+=a[n&63]),n=(n<<8)+e[i];return t=o%3,t===0?(r+=a[n>>18&63],r+=a[n>>12&63],r+=a[n>>6&63],r+=a[n&63]):t===2?(r+=a[n>>10&63],r+=a[n>>4&63],r+=a[n<<2&63],r+=a[64]):t===1&&(r+=a[n>>2&63],r+=a[n<<4&63],r+=a[64],r+=a[64]),r}function Wa(e){return D&&D.isBuffer(e)}xi.exports=new Ua("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Ya,construct:za,predicate:Wa,represent:$a})});var Ai=y((ep,vi)=>{"use strict";var Ka=w(),Ja=Object.prototype.hasOwnProperty,Qa=Object.prototype.toString;function Va(e){if(e===null)return!0;var r=[],n,i,t,o,a,l=e;for(n=0,i=l.length;n<i;n+=1){if(t=l[n],a=!1,Qa.call(t)!=="[object Object]")return!1;for(o in t)if(Ja.call(t,o))if(!a)a=!0;else return!1;if(!a)return!1;if(r.indexOf(o)===-1)r.push(o);else return!1}return!0}function Xa(e){return e!==null?e:[]}vi.exports=new Ka("tag:yaml.org,2002:omap",{kind:"sequence",resolve:Va,construct:Xa})});var Ci=y((rp,wi)=>{"use strict";var Za=w(),el=Object.prototype.toString;function rl(e){if(e===null)return!0;var r,n,i,t,o,a=e;for(o=new Array(a.length),r=0,n=a.length;r<n;r+=1){if(i=a[r],el.call(i)!=="[object Object]"||(t=Object.keys(i),t.length!==1))return!1;o[r]=[t[0],i[t[0]]]}return!0}function nl(e){if(e===null)return[];var r,n,i,t,o,a=e;for(o=new Array(a.length),r=0,n=a.length;r<n;r+=1)i=a[r],t=Object.keys(i),o[r]=[t[0],i[t[0]]];return o}wi.exports=new Za("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:rl,construct:nl})});var bi=y((np,Si)=>{"use strict";var il=w(),tl=Object.prototype.hasOwnProperty;function ol(e){if(e===null)return!0;var r,n=e;for(r in n)if(tl.call(n,r)&&n[r]!==null)return!1;return!0}function al(e){return e!==null?e:{}}Si.exports=new il("tag:yaml.org,2002:set",{kind:"mapping",resolve:ol,construct:al})});var K=y((ip,_i)=>{"use strict";var ll=R();_i.exports=new ll({include:[Ke()],implicit:[di(),mi()],explicit:[yi(),Ai(),Ci(),bi()]})});var Fi=y((tp,Oi)=>{"use strict";var sl=w();function ul(){return!0}function cl(){}function fl(){return""}function pl(e){return typeof e>"u"}Oi.exports=new sl("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:ul,construct:cl,predicate:pl,represent:fl})});var ki=y((op,Ei)=>{"use strict";var dl=w();function hl(e){if(e===null||e.length===0)return!1;var r=e,n=/\/([gim]*)$/.exec(e),i="";return!(r[0]==="/"&&(n&&(i=n[1]),i.length>3||r[r.length-i.length-1]!=="/"))}function ml(e){var r=e,n=/\/([gim]*)$/.exec(e),i="";return r[0]==="/"&&(n&&(i=n[1]),r=r.slice(1,r.length-i.length-1)),new RegExp(r,i)}function gl(e){var r="/"+e.source+"/";return e.global&&(r+="g"),e.multiline&&(r+="m"),e.ignoreCase&&(r+="i"),r}function xl(e){return Object.prototype.toString.call(e)==="[object RegExp]"}Ei.exports=new dl("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:hl,construct:ml,predicate:xl,represent:gl})});var Ni=y((ap,Ii)=>{"use strict";var ve;try{Ti=T,ve=Ti("esprima")}catch (e3){typeof window<"u"&&(ve=window.esprima)}var Ti,yl=w();function vl(e){if(e===null)return!1;try{var r="("+e+")",n=ve.parse(r,{range:!0});return!(n.type!=="Program"||n.body.length!==1||n.body[0].type!=="ExpressionStatement"||n.body[0].expression.type!=="ArrowFunctionExpression"&&n.body[0].expression.type!=="FunctionExpression")}catch (e4){return!1}}function Al(e){var r="("+e+")",n=ve.parse(r,{range:!0}),i=[],t;if(n.type!=="Program"||n.body.length!==1||n.body[0].type!=="ExpressionStatement"||n.body[0].expression.type!=="ArrowFunctionExpression"&&n.body[0].expression.type!=="FunctionExpression")throw new Error("Failed to resolve function");return n.body[0].expression.params.forEach(function(o){i.push(o.name)}),t=n.body[0].expression.body.range,n.body[0].expression.body.type==="BlockStatement"?new Function(i,r.slice(t[0]+1,t[1]-1)):new Function(i,"return "+r.slice(t[0],t[1]))}function wl(e){return e.toString()}function Cl(e){return Object.prototype.toString.call(e)==="[object Function]"}Ii.exports=new yl("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:vl,construct:Al,predicate:Cl,represent:wl})});var oe=y((lp,Li)=>{"use strict";var Mi=R();Li.exports=Mi.DEFAULT=new Mi({include:[K()],explicit:[Fi(),ki(),Ni()]})});var Zi=y((sp,ae)=>{"use strict";var E=P(),Bi=$(),Sl=Bn(),Gi=K(),bl=oe(),N=Object.prototype.hasOwnProperty,Ae=1,Ui=2,Yi=3,we=4,Qe=1,_l=2,Pi=3,Ol=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Fl=/[\x85\u2028\u2029]/,El=/[,\[\]\{\}]/,zi=/^(?:!|!!|![a-z\-]+!)$/i,$i=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Ri(e){return Object.prototype.toString.call(e)}function O(e){return e===10||e===13}function q(e){return e===9||e===32}function b(e){return e===9||e===32||e===10||e===13}function J(e){return e===44||e===91||e===93||e===123||e===125}function kl(e){var r;return 48<=e&&e<=57?e-48:(r=e|32,97<=r&&r<=102?r-97+10:-1)}function Tl(e){return e===120?2:e===117?4:e===85?8:0}function Il(e){return 48<=e&&e<=57?e-48:-1}function Di(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
|
|
15
|
+
`:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"\x85":e===95?"\xA0":e===76?"\u2028":e===80?"\u2029":""}function Nl(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}var Wi=new Array(256),Ki=new Array(256);for(j=0;j<256;j++)Wi[j]=Di(j)?1:0,Ki[j]=Di(j);var j;function Ml(e,r){this.input=e,this.filename=r.filename||null,this.schema=r.schema||bl,this.onWarning=r.onWarning||null,this.legacy=r.legacy||!1,this.json=r.json||!1,this.listener=r.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function Ji(e,r){return new Bi(r,new Sl(e.filename,e.input,e.position,e.line,e.position-e.lineStart))}function g(e,r){throw Ji(e,r)}function Ce(e,r){e.onWarning&&e.onWarning.call(null,Ji(e,r))}var ji={YAML:function(r,n,i){var t,o,a;r.version!==null&&g(r,"duplication of %YAML directive"),i.length!==1&&g(r,"YAML directive accepts exactly one argument"),t=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),t===null&&g(r,"ill-formed argument of the YAML directive"),o=parseInt(t[1],10),a=parseInt(t[2],10),o!==1&&g(r,"unacceptable YAML version of the document"),r.version=i[0],r.checkLineBreaks=a<2,a!==1&&a!==2&&Ce(r,"unsupported YAML version of the document")},TAG:function(r,n,i){var t,o;i.length!==2&&g(r,"TAG directive accepts exactly two arguments"),t=i[0],o=i[1],zi.test(t)||g(r,"ill-formed tag handle (first argument) of the TAG directive"),N.call(r.tagMap,t)&&g(r,'there is a previously declared suffix for "'+t+'" tag handle'),$i.test(o)||g(r,"ill-formed tag prefix (second argument) of the TAG directive"),r.tagMap[t]=o}};function I(e,r,n,i){var t,o,a,l;if(r<n){if(l=e.input.slice(r,n),i)for(t=0,o=l.length;t<o;t+=1)a=l.charCodeAt(t),a===9||32<=a&&a<=1114111||g(e,"expected valid JSON character");else Ol.test(l)&&g(e,"the stream contains non-printable characters");e.result+=l}}function qi(e,r,n,i){var t,o,a,l;for(E.isObject(n)||g(e,"cannot merge mappings; the provided source object is unacceptable"),t=Object.keys(n),a=0,l=t.length;a<l;a+=1)o=t[a],N.call(r,o)||(r[o]=n[o],i[o]=!0)}function Q(e,r,n,i,t,o,a,l){var s,u;if(Array.isArray(t))for(t=Array.prototype.slice.call(t),s=0,u=t.length;s<u;s+=1)Array.isArray(t[s])&&g(e,"nested arrays are not supported inside keys"),typeof t=="object"&&Ri(t[s])==="[object Object]"&&(t[s]="[object Object]");if(typeof t=="object"&&Ri(t)==="[object Object]"&&(t="[object Object]"),t=String(t),r===null&&(r={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(o))for(s=0,u=o.length;s<u;s+=1)qi(e,r,o[s],n);else qi(e,r,o,n);else!e.json&&!N.call(n,t)&&N.call(r,t)&&(e.line=a||e.line,e.position=l||e.position,g(e,"duplicated mapping key")),r[t]=o,delete n[t];return r}function Ve(e){var r;r=e.input.charCodeAt(e.position),r===10?e.position++:r===13?(e.position++,e.input.charCodeAt(e.position)===10&&e.position++):g(e,"a line break is expected"),e.line+=1,e.lineStart=e.position}function A(e,r,n){for(var i=0,t=e.input.charCodeAt(e.position);t!==0;){for(;q(t);)t=e.input.charCodeAt(++e.position);if(r&&t===35)do t=e.input.charCodeAt(++e.position);while(t!==10&&t!==13&&t!==0);if(O(t))for(Ve(e),t=e.input.charCodeAt(e.position),i++,e.lineIndent=0;t===32;)e.lineIndent++,t=e.input.charCodeAt(++e.position);else break}return n!==-1&&i!==0&&e.lineIndent<n&&Ce(e,"deficient indentation"),i}function Se(e){var r=e.position,n;return n=e.input.charCodeAt(r),!!((n===45||n===46)&&n===e.input.charCodeAt(r+1)&&n===e.input.charCodeAt(r+2)&&(r+=3,n=e.input.charCodeAt(r),n===0||b(n)))}function Xe(e,r){r===1?e.result+=" ":r>1&&(e.result+=E.repeat(`
|
|
16
|
+
`,r-1))}function Ll(e,r,n){var i,t,o,a,l,s,u,p,c=e.kind,d=e.result,f;if(f=e.input.charCodeAt(e.position),b(f)||J(f)||f===35||f===38||f===42||f===33||f===124||f===62||f===39||f===34||f===37||f===64||f===96||(f===63||f===45)&&(t=e.input.charCodeAt(e.position+1),b(t)||n&&J(t)))return!1;for(e.kind="scalar",e.result="",o=a=e.position,l=!1;f!==0;){if(f===58){if(t=e.input.charCodeAt(e.position+1),b(t)||n&&J(t))break}else if(f===35){if(i=e.input.charCodeAt(e.position-1),b(i))break}else{if(e.position===e.lineStart&&Se(e)||n&&J(f))break;if(O(f))if(s=e.line,u=e.lineStart,p=e.lineIndent,A(e,!1,-1),e.lineIndent>=r){l=!0,f=e.input.charCodeAt(e.position);continue}else{e.position=a,e.line=s,e.lineStart=u,e.lineIndent=p;break}}l&&(I(e,o,a,!1),Xe(e,e.line-s),o=a=e.position,l=!1),q(f)||(a=e.position+1),f=e.input.charCodeAt(++e.position)}return I(e,o,a,!1),e.result?!0:(e.kind=c,e.result=d,!1)}function Pl(e,r){var n,i,t;if(n=e.input.charCodeAt(e.position),n!==39)return!1;for(e.kind="scalar",e.result="",e.position++,i=t=e.position;(n=e.input.charCodeAt(e.position))!==0;)if(n===39)if(I(e,i,e.position,!0),n=e.input.charCodeAt(++e.position),n===39)i=e.position,e.position++,t=e.position;else return!0;else O(n)?(I(e,i,t,!0),Xe(e,A(e,!1,r)),i=t=e.position):e.position===e.lineStart&&Se(e)?g(e,"unexpected end of the document within a single quoted scalar"):(e.position++,t=e.position);g(e,"unexpected end of the stream within a single quoted scalar")}function Rl(e,r){var n,i,t,o,a,l;if(l=e.input.charCodeAt(e.position),l!==34)return!1;for(e.kind="scalar",e.result="",e.position++,n=i=e.position;(l=e.input.charCodeAt(e.position))!==0;){if(l===34)return I(e,n,e.position,!0),e.position++,!0;if(l===92){if(I(e,n,e.position,!0),l=e.input.charCodeAt(++e.position),O(l))A(e,!1,r);else if(l<256&&Wi[l])e.result+=Ki[l],e.position++;else if((a=Tl(l))>0){for(t=a,o=0;t>0;t--)l=e.input.charCodeAt(++e.position),(a=kl(l))>=0?o=(o<<4)+a:g(e,"expected hexadecimal character");e.result+=Nl(o),e.position++}else g(e,"unknown escape sequence");n=i=e.position}else O(l)?(I(e,n,i,!0),Xe(e,A(e,!1,r)),n=i=e.position):e.position===e.lineStart&&Se(e)?g(e,"unexpected end of the document within a double quoted scalar"):(e.position++,i=e.position)}g(e,"unexpected end of the stream within a double quoted scalar")}function Dl(e,r){var n=!0,i,t=e.tag,o,a=e.anchor,l,s,u,p,c,d={},f,h,x,m;if(m=e.input.charCodeAt(e.position),m===91)s=93,c=!1,o=[];else if(m===123)s=125,c=!0,o={};else return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=o),m=e.input.charCodeAt(++e.position);m!==0;){if(A(e,!0,r),m=e.input.charCodeAt(e.position),m===s)return e.position++,e.tag=t,e.anchor=a,e.kind=c?"mapping":"sequence",e.result=o,!0;n||g(e,"missed comma between flow collection entries"),h=f=x=null,u=p=!1,m===63&&(l=e.input.charCodeAt(e.position+1),b(l)&&(u=p=!0,e.position++,A(e,!0,r))),i=e.line,V(e,r,Ae,!1,!0),h=e.tag,f=e.result,A(e,!0,r),m=e.input.charCodeAt(e.position),(p||e.line===i)&&m===58&&(u=!0,m=e.input.charCodeAt(++e.position),A(e,!0,r),V(e,r,Ae,!1,!0),x=e.result),c?Q(e,o,d,h,f,x):u?o.push(Q(e,null,d,h,f,x)):o.push(f),A(e,!0,r),m=e.input.charCodeAt(e.position),m===44?(n=!0,m=e.input.charCodeAt(++e.position)):n=!1}g(e,"unexpected end of the stream within a flow collection")}function jl(e,r){var n,i,t=Qe,o=!1,a=!1,l=r,s=0,u=!1,p,c;if(c=e.input.charCodeAt(e.position),c===124)i=!1;else if(c===62)i=!0;else return!1;for(e.kind="scalar",e.result="";c!==0;)if(c=e.input.charCodeAt(++e.position),c===43||c===45)Qe===t?t=c===43?Pi:_l:g(e,"repeat of a chomping mode identifier");else if((p=Il(c))>=0)p===0?g(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):a?g(e,"repeat of an indentation width identifier"):(l=r+p-1,a=!0);else break;if(q(c)){do c=e.input.charCodeAt(++e.position);while(q(c));if(c===35)do c=e.input.charCodeAt(++e.position);while(!O(c)&&c!==0)}for(;c!==0;){for(Ve(e),e.lineIndent=0,c=e.input.charCodeAt(e.position);(!a||e.lineIndent<l)&&c===32;)e.lineIndent++,c=e.input.charCodeAt(++e.position);if(!a&&e.lineIndent>l&&(l=e.lineIndent),O(c)){s++;continue}if(e.lineIndent<l){t===Pi?e.result+=E.repeat(`
|
|
17
17
|
`,o?1+s:s):t===Qe&&o&&(e.result+=`
|
|
18
18
|
`);break}for(i?q(c)?(u=!0,e.result+=E.repeat(`
|
|
19
19
|
`,o?1+s:s)):u?(u=!1,e.result+=E.repeat(`
|
|
20
20
|
`,s+1)):s===0?o&&(e.result+=" "):e.result+=E.repeat(`
|
|
21
21
|
`,s):e.result+=E.repeat(`
|
|
22
|
-
`,o?1+s:s),o=!0,a=!0,s=0,n=e.position;!O(c)&&c!==0;)c=e.input.charCodeAt(++e.position);I(e,n,e.position,!1)}return!0}function Hi(e,r){var n,i=e.tag,t=e.anchor,o=[],a,l=!1,s;for(e.anchor!==null&&(e.anchorMap[e.anchor]=o),s=e.input.charCodeAt(e.position);s!==0&&!(s!==45||(a=e.input.charCodeAt(e.position+1),!b(a)));){if(l=!0,e.position++,A(e,!0,-1)&&e.lineIndent<=r){o.push(null),s=e.input.charCodeAt(e.position);continue}if(n=e.line,V(e,r,Yi,!1,!0),o.push(e.result),A(e,!0,-1),s=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>r)&&s!==0)g(e,"bad indentation of a sequence entry");else if(e.lineIndent<r)break}return l?(e.tag=i,e.anchor=t,e.kind="sequence",e.result=o,!0):!1}function ql(e,r,n){var i,t,o,a,l=e.tag,s=e.anchor,u={},p={},c=null,d=null,f=null,h=!1,x=!1,m;for(e.anchor!==null&&(e.anchorMap[e.anchor]=u),m=e.input.charCodeAt(e.position);m!==0;){if(i=e.input.charCodeAt(e.position+1),o=e.line,a=e.position,(m===63||m===58)&&b(i))m===63?(h&&(Q(e,u,p,c,d,null),c=d=f=null),x=!0,h=!0,t=!0):h?(h=!1,t=!0):g(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,m=i;else if(V(e,n,Ui,!1,!0))if(e.line===o){for(m=e.input.charCodeAt(e.position);q(m);)m=e.input.charCodeAt(++e.position);if(m===58)m=e.input.charCodeAt(++e.position),b(m)||g(e,"a whitespace character is expected after the key-value separator within a block mapping"),h&&(Q(e,u,p,c,d,null),c=d=f=null),x=!0,h=!1,t=!1,c=e.tag,d=e.result;else if(x)g(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=l,e.anchor=s,!0}else if(x)g(e,"can not read a block mapping entry; a multiline key may not be an implicit key");else return e.tag=l,e.anchor=s,!0;else break;if((e.line===o||e.lineIndent>r)&&(V(e,r,
|
|
23
|
-
`),e.charCodeAt(0)===65279&&(e=e.slice(1)));var n=new Ml(e,r),i=e.indexOf("\0");for(i!==-1&&(n.position=i,g(n,"null byte is not allowed in input")),n.input+="\0";n.input.charCodeAt(n.position)===32;)n.lineIndent+=1,n.position+=1;for(;n.position<n.length-1;)Ul(n);return n.documents}function Vi(e,r,n){r!==null&&typeof r=="object"&&typeof n>"u"&&(n=r,r=null);var i=Qi(e,n);if(typeof r!="function")return i;for(var t=0,o=i.length;t<o;t+=1)r(i[t])}function Xi(e,r){var n=Qi(e,r);if(n.length!==0){if(n.length===1)return n[0];throw new Bi("expected a single document in the stream, but found more")}}function Yl(e,r,n){return typeof r=="object"&&r!==null&&typeof n>"u"&&(n=r,r=null),Vi(e,r,E.extend({schema:Gi},n))}function
|
|
22
|
+
`,o?1+s:s),o=!0,a=!0,s=0,n=e.position;!O(c)&&c!==0;)c=e.input.charCodeAt(++e.position);I(e,n,e.position,!1)}return!0}function Hi(e,r){var n,i=e.tag,t=e.anchor,o=[],a,l=!1,s;for(e.anchor!==null&&(e.anchorMap[e.anchor]=o),s=e.input.charCodeAt(e.position);s!==0&&!(s!==45||(a=e.input.charCodeAt(e.position+1),!b(a)));){if(l=!0,e.position++,A(e,!0,-1)&&e.lineIndent<=r){o.push(null),s=e.input.charCodeAt(e.position);continue}if(n=e.line,V(e,r,Yi,!1,!0),o.push(e.result),A(e,!0,-1),s=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>r)&&s!==0)g(e,"bad indentation of a sequence entry");else if(e.lineIndent<r)break}return l?(e.tag=i,e.anchor=t,e.kind="sequence",e.result=o,!0):!1}function ql(e,r,n){var i,t,o,a,l=e.tag,s=e.anchor,u={},p={},c=null,d=null,f=null,h=!1,x=!1,m;for(e.anchor!==null&&(e.anchorMap[e.anchor]=u),m=e.input.charCodeAt(e.position);m!==0;){if(i=e.input.charCodeAt(e.position+1),o=e.line,a=e.position,(m===63||m===58)&&b(i))m===63?(h&&(Q(e,u,p,c,d,null),c=d=f=null),x=!0,h=!0,t=!0):h?(h=!1,t=!0):g(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,m=i;else if(V(e,n,Ui,!1,!0))if(e.line===o){for(m=e.input.charCodeAt(e.position);q(m);)m=e.input.charCodeAt(++e.position);if(m===58)m=e.input.charCodeAt(++e.position),b(m)||g(e,"a whitespace character is expected after the key-value separator within a block mapping"),h&&(Q(e,u,p,c,d,null),c=d=f=null),x=!0,h=!1,t=!1,c=e.tag,d=e.result;else if(x)g(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=l,e.anchor=s,!0}else if(x)g(e,"can not read a block mapping entry; a multiline key may not be an implicit key");else return e.tag=l,e.anchor=s,!0;else break;if((e.line===o||e.lineIndent>r)&&(V(e,r,we,!0,t)&&(h?d=e.result:f=e.result),h||(Q(e,u,p,c,d,f,o,a),c=d=f=null),A(e,!0,-1),m=e.input.charCodeAt(e.position)),e.lineIndent>r&&m!==0)g(e,"bad indentation of a mapping entry");else if(e.lineIndent<r)break}return h&&Q(e,u,p,c,d,null),x&&(e.tag=l,e.anchor=s,e.kind="mapping",e.result=u),x}function Hl(e){var r,n=!1,i=!1,t,o,a;if(a=e.input.charCodeAt(e.position),a!==33)return!1;if(e.tag!==null&&g(e,"duplication of a tag property"),a=e.input.charCodeAt(++e.position),a===60?(n=!0,a=e.input.charCodeAt(++e.position)):a===33?(i=!0,t="!!",a=e.input.charCodeAt(++e.position)):t="!",r=e.position,n){do a=e.input.charCodeAt(++e.position);while(a!==0&&a!==62);e.position<e.length?(o=e.input.slice(r,e.position),a=e.input.charCodeAt(++e.position)):g(e,"unexpected end of the stream within a verbatim tag")}else{for(;a!==0&&!b(a);)a===33&&(i?g(e,"tag suffix cannot contain exclamation marks"):(t=e.input.slice(r-1,e.position+1),zi.test(t)||g(e,"named tag handle cannot contain such characters"),i=!0,r=e.position+1)),a=e.input.charCodeAt(++e.position);o=e.input.slice(r,e.position),El.test(o)&&g(e,"tag suffix cannot contain flow indicator characters")}return o&&!$i.test(o)&&g(e,"tag name cannot contain such characters: "+o),n?e.tag=o:N.call(e.tagMap,t)?e.tag=e.tagMap[t]+o:t==="!"?e.tag="!"+o:t==="!!"?e.tag="tag:yaml.org,2002:"+o:g(e,'undeclared tag handle "'+t+'"'),!0}function Bl(e){var r,n;if(n=e.input.charCodeAt(e.position),n!==38)return!1;for(e.anchor!==null&&g(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),r=e.position;n!==0&&!b(n)&&!J(n);)n=e.input.charCodeAt(++e.position);return e.position===r&&g(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(r,e.position),!0}function Gl(e){var r,n,i;if(i=e.input.charCodeAt(e.position),i!==42)return!1;for(i=e.input.charCodeAt(++e.position),r=e.position;i!==0&&!b(i)&&!J(i);)i=e.input.charCodeAt(++e.position);return e.position===r&&g(e,"name of an alias node must contain at least one character"),n=e.input.slice(r,e.position),N.call(e.anchorMap,n)||g(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],A(e,!0,-1),!0}function V(e,r,n,i,t){var o,a,l,s=1,u=!1,p=!1,c,d,f,h,x;if(e.listener!==null&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,o=a=l=we===n||Yi===n,i&&A(e,!0,-1)&&(u=!0,e.lineIndent>r?s=1:e.lineIndent===r?s=0:e.lineIndent<r&&(s=-1)),s===1)for(;Hl(e)||Bl(e);)A(e,!0,-1)?(u=!0,l=o,e.lineIndent>r?s=1:e.lineIndent===r?s=0:e.lineIndent<r&&(s=-1)):l=!1;if(l&&(l=u||t),(s===1||we===n)&&(Ae===n||Ui===n?h=r:h=r+1,x=e.position-e.lineStart,s===1?l&&(Hi(e,x)||ql(e,x,h))||Dl(e,h)?p=!0:(a&&jl(e,h)||Pl(e,h)||Rl(e,h)?p=!0:Gl(e)?(p=!0,(e.tag!==null||e.anchor!==null)&&g(e,"alias node should not have any properties")):Ll(e,h,Ae===n)&&(p=!0,e.tag===null&&(e.tag="?")),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):s===0&&(p=l&&Hi(e,x))),e.tag!==null&&e.tag!=="!")if(e.tag==="?"){for(e.result!==null&&e.kind!=="scalar"&&g(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),c=0,d=e.implicitTypes.length;c<d;c+=1)if(f=e.implicitTypes[c],f.resolve(e.result)){e.result=f.construct(e.result),e.tag=f.tag,e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);break}}else N.call(e.typeMap[e.kind||"fallback"],e.tag)?(f=e.typeMap[e.kind||"fallback"][e.tag],e.result!==null&&f.kind!==e.kind&&g(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+f.kind+'", not "'+e.kind+'"'),f.resolve(e.result)?(e.result=f.construct(e.result),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):g(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")):g(e,"unknown tag !<"+e.tag+">");return e.listener!==null&&e.listener("close",e),e.tag!==null||e.anchor!==null||p}function Ul(e){var r=e.position,n,i,t,o=!1,a;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap={},e.anchorMap={};(a=e.input.charCodeAt(e.position))!==0&&(A(e,!0,-1),a=e.input.charCodeAt(e.position),!(e.lineIndent>0||a!==37));){for(o=!0,a=e.input.charCodeAt(++e.position),n=e.position;a!==0&&!b(a);)a=e.input.charCodeAt(++e.position);for(i=e.input.slice(n,e.position),t=[],i.length<1&&g(e,"directive name must not be less than one character in length");a!==0;){for(;q(a);)a=e.input.charCodeAt(++e.position);if(a===35){do a=e.input.charCodeAt(++e.position);while(a!==0&&!O(a));break}if(O(a))break;for(n=e.position;a!==0&&!b(a);)a=e.input.charCodeAt(++e.position);t.push(e.input.slice(n,e.position))}a!==0&&Ve(e),N.call(ji,i)?ji[i](e,i,t):Ce(e,'unknown document directive "'+i+'"')}if(A(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,A(e,!0,-1)):o&&g(e,"directives end mark is expected"),V(e,e.lineIndent-1,we,!1,!0),A(e,!0,-1),e.checkLineBreaks&&Fl.test(e.input.slice(r,e.position))&&Ce(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&Se(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,A(e,!0,-1));return}if(e.position<e.length-1)g(e,"end of the stream or a document separator is expected");else return}function Qi(e,r){e=String(e),r=r||{},e.length!==0&&(e.charCodeAt(e.length-1)!==10&&e.charCodeAt(e.length-1)!==13&&(e+=`
|
|
23
|
+
`),e.charCodeAt(0)===65279&&(e=e.slice(1)));var n=new Ml(e,r),i=e.indexOf("\0");for(i!==-1&&(n.position=i,g(n,"null byte is not allowed in input")),n.input+="\0";n.input.charCodeAt(n.position)===32;)n.lineIndent+=1,n.position+=1;for(;n.position<n.length-1;)Ul(n);return n.documents}function Vi(e,r,n){r!==null&&typeof r=="object"&&typeof n>"u"&&(n=r,r=null);var i=Qi(e,n);if(typeof r!="function")return i;for(var t=0,o=i.length;t<o;t+=1)r(i[t])}function Xi(e,r){var n=Qi(e,r);if(n.length!==0){if(n.length===1)return n[0];throw new Bi("expected a single document in the stream, but found more")}}function Yl(e,r,n){return typeof r=="object"&&r!==null&&typeof n>"u"&&(n=r,r=null),Vi(e,r,E.extend({schema:Gi},n))}function zl(e,r){return Xi(e,E.extend({schema:Gi},r))}ae.exports.loadAll=Vi;ae.exports.load=Xi;ae.exports.safeLoadAll=Yl;ae.exports.safeLoad=zl});var Ct=y((up,nr)=>{"use strict";var se=P(),ue=$(),$l=oe(),Wl=K(),lt=Object.prototype.toString,st=Object.prototype.hasOwnProperty,Kl=9,le=10,Jl=13,Ql=32,Vl=33,Xl=34,ut=35,Zl=37,es=38,rs=39,ns=42,ct=44,is=45,ft=58,ts=61,os=62,as=63,ls=64,pt=91,dt=93,ss=96,ht=123,us=124,mt=125,C={};C[0]="\\0";C[7]="\\a";C[8]="\\b";C[9]="\\t";C[10]="\\n";C[11]="\\v";C[12]="\\f";C[13]="\\r";C[27]="\\e";C[34]='\\"';C[92]="\\\\";C[133]="\\N";C[160]="\\_";C[8232]="\\L";C[8233]="\\P";var cs=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function fs(e,r){var n,i,t,o,a,l,s;if(r===null)return{};for(n={},i=Object.keys(r),t=0,o=i.length;t<o;t+=1)a=i[t],l=String(r[a]),a.slice(0,2)==="!!"&&(a="tag:yaml.org,2002:"+a.slice(2)),s=e.compiledTypeMap.fallback[a],s&&st.call(s.styleAliases,l)&&(l=s.styleAliases[l]),n[a]=l;return n}function et(e){var r,n,i;if(r=e.toString(16).toUpperCase(),e<=255)n="x",i=2;else if(e<=65535)n="u",i=4;else if(e<=4294967295)n="U",i=8;else throw new ue("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+n+se.repeat("0",i-r.length)+r}function ps(e){this.schema=e.schema||$l,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=se.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=fs(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function rt(e,r){for(var n=se.repeat(" ",r),i=0,t=-1,o="",a,l=e.length;i<l;)t=e.indexOf(`
|
|
24
24
|
`,i),t===-1?(a=e.slice(i),i=l):(a=e.slice(i,t+1),i=t+1),a.length&&a!==`
|
|
25
25
|
`&&(o+=n),o+=a;return o}function Ze(e,r){return`
|
|
26
|
-
`+se.repeat(" ",e.indent*r)}function ds(e,r){var n,i,t;for(n=0,i=e.implicitTypes.length;n<i;n+=1)if(t=e.implicitTypes[n],t.resolve(r))return!0;return!1}function rr(e){return e===Ql||e===Kl}function X(e){return 32<=e&&e<=126||161<=e&&e<=55295&&e!==8232&&e!==8233||57344<=e&&e<=65533&&e!==65279||65536<=e&&e<=1114111}function hs(e){return X(e)&&!rr(e)&&e!==65279&&e!==Jl&&e!==le}function nt(e,r){return X(e)&&e!==65279&&e!==ct&&e!==pt&&e!==dt&&e!==ht&&e!==mt&&e!==ft&&(e!==ut||r&&hs(r))}function ms(e){return X(e)&&e!==65279&&!rr(e)&&e!==is&&e!==as&&e!==ft&&e!==ct&&e!==pt&&e!==dt&&e!==ht&&e!==mt&&e!==ut&&e!==es&&e!==ns&&e!==Vl&&e!==us&&e!==ts&&e!==os&&e!==rs&&e!==Xl&&e!==Zl&&e!==ls&&e!==ss}function gt(e){var r=/^\n* /;return r.test(e)}var xt=1,yt=2,vt=3,At=4,
|
|
26
|
+
`+se.repeat(" ",e.indent*r)}function ds(e,r){var n,i,t;for(n=0,i=e.implicitTypes.length;n<i;n+=1)if(t=e.implicitTypes[n],t.resolve(r))return!0;return!1}function rr(e){return e===Ql||e===Kl}function X(e){return 32<=e&&e<=126||161<=e&&e<=55295&&e!==8232&&e!==8233||57344<=e&&e<=65533&&e!==65279||65536<=e&&e<=1114111}function hs(e){return X(e)&&!rr(e)&&e!==65279&&e!==Jl&&e!==le}function nt(e,r){return X(e)&&e!==65279&&e!==ct&&e!==pt&&e!==dt&&e!==ht&&e!==mt&&e!==ft&&(e!==ut||r&&hs(r))}function ms(e){return X(e)&&e!==65279&&!rr(e)&&e!==is&&e!==as&&e!==ft&&e!==ct&&e!==pt&&e!==dt&&e!==ht&&e!==mt&&e!==ut&&e!==es&&e!==ns&&e!==Vl&&e!==us&&e!==ts&&e!==os&&e!==rs&&e!==Xl&&e!==Zl&&e!==ls&&e!==ss}function gt(e){var r=/^\n* /;return r.test(e)}var xt=1,yt=2,vt=3,At=4,be=5;function gs(e,r,n,i,t){var o,a,l,s=!1,u=!1,p=i!==-1,c=-1,d=ms(e.charCodeAt(0))&&!rr(e.charCodeAt(e.length-1));if(r)for(o=0;o<e.length;o++){if(a=e.charCodeAt(o),!X(a))return be;l=o>0?e.charCodeAt(o-1):null,d=d&&nt(a,l)}else{for(o=0;o<e.length;o++){if(a=e.charCodeAt(o),a===le)s=!0,p&&(u=u||o-c-1>i&&e[c+1]!==" ",c=o);else if(!X(a))return be;l=o>0?e.charCodeAt(o-1):null,d=d&&nt(a,l)}u=u||p&&o-c-1>i&&e[c+1]!==" "}return!s&&!u?d&&!t(e)?xt:yt:n>9&>(e)?be:u?At:vt}function xs(e,r,n,i){e.dump=function(){if(r.length===0)return"''";if(!e.noCompatMode&&cs.indexOf(r)!==-1)return"'"+r+"'";var t=e.indent*Math.max(1,n),o=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-t),a=i||e.flowLevel>-1&&n>=e.flowLevel;function l(s){return ds(e,s)}switch(gs(r,a,e.indent,o,l)){case xt:return r;case yt:return"'"+r.replace(/'/g,"''")+"'";case vt:return"|"+it(r,e.indent)+tt(rt(r,t));case At:return">"+it(r,e.indent)+tt(rt(ys(r,o),t));case be:return'"'+vs(r,o)+'"';default:throw new ue("impossible error: invalid scalar style")}}()}function it(e,r){var n=gt(e)?String(r):"",i=e[e.length-1]===`
|
|
27
27
|
`,t=i&&(e[e.length-2]===`
|
|
28
28
|
`||e===`
|
|
29
29
|
`),o=t?"+":i?"":"-";return n+o+`
|
|
@@ -35,10 +35,10 @@
|
|
|
35
35
|
`+e.slice(t,o),t=o+1),a=l;return s+=`
|
|
36
36
|
`,e.length-t>r&&a>t?s+=e.slice(t,a)+`
|
|
37
37
|
`+e.slice(a+1):s+=e.slice(t),s.slice(1)}function vs(e){for(var r="",n,i,t,o=0;o<e.length;o++){if(n=e.charCodeAt(o),n>=55296&&n<=56319&&(i=e.charCodeAt(o+1),i>=56320&&i<=57343)){r+=et((n-55296)*1024+i-56320+65536),o++;continue}t=C[n],r+=!t&&X(n)?e[o]:t||et(n)}return r}function As(e,r,n){var i="",t=e.tag,o,a;for(o=0,a=n.length;o<a;o+=1)H(e,r,n[o],!1,!1)&&(o!==0&&(i+=","+(e.condenseFlow?"":" ")),i+=e.dump);e.tag=t,e.dump="["+i+"]"}function ws(e,r,n,i){var t="",o=e.tag,a,l;for(a=0,l=n.length;a<l;a+=1)H(e,r+1,n[a],!0,!0)&&((!i||a!==0)&&(t+=Ze(e,r)),e.dump&&le===e.dump.charCodeAt(0)?t+="-":t+="- ",t+=e.dump);e.tag=o,e.dump=t||"[]"}function Cs(e,r,n){var i="",t=e.tag,o=Object.keys(n),a,l,s,u,p;for(a=0,l=o.length;a<l;a+=1)p="",a!==0&&(p+=", "),e.condenseFlow&&(p+='"'),s=o[a],u=n[s],H(e,r,s,!1,!1)&&(e.dump.length>1024&&(p+="? "),p+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),H(e,r,u,!1,!1)&&(p+=e.dump,i+=p));e.tag=t,e.dump="{"+i+"}"}function Ss(e,r,n,i){var t="",o=e.tag,a=Object.keys(n),l,s,u,p,c,d;if(e.sortKeys===!0)a.sort();else if(typeof e.sortKeys=="function")a.sort(e.sortKeys);else if(e.sortKeys)throw new ue("sortKeys must be a boolean or a function");for(l=0,s=a.length;l<s;l+=1)d="",(!i||l!==0)&&(d+=Ze(e,r)),u=a[l],p=n[u],H(e,r+1,u,!0,!0,!0)&&(c=e.tag!==null&&e.tag!=="?"||e.dump&&e.dump.length>1024,c&&(e.dump&&le===e.dump.charCodeAt(0)?d+="?":d+="? "),d+=e.dump,c&&(d+=Ze(e,r)),H(e,r+1,p,!0,c)&&(e.dump&&le===e.dump.charCodeAt(0)?d+=":":d+=": ",d+=e.dump,t+=d));e.tag=o,e.dump=t||"{}"}function at(e,r,n){var i,t,o,a,l,s;for(t=n?e.explicitTypes:e.implicitTypes,o=0,a=t.length;o<a;o+=1)if(l=t[o],(l.instanceOf||l.predicate)&&(!l.instanceOf||typeof r=="object"&&r instanceof l.instanceOf)&&(!l.predicate||l.predicate(r))){if(e.tag=n?l.tag:"?",l.represent){if(s=e.styleMap[l.tag]||l.defaultStyle,lt.call(l.represent)==="[object Function]")i=l.represent(r,s);else if(st.call(l.represent,s))i=l.represent[s](r,s);else throw new ue("!<"+l.tag+'> tag resolver accepts not "'+s+'" style');e.dump=i}return!0}return!1}function H(e,r,n,i,t,o){e.tag=null,e.dump=n,at(e,n,!1)||at(e,n,!0);var a=lt.call(e.dump);i&&(i=e.flowLevel<0||e.flowLevel>r);var l=a==="[object Object]"||a==="[object Array]",s,u;if(l&&(s=e.duplicates.indexOf(n),u=s!==-1),(e.tag!==null&&e.tag!=="?"||u||e.indent!==2&&r>0)&&(t=!1),u&&e.usedDuplicates[s])e.dump="*ref_"+s;else{if(l&&u&&!e.usedDuplicates[s]&&(e.usedDuplicates[s]=!0),a==="[object Object]")i&&Object.keys(e.dump).length!==0?(Ss(e,r,e.dump,t),u&&(e.dump="&ref_"+s+e.dump)):(Cs(e,r,e.dump),u&&(e.dump="&ref_"+s+" "+e.dump));else if(a==="[object Array]"){var p=e.noArrayIndent&&r>0?r-1:r;i&&e.dump.length!==0?(ws(e,p,e.dump,t),u&&(e.dump="&ref_"+s+e.dump)):(As(e,p,e.dump),u&&(e.dump="&ref_"+s+" "+e.dump))}else if(a==="[object String]")e.tag!=="?"&&xs(e,e.dump,r,o);else{if(e.skipInvalid)return!1;throw new ue("unacceptable kind of an object to dump "+a)}e.tag!==null&&e.tag!=="?"&&(e.dump="!<"+e.tag+"> "+e.dump)}return!0}function bs(e,r){var n=[],i=[],t,o;for(er(e,n,i),t=0,o=i.length;t<o;t+=1)r.duplicates.push(n[i[t]]);r.usedDuplicates=new Array(o)}function er(e,r,n){var i,t,o;if(e!==null&&typeof e=="object")if(t=r.indexOf(e),t!==-1)n.indexOf(t)===-1&&n.push(t);else if(r.push(e),Array.isArray(e))for(t=0,o=e.length;t<o;t+=1)er(e[t],r,n);else for(i=Object.keys(e),t=0,o=i.length;t<o;t+=1)er(e[i[t]],r,n)}function wt(e,r){r=r||{};var n=new ps(r);return n.noRefs||bs(e,n),H(n,0,e,!0,!0)?n.dump+`
|
|
38
|
-
`:""}function _s(e,r){return wt(e,se.extend({schema:Wl},r))}nr.exports.dump=wt;nr.exports.safeDump=_s});var bt=y((cp,v)=>{"use strict";var
|
|
38
|
+
`:""}function _s(e,r){return wt(e,se.extend({schema:Wl},r))}nr.exports.dump=wt;nr.exports.safeDump=_s});var bt=y((cp,v)=>{"use strict";var _e=Zi(),St=Ct();function Oe(e){return function(){throw new Error("Function "+e+" is deprecated and cannot be used.")}}v.exports.Type=w();v.exports.Schema=R();v.exports.FAILSAFE_SCHEMA=ye();v.exports.JSON_SCHEMA=We();v.exports.CORE_SCHEMA=Ke();v.exports.DEFAULT_SAFE_SCHEMA=K();v.exports.DEFAULT_FULL_SCHEMA=oe();v.exports.load=_e.load;v.exports.loadAll=_e.loadAll;v.exports.safeLoad=_e.safeLoad;v.exports.safeLoadAll=_e.safeLoadAll;v.exports.dump=St.dump;v.exports.safeDump=St.safeDump;v.exports.YAMLException=$();v.exports.MINIMAL_SCHEMA=ye();v.exports.SAFE_SCHEMA=K();v.exports.DEFAULT_SCHEMA=oe();v.exports.scan=Oe("scan");v.exports.parse=Oe("parse");v.exports.compose=Oe("compose");v.exports.addConstructor=Oe("addConstructor")});var Ot=y((fp,_t)=>{"use strict";var Os=bt();_t.exports=Os});var Ut=y((pp,Gt)=>{var Fs=200,or="__lodash_hash_undefined__",Es=1/0,It=9007199254740991,ks="[object Arguments]",Ts="[object Function]",Is="[object GeneratorFunction]",Ns="[object Symbol]",Ms=/[\\^$.*+?()[\]{}|]/g,Ls=/^\[object .+?Constructor\]$/,Ps=/^(?:0|[1-9]\d*)$/,Rs=typeof global=="object"&&global&&global.Object===Object&&global,Ds=typeof self=="object"&&self&&self.Object===Object&&self,ar=Rs||Ds||Function("return this")();function js(e,r,n){switch(n.length){case 0:return e.call(r);case 1:return e.call(r,n[0]);case 2:return e.call(r,n[0],n[1]);case 3:return e.call(r,n[0],n[1],n[2])}return e.apply(r,n)}function qs(e,r){var n=e?e.length:0;return!!n&&Gs(e,r,0)>-1}function Hs(e,r,n){for(var i=-1,t=e?e.length:0;++i<t;)if(n(r,e[i]))return!0;return!1}function Nt(e,r){for(var n=-1,i=e?e.length:0,t=Array(i);++n<i;)t[n]=r(e[n],n,e);return t}function lr(e,r){for(var n=-1,i=r.length,t=e.length;++n<i;)e[t+n]=r[n];return e}function Bs(e,r,n,i){for(var t=e.length,o=n+(i?1:-1);i?o--:++o<t;)if(r(e[o],o,e))return o;return-1}function Gs(e,r,n){if(r!==r)return Bs(e,Us,n);for(var i=n-1,t=e.length;++i<t;)if(e[i]===r)return i;return-1}function Us(e){return e!==e}function Ys(e,r){for(var n=-1,i=Array(e);++n<e;)i[n]=r(n);return i}function zs(e){return function(r){return e(r)}}function $s(e,r){return e.has(r)}function Ws(e,r){return e==null?void 0:e[r]}function Ks(e){var r=!1;if(e!=null&&typeof e.toString!="function")try{r=!!(e+"")}catch (e5){}return r}function Mt(e,r){return function(n){return e(r(n))}}var Js=Array.prototype,Qs=Function.prototype,Ee=Object.prototype,ir=ar["__core-js_shared__"],Ft=function(){var e=/[^.]+$/.exec(ir&&ir.keys&&ir.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),Lt=Qs.toString,Z=Ee.hasOwnProperty,sr=Ee.toString,Vs=RegExp("^"+Lt.call(Z).replace(Ms,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Et=ar.Symbol,Xs=Mt(Object.getPrototypeOf,Object),Zs=Ee.propertyIsEnumerable,eu=Js.splice,kt=Et?Et.isConcatSpreadable:void 0,tr=Object.getOwnPropertySymbols,Tt=Math.max,ru=Rt(ar,"Map"),ce=Rt(Object,"create");function B(e){var r=-1,n=e?e.length:0;for(this.clear();++r<n;){var i=e[r];this.set(i[0],i[1])}}function nu(){this.__data__=ce?ce(null):{}}function iu(e){return this.has(e)&&delete this.__data__[e]}function tu(e){var r=this.__data__;if(ce){var n=r[e];return n===or?void 0:n}return Z.call(r,e)?r[e]:void 0}function ou(e){var r=this.__data__;return ce?r[e]!==void 0:Z.call(r,e)}function au(e,r){var n=this.__data__;return n[e]=ce&&r===void 0?or:r,this}B.prototype.clear=nu;B.prototype.delete=iu;B.prototype.get=tu;B.prototype.has=ou;B.prototype.set=au;function ee(e){var r=-1,n=e?e.length:0;for(this.clear();++r<n;){var i=e[r];this.set(i[0],i[1])}}function lu(){this.__data__=[]}function su(e){var r=this.__data__,n=ke(r,e);if(n<0)return!1;var i=r.length-1;return n==i?r.pop():eu.call(r,n,1),!0}function uu(e){var r=this.__data__,n=ke(r,e);return n<0?void 0:r[n][1]}function cu(e){return ke(this.__data__,e)>-1}function fu(e,r){var n=this.__data__,i=ke(n,e);return i<0?n.push([e,r]):n[i][1]=r,this}ee.prototype.clear=lu;ee.prototype.delete=su;ee.prototype.get=uu;ee.prototype.has=cu;ee.prototype.set=fu;function re(e){var r=-1,n=e?e.length:0;for(this.clear();++r<n;){var i=e[r];this.set(i[0],i[1])}}function pu(){this.__data__={hash:new B,map:new(ru||ee),string:new B}}function du(e){return Te(this,e).delete(e)}function hu(e){return Te(this,e).get(e)}function mu(e){return Te(this,e).has(e)}function gu(e,r){return Te(this,e).set(e,r),this}re.prototype.clear=pu;re.prototype.delete=du;re.prototype.get=hu;re.prototype.has=mu;re.prototype.set=gu;function Fe(e){var r=-1,n=e?e.length:0;for(this.__data__=new re;++r<n;)this.add(e[r])}function xu(e){return this.__data__.set(e,or),this}function yu(e){return this.__data__.has(e)}Fe.prototype.add=Fe.prototype.push=xu;Fe.prototype.has=yu;function vu(e,r){var n=ur(e)||Dt(e)?Ys(e.length,String):[],i=n.length,t=!!i;for(var o in e)(r||Z.call(e,o))&&!(t&&(o=="length"||Iu(o,i)))&&n.push(o);return n}function ke(e,r){for(var n=e.length;n--;)if(ju(e[n][0],r))return n;return-1}function Au(e,r,n,i){var t=-1,o=qs,a=!0,l=e.length,s=[],u=r.length;if(!l)return s;n&&(r=Nt(r,zs(n))),i?(o=Hs,a=!1):r.length>=Fs&&(o=$s,a=!1,r=new Fe(r));e:for(;++t<l;){var p=e[t],c=n?n(p):p;if(p=i||p!==0?p:0,a&&c===c){for(var d=u;d--;)if(r[d]===c)continue e;s.push(p)}else o(r,c,i)||s.push(p)}return s}function Pt(e,r,n,i,t){var o=-1,a=e.length;for(n||(n=Tu),t||(t=[]);++o<a;){var l=e[o];r>0&&n(l)?r>1?Pt(l,r-1,n,i,t):lr(t,l):i||(t[t.length]=l)}return t}function wu(e,r,n){var i=r(e);return ur(e)?i:lr(i,n(e))}function Cu(e){if(!cr(e)||Mu(e))return!1;var r=qt(e)||Ks(e)?Vs:Ls;return r.test(Du(e))}function Su(e){if(!cr(e))return Pu(e);var r=Lu(e),n=[];for(var i in e)i=="constructor"&&(r||!Z.call(e,i))||n.push(i);return n}function bu(e,r){return e=Object(e),_u(e,r,function(n,i){return i in e})}function _u(e,r,n){for(var i=-1,t=r.length,o={};++i<t;){var a=r[i],l=e[a];n(l,a)&&(o[a]=l)}return o}function Ou(e,r){return r=Tt(r===void 0?e.length-1:r,0),function(){for(var n=arguments,i=-1,t=Tt(n.length-r,0),o=Array(t);++i<t;)o[i]=n[r+i];i=-1;for(var a=Array(r+1);++i<r;)a[i]=n[i];return a[r]=o,js(e,this,a)}}function Fu(e){return wu(e,Gu,ku)}function Te(e,r){var n=e.__data__;return Nu(r)?n[typeof r=="string"?"string":"hash"]:n.map}function Rt(e,r){var n=Ws(e,r);return Cu(n)?n:void 0}var Eu=tr?Mt(tr,Object):Bt,ku=tr?function(e){for(var r=[];e;)lr(r,Eu(e)),e=Xs(e);return r}:Bt;function Tu(e){return ur(e)||Dt(e)||!!(kt&&e&&e[kt])}function Iu(e,r){return r=r==null?It:r,!!r&&(typeof e=="number"||Ps.test(e))&&e>-1&&e%1==0&&e<r}function Nu(e){var r=typeof e;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?e!=="__proto__":e===null}function Mu(e){return!!Ft&&Ft in e}function Lu(e){var r=e&&e.constructor,n=typeof r=="function"&&r.prototype||Ee;return e===n}function Pu(e){var r=[];if(e!=null)for(var n in Object(e))r.push(n);return r}function Ru(e){if(typeof e=="string"||Bu(e))return e;var r=e+"";return r=="0"&&1/e==-Es?"-0":r}function Du(e){if(e!=null){try{return Lt.call(e)}catch (e6){}try{return e+""}catch (e7){}}return""}function ju(e,r){return e===r||e!==e&&r!==r}function Dt(e){return qu(e)&&Z.call(e,"callee")&&(!Zs.call(e,"callee")||sr.call(e)==ks)}var ur=Array.isArray;function jt(e){return e!=null&&Hu(e.length)&&!qt(e)}function qu(e){return Ht(e)&&jt(e)}function qt(e){var r=cr(e)?sr.call(e):"";return r==Ts||r==Is}function Hu(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=It}function cr(e){var r=typeof e;return!!e&&(r=="object"||r=="function")}function Ht(e){return!!e&&typeof e=="object"}function Bu(e){return typeof e=="symbol"||Ht(e)&&sr.call(e)==Ns}function Gu(e){return jt(e)?vu(e,!0):Su(e)}var Uu=Ou(function(e,r){return e==null?{}:(r=Nt(Pt(r,1),Ru),bu(e,Au(Fu(e),r)))});function Bt(){return[]}Gt.exports=Uu});var _angular = require('@orval/angular'); var _angular2 = _interopRequireDefault(_angular);var _axios = require('@orval/axios'); var _axios2 = _interopRequireDefault(_axios);var _msw = require('@orval/msw');var _query = require('@orval/query'); var _query2 = _interopRequireDefault(_query);var _swr = require('@orval/swr'); var _swr2 = _interopRequireDefault(_swr);var _zod = require('@orval/zod'); var _zod2 = _interopRequireDefault(_zod);var fe,zt,pe,$t,Wt,Kt,Jt,Vu,Qt,Vt=S(()=>{"use strict";fe=_core.OutputClient.AXIOS,zt={axios:_axios2.default.call(void 0, {type:"axios"})(),"axios-functions":_axios2.default.call(void 0, {type:"axios-functions"})(),angular:_angular2.default.call(void 0, )(),"react-query":_query2.default.call(void 0, {type:"react-query"})(),"svelte-query":_query2.default.call(void 0, {type:"svelte-query"})(),"vue-query":_query2.default.call(void 0, {type:"vue-query"})(),swr:_swr2.default.call(void 0, )(),zod:_zod2.default.call(void 0, )()},pe=e=>{let r=_core.isFunction.call(void 0, e)?e(zt):zt[e];if(!r)throw`Oups... \u{1F37B}. Client not found: ${e}`;return r},$t=({client:e=fe,implementation:r,imports:n,specsName:i,hasSchemaDir:t,isAllowSyntheticDefaultImports:o,hasGlobalMutator:a,packageJson:l})=>{let{dependencies:s}=pe(e);return _core.generateDependencyImports.call(void 0, r,s?[...s(a,l),...n]:n,i,t,o)},Wt=({outputClient:e=fe,isRequestOptions:r,isGlobalMutator:n,isMutator:i,provideIn:t,hasAwaitedType:o,titles:a})=>{let{header:l}=pe(e);return{implementation:l?l({title:a.implementation,isRequestOptions:r,isGlobalMutator:n,isMutator:i,provideIn:t,hasAwaitedType:o}):"",implementationMSW:`export const ${a.implementationMSW} = () => [
|
|
39
39
|
`}},Kt=({outputClient:e=fe,operationNames:r,hasMutator:n,hasAwaitedType:i,titles:t})=>{let{footer:o}=pe(e);if(!o)return{implementation:"",implementationMSW:`]
|
|
40
40
|
`};let a;try{_core.isFunction.call(void 0, e)?(a=o(r),console.warn("[WARN] Passing an array of strings for operations names to the footer function is deprecated and will be removed in a future major release. Please pass them in an object instead: { operationNames: string[] }.")):a=o({operationNames:r,title:t.implementation,hasMutator:n,hasAwaitedType:i})}catch (e8){a=o({operationNames:r,title:t.implementation,hasMutator:n,hasAwaitedType:i})}return{implementation:a,implementationMSW:`]
|
|
41
|
-
`}},Jt=({outputClient:e=fe,title:r,customTitleFunc:n})=>{let{title:i}=pe(e);if(!i)return{implementation:"",implementationMSW:`get${_core.pascal.call(void 0, r)}MSW`};if(n){let t=n(r);return{implementation:i(t),implementationMSW:`get${_core.pascal.call(void 0, t)}MSW`}}return{implementation:i(r),implementationMSW:`get${_core.pascal.call(void 0, r)}MSW`}},Vu=(e,r)=>r.mock?_core.isFunction.call(void 0, r.mock)?r.mock(e,r):_msw.generateMSW.call(void 0, e,r):{implementation:{function:"",handler:""},imports:[]},Qt=(e=fe,r,n)=>_core.asyncReduce.call(void 0, r,async(i,t)=>{let{client:o}=pe(e),a=await o(t,n,e),l=Vu(t,n);return a.implementation&&(i[t.operationId]={implementation:t.doc+a.implementation,imports:a.imports,implementationMSW:l.implementation,importsMSW:l.imports,tags:t.tags,mutator:t.mutator,clientMutators:a.mutators,formData:t.formData,formUrlEncoded:t.formUrlEncoded,operationName:t.operationName}),i},{})});var Xt,Zt=S(()=>{"use strict";Vt();Xt=async({input:e,output:r,context:n})=>{var t;let i=await _core.asyncReduce.call(void 0, Object.entries((t=n.specs[n.specKey].paths)!=null?t:{}),async(o,[a,l])=>{let s=_core.getRoute.call(void 0, a),u=l,p=n;if(_core.isReference.call(void 0, l)){let{schema:h,imports:x}=_core.resolveRef.call(void 0, l,n);u=h,p={...n,...x.length?{specKey:x[0].specKey}:{}}}let c=await _core.generateVerbsOptions.call(void 0, {verbs:u,input:e,output:r,route:s,context:p});r.override.useDeprecatedOperations===!1&&(c=c.filter(h=>!h.deprecated));let d=c.reduce((h,{queryParams:x,headers:m,body:G,response:k})=>(x&&h.push(x.schema,...x.deps),m&&h.push(m.schema,...m.deps),h.push(...G.schemas),h.push(...k.schemas),h),[]),f=await Qt(r.client,c,{route:s,pathRoute:a,override:r.override,context:p,mock:!!r.mock,output:r.target});return o.schemas.push(...d),o.operations={...o.operations,...f},o},{operations:{},schemas:[]});return{operations:i.operations,schemas:i.schemas,title:Jt,header:Wt,footer:Kt,imports
|
|
41
|
+
`}},Jt=({outputClient:e=fe,title:r,customTitleFunc:n})=>{let{title:i}=pe(e);if(!i)return{implementation:"",implementationMSW:`get${_core.pascal.call(void 0, r)}MSW`};if(n){let t=n(r);return{implementation:i(t),implementationMSW:`get${_core.pascal.call(void 0, t)}MSW`}}return{implementation:i(r),implementationMSW:`get${_core.pascal.call(void 0, r)}MSW`}},Vu=(e,r)=>r.mock?_core.isFunction.call(void 0, r.mock)?r.mock(e,r):_msw.generateMSW.call(void 0, e,r):{implementation:{function:"",handler:""},imports:[]},Qt=(e=fe,r,n)=>_core.asyncReduce.call(void 0, r,async(i,t)=>{let{client:o}=pe(e),a=await o(t,n,e),l=Vu(t,n);return a.implementation&&(i[t.operationId]={implementation:t.doc+a.implementation,imports:a.imports,implementationMSW:l.implementation,importsMSW:l.imports,tags:t.tags,mutator:t.mutator,clientMutators:a.mutators,formData:t.formData,formUrlEncoded:t.formUrlEncoded,operationName:t.operationName}),i},{})});var Xt,Zt=S(()=>{"use strict";Vt();Xt=async({input:e,output:r,context:n})=>{var t;let i=await _core.asyncReduce.call(void 0, Object.entries((t=n.specs[n.specKey].paths)!=null?t:{}),async(o,[a,l])=>{let s=_core.getRoute.call(void 0, a),u=l,p=n;if(_core.isReference.call(void 0, l)){let{schema:h,imports:x}=_core.resolveRef.call(void 0, l,n);u=h,p={...n,...x.length?{specKey:x[0].specKey}:{}}}let c=await _core.generateVerbsOptions.call(void 0, {verbs:u,input:e,output:r,route:s,context:p});r.override.useDeprecatedOperations===!1&&(c=c.filter(h=>!h.deprecated));let d=c.reduce((h,{queryParams:x,headers:m,body:G,response:k})=>(x&&h.push(x.schema,...x.deps),m&&h.push(m.schema,...m.deps),h.push(...G.schemas),h.push(...k.schemas),h),[]),f=await Qt(r.client,c,{route:s,pathRoute:a,override:r.override,context:p,mock:!!r.mock,output:r.target});return o.schemas.push(...d),o.operations={...o.operations,...f},o},{operations:{},schemas:[]});return{operations:i.operations,schemas:i.schemas,title:Jt,header:Wt,footer:Kt,imports:$t,importsMock:_msw.generateMSWImports}}});var hr,gr,dc,hc,mr,no=S(()=>{"use strict";hr=M(Ut());Zt();gr=async({data:e,input:r,output:n,target:i,workspace:t})=>{var s;let o=await dc({specs:e,input:r,workspace:t}),a=hc({output:n,target:i,workspace:t,specs:o}),l=await Xt({input:r,output:n,context:{specKey:i,target:i,workspace:t,specs:o,override:n.override,tslint:n.tslint,tsconfig:n.tsconfig,packageJson:n.packageJson}});return{...l,schemas:{...a,[i]:[...(s=a[i])!=null?s:[],...l.schemas]},target:i,info:o[i].info}},dc=async({specs:e,input:r,workspace:n})=>{var t;let i=(t=r.override)!=null&&t.transformer?await _core.dynamicImport.call(void 0, r.override.transformer,n):void 0;return _core.asyncReduce.call(void 0, Object.entries(e),async(o,[a,l])=>{let s=await _core.openApiConverter.call(void 0, l,r.converterOptions,a),u=i?i(s):s;return r.validation&&await _core.ibmOpenapiValidator.call(void 0, u),o[a]=u,o},{})},hc=({output:e,target:r,workspace:n,specs:i})=>Object.entries(i).reduce((t,[o,a])=>{var f,h,x,m;let l={specKey:o,target:r,workspace:n,specs:i,override:e.override,tslint:e.tslint,tsconfig:e.tsconfig,packageJson:e.packageJson},s=_core.generateSchemasDefinition.call(void 0, a.openapi?(f=a.components)==null?void 0:f.schemas:mr(a,o),l,e.override.components.schemas.suffix),u=_core.generateComponentDefinition.call(void 0, (h=a.components)==null?void 0:h.responses,l,e.override.components.responses.suffix),p=_core.generateComponentDefinition.call(void 0, (x=a.components)==null?void 0:x.requestBodies,l,e.override.components.requestBodies.suffix),c=_core.generateParameterDefinition.call(void 0, (m=a.components)==null?void 0:m.parameters,l,e.override.components.parameters.suffix),d=[...s,...u,...p,...c];return d.length&&(t[o]=d),t},{}),mr=(e,r)=>{var t;let n=(0,hr.default)(e,["openapi","info","servers","paths","components","security","tags","externalDocs"]);return r&&_core.isSchema.call(void 0, n)?{[_core.upath.getSchemaFileName(r)]:n,...mr((0,hr.default)(n,["type","properties","allOf","oneOf","anyOf","items"]))}:{...Object.entries(n).reduce((o,[a,l])=>_core.isObject.call(void 0, l)?!_core.isSchema.call(void 0, l)&&!_core.isReference.call(void 0, l)?{...o,...mr(l)}:(o[a]=l,o):o,{}),...(t=e==null?void 0:e.components)==null?void 0:t.schemas}}});var _swaggerparser = require('@apidevtools/swagger-parser'); var _swaggerparser2 = _interopRequireDefault(_swaggerparser);var to,wc,oo,ao=S(()=>{"use strict";to=M(Ot());no();wc=async(e,{validate:r,...n},i,t)=>{try{if(r)try{await _swaggerparser2.default.validate(e,n)}catch(a){if((a==null?void 0:a.name)==="ParserError")throw a;t||_core.log.call(void 0, `\u26A0\uFE0F ${_chalk2.default.yellow(a)}`)}let o=(await _swaggerparser2.default.resolve(e,n)).values();return i?o:Object.fromEntries(Object.entries(o).map(([a,l])=>[_core.upath.resolve(a),l]))}catch (e9){let o=await _fsextra2.default.readFile(e,"utf8");return{[e]:to.default.load(o)}}},oo=async(e,r)=>{let{input:n,output:i}=r;if(_core.isObject.call(void 0, n.target))return gr({data:{[e]:n.target},input:n,output:i,target:e,workspace:e});let t=_core.isUrl.call(void 0, n.target),o=await wc(n.target,n.parserOptions,t,!i.target);return gr({data:o,input:n,output:i,target:n.target,workspace:e})}});var _execa = require('execa'); var _execa2 = _interopRequireDefault(_execa);var _stringargv = require('string-argv');var uo,co=S(()=>{"use strict";uo=async(e,r=[],n=[])=>{_core.log.call(void 0, _chalk2.default.white(`Running ${e} hook...`));for(let i of r)if(_core.isString.call(void 0, i)){let[t,...o]=[..._stringargv.parseArgsStringToArgv.call(void 0, i),...n];try{await _execa2.default.call(void 0, t,o)}catch(a){_core.log.call(void 0, _chalk2.default.red(`\u{1F6D1} Failed to run ${e} hook: ${a}`))}}else _core.isFunction.call(void 0, i)&&await i(n)}});var fo=S(()=>{"use strict";co();Re();ie();De();Me();je();Ye()});var _lodashuniq = require('lodash.uniq'); var _lodashuniq2 = _interopRequireDefault(_lodashuniq);var Rc,mo,Dc,go=S(()=>{"use strict";fo();Rc=(e,r)=>{if(!e)return"";let n=e(r);return Array.isArray(n)?_core.jsDoc.call(void 0, {description:n}):n},mo=async(e,r,n,i)=>{let{info:t={title:"",version:0},schemas:o,target:a}=e,{output:l}=n,s=i||t.title,u=Object.keys(o).reduce((f,h)=>{let m=_core.upath.getSpecName(h,a).slice(1).split("/").join("-");return f[h]=m,f},{}),p=Rc(l.override.header,t);if(l.schemas){let f=l.schemas;await Promise.all(Object.entries(o).map(([h,x])=>{let m=_core.isRootKey.call(void 0, h,a)?f:_core.upath.join(f,u[h]);return _core.writeSchemas.call(void 0, {schemaPath:m,schemas:x,target:a,specsName:u,specKey:h,isRootKey:_core.isRootKey.call(void 0, h,a),header:p})}))}let c=[];if(l.target&&(c=await Dc(l.mode)({builder:e,workspace:r,output:l,specsName:u,header:p,needSchema:!l.schemas&&l.client!=="zod"})),l.workspace){let f=l.workspace,h=c.filter(m=>!m.endsWith(".msw.ts")).map(m=>_core.upath.relativeSafe(f,_core.getFileInfo.call(void 0, m).pathWithoutExtension));l.schemas&&h.push(_core.upath.relativeSafe(f,_core.getFileInfo.call(void 0, l.schemas).dirname));let x=_core.upath.join(f,"/index.ts");if(await _fsextra2.default.pathExists(x)){let m=await _fsextra2.default.readFile(x,"utf8"),G=h.filter(k=>!m.includes(k));await _fsextra2.default.appendFile(x,_lodashuniq2.default.call(void 0, G).map(k=>`export * from '${k}';`).join(`
|
|
42
42
|
`)+`
|
|
43
43
|
`)}else await _fsextra2.default.outputFile(x,_lodashuniq2.default.call(void 0, h).map(m=>`export * from '${m}';`).join(`
|
|
44
44
|
`)+`
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var _chunkL4BGJ5OZjs = require('./chunk-L4BGJ5OZ.js');_chunkL4BGJ5OZjs.k.call(void 0, );_chunkL4BGJ5OZjs.f.call(void 0, );_chunkL4BGJ5OZjs.h.call(void 0, );var _core = require('@orval/core');var _chalk = require('chalk'); var _chalk2 = _interopRequireDefault(_chalk);var y=async(r,a=process.cwd(),e)=>{if(!r||_core.isString.call(void 0, r))return _chunkL4BGJ5OZjs.j.call(void 0, r,e);let c=await _chunkL4BGJ5OZjs.e.call(void 0, r,a,e);if(e!=null&&e.watch)_chunkL4BGJ5OZjs.g.call(void 0, e==null?void 0:e.watch,async()=>{try{await _chunkL4BGJ5OZjs.i.call(void 0, a,c)}catch(m){_core.log.call(void 0, _chalk2.default.red(`\u{1F6D1} ${e!=null&&e.projectName?`${e==null?void 0:e.projectName} - `:""}${m}`))}},c.input.target);else try{return await _chunkL4BGJ5OZjs.i.call(void 0, a,c)}catch(m){_core.log.call(void 0, _chalk2.default.red(`\u{1F6D1} ${e!=null&&e.projectName?`${e==null?void 0:e.projectName} - `:""}${m}`))}};var q=y;exports.Options = _core.Options; exports.default = q; exports.defineConfig = _chunkL4BGJ5OZjs.d; exports.generate = y;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "orval",
|
|
3
3
|
"description": "A swagger client generator for typescript",
|
|
4
|
-
"version": "6.
|
|
4
|
+
"version": "6.17.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist"
|
|
@@ -31,7 +31,8 @@
|
|
|
31
31
|
"axios",
|
|
32
32
|
"vue-query",
|
|
33
33
|
"vue",
|
|
34
|
-
"swr"
|
|
34
|
+
"swr",
|
|
35
|
+
"zod"
|
|
35
36
|
],
|
|
36
37
|
"author": {
|
|
37
38
|
"name": "Victor Bury",
|
|
@@ -55,13 +56,13 @@
|
|
|
55
56
|
},
|
|
56
57
|
"dependencies": {
|
|
57
58
|
"@apidevtools/swagger-parser": "^10.1.0",
|
|
58
|
-
"@orval/angular": "6.
|
|
59
|
-
"@orval/axios": "6.
|
|
60
|
-
"@orval/core": "6.
|
|
61
|
-
"@orval/msw": "6.
|
|
62
|
-
"@orval/query": "6.
|
|
63
|
-
"@orval/swr": "6.
|
|
64
|
-
"@orval/zod": "6.
|
|
59
|
+
"@orval/angular": "6.17.0",
|
|
60
|
+
"@orval/axios": "6.17.0",
|
|
61
|
+
"@orval/core": "6.17.0",
|
|
62
|
+
"@orval/msw": "6.17.0",
|
|
63
|
+
"@orval/query": "6.17.0",
|
|
64
|
+
"@orval/swr": "6.17.0",
|
|
65
|
+
"@orval/zod": "6.17.0",
|
|
65
66
|
"ajv": "^8.11.0",
|
|
66
67
|
"cac": "^6.7.12",
|
|
67
68
|
"chalk": "^4.1.2",
|