import { CreateObject, CreateArray, CreateString, CreateBoolean, CreateNumber, CreateInteger, CreateNull, } from "@theme/JSONSchemaViewer/JSONSchemaElements" import type { JSX } from "react" import type { JSONSchema, JSONSchemaNS, TypeValues, } from "@theme/JSONSchemaViewer/types" // Utily function to render a specific type type RenderProvidedTypeProps = { schema: Exclude type: TypeValues nullable?: boolean } export default function RenderProvidedType({ schema, type, nullable, }: RenderProvidedTypeProps): JSX.Element { const commonProps = { description: schema.description, nullable } switch (type) { case "array": return ( ) case "object": return ( ) case "string": return ( ) case "boolean": return ( ) case "number": return ( ) case "integer": return ( ) default: return ( ) } }