mirror of
https://github.com/Redocly/redoc.git
synced 2025-07-29 17:40:05 +03:00
feat(): Expose certain extensions
This commit is contained in:
parent
aa159377d5
commit
efbcec58a0
|
@ -60,6 +60,11 @@ export class FieldModel {
|
|||
|
||||
serializationMime?: string;
|
||||
extraDescription: Record<string, boolean>;
|
||||
extraApiReferenceForValidation: {
|
||||
httpVerb: string;
|
||||
label: string;
|
||||
description: string;
|
||||
};
|
||||
|
||||
constructor(
|
||||
parser: OpenAPIParser,
|
||||
|
@ -104,6 +109,17 @@ export class FieldModel {
|
|||
this.extraDescription = info[MilesConstants.MILES_EXTRA_DESCRIPTION_PROPERTY_NAME];
|
||||
}
|
||||
|
||||
if (
|
||||
info[MilesConstants.MILES_VALIDATION_MODEL_PROPERTY_NAME] !== undefined &&
|
||||
info[MilesConstants.MILES_VALIDATION_MODEL_PROPERTY_NAME]?.label
|
||||
) {
|
||||
this.extraApiReferenceForValidation = {
|
||||
label: info[MilesConstants.MILES_VALIDATION_MODEL_PROPERTY_NAME]?.label,
|
||||
httpVerb: info[MilesConstants.MILES_VALIDATION_MODEL_PROPERTY_NAME]?.httpVerb,
|
||||
description: info[MilesConstants.MILES_VALIDATION_MODEL_PROPERTY_NAME]?.description,
|
||||
};
|
||||
}
|
||||
|
||||
if (serializationMime) {
|
||||
this.serializationMime = serializationMime;
|
||||
} else if (info.style) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user