Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Base64Png Editor Factory
import { EditorFactory, EditorInitArgs, KogitoEditorEnvelopeContextType } from "@kogito-tooling/editor/dist/api";
import { Base64PngEditorInterface } from "./Base64PngEditorInterface";
export class Base64PngEditorFactory implements EditorFactory {
public supports(fileExtension: string) {
return fileExtension === "base64png";
}
public createEditor(envelopeContext: KogitoEditorEnvelopeContextType, initArgs: EditorInitArgs) {
return Promise.resolve(new Base64PngEditorInterface(envelopeContext, initArgs));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment