@redocly/openapi-docs 3.8.0-next.6 → 3.9.0-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Redocly OpenAPI Docs
|
|
3
3
|
* (c) Copyright 2018 Redocly LLC, all rights reserved.
|
|
4
4
|
* -------------------------------------------------------------
|
|
5
|
-
* Version: "3.
|
|
5
|
+
* Version: "3.9.0-next.0"
|
|
6
6
|
*/(function(Du,Lc){typeof exports=="object"&&typeof module=="object"?module.exports=Lc(require("null")):typeof define=="function"&&define.amd?define(["null"],Lc):typeof exports=="object"?exports.RedoclyOpenAPIDocs=Lc(require("null")):Du.RedoclyOpenAPIDocs=Lc(Du.null)})(this,Op=>(()=>{var Du={44607:(P,n,e)=>{"use strict";e.d(n,{A:()=>o});function o(h){var f=Object.create(null);return function(O){return f[O]===void 0&&(f[O]=h(O)),f[O]}}},61203:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.CodeGen=n.Name=n.nil=n.stringify=n.str=n._=n.KeywordCxt=void 0;const o=e(85968),h=e(96735),f=e(67104),O=e(48226),d="https://json-schema.org/draft/2020-12/schema";class p extends o.default{constructor(x={}){super({...x,dynamicRef:!0,next:!0,unevaluated:!0})}_addVocabularies(){super._addVocabularies(),h.default.forEach(x=>this.addVocabulary(x)),this.opts.discriminator&&this.addKeyword(f.default)}_addDefaultMetaSchema(){super._addDefaultMetaSchema();const{$data:x,meta:y}=this.opts;y&&(O.default.call(this,x),this.refs["http://json-schema.org/schema"]=d)}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(d)?d:void 0)}}P.exports=n=p,Object.defineProperty(n,"__esModule",{value:!0}),n.default=p;var c=e(9804);Object.defineProperty(n,"KeywordCxt",{enumerable:!0,get:function(){return c.KeywordCxt}});var v=e(57287);Object.defineProperty(n,"_",{enumerable:!0,get:function(){return v._}}),Object.defineProperty(n,"str",{enumerable:!0,get:function(){return v.str}}),Object.defineProperty(n,"stringify",{enumerable:!0,get:function(){return v.stringify}}),Object.defineProperty(n,"nil",{enumerable:!0,get:function(){return v.nil}}),Object.defineProperty(n,"Name",{enumerable:!0,get:function(){return v.Name}}),Object.defineProperty(n,"CodeGen",{enumerable:!0,get:function(){return v.CodeGen}})},76202:(P,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.nil=n._Code=n.Name=n.IDENTIFIER=n._CodeOrName=void 0,n._=f,n.str=d,n.addCodeArg=p,n.strConcat=g,n.stringify=y,n.safeStringify=I,n.getProperty=E,n.getEsmExportName=S,n.regexpCode=t;class e{}n._CodeOrName=e,n.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class o extends e{constructor(l){if(super(),!n.IDENTIFIER.test(l))throw new Error("CodeGen: name must be a valid identifier");this.str=l}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}n.Name=o;class h extends e{constructor(l){super(),this._items=typeof l=="string"?[l]:l}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const l=this._items[0];return l===""||l==='""'}get str(){var l;return(l=this._str)!==null&&l!==void 0?l:this._str=this._items.reduce((M,b)=>`${M}${b}`,"")}get names(){var l;return(l=this._names)!==null&&l!==void 0?l:this._names=this._items.reduce((M,b)=>(b instanceof o&&(M[b.str]=(M[b.str]||0)+1),M),{})}}n._Code=h,n.nil=new h("");function f(a,...l){const M=[a[0]];let b=0;for(;b<l.length;)p(M,l[b]),M.push(a[++b]);return new h(M)}const O=new h("+");function d(a,...l){const M=[I(a[0])];let b=0;for(;b<l.length;)M.push(O),p(M,l[b]),M.push(O,I(a[++b]));return c(M),new h(M)}function p(a,l){l instanceof h?a.push(...l._items):l instanceof o?a.push(l):a.push(x(l))}function c(a){let l=1;for(;l<a.length-1;){if(a[l]===O){const M=v(a[l-1],a[l+1]);if(M!==void 0){a.splice(l-1,3,M);continue}a[l++]="+"}l++}}function v(a,l){if(l==='""')return a;if(a==='""')return l;if(typeof a=="string")return l instanceof o||a[a.length-1]!=='"'?void 0:typeof l!="string"?`${a.slice(0,-1)}${l}"`:l[0]==='"'?a.slice(0,-1)+l.slice(1):void 0;if(typeof l=="string"&&l[0]==='"'&&!(a instanceof o))return`"${a}${l.slice(1)}`}function g(a,l){return l.emptyStr()?a:a.emptyStr()?l:d`${a}${l}`}function x(a){return typeof a=="number"||typeof a=="boolean"||a===null?a:I(Array.isArray(a)?a.join(","):a)}function y(a){return new h(I(a))}function I(a){return JSON.stringify(a).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}function E(a){return typeof a=="string"&&n.IDENTIFIER.test(a)?new h(`.${a}`):f`[${a}]`}function S(a){if(typeof a=="string"&&n.IDENTIFIER.test(a))return new h(`${a}`);throw new Error(`CodeGen: invalid export name: ${a}, use explicit $id name mapping`)}function t(a){return new h(a.toString())}},57287:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.CodeGen=n.operators=n.varKinds=n.ValueScopeName=n.ValueScope=n.Scope=n.Name=n.regexpCode=n.stringify=n.getProperty=n.nil=n.strConcat=n.str=n._=void 0,n.not=Ee,n.and=je,n.or=ce;const o=e(76202),h=e(34863);var f=e(76202);Object.defineProperty(n,"_",{enumerable:!0,get:function(){return f._}}),Object.defineProperty(n,"str",{enumerable:!0,get:function(){return f.str}}),Object.defineProperty(n,"strConcat",{enumerable:!0,get:function(){return f.strConcat}}),Object.defineProperty(n,"nil",{enumerable:!0,get:function(){return f.nil}}),Object.defineProperty(n,"getProperty",{enumerable:!0,get:function(){return f.getProperty}}),Object.defineProperty(n,"stringify",{enumerable:!0,get:function(){return f.stringify}}),Object.defineProperty(n,"regexpCode",{enumerable:!0,get:function(){return f.regexpCode}}),Object.defineProperty(n,"Name",{enumerable:!0,get:function(){return f.Name}});var O=e(34863);Object.defineProperty(n,"Scope",{enumerable:!0,get:function(){return O.Scope}}),Object.defineProperty(n,"ValueScope",{enumerable:!0,get:function(){return O.ValueScope}}),Object.defineProperty(n,"ValueScopeName",{enumerable:!0,get:function(){return O.ValueScopeName}}),Object.defineProperty(n,"varKinds",{enumerable:!0,get:function(){return O.varKinds}}),n.operators={GT:new o._Code(">"),GTE:new o._Code(">="),LT:new o._Code("<"),LTE:new o._Code("<="),EQ:new o._Code("==="),NEQ:new o._Code("!=="),NOT:new o._Code("!"),OR:new o._Code("||"),AND:new o._Code("&&"),ADD:new o._Code("+")};class d{optimizeNodes(){return this}optimizeNames(_,re){return this}}class p extends d{constructor(_,re,Oe){super(),this.varKind=_,this.name=re,this.rhs=Oe}render({es5:_,_n:re}){const Oe=_?h.varKinds.var:this.varKind,Ne=this.rhs===void 0?"":` = ${this.rhs}`;return`${Oe} ${this.name}${Ne};`+re}optimizeNames(_,re){if(_[this.name.str])return this.rhs&&(this.rhs=N(this.rhs,_,re)),this}get names(){return this.rhs instanceof o._CodeOrName?this.rhs.names:{}}}class c extends d{constructor(_,re,Oe){super(),this.lhs=_,this.rhs=re,this.sideEffects=Oe}render({_n:_}){return`${this.lhs} = ${this.rhs};`+_}optimizeNames(_,re){if(!(this.lhs instanceof o.Name&&!_[this.lhs.str]&&!this.sideEffects))return this.rhs=N(this.rhs,_,re),this}get names(){const _=this.lhs instanceof o.Name?{}:{...this.lhs.names};return Q(_,this.rhs)}}class v extends c{constructor(_,re,Oe,Ne){super(_,Oe,Ne),this.op=re}render({_n:_}){return`${this.lhs} ${this.op}= ${this.rhs};`+_}}class g extends d{constructor(_){super(),this.label=_,this.names={}}render({_n:_}){return`${this.label}:`+_}}class x extends d{constructor(_){super(),this.label=_,this.names={}}render({_n:_}){return`break${this.label?` ${this.label}`:""};`+_}}class y extends d{constructor(_){super(),this.error=_}render({_n:_}){return`throw ${this.error};`+_}get names(){return this.error.names}}class I extends d{constructor(_){super(),this.code=_}render({_n:_}){return`${this.code};`+_}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(_,re){return this.code=N(this.code,_,re),this}get names(){return this.code instanceof o._CodeOrName?this.code.names:{}}}class E extends d{constructor(_=[]){super(),this.nodes=_}render(_){return this.nodes.reduce((re,Oe)=>re+Oe.render(_),"")}optimizeNodes(){const{nodes:_}=this;let re=_.length;for(;re--;){const Oe=_[re].optimizeNodes();Array.isArray(Oe)?_.splice(re,1,...Oe):Oe?_[re]=Oe:_.splice(re,1)}return _.length>0?this:void 0}optimizeNames(_,re){const{nodes:Oe}=this;let Ne=Oe.length;for(;Ne--;){const ke=Oe[Ne];ke.optimizeNames(_,re)||(ue(_,ke.names),Oe.splice(Ne,1))}return Oe.length>0?this:void 0}get names(){return this.nodes.reduce((_,re)=>J(_,re.names),{})}}class S extends E{render(_){return"{"+_._n+super.render(_)+"}"+_._n}}class t extends E{}class a extends S{}a.kind="else";class l extends S{constructor(_,re){super(re),this.condition=_}render(_){let re=`if(${this.condition})`+super.render(_);return this.else&&(re+="else "+this.else.render(_)),re}optimizeNodes(){super.optimizeNodes();const _=this.condition;if(_===!0)return this.nodes;let re=this.else;if(re){const Oe=re.optimizeNodes();re=this.else=Array.isArray(Oe)?new a(Oe):Oe}if(re)return _===!1?re instanceof l?re:re.nodes:this.nodes.length?this:new l(Ee(_),re instanceof l?[re]:re.nodes);if(!(_===!1||!this.nodes.length))return this}optimizeNames(_,re){var Oe;if(this.else=(Oe=this.else)===null||Oe===void 0?void 0:Oe.optimizeNames(_,re),!!(super.optimizeNames(_,re)||this.else))return this.condition=N(this.condition,_,re),this}get names(){const _=super.names;return Q(_,this.condition),this.else&&J(_,this.else.names),_}}l.kind="if";class M extends S{}M.kind="for";class b extends M{constructor(_){super(),this.iteration=_}render(_){return`for(${this.iteration})`+super.render(_)}optimizeNames(_,re){if(super.optimizeNames(_,re))return this.iteration=N(this.iteration,_,re),this}get names(){return J(super.names,this.iteration.names)}}class R extends M{constructor(_,re,Oe,Ne){super(),this.varKind=_,this.name=re,this.from=Oe,this.to=Ne}render(_){const re=_.es5?h.varKinds.var:this.varKind,{name:Oe,from:Ne,to:ke}=this;return`for(${re} ${Oe}=${Ne}; ${Oe}<${ke}; ${Oe}++)`+super.render(_)}get names(){const _=Q(super.names,this.from);return Q(_,this.to)}}class D extends M{constructor(_,re,Oe,Ne){super(),this.loop=_,this.varKind=re,this.name=Oe,this.iterable=Ne}render(_){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(_)}optimizeNames(_,re){if(super.optimizeNames(_,re))return this.iterable=N(this.iterable,_,re),this}get names(){return J(super.names,this.iterable.names)}}class B extends S{constructor(_,re,Oe){super(),this.name=_,this.args=re,this.async=Oe}render(_){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(_)}}B.kind="func";class j extends E{render(_){return"return "+super.render(_)}}j.kind="return";class $ extends S{render(_){let re="try"+super.render(_);return this.catch&&(re+=this.catch.render(_)),this.finally&&(re+=this.finally.render(_)),re}optimizeNodes(){var _,re;return super.optimizeNodes(),(_=this.catch)===null||_===void 0||_.optimizeNodes(),(re=this.finally)===null||re===void 0||re.optimizeNodes(),this}optimizeNames(_,re){var Oe,Ne;return super.optimizeNames(_,re),(Oe=this.catch)===null||Oe===void 0||Oe.optimizeNames(_,re),(Ne=this.finally)===null||Ne===void 0||Ne.optimizeNames(_,re),this}get names(){const _=super.names;return this.catch&&J(_,this.catch.names),this.finally&&J(_,this.finally.names),_}}class w extends S{constructor(_){super(),this.error=_}render(_){return`catch(${this.error})`+super.render(_)}}w.kind="catch";class V extends S{render(_){return"finally"+super.render(_)}}V.kind="finally";class X{constructor(_,re={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...re,_n:re.lines?`
|
|
7
7
|
`:""},this._extScope=_,this._scope=new h.Scope({parent:_}),this._nodes=[new t]}toString(){return this._root.render(this.opts)}name(_){return this._scope.name(_)}scopeName(_){return this._extScope.name(_)}scopeValue(_,re){const Oe=this._extScope.value(_,re);return(this._values[Oe.prefix]||(this._values[Oe.prefix]=new Set)).add(Oe),Oe}getScopeValue(_,re){return this._extScope.getValue(_,re)}scopeRefs(_){return this._extScope.scopeRefs(_,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(_,re,Oe,Ne){const ke=this._scope.toName(re);return Oe!==void 0&&Ne&&(this._constants[ke.str]=Oe),this._leafNode(new p(_,ke,Oe)),ke}const(_,re,Oe){return this._def(h.varKinds.const,_,re,Oe)}let(_,re,Oe){return this._def(h.varKinds.let,_,re,Oe)}var(_,re,Oe){return this._def(h.varKinds.var,_,re,Oe)}assign(_,re,Oe){return this._leafNode(new c(_,re,Oe))}add(_,re){return this._leafNode(new v(_,n.operators.ADD,re))}code(_){return typeof _=="function"?_():_!==o.nil&&this._leafNode(new I(_)),this}object(..._){const re=["{"];for(const[Oe,Ne]of _)re.length>1&&re.push(","),re.push(Oe),(Oe!==Ne||this.opts.es5)&&(re.push(":"),(0,o.addCodeArg)(re,Ne));return re.push("}"),new o._Code(re)}if(_,re,Oe){if(this._blockNode(new l(_)),re&&Oe)this.code(re).else().code(Oe).endIf();else if(re)this.code(re).endIf();else if(Oe)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(_){return this._elseNode(new l(_))}else(){return this._elseNode(new a)}endIf(){return this._endBlockNode(l,a)}_for(_,re){return this._blockNode(_),re&&this.code(re).endFor(),this}for(_,re){return this._for(new b(_),re)}forRange(_,re,Oe,Ne,ke=this.opts.es5?h.varKinds.var:h.varKinds.let){const ct=this._scope.toName(_);return this._for(new R(ke,ct,re,Oe),()=>Ne(ct))}forOf(_,re,Oe,Ne=h.varKinds.const){const ke=this._scope.toName(_);if(this.opts.es5){const ct=re instanceof o.Name?re:this.var("_arr",re);return this.forRange("_i",0,(0,o._)`${ct}.length`,it=>{this.var(ke,(0,o._)`${ct}[${it}]`),Oe(ke)})}return this._for(new D("of",Ne,ke,re),()=>Oe(ke))}forIn(_,re,Oe,Ne=this.opts.es5?h.varKinds.var:h.varKinds.const){if(this.opts.ownProperties)return this.forOf(_,(0,o._)`Object.keys(${re})`,Oe);const ke=this._scope.toName(_);return this._for(new D("in",Ne,ke,re),()=>Oe(ke))}endFor(){return this._endBlockNode(M)}label(_){return this._leafNode(new g(_))}break(_){return this._leafNode(new x(_))}return(_){const re=new j;if(this._blockNode(re),this.code(_),re.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(j)}try(_,re,Oe){if(!re&&!Oe)throw new Error('CodeGen: "try" without "catch" and "finally"');const Ne=new $;if(this._blockNode(Ne),this.code(_),re){const ke=this.name("e");this._currNode=Ne.catch=new w(ke),re(ke)}return Oe&&(this._currNode=Ne.finally=new V,this.code(Oe)),this._endBlockNode(w,V)}throw(_){return this._leafNode(new y(_))}block(_,re){return this._blockStarts.push(this._nodes.length),_&&this.code(_).endBlock(re),this}endBlock(_){const re=this._blockStarts.pop();if(re===void 0)throw new Error("CodeGen: not in self-balancing block");const Oe=this._nodes.length-re;if(Oe<0||_!==void 0&&Oe!==_)throw new Error(`CodeGen: wrong number of nodes: ${Oe} vs ${_} expected`);return this._nodes.length=re,this}func(_,re=o.nil,Oe,Ne){return this._blockNode(new B(_,re,Oe)),Ne&&this.code(Ne).endFunc(),this}endFunc(){return this._endBlockNode(B)}optimize(_=1){for(;_-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(_){return this._currNode.nodes.push(_),this}_blockNode(_){this._currNode.nodes.push(_),this._nodes.push(_)}_endBlockNode(_,re){const Oe=this._currNode;if(Oe instanceof _||re&&Oe instanceof re)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${re?`${_.kind}/${re.kind}`:_.kind}"`)}_elseNode(_){const re=this._currNode;if(!(re instanceof l))throw new Error('CodeGen: "else" without "if"');return this._currNode=re.else=_,this}get _root(){return this._nodes[0]}get _currNode(){const _=this._nodes;return _[_.length-1]}set _currNode(_){const re=this._nodes;re[re.length-1]=_}}n.CodeGen=X;function J(ie,_){for(const re in _)ie[re]=(ie[re]||0)+(_[re]||0);return ie}function Q(ie,_){return _ instanceof o._CodeOrName?J(ie,_.names):ie}function N(ie,_,re){if(ie instanceof o.Name)return Oe(ie);if(!Ne(ie))return ie;return new o._Code(ie._items.reduce((ke,ct)=>(ct instanceof o.Name&&(ct=Oe(ct)),ct instanceof o._Code?ke.push(...ct._items):ke.push(ct),ke),[]));function Oe(ke){const ct=re[ke.str];return ct===void 0||_[ke.str]!==1?ke:(delete _[ke.str],ct)}function Ne(ke){return ke instanceof o._Code&&ke._items.some(ct=>ct instanceof o.Name&&_[ct.str]===1&&re[ct.str]!==void 0)}}function ue(ie,_){for(const re in _)ie[re]=(ie[re]||0)-(_[re]||0)}function Ee(ie){return typeof ie=="boolean"||typeof ie=="number"||ie===null?!ie:(0,o._)`!${Z(ie)}`}const de=K(n.operators.AND);function je(...ie){return ie.reduce(de)}const pe=K(n.operators.OR);function ce(...ie){return ie.reduce(pe)}function K(ie){return(_,re)=>_===o.nil?re:re===o.nil?_:(0,o._)`${Z(_)} ${ie} ${Z(re)}`}function Z(ie){return ie instanceof o.Name?ie:(0,o._)`(${ie})`}},34863:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.ValueScope=n.ValueScopeName=n.Scope=n.varKinds=n.UsedValueState=void 0;const o=e(76202);class h extends Error{constructor(g){super(`CodeGen: "code" for ${g} not defined`),this.value=g.value}}var f;(function(v){v[v.Started=0]="Started",v[v.Completed=1]="Completed"})(f||(n.UsedValueState=f={})),n.varKinds={const:new o.Name("const"),let:new o.Name("let"),var:new o.Name("var")};class O{constructor({prefixes:g,parent:x}={}){this._names={},this._prefixes=g,this._parent=x}toName(g){return g instanceof o.Name?g:this.name(g)}name(g){return new o.Name(this._newName(g))}_newName(g){const x=this._names[g]||this._nameGroup(g);return`${g}${x.index++}`}_nameGroup(g){var x,y;if(!((y=(x=this._parent)===null||x===void 0?void 0:x._prefixes)===null||y===void 0)&&y.has(g)||this._prefixes&&!this._prefixes.has(g))throw new Error(`CodeGen: prefix "${g}" is not allowed in this scope`);return this._names[g]={prefix:g,index:0}}}n.Scope=O;class d extends o.Name{constructor(g,x){super(x),this.prefix=g}setValue(g,{property:x,itemIndex:y}){this.value=g,this.scopePath=(0,o._)`.${new o.Name(x)}[${y}]`}}n.ValueScopeName=d;const p=(0,o._)`\n`;class c extends O{constructor(g){super(g),this._values={},this._scope=g.scope,this.opts={...g,_n:g.lines?p:o.nil}}get(){return this._scope}name(g){return new d(g,this._newName(g))}value(g,x){var y;if(x.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const I=this.toName(g),{prefix:E}=I,S=(y=x.key)!==null&&y!==void 0?y:x.ref;let t=this._values[E];if(t){const M=t.get(S);if(M)return M}else t=this._values[E]=new Map;t.set(S,I);const a=this._scope[E]||(this._scope[E]=[]),l=a.length;return a[l]=x.ref,I.setValue(x,{property:E,itemIndex:l}),I}getValue(g,x){const y=this._values[g];if(y)return y.get(x)}scopeRefs(g,x=this._values){return this._reduceValues(x,y=>{if(y.scopePath===void 0)throw new Error(`CodeGen: name "${y}" has no value`);return(0,o._)`${g}${y.scopePath}`})}scopeCode(g=this._values,x,y){return this._reduceValues(g,I=>{if(I.value===void 0)throw new Error(`CodeGen: name "${I}" has no value`);return I.value.code},x,y)}_reduceValues(g,x,y={},I){let E=o.nil;for(const S in g){const t=g[S];if(!t)continue;const a=y[S]=y[S]||new Map;t.forEach(l=>{if(a.has(l))return;a.set(l,f.Started);let M=x(l);if(M){const b=this.opts.es5?n.varKinds.var:n.varKinds.const;E=(0,o._)`${E}${b} ${l} = ${M};${this.opts._n}`}else if(M=I?.(l))E=(0,o._)`${E}${M}${this.opts._n}`;else throw new h(l);a.set(l,f.Completed)})}return E}}n.ValueScope=c},39054:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.keyword$DataError=n.keywordError=void 0,n.reportError=O,n.reportExtraError=d,n.resetErrorsCount=p,n.extendErrors=c;const o=e(57287),h=e(977),f=e(5057);n.keywordError={message:({keyword:a})=>(0,o.str)`must pass "${a}" keyword validation`},n.keyword$DataError={message:({keyword:a,schemaType:l})=>l?(0,o.str)`"${a}" keyword must be ${l} ($data)`:(0,o.str)`"${a}" keyword is invalid ($data)`};function O(a,l=n.keywordError,M,b){const{it:R}=a,{gen:D,compositeRule:B,allErrors:j}=R,$=y(a,l,M);b??(B||j)?v(D,$):g(R,(0,o._)`[${$}]`)}function d(a,l=n.keywordError,M){const{it:b}=a,{gen:R,compositeRule:D,allErrors:B}=b,j=y(a,l,M);v(R,j),D||B||g(b,f.default.vErrors)}function p(a,l){a.assign(f.default.errors,l),a.if((0,o._)`${f.default.vErrors} !== null`,()=>a.if(l,()=>a.assign((0,o._)`${f.default.vErrors}.length`,l),()=>a.assign(f.default.vErrors,null)))}function c({gen:a,keyword:l,schemaValue:M,data:b,errsCount:R,it:D}){if(R===void 0)throw new Error("ajv implementation error");const B=a.name("err");a.forRange("i",R,f.default.errors,j=>{a.const(B,(0,o._)`${f.default.vErrors}[${j}]`),a.if((0,o._)`${B}.instancePath === undefined`,()=>a.assign((0,o._)`${B}.instancePath`,(0,o.strConcat)(f.default.instancePath,D.errorPath))),a.assign((0,o._)`${B}.schemaPath`,(0,o.str)`${D.errSchemaPath}/${l}`),D.opts.verbose&&(a.assign((0,o._)`${B}.schema`,M),a.assign((0,o._)`${B}.data`,b))})}function v(a,l){const M=a.const("err",l);a.if((0,o._)`${f.default.vErrors} === null`,()=>a.assign(f.default.vErrors,(0,o._)`[${M}]`),(0,o._)`${f.default.vErrors}.push(${M})`),a.code((0,o._)`${f.default.errors}++`)}function g(a,l){const{gen:M,validateName:b,schemaEnv:R}=a;R.$async?M.throw((0,o._)`new ${a.ValidationError}(${l})`):(M.assign((0,o._)`${b}.errors`,l),M.return(!1))}const x={keyword:new o.Name("keyword"),schemaPath:new o.Name("schemaPath"),params:new o.Name("params"),propertyName:new o.Name("propertyName"),message:new o.Name("message"),schema:new o.Name("schema"),parentSchema:new o.Name("parentSchema")};function y(a,l,M){const{createErrors:b}=a.it;return b===!1?(0,o._)`{}`:I(a,l,M)}function I(a,l,M={}){const{gen:b,it:R}=a,D=[E(R,M),S(a,M)];return t(a,l,D),b.object(...D)}function E({errorPath:a},{instancePath:l}){const M=l?(0,o.str)`${a}${(0,h.getErrorPath)(l,h.Type.Str)}`:a;return[f.default.instancePath,(0,o.strConcat)(f.default.instancePath,M)]}function S({keyword:a,it:{errSchemaPath:l}},{schemaPath:M,parentSchema:b}){let R=b?l:(0,o.str)`${l}/${a}`;return M&&(R=(0,o.str)`${R}${(0,h.getErrorPath)(M,h.Type.Str)}`),[x.schemaPath,R]}function t(a,{params:l,message:M},b){const{keyword:R,data:D,schemaValue:B,it:j}=a,{opts:$,propertyName:w,topSchemaRef:V,schemaPath:X}=j;b.push([x.keyword,R],[x.params,typeof l=="function"?l(a):l||(0,o._)`{}`]),$.messages&&b.push([x.message,typeof M=="function"?M(a):M]),$.verbose&&b.push([x.schema,B],[x.parentSchema,(0,o._)`${V}${X}`],[f.default.data,D]),w&&b.push([x.propertyName,w])}},65545:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.SchemaEnv=void 0,n.compileSchema=v,n.resolveRef=g,n.getCompilingSchema=y,n.resolveSchema=S;const o=e(57287),h=e(84012),f=e(5057),O=e(95421),d=e(977),p=e(9804);class c{constructor(M){var b;this.refs={},this.dynamicAnchors={};let R;typeof M.schema=="object"&&(R=M.schema),this.schema=M.schema,this.schemaId=M.schemaId,this.root=M.root||this,this.baseId=(b=M.baseId)!==null&&b!==void 0?b:(0,O.normalizeId)(R?.[M.schemaId||"$id"]),this.schemaPath=M.schemaPath,this.localRefs=M.localRefs,this.meta=M.meta,this.$async=R?.$async,this.refs={}}}n.SchemaEnv=c;function v(l){const M=y.call(this,l);if(M)return M;const b=(0,O.getFullPath)(this.opts.uriResolver,l.root.baseId),{es5:R,lines:D}=this.opts.code,{ownProperties:B}=this.opts,j=new o.CodeGen(this.scope,{es5:R,lines:D,ownProperties:B});let $;l.$async&&($=j.scopeValue("Error",{ref:h.default,code:(0,o._)`require("ajv/dist/runtime/validation_error").default`}));const w=j.scopeName("validate");l.validateName=w;const V={gen:j,allErrors:this.opts.allErrors,data:f.default.data,parentData:f.default.parentData,parentDataProperty:f.default.parentDataProperty,dataNames:[f.default.data],dataPathArr:[o.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:j.scopeValue("schema",this.opts.code.source===!0?{ref:l.schema,code:(0,o.stringify)(l.schema)}:{ref:l.schema}),validateName:w,ValidationError:$,schema:l.schema,schemaEnv:l,rootId:b,baseId:l.baseId||b,schemaPath:o.nil,errSchemaPath:l.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,o._)`""`,opts:this.opts,self:this};let X;try{this._compilations.add(l),(0,p.validateFunctionCode)(V),j.optimize(this.opts.code.optimize);const J=j.toString();X=`const visitedNodesForRef = new WeakMap(); ${j.scopeRefs(f.default.scope)}return ${J}`,this.opts.code.process&&(X=this.opts.code.process(X,l));const N=new Function(`${f.default.self}`,`${f.default.scope}`,X)(this,this.scope.get());if(this.scope.value(w,{ref:N}),N.errors=null,N.schema=l.schema,N.schemaEnv=l,l.$async&&(N.$async=!0),this.opts.code.source===!0&&(N.source={validateName:w,validateCode:J,scopeValues:j._values}),this.opts.unevaluated){const{props:ue,items:Ee}=V;N.evaluated={props:ue instanceof o.Name?void 0:ue,items:Ee instanceof o.Name?void 0:Ee,dynamicProps:ue instanceof o.Name,dynamicItems:Ee instanceof o.Name},N.source&&(N.source.evaluated=(0,o.stringify)(N.evaluated))}return l.validate=N,l}catch(J){throw delete l.validate,delete l.validateName,X&&this.logger.error("Error compiling schema, function code:",X),J}finally{this._compilations.delete(l)}}function g(l,M,b){var R;const D=(0,O.resolveUrl)(this.opts.uriResolver,M,b),B=l.refs[D];if(B)return B;let j=E.call(this,l,D);if(j===void 0){const $=(R=l.localRefs)===null||R===void 0?void 0:R[D],{schemaId:w}=this.opts;$&&(j=new c({schema:$,schemaId:w,root:l,baseId:M}))}if(j===void 0&&this.opts.loadSchemaSync){const $=this.opts.loadSchemaSync(M,b,D);$&&!(this.refs[D]||this.schemas[D])&&(this.addSchema($,D,void 0),j=E.call(this,l,D))}if(j!==void 0)return l.refs[D]=x.call(this,j)}function x(l){return(0,O.inlineRef)(l.schema,this.opts.inlineRefs)?l.schema:l.validate?l:v.call(this,l)}function y(l){for(const M of this._compilations)if(I(M,l))return M}function I(l,M){return l.schema===M.schema&&l.root===M.root&&l.baseId===M.baseId}function E(l,M){let b;for(;typeof(b=this.refs[M])=="string";)M=b;return b||this.schemas[M]||S.call(this,l,M)}function S(l,M){const b=this.opts.uriResolver.parse(M),R=(0,O._getFullPath)(this.opts.uriResolver,b);let D=(0,O.getFullPath)(this.opts.uriResolver,l.baseId,void 0);if(Object.keys(l.schema).length>0&&R===D)return a.call(this,b,l);const B=(0,O.normalizeId)(R),j=this.refs[B]||this.schemas[B];if(typeof j=="string"){const $=S.call(this,l,j);return typeof $?.schema!="object"?void 0:a.call(this,b,$)}if(typeof j?.schema=="object"){if(j.validate||v.call(this,j),B===(0,O.normalizeId)(M)){const{schema:$}=j,{schemaId:w}=this.opts,V=$[w];return V&&(D=(0,O.resolveUrl)(this.opts.uriResolver,D,V)),new c({schema:$,schemaId:w,root:l,baseId:D})}return a.call(this,b,j)}}const t=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function a(l,{baseId:M,schema:b,root:R}){var D;if(((D=l.fragment)===null||D===void 0?void 0:D[0])!=="/")return;for(const $ of l.fragment.slice(1).split("/")){if(typeof b=="boolean")return;const w=b[(0,d.unescapeFragment)($)];if(w===void 0)return;b=w;const V=typeof b=="object"&&b[this.opts.schemaId];!t.has($)&&V&&(M=(0,O.resolveUrl)(this.opts.uriResolver,M,V))}let B;if(typeof b!="boolean"&&b.$ref&&!(0,d.schemaHasRulesButRef)(b,this.RULES)){const $=(0,O.resolveUrl)(this.opts.uriResolver,M,b.$ref);B=S.call(this,R,$)}const{schemaId:j}=this.opts;if(B=B||new c({schema:b,schemaId:j,root:R,baseId:M}),B.schema!==B.root.schema)return B}},5057:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});const o=e(57287),h={data:new o.Name("data"),valCxt:new o.Name("valCxt"),instancePath:new o.Name("instancePath"),parentData:new o.Name("parentData"),parentDataProperty:new o.Name("parentDataProperty"),rootData:new o.Name("rootData"),dynamicAnchors:new o.Name("dynamicAnchors"),isAllOfVariant:new o.Name("isAllOfVariant"),vErrors:new o.Name("vErrors"),errors:new o.Name("errors"),this:new o.Name("this"),self:new o.Name("self"),scope:new o.Name("scope"),json:new o.Name("json"),jsonPos:new o.Name("jsonPos"),jsonLen:new o.Name("jsonLen"),jsonPart:new o.Name("jsonPart")};n.default=h},78805:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});const o=e(95421);class h extends Error{constructor(O,d,p,c){super(c||`can't resolve reference ${p} from id ${d}`),this.missingRef=(0,o.resolveUrl)(O,d,p),this.missingSchema=(0,o.normalizeId)((0,o.getFullPath)(O,this.missingRef))}}n.default=h},95421:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.inlineRef=d,n.getFullPath=g,n._getFullPath=x,n.normalizeId=I,n.resolveUrl=E,n.getSchemaRefs=t;const o=e(977),h=e(67371),f=e(50205),O=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function d(a,l=!0){return typeof a=="boolean"?!0:l===!0?!c(a):l?v(a)<=l:!1}const p=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function c(a){for(const l in a){if(p.has(l))return!0;const M=a[l];if(Array.isArray(M)&&M.some(c)||typeof M=="object"&&c(M))return!0}return!1}function v(a){let l=0;for(const M in a){if(M==="$ref")return 1/0;if(l++,!O.has(M)&&(typeof a[M]=="object"&&(0,o.eachItem)(a[M],b=>l+=v(b)),l===1/0))return 1/0}return l}function g(a,l="",M){M!==!1&&(l=I(l));const b=a.parse(l);return x(a,b)}function x(a,l){return a.serialize(l).split("#")[0]+"#"}const y=/#\/?$/;function I(a){return a?a.replace(y,""):""}function E(a,l,M){return M=I(M),a.resolve(l,M)}const S=/^[a-z_][-a-z0-9._]*$/i;function t(a,l){if(typeof a=="boolean")return{};const{schemaId:M,uriResolver:b}=this.opts,R=I(a[M]||l),D={"":R},B=g(b,R,!1),j={},$=new Set;return f(a,{allKeys:!0},(X,J,Q,N)=>{if(N===void 0)return;const ue=B+J;let Ee=D[N];typeof X[M]=="string"&&(Ee=de.call(this,X[M])),je.call(this,X.$anchor),je.call(this,X.$dynamicAnchor),D[J]=Ee;function de(pe){const ce=this.opts.uriResolver.resolve;if(pe=I(Ee?ce(Ee,pe):pe),$.has(pe))throw V(pe);$.add(pe);let K=this.refs[pe];return typeof K=="string"&&(K=this.refs[K]),typeof K=="object"?w(X,K.schema,pe):pe!==I(ue)&&(pe[0]==="#"?(w(X,j[pe],pe),j[pe]=X):this.refs[pe]=ue),pe}function je(pe){if(typeof pe=="string"){if(!S.test(pe))throw new Error(`invalid anchor "${pe}"`);de.call(this,`#${pe}`)}}}),j;function w(X,J,Q){if(J!==void 0&&!h(X,J))throw V(Q)}function V(X){return new Error(`reference "${X}" resolves to more than one schema`)}}},90942:(P,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.isJSONType=h,n.getRules=f;const e=["string","number","integer","boolean","null","object","array"],o=new Set(e);function h(O){return typeof O=="string"&&o.has(O)}function f(){const O={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...O,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},O.number,O.string,O.array,O.object],post:{rules:[]},all:{},keywords:{}}}},977:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Type=n.mergeEvaluated=void 0,n.toHash=f,n.alwaysValidSchema=O,n.checkUnknownRules=d,n.schemaHasRules=p,n.schemaHasRulesButRef=c,n.schemaRefOrVal=v,n.unescapeFragment=g,n.escapeFragment=x,n.escapeJsonPointer=y,n.unescapeJsonPointer=I,n.eachItem=E,n.evaluatedPropsToName=t,n.setEvaluated=a,n.useFunc=M,n.getErrorPath=R,n.checkStrictMode=D;const o=e(57287),h=e(76202);function f(B){const j={};for(const $ of B)j[$]=!0;return j}function O(B,j){return typeof j=="boolean"?j:Object.keys(j).length===0?!0:(d(B,j),!p(j,B.self.RULES.all))}function d(B,j=B.schema){const{opts:$,self:w}=B;if(!$.strictSchema||typeof j=="boolean")return;const V=w.RULES.keywords;for(const X in j)V[X]||D(B,`unknown keyword: "${X}"`)}function p(B,j){if(typeof B=="boolean")return!B;for(const $ in B)if(j[$])return!0;return!1}function c(B,j){if(typeof B=="boolean")return!B;for(const $ in B)if($!=="$ref"&&j.all[$])return!0;return!1}function v({topSchemaRef:B,schemaPath:j},$,w,V){if(!V){if(typeof $=="number"||typeof $=="boolean")return $;if(typeof $=="string")return(0,o._)`${$}`}return(0,o._)`${B}${j}${(0,o.getProperty)(w)}`}function g(B){return I(decodeURIComponent(B))}function x(B){return encodeURIComponent(y(B))}function y(B){return typeof B=="number"?`${B}`:B.replace(/~/g,"~0").replace(/\//g,"~1")}function I(B){return B.replace(/~1/g,"/").replace(/~0/g,"~")}function E(B,j){if(Array.isArray(B))for(const $ of B)j($);else j(B)}function S({mergeNames:B,mergeToName:j,mergeValues:$,resultToName:w}){return(V,X,J,Q)=>{const N=J===void 0?X:J instanceof o.Name?(X instanceof o.Name?B(V,X,J):j(V,X,J),J):X instanceof o.Name?(j(V,J,X),X):$(X,J);return Q===o.Name&&!(N instanceof o.Name)?w(V,N):N}}n.mergeEvaluated={props:S({mergeNames:(B,j,$)=>B.if((0,o._)`${$} !== true && ${j} !== undefined`,()=>{B.if((0,o._)`${j} === true`,()=>B.assign($,!0),()=>B.assign($,(0,o._)`${$} || {}`).code((0,o._)`Object.assign(${$}, ${j})`))}),mergeToName:(B,j,$)=>B.if((0,o._)`${$} !== true`,()=>{j===!0?B.assign($,!0):(B.assign($,(0,o._)`${$} || {}`),a(B,$,j))}),mergeValues:(B,j)=>B===!0?!0:{...B,...j},resultToName:t}),items:S({mergeNames:(B,j,$)=>B.if((0,o._)`${$} !== true && ${j} !== undefined`,()=>B.assign($,(0,o._)`${j} === true ? true : ${$} > ${j} ? ${$} : ${j}`)),mergeToName:(B,j,$)=>B.if((0,o._)`${$} !== true`,()=>B.assign($,j===!0?!0:(0,o._)`${$} > ${j} ? ${$} : ${j}`)),mergeValues:(B,j)=>B===!0?!0:Math.max(B,j),resultToName:(B,j)=>B.var("items",j)})};function t(B,j){if(j===!0)return B.var("props",!0);const $=B.var("props",(0,o._)`{}`);return j!==void 0&&a(B,$,j),$}function a(B,j,$){Object.keys($).forEach(w=>B.assign((0,o._)`${j}${(0,o.getProperty)(w)}`,!0))}const l={};function M(B,j){return B.scopeValue("func",{ref:j,code:l[j.code]||(l[j.code]=new h._Code(j.code))})}var b;(function(B){B[B.Num=0]="Num",B[B.Str=1]="Str"})(b||(n.Type=b={}));function R(B,j,$){if(B instanceof o.Name){const w=j===b.Num;return $?w?(0,o._)`"[" + ${B} + "]"`:(0,o._)`"['" + ${B} + "']"`:w?(0,o._)`"/" + ${B}`:(0,o._)`"/" + ${B}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return $?(0,o.getProperty)(B).toString():"/"+y(B)}function D(B,j,$=B.opts.strictSchema){if($){if(j=`strict mode: ${j}`,$===!0)throw new Error(j);B.self.logger.warn(j)}}},5413:(P,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.schemaHasRulesForType=e,n.shouldUseGroup=o,n.shouldUseRule=h;function e({schema:f,self:O},d){const p=O.RULES.types[d];return p&&p!==!0&&o(f,p)}function o(f,O){return O.rules.some(d=>h(f,d))}function h(f,O){var d;return f[O.keyword]!==void 0||((d=O.definition.implements)===null||d===void 0?void 0:d.some(p=>f[p]!==void 0))}},98213:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.topBoolOrEmptySchema=d,n.boolOrEmptySchema=p;const o=e(39054),h=e(57287),f=e(5057),O={message:"boolean schema is false"};function d(v){const{gen:g,schema:x,validateName:y}=v;x===!1?c(v,!1):typeof x=="object"&&x.$async===!0?g.return(f.default.data):(g.assign((0,h._)`${y}.errors`,null),g.return(!0))}function p(v,g){const{gen:x,schema:y}=v;y===!1?(x.var(g,!1),c(v)):x.var(g,!0)}function c(v,g){const{gen:x,data:y}=v,I={gen:x,keyword:"false schema",data:y,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:v};(0,o.reportError)(I,O,void 0,g)}},41434:(P,n,e)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.DataType=void 0,n.getSchemaTypes=c,n.getJSONTypes=v,n.coerceAndCheckDataType=g,n.checkDataType=S,n.checkDataTypes=t,n.reportTypeError=l;const o=e(90942),h=e(5413),f=e(39054),O=e(57287),d=e(977);var p;(function(b){b[b.Correct=0]="Correct",b[b.Wrong=1]="Wrong"})(p||(n.DataType=p={}));function c(b){const R=v(b.type);if(R.includes("null")){if(b.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!R.length&&b.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');b.nullable===!0&&R.push("null")}return R}function v(b){const R=Array.isArray(b)?b:b?[b]:[];if(R.every(o.isJSONType))return R;throw new Error("type must be JSONType or JSONType[]: "+R.join(","))}function g(b,R){const{gen:D,data:B,opts:j}=b,$=y(R,j.coerceTypes),w=R.length>0&&!($.length===0&&R.length===1&&(0,h.schemaHasRulesForType)(b,R[0]));if(w){const V=t(R,B,j.strictNumbers,p.Wrong);D.if(V,()=>{$.length?I(b,R,$):l(b)})}return w}const x=new Set(["string","number","integer","boolean","null"]);function y(b,R){return R?b.filter(D=>x.has(D)||R==="array"&&D==="array"):[]}function I(b,R,D){const{gen:B,data:j,opts:$}=b,w=B.let("dataType",(0,O._)`typeof ${j}`),V=B.let("coerced",(0,O._)`undefined`);$.coerceTypes==="array"&&B.if((0,O._)`${w} == 'object' && Array.isArray(${j}) && ${j}.length == 1`,()=>B.assign(j,(0,O._)`${j}[0]`).assign(w,(0,O._)`typeof ${j}`).if(t(R,j,$.strictNumbers),()=>B.assign(V,j))),B.if((0,O._)`${V} !== undefined`);for(const J of D)(x.has(J)||J==="array"&&$.coerceTypes==="array")&&X(J);B.else(),l(b),B.endIf(),B.if((0,O._)`${V} !== undefined`,()=>{B.assign(j,V),E(b,V)});function X(J){switch(J){case"string":B.elseIf((0,O._)`${w} == "number" || ${w} == "boolean"`).assign(V,(0,O._)`"" + ${j}`).elseIf((0,O._)`${j} === null`).assign(V,(0,O._)`""`);return;case"number":B.elseIf((0,O._)`${w} == "boolean" || ${j} === null
|
|
8
8
|
|| (${w} == "string" && ${j} && ${j} == +${j})`).assign(V,(0,O._)`+${j}`);return;case"integer":B.elseIf((0,O._)`${w} === "boolean" || ${j} === null
|
|
@@ -12271,4 +12271,4 @@ Error generating stack: `+xe.message+`
|
|
|
12271
12271
|
`,Ay=({pointer:A,schema:L})=>{const{options:F,parser:ne}=useAtomValue(globalStoreAtom),ye=L||{$ref:A},Be=getSchema({parser:ne,schemaOrRef:ye,pointer:A||"",options:F,deps:{operation:{pointer:"RedocSchema"}}});return jsx(Row,{children:jsx(FullWidthPanel,{children:jsx(Schema,{schema:Be,level:1,disableDeepLinks:!0})})})},Dy=({pointer:A,mimeType:L,encoding:F})=>{const ne=useAtomValue(globalParserAtom),ye=useAtomValue(layoutAtom),Be=getExamples({parser:ne,infoOrRef:{$ref:A},mime:L,encoding:F});return jsx(Row,{layout:ye,children:jsx(ExamplesWrap,{children:jsx(Example,{example:Be,mimeType:L})})})},ey=oe.Ay.div`
|
|
12272
12272
|
padding: 20px;
|
|
12273
12273
|
color: red;
|
|
12274
|
-
`;class jy extends t.Component{constructor(L){super(L),this.state={error:void 0}}componentDidCatch(L){return this.setState({error:L}),!1}render(){return this.state.error?(0,P.jsxs)(ey,{children:[(0,P.jsx)("h1",{children:"Something went wrong..."}),(0,P.jsxs)("small",{children:[" ",this.state.error.message," "]}),(0,P.jsx)("p",{children:(0,P.jsxs)("details",{children:[(0,P.jsx)("summary",{children:"Stack trace"}),(0,P.jsx)("pre",{children:this.state.error.stack})]})}),typeof __REDOC_VERSION__<"u"?(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)("small",{children:[" References docs version: ",__REDOC_VERSION__]})," ",(0,P.jsx)("br",{})]}):null,typeof __REDOC_REVISION__<"u"?(0,P.jsxs)("small",{children:[" Commit: ",__REDOC_REVISION__]}):null]}):(0,P.jsx)(P.Fragment,{children:t.Children.only(this.props.children)})}}var ty=Object.defineProperty,$h=Object.getOwnPropertySymbols,ny=Object.prototype.hasOwnProperty,ry=Object.prototype.propertyIsEnumerable,Uh=(A,L,F)=>L in A?ty(A,L,{enumerable:!0,configurable:!0,writable:!0,value:F}):A[L]=F,Wh=(A,L)=>{for(var F in L||(L={}))ny.call(L,F)&&Uh(A,F,L[F]);if($h)for(var F of $h(L))ry.call(L,F)&&Uh(A,F,L[F]);return A};const zh=(0,M.JA)(),oy=zh?(0,S.dirname)(zh)+"/":"";function iy(A){const L={},F=A.attributes;for(let ne=0;ne<F.length;ne++){const ye=F[ne];L[ye.name]=ye.value}return L}function ay(A){const L=iy(A),F={};for(const ne in L){const ye=ne.replace(/-(.)/g,(Be,rt)=>rt.toUpperCase());F[ye]=L[ne]}return F}function sy(A,L=document.querySelector("redoc")){(0,a.c)(L,(0,P.jsx)(Nh,{store:A}))}function Hh(A,L={},F=(0,M.iT)("redoc")){if(F===null)throw new Error('"element" argument is not provided and <redoc> tag is not found on the page');let ne,ye;typeof A=="string"?ne=A:typeof A=="object"&&(ye=A),(0,a.H)(F).render((0,t.createElement)(qv,{definition:ye,definitionUrl:ne,options:Wh(Wh({},L),ay(F))},["Loading..."]))}function Vh(A){$r.p=A}const ly="3.
|
|
12274
|
+
`;class jy extends t.Component{constructor(L){super(L),this.state={error:void 0}}componentDidCatch(L){return this.setState({error:L}),!1}render(){return this.state.error?(0,P.jsxs)(ey,{children:[(0,P.jsx)("h1",{children:"Something went wrong..."}),(0,P.jsxs)("small",{children:[" ",this.state.error.message," "]}),(0,P.jsx)("p",{children:(0,P.jsxs)("details",{children:[(0,P.jsx)("summary",{children:"Stack trace"}),(0,P.jsx)("pre",{children:this.state.error.stack})]})}),typeof __REDOC_VERSION__<"u"?(0,P.jsxs)(P.Fragment,{children:[(0,P.jsxs)("small",{children:[" References docs version: ",__REDOC_VERSION__]})," ",(0,P.jsx)("br",{})]}):null,typeof __REDOC_REVISION__<"u"?(0,P.jsxs)("small",{children:[" Commit: ",__REDOC_REVISION__]}):null]}):(0,P.jsx)(P.Fragment,{children:t.Children.only(this.props.children)})}}var ty=Object.defineProperty,$h=Object.getOwnPropertySymbols,ny=Object.prototype.hasOwnProperty,ry=Object.prototype.propertyIsEnumerable,Uh=(A,L,F)=>L in A?ty(A,L,{enumerable:!0,configurable:!0,writable:!0,value:F}):A[L]=F,Wh=(A,L)=>{for(var F in L||(L={}))ny.call(L,F)&&Uh(A,F,L[F]);if($h)for(var F of $h(L))ry.call(L,F)&&Uh(A,F,L[F]);return A};const zh=(0,M.JA)(),oy=zh?(0,S.dirname)(zh)+"/":"";function iy(A){const L={},F=A.attributes;for(let ne=0;ne<F.length;ne++){const ye=F[ne];L[ye.name]=ye.value}return L}function ay(A){const L=iy(A),F={};for(const ne in L){const ye=ne.replace(/-(.)/g,(Be,rt)=>rt.toUpperCase());F[ye]=L[ne]}return F}function sy(A,L=document.querySelector("redoc")){(0,a.c)(L,(0,P.jsx)(Nh,{store:A}))}function Hh(A,L={},F=(0,M.iT)("redoc")){if(F===null)throw new Error('"element" argument is not provided and <redoc> tag is not found on the page');let ne,ye;typeof A=="string"?ne=A:typeof A=="object"&&(ye=A),(0,a.H)(F).render((0,t.createElement)(qv,{definition:ye,definitionUrl:ne,options:Wh(Wh({},L),ay(F))},["Loading..."]))}function Vh(A){$r.p=A}const ly="3.9.0-next.0",cy="28cd138";function uy(){const A=(0,M.iT)("redoc");if(!A)return;const L=A.getAttribute("spec-url");L&&Hh(L,{},A)}l.IS_BROWSER&&Vh(oy),uy()})(),If})());
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@redocly/openapi-docs",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.9.0-next.0",
|
|
4
4
|
"description": "Redocly OpenAPI Docs",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib-esm/index.js",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"openapi-docs": "bin.js"
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"@redocly/theme": ">=0.
|
|
19
|
+
"@redocly/theme": ">=0.53.0-next.0",
|
|
20
20
|
"core-js": "^3.1.4",
|
|
21
21
|
"react": "^18.0.0",
|
|
22
22
|
"react-dom": "^18.0.0",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"util": "~0.12.5",
|
|
45
45
|
"web-vitals": "3.3.1",
|
|
46
46
|
"@redocly/config": "0.23.0",
|
|
47
|
-
"@redocly/replay": "0.
|
|
47
|
+
"@redocly/replay": "0.12.0-next.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@shikijs/transformers": "1.24.0",
|
|
@@ -92,7 +92,7 @@
|
|
|
92
92
|
"webpack": "5.94.0",
|
|
93
93
|
"webpack-cli": "5.1.4",
|
|
94
94
|
"webpack-dev-server": "5.1.0",
|
|
95
|
-
"@redocly/theme": "0.
|
|
95
|
+
"@redocly/theme": "0.53.0-next.0"
|
|
96
96
|
},
|
|
97
97
|
"scripts": {
|
|
98
98
|
"start": "npm run copy-highlight-hook && webpack serve --mode=development --hot",
|