From 50519927b56dad84c6534ec5eabd40550a9a211f Mon Sep 17 00:00:00 2001 From: Viacheslav Turovskyi Date: Wed, 11 Sep 2024 19:23:22 +0000 Subject: [PATCH] renamed `ConvertVersion` -> `AsyncAPIConvertVersion` --- apps/studio-next/src/services/converter.service.ts | 4 ++-- apps/studio-next/src/services/editor.service.tsx | 6 +++--- apps/studio/src/services/converter.service.ts | 4 ++-- apps/studio/src/services/editor.service.tsx | 6 +++--- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/apps/studio-next/src/services/converter.service.ts b/apps/studio-next/src/services/converter.service.ts index b8a46060c..5b9b5790a 100644 --- a/apps/studio-next/src/services/converter.service.ts +++ b/apps/studio-next/src/services/converter.service.ts @@ -2,12 +2,12 @@ import { AbstractService } from './abstract.service'; import { convert } from '@asyncapi/converter'; -import type { ConvertVersion, ConvertOptions } from '@asyncapi/converter'; +import type { AsyncAPIConvertVersion, ConvertOptions } from '@asyncapi/converter'; export class ConverterService extends AbstractService { async convert( spec: string, - version?: ConvertVersion, + version?: AsyncAPIConvertVersion, options?: ConvertOptions, ): Promise { version = version || this.svcs.specificationSvc.latestVersion; diff --git a/apps/studio-next/src/services/editor.service.tsx b/apps/studio-next/src/services/editor.service.tsx index 8ec0cc2c2..fc3c01970 100644 --- a/apps/studio-next/src/services/editor.service.tsx +++ b/apps/studio-next/src/services/editor.service.tsx @@ -10,7 +10,7 @@ import { appState, documentsState, filesState, settingsState } from '@/state'; import type * as monacoAPI from 'monaco-editor/esm/vs/editor/editor.api'; import type { Diagnostic } from '@asyncapi/parser'; -import type { ConvertVersion } from '@asyncapi/converter'; +import type { AsyncAPIConvertVersion } from '@asyncapi/converter'; import type { File } from '@/state/files.state'; export interface UpdateState { @@ -97,8 +97,8 @@ export class EditorService extends AbstractService { }); } - async convertSpec(version?: ConvertVersion | string) { - const converted = await this.svcs.converterSvc.convert(this.value, version as ConvertVersion); + async convertSpec(version?: AsyncAPIConvertVersion | string) { + const converted = await this.svcs.converterSvc.convert(this.value, version as AsyncAPIConvertVersion); this.updateState({ content: converted, updateModel: true }); } diff --git a/apps/studio/src/services/converter.service.ts b/apps/studio/src/services/converter.service.ts index b8a46060c..5b9b5790a 100644 --- a/apps/studio/src/services/converter.service.ts +++ b/apps/studio/src/services/converter.service.ts @@ -2,12 +2,12 @@ import { AbstractService } from './abstract.service'; import { convert } from '@asyncapi/converter'; -import type { ConvertVersion, ConvertOptions } from '@asyncapi/converter'; +import type { AsyncAPIConvertVersion, ConvertOptions } from '@asyncapi/converter'; export class ConverterService extends AbstractService { async convert( spec: string, - version?: ConvertVersion, + version?: AsyncAPIConvertVersion, options?: ConvertOptions, ): Promise { version = version || this.svcs.specificationSvc.latestVersion; diff --git a/apps/studio/src/services/editor.service.tsx b/apps/studio/src/services/editor.service.tsx index 630ef33bf..6b46d896e 100644 --- a/apps/studio/src/services/editor.service.tsx +++ b/apps/studio/src/services/editor.service.tsx @@ -10,7 +10,7 @@ import { appState, documentsState, filesState, settingsState } from '../state'; import type * as monacoAPI from 'monaco-editor/esm/vs/editor/editor.api'; import type { Diagnostic } from '@asyncapi/parser/cjs'; -import type { ConvertVersion } from '@asyncapi/converter'; +import type { AsyncAPIConvertVersion } from '@asyncapi/converter'; import type { File } from '../state/files.state'; export interface UpdateState { @@ -97,8 +97,8 @@ export class EditorService extends AbstractService { }); } - async convertSpec(version?: ConvertVersion | string) { - const converted = await this.svcs.converterSvc.convert(this.value, version as ConvertVersion); + async convertSpec(version?: AsyncAPIConvertVersion | string) { + const converted = await this.svcs.converterSvc.convert(this.value, version as AsyncAPIConvertVersion); this.updateState({ content: converted, updateModel: true }); }