/** * @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved. * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options */ /** * @module uploadcare/uploadcareimageedit/ui/uploadcareimageeditcontroller */ import { type ObservableMixinConstructor } from "@ckeditor/ckeditor5-utils"; import { type Dialog } from "@ckeditor/ckeditor5-ui"; import type { Editor } from "@ckeditor/ckeditor5-core"; import type { ModelElement } from "@ckeditor/ckeditor5-engine"; declare const UploadcareImageEditControllerBase: ObservableMixinConstructor; /** * Controller for the Image Edit Dialog. * * It manages the dialog and all the related actions during dialog instance lifecycle. It is bound to a dialog instance * and an active image element and destroyed when dialog instance is closed. */ export declare class UploadcareImageEditController extends UploadcareImageEditControllerBase { /** * Whenever the controller is active and dialog UI visible. * * @observable * @readonly */ isActive: boolean; /** * Status of the selected image when command is executed: * * * `uploading` - image is being uploaded to Uploadcare, * * `ready` - image is ready to be edited (already in Uploadcare or just uploaded to it), * * `error` - error occurred during image upload. * * @observable * @readonly */ imageStatus: "uploading" | "ready" | "error"; imageErrorType: "Network" | "NotFound" | null; /** * The Uploadcare image ID. * * @observable * @readonly */ imageId: string | null; /** * The Uploadcare image source URL. * * @observable * @readonly */ imageSrc: string | null; /** * The image width and height. It is used to calculate proper `srcset` attributes and aspect ratio. * * @observable * @readonly */ imageDimension: { width: number; height: number; } | null; /** * The Uploadcare image upload progress. * * @observable * @readonly */ imageUploadProgress: number | null; /** * Creates a new instance of `UploadcareImageEditController`. */ constructor(editor: Editor, dialog: Dialog, imageElement: ModelElement); /** * Destroys `UploadcareImageEditController` instance. */ destroy(): void; } export {};