import{RedocSchema as c,StoreProvider as p}from"@redocly/openapi-docs";import*as e from"react";import{Admonition as d}from"@redocly/theme/markdoc/components/Admonition/Admonition";import{OpenApiComponentWrap as l}from"../styled.elements";function v(s){const{options:r,schemaResolved:o,schemaResolvedErrors:t,schema:n}=s;if(n||o){const m={openapi:"3.0.0",info:{version:"1",description:"test",title:"test"},paths:{},"x-root":o?.components?.schemas?.__root||n,components:{schemas:{...o?.components?.schemas}}};return e.createElement(l,{"data-testid":"json-schema"},e.createElement(p,{options:r,definition:m},t?.length?e.createElement(d,{name:"Problem in json-schema tag",type:"danger"},t.map((i,a)=>e.createElement("div",{key:a},i))):null,e.createElement(c,{pointer:"#/x-root",disableDeepLinks:!0})))}}export{v as JsonSchema};
