import React from 'react';
import type { Processor } from 'unified';
import { type MarkdownRemarkPlugin, type MarkdownToHtmlConfig } from '../MarkdownEditor/editor/utils/markdownToHtml';
import type { MarkdownEditorProps } from '../MarkdownEditor/types';
import type { MarkdownRendererEleProps, RendererBlockProps } from './types';
declare const createHastProcessor: (extraRemarkPlugins?: MarkdownRemarkPlugin[], config?: MarkdownToHtmlConfig) => Processor;
/** hast → React 组件映射，与 MarkdownEditor Readonly 的 data-be / prefixCls 对齐 */
declare const buildEditorAlignedComponents: (prefixCls: string, userComponents: Record<string, React.ComponentType<RendererBlockProps>>, streaming?: boolean, linkConfig?: {
    openInNewTab?: boolean | undefined;
    onClick?: ((url?: string) => boolean | void) | undefined;
} | undefined, fncProps?: MarkdownEditorProps['fncProps'], streamingParagraphAnimation?: boolean, eleRender?: ((props: MarkdownRendererEleProps, defaultDom: React.ReactNode) => React.ReactNode) | undefined) => {
    p: (props: any) => React.ReactNode;
    h1: (props: any) => React.ReactNode;
    h2: (props: any) => React.ReactNode;
    h3: (props: any) => React.ReactNode;
    h4: (props: any) => React.ReactNode;
    h5: (props: any) => React.ReactNode;
    h6: (props: any) => React.ReactNode;
    blockquote: (props: any) => React.ReactNode;
    ul: (props: any) => React.ReactNode;
    ol: (props: any) => React.ReactNode;
    li: (props: any) => React.ReactNode;
    table: (props: any) => React.ReactNode;
    thead: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    tbody: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    tr: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    th: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    td: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    input: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    a: (props: any) => React.ReactNode;
    strong: (props: any) => React.ReactNode;
    em: (props: any) => React.ReactNode;
    del: (props: any) => React.ReactNode;
    code: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    mark: (props: any) => React.ReactNode;
    kbd: (props: any) => React.ReactNode;
    sub: (props: any) => React.ReactNode;
    pre: (props: any) => React.ReactNode;
    img: (props: any) => React.ReactNode;
    video: (props: any) => React.ReactNode;
    audio: (props: any) => React.ReactNode;
    iframe: (props: any) => React.ReactNode;
    hr: (props: any) => React.ReactNode;
    sup: (props: any) => React.ReactNode;
    span: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    section: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
    think: (props: any) => React.FunctionComponentElement<import("../ToolUseBarThink").ToolUseBarThinkProps>;
    thinking: (props: any) => React.FunctionComponentElement<import("../ToolUseBarThink").ToolUseBarThinkProps>;
    answer: (props: any) => React.ReactElement<any, string | React.JSXElementConstructor<any>>;
};
/** markdown 片段 → React 元素 */
declare const renderMarkdownBlock: (blockContent: string, processor: Processor, components: Record<string, any>) => React.ReactNode;
/** 按单空行拆块，保留围栏代码块、列表、blockquote、HTML 注释+表格、脚注定义的连续性 */
declare const splitMarkdownBlocks: (content: string) => string[];
export interface UseMarkdownToReactOptions {
    remarkPlugins?: MarkdownRemarkPlugin[];
    htmlConfig?: MarkdownToHtmlConfig;
    components?: Record<string, React.ComponentType<RendererBlockProps>>;
    prefixCls?: string;
    linkConfig?: {
        openInNewTab?: boolean;
        onClick?: (url?: string) => boolean | void;
    };
    fncProps?: MarkdownEditorProps['fncProps'];
    streaming?: boolean;
    /** 默认开启；传 false 关闭末段段落动画 */
    streamingParagraphAnimation?: boolean;
    /** 原始流字符串，与 useStreaming 输出分离避免缓存误判 */
    contentRevisionSource?: string;
    /** 返回 undefined 回退默认渲染 */
    eleRender?: (props: MarkdownRendererEleProps, defaultDom: React.ReactNode) => React.ReactNode;
}
export { buildEditorAlignedComponents, createHastProcessor, renderMarkdownBlock, splitMarkdownBlocks, };
export type { MarkdownRendererEleProps };
