@tachybase/plugin-devtools 0.23.41 → 0.23.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/client/index.js
CHANGED
|
@@ -201,7 +201,7 @@ new Remarkable().use(linkify)
|
|
|
201
201
|
`)}(0,JSON.stringify(u,null,2))||"{}",p.createElement("br",null)))}}const L7=D7,$7=({servers:t,currentServer:e,setSelectedServer:r,setServerVariableValue:n,getServerVariable:a,getEffectiveServerValue:o})=>{const u=(t.find(x=>x.get("url")===e)||(0,ce.OrderedMap)()).get("variables")||(0,ce.OrderedMap)(),c=u.size!==0;(0,p.useEffect)(()=>{var x;e||r((x=t.first())==null?void 0:x.get("url"))},[]),(0,p.useEffect)(()=>{const x=t.find(A=>A.get("url")===e);if(!x)return void r(t.first().get("url"));(x.get("variables")||(0,ce.OrderedMap)()).map((A,T)=>{n({server:e,key:T,val:A.get("default")||""})})},[e,t]);const h=(0,p.useCallback)(x=>{r(x.target.value)},[r]),E=(0,p.useCallback)(x=>{const A=x.target.getAttribute("data-variable"),T=x.target.value;n({server:e,key:A,val:T})},[n,e]);return p.createElement("div",{className:"servers"},p.createElement("label",{htmlFor:"servers"},p.createElement("select",{onChange:h,value:e,id:"servers"},t.valueSeq().map(x=>p.createElement("option",{value:x.get("url"),key:x.get("url")},x.get("url"),x.get("description")&&` - ${x.get("description")}`)).toArray())),c&&p.createElement("div",null,p.createElement("div",{className:"computed-url"},"Computed URL:",p.createElement("code",null,o(e))),p.createElement("h4",null,"Server variables"),p.createElement("table",null,p.createElement("tbody",null,u.entrySeq().map(([x,A])=>p.createElement("tr",{key:x},p.createElement("td",null,x),p.createElement("td",null,A.get("enum")?p.createElement("select",{"data-variable":x,onChange:E},A.get("enum").map(T=>p.createElement("option",{selected:T===a(e,x),key:T,value:T},T))):p.createElement("input",{type:"text",value:a(e,x)||"",onChange:E,"data-variable":x}))))))))};class F7 extends p.Component{render(){const{specSelectors:e,oas3Selectors:r,oas3Actions:n,getComponent:a}=this.props,o=e.servers(),u=a("Servers");return o&&o.size?p.createElement("div",null,p.createElement("span",{className:"servers-title"},"Servers"),p.createElement(u,{servers:o,currentServer:r.selectedServer(),setSelectedServer:n.setSelectedServer,setServerVariableValue:n.setServerVariableValue,getServerVariable:r.serverVariableValue,getEffectiveServerValue:r.serverEffectiveValue})):null}}const B7=Function.prototype;class lx extends p.PureComponent{constructor(r,n){super(r,n);Ee(this,"applyDefaultValue",r=>{const{onChange:n,defaultValue:a}=r||this.props;return this.setState({value:a}),n(a)});Ee(this,"onChange",r=>{this.props.onChange(zt(r))});Ee(this,"onDomChange",r=>{const n=r.target.value;this.setState({value:n},()=>this.onChange(n))});this.state={value:zt(r.value)||r.defaultValue},r.onChange(r.value)}UNSAFE_componentWillReceiveProps(r){this.props.value!==r.value&&r.value!==this.state.value&&this.setState({value:zt(r.value)}),!r.value&&r.defaultValue&&this.state.value&&this.applyDefaultValue(r)}render(){let{getComponent:r,errors:n}=this.props,{value:a}=this.state,o=n.size>0;const u=r("TextArea");return p.createElement("div",{className:"body-param"},p.createElement(u,{className:cn()("body-param__text",{invalid:o}),title:n.size?n.join(", "):"",value:a,onChange:this.onDomChange}))}}Ee(lx,"defaultProps",{onChange:B7,userHasEditedBody:!1});class q7 extends p.Component{constructor(r,n){super(r,n);Ee(this,"onChange",r=>{let{onChange:n}=this.props,{value:a,name:o}=r.target,u=Object.assign({},this.state.value);o?u[o]=a:u=a,this.setState({value:u},()=>n(this.state))});let{name:a,schema:o}=this.props,u=this.getValue();this.state={name:a,schema:o,value:u}}getValue(){let{name:r,authorized:n}=this.props;return n&&n.getIn([r,"value"])}render(){let{schema:r,getComponent:n,errSelectors:a,name:o}=this.props;const u=n("Input"),c=n("Row"),h=n("Col"),E=n("authError"),x=n("Markdown",!0),A=n("JumpToPath",!0),T=(r.get("scheme")||"").toLowerCase();let R=this.getValue(),B=a.allErrors().filter(H=>H.get("authId")===o);if(T==="basic"){let H=R?R.get("username"):null;return p.createElement("div",null,p.createElement("h4",null,p.createElement("code",null,o||r.get("name"))," (http, Basic)",p.createElement(A,{path:["securityDefinitions",o]})),H&&p.createElement("h6",null,"Authorized"),p.createElement(c,null,p.createElement(x,{source:r.get("description")})),p.createElement(c,null,p.createElement("label",{htmlFor:"auth-basic-username"},"Username:"),H?p.createElement("code",null," ",H," "):p.createElement(h,null,p.createElement(u,{id:"auth-basic-username",type:"text",required:"required",name:"username","aria-label":"auth-basic-username",onChange:this.onChange,autoFocus:!0}))),p.createElement(c,null,p.createElement("label",{htmlFor:"auth-basic-password"},"Password:"),H?p.createElement("code",null," ****** "):p.createElement(h,null,p.createElement(u,{id:"auth-basic-password",autoComplete:"new-password",name:"password",type:"password","aria-label":"auth-basic-password",onChange:this.onChange}))),B.valueSeq().map((G,X)=>p.createElement(E,{error:G,key:X})))}return T==="bearer"?p.createElement("div",null,p.createElement("h4",null,p.createElement("code",null,o||r.get("name"))," (http, Bearer)",p.createElement(A,{path:["securityDefinitions",o]})),R&&p.createElement("h6",null,"Authorized"),p.createElement(c,null,p.createElement(x,{source:r.get("description")})),p.createElement(c,null,p.createElement("label",{htmlFor:"auth-bearer-value"},"Value:"),R?p.createElement("code",null," ****** "):p.createElement(h,null,p.createElement(u,{id:"auth-bearer-value",type:"text","aria-label":"auth-bearer-value",onChange:this.onChange,autoFocus:!0}))),B.valueSeq().map((H,G)=>p.createElement(E,{error:H,key:G}))):p.createElement("div",null,p.createElement("em",null,p.createElement("b",null,o)," HTTP authentication: unsupported scheme ",`'${T}'`))}}class z7 extends p.Component{constructor(){super(...arguments);Ee(this,"setSelectedServer",r=>{const{path:n,method:a}=this.props;return this.forceUpdate(),this.props.setSelectedServer(r,`${n}:${a}`)});Ee(this,"setServerVariableValue",r=>{const{path:n,method:a}=this.props;return this.forceUpdate(),this.props.setServerVariableValue(zr(lt({},r),{namespace:`${n}:${a}`}))});Ee(this,"getSelectedServer",()=>{const{path:r,method:n}=this.props;return this.props.getSelectedServer(`${r}:${n}`)});Ee(this,"getServerVariable",(r,n)=>{const{path:a,method:o}=this.props;return this.props.getServerVariable({namespace:`${a}:${o}`,server:r},n)});Ee(this,"getEffectiveServerValue",r=>{const{path:n,method:a}=this.props;return this.props.getEffectiveServerValue({server:r,namespace:`${n}:${a}`})})}render(){const{operationServers:r,pathServers:n,getComponent:a}=this.props;if(!r&&!n)return null;const o=a("Servers"),u=r||n,c=r?"operation":"path";return p.createElement("div",{className:"opblock-section operation-servers"},p.createElement("div",{className:"opblock-section-header"},p.createElement("div",{className:"tab-header"},p.createElement("h4",{className:"opblock-title"},"Servers"))),p.createElement("div",{className:"opblock-description-wrapper"},p.createElement("h4",{className:"message"},"These ",c,"-level options override the global server options."),p.createElement(o,{servers:u,currentServer:this.getSelectedServer(),setSelectedServer:this.setSelectedServer,setServerVariableValue:this.setServerVariableValue,getServerVariable:this.getServerVariable,getEffectiveServerValue:this.getEffectiveServerValue})))}}const U7={Callbacks:M7,HttpAuth:q7,RequestBody:R7,Servers:$7,ServersContainer:F7,RequestBodyEditor:lx,OperationServers:z7,operationLink:L7},G1=new $l("commonmark");G1.block.ruler.enable(["table"]),G1.set({linkTarget:"_blank"});const V7=Yf(({source:t,className:e="",getConfigs:r=()=>({useUnsafeMarkdown:!1})})=>{if(typeof t!="string")return null;if(t){const{useUnsafeMarkdown:n}=r(),a=Hf(G1.render(t),{useUnsafeMarkdown:n});let o;return typeof a=="string"&&(o=a.trim()),p.createElement("div",{dangerouslySetInnerHTML:{__html:o},className:cn()(e,"renderedMarkdown")})}return null}),W7=Yf(r=>{var n=r,{Ori:t}=n,e=Pr(n,["Ori"]);const{schema:a,getComponent:o,errSelectors:u,authorized:c,onAuthChange:h,name:E}=e,x=o("HttpAuth");return a.get("type")==="http"?p.createElement(x,{key:E,schema:a,name:E,errSelectors:u,authorized:c,getComponent:o,onChange:h}):p.createElement(t,e)}),K7=Yf(oS);class H7 extends p.Component{render(){let{getConfigs:e,schema:r,Ori:n}=this.props,a=["model-box"],o=null;return r.get("deprecated")===!0&&(a.push("deprecated"),o=p.createElement("span",{className:"model-deprecated-warning"},"Deprecated:")),p.createElement("div",{className:a.join(" ")},o,p.createElement(n,Wr()({},this.props,{getConfigs:e,depth:1,expandDepth:this.props.expandDepth||0})))}}const J7=Yf(H7),G7=Yf(r=>{var n=r,{Ori:t}=n,e=Pr(n,["Ori"]);const{schema:a,getComponent:o,errors:u,onChange:c}=e,h=a&&a.get?a.get("format"):null,E=a&&a.get?a.get("type"):null,x=o("Input");return E&&E==="string"&&h&&(h==="binary"||h==="base64")?p.createElement(x,{type:"file",className:u.length?"invalid":"",title:u.length?u:"",onChange:A=>{c(A.target.files[0])},disabled:t.isDisabled}):p.createElement(t,e)}),Y7={Markdown:V7,AuthItem:W7,OpenAPIVersion:function(e){return(r,n)=>a=>{var o;return typeof((o=n.specSelectors)==null?void 0:o.isOAS30)=="function"?n.specSelectors.isOAS30()?p.createElement(e,Wr()({},a,n,{Ori:r})):p.createElement(r,a):(console.warn("OAS30 wrapper: couldn't get spec"),null)}}(t=>{const{Ori:e}=t;return p.createElement(e,{oasVersion:"3.0"})}),JsonSchema_string:G7,model:J7,onlineValidatorBadge:K7},Y1="oas3_set_servers",X1="oas3_set_request_body_value",Z1="oas3_set_request_body_retain_flag",Q1="oas3_set_request_body_inclusion",ew="oas3_set_active_examples_member",tw="oas3_set_request_content_type",rw="oas3_set_response_content_type",nw="oas3_set_server_variable_value",aw="oas3_set_request_body_validate_error",$y="oas3_clear_request_body_validate_error",ow="oas3_clear_request_body_value";function X7(t,e){return{type:Y1,payload:{selectedServerUrl:t,namespace:e}}}function Z7({value:t,pathMethod:e}){return{type:X1,payload:{value:t,pathMethod:e}}}const Q7=({value:t,pathMethod:e})=>({type:Z1,payload:{value:t,pathMethod:e}});function eD({value:t,pathMethod:e,name:r}){return{type:Q1,payload:{value:t,pathMethod:e,name:r}}}function tD({name:t,pathMethod:e,contextType:r,contextName:n}){return{type:ew,payload:{name:t,pathMethod:e,contextType:r,contextName:n}}}function rD({value:t,pathMethod:e}){return{type:tw,payload:{value:t,pathMethod:e}}}function nD({value:t,path:e,method:r}){return{type:rw,payload:{value:t,path:e,method:r}}}function aD({server:t,namespace:e,key:r,val:n}){return{type:nw,payload:{server:t,namespace:e,key:r,val:n}}}const oD=({path:t,method:e,validationErrors:r})=>({type:aw,payload:{path:t,method:e,validationErrors:r}}),iD=({path:t,method:e})=>({type:$y,payload:{path:t,method:e}}),sD=({pathMethod:t})=>({type:$y,payload:{path:t[0],method:t[1]}}),lD=({pathMethod:t})=>({type:ow,payload:{pathMethod:t}});var cD=Te(60680),uD=Te.n(cD);const Hi=t=>(e,...r)=>n=>{if(n.getSystem().specSelectors.isOAS3()){const a=t(e,...r);return typeof a=="function"?a(n):a}return null},pD=Hi((t,e)=>{const r=e?[e,"selectedServer"]:["selectedServer"];return t.getIn(r)||""}),hD=Hi((t,e,r)=>t.getIn(["requestData",e,r,"bodyValue"])||null),dD=Hi((t,e,r)=>t.getIn(["requestData",e,r,"retainBodyValue"])||!1),fD=(t,e,r)=>n=>{const{oas3Selectors:a,specSelectors:o,fn:u}=n.getSystem();if(o.isOAS3()){const c=a.requestContentType(e,r);if(c)return Ly(o.specResolvedSubtree(["paths",e,r,"requestBody"]),c,a.activeExamplesMember(e,r,"requestBody","requestBody"),u)}return null},mD=Hi((t,e,r)=>n=>{const{oas3Selectors:a,specSelectors:o,fn:u}=n;let c=!1;const h=a.requestContentType(e,r);let E=a.requestBodyValue(e,r);const x=o.specResolvedSubtree(["paths",e,r,"requestBody"]);if(!x)return!1;if(ce.Map.isMap(E)&&(E=zt(E.mapEntries(A=>ce.Map.isMap(A[1])?[A[0],A[1].get("value")]:A).toJS())),ce.List.isList(E)&&(E=zt(E)),h){const A=Ly(x,h,a.activeExamplesMember(e,r,"requestBody","requestBody"),u);c=!!E&&E!==A}return c}),gD=Hi((t,e,r)=>t.getIn(["requestData",e,r,"bodyInclusion"])||(0,ce.Map)()),yD=Hi((t,e,r)=>t.getIn(["requestData",e,r,"errors"])||null),vD=Hi((t,e,r,n,a)=>t.getIn(["examples",e,r,n,a,"activeExample"])||null),bD=Hi((t,e,r)=>t.getIn(["requestData",e,r,"requestContentType"])||null),wD=Hi((t,e,r)=>t.getIn(["requestData",e,r,"responseContentType"])||null),ED=Hi((t,e,r)=>{let n;if(typeof e!="string"){const{server:a,namespace:o}=e;n=o?[o,"serverVariableValues",a,r]:["serverVariableValues",a,r]}else n=["serverVariableValues",e,r];return t.getIn(n)||null}),_D=Hi((t,e)=>{let r;if(typeof e!="string"){const{server:n,namespace:a}=e;r=a?[a,"serverVariableValues",n]:["serverVariableValues",n]}else r=["serverVariableValues",e];return t.getIn(r)||(0,ce.OrderedMap)()}),SD=Hi((t,e)=>{var r,n;if(typeof e!="string"){const{server:o,namespace:u}=e;n=o,r=u?t.getIn([u,"serverVariableValues",n]):t.getIn(["serverVariableValues",n])}else n=e,r=t.getIn(["serverVariableValues",n]);r=r||(0,ce.OrderedMap)();let a=n;return r.map((o,u)=>{a=a.replace(new RegExp(`{${uD()(u)}}`,"g"),o)}),a}),xD=function(e){return(...r)=>n=>{const a=n.getSystem().specSelectors.specJson();let o=[...r][1]||[];return!a.getIn(["paths",...o,"requestBody","required"])||e(...r)}}((t,e)=>((r,n)=>(n=n||[],!!r.getIn(["requestData",...n,"bodyValue"])))(t,e)),kD=(t,{oas3RequiredRequestBodyContentType:e,oas3RequestContentType:r,oas3RequestBodyValue:n})=>{let a=[];if(!ce.Map.isMap(n))return a;let o=[];return Object.keys(e.requestContentType).forEach(u=>{u===r&&e.requestContentType[u].forEach(c=>{o.indexOf(c)<0&&o.push(c)})}),o.forEach(u=>{n.getIn([u,"value"])||a.push(u)}),a},CD=_u()(["get","put","post","delete","options","head","patch","trace"]),AD={[Y1]:(t,{payload:{selectedServerUrl:e,namespace:r}})=>{const n=r?[r,"selectedServer"]:["selectedServer"];return t.setIn(n,e)},[X1]:(t,{payload:{value:e,pathMethod:r}})=>{let[n,a]=r;if(!ce.Map.isMap(e))return t.setIn(["requestData",n,a,"bodyValue"],e);let o,u=t.getIn(["requestData",n,a,"bodyValue"])||(0,ce.Map)();ce.Map.isMap(u)||(u=(0,ce.Map)());const[...c]=e.keys();return c.forEach(h=>{let E=e.getIn([h]);u.has(h)&&ce.Map.isMap(E)||(o=u.setIn([h,"value"],E))}),t.setIn(["requestData",n,a,"bodyValue"],o)},[Z1]:(t,{payload:{value:e,pathMethod:r}})=>{let[n,a]=r;return t.setIn(["requestData",n,a,"retainBodyValue"],e)},[Q1]:(t,{payload:{value:e,pathMethod:r,name:n}})=>{let[a,o]=r;return t.setIn(["requestData",a,o,"bodyInclusion",n],e)},[ew]:(t,{payload:{name:e,pathMethod:r,contextType:n,contextName:a}})=>{let[o,u]=r;return t.setIn(["examples",o,u,n,a,"activeExample"],e)},[tw]:(t,{payload:{value:e,pathMethod:r}})=>{let[n,a]=r;return t.setIn(["requestData",n,a,"requestContentType"],e)},[rw]:(t,{payload:{value:e,path:r,method:n}})=>t.setIn(["requestData",r,n,"responseContentType"],e),[nw]:(t,{payload:{server:e,namespace:r,key:n,val:a}})=>{const o=r?[r,"serverVariableValues",e,n]:["serverVariableValues",e,n];return t.setIn(o,a)},[aw]:(t,{payload:{path:e,method:r,validationErrors:n}})=>{let a=[];if(a.push("Required field is not provided"),n.missingBodyValue)return t.setIn(["requestData",e,r,"errors"],(0,ce.fromJS)(a));if(n.missingRequiredKeys&&n.missingRequiredKeys.length>0){const{missingRequiredKeys:o}=n;return t.updateIn(["requestData",e,r,"bodyValue"],(0,ce.fromJS)({}),u=>o.reduce((c,h)=>c.setIn([h,"errors"],(0,ce.fromJS)(a)),u))}return console.warn("unexpected result: SET_REQUEST_BODY_VALIDATE_ERROR"),t},[$y]:(t,{payload:{path:e,method:r}})=>{const n=t.getIn(["requestData",e,r,"bodyValue"]);if(!ce.Map.isMap(n))return t.setIn(["requestData",e,r,"errors"],(0,ce.fromJS)([]));const[...a]=n.keys();return a?t.updateIn(["requestData",e,r,"bodyValue"],(0,ce.fromJS)({}),o=>a.reduce((u,c)=>u.setIn([c,"errors"],(0,ce.fromJS)([])),o)):t},[ow]:(t,{payload:{pathMethod:e}})=>{let[r,n]=e;const a=t.getIn(["requestData",r,n,"bodyValue"]);return a?ce.Map.isMap(a)?t.setIn(["requestData",r,n,"bodyValue"],(0,ce.Map)()):t.setIn(["requestData",r,n,"bodyValue"],""):t}};function iw(){return{components:U7,wrapComponents:Y7,statePlugins:{spec:{wrapSelectors:le,selectors:Fe},auth:{wrapSelectors:Pe},oas3:{actions:lt({},ze),reducers:AD,selectors:lt({},qe)}}}}const OD=({specSelectors:t,getComponent:e})=>{const r=t.selectWebhooksOperations(),n=Object.keys(r),a=e("OperationContainer",!0);return n.length===0?null:p.createElement("div",{className:"webhooks"},p.createElement("h2",null,"Webhooks"),n.map(o=>p.createElement("div",{key:`${o}-webhook`},r[o].map(u=>p.createElement(a,{key:`${o}-${u.method}-webhook`,op:u.operation,tag:"webhooks",method:u.method,path:o,specPath:(0,ce.List)(u.specPath),allowTryItOut:!1})))))},jD=({getComponent:t,specSelectors:e})=>{const r=e.selectLicenseNameField(),n=e.selectLicenseUrl(),a=t("Link");return p.createElement("div",{className:"info__license"},n?p.createElement("div",{className:"info__license__url"},p.createElement(a,{target:"_blank",href:vr(n)},r)):p.createElement("span",null,r))},PD=({getComponent:t,specSelectors:e})=>{const r=e.selectContactNameField(),n=e.selectContactUrl(),a=e.selectContactEmailField(),o=t("Link");return p.createElement("div",{className:"info__contact"},n&&p.createElement("div",null,p.createElement(o,{href:vr(n),target:"_blank"},r," - Website")),a&&p.createElement(o,{href:vr(`mailto:${a}`)},n?`Send email to ${r}`:`Contact ${r}`))},ND=({getComponent:t,specSelectors:e})=>{const r=e.version(),n=e.url(),a=e.basePath(),o=e.host(),u=e.selectInfoSummaryField(),c=e.selectInfoDescriptionField(),h=e.selectInfoTitleField(),E=e.selectInfoTermsOfServiceUrl(),x=e.selectExternalDocsUrl(),A=e.selectExternalDocsDescriptionField(),T=e.contact(),R=e.license(),B=t("Markdown",!0),H=t("Link"),G=t("VersionStamp"),X=t("OpenAPIVersion"),L=t("InfoUrl"),ie=t("InfoBasePath"),oe=t("License",!0),pe=t("Contact",!0),he=t("JsonSchemaDialect",!0);return p.createElement("div",{className:"info"},p.createElement("hgroup",{className:"main"},p.createElement("h2",{className:"title"},h,p.createElement("span",null,r&&p.createElement(G,{version:r}),p.createElement(X,{oasVersion:"3.1"}))),(o||a)&&p.createElement(ie,{host:o,basePath:a}),n&&p.createElement(L,{getComponent:t,url:n})),u&&p.createElement("p",{className:"info__summary"},u),p.createElement("div",{className:"info__description description"},p.createElement(B,{source:c})),E&&p.createElement("div",{className:"info__tos"},p.createElement(H,{target:"_blank",href:vr(E)},"Terms of service")),T.size>0&&p.createElement(pe,null),R.size>0&&p.createElement(oe,null),x&&p.createElement(H,{className:"info__extdocs",target:"_blank",href:vr(x)},A||x),p.createElement(he,null))},ID=({getComponent:t,specSelectors:e})=>{const r=e.selectJsonSchemaDialectField(),n=e.selectJsonSchemaDialectDefault(),a=t("Link");return p.createElement(p.Fragment,null,r&&r===n&&p.createElement("p",{className:"info__jsonschemadialect"},"JSON Schema dialect:"," ",p.createElement(a,{target:"_blank",href:vr(r)},r)),r&&r!==n&&p.createElement("div",{className:"error-wrapper"},p.createElement("div",{className:"no-margin"},p.createElement("div",{className:"errors"},p.createElement("div",{className:"errors-wrapper"},p.createElement("h4",{className:"center"},"Warning"),p.createElement("p",{className:"message"},p.createElement("strong",null,"OpenAPI.jsonSchemaDialect")," field contains a value different from the default value of"," ",p.createElement(a,{target:"_blank",href:n},n),". Values different from the default one are currently not supported. Please either omit the field or provide it with the default value."))))))},TD=({bypass:t,isSwagger2:e,isOAS3:r,isOAS31:n,alsoShow:a,children:o})=>t?p.createElement("div",null,o):e&&(r||n)?p.createElement("div",{className:"version-pragma"},a,p.createElement("div",{className:"version-pragma__message version-pragma__message--ambiguous"},p.createElement("div",null,p.createElement("h3",null,"Unable to render this definition"),p.createElement("p",null,p.createElement("code",null,"swagger")," and ",p.createElement("code",null,"openapi")," fields cannot be present in the same Swagger or OpenAPI definition. Please remove one of the fields."),p.createElement("p",null,"Supported version fields are ",p.createElement("code",null,'swagger: "2.0"')," and those that match ",p.createElement("code",null,"openapi: 3.x.y")," (for example,"," ",p.createElement("code",null,"openapi: 3.1.0"),").")))):e||r||n?p.createElement("div",null,o):p.createElement("div",{className:"version-pragma"},a,p.createElement("div",{className:"version-pragma__message version-pragma__message--missing"},p.createElement("div",null,p.createElement("h3",null,"Unable to render this definition"),p.createElement("p",null,"The provided definition does not specify a valid version field."),p.createElement("p",null,"Please indicate a valid Swagger or OpenAPI version field. Supported version fields are ",p.createElement("code",null,'swagger: "2.0"')," and those that match ",p.createElement("code",null,"openapi: 3.x.y")," (for example,"," ",p.createElement("code",null,"openapi: 3.1.0"),").")))),MD=t=>typeof t=="string"&&t.includes("#/components/schemas/")?(e=>{const r=e.replace(/~1/g,"/").replace(/~0/g,"~");try{return decodeURIComponent(r)}catch(n){return r}})(t.replace(/^.*#\/components\/schemas\//,"")):null,RD=(0,p.forwardRef)(({schema:t,getComponent:e,onToggle:r=()=>{}},n)=>{const a=e("JSONSchema202012"),o=MD(t.get("$$ref")),u=(0,p.useCallback)((c,h)=>{r(o,h)},[o,r]);return p.createElement(a,{name:o,schema:t.toJS(),ref:n,onExpand:u})}),DD=RD,LD=({specActions:t,specSelectors:e,layoutSelectors:r,layoutActions:n,getComponent:a,getConfigs:o,fn:u})=>{const c=e.selectSchemas(),h=Object.keys(c).length>0,E=["components","schemas"],{docExpansion:x,defaultModelsExpandDepth:A}=o(),T=A>0&&x!=="none",R=r.isShown(E,T),B=a("Collapse"),H=a("JSONSchema202012"),G=a("ArrowUpIcon"),X=a("ArrowDownIcon"),{getTitle:L}=u.jsonSchema202012.useFn();(0,p.useEffect)(()=>{const ae=R&&A>1,je=e.specResolvedSubtree(E)!=null;ae&&!je&&t.requestResolvedSubtree(E)},[R,A]);const ie=(0,p.useCallback)(()=>{n.show(E,!R)},[R]),oe=(0,p.useCallback)(ae=>{ae!==null&&n.readyToScroll(E,ae)},[]),pe=ae=>je=>{je!==null&&n.readyToScroll([...E,ae],je)},he=ae=>(je,fe)=>{if(fe){const ge=[...E,ae];e.specResolvedSubtree(ge)!=null||t.requestResolvedSubtree([...E,ae])}};return!h||A<0?null:p.createElement("section",{className:cn()("models",{"is-open":R}),ref:oe},p.createElement("h4",null,p.createElement("button",{"aria-expanded":R,className:"models-control",onClick:ie},p.createElement("span",null,"Schemas"),R?p.createElement(G,null):p.createElement(X,null))),p.createElement(B,{isOpened:R},Object.entries(c).map(([ae,je])=>{const fe=L(je,{lookup:"basic"})||ae;return p.createElement(H,{key:ae,ref:pe(ae),schema:je,name:fe,onExpand:he(ae)})})))},$D=({schema:t,getComponent:e})=>{const r=e("JumpToPath",!0);return p.createElement("div",null,p.createElement("h4",null,t.get("name")," (mutualTLS)"," ",p.createElement(r,{path:["securityDefinitions",t.get("name")]})),p.createElement("p",null,"Mutual TLS is required by this API/Operation. Certificates are managed via your Operating System and/or your browser."),p.createElement("p",null,t.get("description")))};class FD extends p.Component{constructor(r,n){super(r,n);Ee(this,"onAuthChange",r=>{let{name:n}=r;this.setState({[n]:r})});Ee(this,"submitAuth",r=>{r.preventDefault();let{authActions:n}=this.props;n.authorizeWithPersistOption(this.state)});Ee(this,"logoutClick",r=>{r.preventDefault();let{authActions:n,definitions:a}=this.props,o=a.map((u,c)=>c).toArray();this.setState(o.reduce((u,c)=>(u[c]="",u),{})),n.logoutWithPersistOption(o)});Ee(this,"close",r=>{r.preventDefault();let{authActions:n}=this.props;n.showDefinitions(!1)});this.state={}}render(){let{definitions:r,getComponent:n,authSelectors:a,errSelectors:o}=this.props;const u=n("AuthItem"),c=n("oauth2",!0),h=n("Button"),E=a.authorized(),x=r.filter((B,H)=>!!E.get(H)),A=r.filter(B=>B.get("type")!=="oauth2"&&B.get("type")!=="mutualTLS"),T=r.filter(B=>B.get("type")==="oauth2"),R=r.filter(B=>B.get("type")==="mutualTLS");return p.createElement("div",{className:"auth-container"},A.size>0&&p.createElement("form",{onSubmit:this.submitAuth},A.map((B,H)=>p.createElement(u,{key:H,schema:B,name:H,getComponent:n,onAuthChange:this.onAuthChange,authorized:E,errSelectors:o})).toArray(),p.createElement("div",{className:"auth-btn-wrapper"},A.size===x.size?p.createElement(h,{className:"btn modal-btn auth",onClick:this.logoutClick,"aria-label":"Remove authorization"},"Logout"):p.createElement(h,{type:"submit",className:"btn modal-btn auth authorize","aria-label":"Apply credentials"},"Authorize"),p.createElement(h,{className:"btn modal-btn auth btn-done",onClick:this.close},"Close"))),T.size>0?p.createElement("div",null,p.createElement("div",{className:"scope-def"},p.createElement("p",null,"Scopes are used to grant an application different levels of access to data on behalf of the end user. Each API may declare one or more scopes."),p.createElement("p",null,"API requires the following scopes. Select which ones you want to grant to Swagger UI.")),r.filter(B=>B.get("type")==="oauth2").map((B,H)=>p.createElement("div",{key:H},p.createElement(c,{authorized:E,schema:B,name:H}))).toArray()):null,R.size>0&&p.createElement("div",null,R.map((B,H)=>p.createElement(u,{key:H,schema:B,name:H,getComponent:n,onAuthChange:this.onAuthChange,authorized:E,errSelectors:o})).toArray()))}}const BD=FD,cx=t=>{const e=t.get("openapi");return typeof e=="string"&&/^3\.1\.(?:[1-9]\d*|0)$/.test(e)},ux=t=>(e,...r)=>n=>{if(n.getSystem().specSelectors.isOAS31()){const a=t(e,...r);return typeof a=="function"?a(n):a}return null},px=t=>(e,r)=>(n,...a)=>{if(r.getSystem().specSelectors.isOAS31()){const o=t(n,...a);return typeof o=="function"?o(e,r):o}return e(...a)},hx=t=>(e,...r)=>n=>{const a=t(e,n,...r);return typeof a=="function"?a(n):a},tl=t=>(e,r)=>n=>r.specSelectors.isOAS31()?p.createElement(t,Wr()({},n,{originalComponent:e,getSystem:r.getSystem})):p.createElement(e,n),qD=tl(({getSystem:t})=>{const e=t().getComponent("OAS31License",!0);return p.createElement(e,null)}),zD=tl(({getSystem:t})=>{const e=t().getComponent("OAS31Contact",!0);return p.createElement(e,null)}),UD=tl(({getSystem:t})=>{const e=t().getComponent("OAS31Info",!0);return p.createElement(e,null)}),VD=tl(r=>{var n=r,{getSystem:t}=n,e=Pr(n,["getSystem"]);const a=t(),{getComponent:o,fn:u,getConfigs:c}=a,h=c(),E=o("OAS31Model"),x=o("JSONSchema202012"),A=o("JSONSchema202012Keyword$schema"),T=o("JSONSchema202012Keyword$vocabulary"),R=o("JSONSchema202012Keyword$id"),B=o("JSONSchema202012Keyword$anchor"),H=o("JSONSchema202012Keyword$dynamicAnchor"),G=o("JSONSchema202012Keyword$ref"),X=o("JSONSchema202012Keyword$dynamicRef"),L=o("JSONSchema202012Keyword$defs"),ie=o("JSONSchema202012Keyword$comment"),oe=o("JSONSchema202012KeywordAllOf"),pe=o("JSONSchema202012KeywordAnyOf"),he=o("JSONSchema202012KeywordOneOf"),ae=o("JSONSchema202012KeywordNot"),je=o("JSONSchema202012KeywordIf"),fe=o("JSONSchema202012KeywordThen"),ge=o("JSONSchema202012KeywordElse"),be=o("JSONSchema202012KeywordDependentSchemas"),ye=o("JSONSchema202012KeywordPrefixItems"),me=o("JSONSchema202012KeywordItems"),Ae=o("JSONSchema202012KeywordContains"),Ue=o("JSONSchema202012KeywordProperties"),ft=o("JSONSchema202012KeywordPatternProperties"),Tt=o("JSONSchema202012KeywordAdditionalProperties"),Dt=o("JSONSchema202012KeywordPropertyNames"),Vt=o("JSONSchema202012KeywordUnevaluatedItems"),or=o("JSONSchema202012KeywordUnevaluatedProperties"),fr=o("JSONSchema202012KeywordType"),hr=o("JSONSchema202012KeywordEnum"),st=o("JSONSchema202012KeywordConst"),ht=o("JSONSchema202012KeywordConstraint"),bt=o("JSONSchema202012KeywordDependentRequired"),wt=o("JSONSchema202012KeywordContentSchema"),Zt=o("JSONSchema202012KeywordTitle"),kr=o("JSONSchema202012KeywordDescription"),Gr=o("JSONSchema202012KeywordDefault"),hn=o("JSONSchema202012KeywordDeprecated"),Lr=o("JSONSchema202012KeywordReadOnly"),nn=o("JSONSchema202012KeywordWriteOnly"),Qr=o("JSONSchema202012Accordion"),kn=o("JSONSchema202012ExpandDeepButton"),Dn=o("JSONSchema202012ChevronRightIcon"),za=o("withJSONSchema202012Context")(E,{config:{default$schema:"https://spec.openapis.org/oas/3.1/dialect/base",defaultExpandedLevels:h.defaultModelExpandDepth,includeReadOnly:!!e.includeReadOnly,includeWriteOnly:!!e.includeWriteOnly},components:{JSONSchema:x,Keyword$schema:A,Keyword$vocabulary:T,Keyword$id:R,Keyword$anchor:B,Keyword$dynamicAnchor:H,Keyword$ref:G,Keyword$dynamicRef:X,Keyword$defs:L,Keyword$comment:ie,KeywordAllOf:oe,KeywordAnyOf:pe,KeywordOneOf:he,KeywordNot:ae,KeywordIf:je,KeywordThen:fe,KeywordElse:ge,KeywordDependentSchemas:be,KeywordPrefixItems:ye,KeywordItems:me,KeywordContains:Ae,KeywordProperties:Ue,KeywordPatternProperties:ft,KeywordAdditionalProperties:Tt,KeywordPropertyNames:Dt,KeywordUnevaluatedItems:Vt,KeywordUnevaluatedProperties:or,KeywordType:fr,KeywordEnum:hr,KeywordConst:st,KeywordConstraint:ht,KeywordDependentRequired:bt,KeywordContentSchema:wt,KeywordTitle:Zt,KeywordDescription:kr,KeywordDefault:Gr,KeywordDeprecated:hn,KeywordReadOnly:Lr,KeywordWriteOnly:nn,Accordion:Qr,ExpandDeepButton:kn,ChevronRightIcon:Dn},fn:{upperFirst:u.upperFirst,isExpandable:u.jsonSchema202012.isExpandable,getProperties:u.jsonSchema202012.getProperties}});return p.createElement(za,e)}),WD=VD,jh=tl(({getSystem:t})=>{const{getComponent:e,fn:r,getConfigs:n}=t(),a=n();if(jh.ModelsWithJSONSchemaContext)return p.createElement(jh.ModelsWithJSONSchemaContext,null);const o=e("OAS31Models",!0),u=e("JSONSchema202012"),c=e("JSONSchema202012Keyword$schema"),h=e("JSONSchema202012Keyword$vocabulary"),E=e("JSONSchema202012Keyword$id"),x=e("JSONSchema202012Keyword$anchor"),A=e("JSONSchema202012Keyword$dynamicAnchor"),T=e("JSONSchema202012Keyword$ref"),R=e("JSONSchema202012Keyword$dynamicRef"),B=e("JSONSchema202012Keyword$defs"),H=e("JSONSchema202012Keyword$comment"),G=e("JSONSchema202012KeywordAllOf"),X=e("JSONSchema202012KeywordAnyOf"),L=e("JSONSchema202012KeywordOneOf"),ie=e("JSONSchema202012KeywordNot"),oe=e("JSONSchema202012KeywordIf"),pe=e("JSONSchema202012KeywordThen"),he=e("JSONSchema202012KeywordElse"),ae=e("JSONSchema202012KeywordDependentSchemas"),je=e("JSONSchema202012KeywordPrefixItems"),fe=e("JSONSchema202012KeywordItems"),ge=e("JSONSchema202012KeywordContains"),be=e("JSONSchema202012KeywordProperties"),ye=e("JSONSchema202012KeywordPatternProperties"),me=e("JSONSchema202012KeywordAdditionalProperties"),Ae=e("JSONSchema202012KeywordPropertyNames"),Ue=e("JSONSchema202012KeywordUnevaluatedItems"),ft=e("JSONSchema202012KeywordUnevaluatedProperties"),Tt=e("JSONSchema202012KeywordType"),Dt=e("JSONSchema202012KeywordEnum"),Vt=e("JSONSchema202012KeywordConst"),or=e("JSONSchema202012KeywordConstraint"),fr=e("JSONSchema202012KeywordDependentRequired"),hr=e("JSONSchema202012KeywordContentSchema"),st=e("JSONSchema202012KeywordTitle"),ht=e("JSONSchema202012KeywordDescription"),bt=e("JSONSchema202012KeywordDefault"),wt=e("JSONSchema202012KeywordDeprecated"),Zt=e("JSONSchema202012KeywordReadOnly"),kr=e("JSONSchema202012KeywordWriteOnly"),Gr=e("JSONSchema202012Accordion"),hn=e("JSONSchema202012ExpandDeepButton"),Lr=e("JSONSchema202012ChevronRightIcon"),nn=e("withJSONSchema202012Context");return jh.ModelsWithJSONSchemaContext=nn(o,{config:{default$schema:"https://spec.openapis.org/oas/3.1/dialect/base",defaultExpandedLevels:a.defaultModelsExpandDepth-1,includeReadOnly:!0,includeWriteOnly:!0},components:{JSONSchema:u,Keyword$schema:c,Keyword$vocabulary:h,Keyword$id:E,Keyword$anchor:x,Keyword$dynamicAnchor:A,Keyword$ref:T,Keyword$dynamicRef:R,Keyword$defs:B,Keyword$comment:H,KeywordAllOf:G,KeywordAnyOf:X,KeywordOneOf:L,KeywordNot:ie,KeywordIf:oe,KeywordThen:pe,KeywordElse:he,KeywordDependentSchemas:ae,KeywordPrefixItems:je,KeywordItems:fe,KeywordContains:ge,KeywordProperties:be,KeywordPatternProperties:ye,KeywordAdditionalProperties:me,KeywordPropertyNames:Ae,KeywordUnevaluatedItems:Ue,KeywordUnevaluatedProperties:ft,KeywordType:Tt,KeywordEnum:Dt,KeywordConst:Vt,KeywordConstraint:or,KeywordDependentRequired:fr,KeywordContentSchema:hr,KeywordTitle:st,KeywordDescription:ht,KeywordDefault:bt,KeywordDeprecated:wt,KeywordReadOnly:Zt,KeywordWriteOnly:kr,Accordion:Gr,ExpandDeepButton:hn,ChevronRightIcon:Lr},fn:{upperFirst:r.upperFirst,isExpandable:r.jsonSchema202012.isExpandable,getProperties:r.jsonSchema202012.getProperties}}),p.createElement(jh.ModelsWithJSONSchemaContext,null)});jh.ModelsWithJSONSchemaContext=null;const KD=jh,HD=(t,e)=>r=>{const n=e.specSelectors.isOAS31(),a=e.getComponent("OAS31VersionPragmaFilter");return p.createElement(a,Wr()({isOAS31:n},r))},JD=tl(r=>{var n=r,{originalComponent:t}=n,e=Pr(n,["originalComponent"]);const{getComponent:a,schema:o}=e,u=a("MutualTLSAuth",!0);return o.get("type")==="mutualTLS"?p.createElement(u,{schema:o}):p.createElement(t,e)}),GD=JD,YD=tl(r=>{var n=r,{getSystem:t}=n,e=Pr(n,["getSystem"]);const a=t().getComponent("OAS31Auths",!0);return p.createElement(a,e)}),sw=(0,ce.Map)(),XD=ar((t,e)=>e.specSelectors.specJson(),cx),ZD=()=>t=>{const e=t.specSelectors.specJson().get("webhooks");return ce.Map.isMap(e)?e:sw},QD=ar([(t,e)=>e.specSelectors.webhooks(),(t,e)=>e.specSelectors.validOperationMethods(),(t,e)=>e.specSelectors.specResolvedSubtree(["webhooks"])],(t,e)=>t.reduce((r,n,a)=>{if(!ce.Map.isMap(n))return r;const o=n.entrySeq().filter(([u])=>e.includes(u)).map(([u,c])=>({operation:(0,ce.Map)({operation:c}),method:u,path:a,specPath:["webhooks",a,u]}));return r.concat(o)},(0,ce.List)()).groupBy(r=>r.path).map(r=>r.toArray()).toObject()),eL=()=>t=>{const e=t.specSelectors.info().get("license");return ce.Map.isMap(e)?e:sw},tL=()=>t=>t.specSelectors.license().get("name","License"),rL=()=>t=>t.specSelectors.license().get("url"),nL=ar([(t,e)=>e.specSelectors.url(),(t,e)=>e.oas3Selectors.selectedServer(),(t,e)=>e.specSelectors.selectLicenseUrlField()],(t,e,r)=>{if(r)return ws(r,t,{selectedServer:e})}),aL=()=>t=>t.specSelectors.license().get("identifier"),oL=()=>t=>{const e=t.specSelectors.info().get("contact");return ce.Map.isMap(e)?e:sw},iL=()=>t=>t.specSelectors.contact().get("name","the developer"),sL=()=>t=>t.specSelectors.contact().get("email"),lL=()=>t=>t.specSelectors.contact().get("url"),cL=ar([(t,e)=>e.specSelectors.url(),(t,e)=>e.oas3Selectors.selectedServer(),(t,e)=>e.specSelectors.selectContactUrlField()],(t,e,r)=>{if(r)return ws(r,t,{selectedServer:e})}),uL=()=>t=>t.specSelectors.info().get("title"),pL=()=>t=>t.specSelectors.info().get("summary"),hL=()=>t=>t.specSelectors.info().get("description"),dL=()=>t=>t.specSelectors.info().get("termsOfService"),fL=ar([(t,e)=>e.specSelectors.url(),(t,e)=>e.oas3Selectors.selectedServer(),(t,e)=>e.specSelectors.selectInfoTermsOfServiceField()],(t,e,r)=>{if(r)return ws(r,t,{selectedServer:e})}),mL=()=>t=>t.specSelectors.externalDocs().get("description"),gL=()=>t=>t.specSelectors.externalDocs().get("url"),yL=ar([(t,e)=>e.specSelectors.url(),(t,e)=>e.oas3Selectors.selectedServer(),(t,e)=>e.specSelectors.selectExternalDocsUrlField()],(t,e,r)=>{if(r)return ws(r,t,{selectedServer:e})}),vL=()=>t=>t.specSelectors.specJson().get("jsonSchemaDialect"),bL=()=>"https://spec.openapis.org/oas/3.1/dialect/base",wL=ar((t,e)=>e.specSelectors.definitions(),(t,e)=>e.specSelectors.specResolvedSubtree(["components","schemas"]),(t,e)=>ce.Map.isMap(t)?ce.Map.isMap(e)?Object.entries(t.toJS()).reduce((r,[n,a])=>{const o=e.get(n);return r[n]=(o==null?void 0:o.toJS())||a,r},{}):t.toJS():{}),EL=(t,e)=>(r,...n)=>e.specSelectors.isOAS31()||t(...n),_L=px(()=>(t,e)=>e.oas31Selectors.selectLicenseUrl()),SL=px(()=>(t,e)=>{const r=e.specSelectors.securityDefinitions();let n=t();return r&&r.entrySeq().forEach(([a,o])=>{o.get("type")==="mutualTLS"&&(n=n.push(new ce.Map({[a]:o})))}),n}),xL=ar([(t,e)=>e.specSelectors.url(),(t,e)=>e.oas3Selectors.selectedServer(),(t,e)=>e.specSelectors.selectLicenseUrlField(),(t,e)=>e.specSelectors.selectLicenseIdentifierField()],(t,e,r,n)=>r?ws(r,t,{selectedServer:e}):n?`https://spdx.org/licenses/${n}.html`:void 0),kL=({schema:t,getSystem:e})=>{const{fn:r}=e(),{hasKeyword:n,stringify:a}=r.jsonSchema202012.useFn();return n(t,"example")?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--example"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"Example"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const"},a(t.example))):null},CL=({schema:t,getSystem:e})=>{const r=(t==null?void 0:t.xml)||{},{fn:n,getComponent:a}=e(),{useIsExpandedDeeply:o,useComponent:u}=n.jsonSchema202012,c=o(),h=!!(r.name||r.namespace||r.prefix),[E,x]=(0,p.useState)(c),[A,T]=(0,p.useState)(!1),R=u("Accordion"),B=u("ExpandDeepButton"),H=a("JSONSchema202012DeepExpansionContext")(),G=(0,p.useCallback)(()=>{x(L=>!L)},[]),X=(0,p.useCallback)((L,ie)=>{x(ie),T(ie)},[]);return Object.keys(r).length===0?null:p.createElement(H.Provider,{value:A},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--xml"},h?p.createElement(p.Fragment,null,p.createElement(R,{expanded:E,onChange:G},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"XML")),p.createElement(B,{expanded:E,onClick:X})):p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"XML"),r.attribute===!0&&p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--muted"},"attribute"),r.wrapped===!0&&p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--muted"},"wrapped"),p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"object"),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!E})},E&&p.createElement(p.Fragment,null,r.name&&p.createElement("li",{className:"json-schema-2020-12-property"},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"name"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},r.name))),r.namespace&&p.createElement("li",{className:"json-schema-2020-12-property"},p.createElement("div",{className:"json-schema-2020-12-keyword"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"namespace"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},r.namespace))),r.prefix&&p.createElement("li",{className:"json-schema-2020-12-property"},p.createElement("div",{className:"json-schema-2020-12-keyword"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"prefix"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},r.prefix)))))))},AL=({discriminator:t})=>{const e=(t==null?void 0:t.mapping)||{};return Object.keys(e).length===0?null:Object.entries(e).map(([r,n])=>p.createElement("div",{key:`${r}-${n}`,className:"json-schema-2020-12-keyword"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},r),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},n)))},OL=({schema:t,getSystem:e})=>{const r=(t==null?void 0:t.discriminator)||{},{fn:n,getComponent:a}=e(),{useIsExpandedDeeply:o,useComponent:u}=n.jsonSchema202012,c=o(),h=!!r.mapping,[E,x]=(0,p.useState)(c),[A,T]=(0,p.useState)(!1),R=u("Accordion"),B=u("ExpandDeepButton"),H=a("JSONSchema202012DeepExpansionContext")(),G=(0,p.useCallback)(()=>{x(L=>!L)},[]),X=(0,p.useCallback)((L,ie)=>{x(ie),T(ie)},[]);return Object.keys(r).length===0?null:p.createElement(H.Provider,{value:A},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--discriminator"},h?p.createElement(p.Fragment,null,p.createElement(R,{expanded:E,onChange:G},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"Discriminator")),p.createElement(B,{expanded:E,onClick:X})):p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"Discriminator"),r.propertyName&&p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--muted"},r.propertyName),p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"object"),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!E})},E&&p.createElement("li",{className:"json-schema-2020-12-property"},p.createElement(AL,{discriminator:r})))))},jL=({schema:t,getSystem:e})=>{const r=(t==null?void 0:t.externalDocs)||{},{fn:n,getComponent:a}=e(),{useIsExpandedDeeply:o,useComponent:u}=n.jsonSchema202012,c=o(),h=!(!r.description&&!r.url),[E,x]=(0,p.useState)(c),[A,T]=(0,p.useState)(!1),R=u("Accordion"),B=u("ExpandDeepButton"),H=a("JSONSchema202012KeywordDescription"),G=a("Link"),X=a("JSONSchema202012DeepExpansionContext")(),L=(0,p.useCallback)(()=>{x(oe=>!oe)},[]),ie=(0,p.useCallback)((oe,pe)=>{x(pe),T(pe)},[]);return Object.keys(r).length===0?null:p.createElement(X.Provider,{value:A},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--externalDocs"},h?p.createElement(p.Fragment,null,p.createElement(R,{expanded:E,onChange:L},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"External documentation")),p.createElement(B,{expanded:E,onClick:ie})):p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"External documentation"),p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"object"),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!E})},E&&p.createElement(p.Fragment,null,r.description&&p.createElement("li",{className:"json-schema-2020-12-property"},p.createElement(H,{schema:r,getSystem:e})),r.url&&p.createElement("li",{className:"json-schema-2020-12-property"},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"url"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},p.createElement(G,{target:"_blank",href:vr(r.url)},r.url))))))))},PL=({schema:t,getSystem:e})=>{if(!(t!=null&&t.description))return null;const{getComponent:r}=e(),n=r("Markdown");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--description"},p.createElement("div",{className:"json-schema-2020-12-core-keyword__value json-schema-2020-12-core-keyword__value--secondary"},p.createElement(n,{source:t.description})))},NL=tl(PL),IL=tl(({schema:t,getSystem:e,originalComponent:r})=>{const{getComponent:n}=e(),a=n("JSONSchema202012KeywordDiscriminator"),o=n("JSONSchema202012KeywordXml"),u=n("JSONSchema202012KeywordExample"),c=n("JSONSchema202012KeywordExternalDocs");return p.createElement(p.Fragment,null,p.createElement(r,{schema:t}),p.createElement(a,{schema:t,getSystem:e}),p.createElement(o,{schema:t,getSystem:e}),p.createElement(c,{schema:t,getSystem:e}),p.createElement(u,{schema:t,getSystem:e}))}),TL=IL,ML=({schema:t,getSystem:e})=>{const{fn:r}=e(),{useComponent:n}=r.jsonSchema202012,{getDependentRequired:a,getProperties:o}=r.jsonSchema202012.useFn(),u=r.jsonSchema202012.useConfig(),c=Array.isArray(t==null?void 0:t.required)?t.required:[],h=n("JSONSchema"),E=o(t,u);return Object.keys(E).length===0?null:p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--properties"},p.createElement("ul",null,Object.entries(E).map(([x,A])=>{const T=c.includes(x),R=a(x,t);return p.createElement("li",{key:x,className:cn()("json-schema-2020-12-property",{"json-schema-2020-12-property--required":T})},p.createElement(h,{name:x,schema:A,dependentRequired:R}))})))},RL=tl(ML),DL=(t,{includeReadOnly:e,includeWriteOnly:r})=>{if(!(t!=null&&t.properties))return{};const n=Object.entries(t.properties).filter(([,a])=>((a==null?void 0:a.readOnly)!==!0||e)&&((a==null?void 0:a.writeOnly)!==!0||r));return Object.fromEntries(n)},LL=function({fn:e,getSystem:r}){if(e.jsonSchema202012){const n=((a,o)=>{const{fn:u}=o();if(typeof a!="function")return null;const{hasKeyword:c}=u.jsonSchema202012;return h=>a(h)||c(h,"example")||(h==null?void 0:h.xml)||(h==null?void 0:h.discriminator)||(h==null?void 0:h.externalDocs)})(e.jsonSchema202012.isExpandable,r);Object.assign(this.fn.jsonSchema202012,{isExpandable:n,getProperties:DL})}if(typeof e.sampleFromSchema=="function"&&e.jsonSchema202012){const n=((a,o)=>{const{fn:u,specSelectors:c}=o;return Object.fromEntries(Object.entries(a).map(([h,E])=>{const x=u[h];return[h,(...A)=>c.isOAS31()?E(...A):typeof x=="function"?x(...A):void 0]}))})({sampleFromSchema:e.jsonSchema202012.sampleFromSchema,sampleFromSchemaGeneric:e.jsonSchema202012.sampleFromSchemaGeneric,createXMLExample:e.jsonSchema202012.createXMLExample,memoizedSampleFromSchema:e.jsonSchema202012.memoizedSampleFromSchema,memoizedCreateXMLExample:e.jsonSchema202012.memoizedCreateXMLExample,getJsonSampleSchema:e.jsonSchema202012.getJsonSampleSchema,getYamlSampleSchema:e.jsonSchema202012.getYamlSampleSchema,getXmlSampleSchema:e.jsonSchema202012.getXmlSampleSchema,getSampleSchema:e.jsonSchema202012.getSampleSchema,mergeJsonSchema:e.jsonSchema202012.mergeJsonSchema},r());Object.assign(this.fn,n)}},$L=({fn:t})=>{const e=t.createSystemSelector||hx,r=t.createOnlyOAS31Selector||ux;return{afterLoad:LL,fn:{isOAS31:cx,createSystemSelector:hx,createOnlyOAS31Selector:ux},components:{Webhooks:OD,JsonSchemaDialect:ID,MutualTLSAuth:$D,OAS31Info:ND,OAS31License:jD,OAS31Contact:PD,OAS31VersionPragmaFilter:TD,OAS31Model:DD,OAS31Models:LD,OAS31Auths:BD,JSONSchema202012KeywordExample:kL,JSONSchema202012KeywordXml:CL,JSONSchema202012KeywordDiscriminator:OL,JSONSchema202012KeywordExternalDocs:jL},wrapComponents:{InfoContainer:UD,License:qD,Contact:zD,VersionPragmaFilter:HD,Model:WD,Models:KD,AuthItem:GD,auths:YD,JSONSchema202012KeywordDescription:NL,JSONSchema202012KeywordDefault:TL,JSONSchema202012KeywordProperties:RL},statePlugins:{auth:{wrapSelectors:{definitionsToAuthorize:SL}},spec:{selectors:{isOAS31:e(XD),license:eL,selectLicenseNameField:tL,selectLicenseUrlField:rL,selectLicenseIdentifierField:r(aL),selectLicenseUrl:e(nL),contact:oL,selectContactNameField:iL,selectContactEmailField:sL,selectContactUrlField:lL,selectContactUrl:e(cL),selectInfoTitleField:uL,selectInfoSummaryField:r(pL),selectInfoDescriptionField:hL,selectInfoTermsOfServiceField:dL,selectInfoTermsOfServiceUrl:e(fL),selectExternalDocsDescriptionField:mL,selectExternalDocsUrlField:gL,selectExternalDocsUrl:e(yL),webhooks:r(ZD),selectWebhooksOperations:r(e(QD)),selectJsonSchemaDialectField:vL,selectJsonSchemaDialectDefault:bL,selectSchemas:e(wL)},wrapSelectors:{isOAS3:EL,selectLicenseUrl:_L}},oas31:{selectors:{selectLicenseUrl:r(e(xL))}}}}},FL=Qa().object,BL=Qa().bool,Ph=(Qa().oneOfType([FL,BL]),(0,p.createContext)(null));Ph.displayName="JSONSchemaContext";const lw=(0,p.createContext)(0);lw.displayName="JSONSchemaLevelContext";const rl=(0,p.createContext)(!1);rl.displayName="JSONSchemaDeepExpansionContext";const cw=(0,p.createContext)(new Set),dx=()=>{const{config:t}=(0,p.useContext)(Ph);return t},$t=t=>{const{components:e}=(0,p.useContext)(Ph);return e[t]||null},Vn=(t=void 0)=>{const{fn:e}=(0,p.useContext)(Ph);return t!==void 0?e[t]:e},uw=()=>{const t=(0,p.useContext)(lw);return[t,t+1]},qc=()=>{const[t]=uw(),{defaultExpandedLevels:e}=dx();return e-t>0},Fl=()=>(0,p.useContext)(rl),fx=(t=void 0)=>{if(t===void 0)return(0,p.useContext)(cw);const e=(0,p.useContext)(cw);return new Set([...e,t])},qL=(0,p.forwardRef)(({schema:t,name:e="",dependentRequired:r=[],onExpand:n=()=>{}},a)=>{const o=Vn(),u=qc(),c=Fl(),[h,E]=(0,p.useState)(u||c),[x,A]=(0,p.useState)(c),[T,R]=uw(),B=(()=>{const[co]=uw();return co>0})(),H=o.isExpandable(t)||r.length>0,G=(co=>fx().has(co))(t),X=fx(t),L=o.stringifyConstraints(t),ie=$t("Accordion"),oe=$t("Keyword$schema"),pe=$t("Keyword$vocabulary"),he=$t("Keyword$id"),ae=$t("Keyword$anchor"),je=$t("Keyword$dynamicAnchor"),fe=$t("Keyword$ref"),ge=$t("Keyword$dynamicRef"),be=$t("Keyword$defs"),ye=$t("Keyword$comment"),me=$t("KeywordAllOf"),Ae=$t("KeywordAnyOf"),Ue=$t("KeywordOneOf"),ft=$t("KeywordNot"),Tt=$t("KeywordIf"),Dt=$t("KeywordThen"),Vt=$t("KeywordElse"),or=$t("KeywordDependentSchemas"),fr=$t("KeywordPrefixItems"),hr=$t("KeywordItems"),st=$t("KeywordContains"),ht=$t("KeywordProperties"),bt=$t("KeywordPatternProperties"),wt=$t("KeywordAdditionalProperties"),Zt=$t("KeywordPropertyNames"),kr=$t("KeywordUnevaluatedItems"),Gr=$t("KeywordUnevaluatedProperties"),hn=$t("KeywordType"),Lr=$t("KeywordEnum"),nn=$t("KeywordConst"),Qr=$t("KeywordConstraint"),kn=$t("KeywordDependentRequired"),Dn=$t("KeywordContentSchema"),za=$t("KeywordTitle"),ia=$t("KeywordDescription"),Zn=$t("KeywordDefault"),Gi=$t("KeywordDeprecated"),va=$t("KeywordReadOnly"),Ei=$t("KeywordWriteOnly"),Dh=$t("ExpandDeepButton");(0,p.useEffect)(()=>{A(c)},[c]),(0,p.useEffect)(()=>{A(x)},[x]);const ap=(0,p.useCallback)((co,Yi)=>{E(Yi),!Yi&&A(!1),n(co,Yi,!1)},[n]),ql=(0,p.useCallback)((co,Yi)=>{E(Yi),A(Yi),n(co,Yi,!0)},[n]);return p.createElement(lw.Provider,{value:R},p.createElement(rl.Provider,{value:x},p.createElement(cw.Provider,{value:X},p.createElement("article",{ref:a,"data-json-schema-level":T,className:cn()("json-schema-2020-12",{"json-schema-2020-12--embedded":B,"json-schema-2020-12--circular":G})},p.createElement("div",{className:"json-schema-2020-12-head"},H&&!G?p.createElement(p.Fragment,null,p.createElement(ie,{expanded:h,onChange:ap},p.createElement(za,{title:e,schema:t})),p.createElement(Dh,{expanded:h,onClick:ql})):p.createElement(za,{title:e,schema:t}),p.createElement(Gi,{schema:t}),p.createElement(va,{schema:t}),p.createElement(Ei,{schema:t}),p.createElement(hn,{schema:t,isCircular:G}),L.length>0&&L.map(co=>p.createElement(Qr,{key:`${co.scope}-${co.value}`,constraint:co}))),p.createElement("div",{className:cn()("json-schema-2020-12-body",{"json-schema-2020-12-body--collapsed":!h})},h&&p.createElement(p.Fragment,null,p.createElement(ia,{schema:t}),!G&&H&&p.createElement(p.Fragment,null,p.createElement(ht,{schema:t}),p.createElement(bt,{schema:t}),p.createElement(wt,{schema:t}),p.createElement(Gr,{schema:t}),p.createElement(Zt,{schema:t}),p.createElement(me,{schema:t}),p.createElement(Ae,{schema:t}),p.createElement(Ue,{schema:t}),p.createElement(ft,{schema:t}),p.createElement(Tt,{schema:t}),p.createElement(Dt,{schema:t}),p.createElement(Vt,{schema:t}),p.createElement(or,{schema:t}),p.createElement(fr,{schema:t}),p.createElement(hr,{schema:t}),p.createElement(kr,{schema:t}),p.createElement(st,{schema:t}),p.createElement(Dn,{schema:t})),p.createElement(Lr,{schema:t}),p.createElement(nn,{schema:t}),p.createElement(kn,{schema:t,dependentRequired:r}),p.createElement(Zn,{schema:t}),p.createElement(oe,{schema:t}),p.createElement(pe,{schema:t}),p.createElement(he,{schema:t}),p.createElement(ae,{schema:t}),p.createElement(je,{schema:t}),p.createElement(fe,{schema:t}),!G&&H&&p.createElement(be,{schema:t}),p.createElement(ge,{schema:t}),p.createElement(ye,{schema:t})))))))}),mx=qL,gx=({schema:t})=>t!=null&&t.$schema?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$schema"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$schema"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$schema)):null,yx=({schema:t})=>{const e=qc(),r=Fl(),[n,a]=(0,p.useState)(e||r),o=$t("Accordion"),u=(0,p.useCallback)(()=>{a(c=>!c)},[]);return t!=null&&t.$vocabulary?typeof t.$vocabulary!="object"?null:p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$vocabulary"},p.createElement(o,{expanded:n,onChange:u},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$vocabulary")),p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"object"),p.createElement("ul",null,n&&Object.entries(t.$vocabulary).map(([c,h])=>p.createElement("li",{key:c,className:cn()("json-schema-2020-12-$vocabulary-uri",{"json-schema-2020-12-$vocabulary-uri--disabled":!h})},p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},c))))):null},vx=({schema:t})=>t!=null&&t.$id?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$id"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$id"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$id)):null,bx=({schema:t})=>t!=null&&t.$anchor?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$anchor"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$anchor"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$anchor)):null,wx=({schema:t})=>t!=null&&t.$dynamicAnchor?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$dynamicAnchor"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$dynamicAnchor"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$dynamicAnchor)):null,Ex=({schema:t})=>t!=null&&t.$ref?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$ref"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$ref"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$ref)):null,_x=({schema:t})=>t!=null&&t.$dynamicRef?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$dynamicRef"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$dynamicRef"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$dynamicRef)):null,Sx=({schema:t})=>{const e=(t==null?void 0:t.$defs)||{},r=qc(),n=Fl(),[a,o]=(0,p.useState)(r||n),[u,c]=(0,p.useState)(!1),h=$t("Accordion"),E=$t("ExpandDeepButton"),x=$t("JSONSchema"),A=(0,p.useCallback)(()=>{o(R=>!R)},[]),T=(0,p.useCallback)((R,B)=>{o(B),c(B)},[]);return Object.keys(e).length===0?null:p.createElement(rl.Provider,{value:u},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$defs"},p.createElement(h,{expanded:a,onChange:A},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$defs")),p.createElement(E,{expanded:a,onClick:T}),p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"object"),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!a})},a&&p.createElement(p.Fragment,null,Object.entries(e).map(([R,B])=>p.createElement("li",{key:R,className:"json-schema-2020-12-property"},p.createElement(x,{name:R,schema:B})))))))},xx=({schema:t})=>t!=null&&t.$comment?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--$comment"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary"},"$comment"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary"},t.$comment)):null,kx=({schema:t})=>{const e=(t==null?void 0:t.allOf)||[],r=Vn(),n=qc(),a=Fl(),[o,u]=(0,p.useState)(n||a),[c,h]=(0,p.useState)(!1),E=$t("Accordion"),x=$t("ExpandDeepButton"),A=$t("JSONSchema"),T=$t("KeywordType"),R=(0,p.useCallback)(()=>{u(H=>!H)},[]),B=(0,p.useCallback)((H,G)=>{u(G),h(G)},[]);return Array.isArray(e)&&e.length!==0?p.createElement(rl.Provider,{value:c},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--allOf"},p.createElement(E,{expanded:o,onChange:R},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"All of")),p.createElement(x,{expanded:o,onClick:B}),p.createElement(T,{schema:{allOf:e}}),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!o})},o&&p.createElement(p.Fragment,null,e.map((H,G)=>p.createElement("li",{key:`#${G}`,className:"json-schema-2020-12-property"},p.createElement(A,{name:`#${G} ${r.getTitle(H)}`,schema:H}))))))):null},Cx=({schema:t})=>{const e=(t==null?void 0:t.anyOf)||[],r=Vn(),n=qc(),a=Fl(),[o,u]=(0,p.useState)(n||a),[c,h]=(0,p.useState)(!1),E=$t("Accordion"),x=$t("ExpandDeepButton"),A=$t("JSONSchema"),T=$t("KeywordType"),R=(0,p.useCallback)(()=>{u(H=>!H)},[]),B=(0,p.useCallback)((H,G)=>{u(G),h(G)},[]);return Array.isArray(e)&&e.length!==0?p.createElement(rl.Provider,{value:c},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--anyOf"},p.createElement(E,{expanded:o,onChange:R},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Any of")),p.createElement(x,{expanded:o,onClick:B}),p.createElement(T,{schema:{anyOf:e}}),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!o})},o&&p.createElement(p.Fragment,null,e.map((H,G)=>p.createElement("li",{key:`#${G}`,className:"json-schema-2020-12-property"},p.createElement(A,{name:`#${G} ${r.getTitle(H)}`,schema:H}))))))):null},Ax=({schema:t})=>{const e=(t==null?void 0:t.oneOf)||[],r=Vn(),n=qc(),a=Fl(),[o,u]=(0,p.useState)(n||a),[c,h]=(0,p.useState)(!1),E=$t("Accordion"),x=$t("ExpandDeepButton"),A=$t("JSONSchema"),T=$t("KeywordType"),R=(0,p.useCallback)(()=>{u(H=>!H)},[]),B=(0,p.useCallback)((H,G)=>{u(G),h(G)},[]);return Array.isArray(e)&&e.length!==0?p.createElement(rl.Provider,{value:c},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--oneOf"},p.createElement(E,{expanded:o,onChange:R},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"One of")),p.createElement(x,{expanded:o,onClick:B}),p.createElement(T,{schema:{oneOf:e}}),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!o})},o&&p.createElement(p.Fragment,null,e.map((H,G)=>p.createElement("li",{key:`#${G}`,className:"json-schema-2020-12-property"},p.createElement(A,{name:`#${G} ${r.getTitle(H)}`,schema:H}))))))):null},Ox=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"not"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Not");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--not"},p.createElement(r,{name:n,schema:t.not}))},jx=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"if"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"If");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--if"},p.createElement(r,{name:n,schema:t.if}))},Px=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"then"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Then");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--then"},p.createElement(r,{name:n,schema:t.then}))},Nx=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"else"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Else");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--if"},p.createElement(r,{name:n,schema:t.else}))},Ix=({schema:t})=>{const e=(t==null?void 0:t.dependentSchemas)||[],r=qc(),n=Fl(),[a,o]=(0,p.useState)(r||n),[u,c]=(0,p.useState)(!1),h=$t("Accordion"),E=$t("ExpandDeepButton"),x=$t("JSONSchema"),A=(0,p.useCallback)(()=>{o(R=>!R)},[]),T=(0,p.useCallback)((R,B)=>{o(B),c(B)},[]);return typeof e!="object"||Object.keys(e).length===0?null:p.createElement(rl.Provider,{value:u},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--dependentSchemas"},p.createElement(h,{expanded:a,onChange:A},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Dependent schemas")),p.createElement(E,{expanded:a,onClick:T}),p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"object"),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!a})},a&&p.createElement(p.Fragment,null,Object.entries(e).map(([R,B])=>p.createElement("li",{key:R,className:"json-schema-2020-12-property"},p.createElement(x,{name:R,schema:B})))))))},Tx=({schema:t})=>{const e=(t==null?void 0:t.prefixItems)||[],r=Vn(),n=qc(),a=Fl(),[o,u]=(0,p.useState)(n||a),[c,h]=(0,p.useState)(!1),E=$t("Accordion"),x=$t("ExpandDeepButton"),A=$t("JSONSchema"),T=$t("KeywordType"),R=(0,p.useCallback)(()=>{u(H=>!H)},[]),B=(0,p.useCallback)((H,G)=>{u(G),h(G)},[]);return Array.isArray(e)&&e.length!==0?p.createElement(rl.Provider,{value:c},p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--prefixItems"},p.createElement(E,{expanded:o,onChange:R},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Prefix items")),p.createElement(x,{expanded:o,onClick:B}),p.createElement(T,{schema:{prefixItems:e}}),p.createElement("ul",{className:cn()("json-schema-2020-12-keyword__children",{"json-schema-2020-12-keyword__children--collapsed":!o})},o&&p.createElement(p.Fragment,null,e.map((H,G)=>p.createElement("li",{key:`#${G}`,className:"json-schema-2020-12-property"},p.createElement(A,{name:`#${G} ${r.getTitle(H)}`,schema:H}))))))):null},Mx=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"items"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Items");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--items"},p.createElement(r,{name:n,schema:t.items}))},Rx=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"contains"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Contains");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--contains"},p.createElement(r,{name:n,schema:t.contains}))},Dx=({schema:t})=>{const e=Vn(),r=(t==null?void 0:t.properties)||{},n=Array.isArray(t==null?void 0:t.required)?t.required:[],a=$t("JSONSchema");return Object.keys(r).length===0?null:p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--properties"},p.createElement("ul",null,Object.entries(r).map(([o,u])=>{const c=n.includes(o),h=e.getDependentRequired(o,t);return p.createElement("li",{key:o,className:cn()("json-schema-2020-12-property",{"json-schema-2020-12-property--required":c})},p.createElement(a,{name:o,schema:u,dependentRequired:h}))})))},Lx=({schema:t})=>{const e=(t==null?void 0:t.patternProperties)||{},r=$t("JSONSchema");return Object.keys(e).length===0?null:p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--patternProperties"},p.createElement("ul",null,Object.entries(e).map(([n,a])=>p.createElement("li",{key:n,className:"json-schema-2020-12-property"},p.createElement(r,{name:n,schema:a})))))},$x=({schema:t})=>{const e=Vn(),{additionalProperties:r}=t,n=$t("JSONSchema");if(!e.hasKeyword(t,"additionalProperties"))return null;const a=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Additional properties");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--additionalProperties"},r===!0?p.createElement(p.Fragment,null,a,p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"allowed")):r===!1?p.createElement(p.Fragment,null,a,p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},"forbidden")):p.createElement(n,{name:a,schema:r}))},Fx=({schema:t})=>{const e=Vn(),{propertyNames:r}=t,n=$t("JSONSchema"),a=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Property names");return e.hasKeyword(t,"propertyNames")?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--propertyNames"},p.createElement(n,{name:a,schema:r})):null},Bx=({schema:t})=>{const e=Vn(),{unevaluatedItems:r}=t,n=$t("JSONSchema");if(!e.hasKeyword(t,"unevaluatedItems"))return null;const a=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Unevaluated items");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--unevaluatedItems"},p.createElement(n,{name:a,schema:r}))},qx=({schema:t})=>{const e=Vn(),{unevaluatedProperties:r}=t,n=$t("JSONSchema");if(!e.hasKeyword(t,"unevaluatedProperties"))return null;const a=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Unevaluated properties");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--unevaluatedProperties"},p.createElement(n,{name:a,schema:r}))},zx=({schema:t,isCircular:e=!1})=>{const r=Vn().getType(t),n=e?" [circular]":"";return p.createElement("strong",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--primary"},`${r}${n}`)},Ux=({schema:t})=>{const e=Vn();return Array.isArray(t==null?void 0:t.enum)?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--enum"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Allowed values"),p.createElement("ul",null,t.enum.map(r=>{const n=e.stringify(r);return p.createElement("li",{key:n},p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const"},n))}))):null},Vx=({schema:t})=>{const e=Vn();return e.hasKeyword(t,"const")?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--const"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Const"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const"},e.stringify(t.const))):null},zL=({constraint:t})=>p.createElement("span",{className:`json-schema-2020-12__constraint json-schema-2020-12__constraint--${t.scope}`},t.value),Wx=p.memo(zL),Kx=({dependentRequired:t})=>t.length===0?null:p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--dependentRequired"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Required when defined"),p.createElement("ul",null,t.map(e=>p.createElement("li",{key:e},p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--warning"},e))))),Hx=({schema:t})=>{const e=Vn(),r=$t("JSONSchema");if(!e.hasKeyword(t,"contentSchema"))return null;const n=p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Content schema");return p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--contentSchema"},p.createElement(r,{name:n,schema:t.contentSchema}))},Jx=({title:t="",schema:e})=>{const r=Vn(),n=t||r.getTitle(e);return n?p.createElement("div",{className:"json-schema-2020-12__title"},n):null},Gx=({schema:t})=>t!=null&&t.description?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--description"},p.createElement("div",{className:"json-schema-2020-12-core-keyword__value json-schema-2020-12-core-keyword__value--secondary"},t.description)):null,Yx=({schema:t})=>{const e=Vn();return e.hasKeyword(t,"default")?p.createElement("div",{className:"json-schema-2020-12-keyword json-schema-2020-12-keyword--default"},p.createElement("span",{className:"json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary"},"Default"),p.createElement("span",{className:"json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const"},e.stringify(t.default))):null},Xx=({schema:t})=>(t==null?void 0:t.deprecated)!==!0?null:p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--warning"},"deprecated"),Zx=({schema:t})=>(t==null?void 0:t.readOnly)!==!0?null:p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--muted"},"read-only"),Qx=({schema:t})=>(t==null?void 0:t.writeOnly)!==!0?null:p.createElement("span",{className:"json-schema-2020-12__attribute json-schema-2020-12__attribute--muted"},"write-only"),ek=({expanded:t=!1,children:e,onChange:r})=>{const n=$t("ChevronRightIcon"),a=(0,p.useCallback)(o=>{r(o,!t)},[t,r]);return p.createElement("button",{type:"button",className:"json-schema-2020-12-accordion",onClick:a},p.createElement("div",{className:"json-schema-2020-12-accordion__children"},e),p.createElement("span",{className:cn()("json-schema-2020-12-accordion__icon",{"json-schema-2020-12-accordion__icon--expanded":t,"json-schema-2020-12-accordion__icon--collapsed":!t})},p.createElement(n,null)))},tk=({expanded:t,onClick:e})=>{const r=(0,p.useCallback)(n=>{e(n,!t)},[t,e]);return p.createElement("button",{type:"button",className:"json-schema-2020-12-expand-deep-button",onClick:r},t?"Collapse all":"Expand all")},rk=()=>p.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},p.createElement("path",{d:"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"})),nk=t=>typeof t=="string"?`${t.charAt(0).toUpperCase()}${t.slice(1)}`:t,UL=(t,{lookup:e="extended"}={})=>{const r=Vn();if((t==null?void 0:t.title)!=null)return r.upperFirst(String(t.title));if(e==="extended"){if((t==null?void 0:t.$anchor)!=null)return r.upperFirst(String(t.$anchor));if((t==null?void 0:t.$id)!=null)return String(t.$id)}return""},Nh=(t,e=new WeakSet)=>{const r=Vn();if(t==null)return"any";if(r.isBooleanJSONSchema(t))return t?"any":"never";if(typeof t!="object"||e.has(t))return"any";e.add(t);const{type:n,prefixItems:a,items:o}=t,u=()=>{if(Array.isArray(a)){const E=a.map(A=>Nh(A,e)),x=o?Nh(o,e):"any";return`array<[${E.join(", ")}], ${x}>`}return o?`array<${Nh(o,e)}>`:"array<any>"};if(t.not&&Nh(t.not)==="any")return"never";const c=(E,x)=>Array.isArray(t[E])?`(${t[E].map(A=>Nh(A,e)).join(x)})`:null,h=[Array.isArray(n)?n.map(E=>E==="array"?u():E).join(" | "):n==="array"?u():["null","boolean","object","array","number","integer","string"].includes(n)?n:(()=>{if(Object.hasOwn(t,"prefixItems")||Object.hasOwn(t,"items")||Object.hasOwn(t,"contains"))return u();if(Object.hasOwn(t,"properties")||Object.hasOwn(t,"additionalProperties")||Object.hasOwn(t,"patternProperties"))return"object";if(["int32","int64"].includes(t.format))return"integer";if(["float","double"].includes(t.format))return"number";if(Object.hasOwn(t,"minimum")||Object.hasOwn(t,"maximum")||Object.hasOwn(t,"exclusiveMinimum")||Object.hasOwn(t,"exclusiveMaximum")||Object.hasOwn(t,"multipleOf"))return"number | integer";if(Object.hasOwn(t,"pattern")||Object.hasOwn(t,"format")||Object.hasOwn(t,"minLength")||Object.hasOwn(t,"maxLength"))return"string";if(t.const!==void 0){if(t.const===null)return"null";if(typeof t.const=="boolean")return"boolean";if(typeof t.const=="number")return Number.isInteger(t.const)?"integer":"number";if(typeof t.const=="string")return"string";if(Array.isArray(t.const))return"array<any>";if(typeof t.const=="object")return"object"}return null})(),c("oneOf"," | "),c("anyOf"," | "),c("allOf"," & ")].filter(Boolean).join(" | ");return e.delete(t),h||"any"},VL=t=>typeof t=="boolean",ak=(t,e)=>t!==null&&typeof t=="object"&&Object.hasOwn(t,e),ok=t=>{const e=Vn();return(t==null?void 0:t.$schema)||(t==null?void 0:t.$vocabulary)||(t==null?void 0:t.$id)||(t==null?void 0:t.$anchor)||(t==null?void 0:t.$dynamicAnchor)||(t==null?void 0:t.$ref)||(t==null?void 0:t.$dynamicRef)||(t==null?void 0:t.$defs)||(t==null?void 0:t.$comment)||(t==null?void 0:t.allOf)||(t==null?void 0:t.anyOf)||(t==null?void 0:t.oneOf)||e.hasKeyword(t,"not")||e.hasKeyword(t,"if")||e.hasKeyword(t,"then")||e.hasKeyword(t,"else")||(t==null?void 0:t.dependentSchemas)||(t==null?void 0:t.prefixItems)||e.hasKeyword(t,"items")||e.hasKeyword(t,"contains")||(t==null?void 0:t.properties)||(t==null?void 0:t.patternProperties)||e.hasKeyword(t,"additionalProperties")||e.hasKeyword(t,"propertyNames")||e.hasKeyword(t,"unevaluatedItems")||e.hasKeyword(t,"unevaluatedProperties")||(t==null?void 0:t.description)||(t==null?void 0:t.enum)||e.hasKeyword(t,"const")||e.hasKeyword(t,"contentSchema")||e.hasKeyword(t,"default")},ik=t=>t===null||["number","bigint","boolean"].includes(typeof t)?String(t):Array.isArray(t)?`[${t.map(ik).join(", ")}]`:JSON.stringify(t),Fy=(t,e,r)=>{const n=typeof e=="number",a=typeof r=="number";return n&&a?e===r?`${e} ${t}`:`[${e}, ${r}] ${t}`:n?`>= ${e} ${t}`:a?`<= ${r} ${t}`:null},WL=t=>{const e=[],r=(h=>{if(typeof(h==null?void 0:h.multipleOf)!="number"||h.multipleOf<=0||h.multipleOf===1)return null;const{multipleOf:E}=h;if(Number.isInteger(E))return`multiple of ${E}`;const x=nl(10,E.toString().split(".")[1].length);return`multiple of ${E*x}/${x}`})(t);r!==null&&e.push({scope:"number",value:r});const n=(h=>{const E=h==null?void 0:h.minimum,x=h==null?void 0:h.maximum,A=h==null?void 0:h.exclusiveMinimum,T=h==null?void 0:h.exclusiveMaximum,R=typeof E=="number",B=typeof x=="number",H=typeof A=="number",G=typeof T=="number",X=H&&(!R||E<A),L=G&&(!B||x>T);return(R||H)&&(B||G)?`${X?"(":"["}${X?A:E}, ${L?T:x}${L?")":"]"}`:R||H?`${X?">":"≥"} ${X?A:E}`:B||G?`${L?"<":"≤"} ${L?T:x}`:null})(t);n!==null&&e.push({scope:"number",value:n}),t!=null&&t.format&&e.push({scope:"string",value:t.format});const a=Fy("characters",t==null?void 0:t.minLength,t==null?void 0:t.maxLength);a!==null&&e.push({scope:"string",value:a}),t!=null&&t.pattern&&e.push({scope:"string",value:`matches ${t==null?void 0:t.pattern}`}),t!=null&&t.contentMediaType&&e.push({scope:"string",value:`media type: ${t.contentMediaType}`}),t!=null&&t.contentEncoding&&e.push({scope:"string",value:`encoding: ${t.contentEncoding}`});const o=Fy(t!=null&&t.hasUniqueItems?"unique items":"items",t==null?void 0:t.minItems,t==null?void 0:t.maxItems);o!==null&&e.push({scope:"array",value:o});const u=Fy("contained items",t==null?void 0:t.minContains,t==null?void 0:t.maxContains);u!==null&&e.push({scope:"array",value:u});const c=Fy("properties",t==null?void 0:t.minProperties,t==null?void 0:t.maxProperties);return c!==null&&e.push({scope:"object",value:c}),e},KL=(t,e)=>e!=null&&e.dependentRequired?Array.from(Object.entries(e.dependentRequired).reduce((r,[n,a])=>(Array.isArray(a)&&a.includes(t)&&r.add(n),r),new Set)):[],HL=(t,e={})=>{const r={components:lt({JSONSchema:mx,Keyword$schema:gx,Keyword$vocabulary:yx,Keyword$id:vx,Keyword$anchor:bx,Keyword$dynamicAnchor:wx,Keyword$ref:Ex,Keyword$dynamicRef:_x,Keyword$defs:Sx,Keyword$comment:xx,KeywordAllOf:kx,KeywordAnyOf:Cx,KeywordOneOf:Ax,KeywordNot:Ox,KeywordIf:jx,KeywordThen:Px,KeywordElse:Nx,KeywordDependentSchemas:Ix,KeywordPrefixItems:Tx,KeywordItems:Mx,KeywordContains:Rx,KeywordProperties:Dx,KeywordPatternProperties:Lx,KeywordAdditionalProperties:$x,KeywordPropertyNames:Fx,KeywordUnevaluatedItems:Bx,KeywordUnevaluatedProperties:qx,KeywordType:zx,KeywordEnum:Ux,KeywordConst:Vx,KeywordConstraint:Wx,KeywordDependentRequired:Kx,KeywordContentSchema:Hx,KeywordTitle:Jx,KeywordDescription:Gx,KeywordDefault:Yx,KeywordDeprecated:Xx,KeywordReadOnly:Zx,KeywordWriteOnly:Qx,Accordion:ek,ExpandDeepButton:tk,ChevronRightIcon:rk},e.components),config:lt({default$schema:"https://json-schema.org/draft/2020-12/schema",defaultExpandedLevels:0},e.config),fn:lt({upperFirst:nk,getTitle:UL,getType:Nh,isBooleanJSONSchema:VL,hasKeyword:ak,isExpandable:ok,stringify:ik,stringifyConstraints:WL,getDependentRequired:KL},e.fn)},n=a=>p.createElement(Ph.Provider,{value:r},p.createElement(t,a));return n.contexts={JSONSchemaContext:Ph},n.displayName=t.displayName,n},sk=()=>({components:{JSONSchema202012:mx,JSONSchema202012Keyword$schema:gx,JSONSchema202012Keyword$vocabulary:yx,JSONSchema202012Keyword$id:vx,JSONSchema202012Keyword$anchor:bx,JSONSchema202012Keyword$dynamicAnchor:wx,JSONSchema202012Keyword$ref:Ex,JSONSchema202012Keyword$dynamicRef:_x,JSONSchema202012Keyword$defs:Sx,JSONSchema202012Keyword$comment:xx,JSONSchema202012KeywordAllOf:kx,JSONSchema202012KeywordAnyOf:Cx,JSONSchema202012KeywordOneOf:Ax,JSONSchema202012KeywordNot:Ox,JSONSchema202012KeywordIf:jx,JSONSchema202012KeywordThen:Px,JSONSchema202012KeywordElse:Nx,JSONSchema202012KeywordDependentSchemas:Ix,JSONSchema202012KeywordPrefixItems:Tx,JSONSchema202012KeywordItems:Mx,JSONSchema202012KeywordContains:Rx,JSONSchema202012KeywordProperties:Dx,JSONSchema202012KeywordPatternProperties:Lx,JSONSchema202012KeywordAdditionalProperties:$x,JSONSchema202012KeywordPropertyNames:Fx,JSONSchema202012KeywordUnevaluatedItems:Bx,JSONSchema202012KeywordUnevaluatedProperties:qx,JSONSchema202012KeywordType:zx,JSONSchema202012KeywordEnum:Ux,JSONSchema202012KeywordConst:Vx,JSONSchema202012KeywordConstraint:Wx,JSONSchema202012KeywordDependentRequired:Kx,JSONSchema202012KeywordContentSchema:Hx,JSONSchema202012KeywordTitle:Jx,JSONSchema202012KeywordDescription:Gx,JSONSchema202012KeywordDefault:Yx,JSONSchema202012KeywordDeprecated:Xx,JSONSchema202012KeywordReadOnly:Zx,JSONSchema202012KeywordWriteOnly:Qx,JSONSchema202012Accordion:ek,JSONSchema202012ExpandDeepButton:tk,JSONSchema202012ChevronRightIcon:rk,withJSONSchema202012Context:HL,JSONSchema202012DeepExpansionContext:()=>rl},fn:{upperFirst:nk,jsonSchema202012:{isExpandable:ok,hasKeyword:ak,useFn:Vn,useConfig:dx,useComponent:$t,useIsExpandedDeeply:Fl}}});var JL=Te(11331),By=Te.n(JL);const GL=(t,{sample:e})=>((r,n={})=>{const{minItems:a,maxItems:o,uniqueItems:u}=n,{contains:c,minContains:h,maxContains:E}=n;let x=[...r];if(c!=null&&typeof c=="object"&&Number.isInteger(h)&&h>1){const A=x.at(0);for(let T=1;T<h;T+=1)x.unshift(A)}if(Number.isInteger(o)&&o>0&&(x=r.slice(0,o)),Number.isInteger(a)&&a>0)for(let A=0;x.length<a;A+=1)x.push(x[A%x.length]);return u===!0&&(x=Array.from(new Set(x))),x})(e,t),YL=()=>{throw new Error("Not implemented")},qy=t=>Vr()(t),zy=t=>t.at(0),rp=t=>typeof t=="boolean",Es=t=>By()(t),Bl=t=>rp(t)||Es(t),Uy=class{constructor(){Ee(this,"data",{})}register(e,r){this.data[e]=r}unregister(e){e===void 0?this.data={}:delete this.data[e]}get(e){return this.data[e]}},lk=()=>nl(2,30)>>>0,ck=()=>nl(2,53)-1,XL=()=>.1,ZL=()=>.1,QL=()=>"user@example.com",e$=()=>"실례@example.com",t$=()=>"example.com",r$=()=>"실례.com",n$=()=>"198.51.100.42",a$=()=>"2001:0db8:5b96:0000:0000:426f:8e17:642a",o$=()=>"https://example.com/",i$=()=>"path/index.html",s$=()=>"https://실례.com/",l$=()=>"path/실례.html",c$=()=>"3fa85f64-5717-4562-b3fc-2c963f66afa6",u$=()=>"https://example.com/dictionary/{term:1}/{term}",p$=()=>"/a/b/c",h$=()=>"1/0",d$=()=>new Date().toISOString(),f$=()=>new Date().toISOString().substring(0,10),m$=()=>new Date().toISOString().substring(11),g$=()=>"P3D",y$=()=>"********",v$=()=>"^[a-z]+$",Vy=new(Pk=class extends Uy{constructor(){super(...arguments);Lh(this,Qf,{int32:lk,int64:ck,float:XL,double:ZL,email:QL,"idn-email":e$,hostname:t$,"idn-hostname":r$,ipv4:n$,ipv6:a$,uri:o$,"uri-reference":i$,iri:s$,"iri-reference":l$,uuid:c$,"uri-template":u$,"json-pointer":p$,"relative-json-pointer":h$,"date-time":d$,date:f$,time:m$,duration:g$,password:y$,regex:v$});Ee(this,"data",lt({},Ss(this,Qf)))}get defaults(){return lt({},Ss(this,Qf))}},Qf=new WeakMap,Pk),uk=(t,e)=>typeof e=="function"?Vy.register(t,e):e===null?Vy.unregister(t):Vy.get(t);uk.getDefaults=()=>Vy.defaults;const Wy=uk;var b$=Te(48287).Buffer;const w$=t=>b$.from(t).toString("ascii");var E$=Te(48287).Buffer;const _$=t=>E$.from(t).toString("utf8");var S$=Te(48287).Buffer;const x$=t=>S$.from(t).toString("binary"),k$=t=>{let e="";for(let r=0;r<t.length;r++){const n=t.charCodeAt(r);if(n===61)e+="=3D";else if(n>=33&&n<=60||n>=62&&n<=126||n===9||n===32)e+=t.charAt(r);else if(n===13||n===10)e+=`\r
|
|
202
202
|
`;else if(n>126){const a=unescape(encodeURIComponent(t.charAt(r)));for(let o=0;o<a.length;o++)e+="="+("0"+a.charCodeAt(o).toString(16)).slice(-2).toUpperCase()}else e+="="+("0"+n.toString(16)).slice(-2).toUpperCase()}return e};var C$=Te(48287).Buffer;const A$=t=>C$.from(t).toString("hex");var O$=Te(48287).Buffer;const j$=t=>{const e=O$.from(t).toString("utf8"),r="ABCDEFGHIJKLMNOPQRSTUVWXYZ234567";let n=0,a="",o=0,u=0;for(let c=0;c<e.length;c++)for(o=o<<8|e.charCodeAt(c),u+=8;u>=5;)a+=r.charAt(o>>>u-5&31),u-=5;u>0&&(a+=r.charAt(o<<5-u&31),n=(8-8*e.length%5)%5);for(let c=0;c<n;c++)a+="=";return a};var P$=Te(48287).Buffer;const N$=t=>P$.from(t).toString("base64");var I$=Te(48287).Buffer;const T$=t=>I$.from(t).toString("base64url"),Ky=new(Nk=class extends Uy{constructor(){super(...arguments);Lh(this,em,{"7bit":w$,"8bit":_$,binary:x$,"quoted-printable":k$,base16:A$,base32:j$,base64:N$,base64url:T$});Ee(this,"data",lt({},Ss(this,em)))}get defaults(){return lt({},Ss(this,em))}},em=new WeakMap,Nk),pk=(t,e)=>typeof e=="function"?Ky.register(t,e):e===null?Ky.unregister(t):Ky.get(t);pk.getDefaults=()=>Ky.defaults;const hk=pk,M$={"text/plain":()=>"string","text/css":()=>".selector { border: 1px solid red }","text/csv":()=>"value1,value2,value3","text/html":()=>"<p>content</p>","text/calendar":()=>"BEGIN:VCALENDAR","text/javascript":()=>"console.dir('Hello world!');","text/xml":()=>'<person age="30">John Doe</person>',"text/*":()=>"string"},R$={"image/*":()=>qy(25).toString("binary")},D$={"audio/*":()=>qy(25).toString("binary")},L$={"video/*":()=>qy(25).toString("binary")},$$={"application/json":()=>'{"key":"value"}',"application/ld+json":()=>'{"name": "John Doe"}',"application/x-httpd-php":()=>"<?php echo '<p>Hello World!</p>'; ?>","application/rtf":()=>String.raw`{\rtf1\adeflang1025\ansi\ansicpg1252\uc1`,"application/x-sh":()=>'echo "Hello World!"',"application/xhtml+xml":()=>"<p>content</p>","application/*":()=>qy(25).toString("binary")},Ih=new(Ik=class extends Uy{constructor(){super(...arguments);Lh(this,tm,lt(lt(lt(lt(lt({},M$),R$),D$),L$),$$));Ee(this,"data",lt({},Ss(this,tm)))}get defaults(){return lt({},Ss(this,tm))}},tm=new WeakMap,Ik),dk=(t,e)=>{if(typeof e=="function")return Ih.register(t,e);if(e===null)return Ih.unregister(t);const r=t.split(";").at(0),n=`${r.split("/").at(0)}/*`;return Ih.get(t)||Ih.get(r)||Ih.get(n)};dk.getDefaults=()=>Ih.defaults;const fk=dk,pw=(t,e={})=>{const{maxLength:r,minLength:n}=e;let a=t;if(Number.isInteger(r)&&r>0&&(a=a.slice(0,r)),Number.isInteger(n)&&n>0){let o=0;for(;a.length<n;)a+=a[o++%a.length]}return a},F$=(t,{sample:e}={})=>{const{contentEncoding:r,contentMediaType:n,contentSchema:a}=t,{pattern:o,format:u}=t,c=hk(r)||I2();let h;return h=typeof o=="string"?pw((E=>{try{return new(Pm())(E).gen()}catch(x){return"string"}})(o),t):typeof u=="string"?(E=>{const{format:x}=E,A=Wy(x);return typeof A=="function"?A(E):"string"})(t):Bl(a)&&typeof n=="string"&&e!==void 0?Array.isArray(e)||typeof e=="object"?JSON.stringify(e):pw(String(e),t):typeof n=="string"?(E=>{const{contentMediaType:x}=E,A=fk(x);return typeof A=="function"?A(E):"string"})(t):pw("string",t),c(h)},mk=(t,e={})=>{const{minimum:r,maximum:n,exclusiveMinimum:a,exclusiveMaximum:o}=e,{multipleOf:u}=e,c=Number.isInteger(t)?1:Number.EPSILON;let h=typeof r=="number"?r:null,E=typeof n=="number"?n:null,x=t;if(typeof a=="number"&&(h=h!==null?Math.max(h,a+c):a+c),typeof o=="number"&&(E=E!==null?Math.min(E,o-c):o-c),x=h>E&&t||h||E||x,typeof u=="number"&&u>0){const A=x%u;x=A===0?x:x+u-A}return x},B$=t=>{const{format:e}=t;let r;return r=typeof e=="string"?(n=>{const{format:a}=n,o=Wy(a);return typeof o=="function"?o(n):0})(t):0,mk(r,t)},q$=t=>{const{format:e}=t;let r;return r=typeof e=="string"?(n=>{const{format:a}=n,o=Wy(a);if(typeof o=="function")return o(n);switch(a){case"int32":return lk();case"int64":return ck()}return 0})(t):0,mk(r,t)},z$=t=>typeof t.default!="boolean"||t.default,Hy=new Proxy({array:GL,object:YL,string:F$,number:B$,integer:q$,boolean:z$,null:()=>null},{get:(t,e)=>typeof e=="string"&&Object.hasOwn(t,e)?t[e]:()=>`Unknown Type: ${e}`}),gk=["array","object","number","integer","string","boolean","null"],Xf=t=>{if(!Es(t))return!1;const{examples:e,example:r,default:n}=t;return!!(Array.isArray(e)&&e.length>=1)||n!==void 0||r!==void 0},hw=t=>{if(!Es(t))return null;const{examples:e,example:r,default:n}=t;return Array.isArray(e)&&e.length>=1?e.at(0):n!==void 0?n:r!==void 0?r:void 0},Jy={array:["items","prefixItems","contains","maxContains","minContains","maxItems","minItems","uniqueItems","unevaluatedItems"],object:["properties","additionalProperties","patternProperties","propertyNames","minProperties","maxProperties","required","dependentSchemas","dependentRequired","unevaluatedProperties"],string:["pattern","format","minLength","maxLength","contentEncoding","contentMediaType","contentSchema"],integer:["minimum","maximum","exclusiveMinimum","exclusiveMaximum","multipleOf"]};Jy.number=Jy.integer;const dw="string",yk=t=>t===void 0?null:t===null?"null":Array.isArray(t)?"array":Number.isInteger(t)?"integer":typeof t,fw=t=>{if(Array.isArray(t)&&t.length>=1){if(t.includes("array"))return"array";if(t.includes("object"))return"object";{const e=zy(t);if(gk.includes(e))return e}}return gk.includes(t)?t:null},mw=(t,e=new WeakSet)=>{if(!Es(t)||e.has(t))return dw;e.add(t);let{type:r,const:n}=t;if(r=fw(r),typeof r!="string"){const a=Object.keys(Jy);e:for(let o=0;o<a.length;o+=1){const u=a[o],c=Jy[u];for(let h=0;h<c.length;h+=1){const E=c[h];if(Object.hasOwn(t,E)){r=u;break e}}}}if(typeof r!="string"&&n!==void 0){const a=yk(n);r=typeof a=="string"?a:r}if(typeof r!="string"){const a=E=>{if(Array.isArray(t[E])){const x=t[E].map(A=>mw(A,e));return fw(x)}return null},o=a("allOf"),u=a("anyOf"),c=a("oneOf"),h=t.not?mw(t.not,e):null;(o||u||c||h)&&(r=fw([o,u,c,h].filter(Boolean)))}if(typeof r!="string"&&Xf(t)){const a=hw(t),o=yk(a);r=typeof o=="string"?o:r}return e.delete(t),r||dw},vk=t=>mw(t),gw=t=>rp(t)?(e=>e===!1?{not:{}}:{})(t):Es(t)?t:{},Zf=(t,e,r={})=>{if(rp(t)&&t===!0)return!0;if(rp(t)&&t===!1)return!1;if(rp(e)&&e===!0)return!0;if(rp(e)&&e===!1)return!1;if(!Bl(t))return e;if(!Bl(e))return t;const n=lt(lt({},e),t);if(e.type&&t.type&&Array.isArray(e.type)&&typeof e.type=="string"){const a=_n(e.type).concat(t.type);n.type=Array.from(new Set(a))}if(Array.isArray(e.required)&&Array.isArray(t.required)&&(n.required=[...new Set([...t.required,...e.required])]),e.properties&&t.properties){const a=new Set([...Object.keys(e.properties),...Object.keys(t.properties)]);n.properties={};for(const o of a){const u=e.properties[o]||{},c=t.properties[o]||{};u.readOnly&&!r.includeReadOnly||u.writeOnly&&!r.includeWriteOnly?n.required=(n.required||[]).filter(h=>h!==o):n.properties[o]=Zf(c,u,r)}}return Bl(e.items)&&Bl(t.items)&&(n.items=Zf(t.items,e.items,r)),Bl(e.contains)&&Bl(t.contains)&&(n.contains=Zf(t.contains,e.contains,r)),Bl(e.contentSchema)&&Bl(t.contentSchema)&&(n.contentSchema=Zf(t.contentSchema,e.contentSchema,r)),n},Th=Zf,lo=(t,e={},r=void 0,n=!1)=>{var be,ye,me,Ae,Vt,or,fr,hr,st;if(t==null&&r===void 0)return;typeof(t==null?void 0:t.toJS)=="function"&&(t=t.toJS()),t=gw(t);let a=r!==void 0||Xf(t);const o=!a&&Array.isArray(t.oneOf)&&t.oneOf.length>0,u=!a&&Array.isArray(t.anyOf)&&t.anyOf.length>0;if(!a&&(o||u)){const ht=gw(zy(o?t.oneOf:t.anyOf));!(t=Th(t,ht,e)).xml&&ht.xml&&(t.xml=ht.xml),Xf(t)&&Xf(ht)&&(a=!0)}const c={};let{xml:h,properties:E,additionalProperties:x,items:A,contains:T}=t||{},R=vk(t),{includeReadOnly:B,includeWriteOnly:H}=e;h=h||{};let G,{name:X,prefix:L,namespace:ie}=h,oe={};Object.hasOwn(t,"type")||(t.type=R),n&&(X=X||"notagname",G=(L?`${L}:`:"")+X,ie)&&(c[L?`xmlns:${L}`:"xmlns"]=ie),n&&(oe[G]=[]);const pe=gr(E);let he,ae=0;const je=()=>Number.isInteger(t.maxProperties)&&t.maxProperties>0&&ae>=t.maxProperties,fe=ht=>!(Number.isInteger(t.maxProperties)&&t.maxProperties>0)||!je()&&(!(bt=>!Array.isArray(t.required)||t.required.length===0||!t.required.includes(bt))(ht)||t.maxProperties-ae-(()=>{if(!Array.isArray(t.required)||t.required.length===0)return 0;let bt=0;return n?t.required.forEach(wt=>bt+=oe[wt]===void 0?0:1):t.required.forEach(wt=>{var Zt;bt+=((Zt=oe[G])==null?void 0:Zt.find(kr=>kr[wt]!==void 0))===void 0?0:1}),t.required.length-bt})()>0);if(he=n?(ht,bt=void 0)=>{if(t&&pe[ht]){if(pe[ht].xml=pe[ht].xml||{},pe[ht].xml.attribute){const Zt=Array.isArray(pe[ht].enum)?zy(pe[ht].enum):void 0;if(Xf(pe[ht]))c[pe[ht].xml.name||ht]=hw(pe[ht]);else if(Zt!==void 0)c[pe[ht].xml.name||ht]=Zt;else{const kr=gw(pe[ht]),Gr=vk(kr),hn=pe[ht].xml.name||ht;c[hn]=Hy[Gr](kr)}return}pe[ht].xml.name=pe[ht].xml.name||ht}else pe[ht]||x===!1||(pe[ht]={xml:{name:ht}});let wt=lo(pe[ht],e,bt,n);fe(ht)&&(ae++,Array.isArray(wt)?oe[G]=oe[G].concat(wt):oe[G].push(wt))}:(ht,bt)=>{var wt;if(fe(ht)){if(By()((wt=t.discriminator)==null?void 0:wt.mapping)&&t.discriminator.propertyName===ht&&typeof t.$$ref=="string"){for(const Zt in t.discriminator.mapping)if(t.$$ref.search(t.discriminator.mapping[Zt])!==-1){oe[ht]=Zt;break}}else oe[ht]=lo(pe[ht],e,bt,n);ae++}},a){let ht;if(ht=r!==void 0?r:hw(t),!n){if(typeof ht=="number"&&R==="string")return`${ht}`;if(typeof ht!="string"||R==="string")return ht;try{return JSON.parse(ht)}catch(bt){return ht}}if(R==="array"){if(!Array.isArray(ht)){if(typeof ht=="string")return ht;ht=[ht]}let bt=[];return Es(A)&&(A.xml=A.xml||h||{},A.xml.name=A.xml.name||h.name,bt=ht.map(wt=>lo(A,e,wt,n))),Es(T)&&(T.xml=T.xml||h||{},T.xml.name=T.xml.name||h.name,bt=[lo(T,e,void 0,n),...bt]),bt=Hy.array(t,{sample:bt}),h.wrapped?(oe[G]=bt,da()(c)||oe[G].push({_attr:c})):oe=bt,oe}if(R==="object"){if(typeof ht=="string")return ht;for(const bt in ht)Object.hasOwn(ht,bt)&&((be=pe[bt])!=null&&be.readOnly&&!B||(ye=pe[bt])!=null&&ye.writeOnly&&!H||((Ae=(me=pe[bt])==null?void 0:me.xml)!=null&&Ae.attribute?c[pe[bt].xml.name||bt]=ht[bt]:he(bt,ht[bt])));return da()(c)||oe[G].push({_attr:c}),oe}return oe[G]=da()(c)?ht:[{_attr:c},ht],oe}if(R==="array"){let ht=[];if(Es(T))if(n&&(T.xml=T.xml||t.xml||{},T.xml.name=T.xml.name||h.name),Array.isArray(T.anyOf)){const Ue=A,{anyOf:bt}=Ue,wt=Pr(Ue,["anyOf"]);ht.push(...T.anyOf.map(Zt=>lo(Th(Zt,wt,e),e,void 0,n)))}else if(Array.isArray(T.oneOf)){const ft=A,{oneOf:bt}=ft,wt=Pr(ft,["oneOf"]);ht.push(...T.oneOf.map(Zt=>lo(Th(Zt,wt,e),e,void 0,n)))}else{if(!(!n||n&&h.wrapped))return lo(T,e,void 0,n);ht.push(lo(T,e,void 0,n))}if(Es(A))if(n&&(A.xml=A.xml||t.xml||{},A.xml.name=A.xml.name||h.name),Array.isArray(A.anyOf)){const Tt=A,{anyOf:bt}=Tt,wt=Pr(Tt,["anyOf"]);ht.push(...A.anyOf.map(Zt=>lo(Th(Zt,wt,e),e,void 0,n)))}else if(Array.isArray(A.oneOf)){const Dt=A,{oneOf:bt}=Dt,wt=Pr(Dt,["oneOf"]);ht.push(...A.oneOf.map(Zt=>lo(Th(Zt,wt,e),e,void 0,n)))}else{if(!(!n||n&&h.wrapped))return lo(A,e,void 0,n);ht.push(lo(A,e,void 0,n))}return ht=Hy.array(t,{sample:ht}),n&&h.wrapped?(oe[G]=ht,da()(c)||oe[G].push({_attr:c}),oe):ht}if(R==="object"){for(let ht in pe)Object.hasOwn(pe,ht)&&((Vt=pe[ht])!=null&&Vt.deprecated||(or=pe[ht])!=null&&or.readOnly&&!B||(fr=pe[ht])!=null&&fr.writeOnly&&!H||he(ht));if(n&&c&&oe[G].push({_attr:c}),je())return oe;if(rp(x)&&x)n?oe[G].push({additionalProp:"Anything can be here"}):oe.additionalProp1={},ae++;else if(Es(x)){const ht=x,bt=lo(ht,e,void 0,n);if(n&&typeof((hr=ht==null?void 0:ht.xml)==null?void 0:hr.name)=="string"&&((st=ht==null?void 0:ht.xml)==null?void 0:st.name)!=="notagname")oe[G].push(bt);else{const wt=Number.isInteger(t.minProperties)&&t.minProperties>0&&ae<t.minProperties?t.minProperties-ae:3;for(let Zt=1;Zt<=wt;Zt++){if(je())return oe;if(n){const kr={};kr["additionalProp"+Zt]=bt.notagname,oe[G].push(kr)}else oe["additionalProp"+Zt]=bt;ae++}}}return oe}let ge;if(t.const!==void 0)ge=t.const;else if(t&&Array.isArray(t.enum))ge=zy(_n(t.enum));else{const ht=Es(t.contentSchema)?lo(t.contentSchema,e,void 0,n):void 0;ge=Hy[R](t,{sample:ht})}return n?(oe[G]=da()(c)?ge:[{_attr:c},ge],oe):ge},bk=(t,e,r)=>{const n=lo(t,e,r,!0);if(n)return typeof n=="string"?n:wu()(n,{declaration:!0,indent:" "})},wk=(t,e,r)=>lo(t,e,r,!1),Ek=(t,e,r)=>[t,JSON.stringify(e),JSON.stringify(r)],U$=yc(bk,Ek),V$=yc(wk,Ek),_k=new(Tk=class extends Uy{constructor(){super(...arguments);Lh(this,rm,{});Ee(this,"data",lt({},Ss(this,rm)))}get defaults(){return lt({},Ss(this,rm))}},rm=new WeakMap,Tk),W$=(t,e)=>(e!==void 0&&_k.register(t,e),_k.get(t)),K$=[{when:/json/,shouldStringifyTypes:["string"]}],H$=["object"],J$=t=>(e,r,n,a)=>{const{fn:o}=t(),u=o.jsonSchema202012.memoizedSampleFromSchema(e,r,a),c=typeof u,h=K$.reduce((E,x)=>x.when.test(n)?[...E,...x.shouldStringifyTypes]:E,H$);return Yr()(h,E=>E===c)?JSON.stringify(u,null,2):u},G$=t=>(e,r,n,a)=>{const{fn:o}=t(),u=o.jsonSchema202012.getJsonSampleSchema(e,r,n,a);let c;try{c=Mn.dump(Mn.load(u),{lineWidth:-1},{schema:To}),c[c.length-1]===`
|
|
203
203
|
`&&(c=c.slice(0,c.length-1))}catch(h){return console.error(h),"error: could not generate yaml example"}return c.replace(/\t/g," ")},Y$=t=>(e,r,n)=>{const{fn:a}=t();if(e&&!e.xml&&(e.xml={}),e&&!e.xml.name){if(!e.$$ref&&(e.type||e.items||e.properties||e.additionalProperties))return`<?xml version="1.0" encoding="UTF-8"?>
|
|
204
|
-
<!-- XML example cannot be generated; root element name is undefined -->`;if(e.$$ref){let o=e.$$ref.match(/\S*\/(\S+)$/);e.xml.name=o[1]}}return a.jsonSchema202012.memoizedCreateXMLExample(e,r,n)},X$=t=>(e,r="",n={},a=void 0)=>{const{fn:o}=t();return typeof(e==null?void 0:e.toJS)=="function"&&(e=e.toJS()),typeof(a==null?void 0:a.toJS)=="function"&&(a=a.toJS()),/xml/.test(r)?o.jsonSchema202012.getXmlSampleSchema(e,n,a):/(yaml|yml)/.test(r)?o.jsonSchema202012.getYamlSampleSchema(e,n,r,a):o.jsonSchema202012.getJsonSampleSchema(e,n,r,a)},Sk=({getSystem:t})=>{const e=J$(t),r=G$(t),n=Y$(t),a=X$(t);return{fn:{jsonSchema202012:{sampleFromSchema:wk,sampleFromSchemaGeneric:lo,sampleOptionAPI:W$,sampleEncoderAPI:hk,sampleFormatAPI:Wy,sampleMediaTypeAPI:fk,createXMLExample:bk,memoizedSampleFromSchema:V$,memoizedCreateXMLExample:U$,getJsonSampleSchema:e,getYamlSampleSchema:r,getXmlSampleSchema:n,getSampleSchema:a,mergeJsonSchema:Th}}}};function xk(){return[ix,iw,sk,Sk,$L]}const Z$=t=>()=>({fn:t.fn,components:t.components}),Q$=t=>{const e=xe()({layout:{layout:t.layout,filter:t.filter},spec:{spec:"",url:t.url},requestSnippets:t.requestSnippets},t.initialState);if(t.initialState)for(const[r,n]of Object.entries(t.initialState))n===void 0&&delete e[r];return{system:{configs:t.configs},plugins:t.presets,state:e}},eF=()=>t=>{const e=t.queryConfigEnabled?(()=>{const r=new URLSearchParams(Xe.location.search);return Object.fromEntries(r)})():{};return Object.entries(e).reduce((r,[n,a])=>(n==="config"?r.configUrl=a:n==="urls.primaryName"?r[n]=a:r=ju()(r,n,a),r),{})},tF=({url:t,system:e})=>r=>ir(this,null,function*(){var a;if(!t)return{};if(typeof((a=e.configsActions)==null?void 0:a.getConfigByUrl)!="function")return{};const n=(()=>{const o={};return o.promise=new Promise((u,c)=>{o.resolve=u,o.reject=c}),o})();return e.configsActions.getConfigByUrl({url:t,loadRemoteConfig:!0,requestInterceptor:r.requestInterceptor,responseInterceptor:r.responseInterceptor},o=>{n.resolve(o)}),n.promise}),rF=()=>()=>{const t={};return globalThis.location&&(t.oauth2RedirectUrl=`${globalThis.location.protocol}//${globalThis.location.host}${globalThis.location.pathname.substring(0,globalThis.location.pathname.lastIndexOf("/"))}/oauth2-redirect.html`),t},oa=Object.freeze({dom_id:null,domNode:null,spec:{},url:"",urls:null,configUrl:null,layout:"BaseLayout",docExpansion:"list",maxDisplayedTags:-1,filter:!1,validatorUrl:"https://validator.swagger.io/validator",oauth2RedirectUrl:void 0,persistAuthorization:!1,configs:{},displayOperationId:!1,displayRequestDuration:!1,deepLinking:!1,tryItOutEnabled:!1,requestInterceptor:t=>(t.curlOptions=[],t),responseInterceptor:t=>t,showMutatedRequest:!0,defaultModelRendering:"example",defaultModelExpandDepth:1,defaultModelsExpandDepth:1,showExtensions:!1,showCommonExtensions:!1,withCredentials:!1,requestSnippetsEnabled:!1,requestSnippets:{generators:{curl_bash:{title:"cURL (bash)",syntax:"bash"},curl_powershell:{title:"cURL (PowerShell)",syntax:"powershell"},curl_cmd:{title:"cURL (CMD)",syntax:"bash"}},defaultExpanded:!0,languages:null},supportedSubmitMethods:["get","put","post","delete","options","head","patch","trace"],queryConfigEnabled:!1,presets:[xk],plugins:[],initialState:{},fn:{},components:{},syntaxHighlight:{activated:!0,theme:"agate"},operationsSorter:null,tagsSorter:null,onComplete:null,modelPropertyMacro:null,parameterMacro:null});var nF=Te(61448),aF=Te.n(nF),oF=Te(77731),iF=Te.n(oF);const yw=(t,e=[])=>Array.isArray(t)?t:e,Ji=(t,e=!1)=>t===!0||t==="true"||t===1||t==="1"||t!==!1&&t!=="false"&&t!==0&&t!=="0"&&e,sF=t=>t===null||t==="null"?null:t,lF=t=>{const e=String(t);return Ji(t,e)},kk=(t,e)=>typeof t=="function"?t:e,cF=t=>Array.isArray(t)?t:null,vw=t=>typeof t=="function"?t:null,bw=t=>t===null||t==="null"?null:String(t),ww=(t,e=-1)=>{const r=parseInt(t,10);return Number.isNaN(r)?e:r},Mh=(t,e={})=>By()(t)?t:e,Ck=t=>typeof t=="function"||typeof t=="string"?t:null,Rh=t=>String(t),uF=(t,e)=>By()(t)?t:t===!1||t==="false"||t===0||t==="0"?{activated:!1}:e,pF=t=>t===void 0||t==="undefined"?void 0:String(t),Ak={components:{typeCaster:Mh},configs:{typeCaster:Mh},configUrl:{typeCaster:bw},deepLinking:{typeCaster:Ji,defaultValue:oa.deepLinking},defaultModelExpandDepth:{typeCaster:ww,defaultValue:oa.defaultModelExpandDepth},defaultModelRendering:{typeCaster:Rh},defaultModelsExpandDepth:{typeCaster:ww,defaultValue:oa.defaultModelsExpandDepth},displayOperationId:{typeCaster:Ji,defaultValue:oa.displayOperationId},displayRequestDuration:{typeCaster:Ji,defaultValue:oa.displayRequestDuration},docExpansion:{typeCaster:Rh},dom_id:{typeCaster:bw},domNode:{typeCaster:sF},filter:{typeCaster:lF},fn:{typeCaster:Mh},initialState:{typeCaster:Mh},layout:{typeCaster:Rh},maxDisplayedTags:{typeCaster:ww,defaultValue:oa.maxDisplayedTags},modelPropertyMacro:{typeCaster:vw},oauth2RedirectUrl:{typeCaster:pF},onComplete:{typeCaster:vw},operationsSorter:{typeCaster:Ck},paramaterMacro:{typeCaster:vw},persistAuthorization:{typeCaster:Ji,defaultValue:oa.persistAuthorization},plugins:{typeCaster:yw,defaultValue:oa.plugins},presets:{typeCaster:yw,defaultValue:oa.presets},requestInterceptor:{typeCaster:kk,defaultValue:oa.requestInterceptor},requestSnippets:{typeCaster:Mh,defaultValue:oa.requestSnippets},requestSnippetsEnabled:{typeCaster:Ji,defaultValue:oa.requestSnippetsEnabled},responseInterceptor:{typeCaster:kk,defaultValue:oa.responseInterceptor},showCommonExtensions:{typeCaster:Ji,defaultValue:oa.showCommonExtensions},showExtensions:{typeCaster:Ji,defaultValue:oa.showExtensions},showMutatedRequest:{typeCaster:Ji,defaultValue:oa.showMutatedRequest},spec:{typeCaster:Mh,defaultValue:oa.spec},supportedSubmitMethods:{typeCaster:yw,defaultValue:oa.supportedSubmitMethods},syntaxHighlight:{typeCaster:uF,defaultValue:oa.syntaxHighlight},"syntaxHighlight.activated":{typeCaster:Ji,defaultValue:oa.syntaxHighlight.activated},"syntaxHighlight.theme":{typeCaster:Rh},tagsSorter:{typeCaster:Ck},tryItOutEnabled:{typeCaster:Ji,defaultValue:oa.tryItOutEnabled},url:{typeCaster:Rh},urls:{typeCaster:cF},"urls.primaryName":{typeCaster:Rh},validatorUrl:{typeCaster:bw},withCredentials:{typeCaster:Ji,defaultValue:oa.withCredentials}},Ok=t=>Object.entries(Ak).reduce((e,[r,{typeCaster:n,defaultValue:a}])=>{if(aF()(e,r)){const o=n(hu()(e,r),a);e=iF()(r,o,e)}return e},lt({},t)),hF=(t,...e)=>{let r=Symbol.for("domNode"),n=Symbol.for("primaryName");const a=[];for(const u of e){const c=lt({},u);Object.hasOwn(c,"domNode")&&(r=c.domNode,delete c.domNode),Object.hasOwn(c,"urls.primaryName")?(n=c["urls.primaryName"],delete c["urls.primaryName"]):Array.isArray(c.urls)&&Object.hasOwn(c.urls,"primaryName")&&(n=c.urls.primaryName,delete c.urls.primaryName),a.push(c)}const o=xe()(t,...a);return r!==Symbol.for("domNode")&&(o.domNode=r),n!==Symbol.for("primaryName")&&Array.isArray(o.urls)&&(o.urls.primaryName=n),Ok(o)};function zc(t){const e=eF()(t),r=rF()(),n=zc.config.merge({},zc.config.defaults,r,t,e),a=Q$(n),o=Z$(n),u=new wa(a);u.register([n.plugins,o]);const c=u.getSystem(),h=A=>{u.setConfigs(A),c.configsActions.loaded()},E=A=>{!e.url&&typeof A.spec=="object"&&Object.keys(A.spec).length>0?(c.specActions.updateUrl(""),c.specActions.updateLoadingStatus("success"),c.specActions.updateSpec(JSON.stringify(A.spec))):typeof c.specActions.download=="function"&&A.url&&!A.urls&&(c.specActions.updateUrl(A.url),c.specActions.download(A.url))},x=A=>{if(A.domNode)c.render(A.domNode,"App");else if(A.dom_id){const T=document.querySelector(A.dom_id);c.render(T,"App")}else A.dom_id===null||A.domNode===null||console.error("Skipped rendering: no `dom_id` or `domNode` was specified")};return n.configUrl?(ir(this,null,function*(){const{configUrl:A}=n,T=yield tF({url:A,system:c})(n),R=zc.config.merge({},n,T,e);h(R),T!==null&&E(R),x(R)}),c):(h(n),E(n),x(n),c)}zc.System=wa,zc.config={defaults:oa,merge:hF,typeCast:Ok,typeCastMappings:Ak},zc.presets={base:ix,apis:xk},zc.plugins={Auth:Qi,Configs:uu,DeepLining:gi,Err:_p,Filter:Jh,Icons:gl,JSONSchema5:gd,JSONSchema5Samples:Up,JSONSchema202012:sk,JSONSchema202012Samples:Sk,Layout:Ap,Logs:ed,OpenAPI30:iw,OpenAPI31:iw,OnComplete:cs,RequestSnippets:$s,Spec:Ru,SwaggerClient:m2,Util:g2,View:R2,ViewLegacy:D2,DownloadUrl:L2,SyntaxHighlighting:X2,Versions:Z2,SafeRender:rS};const dF=zc})(),Vc=Vc.default})())})(Mw);var Uk=Mw.exports;const Vk=zk(Uk),Rw="API_DOC:DESTINATION_URL_KEY",Dw=()=>localStorage.getItem(Rw),Wk=Object.freeze(Object.defineProperty({__proto__:null,default:()=>{const sa=Dr.useAPIClient(),{t:la}=Cw(),ca=sr.useRef(),{data:Kn}=Dr.useRequest({url:"swagger:getUrls"}),al=Dr.useApp(),zl=_=>{if(
|
|
204
|
+
<!-- XML example cannot be generated; root element name is undefined -->`;if(e.$$ref){let o=e.$$ref.match(/\S*\/(\S+)$/);e.xml.name=o[1]}}return a.jsonSchema202012.memoizedCreateXMLExample(e,r,n)},X$=t=>(e,r="",n={},a=void 0)=>{const{fn:o}=t();return typeof(e==null?void 0:e.toJS)=="function"&&(e=e.toJS()),typeof(a==null?void 0:a.toJS)=="function"&&(a=a.toJS()),/xml/.test(r)?o.jsonSchema202012.getXmlSampleSchema(e,n,a):/(yaml|yml)/.test(r)?o.jsonSchema202012.getYamlSampleSchema(e,n,r,a):o.jsonSchema202012.getJsonSampleSchema(e,n,r,a)},Sk=({getSystem:t})=>{const e=J$(t),r=G$(t),n=Y$(t),a=X$(t);return{fn:{jsonSchema202012:{sampleFromSchema:wk,sampleFromSchemaGeneric:lo,sampleOptionAPI:W$,sampleEncoderAPI:hk,sampleFormatAPI:Wy,sampleMediaTypeAPI:fk,createXMLExample:bk,memoizedSampleFromSchema:V$,memoizedCreateXMLExample:U$,getJsonSampleSchema:e,getYamlSampleSchema:r,getXmlSampleSchema:n,getSampleSchema:a,mergeJsonSchema:Th}}}};function xk(){return[ix,iw,sk,Sk,$L]}const Z$=t=>()=>({fn:t.fn,components:t.components}),Q$=t=>{const e=xe()({layout:{layout:t.layout,filter:t.filter},spec:{spec:"",url:t.url},requestSnippets:t.requestSnippets},t.initialState);if(t.initialState)for(const[r,n]of Object.entries(t.initialState))n===void 0&&delete e[r];return{system:{configs:t.configs},plugins:t.presets,state:e}},eF=()=>t=>{const e=t.queryConfigEnabled?(()=>{const r=new URLSearchParams(Xe.location.search);return Object.fromEntries(r)})():{};return Object.entries(e).reduce((r,[n,a])=>(n==="config"?r.configUrl=a:n==="urls.primaryName"?r[n]=a:r=ju()(r,n,a),r),{})},tF=({url:t,system:e})=>r=>ir(this,null,function*(){var a;if(!t)return{};if(typeof((a=e.configsActions)==null?void 0:a.getConfigByUrl)!="function")return{};const n=(()=>{const o={};return o.promise=new Promise((u,c)=>{o.resolve=u,o.reject=c}),o})();return e.configsActions.getConfigByUrl({url:t,loadRemoteConfig:!0,requestInterceptor:r.requestInterceptor,responseInterceptor:r.responseInterceptor},o=>{n.resolve(o)}),n.promise}),rF=()=>()=>{const t={};return globalThis.location&&(t.oauth2RedirectUrl=`${globalThis.location.protocol}//${globalThis.location.host}${globalThis.location.pathname.substring(0,globalThis.location.pathname.lastIndexOf("/"))}/oauth2-redirect.html`),t},oa=Object.freeze({dom_id:null,domNode:null,spec:{},url:"",urls:null,configUrl:null,layout:"BaseLayout",docExpansion:"list",maxDisplayedTags:-1,filter:!1,validatorUrl:"https://validator.swagger.io/validator",oauth2RedirectUrl:void 0,persistAuthorization:!1,configs:{},displayOperationId:!1,displayRequestDuration:!1,deepLinking:!1,tryItOutEnabled:!1,requestInterceptor:t=>(t.curlOptions=[],t),responseInterceptor:t=>t,showMutatedRequest:!0,defaultModelRendering:"example",defaultModelExpandDepth:1,defaultModelsExpandDepth:1,showExtensions:!1,showCommonExtensions:!1,withCredentials:!1,requestSnippetsEnabled:!1,requestSnippets:{generators:{curl_bash:{title:"cURL (bash)",syntax:"bash"},curl_powershell:{title:"cURL (PowerShell)",syntax:"powershell"},curl_cmd:{title:"cURL (CMD)",syntax:"bash"}},defaultExpanded:!0,languages:null},supportedSubmitMethods:["get","put","post","delete","options","head","patch","trace"],queryConfigEnabled:!1,presets:[xk],plugins:[],initialState:{},fn:{},components:{},syntaxHighlight:{activated:!0,theme:"agate"},operationsSorter:null,tagsSorter:null,onComplete:null,modelPropertyMacro:null,parameterMacro:null});var nF=Te(61448),aF=Te.n(nF),oF=Te(77731),iF=Te.n(oF);const yw=(t,e=[])=>Array.isArray(t)?t:e,Ji=(t,e=!1)=>t===!0||t==="true"||t===1||t==="1"||t!==!1&&t!=="false"&&t!==0&&t!=="0"&&e,sF=t=>t===null||t==="null"?null:t,lF=t=>{const e=String(t);return Ji(t,e)},kk=(t,e)=>typeof t=="function"?t:e,cF=t=>Array.isArray(t)?t:null,vw=t=>typeof t=="function"?t:null,bw=t=>t===null||t==="null"?null:String(t),ww=(t,e=-1)=>{const r=parseInt(t,10);return Number.isNaN(r)?e:r},Mh=(t,e={})=>By()(t)?t:e,Ck=t=>typeof t=="function"||typeof t=="string"?t:null,Rh=t=>String(t),uF=(t,e)=>By()(t)?t:t===!1||t==="false"||t===0||t==="0"?{activated:!1}:e,pF=t=>t===void 0||t==="undefined"?void 0:String(t),Ak={components:{typeCaster:Mh},configs:{typeCaster:Mh},configUrl:{typeCaster:bw},deepLinking:{typeCaster:Ji,defaultValue:oa.deepLinking},defaultModelExpandDepth:{typeCaster:ww,defaultValue:oa.defaultModelExpandDepth},defaultModelRendering:{typeCaster:Rh},defaultModelsExpandDepth:{typeCaster:ww,defaultValue:oa.defaultModelsExpandDepth},displayOperationId:{typeCaster:Ji,defaultValue:oa.displayOperationId},displayRequestDuration:{typeCaster:Ji,defaultValue:oa.displayRequestDuration},docExpansion:{typeCaster:Rh},dom_id:{typeCaster:bw},domNode:{typeCaster:sF},filter:{typeCaster:lF},fn:{typeCaster:Mh},initialState:{typeCaster:Mh},layout:{typeCaster:Rh},maxDisplayedTags:{typeCaster:ww,defaultValue:oa.maxDisplayedTags},modelPropertyMacro:{typeCaster:vw},oauth2RedirectUrl:{typeCaster:pF},onComplete:{typeCaster:vw},operationsSorter:{typeCaster:Ck},paramaterMacro:{typeCaster:vw},persistAuthorization:{typeCaster:Ji,defaultValue:oa.persistAuthorization},plugins:{typeCaster:yw,defaultValue:oa.plugins},presets:{typeCaster:yw,defaultValue:oa.presets},requestInterceptor:{typeCaster:kk,defaultValue:oa.requestInterceptor},requestSnippets:{typeCaster:Mh,defaultValue:oa.requestSnippets},requestSnippetsEnabled:{typeCaster:Ji,defaultValue:oa.requestSnippetsEnabled},responseInterceptor:{typeCaster:kk,defaultValue:oa.responseInterceptor},showCommonExtensions:{typeCaster:Ji,defaultValue:oa.showCommonExtensions},showExtensions:{typeCaster:Ji,defaultValue:oa.showExtensions},showMutatedRequest:{typeCaster:Ji,defaultValue:oa.showMutatedRequest},spec:{typeCaster:Mh,defaultValue:oa.spec},supportedSubmitMethods:{typeCaster:yw,defaultValue:oa.supportedSubmitMethods},syntaxHighlight:{typeCaster:uF,defaultValue:oa.syntaxHighlight},"syntaxHighlight.activated":{typeCaster:Ji,defaultValue:oa.syntaxHighlight.activated},"syntaxHighlight.theme":{typeCaster:Rh},tagsSorter:{typeCaster:Ck},tryItOutEnabled:{typeCaster:Ji,defaultValue:oa.tryItOutEnabled},url:{typeCaster:Rh},urls:{typeCaster:cF},"urls.primaryName":{typeCaster:Rh},validatorUrl:{typeCaster:bw},withCredentials:{typeCaster:Ji,defaultValue:oa.withCredentials}},Ok=t=>Object.entries(Ak).reduce((e,[r,{typeCaster:n,defaultValue:a}])=>{if(aF()(e,r)){const o=n(hu()(e,r),a);e=iF()(r,o,e)}return e},lt({},t)),hF=(t,...e)=>{let r=Symbol.for("domNode"),n=Symbol.for("primaryName");const a=[];for(const u of e){const c=lt({},u);Object.hasOwn(c,"domNode")&&(r=c.domNode,delete c.domNode),Object.hasOwn(c,"urls.primaryName")?(n=c["urls.primaryName"],delete c["urls.primaryName"]):Array.isArray(c.urls)&&Object.hasOwn(c.urls,"primaryName")&&(n=c.urls.primaryName,delete c.urls.primaryName),a.push(c)}const o=xe()(t,...a);return r!==Symbol.for("domNode")&&(o.domNode=r),n!==Symbol.for("primaryName")&&Array.isArray(o.urls)&&(o.urls.primaryName=n),Ok(o)};function zc(t){const e=eF()(t),r=rF()(),n=zc.config.merge({},zc.config.defaults,r,t,e),a=Q$(n),o=Z$(n),u=new wa(a);u.register([n.plugins,o]);const c=u.getSystem(),h=A=>{u.setConfigs(A),c.configsActions.loaded()},E=A=>{!e.url&&typeof A.spec=="object"&&Object.keys(A.spec).length>0?(c.specActions.updateUrl(""),c.specActions.updateLoadingStatus("success"),c.specActions.updateSpec(JSON.stringify(A.spec))):typeof c.specActions.download=="function"&&A.url&&!A.urls&&(c.specActions.updateUrl(A.url),c.specActions.download(A.url))},x=A=>{if(A.domNode)c.render(A.domNode,"App");else if(A.dom_id){const T=document.querySelector(A.dom_id);c.render(T,"App")}else A.dom_id===null||A.domNode===null||console.error("Skipped rendering: no `dom_id` or `domNode` was specified")};return n.configUrl?(ir(this,null,function*(){const{configUrl:A}=n,T=yield tF({url:A,system:c})(n),R=zc.config.merge({},n,T,e);h(R),T!==null&&E(R),x(R)}),c):(h(n),E(n),x(n),c)}zc.System=wa,zc.config={defaults:oa,merge:hF,typeCast:Ok,typeCastMappings:Ak},zc.presets={base:ix,apis:xk},zc.plugins={Auth:Qi,Configs:uu,DeepLining:gi,Err:_p,Filter:Jh,Icons:gl,JSONSchema5:gd,JSONSchema5Samples:Up,JSONSchema202012:sk,JSONSchema202012Samples:Sk,Layout:Ap,Logs:ed,OpenAPI30:iw,OpenAPI31:iw,OnComplete:cs,RequestSnippets:$s,Spec:Ru,SwaggerClient:m2,Util:g2,View:R2,ViewLegacy:D2,DownloadUrl:L2,SyntaxHighlighting:X2,Versions:Z2,SafeRender:rS};const dF=zc})(),Vc=Vc.default})())})(Mw);var Uk=Mw.exports;const Vk=zk(Uk),Rw="API_DOC:DESTINATION_URL_KEY",Dw=()=>localStorage.getItem(Rw),Wk=Object.freeze(Object.defineProperty({__proto__:null,default:()=>{const sa=Dr.useAPIClient(),{t:la}=Cw(),ca=sr.useRef(),{data:Kn}=Dr.useRequest({url:"swagger:getUrls"}),al=Dr.useApp(),zl=_=>{if(_.headers["X-Hostname"]=window.location.hostname,!_.headers.Authorization){const j=Uc.getSubAppName(al.getPublicPath());j&&(_.headers["X-App"]=j),_.headers.Authorization=`Bearer ${sa.auth.getToken()}`}return _},[Te,Vc]=sr.useState(Dw());return sr.useEffect(()=>{Te&&localStorage.setItem(Rw,Te)},[Te]),sr.useEffect(()=>{var _;(_=Kn==null?void 0:Kn.data)!=null&&_.length&&(!Te||!Kn.data.find(j=>j.url===Dw()))&&Vc(Kn.data[0].url)},[Te,Kn]),sr.useEffect(()=>{Vk({requestInterceptor:zl,url:Te,domNode:ca.current})},[Te]),Te?jt.jsxs(Ln.Space,{direction:"vertical",style:{width:"100%"},children:[jt.jsx("div",{style:{display:"flex",justifyContent:"center",width:"100%"},children:jt.jsxs("div",{className:Dr.css`
|
|
205
205
|
display: flex;
|
|
206
206
|
align-items: center;
|
|
207
207
|
gap: 8px;
|
package/dist/externalVersion.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
module.exports = {
|
|
2
2
|
"react": "18.3.1",
|
|
3
|
-
"@tachybase/client": "0.23.
|
|
4
|
-
"@tachybase/sdk": "0.23.
|
|
3
|
+
"@tachybase/client": "0.23.48",
|
|
4
|
+
"@tachybase/sdk": "0.23.48",
|
|
5
5
|
"antd": "5.22.5",
|
|
6
6
|
"ahooks": "3.8.4",
|
|
7
7
|
"@ant-design/icons": "5.5.2",
|
|
8
|
-
"@tachybase/actions": "0.23.
|
|
9
|
-
"@tachybase/server": "0.23.
|
|
8
|
+
"@tachybase/actions": "0.23.48",
|
|
9
|
+
"@tachybase/server": "0.23.48",
|
|
10
10
|
"react-i18next": "15.2.0",
|
|
11
|
-
"@tachybase/utils": "0.23.
|
|
12
|
-
"@tachybase/database": "0.23.
|
|
11
|
+
"@tachybase/utils": "0.23.48",
|
|
12
|
+
"@tachybase/database": "0.23.48"
|
|
13
13
|
};
|
package/dist/server/plugin.js
CHANGED
|
@@ -26,7 +26,6 @@ var import_ENV_controller = require("./actions/ENV-controller");
|
|
|
26
26
|
var import_middleware_controller = require("./actions/middleware-controller");
|
|
27
27
|
var import_swagger = require("./swagger");
|
|
28
28
|
class PluginDevToolServer extends import_server.Plugin {
|
|
29
|
-
swagger;
|
|
30
29
|
constructor(app, options) {
|
|
31
30
|
super(app, options);
|
|
32
31
|
this.swagger = new import_swagger.SwaggerManager(this);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tachybase/plugin-devtools",
|
|
3
3
|
"displayName": "Devtools",
|
|
4
|
-
"version": "0.23.
|
|
4
|
+
"version": "0.23.48",
|
|
5
5
|
"description": "Development tools for viewing API documentation, middleware, environment variables, events, and more",
|
|
6
6
|
"main": "dist/server/index.js",
|
|
7
7
|
"dependencies": {},
|
|
@@ -13,13 +13,13 @@
|
|
|
13
13
|
"swagger-ui-dist": "^5.18.2"
|
|
14
14
|
},
|
|
15
15
|
"peerDependencies": {
|
|
16
|
-
"@tachybase/
|
|
17
|
-
"@tachybase/
|
|
18
|
-
"@tachybase/
|
|
19
|
-
"@tachybase/sdk": "0.23.
|
|
20
|
-
"@tachybase/server": "0.23.
|
|
21
|
-
"@tachybase/utils": "0.23.
|
|
22
|
-
"@tachybase/test": "0.23.
|
|
16
|
+
"@tachybase/client": "0.23.48",
|
|
17
|
+
"@tachybase/actions": "0.23.48",
|
|
18
|
+
"@tachybase/database": "0.23.48",
|
|
19
|
+
"@tachybase/sdk": "0.23.48",
|
|
20
|
+
"@tachybase/server": "0.23.48",
|
|
21
|
+
"@tachybase/utils": "0.23.48",
|
|
22
|
+
"@tachybase/test": "0.23.48"
|
|
23
23
|
},
|
|
24
24
|
"description.zh-CN": "开发工具,用于查看Api文档,中间件,环境变量,事件等信息",
|
|
25
25
|
"displayName.zh-CN": "开发工具",
|