diff --git a/lib/components/JsonSchema/json-schema-lazy.ts b/lib/components/JsonSchema/json-schema-lazy.ts index 24e2f1cb..c3a81bb1 100644 --- a/lib/components/JsonSchema/json-schema-lazy.ts +++ b/lib/components/JsonSchema/json-schema-lazy.ts @@ -36,7 +36,7 @@ export class JsonSchemaLazy implements OnDestroy, OnInit, AfterViewInit { return schema && schema.$ref || this.pointer; } - _loadAfterSelf() { + private _loadAfterSelf() { var componentFactory = this.resolver.resolveComponentFactory(JsonSchema); let contextInjector = this.location.parentInjector; let compRef = this.location.createComponent(componentFactory, null, contextInjector, null); diff --git a/lib/components/Operation/operation.ts b/lib/components/Operation/operation.ts index 7931069a..9b635cd4 100644 --- a/lib/components/Operation/operation.ts +++ b/lib/components/Operation/operation.ts @@ -4,9 +4,9 @@ import JsonPointer from '../../utils/JsonPointer'; import { BaseComponent, SpecManager } from '../base'; import { SchemaHelper } from '../../services/schema-helper.service'; import { OptionsService, MenuService } from '../../services/'; +import { SwaggerBodyParameter } from '../../utils/swagger-typings'; - -interface OperationInfo { +export interface OperationInfo { verb: string; path: string; info: { @@ -72,7 +72,7 @@ export class Operation extends BaseComponent implements OnInit { return tags.filter(tag => tagsMap[tag] && tagsMap[tag]['x-traitTag']); } - findBodyParam() { + findBodyParam():SwaggerBodyParameter { let params = this.specMgr.getOperationParams(this.pointer); let bodyParam = params.find(param => param.in === 'body'); return bodyParam; diff --git a/lib/components/Search/redoc-search.ts b/lib/components/Search/redoc-search.ts index 35a66ff5..5cf8b286 100644 --- a/lib/components/Search/redoc-search.ts +++ b/lib/components/Search/redoc-search.ts @@ -74,7 +74,7 @@ export class RedocSearch implements OnInit { item.pointers ); this.marker.remark(); - this.menu.activate(item.menuItem.flatIdx); + this.menu.activate(item.menuItem); this.menu.scrollToActive(); } diff --git a/lib/utils/swagger-typings.ts b/lib/utils/swagger-typings.ts index 530f07f9..91e74c5e 100644 --- a/lib/utils/swagger-typings.ts +++ b/lib/utils/swagger-typings.ts @@ -10,7 +10,7 @@ import { Response } from '@types/swagger-schema-official'; -interface RedocInjectedPointer { +export interface RedocInjectedPointer { _pointer?: string; }