export interface ParserConfig { /** * @internal */ _document: Document; /** * @internal */ _isBlock: (node: Element) => boolean; } interface ParserOption { _endNode?: Node; _excludeEnd?: boolean; _startNode?: Node; } /** @internal */ export declare const TOKEN_TEXT = 1; /** @internal */ export declare const TOKEN_VOID = 2; /** @internal */ export declare const TOKEN_SOFT_BREAK = 3; /** @internal */ export declare const TOKEN_BLOCK = 4; declare const TOKEN_EMPTY_BLOCK_ANCHOR = 5; declare const TOKEN_INVALID_SOFT_BREAK = 6; /** * @internal */ export type TokenType = typeof TOKEN_BLOCK | typeof TOKEN_EMPTY_BLOCK_ANCHOR | typeof TOKEN_INVALID_SOFT_BREAK | typeof TOKEN_SOFT_BREAK | typeof TOKEN_TEXT | typeof TOKEN_VOID; /** * @internal */ export declare const isTextNode: (node: Node) => node is Text; /** * @internal */ export declare const isElementNode: (node: Node) => node is Element; /** * @internal */ export declare const isCommentNode: (node: Node) => node is Comment; /** * @internal */ export declare const isVoidNode: (node: Element) => boolean; /** * @internal */ export declare const getDomNode: () => T extends typeof TOKEN_TEXT ? Text : T extends TokenType ? Element : Element | Text; /** * @internal */ export declare const getNodeSize: () => number; /** * @internal */ export declare const moveToBlock: (index: number) => void; declare const readNext: () => TokenType | void; /** * @internal */ export declare const parse: (scopeFn: (read: typeof readNext) => T, root: Node, { _document: document, _isBlock: isBlock }: ParserConfig, option?: ParserOption) => T; export {};