fix: Only show description when type is object

This commit is contained in:
Eduardo Barreto Alexandre 2026-01-03 10:18:51 -03:00
parent 003cd33e91
commit 2dddc3805b

View File

@ -62,7 +62,7 @@ export class OneOfSchema extends React.Component<SchemaProps> {
<div>
{oneOf[schema.activeOneOf].deprecated && <Badge type="warning">Deprecated</Badge>}
</div>
{activeSchema.rawSchema.description && (
{activeSchema.type == 'object' && activeSchema.rawSchema.description && (
<Markdown source={activeSchema.rawSchema.description} />
)}
<ConstraintsView constraints={activeSchema.constraints} />