export function addToolbarCallback(func: any): void;
export function clearToolbarCallbacks(): void;
export function onToolbarCreate(func: any): void;
export default class DEditor extends Component<any> {
    constructor(owner?: import("@ember/owner").default | undefined);
    emojiStore: any;
    modal: any;
    menu: any;
    editorComponent: any;
    /** @type {TextManipulation} */
    textManipulation: TextManipulation;
    replacedToolbarInstance: any;
    preview: any;
    ready: boolean;
    lastSel: any;
    showLink: boolean;
    isEditorFocused: boolean;
    processPreview: boolean;
    morphingOptions: {
        beforeAttributeUpdated: (element: any, attributeName: any) => boolean;
    };
    init(...args: any[]): globalThis.Promise<void>;
    register: {
        lookup: (...args: any[]) => any;
        lookupFactory: (...args: any[]) => any;
        deprecateContainer(target: any): void;
    };
    setupToolbar(): void;
    toolbar: Toolbar;
    setupEditorMode(): globalThis.Promise<void>;
    handleOldRichEditorPreference(): globalThis.Promise<void>;
    placeholderTranslated(placeholder: any): any;
    showEditorModeToggle(): boolean;
    _readyNow(): void;
    didInsertElement(...args: any[]): void;
    _previewMutationObserver: MutationObserver;
    get editorContainerModeClass(): "--rich-editor-enabled" | "--markdown-editor-enabled";
    get keymap(): {
        tab(): boolean;
        "shift+tab"(): boolean;
        "ctrl+m"(): globalThis.Promise<void>;
    };
    _shutDown(): void;
    _cachedCookFunction: any;
    cachedCookAsync(text: any, options: any): globalThis.Promise<any>;
    _updatePreview(): globalThis.Promise<void>;
    _watchForChanges(): globalThis.Promise<void>;
    _applyHashtagAutocomplete(): void;
    _applyEmojiAutocomplete(): void;
    menuInstance: any;
    _applyMentionAutocomplete(): void;
    rovingButtonBar(event: any): boolean;
    /**
     * Represents a toolbar event object passed to toolbar buttons.
     *
     * @typedef {Object} ToolbarEvent
     * @property {function} applySurround - Applies surrounding text
     * @property {function} formatCode - Formats as code
     * @property {function} replaceText - Replaces text
     * @property {function} selectText - Selects a range of text
     * @property {function} toggleDirection - Toggles text direction
     * @property {function} getText - Gets the text
     * @property {function} addText - Adds text
     * @property {function} applyList - Applies a list format
     * @property {*} selected - The current selection
     * @property {Object} commands - Available commands
     * @property {Object} state - Current editor state (inWrap, inBold, etc.)
     */
    /**
     * Creates a new toolbar event object
     *
     * @param {boolean} trimLeading - Whether to trim leading whitespace
     * @returns {ToolbarEvent} An object with toolbar event actions
     */
    newToolbarEvent(trimLeading: boolean): {
        /**
         * - Applies surrounding text
         */
        applySurround: Function;
        /**
         * - Formats as code
         */
        formatCode: Function;
        /**
         * - Replaces text
         */
        replaceText: Function;
        /**
         * - Selects a range of text
         */
        selectText: Function;
        /**
         * - Toggles text direction
         */
        toggleDirection: Function;
        /**
         * - Gets the text
         */
        getText: Function;
        /**
         * - Adds text
         */
        addText: Function;
        /**
         * - Applies a list format
         */
        applyList: Function;
        /**
         * - The current selection
         */
        selected: any;
        /**
         * - Available commands
         */
        commands: any;
        /**
         * - Current editor state (inWrap, inBold, etc.)
         */
        state: any;
    };
    showLinkModal(toolbarEvent: any): void;
    _lastSel: any;
    handleFocusIn(): void;
    handleFocusOut(): void;
    /**
     * Sets up the editor with the given text manipulation instance
     *
     * @param {TextManipulation} textManipulation The text manipulation instance
     * @returns {(() => void)} destructor function
     */
    setupEditor(textManipulation: TextManipulation): (() => void);
    toggleRichEditor(): globalThis.Promise<void>;
    _debounceSaveRichEditorPreference: any;
    replaceToolbar(toolbarInstance: any): void;
    resetToolbar(): void;
    onChange(event: any): void;
    get isRichEditorEnabled(): boolean;
    setupEvents(): () => void;
    replacedToolbarComponent: any;
    _disablePreviewTabIndex(): MutationObserver;
    #private;
}
import Component from "@ember/component";
import Toolbar from "discourse/lib/composer/toolbar";
//# sourceMappingURL=d-editor.d.ts.map