/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- */ import { addColSpan } from '@progress/kendo-editor-common'; import { addColumn } from '@progress/kendo-editor-common'; import { addListNodes } from '@progress/kendo-editor-common'; import { AddMarkStep } from '@progress/kendo-editor-common'; import { addRow } from '@progress/kendo-editor-common'; import { AllSelection } from '@progress/kendo-editor-common'; import { autoJoin } from '@progress/kendo-editor-common'; import { ButtonProps } from '@progress/kendo-react-buttons'; import { canJoin } from '@progress/kendo-editor-common'; import { canSplit } from '@progress/kendo-editor-common'; import { cellAround } from '@progress/kendo-editor-common'; import { CellSelection } from '@progress/kendo-editor-common'; import { chainCommands } from '@progress/kendo-editor-common'; import { colCount } from '@progress/kendo-editor-common'; import { ColorPickerProps } from '@progress/kendo-react-inputs'; import { columnIsHeader } from '@progress/kendo-editor-common'; import { columnResizing } from '@progress/kendo-editor-common'; import { Command } from 'prosemirror-state'; import { ComponentClass } from 'react'; import { ContentMatch } from '@progress/kendo-editor-common'; import { Decoration } from '@progress/kendo-editor-common'; import { DecorationSet } from '@progress/kendo-editor-common'; import { default as default_2 } from 'prop-types'; import { deleteRow } from '@progress/kendo-editor-common'; import { deleteTable } from '@progress/kendo-editor-common'; import { DOMParser as DOMParser_2 } from '@progress/kendo-editor-common'; import { DOMSerializer } from '@progress/kendo-editor-common'; import { dropCursor } from '@progress/kendo-editor-common'; import { DropDownListProps } from '@progress/kendo-react-dropdowns'; import { dropPoint } from '@progress/kendo-editor-common'; import { EditorState } from '@progress/kendo-editor-common'; import { EditorView } from '@progress/kendo-editor-common'; import { findCell } from '@progress/kendo-editor-common'; import { findWrapping } from '@progress/kendo-editor-common'; import { fixTables } from '@progress/kendo-editor-common'; import { Fragment } from '@progress/kendo-editor-common'; import { gapCursor } from '@progress/kendo-editor-common'; import { getHtml } from '@progress/kendo-editor-common'; import { goToNextCell } from '@progress/kendo-editor-common'; import { history as history_2 } from '@progress/kendo-editor-common'; import { ImageResizeOptions } from '@progress/kendo-editor-common'; import { InputRule } from '@progress/kendo-editor-common'; import { inputRules } from '@progress/kendo-editor-common'; import { inSameTable } from '@progress/kendo-editor-common'; import { insertPoint } from '@progress/kendo-editor-common'; import { isInTable } from '@progress/kendo-editor-common'; import { joinPoint } from '@progress/kendo-editor-common'; import { JSX } from 'react/jsx-runtime'; import { keydownHandler } from '@progress/kendo-editor-common'; import { keymap } from '@progress/kendo-editor-common'; import { liftListItem } from '@progress/kendo-editor-common'; import { liftTarget } from '@progress/kendo-editor-common'; import { Mapping } from '@progress/kendo-editor-common'; import { MapResult } from '@progress/kendo-editor-common'; import { Mark } from '@progress/kendo-editor-common'; import { marks } from '@progress/kendo-editor-common'; import { MarkSpec } from '@progress/kendo-editor-common'; import { MarkType } from '@progress/kendo-editor-common'; import { mergeCells } from '@progress/kendo-editor-common'; import { moveCellForward } from '@progress/kendo-editor-common'; import { nextCell } from '@progress/kendo-editor-common'; import { Node as Node_2 } from '@progress/kendo-editor-common'; import { NodeRange } from '@progress/kendo-editor-common'; import { nodes } from '@progress/kendo-editor-common'; import { NodeSelection } from '@progress/kendo-editor-common'; import { NodeSpec } from '@progress/kendo-editor-common'; import { NodeType } from '@progress/kendo-editor-common'; import { parseContent } from '@progress/kendo-editor-common'; import { ParseOptions } from '@progress/kendo-editor-common'; import { PasteCleanupSettings as PasteCleanupSettings_2 } from '@progress/kendo-editor-common'; import { PDFExportProps } from '@progress/kendo-react-pdf'; import { Plugin as Plugin_2 } from '@progress/kendo-editor-common'; import { PluginKey } from '@progress/kendo-editor-common'; import * as React_2 from 'react'; import { redoDepth } from '@progress/kendo-editor-common'; import { removeColSpan } from '@progress/kendo-editor-common'; import { RemoveMarkStep } from '@progress/kendo-editor-common'; import { ReplaceAroundStep } from '@progress/kendo-editor-common'; import { ReplaceError } from '@progress/kendo-editor-common'; import { ReplaceStep } from '@progress/kendo-editor-common'; import { replaceStep } from '@progress/kendo-editor-common'; import { ResizeState } from 'prosemirror-tables'; import { ResolvedPos } from '@progress/kendo-editor-common'; import { rowIsHeader } from '@progress/kendo-editor-common'; import { Schema } from '@progress/kendo-editor-common'; import { selectedRect } from '@progress/kendo-editor-common'; import { Selection as Selection_2 } from '@progress/kendo-editor-common'; import { selectionCell } from '@progress/kendo-editor-common'; import { SelectionRange } from '@progress/kendo-editor-common'; import { setBlockType } from '@progress/kendo-editor-common'; import { setCellAttr } from '@progress/kendo-editor-common'; import { sinkListItem } from '@progress/kendo-editor-common'; import { Slice } from '@progress/kendo-editor-common'; import { splitCell } from '@progress/kendo-editor-common'; import { splitCellWithType } from '@progress/kendo-editor-common'; import { splitListItem } from '@progress/kendo-editor-common'; import { Step } from '@progress/kendo-editor-common'; import { StepMap } from '@progress/kendo-editor-common'; import { StepResult } from '@progress/kendo-editor-common'; import { tableEditing } from '@progress/kendo-editor-common'; import { TableMap } from '@progress/kendo-editor-common'; import { tableNodes } from '@progress/kendo-editor-common'; import { tableNodeTypes } from '@progress/kendo-editor-common'; import { textblockTypeInputRule } from '@progress/kendo-editor-common'; import { TextSelection } from '@progress/kendo-editor-common'; import { toggleHeader } from '@progress/kendo-editor-common'; import { toggleMark } from '@progress/kendo-editor-common'; import { Transaction } from '@progress/kendo-editor-common'; import { Transform } from '@progress/kendo-editor-common'; import { undoDepth } from '@progress/kendo-editor-common'; import { updateColumnsOnResize } from '@progress/kendo-editor-common'; import { wrapIn } from '@progress/kendo-editor-common'; import { wrapInList } from '@progress/kendo-editor-common'; import { wrappingInputRule } from '@progress/kendo-editor-common'; /** * @hidden */ declare interface ApplyColorToolProps extends BasicToolProps, EditorToolsSettings.ApplyColorSettings { } /** * @hidden */ declare interface BasicToolProps { /** * The `EditorView` object of the Editor component. */ view?: EditorView; } /** * @hidden */ declare interface CleanFormattingToolProps extends ToolProps { /** * The settings of the tool. Use it to modify the tool appearance. */ settings?: EditorToolsSettings.CleanFormattingSettings; } /** * Represents the [KendoReact Editor component]({% slug overview_editor %}). * * @example * ```jsx * class App extends React.Component { * render() { * return ( * * ); * } * } * ReactDOM.render(, document.querySelector('my-app')); * ``` */ export declare class Editor extends React_2.Component { /** * @hidden */ static propTypes: { defaultContent: default_2.Requireable; value: default_2.Requireable>; defaultEditMode: default_2.Requireable; contentStyle: default_2.Requireable; dir: default_2.Requireable; className: default_2.Requireable; ariaDescribedBy: default_2.Requireable; ariaLabelledBy: default_2.Requireable; ariaLabel: default_2.Requireable; style: default_2.Requireable; tools: default_2.Requireable; keyboardNavigation: default_2.Requireable; resizable: default_2.Requireable; preserveWhitespace: default_2.Requireable; onMount: default_2.Requireable<(...args: any[]) => any>; onFocus: default_2.Requireable<(...args: any[]) => any>; onBlur: default_2.Requireable<(...args: any[]) => any>; onChange: default_2.Requireable<(...args: any[]) => any>; onPasteHtml: default_2.Requireable<(...args: any[]) => any>; onExecute: default_2.Requireable<(...args: any[]) => any>; onIFrameInit: default_2.Requireable<(...args: any[]) => any>; }; /** * @hidden */ readonly state: EditorStateInterface; /** * The value of the Editor. */ get value(): Node_2 | string; /** * Returns the DOM element of the Editor. */ get element(): HTMLElement | null; /** * Returns the content-editable DOM element of the Editor. */ get contentElement(): HTMLDivElement | null; /** * Returns the `view` object of the Editor. */ get view(): EditorView | undefined; private _element; private _view?; private _contentElement; private iframe; private trOnChange; private htmlOnChange; private pasteEvent?; private readonly showLicenseWatermark; constructor(props: EditorProps); /** * @hidden */ componentDidMount(): void; /** * @hidden */ componentDidUpdate(prevProps: EditorProps): void; /** * @hidden */ componentWillUnmount(): void; /** * @hidden */ focus: () => void; /** * @hidden */ render(): JSX.Element; private renderDialog; private renderTool; private updateTools; private initialize; private filterTransaction; private onPasteHtml; private dispatchTransaction; private onFocus; private onBlur; private onPaste; private onIFrameInit; } /** * Represents the object of the `onBlur` Editor event. */ export declare interface EditorBlurEvent extends EditorEvent { /** * The native blur event. */ nativeEvent: FocusEvent; } /** * Represents the object of the `onChange` Editor event. */ export declare interface EditorChangeEvent extends EditorEvent { /** * Represents the [Editor document](https://prosemirror.net/docs/guide/#doc). */ value: Node_2; /** * A getter of the Editor HTML content. * Once called, it will convert the Editor document into HTML string. * Note that, since onChange event is triggered on every key while typing, * this conversion may not be suitable if the Editor is dealing with large amount of content. */ html: string; /** * The Editor Schema object. */ schema: Schema; /** * The Transaction which causes the change. */ transaction: Transaction; } /** * @hidden */ declare interface EditorDialogProps { /** * The `EditorView` object. */ view: EditorView; /** * The `settings` object of the Dialog. */ settings: any; /** * Represents the `dir` HTML attribute. */ dir?: string; /** * The `close` event which will be triggered when the Dialog is about to be unmounted. */ onClose: () => void; /** * Fires when a Dialog is about to be rendered. Used to override the default appearance of the Dialog. */ render?: (tool: React.ReactElement, args?: any) => React.ReactNode; } /** * Represents a wrapping namespace for the dialog components and props of the Editor. */ export declare namespace EditorDialogs { /** * The InsertLinkDialog component. */ export class InsertLinkDialog extends InsertLinkDialog { } /** * The props for the InsertLinkDialog component. */ export interface InsertLinkDialogProps extends InsertLinkDialogProps { } /** * The InsertImageDialog component. */ export class InsertImageDialog extends InsertImageDialog { } /** * The props for the InsertImageDialog component. */ export interface InsertImageDialogProps extends InsertImageDialogProps { } /** * The ViewHtmlDialog component. */ export class ViewHtmlDialog extends ViewHtmlDialog { } /** * The props for the ViewHtmlDialog component. */ export interface ViewHtmlDialogProps extends ViewHtmlDialogProps { } /** * The FindAndReplaceDialog component. */ export class FindAndReplaceDialog extends FindAndReplaceDialog { } /** * The props for the FindAndReplaceDialog component. */ export interface FindAndReplaceDialogProps extends FindAndReplaceDialogProps { } } declare interface EditorEvent { /** * An event target. */ target: Editor; } /** * Represents the object of the `onExecute` Editor event. */ export declare interface EditorExecuteEvent extends EditorEvent { /** * The transaction that will be executed. */ transaction: Transaction; /** * The state of the Editor. */ state: EditorState; } /** * Represents the object of the `onFocus` Editor event. */ export declare interface EditorFocusEvent extends EditorEvent { /** * The native focus event. */ nativeEvent: FocusEvent; } /** * Represents the object of the `onIFrameInit` Editor event. */ export declare interface EditorIFrameInitEvent extends EditorEvent { /** * The object that represents the iframe element inside the Editor. */ iframe: HTMLIFrameElement; } /** * Represents the object of the `onMount` Editor event. */ export declare interface EditorMountEvent extends EditorEvent { /** * The content-editable DOM element of the Editor. */ dom: HTMLDivElement; /** * The default plugins collection of the Editor. */ plugins: Array; /** * The default key bindings of the Editor. */ shortcuts: EditorUtils.Shortcuts; /** * The default [viewProps](https://prosemirror.net/docs/ref/#view.DirectEditorProps) object of the Editor. */ viewProps: { state: EditorState; [key: string]: any; }; } /** * Represents the object of the `onPaste` Editor event. */ export declare interface EditorPasteEvent extends EditorEvent { /** * The HTML that will be pasted in the Editor. */ pastedHtml: string; /** * The native paste event. */ nativeEvent: ClipboardEvent; } /** * Represents the props of the [KendoReact Editor component]({% slug overview_editor %}). */ export declare interface EditorProps { /** * Sets the default HTML content of the Editor. This content is rendered * when the Editor is initialized and no value is provided. * * @example * ```jsx * * ``` */ defaultContent?: string; /** * Sets the initial edit mode of the Editor. Defaults to `iframe`. * - `iframe`: The Editor content is rendered inside an `