mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-29 03:53:43 +03:00
fix: extract extensions of child items in case it is a single object
This commit is contained in:
parent
3658b6def4
commit
56eaef76ff
|
@ -96,6 +96,13 @@ export class SchemaModel {
|
||||||
|
|
||||||
if (options.showExtensions) {
|
if (options.showExtensions) {
|
||||||
this.extensions = extractExtensions(this.schema, options.showExtensions);
|
this.extensions = extractExtensions(this.schema, options.showExtensions);
|
||||||
|
|
||||||
|
if (typeof this.schema.items === 'object') {
|
||||||
|
this.extensions = {
|
||||||
|
...this.extensions,
|
||||||
|
...extractExtensions(this.schema.items, options.showExtensions),
|
||||||
|
};
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -459,7 +466,6 @@ function buildFields(
|
||||||
refsStack,
|
refsStack,
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
if (options.sortPropsAlphabetically) {
|
if (options.sortPropsAlphabetically) {
|
||||||
fields = sortByField(fields, 'name');
|
fields = sortByField(fields, 'name');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user