diff --git a/packages/ui/src/multiplying-architecture/KaotoEditorApp.tsx b/packages/ui/src/multiplying-architecture/KaotoEditorApp.tsx index 6c4dd600a..5a3a5d987 100644 --- a/packages/ui/src/multiplying-architecture/KaotoEditorApp.tsx +++ b/packages/ui/src/multiplying-architecture/KaotoEditorApp.tsx @@ -3,7 +3,6 @@ import { EditorApi, EditorInitArgs, EditorTheme, - KogitoEditorChannelApi, KogitoEditorEnvelopeContextType, } from '@kie-tools-core/editor/dist/api'; import { Notification } from '@kie-tools-core/notifications/dist/api'; @@ -13,6 +12,7 @@ import { EntitiesProvider } from '../providers/entities.provider'; import { SourceCodeProvider } from '../providers/source-code.provider'; import { KaotoBridge } from './KaotoBridge'; import { KaotoEditor } from './KaotoEditor'; +import { KaotoEditorChannelApi } from './KaotoEditorChannelApi'; export class KaotoEditorApp implements Editor { private readonly editorRef: RefObject; @@ -21,7 +21,7 @@ export class KaotoEditorApp implements Editor { af_componentTitle = 'Kaoto Editor'; constructor( - private readonly envelopeContext: KogitoEditorEnvelopeContextType, + private readonly envelopeContext: KogitoEditorEnvelopeContextType, private readonly initArgs: EditorInitArgs, ) { this.editorRef = createRef(); diff --git a/packages/ui/src/multiplying-architecture/KaotoEditorChannelApi.ts b/packages/ui/src/multiplying-architecture/KaotoEditorChannelApi.ts new file mode 100644 index 000000000..c7f11fc42 --- /dev/null +++ b/packages/ui/src/multiplying-architecture/KaotoEditorChannelApi.ts @@ -0,0 +1,5 @@ +import { KogitoEditorChannelApi } from '@kie-tools-core/editor/dist/api'; + +export interface KaotoEditorChannelApi extends KogitoEditorChannelApi { + getCatalogURL(): Promise; +} diff --git a/packages/ui/src/multiplying-architecture/KaotoEditorFactory.ts b/packages/ui/src/multiplying-architecture/KaotoEditorFactory.ts index c6af3d81a..0b3dec840 100644 --- a/packages/ui/src/multiplying-architecture/KaotoEditorFactory.ts +++ b/packages/ui/src/multiplying-architecture/KaotoEditorFactory.ts @@ -4,12 +4,12 @@ import { EditorFactory, EditorInitArgs, KogitoEditorEnvelopeContextType, - KogitoEditorChannelApi, } from '@kie-tools-core/editor/dist/api'; +import { KaotoEditorChannelApi } from './KaotoEditorChannelApi'; -export class KaotoEditorFactory implements EditorFactory { +export class KaotoEditorFactory implements EditorFactory { public createEditor( - envelopeContext: KogitoEditorEnvelopeContextType, + envelopeContext: KogitoEditorEnvelopeContextType, initArgs: EditorInitArgs, ): Promise { return Promise.resolve(new KaotoEditorApp(envelopeContext, initArgs)); diff --git a/packages/ui/src/multiplying-architecture/index.ts b/packages/ui/src/multiplying-architecture/index.ts index 723093cf6..166ff187a 100644 --- a/packages/ui/src/multiplying-architecture/index.ts +++ b/packages/ui/src/multiplying-architecture/index.ts @@ -1 +1,2 @@ export * from './KaotoEditorFactory'; +export * from './KaotoEditorChannelApi';