From 7f6028b8774029fe194e50b68a6caf2a157fa8d2 Mon Sep 17 00:00:00 2001 From: Raphael Hohmann Date: Wed, 1 May 2024 18:07:22 +0200 Subject: [PATCH] feat: makes Makefile redocly update .PHONY, updates the redocly latest bundle url and executes an update --- Makefile | 8 +- assets/redoc.standalone.js | 1825 +++++++++++++++++++++++++++++++++++- 2 files changed, 1828 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 6fc7c5a..541d950 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ -.PHONY: all lint test deps - REDOC_PATH=assets/redoc.standalone.js -REDOC_URL=https://cdn.jsdelivr.net/npm/redoc/bundles/redoc.standalone.js +REDOC_URL=https://cdn.redoc.ly/redoc/latest/bundles/redoc.standalone.js + +.PHONY: all lint test deps $(REDOC_PATH) all: $(REDOC_PATH) lint test @@ -17,4 +17,4 @@ deps: go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest $(REDOC_PATH): - curl -sL -o $(REDOC_PATH) $(REDOC_URL) + curl -sL -o $(REDOC_PATH) $(REDOC_URL) \ No newline at end of file diff --git a/assets/redoc.standalone.js b/assets/redoc.standalone.js index 09f3ab8..3826b5a 100644 --- a/assets/redoc.standalone.js +++ b/assets/redoc.standalone.js @@ -1,3 +1,1826 @@ /*! For license information please see redoc.standalone.js.LICENSE.txt */ -!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("null")):"function"==typeof define&&define.amd?define(["null"],t):"object"==typeof exports?exports.Redoc=t(require("null")):e.Redoc=t(e.null)}(this,(function(e){return function(){var t={7228:function(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){l=!0,a=e},f:function(){try{s||null==n.return||n.return()}finally{if(l)throw a}}}},e.exports.default=e.exports,e.exports.__esModule=!0},9842:function(e,t,n){var r=n(9754),o=n(7067),i=n(8585);e.exports=function(e){var t=o();return function(){var n,o=r(e);if(t){var a=r(this).constructor;n=Reflect.construct(o,arguments,a)}else n=o.apply(this,arguments);return i(this,n)}},e.exports.default=e.exports,e.exports.__esModule=!0},9713:function(e){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.default=e.exports,e.exports.__esModule=!0},9754:function(e){function t(n){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.default=e.exports,e.exports.__esModule=!0,t(n)}e.exports=t,e.exports.default=e.exports,e.exports.__esModule=!0},2205:function(e,t,n){var r=n(9489);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},430:function(e){e.exports=function(e){return-1!==Function.toString.call(e).indexOf("[native code]")},e.exports.default=e.exports,e.exports.__esModule=!0},7067:function(e){e.exports=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.default=e.exports,e.exports.__esModule=!0},6860:function(e){e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.default=e.exports,e.exports.__esModule=!0},3884:function(e){e.exports=function(e,t){var n=e&&("undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"]);if(null!=n){var r,o,i=[],a=!0,s=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){s=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(s)throw o}}return i}},e.exports.default=e.exports,e.exports.__esModule=!0},521:function(e){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.default=e.exports,e.exports.__esModule=!0},8206:function(e){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.default=e.exports,e.exports.__esModule=!0},8585:function(e,t,n){var r=n(8).default,o=n(1506);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?o(e):t},e.exports.default=e.exports,e.exports.__esModule=!0},9489:function(e){function t(n,r){return e.exports=t=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},e.exports.default=e.exports,e.exports.__esModule=!0,t(n,r)}e.exports=t,e.exports.default=e.exports,e.exports.__esModule=!0},3038:function(e,t,n){var r=n(2858),o=n(3884),i=n(379),a=n(521);e.exports=function(e,t){return r(e)||o(e,t)||i(e,t)||a()},e.exports.default=e.exports,e.exports.__esModule=!0},319:function(e,t,n){var r=n(3646),o=n(6860),i=n(379),a=n(8206);e.exports=function(e){return r(e)||o(e)||i(e)||a()},e.exports.default=e.exports,e.exports.__esModule=!0},8:function(e){function t(n){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(e.exports=t=function(e){return typeof e},e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=t=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.default=e.exports,e.exports.__esModule=!0),t(n)}e.exports=t,e.exports.default=e.exports,e.exports.__esModule=!0},379:function(e,t,n){var r=n(7228);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}},e.exports.default=e.exports,e.exports.__esModule=!0},5957:function(e,t,n){var r=n(9754),o=n(9489),i=n(430),a=n(9100);function s(t){var n="function"==typeof Map?new Map:void 0;return e.exports=s=function(e){if(null===e||!i(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==n){if(n.has(e))return n.get(e);n.set(e,t)}function t(){return a(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),o(t,e)},e.exports.default=e.exports,e.exports.__esModule=!0,s(t)}e.exports=s,e.exports.default=e.exports,e.exports.__esModule=!0},7757:function(e,t,n){e.exports=n(5666)},2840:function(e,t,n){"use strict";var r=n(319).default,o=n(7757);n(1539),n(8674),n(9601),n(2222),n(1249),n(8309),n(7941),n(7327),n(4916),n(3123),n(7042);var i=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(e){i(e)}}function s(e){try{l(r.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.bundleDocument=t.bundle=t.OasVersion=void 0;var a,s=n(2307),l=n(8604),c=n(9079),u=n(8553),p=n(4343),f=n(7649),d=n(9562),h=n(3353),m=n(6230),v=n(8140),g=n(4241),y=n(2806),b=n(9272);function x(e){return i(this,void 0,void 0,o.mark((function t(){var n,i,s,v,y,b,x,w,E,S,_,O,A,R,C;return o.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.document,i=e.config,s=e.customTypes,v=e.externalRefResolver,y=e.dereference,b=void 0!==y&&y,x=m.detectOpenAPI(n.parsed),w=m.openAPIMajor(x),E=i.getRulesForOasVersion(w),S=d.normalizeTypes(i.extendTypes((null!=s?s:w===m.OasMajorVersion.Version3)?x===a.Version3_1?f.Oas3_1Types:u.Oas3Types:p.Oas2Types,x),i),_=g.initRules(E,i,"preprocessors",x),O=g.initRules(E,i,"decorators",x),A={problems:[],oasVersion:x},R=c.normalizeVisitors([].concat(r(_),[{severity:"error",ruleId:"bundler",visitor:k(w,b,n)}],r(O)),S),t.next=11,l.resolveDocument({rootDocument:n,rootType:S.DefinitionRoot,externalRefResolver:v});case 11:return C=t.sent,h.walkDocument({document:n,rootType:S.DefinitionRoot,normalizedVisitors:R,resolvedRefMap:C,ctx:A}),t.abrupt("return",{bundle:n,problems:A.problems.map((function(e){return i.addProblemToIgnore(e)})),fileDependencies:v.getFiles()});case 14:case"end":return t.stop()}}),t)})))}function w(e,t){switch(t){case m.OasMajorVersion.Version3:switch(e){case"Schema":return"schemas";case"Parameter":return"parameters";case"Response":return"responses";case"Example":return"examples";case"RequestBody":return"requestBodies";case"Header":return"headers";case"SecuritySchema":return"securitySchemes";case"Link":return"links";case"Callback":return"callbacks";default:return null}case m.OasMajorVersion.Version2:switch(e){case"Schema":return"definitions";case"Parameter":return"parameters";case"Response":return"responses";default:return null}}}function k(e,t,n){var r,o={ref:{leave:function(r,o,s){if(s.location&&void 0!==s.node){if(s.location.source!==n.source||s.location.source!==o.location.source||"scalar"===o.type.name||t){var l=w(o.type.name,e);l?t?(a(l,s,o),i(r,s,o)):r.$ref=a(l,s,o):i(r,s,o)}}else y.reportUnresolvedRef(s,o.report,o.location)}},DefinitionRoot:{enter:function(t){e===m.OasMajorVersion.Version3?r=t.components=t.components||{}:e===m.OasMajorVersion.Version2&&(r=t)}}};function i(e,t,n){b.isPlainObject(t.node)?(delete e.$ref,Object.assign(e,t.node)):n.parent[n.key]=t.node}function a(t,n,o){r[t]=r[t]||{};var i=function(e,t,n){for(var o=[e.location.source.absoluteRef,e.location.pointer],i=o[0],a=o[1],l=r[t],c="",u=a.slice(2).split("/").filter(Boolean);u.length>0;)if(c=u.pop()+(c?"-".concat(c):""),!l||!l[c]||s(l[c],e.node))return c;if(!l[c=v.refBaseName(i)+(c?"_".concat(c):"")]||s(l[c],e.node))return c;for(var p=c,f=2;l[c]&&!s(l[c],e.node);)c="".concat(p,"-").concat(f),f++;return l[c]||n.report({message:"Two schemas are referenced with the same name but different content. Renamed ".concat(p," to ").concat(c,"."),location:n.location,forceSeverity:"warn"}),c}(n,t,o);return r[t][i]=n.node,e===m.OasMajorVersion.Version3?"#/components/".concat(t,"/").concat(i):"#/".concat(t,"/").concat(i)}return e===m.OasMajorVersion.Version3&&(o.DiscriminatorMapping={leave:function(n,r){for(var o=0,i=Object.keys(n);o1&&void 0!==arguments[1]?arguments[1]:"";if(!e)return[];var n=require,r=new Map;return e.map((function(e){var o="string"==typeof e?n(u.resolve(u.dirname(t),e)):e,i=o.id;if("string"!=typeof i)throw new Error(d.red("Plugin must define `id` property in ".concat(d.blue(e.toString()),".")));if(r.has(i)){var a=r.get(i);throw new Error(d.red('Plugin "id" must be unique. Plugin '.concat(d.blue(e.toString()),' uses id "').concat(d.blue(i),'" already seen in ').concat(d.blue(a))))}r.set(i,e.toString());var s=Object.assign(Object.assign({id:i},o.configs?{configs:o.configs}:{}),o.typeExtension?{typeExtension:o.typeExtension}:{});if(o.rules){if(!o.rules.oas3&&!o.rules.oas2)throw new Error('Plugin rules must have `oas3` or `oas2` rules "'.concat(e,"."));s.rules={},o.rules.oas3&&(s.rules.oas3=y(o.rules.oas3,i)),o.rules.oas2&&(s.rules.oas2=y(o.rules.oas2,i))}if(o.preprocessors){if(!o.preprocessors.oas3&&!o.preprocessors.oas2)throw new Error('Plugin `preprocessors` must have `oas3` or `oas2` preprocessors "'.concat(e,"."));s.preprocessors={},o.preprocessors.oas3&&(s.preprocessors.oas3=y(o.preprocessors.oas3,i)),o.preprocessors.oas2&&(s.preprocessors.oas2=y(o.preprocessors.oas2,i))}if(o.decorators){if(!o.decorators.oas3&&!o.decorators.oas2)throw new Error('Plugin `decorators` must have `oas3` or `oas2` decorators "'.concat(e,"."));s.decorators={},o.decorators.oas3&&(s.decorators.oas3=y(o.decorators.oas3,i)),o.decorators.oas2&&(s.decorators.oas2=y(o.decorators.oas2,i))}return s})).filter(h.notUndefined)}(n.plugins,o):[],this.doNotResolveExamples=!!n.doNotResolveExamples,n.extends||(this.recommendedFallback=!0);var w,k,E=n.extends?(w=n.extends,k=this.plugins,w.map((function(e){var t,n=function(e){if(e.indexOf("/")>-1){var t=e.split("/"),n=r(t,2);return{pluginId:n[0],configName:n[1]}}return{pluginId:"",configName:e}}(e),o=n.pluginId,i=n.configName,a=k.find((function(e){return e.id===o}));if(!a)throw new Error("Invalid config ".concat(d.red(e),": plugin ").concat(o," is not included."));var s=null===(t=a.configs)||void 0===t?void 0:t[i];if(!s)throw new Error(o?"Invalid config ".concat(d.red(e),": plugin ").concat(o," doesn't export config with name ").concat(i,"."):"Invalid config ".concat(d.red(e),": there is no such built-in config."));return s}))):[v.default];(n.rules||n.preprocessors||n.decorators)&&E.push({rules:n.rules,preprocessors:n.preprocessors,decorators:n.decorators});var S=function(e){var t,n={rules:{},oas2Rules:{},oas3_0Rules:{},oas3_1Rules:{},preprocessors:{},oas2Preprocessors:{},oas3_0Preprocessors:{},oas3_1Preprocessors:{},decorators:{},oas2Decorators:{},oas3_0Decorators:{},oas3_1Decorators:{}},r=i(e);try{for(r.s();!(t=r.n()).done;){var o=t.value;if(o.extends)throw new Error("`extends` is not supported in shared configs yet: ".concat(JSON.stringify(o,null,2),"."));Object.assign(n.rules,o.rules),Object.assign(n.oas2Rules,o.oas2Rules),b(n.oas2Rules,o.rules||{}),Object.assign(n.oas3_0Rules,o.oas3_0Rules),b(n.oas3_0Rules,o.rules||{}),Object.assign(n.oas3_1Rules,o.oas3_1Rules),b(n.oas3_1Rules,o.rules||{}),Object.assign(n.preprocessors,o.preprocessors),Object.assign(n.oas2Preprocessors,o.oas2Preprocessors),b(n.oas2Preprocessors,o.preprocessors||{}),Object.assign(n.oas3_0Preprocessors,o.oas3_0Preprocessors),b(n.oas3_0Preprocessors,o.preprocessors||{}),Object.assign(n.oas3_1Preprocessors,o.oas3_1Preprocessors),b(n.oas3_1Preprocessors,o.preprocessors||{}),Object.assign(n.decorators,o.decorators),Object.assign(n.oas2Decorators,o.oas2Decorators),b(n.oas2Decorators,o.decorators||{}),Object.assign(n.oas3_0Decorators,o.oas3_0Decorators),b(n.oas3_0Decorators,o.decorators||{}),Object.assign(n.oas3_1Decorators,o.oas3_1Decorators),b(n.oas3_1Decorators,o.decorators||{})}}catch(e){r.e(e)}finally{r.f()}return n}(E);this.rules=(a(l={},m.OasVersion.Version2,Object.assign(Object.assign({},S.rules),S.oas2Rules)),a(l,m.OasVersion.Version3_0,Object.assign(Object.assign({},S.rules),S.oas3_0Rules)),a(l,m.OasVersion.Version3_1,Object.assign(Object.assign({},S.rules),S.oas3_1Rules)),l),this.preprocessors=(a(g={},m.OasVersion.Version2,Object.assign(Object.assign({},S.preprocessors),S.oas2Preprocessors)),a(g,m.OasVersion.Version3_0,Object.assign(Object.assign({},S.preprocessors),S.oas3_0Preprocessors)),a(g,m.OasVersion.Version3_1,Object.assign(Object.assign({},S.preprocessors),S.oas3_1Preprocessors)),g),this.decorators=(a(x={},m.OasVersion.Version2,Object.assign(Object.assign({},S.decorators),S.oas2Decorators)),a(x,m.OasVersion.Version3_0,Object.assign(Object.assign({},S.decorators),S.oas3_0Decorators)),a(x,m.OasVersion.Version3_1,Object.assign(Object.assign({},S.decorators),S.oas3_1Decorators)),x);var _=this.configFile?u.dirname(this.configFile):"undefined"!=typeof process&&process.cwd()||"",O=u.join(_,t.bD);if(c.hasOwnProperty("existsSync")&&c.existsSync(O)){this.ignore=p.safeLoad(c.readFileSync(O,"utf-8"))||{};for(var A=0,R=Object.keys(this.ignore);A-1}},8604:function(e,t,n){"use strict";var r=n(3269).default,o=n(7757),i=n(3038).default,a=n(1506).default,s=n(2205).default,l=n(9842).default,c=n(5957).default,u=n(4575).default,p=n(3913).default;n(1539),n(8674),n(4916),n(3123),n(4723),n(6992),n(1532),n(8783),n(3948),n(189),n(1038),n(6699),n(2222),n(8309),n(7941),n(9601);var f=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(e){i(e)}}function s(e){try{l(r.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.resolveDocument=t.BaseResolver=t.makeDocumentFromString=t.YamlParseError=t.ResolveError=t.Source=void 0;var d=n(3817),h=n(6470),m=n(8575),v=n(4756),g=n(8140),y=n(9562),b=n(9272),x=function(){function e(t,n,r){u(this,e),this.absoluteRef=t,this.body=n,this.mimeType=r}return p(e,[{key:"getAst",value:function(e){var t;return void 0===this._ast&&(this._ast=null!==(t=e(this.body,{filename:this.absoluteRef}))&&void 0!==t?t:void 0,this._ast&&0===this._ast.kind&&""===this._ast.value&&1!==this._ast.startPosition&&(this._ast.startPosition=1,this._ast.endPosition=1)),this._ast}},{key:"getLines",value:function(){return void 0===this._lines&&(this._lines=this.body.split(/\r\n|[\n\r]/g)),this._lines}}]),e}();t.Source=x;var w=function(e){s(n,e);var t=l(n);function n(e){var r;return u(this,n),(r=t.call(this,e.message)).originalError=e,Object.setPrototypeOf(a(r),n.prototype),r}return n}(c(Error));t.ResolveError=w;var k=/at line (\d+), column (\d+):/,E=function(e){s(n,e);var t=l(n);function n(e,r){var o;u(this,n),(o=t.call(this,e.message.split("\n")[0])).originalError=e,o.source=r,Object.setPrototypeOf(a(o),n.prototype);var s=o.message.match(k)||[],l=i(s,3),c=l[1],p=l[2];return o.line=parseInt(c,10),o.col=parseInt(p,10),o}return n}(c(Error));t.YamlParseError=E,t.makeDocumentFromString=function(e,t){var n=new x(t,e);try{return{source:n,parsed:v.safeLoad(e,{filename:t})}}catch(e){throw new E(e,n)}};var S=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{http:{headers:[]}};u(this,e),this.config=t,this.cache=new Map}return p(e,[{key:"getFiles",value:function(){return new Set(Array.from(this.cache.keys()))}},{key:"resolveExternalRef",value:function(e,t){return g.isAbsoluteUrl(t)?t:e&&g.isAbsoluteUrl(e)?m.resolve(e,t):h.resolve(e?h.dirname(e):process.cwd(),t)}},{key:"loadExternalRef",value:function(e){return f(this,void 0,void 0,o.mark((function t(){var n,r,i;return o.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(t.prev=0,!g.isAbsoluteUrl(e)){t.next=10;break}return t.next=4,b.readFileFromUrl(e,this.config.http);case 4:return n=t.sent,r=n.body,i=n.mimeType,t.abrupt("return",new x(e,r,i));case 10:return t.t0=x,t.t1=e,t.next=14,d.promises.readFile(e,"utf-8");case 14:return t.t2=t.sent,t.abrupt("return",new t.t0(t.t1,t.t2));case 16:t.next=21;break;case 18:throw t.prev=18,t.t3=t.catch(0),new w(t.t3);case 21:case"end":return t.stop()}}),t,this,[[0,18]])})))}},{key:"parseDocument",value:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=e.absoluteRef.substr(e.absoluteRef.lastIndexOf("."));if(![".json",".json",".yml",".yaml"].includes(r)&&!(null===(t=e.mimeType)||void 0===t?void 0:t.match(/(json|yaml|openapi)/))&&!n)return{source:e,parsed:e.body};try{return{source:e,parsed:v.safeLoad(e.body,{filename:e.absoluteRef})}}catch(t){throw new E(t,e)}}},{key:"resolveDocument",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return f(this,void 0,void 0,o.mark((function r(){var i,a,s,l=this;return o.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(i=this.resolveExternalRef(e,t),!(a=this.cache.get(i))){r.next=4;break}return r.abrupt("return",a);case 4:return s=this.loadExternalRef(i).then((function(e){return l.parseDocument(e,n)})),this.cache.set(i,s),r.abrupt("return",s);case 7:case"end":return r.stop()}}),r,this)})))}}]),e}();function _(e,t){return{prev:e,node:t}}function O(e,t){for(;e;){if(e.node===t)return!0;e=e.prev}return!1}t.BaseResolver=S;var A={name:"unknown",properties:{}},R={name:"scalar",properties:{}};t.resolveDocument=function(e){return f(this,void 0,void 0,o.mark((function t(){var n,i,a,s,l,c,u,p;return o.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:p=function(e,t,n,a){function u(e,t,n){return f(this,void 0,void 0,o.mark((function a(){var l,c,p,f,d,h,m,v,y,b,x,w,k;return o.wrap((function(o){for(;;)switch(o.prev=o.next){case 0:if(!O(n.prev,t)){o.next=2;break}throw new Error("Self-referencing circular pointer");case 2:if(l=g.parseRef(t.$ref),c=l.uri,p=l.pointer,f=null!==c,o.prev=4,!f){o.next=11;break}return o.next=8,i.resolveDocument(e.source.absoluteRef,c);case 8:o.t0=o.sent,o.next=12;break;case 11:o.t0=e;case 12:d=o.t0,o.next=21;break;case 15:return o.prev=15,o.t1=o.catch(4),h={resolved:!1,isRemote:f,document:void 0,error:o.t1},m=e.source.absoluteRef+"::"+t.$ref,s.set(m,h),o.abrupt("return",h);case 21:v={resolved:!0,document:d,isRemote:f,node:e.parsed,nodePointer:"#/"},y=d.parsed,b=r(p),o.prev=25,b.s();case 27:if((x=b.n()).done){o.next=55;break}if(w=x.value,"object"==typeof y){o.next=34;break}return y=void 0,o.abrupt("break",55);case 34:if(void 0===y[w]){o.next=39;break}y=y[w],v.nodePointer=g.joinPointer(v.nodePointer,g.escapePointer(w)),o.next=53;break;case 39:if(!g.isRef(y)){o.next=51;break}return o.next=42,u(d,y,_(n,y));case 42:if(v=o.sent,d=v.document||d,"object"==typeof v.node){o.next=47;break}return y=void 0,o.abrupt("break",55);case 47:y=v.node[w],v.nodePointer=g.joinPointer(v.nodePointer,g.escapePointer(w)),o.next=53;break;case 51:return y=void 0,o.abrupt("break",55);case 53:o.next=27;break;case 55:o.next=60;break;case 57:o.prev=57,o.t2=o.catch(25),b.e(o.t2);case 60:return o.prev=60,b.f(),o.finish(60);case 63:if(v.node=y,v.document=d,k=e.source.absoluteRef+"::"+t.$ref,!v.document||!g.isRef(y)){o.next=70;break}return o.next=69,u(v.document,y,_(n,y));case 69:v=o.sent;case 70:return s.set(k,v),o.abrupt("return",Object.assign({},v));case 72:case"end":return o.stop()}}),a,null,[[4,15],[25,57,60,63]])})))}!function e(n,r,o){if("object"==typeof n&&null!==n){var i="".concat(r.name,"::").concat(o);if(!l.has(i))if(l.add(i),Array.isArray(n)){var a=r.items;if(r!==A&&void 0===a)return;for(var s=0;s1&&void 0!==arguments[1]?arguments[1]:{},n={},o=0,i=Object.keys(e);o4&&void 0!==arguments[4]?arguments[4]:[];if(!s.includes(t)){s=[].concat(r(s),[t]);for(var l=new Set,c=0,u=Object.values(t.properties);c3&&void 0!==arguments[3]?arguments[3]:0,a=Object.keys(t);if(0===i)a.push("any"),a.push("ref");else{if(r.any)throw new Error("any() is allowed only on top level");if(r.ref)throw new Error("ref() is allowed only on top level")}for(var s=0,l=a;s1&&void 0!==arguments[1]?arguments[1]:C.source.absoluteRef;if(!i.isRef(e))return{location:m,node:e};var n=t+"::"+e.$ref,r=p.get(n);if(!r)return{location:void 0,node:void 0};var o=r.resolved,s=r.node,l=r.document,c=r.nodePointer,u=r.error,f=o?new i.Location(l.source,c):u instanceof a.YamlParseError?new i.Location(u.source,""):void 0;return{location:f,node:s,error:u}}function Ne(e,t,n){var r=n.location?Array.isArray(n.location)?n.location:[n.location]:[Object.assign(Object.assign({},C),{reportOnKey:!1})];f.problems.push(Object.assign(Object.assign({ruleId:e,severity:n.forceSeverity||t},n),{suggest:n.suggest||[],location:r.map((function(e){return Object.assign(Object.assign(Object.assign({},C),{reportOnKey:!1}),e)}))}))}}(t.parsed,n,new i.Location(t.source,"#/"),void 0,"")}},4756:function(e,t,n){"use strict";var r=n(9439);e.exports=r},9439:function(e,t,n){"use strict";var r=n(5143),o=n(9084);function i(e){return function(){throw new Error("Function "+e+" is deprecated and cannot be used.")}}e.exports.Type=n(889),e.exports.Schema=n(304),e.exports.FAILSAFE_SCHEMA=n(4801),e.exports.JSON_SCHEMA=n(2437),e.exports.CORE_SCHEMA=n(9533),e.exports.DEFAULT_SAFE_SCHEMA=n(7265),e.exports.DEFAULT_FULL_SCHEMA=n(1493),e.exports.load=r.load,e.exports.loadAll=r.loadAll,e.exports.safeLoad=r.safeLoad,e.exports.safeLoadAll=r.safeLoadAll,e.exports.dump=o.dump,e.exports.safeDump=o.safeDump,e.exports.YAMLException=n(2188),e.exports.MINIMAL_SCHEMA=n(4801),e.exports.SAFE_SCHEMA=n(7265),e.exports.DEFAULT_SCHEMA=n(1493),e.exports.scan=i("scan"),e.exports.parse=i("parse"),e.exports.compose=i("compose"),e.exports.addConstructor=i("addConstructor")},910:function(e,t,n){"use strict";function r(e){return null==e}n(7941),n(9653),n(2481),e.exports.isNothing=r,e.exports.isObject=function(e){return"object"==typeof e&&null!==e},e.exports.toArray=function(e){return Array.isArray(e)?e:r(e)?[]:[e]},e.exports.repeat=function(e,t){var n,r="";for(n=0;n>10),56320+(e-65536&1023))}for(var k=new Array(256),E=new Array(256),S=0;S<256;S++)k[S]=x(S)?1:0,E[S]=x(S);function _(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||s,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.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 O(e,t){return new o(t,new i(e.filename,e.input,e.position,e.line,e.position-e.lineStart))}function A(e,t){throw O(e,t)}function R(e,t){e.onWarning&&e.onWarning.call(null,O(e,t))}var C={YAML:function(e,t,n){var r,o,i;null!==e.version&&A(e,"duplication of %YAML directive"),1!==n.length&&A(e,"YAML directive accepts exactly one argument"),null===(r=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&A(e,"ill-formed argument of the YAML directive"),o=parseInt(r[1],10),i=parseInt(r[2],10),1!==o&&A(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=i<2,1!==i&&2!==i&&R(e,"unsupported YAML version of the document")},TAG:function(e,t,n){var r,o;2!==n.length&&A(e,"TAG directive accepts exactly two arguments"),r=n[0],o=n[1],f.test(r)||A(e,"ill-formed tag handle (first argument) of the TAG directive"),l.call(e.tagMap,r)&&A(e,'there is a previously declared suffix for "'+r+'" tag handle'),d.test(o)||A(e,"ill-formed tag prefix (second argument) of the TAG directive"),e.tagMap[r]=o}};function T(e,t,n,r){var o,i,a,s;if(t1&&(e.result+=r.repeat("\n",t-1))}function D(e,t){var n,r,o=e.tag,i=e.anchor,a=[],s=!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=a),r=e.input.charCodeAt(e.position);0!==r&&45===r&&g(e.input.charCodeAt(e.position+1));)if(s=!0,e.position++,L(e,!0,-1)&&e.lineIndent<=t)a.push(null),r=e.input.charCodeAt(e.position);else if(n=e.line,U(e,t,3,!1,!0),a.push(e.result),L(e,!0,-1),r=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&0!==r)A(e,"bad indentation of a sequence entry");else if(e.lineIndentt?x=1:e.lineIndent===t?x=0:e.lineIndentt?x=1:e.lineIndent===t?x=0:e.lineIndentt)&&(U(e,t,4,!0,o)&&(m?d=e.result:h=e.result),m||(I(e,u,p,f,d,h,i,a),f=d=h=null),L(e,!0,-1),s=e.input.charCodeAt(e.position)),e.lineIndent>t&&0!==s)A(e,"bad indentation of a mapping entry");else if(e.lineIndent=0))break;0===i?A(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):u?A(e,"repeat of an indentation width identifier"):(p=t+i-1,u=!0)}if(v(a)){do{a=e.input.charCodeAt(++e.position)}while(v(a));if(35===a)do{a=e.input.charCodeAt(++e.position)}while(!m(a)&&0!==a)}for(;0!==a;){for(j(e),e.lineIndent=0,a=e.input.charCodeAt(e.position);(!u||e.lineIndentp&&(p=e.lineIndent),m(a))f++;else{if(e.lineIndent0){for(o=a,i=0;o>0;o--)(a=b(s=e.input.charCodeAt(++e.position)))>=0?i=(i<<4)+a:A(e,"expected hexadecimal character");e.result+=w(i),e.position++}else A(e,"unknown escape sequence");n=r=e.position}else m(s)?(T(e,n,r,!0),M(e,L(e,!1,t)),n=r=e.position):e.position===e.lineStart&&N(e)?A(e,"unexpected end of the document within a double quoted scalar"):(e.position++,r=e.position)}A(e,"unexpected end of the stream within a double quoted scalar")}(e,d)?_=!0:function(e){var t,n,r;if(42!==(r=e.input.charCodeAt(e.position)))return!1;for(r=e.input.charCodeAt(++e.position),t=e.position;0!==r&&!g(r)&&!y(r);)r=e.input.charCodeAt(++e.position);return e.position===t&&A(e,"name of an alias node must contain at least one character"),n=e.input.slice(t,e.position),l.call(e.anchorMap,n)||A(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],L(e,!0,-1),!0}(e)?(_=!0,null===e.tag&&null===e.anchor||A(e,"alias node should not have any properties")):function(e,t,n){var r,o,i,a,s,l,c,u,p=e.kind,f=e.result;if(g(u=e.input.charCodeAt(e.position))||y(u)||35===u||38===u||42===u||33===u||124===u||62===u||39===u||34===u||37===u||64===u||96===u)return!1;if((63===u||45===u)&&(g(r=e.input.charCodeAt(e.position+1))||n&&y(r)))return!1;for(e.kind="scalar",e.result="",o=i=e.position,a=!1;0!==u;){if(58===u){if(g(r=e.input.charCodeAt(e.position+1))||n&&y(r))break}else if(35===u){if(g(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&N(e)||n&&y(u))break;if(m(u)){if(s=e.line,l=e.lineStart,c=e.lineIndent,L(e,!1,-1),e.lineIndent>=t){a=!0,u=e.input.charCodeAt(e.position);continue}e.position=i,e.line=s,e.lineStart=l,e.lineIndent=c;break}}a&&(T(e,o,i,!1),M(e,e.line-s),o=i=e.position,a=!1),v(u)||(i=e.position+1),u=e.input.charCodeAt(++e.position)}return T(e,o,i,!1),!!e.result||(e.kind=p,e.result=f,!1)}(e,d,1===n)&&(_=!0,null===e.tag&&(e.tag="?")),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===x&&(_=c&&D(e,h))),null!==e.tag&&"!"!==e.tag)if("?"===e.tag){for(null!==e.result&&"scalar"!==e.kind&&A(e,'unacceptable node kind for ! tag; it should be "scalar", not "'+e.kind+'"'),u=0,p=e.implicitTypes.length;u tag; it should be "'+f.kind+'", not "'+e.kind+'"'),f.resolve(e.result)?(e.result=f.construct(e.result),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):A(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")):A(e,"unknown tag !<"+e.tag+">");return null!==e.listener&&e.listener("close",e),null!==e.tag||null!==e.anchor||_}function B(e){var t,n,r,o,i=e.position,a=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap={},e.anchorMap={};0!==(o=e.input.charCodeAt(e.position))&&(L(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==o));){for(a=!0,o=e.input.charCodeAt(++e.position),t=e.position;0!==o&&!g(o);)o=e.input.charCodeAt(++e.position);for(r=[],(n=e.input.slice(t,e.position)).length<1&&A(e,"directive name must not be less than one character in length");0!==o;){for(;v(o);)o=e.input.charCodeAt(++e.position);if(35===o){do{o=e.input.charCodeAt(++e.position)}while(0!==o&&!m(o));break}if(m(o))break;for(t=e.position;0!==o&&!g(o);)o=e.input.charCodeAt(++e.position);r.push(e.input.slice(t,e.position))}0!==o&&j(e),l.call(C,n)?C[n](e,n,r):R(e,'unknown document directive "'+n+'"')}L(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,L(e,!0,-1)):a&&A(e,"directives end mark is expected"),U(e,e.lineIndent-1,4,!1,!0),L(e,!0,-1),e.checkLineBreaks&&u.test(e.input.slice(i,e.position))&&R(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&N(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,L(e,!0,-1)):e.position0&&-1==="\0\r\n…\u2028\u2029".indexOf(this.buffer.charAt(o-1));)if(o-=1,this.position-o>t/2-1){n=" ... ",o+=5;break}for(i="",a=this.position;at/2-1){i=" ... ",a-=5;break}return s=this.buffer.slice(o,a),r.repeat(" ",e)+n+s+i+"\n"+r.repeat(" ",e+this.position-o+n.length)+"^"},o.prototype.toString=function(e){var t,n="";return this.name&&(n+='in "'+this.name+'" '),n+="at line "+(this.line+1)+", column "+(this.column+1),e||(t=this.getSnippet())&&(n+=":\n"+t),n},e.exports=o},304:function(e,t,n){"use strict";n(4747),n(7327);var r=n(910),o=n(2188),i=n(889);function a(e,t,n){var r=[];return e.include.forEach((function(e){n=a(e,t,n)})),e[t].forEach((function(e){n.forEach((function(t,n){t.tag===e.tag&&t.kind===e.kind&&r.push(n)})),n.push(e)})),n.filter((function(e,t){return-1===r.indexOf(t)}))}function s(e){this.include=e.include||[],this.implicit=e.implicit||[],this.explicit=e.explicit||[],this.implicit.forEach((function(e){if(e.loadKind&&"scalar"!==e.loadKind)throw new o("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")})),this.compiledImplicit=a(this,"implicit",[]),this.compiledExplicit=a(this,"explicit",[]),this.compiledTypeMap=function(){var e,t,n={scalar:{},sequence:{},mapping:{},fallback:{}};function r(e){n[e.kind][e.tag]=n.fallback[e.tag]=e}for(e=0,t=arguments.length;e64)){if(t<0)return!1;r+=6}return r%8==0},construct:function(e){var t,n,o=e.replace(/[\r\n=]/g,""),a=o.length,s=i,l=0,c=[];for(t=0;t>16&255),c.push(l>>8&255),c.push(255&l)),l=l<<6|s.indexOf(o.charAt(t));return 0==(n=a%4*6)?(c.push(l>>16&255),c.push(l>>8&255),c.push(255&l)):18===n?(c.push(l>>10&255),c.push(l>>2&255)):12===n&&c.push(l>>4&255),r?r.from?r.from(c):new r(c):c},predicate:function(e){return r&&r.isBuffer(e)},represent:function(e){var t,n,r="",o=0,a=e.length,s=i;for(t=0;t>18&63],r+=s[o>>12&63],r+=s[o>>6&63],r+=s[63&o]),o=(o<<8)+e[t];return 0==(n=a%3)?(r+=s[o>>18&63],r+=s[o>>12&63],r+=s[o>>6&63],r+=s[63&o]):2===n?(r+=s[o>>10&63],r+=s[o>>4&63],r+=s[o<<2&63],r+=s[64]):1===n&&(r+=s[o>>2&63],r+=s[o<<4&63],r+=s[64],r+=s[64]),r}})},9753:function(e,t,n){"use strict";n(1539);var r=n(889);e.exports=new r("tag:yaml.org,2002:bool",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t=e.length;return 4===t&&("true"===e||"True"===e||"TRUE"===e)||5===t&&("false"===e||"False"===e||"FALSE"===e)},construct:function(e){return"true"===e||"True"===e||"TRUE"===e},predicate:function(e){return"[object Boolean]"===Object.prototype.toString.call(e)},represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"})},293:function(e,t,n){"use strict";n(4603),n(4916),n(9714),n(5306),n(7042),n(9653),n(4747),n(3123),n(1539);var r=n(910),o=n(889),i=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))$"),a=/^[-+]?[0-9]+e/;e.exports=new o("tag:yaml.org,2002:float",{kind:"scalar",resolve:function(e){return null!==e&&!(!i.test(e)||"_"===e[e.length-1])},construct:function(e){var t,n,r,o;return n="-"===(t=e.replace(/_/g,"").toLowerCase())[0]?-1:1,o=[],"+-".indexOf(t[0])>=0&&(t=t.slice(1)),".inf"===t?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===t?NaN:t.indexOf(":")>=0?(t.split(":").forEach((function(e){o.unshift(parseFloat(e,10))})),t=0,r=1,o.forEach((function(e){t+=e*r,r*=60})),n*t):n*parseFloat(t,10)},predicate:function(e){return"[object Number]"===Object.prototype.toString.call(e)&&(e%1!=0||r.isNegativeZero(e))},represent:function(e,t){var n;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(r.isNegativeZero(e))return"-0.0";return n=e.toString(10),a.test(n)?n.replace("e",".e"):n},defaultStyle:"lowercase"})},5733:function(e,t,n){"use strict";n(7042),n(4916),n(5306),n(4747),n(3123),n(1539),n(9714);var r=n(910),o=n(889);function i(e){return 48<=e&&e<=55}function a(e){return 48<=e&&e<=57}e.exports=new o("tag:yaml.org,2002:int",{kind:"scalar",resolve:function(e){if(null===e)return!1;var t,n,r=e.length,o=0,s=!1;if(!r)return!1;if("-"!==(t=e[o])&&"+"!==t||(t=e[++o]),"0"===t){if(o+1===r)return!0;if("b"===(t=e[++o])){for(o++;o=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"]}})},9798:function(e,t,n){"use strict";var r;n(4747),n(8309),n(7042),n(1539),n(9714);try{r=n(7707)}catch(e){"undefined"!=typeof window&&(r=window.esprima)}var o=n(889);e.exports=new o("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:function(e){if(null===e)return!1;try{var t="("+e+")",n=r.parse(t,{range:!0});return"Program"===n.type&&1===n.body.length&&"ExpressionStatement"===n.body[0].type&&("ArrowFunctionExpression"===n.body[0].expression.type||"FunctionExpression"===n.body[0].expression.type)}catch(e){return!1}},construct:function(e){var t,n="("+e+")",o=r.parse(n,{range:!0}),i=[];if("Program"!==o.type||1!==o.body.length||"ExpressionStatement"!==o.body[0].type||"ArrowFunctionExpression"!==o.body[0].expression.type&&"FunctionExpression"!==o.body[0].expression.type)throw new Error("Failed to resolve function");return o.body[0].expression.params.forEach((function(e){i.push(e.name)})),t=o.body[0].expression.body.range,"BlockStatement"===o.body[0].expression.body.type?new Function(i,n.slice(t[0]+1,t[1]-1)):new Function(i,"return "+n.slice(t[0],t[1]))},predicate:function(e){return"[object Function]"===Object.prototype.toString.call(e)},represent:function(e){return e.toString()}})},6446:function(e,t,n){"use strict";n(4916),n(7042),n(4603),n(9714),n(1539);var r=n(889);e.exports=new r("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:function(e){if(null===e)return!1;if(0===e.length)return!1;var t=e,n=/\/([gim]*)$/.exec(e),r="";if("/"===t[0]){if(n&&(r=n[1]),r.length>3)return!1;if("/"!==t[t.length-r.length-1])return!1}return!0},construct:function(e){var t=e,n=/\/([gim]*)$/.exec(e),r="";return"/"===t[0]&&(n&&(r=n[1]),t=t.slice(1,t.length-r.length-1)),new RegExp(t,r)},predicate:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},represent:function(e){var t="/"+e.source+"/";return e.global&&(t+="g"),e.multiline&&(t+="m"),e.ignoreCase&&(t+="i"),t}})},1467:function(e,t,n){"use strict";var r=n(889);e.exports=new r("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:function(){return!0},construct:function(){},predicate:function(e){return void 0===e},represent:function(){return""}})},127:function(e,t,n){"use strict";var r=n(889);e.exports=new r("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return null!==e?e:{}}})},321:function(e,t,n){"use strict";var r=n(889);e.exports=new r("tag:yaml.org,2002:merge",{kind:"scalar",resolve:function(e){return"<<"===e||null===e}})},1608:function(e,t,n){"use strict";var r=n(889);e.exports=new r("tag:yaml.org,2002:null",{kind:"scalar",resolve:function(e){if(null===e)return!0;var t=e.length;return 1===t&&"~"===e||4===t&&("null"===e||"Null"===e||"NULL"===e)},construct:function(){return null},predicate:function(e){return null===e},represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})},8372:function(e,t,n){"use strict";n(1539);var r=n(889),o=Object.prototype.hasOwnProperty,i=Object.prototype.toString;e.exports=new r("tag:yaml.org,2002:omap",{kind:"sequence",resolve:function(e){if(null===e)return!0;var t,n,r,a,s,l=[],c=e;for(t=0,n=c.length;t1&&console.warn("Replacing with",p),d++}}else{var v=f(u(t,e[n]));if(i.verbose>1&&console.warn((!1===v?m.colour.red:m.colour.green)+"Fragment resolution",e[n],m.colour.normal),!1===v){if(r.parent[r.pkey]={},i.fatal){var g=new Error("Fragment $ref resolution failed "+e[n]);if(!i.promise)throw g;i.promise.reject(g)}}else d++,r.parent[r.pkey]=v,c[e[n]]=r.path.replace("/%24ref","")}else if(l.protocol){var y=s.resolve(o,e[n]).toString();i.verbose>1&&console.warn(m.colour.yellow+"Rewriting external url ref",e[n],"as",y,m.colour.normal),e["x-miro"]=e[n],i.externalRefs[e[n]]&&(i.externalRefs[y]||(i.externalRefs[y]=i.externalRefs[e[n]]),i.externalRefs[y].failed=i.externalRefs[e[n]].failed),e[n]=y}else if(!e["x-miro"]){var b=s.resolve(o,e[n]).toString(),x=!1;i.externalRefs[e[n]]&&(x=i.externalRefs[e[n]].failed),x||(i.verbose>1&&console.warn(m.colour.yellow+"Rewriting external ref",e[n],"as",b,m.colour.normal),e["x-miro"]=e[n],e[n]=b)}}));return p(e,{},(function(e,t,n){h(e,t)&&void 0!==e.$fixed&&delete e.$fixed})),i.verbose>1&&console.warn("Finished fragment resolution"),e}function g(e,t){if(!t.filters||!t.filters.length)return e;var n,o=r(t.filters);try{for(o.s();!(n=o.n()).done;)e=(0,n.value)(e,t)}catch(e){o.e(e)}finally{o.f()}return e}function y(e){return new Promise((function(t,n){(function(e){return new Promise((function(t,n){function r(t,n,r){if(t[n]&&h(t[n],"$ref")){var i=t[n].$ref;if(!i.startsWith("#")){var a="";if(!o[i]){var s=Object.keys(o).find((function(e,t,n){return i.startsWith(e+"/")}));s&&(e.verbose&&console.warn("Found potential subschema at",s),a=(a="/"+(i.split("#")[1]||"").replace(s.split("#")[1]||"")).split("/undefined").join(""),i=s)}if(o[i]||(o[i]={resolved:!1,paths:[],extras:{},description:t[n].description}),o[i].resolved)if(o[i].failed);else if(e.rewriteRefs){var l=o[i].resolvedAt;e.verbose>1&&console.warn("Rewriting ref",i,l),t[n]["x-miro"]=i,t[n].$ref=l+a}else t[n]=f(o[i].data);else o[i].paths.push(r.path),o[i].extras[r.path]=a}}}var o=e.externalRefs;if(e.resolver.depth>0&&e.source===e.resolver.base)return t(o);p(e.openapi.definitions,{identityDetection:!0,path:"#/definitions"},r),p(e.openapi.components,{identityDetection:!0,path:"#/components"},r),p(e.openapi,{identityDetection:!0},r),t(o)}))})(e).then((function(t){var n=function(n){if(!t[n].resolved){var l=e.resolver.depth;l>0&&l++,e.resolver.actions[l].push((function(){return function(e,t,n,r){var o=s.parse(n.source),l=n.source.split("\\").join("/").split("/");l.pop()||l.pop();var p="",d=t.split("#");d.length>1&&(p="#"+d[1],t=d[0]),l=l.join("/");var h,m,y,b=(h=s.parse(t).protocol,m=o.protocol,h&&h.length>2?h:m&&m.length>2?m:"file:");if(y="file:"===b?a.resolve(l?l+"/":"",t):s.resolve(l?l+"/":"",t),n.cache[y]){n.verbose&&console.warn("CACHED",y,p);var x=f(n.cache[y]),w=n.externalRef=x;if(p&&!1===(w=u(w,p))&&(w={},n.fatal)){var k=new Error("Cached $ref resolution failed "+y+p);if(!n.promise)throw k;n.promise.reject(k)}return w=g(w=v(w,x,t,p,y,n),n),r(f(w),y,n),Promise.resolve(w)}if(n.verbose&&console.warn("GET",y,p),n.handlers&&n.handlers[b])return n.handlers[b](l,t,p,n).then((function(e){return n.externalRef=e,e=g(e,n),n.cache[y]=e,r(e,y,n),e})).catch((function(e){throw n.verbose&&console.warn(e),e}));if(b&&b.startsWith("http")){var E=Object.assign({},n.fetchOptions,{agent:n.agent});return n.fetch(y,E).then((function(e){if(200!==e.status){if(n.ignoreIOErrors)return n.verbose&&console.warn("FAILED",t),n.externalRefs[t].failed=!0,'{"$ref":"'+t+'"}';throw new Error("Received status code ".concat(e.status,": ").concat(y))}return e.text()})).then((function(e){try{var o=c.parse(e,{schema:"core",prettyErrors:!0});if(e=n.externalRef=o,n.cache[y]=f(e),p&&!1===(e=u(e,p))&&(e={},n.fatal)){var i=new Error("Remote $ref resolution failed "+y+p);if(!n.promise)throw i;n.promise.reject(i)}e=g(e=v(e,o,t,p,y,n),n)}catch(e){if(n.verbose&&console.warn(e),!n.promise||!n.fatal)throw e;n.promise.reject(e)}return r(e,y,n),e})).catch((function(e){if(n.verbose&&console.warn(e),n.cache[y]={},!n.promise||!n.fatal)throw e;n.promise.reject(e)}))}var S='{"$ref":"'+t+'"}';return function(e,t,n,r,o){return new Promise((function(a,s){i.readFile(e,t,(function(e,t){e?n.ignoreIOErrors&&o?(n.verbose&&console.warn("FAILED",r),n.externalRefs[r].failed=!0,a(o)):s(e):a(t)}))}))}(y,n.encoding||"utf8",n,t,S).then((function(e){try{var o=c.parse(e,{schema:"core",prettyErrors:!0});if(e=n.externalRef=o,n.cache[y]=f(e),p&&!1===(e=u(e,p))&&(e={},n.fatal)){var i=new Error("File $ref resolution failed "+y+p);if(!n.promise)throw i;n.promise.reject(i)}e=g(e=v(e,o,t,p,y,n),n)}catch(e){if(n.verbose&&console.warn(e),!n.promise||!n.fatal)throw e;n.promise.reject(e)}return r(e,y,n),e})).catch((function(e){if(n.verbose&&console.warn(e),!n.promise||!n.fatal)throw e;n.promise.reject(e)}))}(e.openapi,n,e,(function(e,i,a){if(!t[n].resolved){var s={};s.context=t[n],s.$ref=n,s.original=f(e),s.updated=e,s.source=i,a.externals.push(s),t[n].resolved=!0}var l=Object.assign({},a,{source:"",resolver:{actions:a.resolver.actions,depth:a.resolver.actions.length-1,base:a.resolver.base}});a.patch&&t[n].description&&!e.description&&"object"==typeof e&&(e.description=t[n].description),t[n].data=e;var c,p=(c=t[n].paths,o(new Set(c)));p=p.sort((function(e,t){var n=e.startsWith("#/components/")||e.startsWith("#/definitions/"),r=t.startsWith("#/components/")||t.startsWith("#/definitions/");return n&&!r?-1:r&&!n?1:0}));var d,h=r(p);try{for(h.s();!(d=h.n()).done;){var m=d.value;if(t[n].resolvedAt&&m!==t[n].resolvedAt&&m.indexOf("x-ms-examples/")<0)a.verbose>1&&console.warn("Creating pointer to data at",m),u(a.openapi,m,{$ref:t[n].resolvedAt+t[n].extras[m],"x-miro":n+t[n].extras[m]});else{t[n].resolvedAt?a.verbose>1&&console.warn("Avoiding circular reference"):(t[n].resolvedAt=m,a.verbose>1&&console.warn("Creating initial clone of data at",m));var v=f(e);u(a.openapi,m,v)}}}catch(e){h.e(e)}finally{h.f()}0===a.resolver.actions[l.resolver.depth].length&&a.resolver.actions[l.resolver.depth].push((function(){return y(l)}))}))}))}};for(var l in t)n(l)})).catch((function(t){e.verbose&&console.warn(t),n(t)}));var l={options:e};l.actions=e.resolver.actions[e.resolver.depth],t(l)}))}function b(e,t,n){e.resolver.actions.push([]),y(e).then((function(r){var o;(o=r.actions,o.reduce((function(e,t){return e.then((function(e){return t().then(Array.prototype.concat.bind(e))}))}),Promise.resolve([]))).then((function(){if(e.resolver.depth>=e.resolver.actions.length)return console.warn("Ran off the end of resolver actions"),t(!0);e.resolver.depth++,e.resolver.actions[e.resolver.depth].length?setTimeout((function(){b(r.options,t,n)}),0):(e.verbose>1&&console.warn(m.colour.yellow+"Finished external resolution!",m.colour.normal),e.resolveInternal&&(e.verbose>1&&console.warn(m.colour.yellow+"Starting internal resolution!",m.colour.normal),e.openapi=d(e.openapi,e.original,{verbose:e.verbose-1}),e.verbose>1&&console.warn(m.colour.yellow+"Finished internal resolution!",m.colour.normal)),p(e.openapi,{},(function(t,n,r){h(t,n)&&(e.preserveMiro||delete t["x-miro"])})),t(e))})).catch((function(t){e.verbose&&console.warn(t),n(t)}))})).catch((function(t){e.verbose&&console.warn(t),n(t)}))}function x(e){if(e.cache||(e.cache={}),e.fetch||(e.fetch=l),e.source){var t=s.parse(e.source);(!t.protocol||t.protocol.length<=2)&&(e.source=a.resolve(e.source))}e.externals=[],e.externalRefs={},e.rewriteRefs=!0,e.resolver={},e.resolver.depth=0,e.resolver.base=e.source,e.resolver.actions=[[]]}e.exports={optionalResolve:function(e){return x(e),new Promise((function(t,n){e.resolve?b(e,t,n):t(e)}))},resolve:function(e,t,n){return n||(n={}),n.openapi=e,n.source=t,n.resolve=!0,x(n),new Promise((function(e,t){b(n,e,t)}))}}},6704:function(e,t,n){"use strict";function r(){return{depth:0,seen:new WeakMap,top:!0,combine:!1,allowRefSiblings:!1}}n(6992),n(1539),n(8783),n(4129),n(3948),n(2526),n(1817),n(9601),e.exports={getDefaultState:r,walkSchema:function e(t,n,o,i){if(void 0===o.depth&&(o=r()),null==t)return t;if(void 0!==t.$ref){var a={$ref:t.$ref};return o.allowRefSiblings&&t.description&&(a.description=t.description),i(a,n,o),a}if(o.combine&&(t.allOf&&Array.isArray(t.allOf)&&1===t.allOf.length&&delete(t=Object.assign({},t.allOf[0],t)).allOf,t.anyOf&&Array.isArray(t.anyOf)&&1===t.anyOf.length&&delete(t=Object.assign({},t.anyOf[0],t)).anyOf,t.oneOf&&Array.isArray(t.oneOf)&&1===t.oneOf.length&&delete(t=Object.assign({},t.oneOf[0],t)).oneOf),i(t,n,o),o.seen.has(t))return t;if("object"==typeof t&&null!==t&&o.seen.set(t,!0),o.top=!1,o.depth++,void 0!==t.items&&(o.property="items",e(t.items,t,o,i)),t.additionalItems&&"object"==typeof t.additionalItems&&(o.property="additionalItems",e(t.additionalItems,t,o,i)),t.additionalProperties&&"object"==typeof t.additionalProperties&&(o.property="additionalProperties",e(t.additionalProperties,t,o,i)),t.properties)for(var s in t.properties){var l=t.properties[s];o.property="properties/"+s,e(l,t,o,i)}if(t.patternProperties)for(var c in t.patternProperties){var u=t.patternProperties[c];o.property="patternProperties/"+c,e(u,t,o,i)}if(t.allOf)for(var p in t.allOf){var f=t.allOf[p];o.property="allOf/"+p,e(f,t,o,i)}if(t.anyOf)for(var d in t.anyOf){var h=t.anyOf[d];o.property="anyOf/"+d,e(h,t,o,i)}if(t.oneOf)for(var m in t.oneOf){var v=t.oneOf[m];o.property="oneOf/"+m,e(v,t,o,i)}return t.not&&(o.property="not",e(t.not,t,o,i)),o.depth--,t}}},4188:function(e,t,n){"use strict";var r=n(9713).default,o=n(319).default;n(9601),n(6992),n(1539),n(8783),n(4129),n(3948),n(489),n(2222),n(1249),n(7941),e.exports={nop:function(e){return e},clone:function(e){return JSON.parse(JSON.stringify(e))},shallowClone:function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t},deepClone:function e(t){var n=Array.isArray(t)?[]:{};for(var r in t)(t.hasOwnProperty(r)||Array.isArray(t))&&(n[r]="object"==typeof t[r]?e(t[r]):t[r]);return n},fastClone:function(e){return Object.assign({},e)},circularClone:function e(t,n){if(n||(n=new WeakMap),Object(t)!==t||t instanceof Function)return t;if(n.has(t))return n.get(t);try{var i=new t.constructor}catch(e){i=Object.create(Object.getPrototypeOf(t))}return n.set(t,i),Object.assign.apply(Object,[i].concat(o(Object.keys(t).map((function(o){return r({},o,e(t[o],n))})))))}}},3094:function(e,t,n){"use strict";n(7042),n(4916),n(3123);var r=n(9290).recurse,o=n(4188).shallowClone,i=n(2580).jptr,a=n(3856).isRef;e.exports={dereference:function e(t,n,s){s||(s={}),s.cache||(s.cache={}),s.state||(s.state={}),s.state.identityDetection=!0,s.depth=s.depth?s.depth+1:1;var l=s.depth>1?t:o(t),c={data:l},u=s.depth>1?n:o(n);s.master||(s.master=l);for(var p=function(e){return e&&e.verbose?{warn:function(){var e=Array.prototype.slice.call(arguments);console.warn.apply(console,e)}}:{warn:function(){}}}(s),f=1;f>0;)f=0,r(c,s.state,(function(t,n,r){if(a(t,n)){var o=t[n];if(f++,s.cache[o]){var l=s.cache[o];if(l.resolved)p.warn("Patching %s for %s",o,l.path),r.parent[r.pkey]=l.data,s.$ref&&"object"==typeof r.parent[r.pkey]&&(r.parent[r.pkey][s.$ref]=o);else{if(o===l.path)throw new Error("Tight circle at ".concat(l.path));p.warn("Unresolved ref"),r.parent[r.pkey]=i(l.source,l.path),!1===r.parent[r.pkey]&&(r.parent[r.pkey]=i(l.source,l.key)),s.$ref&&"object"==typeof r.parent[r.pkey]&&(r.parent[s.$ref]=o)}}else{var c={};c.path=r.path.split("/$ref")[0],c.key=o,p.warn("Dereffing %s at %s",o,c.path),c.source=u,c.data=i(c.source,c.key),!1===c.data&&(c.data=i(s.master,c.key),c.source=s.master),!1===c.data&&p.warn("Missing $ref target",c.key),s.cache[o]=c,c.data=r.parent[r.pkey]=e(i(c.source,c.key),c.source,s),s.$ref&&"object"==typeof r.parent[r.pkey]&&(r.parent[r.pkey][s.$ref]=o),c.resolved=!0}}}));return c.data}}},3856:function(e){"use strict";e.exports={isRef:function(e,t){return"$ref"===t&&!!e&&"string"==typeof e[t]}}},2580:function(e,t,n){"use strict";function r(e){return e.replace(/\~1/g,"/").replace(/~0/g,"~")}n(4916),n(5306),n(3123),n(9600),n(7042),n(6755),n(1539),n(9714),e.exports={jptr:function(e,t,n){if(void 0===e)return!1;if(!t||"string"!=typeof t||"#"===t)return void 0!==n?n:e;if(t.indexOf("#")>=0){var o=t.split("#");if(o[0])return!1;t=o[1],t=decodeURIComponent(t.slice(1).split("+").join(" "))}t.startsWith("/")&&(t=t.slice(1));for(var i=t.split("/"),a=0;a0?i[a-1]:"",-1!=l||e&&e.hasOwnProperty(i[a]))if(l>=0)s&&(e[l]=n),e=e[l];else{if(-2===l)return s?(Array.isArray(e)&&e.push(n),n):void 0;s&&(e[i[a]]=n),e=e[i[a]]}else{if(void 0===n||"object"!=typeof e||Array.isArray(e))return!1;e[i[a]]=s?n:"0"===i[a+1]||"-"===i[a+1]?[]:{},e=e[i[a]]}}return e},jpescape:function(e){return e.replace(/\~/g,"~0").replace(/\//g,"~1")},jpunescape:r}},9290:function(e,t,n){"use strict";n(6992),n(1539),n(8783),n(4129),n(3948),n(9601);var r=n(2580).jpescape;e.exports={recurse:function e(t,n,o){if(n||(n={depth:0}),n.depth||(n=Object.assign({},{path:"#",depth:0,pkey:"",parent:{},payload:{},seen:new WeakMap,identity:!1,identityDetection:!1},n)),"object"==typeof t){var i=n.path;for(var a in t){if(n.key=a,n.path=n.path+"/"+encodeURIComponent(r(a)),n.identityPath=n.seen.get(t[a]),n.identity=void 0!==n.identityPath,t.hasOwnProperty(a)&&o(t,a,n),"object"==typeof t[a]&&!n.identity){n.identityDetection&&!Array.isArray(t[a])&&null!==t[a]&&n.seen.set(t[a],n.path);var s={};s.parent=t,s.path=n.path,s.depth=n.depth?n.depth+1:1,s.pkey=a,s.payload=n.payload,s.seen=n.seen,s.identity=!1,s.identityDetection=n.identityDetection,e(t[a],s,o)}n.path=i}}}}},6399:function(e,t,n){"use strict";var r=n(3269).default,o=n(4575).default,i=n(2205).default,a=n(9842).default,s=n(5957).default;n(8309),n(7941),n(2222),n(6755),n(4916),n(5306),n(3123),n(9600),n(3210),n(7327),n(2526),n(1817),n(9601),n(9826),n(1539),n(9714),n(6992),n(8783),n(3948),n(285),n(8478),n(8674),n(4723),n(4747);var l,c=n(1683),u=n(8575),p=(n(6470),n(4480)),f=n(7707),d=n(7707),h=n(2580),m=h.jptr,v=n(3856).isRef,g=n(4188).clone,y=n(4188).circularClone,b=n(9290).recurse,x=n(1338),w=n(6704),k=n(8276),E=n(873).statusCodes,S=n(8500).i8,_="3.0.0",O=function(e){i(n,e);var t=a(n);function n(e){var r;return o(this,n),(r=t.call(this,e)).name="S2OError",r}return n}(s(Error));function A(e,t){var n=new O(e);if(n.options=t,!t.promise)throw n;t.promise.reject(n)}function R(e,t,n){n.warnOnly?t[n.warnProperty||"x-s2o-warning"]=e:A(e,n)}function C(e,t){w.walkSchema(e,{},{},(function(e,n,o){!function(e,t){if(e["x-required"]&&Array.isArray(e["x-required"])&&(e.required||(e.required=[]),e.required=e.required.concat(e["x-required"]),delete e["x-required"]),e["x-anyOf"]&&(e.anyOf=e["x-anyOf"],delete e["x-anyOf"]),e["x-oneOf"]&&(e.oneOf=e["x-oneOf"],delete e["x-oneOf"]),e["x-not"]&&(e.not=e["x-not"],delete e["x-not"]),"boolean"==typeof e["x-nullable"]&&(e.nullable=e["x-nullable"],delete e["x-nullable"]),"object"==typeof e["x-discriminator"]&&"string"==typeof e["x-discriminator"].propertyName)for(var n in e.discriminator=e["x-discriminator"],delete e["x-discriminator"],e.discriminator.mapping){var r=e.discriminator.mapping[n];r.startsWith("#/definitions/")&&(e.discriminator.mapping[n]=r.replace("#/definitions/","#/components/schemas/"))}}(e),function(e,t,n){if(e.nullable&&n.patches++,e.discriminator&&"string"==typeof e.discriminator&&(e.discriminator={propertyName:e.discriminator}),e.items&&Array.isArray(e.items)&&(0===e.items.length?e.items={}:1===e.items.length?e.items=e.items[0]:e.items={anyOf:e.items}),e.type&&Array.isArray(e.type))if(n.patch){if(n.patches++,0===e.type.length)delete e.type;else{e.oneOf||(e.oneOf=[]);var o,i=r(e.type);try{for(i.s();!(o=i.n()).done;){var a=o.value,s={};if("null"===a)e.nullable=!0;else{s.type=a;var l,c=r(k.arrayProperties);try{for(c.s();!(l=c.n()).done;){var u=l.value;void 0!==e.prop&&(s[u]=e[u],delete e[u])}}catch(e){c.e(e)}finally{c.f()}}s.type&&e.oneOf.push(s)}}catch(e){i.e(e)}finally{i.f()}delete e.type,0===e.oneOf.length?delete e.oneOf:e.oneOf.length<2&&(e.type=e.oneOf[0].type,Object.keys(e.oneOf[0]).length>1&&R("Lost properties from oneOf",e,n),delete e.oneOf)}e.type&&Array.isArray(e.type)&&1===e.type.length&&(e.type=e.type[0])}else A("(Patchable) schema type must not be an array",n);e.type&&"null"===e.type&&(delete e.type,e.nullable=!0),"array"!==e.type||e.items||(e.items={}),"file"===e.type&&(e.type="string",e.format="binary"),"boolean"==typeof e.required&&(e.required&&e.name&&(void 0===t.required&&(t.required=[]),Array.isArray(t.required)&&t.required.push(e.name)),delete e.required),e.xml&&"string"==typeof e.xml.namespace&&(e.xml.namespace||delete e.xml.namespace),void 0!==e.allowEmptyValue&&(n.patches++,delete e.allowEmptyValue)}(e,n,t)}))}function T(e,t,n){var r=n.payload.options;if(v(e,t)){if(e[t].startsWith("#/components/"));else if("#/consumes"===e[t])delete e[t],n.parent[n.pkey]=g(r.openapi.consumes);else if("#/produces"===e[t])delete e[t],n.parent[n.pkey]=g(r.openapi.produces);else if(e[t].startsWith("#/definitions/")){var o=e[t].replace("#/definitions/","").split("/"),i=h.jpunescape(o[0]),a=l.schemas[decodeURIComponent(i)];a?o[0]=a:R("Could not resolve reference "+e[t],e,r),e[t]="#/components/schemas/"+o.join("/")}else if(e[t].startsWith("#/parameters/"))e[t]="#/components/parameters/"+k.sanitise(e[t].replace("#/parameters/",""));else if(e[t].startsWith("#/responses/"))e[t]="#/components/responses/"+k.sanitise(e[t].replace("#/responses/",""));else if(e[t].startsWith("#")){var s=g(h.jptr(r.openapi,e[t]));if(!1===s)R("direct $ref not found "+e[t],e,r);else if(r.refmap[e[t]])e[t]=r.refmap[e[t]];else{var c=e[t],u="schemas",p=(c=(c=(c=(c=c.replace("/properties/headers/","")).replace("/properties/responses/","")).replace("/properties/parameters/","")).replace("/properties/schemas/","")).lastIndexOf("/schema");if("schemas"==(u=c.indexOf("/headers/")>p?"headers":c.indexOf("/responses/")>p?"responses":c.indexOf("/example")>p?"examples":c.indexOf("/x-")>p?"extensions":c.indexOf("/parameters/")>p?"parameters":"schemas")&&C(s,r),"responses"!==u&&"extensions"!==u){var f=u.substr(0,u.length-1);"parameter"===f&&s.name&&s.name===k.sanitise(s.name)&&(f=encodeURIComponent(s.name));var d=1;for(e["x-miro"]&&(f=function(e){return e=e.indexOf("#")>=0?e.split("#")[1].split("/").pop():e.split("/").pop().split(".")[0],encodeURIComponent(k.sanitise(e))}(e["x-miro"]),d="");h.jptr(r.openapi,"#/components/"+u+"/"+f+d);)d=""===d?2:++d;var m="#/components/"+u+"/"+f+d,y="";"examples"===u&&(s={value:s},y="/value"),h.jptr(r.openapi,m,s),r.refmap[e[t]]=m+y,e[t]=m+y}}}if(delete e["x-miro"],Object.keys(e).length>1){var b=e[t],x=n.path.indexOf("/schema")>=0;"preserve"===r.refSiblings||(x&&"allOf"===r.refSiblings?(delete e.$ref,n.parent[n.pkey]={allOf:[{$ref:b},e]}):n.parent[n.pkey]={$ref:b})}}if("x-ms-odata"===t&&"string"==typeof e[t]&&e[t].startsWith("#/")){var w=e[t].replace("#/definitions/","").replace("#/components/schemas/","").split("/"),E=l.schemas[decodeURIComponent(w[0])];E?w[0]=E:R("Could not resolve reference "+e[t],e,r),e[t]="#/components/schemas/"+w.join("/")}}function P(e){for(var t in e)for(var n in e[t]){var r=k.sanitise(n);n!==r&&(e[t][r]=e[t][n],delete e[t][n])}}function I(e,t){if("basic"===e.type&&(e.type="http",e.scheme="basic"),"oauth2"===e.type){var n={},r=e.flow;"application"===e.flow&&(r="clientCredentials"),"accessCode"===e.flow&&(r="authorizationCode"),void 0!==e.authorizationUrl&&(n.authorizationUrl=e.authorizationUrl.split("?")[0].trim()||"/"),"string"==typeof e.tokenUrl&&(n.tokenUrl=e.tokenUrl.split("?")[0].trim()||"/"),n.scopes=e.scopes||{},e.flows={},e.flows[r]=n,delete e.flow,delete e.authorizationUrl,delete e.tokenUrl,delete e.scopes,void 0!==e.name&&(t.patch?(t.patches++,delete e.name):A("(Patchable) oauth2 securitySchemes should not have name property",t))}}function j(e){return e&&!e["x-s2o-delete"]}function L(e,t){if(e.$ref)e.$ref=e.$ref.replace("#/responses/","#/components/responses/");else{e.type&&!e.schema&&(e.schema={}),e.type&&(e.schema.type=e.type),e.items&&"array"!==e.items.type&&(e.items.collectionFormat!==e.collectionFormat&&R("Nested collectionFormats are not supported",e,t),delete e.items.collectionFormat),"array"===e.type?("ssv"===e.collectionFormat?R("collectionFormat:ssv is no longer supported for headers",e,t):"pipes"===e.collectionFormat?R("collectionFormat:pipes is no longer supported for headers",e,t):"multi"===e.collectionFormat?e.explode=!0:"tsv"===e.collectionFormat?(R("collectionFormat:tsv is no longer supported",e,t),e["x-collectionFormat"]="tsv"):e.style="simple",delete e.collectionFormat):e.collectionFormat&&(t.patch?(t.patches++,delete e.collectionFormat):A("(Patchable) collectionFormat is only applicable to header.type array",t)),delete e.type;var n,o=r(k.parameterTypeProperties);try{for(o.s();!(n=o.n()).done;){var i=n.value;void 0!==e[i]&&(e.schema[i]=e[i],delete e[i])}}catch(e){o.e(e)}finally{o.f()}var a,s=r(k.arrayProperties);try{for(s.s();!(a=s.n()).done;){var l=a.value;void 0!==e[l]&&(e.schema[l]=e[l],delete e[l])}}catch(e){s.e(e)}finally{s.f()}}}function N(e,t){if(e.$ref.indexOf("#/parameters/")>=0){var n=e.$ref.split("#/parameters/");e.$ref=n[0]+"#/components/parameters/"+k.sanitise(n[1])}e.$ref.indexOf("#/definitions/")>=0&&R("Definition used as parameter",e,t)}function M(e,t,n,o,i,a,s){var l,c={},u=!0;if(t&&t.consumes&&"string"==typeof t.consumes){if(!s.patch)return A("(Patchable) operation.consumes must be an array",s);s.patches++,t.consumes=[t.consumes]}Array.isArray(a.consumes)||delete a.consumes;var p=((t?t.consumes:null)||a.consumes||[]).filter(k.uniqueOnly);if(e&&e.$ref&&"string"==typeof e.$ref){N(e,s);var f=decodeURIComponent(e.$ref.replace("#/components/parameters/","")),d=!1,h=a.components.parameters[f];if(h&&!h["x-s2o-delete"]||!e.$ref.startsWith("#/")||(e["x-s2o-delete"]=!0,d=!0),d){var v=e.$ref,y=m(a,e.$ref);!y&&v.startsWith("#/")?R("Could not resolve reference "+v,e,s):y&&(e=y)}}if(e&&(e.name||e.in)){"boolean"==typeof e["x-deprecated"]&&(e.deprecated=e["x-deprecated"],delete e["x-deprecated"]),void 0!==e["x-example"]&&(e.example=e["x-example"],delete e["x-example"]),"body"===e.in||e.type||(s.patch?(s.patches++,e.type="string"):A("(Patchable) parameter.type is mandatory for non-body parameters",s)),e.type&&"object"==typeof e.type&&e.type.$ref&&(e.type=m(a,e.type.$ref)),"file"===e.type&&(e["x-s2o-originalType"]=e.type,l=e.type),e.description&&"object"==typeof e.description&&e.description.$ref&&(e.description=m(a,e.description.$ref)),null===e.description&&delete e.description;var x=e.collectionFormat;if("array"!==e.type||x||(x="csv"),x&&("array"!==e.type&&(s.patch?(s.patches++,delete e.collectionFormat):A("(Patchable) collectionFormat is only applicable to param.type array",s)),"csv"!==x||"query"!==e.in&&"cookie"!==e.in||(e.style="form",e.explode=!1),"csv"!==x||"path"!==e.in&&"header"!==e.in||(e.style="simple"),"ssv"===x&&("query"===e.in?e.style="spaceDelimited":R("collectionFormat:ssv is no longer supported except for in:query parameters",e,s)),"pipes"===x&&("query"===e.in?e.style="pipeDelimited":R("collectionFormat:pipes is no longer supported except for in:query parameters",e,s)),"multi"===x&&(e.explode=!0),"tsv"===x&&(R("collectionFormat:tsv is no longer supported",e,s),e["x-collectionFormat"]="tsv"),delete e.collectionFormat),e.type&&"body"!==e.type&&"formData"!==e.in)if(e.items&&e.schema)R("parameter has array,items and schema",e,s);else{e.schema&&s.patches++,e.schema&&"object"==typeof e.schema||(e.schema={}),e.schema.type=e.type,e.items&&(e.schema.items=e.items,delete e.items,b(e.schema.items,null,(function(t,n,r){"collectionFormat"===n&&"string"==typeof t[n]&&(x&&t[n]!==x&&R("Nested collectionFormats are not supported",e,s),delete t[n])})));var w,E=r(k.parameterTypeProperties);try{for(E.s();!(w=E.n()).done;){var S=w.value;void 0!==e[S]&&(e.schema[S]=e[S]),delete e[S]}}catch(e){E.e(e)}finally{E.f()}}e.schema&&C(e.schema,s),e["x-ms-skip-url-encoding"]&&"query"===e.in&&(e.allowReserved=!0,delete e["x-ms-skip-url-encoding"])}if(e&&"formData"===e.in){u=!1,c.content={};var _="application/x-www-form-urlencoded";if(p.length&&p.indexOf("multipart/form-data")>=0&&(_="multipart/form-data"),c.content[_]={},e.schema)c.content[_].schema=e.schema,e.schema.$ref&&(c["x-s2o-name"]=decodeURIComponent(e.schema.$ref.replace("#/components/schemas/","")));else{c.content[_].schema={},c.content[_].schema.type="object",c.content[_].schema.properties={},c.content[_].schema.properties[e.name]={};var O=c.content[_].schema,T=c.content[_].schema.properties[e.name];e.description&&(T.description=e.description),e.example&&(T.example=e.example),e.type&&(T.type=e.type);var P,I=r(k.parameterTypeProperties);try{for(I.s();!(P=I.n()).done;){var j=P.value;void 0!==e[j]&&(T[j]=e[j])}}catch(e){I.e(e)}finally{I.f()}!0===e.required&&(O.required||(O.required=[]),O.required.push(e.name),c.required=!0),void 0!==e.default&&(T.default=e.default),T.properties&&(T.properties=e.properties),e.allOf&&(T.allOf=e.allOf),"array"===e.type&&e.items&&(T.items=e.items,T.items.collectionFormat&&delete T.items.collectionFormat),"file"!==l&&"file"!==e["x-s2o-originalType"]||(T.type="string",T.format="binary"),D(e,T)}}else e&&"file"===e.type&&(e.required&&(c.required=e.required),c.content={},c.content["application/octet-stream"]={},c.content["application/octet-stream"].schema={},c.content["application/octet-stream"].schema.type="string",c.content["application/octet-stream"].schema.format="binary",D(e,c));if(e&&"body"===e.in){c.content={},e.name&&(c["x-s2o-name"]=(t&&t.operationId?k.sanitiseAll(t.operationId):"")+("_"+e.name).toCamelCase()),e.description&&(c.description=e.description),e.required&&(c.required=e.required),t&&s.rbname&&e.name&&(t[s.rbname]=e.name),e.schema&&e.schema.$ref?c["x-s2o-name"]=decodeURIComponent(e.schema.$ref.replace("#/components/schemas/","")):e.schema&&"array"===e.schema.type&&e.schema.items&&e.schema.items.$ref&&(c["x-s2o-name"]=decodeURIComponent(e.schema.items.$ref.replace("#/components/schemas/",""))+"Array"),p.length||p.push("application/json");var L,M=r(p);try{for(M.s();!(L=M.n()).done;){var F=L.value;c.content[F]={},c.content[F].schema=g(e.schema||{}),C(c.content[F].schema,s)}}catch(e){M.e(e)}finally{M.f()}D(e,c)}if(Object.keys(c).length>0&&(e["x-s2o-delete"]=!0,t&&(t.requestBody&&u?(t.requestBody["x-s2o-overloaded"]=!0,R("Operation "+(t.operationId||i)+" has multiple requestBodies",t,s)):(t.requestBody||(t=n[o]=function(e,t){for(var n={},r=0,o=Object.keys(e);r=0?R("definition used as response: "+e.$ref,e,i):e.$ref.startsWith("#/responses/")&&(e.$ref="#/components/responses/"+k.sanitise(decodeURIComponent(e.$ref.replace("#/responses/",""))));else{if((void 0===e.description||null===e.description||""===e.description&&i.patch)&&(i.patch?"object"!=typeof e||Array.isArray(e)||(i.patches++,e.description=E[e]||""):A("(Patchable) response.description is mandatory",i)),void 0!==e.schema){if(C(e.schema,i),e.schema.$ref&&"string"==typeof e.schema.$ref&&e.schema.$ref.startsWith("#/responses/")&&(e.schema.$ref="#/components/responses/"+k.sanitise(decodeURIComponent(e.schema.$ref.replace("#/responses/","")))),n&&n.produces&&"string"==typeof n.produces){if(!i.patch)return A("(Patchable) operation.produces must be an array",i);i.patches++,n.produces=[n.produces]}o.produces&&!Array.isArray(o.produces)&&delete o.produces;var a=((n?n.produces:null)||o.produces||[]).filter(k.uniqueOnly);a.length||a.push("*/*"),e.content={};var s,l=r(a);try{for(l.s();!(s=l.n()).done;){var c=s.value;if(e.content[c]={},e.content[c].schema=g(e.schema),e.examples&&e.examples[c]){var u={};u.value=e.examples[c],e.content[c].examples={},e.content[c].examples.response=u,delete e.examples[c]}"file"===e.content[c].schema.type&&(e.content[c].schema={type:"string",format:"binary"})}}catch(e){l.e(e)}finally{l.f()}delete e.schema}for(var p in e.examples)e.content||(e.content={}),e.content[p]||(e.content[p]={}),e.content[p].examples={},e.content[p].examples.response={},e.content[p].examples.response.value=e.examples[p];if(delete e.examples,e.headers)for(var f in e.headers)"status code"===f.toLowerCase()?i.patch?(i.patches++,delete e.headers[f]):A('(Patchable) "Status Code" is not a valid header',i):L(e.headers[f],i)}}function z(e,t,n,o,i){for(var a in e){var s=e[a];for(var l in s&&s["x-trace"]&&"object"==typeof s["x-trace"]&&(s.trace=s["x-trace"],delete s["x-trace"]),s&&s["x-summary"]&&"string"==typeof s["x-summary"]&&(s.summary=s["x-summary"],delete s["x-summary"]),s&&s["x-description"]&&"string"==typeof s["x-description"]&&(s.description=s["x-description"],delete s["x-description"]),s&&s["x-servers"]&&Array.isArray(s["x-servers"])&&(s.servers=s["x-servers"],delete s["x-servers"]),s)if(k.httpMethods.indexOf(l)>=0||"x-amazon-apigateway-any-method"===l){var c=s[l];if(c&&c.parameters&&Array.isArray(c.parameters)){if(s.parameters){var p,f=r(s.parameters);try{var d=function(){var e=p.value;"string"==typeof e.$ref&&(N(e,n),e=m(i,e.$ref)),c.parameters.find((function(t,n,r){return t.name===e.name&&t.in===e.in}))||"formData"!==e.in&&"body"!==e.in&&"file"!==e.type||(c=M(e,c,s,l,a,i,n),n.rbname&&""===c[n.rbname]&&delete c[n.rbname])};for(f.s();!(p=f.n()).done;)d()}catch(e){f.e(e)}finally{f.f()}}var v,y=r(c.parameters);try{for(y.s();!(v=y.n()).done;){var b=v.value;c=M(b,c,s,l,l+":"+a,i,n)}}catch(e){y.e(e)}finally{y.f()}n.rbname&&""===c[n.rbname]&&delete c[n.rbname],n.debug||c.parameters&&(c.parameters=c.parameters.filter(j))}if(c&&c.security&&P(c.security),"object"==typeof c){if(!c.responses){c.responses={default:{description:"Default response"}}}for(var x in c.responses)F(c.responses[x],0,c,i,n)}if(c&&c["x-servers"]&&Array.isArray(c["x-servers"]))c.servers=c["x-servers"],delete c["x-servers"];else if(c&&c.schemes&&c.schemes.length){var w,E=r(c.schemes);try{for(E.s();!(w=E.n()).done;){var S=w.value;if((!i.schemes||i.schemes.indexOf(S)<0)&&(c.servers||(c.servers=[]),Array.isArray(i.servers))){var _,O=r(i.servers);try{for(O.s();!(_=O.n()).done;){var A=_.value,R=g(A),C=u.parse(R.url);C.protocol=S,R.url=C.format(),c.servers.push(R)}}catch(e){O.e(e)}finally{O.f()}}}}catch(e){E.e(e)}finally{E.f()}}if(n.debug&&(c["x-s2o-consumes"]=c.consumes||[],c["x-s2o-produces"]=c.produces||[]),c){if(delete c.consumes,delete c.produces,delete c.schemes,c["x-ms-examples"]){for(var T in c["x-ms-examples"]){var I=c["x-ms-examples"][T],L=k.sanitiseAll(T);if(I.parameters)for(var D in I.parameters){var z,U=I.parameters[D],B=r((c.parameters||[]).concat(s.parameters||[]));try{for(B.s();!(z=B.n()).done;){var $=z.value;$.$ref&&($=h.jptr(i,$.$ref)),$.name!==D||$.example||($.examples||($.examples={}),$.examples[T]={value:U})}}catch(e){B.e(e)}finally{B.f()}}if(I.responses)for(var q in I.responses){if(I.responses[q].headers)for(var W in I.responses[q].headers){var V=I.responses[q].headers[W];for(var H in c.responses[q].headers)H===W&&(c.responses[q].headers[H].example=V)}if(I.responses[q].body&&(i.components.examples[L]={value:g(I.responses[q].body)},c.responses[q]&&c.responses[q].content))for(var Y in c.responses[q].content){var G=c.responses[q].content[Y];G.examples||(G.examples={}),G.examples[T]={$ref:"#/components/examples/"+L}}}}delete c["x-ms-examples"]}if(c.parameters&&0===c.parameters.length&&delete c.parameters,c.requestBody){var Q=c.operationId?k.sanitiseAll(c.operationId):k.sanitiseAll(l+a).toCamelCase(),X=k.sanitise(c.requestBody["x-s2o-name"]||Q||"");delete c.requestBody["x-s2o-name"];var K=JSON.stringify(c.requestBody),Z=k.hash(K);if(!o[Z]){var J={};J.name=X,J.body=c.requestBody,J.refs=[],o[Z]=J}var ee="#/"+t+"/"+encodeURIComponent(h.jpescape(a))+"/"+l+"/requestBody";o[Z].refs.push(ee)}}}if(s&&s.parameters){for(var te in s.parameters)M(s.parameters[te],null,s,null,a,i,n);!n.debug&&Array.isArray(s.parameters)&&(s.parameters=s.parameters.filter(j))}}}function U(e){return e&&e.url&&"string"==typeof e.url?(e.url=e.url.split("{{").join("{"),e.url=e.url.split("}}").join("}"),e.url.replace(/\{(.+?)\}/g,(function(t,n){e.variables||(e.variables={}),e.variables[n]={default:"unknown"}})),e):e}function B(e,t,n){if(void 0===e.info||null===e.info){if(!t.patch)return n(new O("(Patchable) info object is mandatory"));t.patches++,e.info={version:"",title:""}}if("object"!=typeof e.info||Array.isArray(e.info))return n(new O("info must be an object"));if(void 0===e.info.title||null===e.info.title){if(!t.patch)return n(new O("(Patchable) info.title cannot be null"));t.patches++,e.info.title=""}if(void 0===e.info.version||null===e.info.version){if(!t.patch)return n(new O("(Patchable) info.version cannot be null"));t.patches++,e.info.version=""}if("string"!=typeof e.info.version){if(!t.patch)return n(new O("(Patchable) info.version must be a string"));t.patches++,e.info.version=e.info.version.toString()}if(void 0!==e.info.logo){if(!t.patch)return n(new O("(Patchable) info should not have logo property"));t.patches++,e.info["x-logo"]=e.info.logo,delete e.info.logo}if(void 0!==e.info.termsOfService){if(null===e.info.termsOfService){if(!t.patch)return n(new O("(Patchable) info.termsOfService cannot be null"));t.patches++,e.info.termsOfService=""}try{new URL(e.info.termsOfService)}catch(r){if(!t.patch)return n(new O("(Patchable) info.termsOfService must be a URL"));t.patches++,delete e.info.termsOfService}}}function $(e,t,n){if(void 0===e.paths){if(!t.patch)return n(new O("(Patchable) paths object is mandatory"));t.patches++,e.paths={}}}function q(e,t,n){return p(n,new Promise((function(n,o){if(e||(e={}),t.original=e,t.text||(t.text=d.stringify(e)),t.externals=[],t.externalRefs={},t.rewriteRefs=!0,t.preserveMiro=!0,t.promise={},t.promise.resolve=n,t.promise.reject=o,t.patches=0,t.cache||(t.cache={}),t.source&&(t.cache[t.source]=t.original),function(e,t){var n=new WeakSet;b(e,{identityDetection:!0},(function(e,r,o){"object"==typeof e[r]&&null!==e[r]&&(n.has(e[r])?t.anchors?e[r]=g(e[r]):A("YAML anchor or merge key at "+o.path,t):n.add(e[r]))}))}(e,t),e.openapi&&"string"==typeof e.openapi&&e.openapi.startsWith("3."))return t.openapi=y(e),B(t.openapi,t,o),$(t.openapi,t,o),void x.optionalResolve(t).then((function(){return t.direct?n(t.openapi):n(t)})).catch((function(e){console.warn(e),o(e)}));if(!e.swagger||"2.0"!=e.swagger)return o(new O("Unsupported swagger/OpenAPI version: "+(e.openapi?e.openapi:e.swagger)));var i=t.openapi={};if(i.openapi="string"==typeof t.targetVersion&&t.targetVersion.startsWith("3.")?t.targetVersion:_,t.origin){i["x-origin"]||(i["x-origin"]=[]);var a={};a.url=t.source||t.origin,a.format="swagger",a.version=e.swagger,a.converter={},a.converter.url="https://github.com/mermade/oas-kit",a.converter.version=S,i["x-origin"].push(a)}if(delete(i=Object.assign(i,y(e))).swagger,b(i,{},(function(e,t,n){null===e[t]&&!t.startsWith("x-")&&"default"!==t&&n.path.indexOf("/example")<0&&delete e[t]})),e.host){var s,c=r(Array.isArray(e.schemes)?e.schemes:[""]);try{for(c.s();!(s=c.n()).done;){var u=s.value,p={},f=(e.basePath||"").replace(/\/$/,"");p.url=(u?u+":":"")+"//"+e.host+f,U(p),i.servers||(i.servers=[]),i.servers.push(p)}}catch(e){c.e(e)}finally{c.f()}}else if(e.basePath){var v={};v.url=e.basePath,U(v),i.servers||(i.servers=[]),i.servers.push(v)}if(delete i.host,delete i.basePath,i["x-servers"]&&Array.isArray(i["x-servers"])&&(i.servers=i["x-servers"],delete i["x-servers"]),e["x-ms-parameterized-host"]){var w=e["x-ms-parameterized-host"],E={};E.url=w.hostTemplate+(e.basePath?e.basePath:""),E.variables={};var R=E.url.match(/\{\w+\}/g);for(var j in w.parameters){var N=w.parameters[j];N.$ref&&(N=g(m(i,N.$ref))),j.startsWith("x-")||(delete N.required,delete N.type,delete N.in,void 0===N.default&&(N.enum?N.default=N.enum[0]:N.default="none"),N.name||(N.name=R[j].replace("{","").replace("}","")),E.variables[N.name]=N,delete N.name)}i.servers||(i.servers=[]),!1===w.useSchemePrefix?i.servers.push(E):e.schemes.forEach((function(e){i.servers.push(Object.assign({},E,{url:e+"://"+E.url}))})),delete i["x-ms-parameterized-host"]}B(i,t,o),$(i,t,o),"string"==typeof i.consumes&&(i.consumes=[i.consumes]),"string"==typeof i.produces&&(i.produces=[i.produces]),i.components={},i["x-callbacks"]&&(i.components.callbacks=i["x-callbacks"],delete i["x-callbacks"]),i.components.examples={},i.components.headers={},i["x-links"]&&(i.components.links=i["x-links"],delete i["x-links"]),i.components.parameters=i.parameters||{},i.components.responses=i.responses||{},i.components.requestBodies={},i.components.securitySchemes=i.securityDefinitions||{},i.components.schemas=i.definitions||{},delete i.definitions,delete i.responses,delete i.parameters,delete i.securityDefinitions,x.optionalResolve(t).then((function(){(function(e,t){var n={};for(var r in l={schemas:{}},e.security&&P(e.security),e.components.securitySchemes){var o=k.sanitise(r);r!==o&&(e.components.securitySchemes[o]&&A("Duplicate sanitised securityScheme name "+o,t),e.components.securitySchemes[o]=e.components.securitySchemes[r],delete e.components.securitySchemes[r]),I(e.components.securitySchemes[o],t)}for(var i in e.components.schemas){var a=k.sanitiseAll(i),s="";if(i!==a){for(;e.components.schemas[a+s];)s=s?++s:2;e.components.schemas[a+s]=e.components.schemas[i],delete e.components.schemas[i]}l.schemas[i]=a+s,C(e.components.schemas[a+s],t)}for(var c in t.refmap={},b(e,{payload:{options:t}},T),function(e,t){for(var n in t.refmap)h.jptr(e,n,{$ref:t.refmap[n]})}(e,t),e.components.parameters){var u=k.sanitise(c);c!==u&&(e.components.parameters[u]&&A("Duplicate sanitised parameter name "+u,t),e.components.parameters[u]=e.components.parameters[c],delete e.components.parameters[c]),M(e.components.parameters[u],null,null,null,u,e,t)}for(var p in e.components.responses){var f=k.sanitise(p);p!==f&&(e.components.responses[f]&&A("Duplicate sanitised response name "+f,t),e.components.responses[f]=e.components.responses[p],delete e.components.responses[p]);var d=e.components.responses[f];if(F(d,0,null,e,t),d.headers)for(var m in d.headers)"status code"===m.toLowerCase()?t.patch?(t.patches++,delete d.headers[m]):A('(Patchable) "Status Code" is not a valid header',t):L(d.headers[m],t)}for(var v in e.components.requestBodies){var y=e.components.requestBodies[v],x=JSON.stringify(y),w=k.hash(x),E={};E.name=v,E.body=y,E.refs=[],n[w]=E}if(z(e.paths,"paths",t,n,e),e["x-ms-paths"]&&z(e["x-ms-paths"],"x-ms-paths",t,n,e),!t.debug)for(var S in e.components.parameters)e.components.parameters[S]["x-s2o-delete"]&&delete e.components.parameters[S];t.debug&&(e["x-s2o-consumes"]=e.consumes||[],e["x-s2o-produces"]=e.produces||[]),delete e.consumes,delete e.produces,delete e.schemes;var _=[];if(e.components.requestBodies={},!t.resolveInternal){var O=1;for(var R in n){var j=n[R];if(j.refs.length>1){var N="";for(j.name||(j.name="requestBody",N=O++);_.indexOf(j.name+N)>=0;)N=N?++N:2;for(var D in j.name=j.name+N,_.push(j.name),e.components.requestBodies[j.name]=g(j.body),j.refs){var U={};U.$ref="#/components/requestBodies/"+j.name,h.jptr(e,j.refs[D],U)}}}}e.components.responses&&0===Object.keys(e.components.responses).length&&delete e.components.responses,e.components.parameters&&0===Object.keys(e.components.parameters).length&&delete e.components.parameters,e.components.examples&&0===Object.keys(e.components.examples).length&&delete e.components.examples,e.components.requestBodies&&0===Object.keys(e.components.requestBodies).length&&delete e.components.requestBodies,e.components.securitySchemes&&0===Object.keys(e.components.securitySchemes).length&&delete e.components.securitySchemes,e.components.headers&&0===Object.keys(e.components.headers).length&&delete e.components.headers,e.components.schemas&&0===Object.keys(e.components.schemas).length&&delete e.components.schemas,e.components&&0===Object.keys(e.components).length&&delete e.components})(t.openapi,t),t.direct?n(t.openapi):n(t)})).catch((function(e){console.warn(e),o(e)}))})))}function W(e,t,n){return p(n,new Promise((function(n,r){var o=null,i=null;try{o=JSON.parse(e),t.text=JSON.stringify(o,null,2)}catch(n){i=n;try{o=d.parse(e,{schema:"core",prettyErrors:!0}),t.sourceYaml=!0,t.text=e}catch(e){i=e}}o?q(o,t).then((function(e){return n(e)})).catch((function(e){return r(e)})):r(new O(i?i.message:"Could not parse string"))})))}e.exports={S2OError:O,targetVersion:_,convert:q,convertObj:q,convertUrl:function(e,t,n){return p(n,new Promise((function(n,r){t.origin=!0,t.source||(t.source=e),t.verbose&&console.warn("GET "+e),t.fetch||(t.fetch=f);var o=Object.assign({},t.fetchOptions,{agent:t.agent});t.fetch(e,o).then((function(t){if(200!==t.status)throw new O("Received status code ".concat(t.status,": ").concat(e));return t.text()})).then((function(e){W(e,t).then((function(e){return n(e)})).catch((function(e){return r(e)}))})).catch((function(e){r(e)}))})))},convertStr:W,convertFile:function(e,t,n){return p(n,new Promise((function(n,r){c.readFile(e,t.encoding||"utf8",(function(o,i){o?r(o):(t.sourceFile=e,W(i,t).then((function(e){return n(e)})).catch((function(e){return r(e)})))}))})))},convertStream:function(e,t,n){return p(n,new Promise((function(n,r){var o="";e.on("data",(function(e){o+=e})).on("end",(function(){W(o,t).then((function(e){return n(e)})).catch((function(e){return r(e)}))}))})))}}},873:function(e,t,n){"use strict";n(9601);var r=n(6177);e.exports={statusCodes:Object.assign({},{default:"Default response","1XX":"Informational",103:"Early hints","2XX":"Successful","3XX":"Redirection","4XX":"Client Error","5XX":"Server Error","7XX":"Developer Error"},r.STATUS_CODES)}},1683:function(e){e.exports={}},5623:function(e){"use strict";function t(e,t,o){e instanceof RegExp&&(e=n(e,o)),t instanceof RegExp&&(t=n(t,o));var i=r(e,t,o);return i&&{start:i[0],end:i[1],pre:o.slice(0,i[0]),body:o.slice(i[0]+e.length,i[1]),post:o.slice(i[1]+t.length)}}function n(e,t){var n=t.match(e);return n?n[0]:null}function r(e,t,n){var r,o,i,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),u=l;if(l>=0&&c>0){if(e===t)return[l,c];for(r=[],i=n.length;u>=0&&!s;)u==l?(r.push(u),l=n.indexOf(e,u+1)):1==r.length?s=[r.pop(),c]:((o=r.pop())=0?l:c;r.length&&(s=[i,a])}return s}e.exports=t,t.range=r},9742:function(e,t){"use strict";t.byteLength=function(e){var t=l(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,i=l(e),a=i[0],s=i[1],c=new o(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),u=0,p=s>0?a-4:a;for(n=0;n>16&255,c[u++]=t>>8&255,c[u++]=255&t;return 2===s&&(t=r[e.charCodeAt(n)]<<2|r[e.charCodeAt(n+1)]>>4,c[u++]=255&t),1===s&&(t=r[e.charCodeAt(n)]<<10|r[e.charCodeAt(n+1)]<<4|r[e.charCodeAt(n+2)]>>2,c[u++]=t>>8&255,c[u++]=255&t),c},t.fromByteArray=function(e){for(var t,r=e.length,o=r%3,i=[],a=16383,s=0,l=r-o;sl?l:s+a));return 1===o?(t=e[r-1],i.push(n[t>>2]+n[t<<4&63]+"==")):2===o&&(t=(e[r-2]<<8)+e[r-1],i.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"=")),i.join("")};for(var n=[],r=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=i.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function c(e,t,r){for(var o,i,a=[],s=t;s>18&63]+n[i>>12&63]+n[i>>6&63]+n[63&i]);return a.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},3644:function(e,t,n){var r=n(1048),o=n(5623);e.exports=function(e){return e?("{}"===e.substr(0,2)&&(e="\\{\\}"+e.substr(2)),g(function(e){return e.split("\\\\").join(i).split("\\{").join(a).split("\\}").join(s).split("\\,").join(l).split("\\.").join(c)}(e),!0).map(p)):[]};var i="\0SLASH"+Math.random()+"\0",a="\0OPEN"+Math.random()+"\0",s="\0CLOSE"+Math.random()+"\0",l="\0COMMA"+Math.random()+"\0",c="\0PERIOD"+Math.random()+"\0";function u(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function p(e){return e.split(i).join("\\").split(a).join("{").split(s).join("}").split(l).join(",").split(c).join(".")}function f(e){if(!e)return[""];var t=[],n=o("{","}",e);if(!n)return e.split(",");var r=n.pre,i=n.body,a=n.post,s=r.split(",");s[s.length-1]+="{"+i+"}";var l=f(a);return a.length&&(s[s.length-1]+=l.shift(),s.push.apply(s,l)),t.push.apply(t,s),t}function d(e){return"{"+e+"}"}function h(e){return/^-?0\d/.test(e)}function m(e,t){return e<=t}function v(e,t){return e>=t}function g(e,t){var n=[],i=o("{","}",e);if(!i||/\$$/.test(i.pre))return[e];var a,l=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(i.body),c=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(i.body),p=l||c,y=i.body.indexOf(",")>=0;if(!p&&!y)return i.post.match(/,.*\}/)?g(e=i.pre+"{"+i.body+s+i.post):[e];if(p)a=i.body.split(/\.\./);else if(1===(a=f(i.body)).length&&1===(a=g(a[0],!1).map(d)).length)return(w=i.post.length?g(i.post,!1):[""]).map((function(e){return i.pre+a[0]+e}));var b,x=i.pre,w=i.post.length?g(i.post,!1):[""];if(p){var k=u(a[0]),E=u(a[1]),S=Math.max(a[0].length,a[1].length),_=3==a.length?Math.abs(u(a[2])):1,O=m;E0){var P=new Array(T+1).join("0");C=R<0?"-"+P+C.slice(1):P+C}}b.push(C)}}else b=r(a,(function(e){return g(e,!1)}));for(var I=0;Ia)throw new RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,l.prototype),t}function l(e,t,n){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return p(e)}return c(e,t,n)}function c(e,t,n){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!l.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var n=0|m(e,t),r=s(n),o=r.write(e,t);return o!==n&&(r=r.slice(0,o)),r}(e,t);if(ArrayBuffer.isView(e))return function(e){if(B(e,Uint8Array)){var t=new Uint8Array(e);return d(t.buffer,t.byteOffset,t.byteLength)}return f(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(B(e,ArrayBuffer)||e&&B(e.buffer,ArrayBuffer))return d(e,t,n);if("undefined"!=typeof SharedArrayBuffer&&(B(e,SharedArrayBuffer)||e&&B(e.buffer,SharedArrayBuffer)))return d(e,t,n);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');var r=e.valueOf&&e.valueOf();if(null!=r&&r!==e)return l.from(r,t,n);var o=function(e){if(l.isBuffer(e)){var t=0|h(e.length),n=s(t);return 0===n.length||e.copy(n,0,0,t),n}return void 0!==e.length?"number"!=typeof e.length||$(e.length)?s(0):f(e):"Buffer"===e.type&&Array.isArray(e.data)?f(e.data):void 0}(e);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return l.from(e[Symbol.toPrimitive]("string"),t,n);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function u(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function p(e){return u(e),s(e<0?0:0|h(e))}function f(e){for(var t=e.length<0?0:0|h(e.length),n=s(t),r=0;r=a)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|e}function m(e,t){if(l.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||B(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var n=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===n)return 0;for(var o=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return z(e).length;default:if(o)return r?-1:F(e).length;t=(""+t).toLowerCase(),o=!0}}function v(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return T(this,t,n);case"utf8":case"utf-8":return O(this,t,n);case"ascii":return R(this,t,n);case"latin1":case"binary":return C(this,t,n);case"base64":return _(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function y(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),$(n=+n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=l.from(t,r)),l.isBuffer(t))return 0===t.length?-1:b(e,t,n,r,o);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):b(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function b(e,t,n,r,o){var i,a=1,s=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,l/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var u=-1;for(i=n;is&&(n=s-l),i=n;i>=0;i--){for(var p=!0,f=0;fo&&(r=o):r=o;var i=t.length;r>i/2&&(r=i/2);for(var a=0;a>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function _(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function O(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o239?4:c>223?3:c>191?2:1;if(o+p<=n)switch(p){case 1:c<128&&(u=c);break;case 2:128==(192&(i=e[o+1]))&&(l=(31&c)<<6|63&i)>127&&(u=l);break;case 3:i=e[o+1],a=e[o+2],128==(192&i)&&128==(192&a)&&(l=(15&c)<<12|(63&i)<<6|63&a)>2047&&(l<55296||l>57343)&&(u=l);break;case 4:i=e[o+1],a=e[o+2],s=e[o+3],128==(192&i)&&128==(192&a)&&128==(192&s)&&(l=(15&c)<<18|(63&i)<<12|(63&a)<<6|63&s)>65535&&l<1114112&&(u=l)}null===u?(u=65533,p=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),o+=p}return function(e){var t=e.length;if(t<=A)return String.fromCharCode.apply(String,e);for(var n="",r=0;rr.length?l.from(i).copy(r,o):Uint8Array.prototype.set.call(r,i,o);else{if(!l.isBuffer(i))throw new TypeError('"list" argument must be an Array of Buffers');i.copy(r,o)}o+=i.length}return r},l.byteLength=m,l.prototype._isBuffer=!0,l.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;tn&&(e+=" ... "),""},i&&(l.prototype[i]=l.prototype.inspect),l.prototype.compare=function(e,t,n,r,o){if(B(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),s=Math.min(i,a),c=this.slice(r,o),u=e.slice(t,n),p=0;p>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return x(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":case"latin1":case"binary":return k(this,e,t,n);case"base64":return E(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return S(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var A=4096;function R(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;or)&&(n=r);for(var o="",i=t;in)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,n,r,o,i){if(!l.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function L(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function N(e,t,n,r,i){return t=+t,n>>>=0,i||L(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function M(e,t,n,r,i){return t=+t,n>>>=0,i||L(e,0,n,8),o.write(e,t,n,r,52,8),n+8}l.prototype.slice=function(e,t){var n=this.length;(e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t>>=0,t>>>=0,n||I(e,t,this.length);for(var r=this[e],o=1,i=0;++i>>=0,t>>>=0,n||I(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},l.prototype.readUint8=l.prototype.readUInt8=function(e,t){return e>>>=0,t||I(e,1,this.length),this[e]},l.prototype.readUint16LE=l.prototype.readUInt16LE=function(e,t){return e>>>=0,t||I(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUint16BE=l.prototype.readUInt16BE=function(e,t){return e>>>=0,t||I(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUint32LE=l.prototype.readUInt32LE=function(e,t){return e>>>=0,t||I(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},l.prototype.readUint32BE=l.prototype.readUInt32BE=function(e,t){return e>>>=0,t||I(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||I(e,t,this.length);for(var r=this[e],o=1,i=0;++i=(o*=128)&&(r-=Math.pow(2,8*t)),r},l.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||I(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},l.prototype.readInt8=function(e,t){return e>>>=0,t||I(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},l.prototype.readInt16LE=function(e,t){e>>>=0,t||I(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},l.prototype.readInt16BE=function(e,t){e>>>=0,t||I(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},l.prototype.readInt32LE=function(e,t){return e>>>=0,t||I(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return e>>>=0,t||I(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readFloatLE=function(e,t){return e>>>=0,t||I(e,4,this.length),o.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return e>>>=0,t||I(e,4,this.length),o.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return e>>>=0,t||I(e,8,this.length),o.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return e>>>=0,t||I(e,8,this.length),o.read(this,e,!1,52,8)},l.prototype.writeUintLE=l.prototype.writeUIntLE=function(e,t,n,r){e=+e,t>>>=0,n>>>=0,r||j(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i>>=0,n>>>=0,r||j(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},l.prototype.writeUint8=l.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,1,255,0),this[t]=255&e,t+1},l.prototype.writeUint16LE=l.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeUint16BE=l.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeUint32LE=l.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},l.prototype.writeUint32BE=l.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var o=Math.pow(2,8*n-1);j(this,e,t,n,o-1,-o)}var i=0,a=1,s=0;for(this[t]=255&e;++i>0)-s&255;return t+n},l.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var o=Math.pow(2,8*n-1);j(this,e,t,n,o-1,-o)}var i=n-1,a=1,s=0;for(this[t+i]=255&e;--i>=0&&(a*=256);)e<0&&0===s&&0!==this[t+i+1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+n},l.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},l.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},l.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeFloatLE=function(e,t,n){return N(this,e,t,!0,n)},l.prototype.writeFloatBE=function(e,t,n){return N(this,e,t,!1,n)},l.prototype.writeDoubleLE=function(e,t,n){return M(this,e,t,!0,n)},l.prototype.writeDoubleBE=function(e,t,n){return M(this,e,t,!1,n)},l.prototype.copy=function(e,t,n,r){if(!l.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function z(e){return r.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(D,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function U(e,t,n,r){for(var o=0;o=t.length||o>=e.length);++o)t[o+n]=e[o];return o}function B(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function $(e){return e!=e}var q=function(){for(var e="0123456789abcdef",t=new Array(256),n=0;n<16;++n)for(var r=16*n,o=0;o<16;++o)t[r+o]=e[n]+e[o];return t}()},4480:function(e,t,n){"use strict";var r=n.g.process&&process.nextTick||n.g.setImmediate||function(e){setTimeout(e,0)};e.exports=function(e,t){return e?void t.then((function(t){r((function(){e(null,t)}))}),(function(t){r((function(){e(t)}))})):t}},4184:function(e,t){var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e=[],t=0;t1?arguments[1]:void 0)}},8457:function(e,t,n){"use strict";var r=n(9974),o=n(7908),i=n(3411),a=n(7659),s=n(7466),l=n(6135),c=n(1246);e.exports=function(e){var t,n,u,p,f,d,h=o(e),m="function"==typeof this?this:Array,v=arguments.length,g=v>1?arguments[1]:void 0,y=void 0!==g,b=c(h),x=0;if(y&&(g=r(g,v>2?arguments[2]:void 0,2)),null==b||m==Array&&a(b))for(n=new m(t=s(h.length));t>x;x++)d=y?g(h[x],x):h[x],l(n,x,d);else for(f=(p=b.call(h)).next,n=new m;!(u=f.call(p)).done;x++)d=y?i(p,g,[u.value,x],!0):u.value,l(n,x,d);return n.length=x,n}},1318:function(e,t,n){var r=n(5656),o=n(7466),i=n(1400),a=function(e){return function(t,n,a){var s,l=r(t),c=o(l.length),u=i(a,c);if(e&&n!=n){for(;c>u;)if((s=l[u++])!=s)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===n)return e||u||0;return!e&&-1}};e.exports={includes:a(!0),indexOf:a(!1)}},2092:function(e,t,n){var r=n(9974),o=n(8361),i=n(7908),a=n(7466),s=n(5417),l=[].push,c=function(e){var t=1==e,n=2==e,c=3==e,u=4==e,p=6==e,f=7==e,d=5==e||p;return function(h,m,v,g){for(var y,b,x=i(h),w=o(x),k=r(m,v,3),E=a(w.length),S=0,_=g||s,O=t?_(h,E):n||f?_(h,0):void 0;E>S;S++)if((d||S in w)&&(b=k(y=w[S],S,x),e))if(t)O[S]=b;else if(b)switch(e){case 3:return!0;case 5:return y;case 6:return S;case 2:l.call(O,y)}else switch(e){case 4:return!1;case 7:l.call(O,y)}return p?-1:c||u?u:O}};e.exports={forEach:c(0),map:c(1),filter:c(2),some:c(3),every:c(4),find:c(5),findIndex:c(6),filterOut:c(7)}},1194:function(e,t,n){var r=n(7293),o=n(5112),i=n(7392),a=o("species");e.exports=function(e){return i>=51||!r((function(){var t=[];return(t.constructor={})[a]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}},2133:function(e,t,n){"use strict";var r=n(7293);e.exports=function(e,t){var n=[][e];return!!n&&r((function(){n.call(null,t||function(){throw 1},1)}))}},4362:function(e){var t=Math.floor,n=function(e,i){var a=e.length,s=t(a/2);return a<8?r(e,i):o(n(e.slice(0,s),i),n(e.slice(s),i),i)},r=function(e,t){for(var n,r,o=e.length,i=1;i0;)e[r]=e[--r];r!==i++&&(e[r]=n)}return e},o=function(e,t,n){for(var r=e.length,o=t.length,i=0,a=0,s=[];i1?arguments[1]:void 0,3);t=t?t.next:n.first;)for(r(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!g(this,e)}}),i(u.prototype,n?{get:function(e){var t=g(this,e);return t&&t.value},set:function(e,t){return v(this,0===e?0:e,t)}}:{add:function(e){return v(this,e=0===e?0:e,e)}}),p&&r(u.prototype,"size",{get:function(){return d(this).size}}),u},setStrong:function(e,t,n){var r=t+" Iterator",o=m(t),i=m(r);c(e,t,(function(e,t){h(this,{type:r,target:e,state:o(e),kind:t,last:void 0})}),(function(){for(var e=i(this),t=e.kind,n=e.last;n&&n.removed;)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(e.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),u(t)}}},9320:function(e,t,n){"use strict";var r=n(2248),o=n(2423).getWeakData,i=n(9670),a=n(111),s=n(5787),l=n(612),c=n(2092),u=n(6656),p=n(9909),f=p.set,d=p.getterFor,h=c.find,m=c.findIndex,v=0,g=function(e){return e.frozen||(e.frozen=new y)},y=function(){this.entries=[]},b=function(e,t){return h(e.entries,(function(e){return e[0]===t}))};y.prototype={get:function(e){var t=b(this,e);if(t)return t[1]},has:function(e){return!!b(this,e)},set:function(e,t){var n=b(this,e);n?n[1]=t:this.entries.push([e,t])},delete:function(e){var t=m(this.entries,(function(t){return t[0]===e}));return~t&&this.entries.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,n,c){var p=e((function(e,r){s(e,p,t),f(e,{type:t,id:v++,frozen:void 0}),null!=r&&l(r,e[c],{that:e,AS_ENTRIES:n})})),h=d(t),m=function(e,t,n){var r=h(e),a=o(i(t),!0);return!0===a?g(r).set(t,n):a[r.id]=n,e};return r(p.prototype,{delete:function(e){var t=h(this);if(!a(e))return!1;var n=o(e);return!0===n?g(t).delete(e):n&&u(n,t.id)&&delete n[t.id]},has:function(e){var t=h(this);if(!a(e))return!1;var n=o(e);return!0===n?g(t).has(e):n&&u(n,t.id)}}),r(p.prototype,n?{get:function(e){var t=h(this);if(a(e)){var n=o(e);return!0===n?g(t).get(e):n?n[t.id]:void 0}},set:function(e,t){return m(this,e,t)}}:{add:function(e){return m(this,e,!0)}}),p}}},7710:function(e,t,n){"use strict";var r=n(2109),o=n(7854),i=n(4705),a=n(1320),s=n(2423),l=n(612),c=n(5787),u=n(111),p=n(7293),f=n(7072),d=n(8003),h=n(9587);e.exports=function(e,t,n){var m=-1!==e.indexOf("Map"),v=-1!==e.indexOf("Weak"),g=m?"set":"add",y=o[e],b=y&&y.prototype,x=y,w={},k=function(e){var t=b[e];a(b,e,"add"==e?function(e){return t.call(this,0===e?0:e),this}:"delete"==e?function(e){return!(v&&!u(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return v&&!u(e)?void 0:t.call(this,0===e?0:e)}:"has"==e?function(e){return!(v&&!u(e))&&t.call(this,0===e?0:e)}:function(e,n){return t.call(this,0===e?0:e,n),this})};if(i(e,"function"!=typeof y||!(v||b.forEach&&!p((function(){(new y).entries().next()})))))x=n.getConstructor(t,e,m,g),s.REQUIRED=!0;else if(i(e,!0)){var E=new x,S=E[g](v?{}:-0,1)!=E,_=p((function(){E.has(1)})),O=f((function(e){new y(e)})),A=!v&&p((function(){for(var e=new y,t=5;t--;)e[g](t,t);return!e.has(-0)}));O||((x=t((function(t,n){c(t,x,e);var r=h(new y,t,x);return null!=n&&l(n,r[g],{that:r,AS_ENTRIES:m}),r}))).prototype=b,b.constructor=x),(_||A)&&(k("delete"),k("has"),m&&k("get")),(A||S)&&k(g),v&&b.clear&&delete b.clear}return w[e]=x,r({global:!0,forced:x!=y},w),d(x,e),v||n.setStrong(x,e,m),x}},9920:function(e,t,n){var r=n(6656),o=n(3887),i=n(1236),a=n(3070);e.exports=function(e,t){for(var n=o(t),s=a.f,l=i.f,c=0;c"+a+""}},4994:function(e,t,n){"use strict";var r=n(3383).IteratorPrototype,o=n(30),i=n(9114),a=n(8003),s=n(7497),l=function(){return this};e.exports=function(e,t,n){var c=t+" Iterator";return e.prototype=o(r,{next:i(1,n)}),a(e,c,!1,!0),s[c]=l,e}},8880:function(e,t,n){var r=n(9781),o=n(3070),i=n(9114);e.exports=r?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},9114:function(e){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},6135:function(e,t,n){"use strict";var r=n(7593),o=n(3070),i=n(9114);e.exports=function(e,t,n){var a=r(t);a in e?o.f(e,a,i(0,n)):e[a]=n}},8709:function(e,t,n){"use strict";var r=n(9670),o=n(7593);e.exports=function(e){if("string"!==e&&"number"!==e&&"default"!==e)throw TypeError("Incorrect hint");return o(r(this),"number"!==e)}},654:function(e,t,n){"use strict";var r=n(2109),o=n(4994),i=n(9518),a=n(7674),s=n(8003),l=n(8880),c=n(1320),u=n(5112),p=n(1913),f=n(7497),d=n(3383),h=d.IteratorPrototype,m=d.BUGGY_SAFARI_ITERATORS,v=u("iterator"),g="keys",y="values",b="entries",x=function(){return this};e.exports=function(e,t,n,u,d,w,k){o(n,t,u);var E,S,_,O=function(e){if(e===d&&P)return P;if(!m&&e in C)return C[e];switch(e){case g:case y:case b:return function(){return new n(this,e)}}return function(){return new n(this)}},A=t+" Iterator",R=!1,C=e.prototype,T=C[v]||C["@@iterator"]||d&&C[d],P=!m&&T||O(d),I="Array"==t&&C.entries||T;if(I&&(E=i(I.call(new e)),h!==Object.prototype&&E.next&&(p||i(E)===h||(a?a(E,h):"function"!=typeof E[v]&&l(E,v,x)),s(E,A,!0,!0),p&&(f[A]=x))),d==y&&T&&T.name!==y&&(R=!0,P=function(){return T.call(this)}),p&&!k||C[v]===P||l(C,v,P),f[t]=P,d)if(S={values:O(y),keys:w?P:O(g),entries:O(b)},k)for(_ in S)(m||R||!(_ in C))&&c(C,_,S[_]);else r({target:t,proto:!0,forced:m||R},S);return S}},7235:function(e,t,n){var r=n(857),o=n(6656),i=n(6061),a=n(3070).f;e.exports=function(e){var t=r.Symbol||(r.Symbol={});o(t,e)||a(t,e,{value:i.f(e)})}},9781:function(e,t,n){var r=n(7293);e.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},317:function(e,t,n){var r=n(7854),o=n(111),i=r.document,a=o(i)&&o(i.createElement);e.exports=function(e){return a?i.createElement(e):{}}},8324:function(e){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},8886:function(e,t,n){var r=n(8113).match(/firefox\/(\d+)/i);e.exports=!!r&&+r[1]},7871:function(e){e.exports="object"==typeof window},256:function(e,t,n){var r=n(8113);e.exports=/MSIE|Trident/.test(r)},6833:function(e,t,n){var r=n(8113);e.exports=/(?:iphone|ipod|ipad).*applewebkit/i.test(r)},5268:function(e,t,n){var r=n(4326),o=n(7854);e.exports="process"==r(o.process)},1036:function(e,t,n){var r=n(8113);e.exports=/web0s(?!.*chrome)/i.test(r)},8113:function(e,t,n){var r=n(5005);e.exports=r("navigator","userAgent")||""},7392:function(e,t,n){var r,o,i=n(7854),a=n(8113),s=i.process,l=s&&s.versions,c=l&&l.v8;c?o=(r=c.split("."))[0]<4?1:r[0]+r[1]:a&&(!(r=a.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=a.match(/Chrome\/(\d+)/))&&(o=r[1]),e.exports=o&&+o},8008:function(e,t,n){var r=n(8113).match(/AppleWebKit\/(\d+)\./);e.exports=!!r&&+r[1]},748:function(e){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},2109:function(e,t,n){var r=n(7854),o=n(1236).f,i=n(8880),a=n(1320),s=n(3505),l=n(9920),c=n(4705);e.exports=function(e,t){var n,u,p,f,d,h=e.target,m=e.global,v=e.stat;if(n=m?r:v?r[h]||s(h,{}):(r[h]||{}).prototype)for(u in t){if(f=t[u],p=e.noTargetGet?(d=o(n,u))&&d.value:n[u],!c(m?u:h+(v?".":"#")+u,e.forced)&&void 0!==p){if(typeof f==typeof p)continue;l(f,p)}(e.sham||p&&p.sham)&&i(f,"sham",!0),a(n,u,f,e)}}},7293:function(e){e.exports=function(e){try{return!!e()}catch(e){return!0}}},7007:function(e,t,n){"use strict";n(4916);var r=n(1320),o=n(2261),i=n(7293),a=n(5112),s=n(8880),l=a("species"),c=RegExp.prototype,u=!i((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$")})),p="$0"==="a".replace(/./,"$0"),f=a("replace"),d=!!/./[f]&&""===/./[f]("a","$0"),h=!i((function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));e.exports=function(e,t,n,f){var m=a(e),v=!i((function(){var t={};return t[m]=function(){return 7},7!=""[e](t)})),g=v&&!i((function(){var t=!1,n=/a/;return"split"===e&&((n={}).constructor={},n.constructor[l]=function(){return n},n.flags="",n[m]=/./[m]),n.exec=function(){return t=!0,null},n[m](""),!t}));if(!v||!g||"replace"===e&&(!u||!p||d)||"split"===e&&!h){var y=/./[m],b=n(m,""[e],(function(e,t,n,r,i){var a=t.exec;return a===o||a===c.exec?v&&!i?{done:!0,value:y.call(t,n,r)}:{done:!0,value:e.call(n,t,r)}:{done:!1}}),{REPLACE_KEEPS_$0:p,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:d}),x=b[0],w=b[1];r(String.prototype,e,x),r(c,m,2==t?function(e,t){return w.call(e,this,t)}:function(e){return w.call(e,this)})}f&&s(c[m],"sham",!0)}},6790:function(e,t,n){"use strict";var r=n(3157),o=n(7466),i=n(9974),a=function(e,t,n,s,l,c,u,p){for(var f,d=l,h=0,m=!!u&&i(u,p,3);h0&&r(f))d=a(e,t,f,o(f.length),d,c-1)-1;else{if(d>=9007199254740991)throw TypeError("Exceed the acceptable array length");e[d]=f}d++}h++}return d};e.exports=a},6677:function(e,t,n){var r=n(7293);e.exports=!r((function(){return Object.isExtensible(Object.preventExtensions({}))}))},9974:function(e,t,n){var r=n(3099);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 0:return function(){return e.call(t)};case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}}},5005:function(e,t,n){var r=n(857),o=n(7854),i=function(e){return"function"==typeof e?e:void 0};e.exports=function(e,t){return arguments.length<2?i(r[e])||i(o[e]):r[e]&&r[e][t]||o[e]&&o[e][t]}},1246:function(e,t,n){var r=n(648),o=n(7497),i=n(5112)("iterator");e.exports=function(e){if(null!=e)return e[i]||e["@@iterator"]||o[r(e)]}},8554:function(e,t,n){var r=n(9670),o=n(1246);e.exports=function(e){var t=o(e);if("function"!=typeof t)throw TypeError(String(e)+" is not iterable");return r(t.call(e))}},647:function(e,t,n){var r=n(7908),o=Math.floor,i="".replace,a=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,s=/\$([$&'`]|\d{1,2})/g;e.exports=function(e,t,n,l,c,u){var p=n+e.length,f=l.length,d=s;return void 0!==c&&(c=r(c),d=a),i.call(u,d,(function(r,i){var a;switch(i.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,n);case"'":return t.slice(p);case"<":a=c[i.slice(1,-1)];break;default:var s=+i;if(0===s)return r;if(s>f){var u=o(s/10);return 0===u?r:u<=f?void 0===l[u-1]?i.charAt(1):l[u-1]+i.charAt(1):r}a=l[s-1]}return void 0===a?"":a}))}},7854:function(e,t,n){var r=function(e){return e&&e.Math==Math&&e};e.exports=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof n.g&&n.g)||function(){return this}()||Function("return this")()},6656:function(e,t,n){var r=n(7908),o={}.hasOwnProperty;e.exports=Object.hasOwn||function(e,t){return o.call(r(e),t)}},3501:function(e){e.exports={}},842:function(e,t,n){var r=n(7854);e.exports=function(e,t){var n=r.console;n&&n.error&&(1===arguments.length?n.error(e):n.error(e,t))}},490:function(e,t,n){var r=n(5005);e.exports=r("document","documentElement")},4664:function(e,t,n){var r=n(9781),o=n(7293),i=n(317);e.exports=!r&&!o((function(){return 7!=Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},8361:function(e,t,n){var r=n(7293),o=n(4326),i="".split;e.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==o(e)?i.call(e,""):Object(e)}:Object},9587:function(e,t,n){var r=n(111),o=n(7674);e.exports=function(e,t,n){var i,a;return o&&"function"==typeof(i=t.constructor)&&i!==n&&r(a=i.prototype)&&a!==n.prototype&&o(e,a),e}},2788:function(e,t,n){var r=n(5465),o=Function.toString;"function"!=typeof r.inspectSource&&(r.inspectSource=function(e){return o.call(e)}),e.exports=r.inspectSource},2423:function(e,t,n){var r=n(3501),o=n(111),i=n(6656),a=n(3070).f,s=n(9711),l=n(6677),c=s("meta"),u=0,p=Object.isExtensible||function(){return!0},f=function(e){a(e,c,{value:{objectID:"O"+ ++u,weakData:{}}})},d=e.exports={REQUIRED:!1,fastKey:function(e,t){if(!o(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,c)){if(!p(e))return"F";if(!t)return"E";f(e)}return e[c].objectID},getWeakData:function(e,t){if(!i(e,c)){if(!p(e))return!0;if(!t)return!1;f(e)}return e[c].weakData},onFreeze:function(e){return l&&d.REQUIRED&&p(e)&&!i(e,c)&&f(e),e}};r[c]=!0},9909:function(e,t,n){var r,o,i,a=n(8536),s=n(7854),l=n(111),c=n(8880),u=n(6656),p=n(5465),f=n(6200),d=n(3501),h="Object already initialized",m=s.WeakMap;if(a||p.state){var v=p.state||(p.state=new m),g=v.get,y=v.has,b=v.set;r=function(e,t){if(y.call(v,e))throw new TypeError(h);return t.facade=e,b.call(v,e,t),t},o=function(e){return g.call(v,e)||{}},i=function(e){return y.call(v,e)}}else{var x=f("state");d[x]=!0,r=function(e,t){if(u(e,x))throw new TypeError(h);return t.facade=e,c(e,x,t),t},o=function(e){return u(e,x)?e[x]:{}},i=function(e){return u(e,x)}}e.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!l(t)||(n=o(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}}}},7659:function(e,t,n){var r=n(5112),o=n(7497),i=r("iterator"),a=Array.prototype;e.exports=function(e){return void 0!==e&&(o.Array===e||a[i]===e)}},3157:function(e,t,n){var r=n(4326);e.exports=Array.isArray||function(e){return"Array"==r(e)}},4705:function(e,t,n){var r=n(7293),o=/#|\.prototype\./,i=function(e,t){var n=s[a(e)];return n==c||n!=l&&("function"==typeof t?r(t):!!t)},a=i.normalize=function(e){return String(e).replace(o,".").toLowerCase()},s=i.data={},l=i.NATIVE="N",c=i.POLYFILL="P";e.exports=i},111:function(e){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},1913:function(e){e.exports=!1},7850:function(e,t,n){var r=n(111),o=n(4326),i=n(5112)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},612:function(e,t,n){var r=n(9670),o=n(7659),i=n(7466),a=n(9974),s=n(1246),l=n(9212),c=function(e,t){this.stopped=e,this.result=t};e.exports=function(e,t,n){var u,p,f,d,h,m,v,g=n&&n.that,y=!(!n||!n.AS_ENTRIES),b=!(!n||!n.IS_ITERATOR),x=!(!n||!n.INTERRUPTED),w=a(t,g,1+y+x),k=function(e){return u&&l(u),new c(!0,e)},E=function(e){return y?(r(e),x?w(e[0],e[1],k):w(e[0],e[1])):x?w(e,k):w(e)};if(b)u=e;else{if("function"!=typeof(p=s(e)))throw TypeError("Target is not iterable");if(o(p)){for(f=0,d=i(e.length);d>f;f++)if((h=E(e[f]))&&h instanceof c)return h;return new c(!1)}u=p.call(e)}for(m=u.next;!(v=m.call(u)).done;){try{h=E(v.value)}catch(e){throw l(u),e}if("object"==typeof h&&h&&h instanceof c)return h}return new c(!1)}},9212:function(e,t,n){var r=n(9670);e.exports=function(e){var t=e.return;if(void 0!==t)return r(t.call(e)).value}},3383:function(e,t,n){"use strict";var r,o,i,a=n(7293),s=n(9518),l=n(8880),c=n(6656),u=n(5112),p=n(1913),f=u("iterator"),d=!1;[].keys&&("next"in(i=[].keys())?(o=s(s(i)))!==Object.prototype&&(r=o):d=!0);var h=null==r||a((function(){var e={};return r[f].call(e)!==e}));h&&(r={}),p&&!h||c(r,f)||l(r,f,(function(){return this})),e.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:d}},7497:function(e){e.exports={}},5948:function(e,t,n){var r,o,i,a,s,l,c,u,p=n(7854),f=n(1236).f,d=n(261).set,h=n(6833),m=n(1036),v=n(5268),g=p.MutationObserver||p.WebKitMutationObserver,y=p.document,b=p.process,x=p.Promise,w=f(p,"queueMicrotask"),k=w&&w.value;k||(r=function(){var e,t;for(v&&(e=b.domain)&&e.exit();o;){t=o.fn,o=o.next;try{t()}catch(e){throw o?a():i=void 0,e}}i=void 0,e&&e.enter()},h||v||m||!g||!y?x&&x.resolve?((c=x.resolve(void 0)).constructor=x,u=c.then,a=function(){u.call(c,r)}):a=v?function(){b.nextTick(r)}:function(){d.call(p,r)}:(s=!0,l=y.createTextNode(""),new g(r).observe(l,{characterData:!0}),a=function(){l.data=s=!s})),e.exports=k||function(e){var t={fn:e,next:void 0};i&&(i.next=t),o||(o=t,a()),i=t}},3366:function(e,t,n){var r=n(7854);e.exports=r.Promise},133:function(e,t,n){var r=n(7392),o=n(7293);e.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},590:function(e,t,n){var r=n(7293),o=n(5112),i=n(1913),a=o("iterator");e.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t.delete("b"),n+=r+e})),i&&!e.toJSON||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[a]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},8536:function(e,t,n){var r=n(7854),o=n(2788),i=r.WeakMap;e.exports="function"==typeof i&&/native code/.test(o(i))},8523:function(e,t,n){"use strict";var r=n(3099),o=function(e){var t,n;this.promise=new e((function(e,r){if(void 0!==t||void 0!==n)throw TypeError("Bad Promise constructor");t=e,n=r})),this.resolve=r(t),this.reject=r(n)};e.exports.f=function(e){return new o(e)}},3929:function(e,t,n){var r=n(7850);e.exports=function(e){if(r(e))throw TypeError("The method doesn't accept regular expressions");return e}},1574:function(e,t,n){"use strict";var r=n(9781),o=n(7293),i=n(1956),a=n(5181),s=n(5296),l=n(7908),c=n(8361),u=Object.assign,p=Object.defineProperty;e.exports=!u||o((function(){if(r&&1!==u({b:1},u(p({},"a",{enumerable:!0,get:function(){p(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},n=Symbol(),o="abcdefghijklmnopqrst";return e[n]=7,o.split("").forEach((function(e){t[e]=e})),7!=u({},e)[n]||i(u({},t)).join("")!=o}))?function(e,t){for(var n=l(e),o=arguments.length,u=1,p=a.f,f=s.f;o>u;)for(var d,h=c(arguments[u++]),m=p?i(h).concat(p(h)):i(h),v=m.length,g=0;v>g;)d=m[g++],r&&!f.call(h,d)||(n[d]=h[d]);return n}:u},30:function(e,t,n){var r,o=n(9670),i=n(6048),a=n(748),s=n(3501),l=n(490),c=n(317),u=n(6200)("IE_PROTO"),p=function(){},f=function(e){return"