/*! * Jodit Editor (https://xdsoft.net/jodit/) * Released under MIT see LICENSE.txt in the project root for license information. * Copyright (c) 2013-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net */ /** * @module helpers/utils */ import type { CanPromise, CanUndef, IControlType, IJodit, IViewBased, Nullable, RejectablePromise } from "../../../types/index"; /** * Call function with parameters * * @example * ```js * const f = Math.random(); * Jodit.modules.Helpers.call(f > 0.5 ? Math.ceil : Math.floor, f); * ``` */ export declare function call(func: (...args: T) => R, ...args: T): R; /** * Call function with parameters * * @example * ```js * const f = Math.random(); * Jodit.modules.Helpers.call(f > 0.5 ? Math.ceil : Math.floor, f); * ``` */ export declare function callThis(func: (this: This, ...args: T) => R, thisArg: This, ...args: T): R; /** * Mark element for debugging */ export declare function markOwner(jodit: IViewBased, elm: HTMLElement): void; export declare function callPromise(condition: CanPromise, callback?: () => CanPromise): CanPromise; /** * Allow load image in promise */ export declare const loadImage: (src: string, jodit: IViewBased) => RejectablePromise; export declare const keys: (obj: object, own?: boolean) => string[]; /** * Memorize last user chose */ export declare const memorizeExec: (editor: T, _: unknown, { control }: { control: IControlType; }, preProcessValue?: (value: string) => string) => void | false; /** * Get DataTransfer from different event types */ export declare const getDataTransfer: (event: ClipboardEvent | DragEvent) => Nullable; export declare function getPropertyDescriptor(obj: unknown, prop: string): CanUndef;