import { BaseEditor, Editor, EditorMarks, Node } from "slate";
import { HistoryEditor } from "slate-history";
import { ReactEditor, RenderElementProps, RenderLeafProps } from "slate-react";
import { TypeElement } from "typescript";
import { RichTextFormat } from "../../../types";
declare module "slate" {
    interface CustomTypes {
        Editor: BaseEditor & ReactEditor & HistoryEditor;
        Element: {
            type: string;
            children: Node[];
            textAlign?: string;
        };
        Text: {
            text: string;
            bold?: boolean;
            italic?: boolean;
            underline?: boolean;
            code?: boolean;
            strikethrough?: boolean;
        };
    }
}
export declare const isMark: (format: string) => format is keyof EditorMarks;
export declare const toggleMark: (editor: Editor, format: keyof EditorMarks) => void;
export declare const toggleBlock: (editor: Editor, format: any) => void;
export declare const isMarkActive: (editor: Editor, format: keyof EditorMarks) => boolean;
export declare const isBlockActive: (editor: Editor, format: TypeElement) => boolean;
export declare const renderLeaf: ({ children, leaf, attributes }: RenderLeafProps) => import("react/jsx-runtime").JSX.Element;
export declare const renderElement: ({ attributes, children, element, }: RenderElementProps) => import("react/jsx-runtime").JSX.Element;
export declare const serialize: (nodes: Node[], format: RichTextFormat) => string;
export declare const serializeHtml: (node: Node) => string;
export declare const DEFAULT_HTML_VALUE = "<br />";
export declare const DEFAULT_JSON_VALUE: {
    type: string;
    children: {
        text: string;
    }[];
}[];
export declare const setDefaultValue: (s: string) => {
    type: string;
    children: {
        text: string;
    }[];
}[];
export declare const deserialize: (string: string | undefined | null, format: RichTextFormat) => any;
export declare const deserializeHtml: (el: HTMLElement, markAttributes?: EditorMarks) => Node[] | {
    bold?: boolean | undefined;
    code?: boolean | undefined;
    italic?: boolean | undefined;
    underline?: boolean | undefined;
    strikethrough?: boolean | undefined;
    text: string;
    type?: undefined;
    textAlign?: undefined;
    children?: undefined;
} | {
    type: string;
    textAlign: string;
    children: Node[];
} | {
    type: string;
    children: Node[];
    textAlign?: undefined;
};
//# sourceMappingURL=utils.d.ts.map