1
0
mirror of https://github.com/flarum/core.git synced 2025-06-10 16:44:59 +02:00
flarum-bot 359e9f6cbb Bundled output for commit d72b8b8d8e7188a4211fb04237cad76709897d92
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2021-11-12 00:58:35 +00:00

33 lines
1.2 KiB
TypeScript

import EditorDriverInterface, { EditorDriverParams } from './EditorDriverInterface';
import ItemList from './ItemList';
export default class BasicEditorDriver implements EditorDriverInterface {
el: HTMLTextAreaElement;
constructor(dom: HTMLElement, params: EditorDriverParams);
protected build(dom: HTMLElement, params: EditorDriverParams): void;
protected keyHandlers(params: EditorDriverParams): ItemList<(e: KeyboardEvent) => void>;
moveCursorTo(position: number): void;
getSelectionRange(): Array<number>;
getLastNChars(n: number): string;
insertAtCursor(text: string): void;
insertAt(pos: number, text: string): void;
insertBetween(selectionStart: number, selectionEnd: number, text: string): void;
replaceBeforeCursor(start: number, text: string): void;
protected setSelectionRange(start: number, end: number): void;
getCaretCoordinates(position: number): {
top: number;
left: number;
};
/**
* Set the disabled status of the editor.
*/
disabled(disabled: boolean): void;
/**
* Focus on the editor.
*/
focus(): void;
/**
* Destroy the editor
*/
destroy(): void;
}