import { ActionIconProps } from '@mantine/core';
import { AlertProps } from '@mantine/core';
import { BadgeProps } from '@mantine/core';
import { BoxProps } from '@mantine/core';
import { ButtonProps } from '@mantine/core';
import { CodeProps } from '@mantine/core';
import { Command } from '@codemirror/view';
import { Command as Command_2 } from 'prosemirror-state';
import { EditorSelection } from '@codemirror/state';
import { EditorState } from 'prosemirror-state';
import { EditorView } from '@codemirror/view';
import { EditorView as EditorView_2 } from 'prosemirror-view';
import { ElementProps } from '@mantine/core';
import { Extension } from '@codemirror/state';
import { FC } from 'react';
import { Fragment } from 'prosemirror-model';
import { GroupProps } from '@mantine/core';
import { Highlighter } from '@lezer/highlight';
import { HighlightStyle } from '@codemirror/language';
import { HTMLAttributes } from 'react';
import { ImageProps } from '@mantine/core';
import { InputRule } from 'prosemirror-inputrules';
import { KeyBinding } from '@codemirror/view';
import { MantineColor } from '@mantine/core';
import { MantineColorScheme } from '@mantine/core';
import { MantineFontSize } from '@mantine/core';
import { MantineThemeOverride } from '@mantine/core';
import { MarkSpec } from 'prosemirror-model';
import { MarkType } from 'prosemirror-model';
import { Node as Node_2 } from 'prosemirror-model';
import { NodeSpec } from 'prosemirror-model';
import { NodeViewConstructor } from 'prosemirror-view';
import { PaperProps } from '@mantine/core';
import { PluginKey } from 'prosemirror-state';
import type * as React_2 from 'react';
import { ReactNode } from 'react';
import { RefObject } from 'react';
import { ResolvedPos } from 'prosemirror-model';
import { Schema } from 'prosemirror-model';
import { StackProps } from '@mantine/core';
import { StateField } from '@codemirror/state';
import { TabsProps as TabsProps_2 } from '@mantine/core';

/**
 * A keybind used to accept a completion
 */
export declare const acceptWithTab: KeyBinding;

/**
 * Add cursor above the current line
 */
export declare const addCursorAbove: Command;

/**
 * Add cursor below the current line
 */
export declare const addCursorBelow: Command;

/**
 * A keymap used to add a cursor below and above the current position
 */
export declare const addCursorVerticallyKeymap: readonly KeyBinding[];

declare type AnyFn = (...rest: any[]) => any;

export declare type AnyNode = BlockNode | InlineNode | SummaryNode | ListItemNode | TableRowNode | TableCellNode | TabItemNode;

/**
 * Apply automatic folding to objects/arrays at the specified depth level
 * @param view - CodeMirror editor view
 * @param autoCollapseDepth - Depth level to start folding (0 = disabled)
 */
export declare function applyAutoFolding(view: EditorView, autoCollapseDepth: number): void;

/**
 * A block in the editor document. Blocks have a stable `id`,
 * a `type` determining their behavior, `props` for type-specific
 * attributes, optional inline `content`, and optional nested
 * `children` blocks.
 */
export declare interface Block {
    id: string;
    type: BlockType;
    props: Record<string, unknown>;
    content?: InlineContent[];
    children?: Block[];
}

/**
 * Controller interface for interacting with a block editor instance.
 * Created by the `useBlockEditor` hook and passed to the `BlockEditor`
 * component.
 */
export declare interface BlockEditorController {
    /** Ref to attach to the editor's mount point DOM element. */
    ref: RefObject<HTMLDivElement | null>;
    /** Whether the ProseMirror EditorView has been mounted. */
    mounted: boolean;
    /** Access the underlying ProseMirror EditorView. Throws if not mounted. */
    getEditor: () => EditorView_2;
    /** Convert the current document to a Block[] JSON model. */
    getBlocks: () => Block[];
    /** Find a block by ID, searching recursively through children. */
    getBlock: (id: string) => Block | undefined;
    /** Find the sibling block before the block with the given ID. */
    getPreviousBlock: (id: string) => Block | undefined;
    /** Find the sibling block after the block with the given ID. */
    getNextBlock: (id: string) => Block | undefined;
    /** Append blocks to the end of the document. IDs are generated automatically. */
    appendBlocks: (...blocks: BlockInput[]) => void;
    /** Insert blocks after the block with the given reference ID. IDs are generated automatically. */
    insertBlocks: (referenceId: string, ...blocks: BlockInput[]) => void;
}

export declare const blockHandlePluginKey: PluginKey<BlockHandleState>;

declare interface BlockHandleState {
    hoveredBlockPos: number | null;
    hoveredBlockNode: Node_2 | null;
    dropIndicatorPos: number | null;
}

/**
 * Input type for creating blocks via the controller API.
 * Omits `id` since IDs are generated internally.
 */
export declare type BlockInput = Omit<Block, "id">;

export declare type BlockNode = HeadingNode | ParagraphNode | CodeNode | BlockquoteNode | ListNode | TableNode | ThematicBreakNode | DivNode | DetailsNode | ImageNode | CheckNode | RailroadDiagramNode | SurrealistMiniNode | VersionNode | SinceNode | LabelNode | TabsNode;

export declare interface BlockquoteNode {
    type: "blockquote";
    children: BlockNode[];
    className?: string;
    id?: string;
    style?: string;
    noteKind?: NoteKind;
    noteTitle?: string;
}

export declare const blockquoteSpec: NodeSpec;

/** Props for read-only block rendering. */
export declare interface BlockRendererProps {
    block: Block;
    inlineContent?: ReactNode;
    children?: ReactNode;
}

/** Configuration for creating a block type definition without raw ProseMirror NodeSpec. */
export declare interface BlockSpecConfig {
    /** Unique block type identifier (hyphenated, e.g. "callout"). */
    type: string;
    /** Map of prop names to their defaults. Generates NodeSpec attrs automatically. */
    propSchema?: Record<string, PropDefault>;
    /** Content model shorthand: "inline" for text, "blocks" for nested blocks, "none" for atoms. */
    content?: "inline" | "blocks" | "none";
    /** React component for rendering this block in the editor. */
    render?: FC<ReactNodeViewProps>;
    /** Slash menu entry for inserting this block. */
    slashMenuItem?: Omit<SlashMenuItem, "type">;
    /** Raw NodeSpec overrides for advanced use cases. Merged after generated spec. */
    nodeSpecOverrides?: Partial<NodeSpec>;
}

/** Convert a Block[] JSON model to a ProseMirror document node. */
export declare function blocksToDoc(blocks: Block[], schema: Schema): Node_2;

/** Convert a single Block to a ProseMirror blockContainer node. */
export declare function blockToNode(block: Block, schema: Schema): Node_2;

/** Identifies the type of a block in the editor document. Extensible via string. */
export declare type BlockType = "text" | "list-item" | "checklist-item" | "blockquote" | "table" | "table-row" | "table-cell" | "columns" | "column" | "divider" | "collapsible-item" | "code-block" | (string & {});

/**
 * Defines a block type that can be registered with a BlockTypeRegistry.
 * Includes the ProseMirror NodeSpec, optional React component for
 * rendering, slash menu entry, input rule, and behavior declarations.
 */
export declare interface BlockTypeDefinition {
    type: string;
    /** ProseMirror node name. Defaults to `type` if not specified. */
    nodeName?: string;
    nodeSpec: NodeSpec;
    /** React component for rendering this block via NodeView. */
    component?: FC<ReactNodeViewProps>;
    /** Whether the NodeView should be non-editable (atom). */
    atom?: boolean;
    /** Slash menu entries for inserting this block. */
    slashMenuItems?: SlashMenuItem[];
    /** Input rules for markdown-style shortcuts. */
    inputRules?: InputRule[];
    /**
     * Factory to create ProseMirror node(s) when this block is inserted
     * via the slash menu. Returns a blockContainer node.
     */
    createNode?: (schema: Schema) => Node_2;
    /** Declares list-like enter/backspace behavior. */
    listBehavior?: ListBehavior;
    /** When true, the Enter key is not handled (falls through to ProseMirror default). */
    enterPassthrough?: boolean;
    /** Extract Block.props from a ProseMirror node (doc -> JSON conversion). */
    toBlockProps?: (node: Node_2) => Record<string, unknown>;
    /** Convert Block.props to ProseMirror node attrs (JSON -> doc conversion). */
    fromBlockProps?: (props: Record<string, unknown>) => Record<string, unknown>;
    /** Custom logic for converting a Block to a ProseMirror inner node. */
    createInnerNode?: (block: Block, schema: Schema) => Node_2;
    /** Whether this block has inline text content. Auto-detected from nodeSpec if not set. */
    hasInlineContent?: boolean;
    /** Whether this block renders children inside itself (e.g. blockquote, table, columns). */
    isContainerBlock?: boolean;
    /** Label shown in the toolbar's block type dropdown. */
    toolbarLabel?: string | ((node: Node_2) => string);
    /** Options for the toolbar's block type conversion dropdown. */
    toolbarOptions?: {
        label: string;
        attrs?: Record<string, unknown>;
    }[];
    /** React component for rendering this block in read-only mode. */
    readOnlyRender?: FC<BlockRendererProps>;
}

/**
 * Registry for block types. Register definitions before
 * passing to `useBlockEditor` so the schema, slash menu, and
 * node views are extended automatically.
 */
export declare class BlockTypeRegistry {
    private definitions;
    /** Register a block type definition. */
    register(definition: BlockTypeDefinition): void;
    /** Look up a registered definition by block type name. */
    get(type: string): BlockTypeDefinition | undefined;
    /** Look up a registered definition by ProseMirror node name. */
    getByNodeName(nodeName: string): BlockTypeDefinition | undefined;
    /** Return all registered definitions. */
    getAll(): BlockTypeDefinition[];
    /** Collect ProseMirror NodeSpecs from all registered definitions. */
    getNodeSpecs(): Record<string, NodeSpec>;
    /** Collect slash menu items from all registered definitions. */
    getSlashMenuItems(): SlashMenuItem[];
    /** Collect input rules from all registered definitions. */
    getInputRules(): InputRule[];
}

export declare interface BooleanHandle {
    open: () => void;
    close: () => void;
    toggle: () => void;
    set: React.Dispatch<React.SetStateAction<boolean>>;
}

export declare const brandAgno: string;

export declare const brandAirbyte: string;

export declare const brandAmazonBedrock: string;

export declare const brandApple: string;

export declare const brandAppleRetro: string;

export declare const brandAspire: string;

export declare const brandAstro: string;

export declare const brandAWS: string;

export declare const brandBluesky: string;

export declare const brandC: string;

export declare const brandCalamu: string;

export declare const brandCamelAI: string;

export declare const brandCrewAI: string;

export declare const brandCursor: string;

export declare const brandDagster: string;

export declare const brandDeepEval: string;

export declare const brandDevTo: string;

export declare const brandDigitalKin: string;

export declare const brandDiscord: string;

export declare const brandDocker: string;

export declare const brandDotNet: string;

export declare const brandDynamiq: string;

export declare const brandFeast: string;

export declare const brandFivetran: string;

export declare const brandFountain: string;

export declare const brandGameScript: string;

export declare const brandGemini: string;

export declare const brandGithub: string;

export declare const brandGo: string;

export declare const brandGoogleAgent: string;

export declare const brandGoogleCloud: string;

export declare const brandHuggingFace: string;

export declare const brandInstagram: string;

export declare const brandJava: string;

export declare const brandJavaScript: string;

export declare const brandKubernetes: string;

export declare const brandLangchain: string;

export declare const brandLinkedin: string;

export declare const brandLinux: string;

export declare const brandLiveSponsors: string;

export declare const brandLlamaIndex: string;

export declare const brandMedium: string;

export declare const brandMicrosoftAzure: string;

export declare const brandMistral: string;

export declare const brandN8N: string;

export declare const brandNetlify: string;

export declare const brandNodeJs: string;

export declare const brandOllama: string;

export declare const brandOpenAi: string;

export declare const brandPermitIO: string;

export declare const brandPHP: string;

export declare const brandPolyAI: string;

export declare const brandPython: string;

export declare const brandReact: string;

export declare const brandReddit: string;

export declare const brandRuby: string;

export declare const brandRust: string;

export declare const brandSamsung: string;

export declare const brandSiteForge: string;

export declare const brandSmolAgents: string;

export declare const brandSolidJS: string;

export declare const brandStackOverflow: string;

export declare const brandSurrealDB: string;

export declare const brandSwift: string;

export declare const brandTencent: string;

export declare const brandThreads: string;

export declare const brandTogetherAI: string;

export declare const brandTypescript: string;

export declare const brandVercel: string;

export declare const brandVerizon: string;

export declare const brandVSCode: string;

export declare const brandWebAssembly: string;

export declare const brandWindows: string;

export declare const brandX: string;

export declare const brandYaacomm: string;

export declare const brandYouTube: string;

export declare const BreadcrumbButton: FC<ButtonProps & ElementProps<"button">>;

export declare interface BreakNode {
    type: "break";
    className?: string;
    id?: string;
    style?: string;
}

/**
 * Build a ProseMirror Schema from the registry's block type definitions.
 * The registry must already have all desired block types registered.
 * Use `customMarks` to add custom mark specs alongside the built-in ones.
 */
export declare function buildSchema(registry?: BlockTypeRegistry, _exclude?: string[], customMarks?: Record<string, MarkSpec>): Schema;

export declare const builtInMarks: Record<string, MarkSpec>;

export declare function Check({ children, ...props }: CheckProps): ReactNode;

export declare const checklistItemSpec: NodeSpec;

export declare interface CheckNode {
    type: "check";
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare interface CheckProps extends GroupProps {
    children?: ReactNode;
}

declare interface ChoiceNode {
    type: "Choice";
    default?: number;
    children: RailroadNode[];
}

export declare function clsx(...args: unknown[]): string;

/**
 * Enhanced code block component with copy button, title, and highlight regions
 */
export declare const CodeBlock: FC<CodeBlockProps>;

export declare interface CodeBlockProps extends Omit<PaperProps, "children" | "styles"> {
    title?: string;
    value: string;
    lang?: string;
    colorScheme?: MantineColorScheme;
    copyCodeProps?: ActionIconProps;
    withLineNumbers?: boolean;
}

export declare const codeBlockSpec: NodeSpec;

export declare const CodeEditor: FC<CodeEditorProps>;

export declare interface CodeEditorProps extends BoxProps {
    controller: EditorController;
    autoFocus?: boolean;
    innerProps?: BoxProps;
    withPadding?: boolean;
    ref?: RefObject<EditorView>;
}

export declare interface CodeNode {
    type: "code";
    value: string;
    lang?: string;
    title?: string;
    runnable?: string;
    className?: string;
    id?: string;
    style?: string;
}

export declare const collapsibleItemSpec: NodeSpec;

export declare type ColorScheme = keyof ThemeConfig;

declare type ColorScheme_2 = keyof ThemeConfig_2;

export declare const columnSpec: NodeSpec;

export declare const columnsSpec: NodeSpec;

declare interface CommentNode {
    type: "Comment";
    text: string;
}

/**
 * Common extensions applied to all CodeMirror editors
 */
export declare const commonExtensions: () => Extension;

declare type ComponentFunction<T extends AnyNode["type"]> = NodeOfType<T> extends {
    children: unknown[];
} ? (props: {
    node: NodeOfType<T>;
    children: ReactNode;
}) => ReactNode : (props: {
    node: NodeOfType<T>;
}) => ReactNode;

declare type ComponentMap = {
    [T in AnyNode["type"]]: ComponentFunction<T>;
};

/**
 * Factory function to create a BlockEditorController from refs.
 * Used internally by `useBlockEditor`.
 */
export declare function createBlockEditorController(ref: RefObject<HTMLDivElement | null>, editorViewRef: RefObject<EditorView_2 | null>, mountedRef: {
    current: boolean;
}): BlockEditorController;

/**
 * Create a BlockTypeDefinition from a simplified config.
 * Generates `nodeSpec` (including `parseDOM`/`toDOM`) automatically from `propSchema`.
 * The raw `nodeSpec` field on `BlockTypeDefinition` remains available via `nodeSpecOverrides`.
 */
export declare function createBlockSpec(config: BlockSpecConfig): BlockTypeDefinition;

/**
 * Create a style highlighter for the given color scheme and syntax theme
 */
export declare function createHighlighter(colorScheme: MantineColorScheme): Highlighter;

/**
 * Create an InlineContentDefinition from a simplified config.
 * Generates a ProseMirror inline node spec with appropriate attrs and DOM serialization.
 */
export declare function createInlineContentSpec(config: InlineContentSpecConfig): InlineContentDefinition;

export declare function createMarkKeymap(schema: Schema): Record<string, Command_2>;

/**
 * Create a ProseMirror NodeViewConstructor that renders a React
 * component via the PortalManager. The component receives
 * `ReactNodeViewProps` and can use `contentRef` to mark its
 * editable content area.
 *
 * **Focus resolution:** When a new NodeView is created and the
 * ProseMirror selection falls inside it, `contentDOM` is already
 * in the DOM tree so ProseMirror can sync its cursor. After React
 * renders the portal, `contentRef` re-parents `contentDOM` and
 * re-syncs the DOM selection automatically.
 *
 * **`data-focus` convention:** For blocks that need custom focus
 * behavior (e.g. atom blocks wrapping a `<CodeEditor>`), add a
 * `data-focus` attribute to the element that should receive DOM
 * focus. After React renders, the NodeView will call `.focus()`
 * on the first `[data-focus]` element if the ProseMirror selection
 * is inside this block.
 */
export declare function createReactNodeView(Component: FC<ReactNodeViewProps>, options?: {
    contentEditable?: boolean;
}): NodeViewConstructor;

/**
 * Create a new serialized editor state from a document string.
 *
 * @param doc The document string to create a serialized state from
 * @returns The serialized state
 */
export declare function createSerializedState(doc: string): EditorStateSnapshot;

/**
 * Create a style highlighter for the given color scheme and syntax theme
 */
export declare function createStyleHighlighter(theme: ThemeConfig_2, colorScheme: ColorScheme_2): Highlighter;

/**
 * A custom variant of the history keymap that uses
 * the Mod key instead of the Ctrl key
 */
export declare const customHistoryKeymap: readonly KeyBinding[];

export declare type DefaultSort = {
    [key: string]: unknown;
};

/**
 * Details component for collapsible content sections
 * Styled with obsidian border and surreal purple/pink accents
 */
export declare const Details: FC<DetailsProps> & {
    Summary: FC<SummaryProps>;
};

export declare interface DetailsNode {
    type: "details";
    children: Array<SummaryNode | BlockNode>;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface DetailsProps extends Omit<BoxProps, "component" | "children"> {
    children: ReactNode;
}

export declare interface DiagramNode {
    type: "Diagram";
    padding?: [number, number, number, number];
    children: RailroadNode[];
}

export declare const dividerSpec: NodeSpec;

export declare interface DivNode {
    type: "div";
    children: BlockNode[];
    className?: string;
    id?: string;
    style?: string;
}

/** Convert a ProseMirror document node to a Block[] JSON model. */
export declare function docToBlocks(doc: Node_2): Block[];

export declare interface EditorController {
    ref: RefObject<HTMLDivElement | null>;
    mounted: boolean;
    getEditor: () => EditorView;
    restoreState: (snapshot: EditorStateSnapshot) => void;
}

/**
 * Extensions applicable to all full editors
 */
export declare const editorExtensions: () => Extension;

export declare interface EditorOptions {
    fields?: StateFields;
    theme?: ThemeConfig;
    document?: string;
    state?: EditorStateSnapshot;
    readOnly?: boolean;
    extensions?: Extension;
    language?: Language;
    lineNumbers?: boolean;
    onMounted?: (editor: EditorView) => void;
    onChangeDocument?: (document: string) => void;
    onChangeSelection?: (selection: EditorSelection) => void;
    onChangeState?: (snapshot: EditorStateSnapshot) => void;
}

export declare type EditorStateSnapshot = Record<string, unknown>;

/**
 * Use a specific syntax theme with the given color scheme
 */
export declare function editorTheme(theme: ThemeConfig_2, colorScheme: MantineColorScheme): Extension;

export declare interface EmphasisNode {
    type: "emphasis";
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

/**
 * Enter a node (push to stack and set container)
 */
export declare function enterNode(state: ParserState, nodeType: string, node: BlockNode | SummaryNode): void;

export declare function executeSlashCommand(view: EditorView_2, schema: Schema, menuState: SlashMenuState, item: SlashMenuItem): void;

/**
 * Exit a node (pop from stack and validate)
 */
export declare function exitNode(state: ParserState, expectedType: string): void;

export declare interface ExtractedCode {
    test?: string;
    code: string;
}

/**
 * Extract test code from block comments at the start.
 * Pattern: block comment (slash-star-star ... star-slash) followed by code
 */
export declare function extractTest(input: string): ExtractedCode;

export declare function filterItems(items: SlashMenuItem[], query: string): SlashMenuItem[];

/**
 * Walk up from a resolved position to find the nearest ancestor
 * node matching the given type name.
 *
 * @returns The ancestor's absolute position, depth, and node, or null if not found.
 */
export declare function findAncestor($pos: ResolvedPos, typeName: string): {
    pos: number;
    depth: number;
    node: Node_2;
} | null;

/** Find the position and node of a blockContainer by its ID attribute. */
export declare function findBlockPos(doc: Node_2, id: string): {
    pos: number;
    node: Node_2;
} | undefined;

/**
 * Find the nearest blockContainer ancestor's position from a
 * resolved position.
 */
export declare function findContainerPos($pos: ResolvedPos): number | null;

/** Convert a ProseMirror inline Fragment to an InlineContent[] array. */
export declare function fragmentToInline(fragment: Fragment): InlineContent[];

/**
 * Generate a 24-character hex string suitable for use as a
 * stable block identifier. Uses `crypto.getRandomValues` for
 * collision resistance.
 */
export declare function generateRandomId(): string;

export declare interface HeadingNode {
    type: "heading";
    depth: 1 | 2 | 3 | 4 | 5 | 6;
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare const Highlighting: FC<HighlightingProps>;

export declare interface HighlightingProps extends BoxProps {
    value: string;
    language: string;
    colorScheme?: MantineColorScheme;
    highlightRegions?: HighlightRegion[];
    withLineNumbers?: boolean;
}

export declare interface HighlightRegion {
    start: number;
    end: number;
}

export declare const Icon: FC<IconProps>;

export declare const iconAccount: string;

export declare const iconAccountPlus: string;

export declare const iconAccountSecure: string;

export declare const iconAPI: string;

export declare const iconArrowDownFat: string;

export declare const iconArrowLeft: string;

export declare const iconArrowLeftFat: string;

export declare const iconArrowUpRight: string;

export declare const iconAuth: string;

export declare const iconAuthKeyhole: string;

export declare const iconAutoFix: string;

export declare const iconBalance: string;

export declare const iconBook: string;

export declare const iconBraces: string;

export declare const iconBrandBluesky: string;

export declare const iconBrandDev: string;

export declare const iconBrandDiscord: string;

export declare const iconBrandGitHub: string;

export declare const iconBrandInstagram: string;

export declare const iconBrandLinkedin: string;

export declare const iconBrandMedium: string;

export declare const iconBrandReddit: string;

export declare const iconBrandStackOverflow: string;

export declare const iconBrandX: string;

export declare const iconBrandYouTube: string;

export declare const iconBroadcastOff: string;

export declare const iconBroadcastOn: string;

export declare const iconBug: string;

export declare const iconBullhorn: string;

export declare const iconCalculator: string;

export declare const iconCancel: string;

export declare const iconChart: string;

export declare const iconChat: string;

export declare const iconChatGPT: string;

export declare const iconCheck: string;

export declare const iconCheckCircle: string;

export declare const iconChevronDown: string;

export declare const iconChevronLeft: string;

export declare const iconChevronRight: string;

export declare const iconChevronUp: string;

export declare const iconChevronY: string;

export declare const iconCircle: string;

export declare const iconCircleFilled: string;

export declare const iconClaude: string;

export declare const iconClock: string;

export declare const iconClose: string;

export declare const iconCloud: string;

export declare const iconCloudClock: string;

export declare const iconCog: string;

export declare const iconCombined: string;

export declare const iconCommand: string;

export declare const iconComment: string;

export declare const iconCommunity: string;

export declare const iconConsole: string;

export declare const iconCopy: string;

export declare const iconCreditCard: string;

export declare const iconCursor: string;

export declare const iconDatabase: string;

export declare const iconDatabaseSecure: string;

export declare const iconDataTable: string;

export declare const iconDelete: string;

export declare const iconDesigner: string;

export declare const iconDiscord: string;

export declare const iconDollar: string;

export declare const iconDotsVertical: string;

export declare const iconDownload: string;

export declare const iconDrag: string;

export declare const iconEdit: string;

export declare const iconEmail: string;

export declare const iconErrorCircle: string;

export declare const iconExitToAp: string;

export declare const iconExplorer: string;

export declare const iconEye: string;

export declare const iconEyeOff: string;

export declare const iconFile: string;

export declare const iconFilter: string;

export declare const iconFlag: string;

export declare const iconFloppy: string;

export declare const iconFolderPlus: string;

export declare const iconFolderSecure: string;

export declare const iconFullscreen: string;

export declare const iconFunction: string;

export declare const iconGraphql: string;

export declare const iconGrid: string;

export declare const iconHammer: string;

export declare const iconHeart: string;

export declare const iconHelp: string;

export declare const iconHistory: string;

export declare const iconHome: string;

export declare const iconHomePlus: string;

export declare const iconImage: string;

export declare const iconInbox: string;

export declare const iconIndex: string;

export declare const iconInfo: string;

export declare const iconJSON: string;

export declare const iconKey: string;

export declare const iconKeyboardControl: string;

export declare const iconKeyboardOption: string;

export declare const iconKeyboardShift: string;

export declare const iconList: string;

export declare const iconLive: string;

export declare const iconMagnifyMinus: string;

export declare const iconMagnifyPlus: string;

export declare const iconMarker: string;

export declare const iconMaximize: string;

export declare const iconMemory: string;

export declare const iconMinimize: string;

export declare const iconMinus: string;

export declare const iconModel: string;

export declare const iconModuleML: string;

export declare const iconMoon: string;

export declare const iconMute: string;

export declare const iconNamespace: string;

export declare const iconNewspaper: string;

export declare const iconOpen: string;

export declare const iconOpenFolder: string;

export declare const iconOrganization: string;

export declare const iconPackageClosed: string;

export declare const iconPaperclip: string;

export declare const iconPause: string;

export declare const iconPin: string;

export declare const iconPinOff: string;

export declare const iconPlay: string;

export declare const iconPlus: string;

export declare const iconPower: string;

export declare const iconProgressClock: string;

export declare interface IconProps extends BoxProps, Omit<HTMLAttributes<SVGElement>, "style"> {
    size?: MantineFontSize | number;
    color?: MantineColor;
    spin?: boolean;
    path: string;
    flip?: "horizontal" | "vertical";
}

export declare const iconQuery: string;

export declare const iconReferral: string;

export declare const iconRefresh: string;

export declare const iconRelation: string;

export declare const iconRelationIn: string;

export declare const iconRelationOut: string;

export declare const iconReset: string;

export declare const iconRestore: string;

export declare const iconRoutes: string;

export declare const iconSandbox: string;

export declare const iconSearch: string;

export declare const iconSend: string;

export declare const iconServer: string;

export declare const iconServerSecure: string;

export declare const iconSidebar: string;

export declare const iconSidekick: string;

export declare const iconStar: string;

export declare const iconStarPlus: string;

export declare const iconStop: string;

export declare const iconSun: string;

export declare const iconSurreal: string;

export declare const iconSurrealist: string;

export declare const iconTable: string;

export declare const iconTag: string;

export declare const iconTarget: string;

export declare const iconText: string;

export declare const iconTextBox: string;

export declare const iconTextBoxMinus: string;

export declare const iconTextBoxPlus: string;

export declare const iconTransfer: string;

export declare const iconTune: string;

export declare const iconUniversity: string;

export declare const iconUnmute: string;

export declare const iconUpload: string;

export declare const iconVariable: string;

export declare const iconVideo: string;

export declare const iconViewGrid: string;

export declare const iconViewList: string;

export declare const iconWarning: string;

export declare const iconWrench: string;

export declare const iconXml: string;

export declare interface ImageNode {
    type: "image";
    src: string;
    darkSrc?: string;
    alt: string;
    title?: string;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface InlineCodeNode {
    type: "inlineCode";
    value: string;
    className?: string;
    id?: string;
    style?: string;
}

/** A piece of inline content within a block, either styled text, a link, or custom inline content. */
export declare type InlineContent = {
    type: "text";
    text: string;
    styles?: TextStyles;
} | {
    type: "link";
    href: string;
    content: InlineContent[];
} | {
    type: string;
    props: Record<string, unknown>;
};

/** Definition of a custom inline content type. */
export declare interface InlineContentDefinition {
    type: string;
    nodeSpec: NodeSpec;
    component: FC<ReactNodeViewProps>;
    triggerCharacter?: string;
}

/** Configuration for creating a custom inline content type. */
export declare interface InlineContentSpecConfig {
    /** Unique type identifier for this inline content. */
    type: string;
    /** Map of prop names to their defaults. */
    propSchema?: Record<string, InlinePropDefault>;
    /** Whether this inline content contains styled text ("styled") or not ("none"). */
    content?: "styled" | "none";
    /** React component for rendering this inline content. */
    render: FC<ReactNodeViewProps>;
    /** Character that triggers a suggestion menu for inserting this inline content (e.g. "@"). */
    triggerCharacter?: string;
}

export declare type InlineNode = TextNode | LinkNode | InlineCodeNode | StrongNode | EmphasisNode | BreakNode | ImageNode;

/** Schema for a single inline content prop with a default value. */
export declare interface InlinePropDefault {
    default: string | number | boolean;
}

/** Convert an InlineContent[] array to a ProseMirror inline Fragment. */
export declare function inlineToFragment(content: InlineContent[], schema: Schema): Fragment;

/**
 * Check if a code point is an emoji
 * Simplified ranges - merged consecutive ranges
 */
export declare function isEmojiCodePoint(code: number): boolean;

/**
 * Check if a tag is self-closing
 */
export declare function isSelfClosingTag(tagName: string): boolean;

export declare function Label({ label, ...props }: LabelProps): ReactNode;

export declare interface LabelNode {
    type: "label";
    label: string;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface LabelProps extends Omit<BadgeProps, "children"> {
    label: string;
}

declare type Language = "csharp" | "rust" | "javascript" | "typescript" | "surrealql" | "json" | "yaml" | "java" | "go" | "python" | "html" | "cli" | "php" | "syntax";

export declare interface LinkNode {
    type: "link";
    url: string;
    title?: string;
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

/** Declares list-like enter/backspace behavior for a block type. */
export declare interface ListBehavior {
    /** Create a new sibling node when Enter is pressed. */
    createSibling: (schema: Schema) => Node_2;
    /** Text prefix to insert when backspacing an empty item back to text. */
    backspacePrefix?: string;
}

export declare interface ListItemNode {
    type: "listItem";
    checked?: boolean;
    spread?: boolean;
    children: AnyNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare const listItemSpec: NodeSpec;

export declare interface ListNode {
    type: "list";
    variant?: "ordered" | "unordered" | "checklist";
    start?: number;
    spread?: boolean;
    children: ListItemNode[];
    className?: string;
    id?: string;
    style?: string;
}

/**
 * The Mantine theme configurtation
 */
export declare const MANTINE_THEME: MantineThemeOverride;

export declare function markActive(state: EditorState, type: MarkType): boolean;

/**
 * Main Markdown component that parses markdown and renders it
 * Applies stylesheet and spacing
 */
export declare function Markdown({ content, components, componentProps, }: MarkdownProps): React_2.ReactElement;

declare interface MarkdownComponentProps {
    code?: Partial<CodeBlockProps>;
}

export declare interface MarkdownProps {
    /**
     * Markdown content to render
     */
    content: string;
    /**
     * Optional custom component overrides
     */
    components?: Partial<Record<string, React_2.ComponentType<unknown>>>;
    componentProps?: MarkdownComponentProps;
}

export declare interface MiniConfig {
    url?: string;
    dataset?: "surreal-deal-store-mini" | `/${string}.surql`;
    setup?: string;
    query?: string;
    variables?: string | Record<string, unknown>;
    theme?: "auto" | "light" | "dark";
    orientation?: "horizontal" | "vertical";
    appearance?: "normal" | "compact" | "plain";
    transparent?: boolean;
    autorun?: boolean;
    corners?: string;
    nonumbers?: boolean;
}

export declare class MiniController {
    private frameRef;
    constructor(frameRef: RefObject<HTMLIFrameElement | null>);
    private get ref();
    private post;
    /**
     * Updates the currently displayed query or variables in the mini
     */
    setEditor(options: {
        query?: string;
        variables?: string;
    }): void;
    /**
     * Clears the query response
     */
    clearResponse(): void;
    /**
     * Sets the mini to show either the query or variables editor
     */
    setEditorMode(mode: "query" | "variables"): void;
    /**
     * Sets the output/result mode to combined, single, graph, table or live
     */
    setResultMode(mode: "combined" | "single" | "graph" | "table" | "live"): void;
    /**
     * Runs the query with the variables as they are currently set
     */
    runQuery(): void;
    /**
     * Executes a given query in the background
     */
    executeQuery(query: string): void;
}

declare type NodeOfType<T extends AnyNode["type"]> = Extract<AnyNode, {
    type: T;
}>;

declare interface NonTerminalNode {
    type: "NonTerminal";
    text: string;
}

/**
 * Note/Callout component with variants: note, important, warning, caution
 */
export declare const Note: FC<NoteProps>;

export declare const NOTE_KINDS: readonly ["note", "tip", "important", "warning", "caution"];

export declare type NoteKind = (typeof NOTE_KINDS)[number];

export declare interface NoteProps extends Omit<AlertProps, "title" | "children"> {
    kind: NoteKind;
    title?: string;
    children: ReactNode;
}

declare interface OneOrMoreNode {
    type: "OneOrMore";
    child: RailroadNode;
    repeat?: RailroadNode;
}

declare interface OptionalNode {
    type: "Optional";
    skip?: boolean;
    child: RailroadNode;
}

export declare interface ParagraphNode {
    type: "paragraph";
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

/**
 * Parse HTML-style attributes from a string
 * Handles: name="value", name='value', name=value
 * Properly handles escaped quotes: name="value with \"escaped\" quotes"
 */
export declare function parseAttributes(attrString: string): Record<string, string>;

export declare function parseBlockquote(state: ParserState): void;

export declare function parseCheckTag(state: ParserState, attrs: Record<string, string>): void;

export declare function parseCodeBlock(state: ParserState): void;

export declare function parseDetailsTag(state: ParserState, attrs: Record<string, string>): void;

export declare function parseDivTag(state: ParserState, attrs: Record<string, string>): void;

export declare function parseEmphasis(text: string, startIndex: number): {
    node: EmphasisNode;
    endIndex: number;
} | null;

export declare function parseHeading(state: ParserState): void;

/**
 * Parse an HTML `<table>` element into the same TableNode AST
 * that the markdown `| ... |` table parser produces.
 *
 * Handles `<thead>`, `<tbody>`, `<tr>`, `<th>`, `<td>`, and common
 * inline HTML elements inside cells (`<strong>`, `<em>`, `<mark>`,
 * `<code>`, `<a>`).
 */
export declare function parseHtmlTable(state: ParserState, attrs: Record<string, string>): void;

export declare function parseHtmlTag(state: ParserState): void;

export declare function parseHtmlTagInline(text: string, startIndex: number): {
    node: BreakNode;
    endIndex: number;
} | null;

export declare function parseImage(text: string, startIndex: number): {
    node: ImageNode;
    endIndex: number;
} | null;

export declare function parseInlineCode(text: string, startIndex: number): {
    node: InlineCodeNode;
    endIndex: number;
} | null;

/**
 * Parse inline markdown content
 */
export declare function parseInlines(text: string): InlineNode[];

export declare function parseLink(text: string, startIndex: number): {
    node: LinkNode;
    endIndex: number;
} | null;

export declare function parseList(state: ParserState): void;

/**
 * Parse markdown string to AST
 */
export declare function parseMarkdown(markdown: string): Root;

export declare function parseParagraph(state: ParserState): void;

export declare interface ParserState {
    lines: string[];
    currentIndex: number;
    stack: string[];
    root: BlockNode[];
    currentContainer: BlockNode[];
}

export declare function parseStrong(text: string, startIndex: number): {
    node: StrongNode;
    endIndex: number;
} | null;

export declare function parseSummaryTag(state: ParserState, attrs: Record<string, string>): void;

export declare function parseTable(state: ParserState): void;

export declare function parseTableAlignment(line: string): Array<"left" | "right" | "center" | null>;

/**
 * Parse a table row into cells
 * Note: Escaped pipes (\|) are not currently supported - they will be treated as cell separators
 * @param line - The table row line
 * @param isHeader - Whether this is a header row
 * @returns Array of table cell nodes
 */
export declare function parseTableRow(line: string, isHeader?: boolean): TableCellNode[];

export declare function parseTabsTag(state: ParserState, attrs: Record<string, string>): void;

export declare function parseText(text: string, startIndex: number): {
    node: TextNode;
    endIndex: number;
};

export declare function parseThematicBreak(state: ParserState): void;

export declare const picto2106: string;

export declare const picto360DegreeView: string;

export declare const picto5Stars: string;

export declare const pictoACID: string;

export declare const pictoAgno: string;

export declare const pictoAI: string;

export declare const pictoAPI: string;

export declare const pictoArrowDown: string;

export declare const pictoArrowUp: string;

export declare const pictoAtom: string;

export declare const pictoAudioClip: string;

export declare const pictoBackups: string;

export declare const pictoBadgeAccess: string;

export declare const pictoBank: string;

export declare const pictoBars: string;

export declare const pictoBegin: string;

export declare const pictoBicycle: string;

export declare const pictoBinary: string;

export declare const pictoBook: string;

export declare const pictoBookmark: string;

export declare const pictoBot: string;

export declare const pictoBrain: string;

export declare const pictoBreakfast: string;

export declare const pictoBucket: string;

export declare const pictoCancel: string;

export declare const pictoCapabilites: string;

export declare const pictoCBOR: string;

export declare const pictoChatHeart: string;

export declare const pictoChecklist: string;

export declare const pictoChristmas: string;

export declare const pictoClaimsManagement: string;

export declare const pictoClaude: string;

export declare const pictoCline: string;

export declare const pictoClipboard: string;

export declare const pictoClisdb: string;

export declare const pictoClock: string;

export declare const pictoCloud: string;

export declare const pictoCloudNodes: string;

export declare const pictoColor: string;

export declare const pictoCommit: string;

export declare const pictoCommitQueue: string;

export declare const pictoComputer: string;

export declare const pictoConflictDetection: string;

export declare const pictoConnect: string;

export declare const pictoContext: string;

export declare const pictoCopyright: string;

export declare const pictoCore: string;

export declare const pictoCreate: string;

export declare const pictoCrop: string;

export declare const pictoCrown: string;

export declare const pictoCurlyBraces: string;

export declare const pictoCursor: string;

export declare const pictoDedicatedSupport: string;

export declare const pictoDev: string;

export declare const pictoDevelopment: string;

export declare const pictoDiscord: string;

export declare const pictoDocument: string;

export declare const pictoDocumentSearch: string;

export declare const pictoDollar: string;

export declare const pictoDownload: string;

export declare const pictoDragCursor: string;

export declare const pictoEar: string;

export declare const pictoEmbeddedDevices: string;

export declare const pictoEmbeddedEdge: string;

export declare const pictoEmbeddingg: string;

export declare const pictoEntertainment: string;

export declare const pictoEV: string;

export declare const pictoExpand: string;

export declare const pictoFile: string;

export declare const pictoFingerPrints: string;

export declare const pictoFlexible: string;

export declare const pictoFloat: string;

export declare const pictoForm: string;

export declare const pictoFraudDetection: string;

export declare const pictoFrown: string;

export declare const pictoFullTextSearch: string;

export declare const pictoGenerativeAI: string;

export declare const pictoGeospatial: string;

export declare const pictoGitHub: string;

export declare const pictoGlitter: string;

export declare const pictoGQL: string;

export declare const pictoGraph: string;

export declare const pictoGraphQL: string;

export declare const pictoGraphRAG: string;

export declare const pictoGrid: string;

export declare const pictoGrowth: string;

export declare const pictoHands: string;

export declare const pictoHandsOn: string;

export declare const pictoHardDisc: string;

export declare const pictoHealthBubble: string;

export declare const pictoHealthChat: string;

export declare const pictoHealthInsurance: string;

export declare const pictoHomeSetup: string;

export declare const pictoHTTP: string;

export declare const pictoHyperlink: string;

export declare const pictoImage: string;

export declare const pictoInbox: string;

export declare const pictoInclusiveCommunication: string;

export declare const pictoInstagram: string;

export declare const pictoInstanceVersion: string;

export declare const pictoIntegrations: string;

export declare const pictoIntegrationSupport: string;

export declare const pictoIntercom: string;

export declare const pictoJSON: string;

export declare const pictoJSONFile: string;

export declare const pictoKey: string;

export declare const pictoKeyValue: string;

export declare const pictoKnowledgeGraph: string;

export declare const pictoKV: string;

export declare const pictoLangChain: string;

export declare const pictoLaptop: string;

export declare const pictoLifebuoy: string;

export declare const pictoLightbulb: string;

export declare const pictoLinkedIn: string;

export declare const pictoLunch: string;

export declare const pictoMachineLearning: string;

export declare const pictoMail: string;

export declare const pictoManInCircle: string;

export declare const pictoMCP: string;

export declare const pictoMediaFile: string;

export declare const pictoMedium: string;

export declare const pictoMemory: string;

export declare const pictoMentalHealth: string;

export declare const pictoMergeQueue: string;

export declare const pictoMicrophone: string;

export declare const pictoML: string;

export declare const pictoN8n: string;

export declare const pictoNature: string;

export declare const pictoNinja: string;

export declare const pictoNodeBrain: string;

export declare const pictoNotification: string;

export declare const pictoOnDisk: string;

export declare const pictoOperationalReadiness: string;

export declare const pictoPadlockClosed: string;

export declare const pictoPadlockOpen: string;

export declare const pictoPalette: string;

export declare const pictoPaperclip: string;

export declare const pictoPasskey: string;

export declare const pictoPath: string;

export declare const pictoPDF: string;

export declare const pictoPen: string;

export declare const pictoPension: string;

export declare const pictoPercentage: string;

export declare const pictoPerformance: string;

export declare const pictoPersonalizedPolicy: string;

export declare const pictoPieChart: string;

export declare const pictoPin: string;

export declare const pictoPlay: string;

export declare const pictoPlayPause: string;

export declare const pictoPlugins: string;

export declare const pictoPortability: string;

export declare const pictoPortfolioRiskManagement: string;

export declare const pictoPresentation: string;

export declare const pictoPriceTag: string;

export declare const pictoProblemDangerError: string;

export declare const pictoPuzzle: string;

export declare const pictoPython: string;

export declare const pictoQL: string;

export declare const pictoQuestion: string;

export declare const pictoQuotationMarks: string;

export declare const pictoQuote: string;

export declare const pictoRAG: string;

export declare const pictoRealTimeApplications: string;

export declare const pictoReddit: string;

export declare const pictoReferenceGuides: string;

export declare const pictoRegulatoryCompliance: string;

export declare const pictoRelational: string;

export declare const pictoREST: string;

export declare const pictoRiskManagement: string;

export declare const pictoRocket: string;

export declare const pictoRPC: string;

export declare const pictoRust: string;

export declare const pictoSafe: string;

export declare const pictoSaveFloppyDisc: string;

export declare const pictoScale: string;

export declare const pictoSDBCloud: string;

export declare const pictoSDKs: string;

export declare const pictoSecureDocument: string;

export declare const pictoSettings: string;

export declare const pictoSidekick: string;

export declare const pictoSignal: string;

export declare const pictoSmartphone: string;

export declare const pictoSmile: string;

export declare const pictoSpectron: string;

export declare const pictoSpeed: string;

export declare const pictoSQLBackends: string;

export declare const pictoStability: string;

export declare const pictoStackOverflow: string;

export declare const pictoStar: string;

export declare const pictoSurrealDB: string;

export declare const pictoSurrealism: string;

export declare const pictoSurrealist: string;

export declare const pictoSwag: string;

export declare const pictoSwatch: string;

export declare const pictoTables: string;

export declare const pictoText: string;

export declare const pictoThreads: string;

export declare const pictoThumbnail: string;

export declare const pictoThumbsDown: string;

export declare const pictoThumbsUp: string;

export declare const pictoTimeline: string;

export declare const pictoTimeSeries: string;

export declare const pictoTOML: string;

export declare const pictoTravel: string;

export declare const pictoTrigger: string;

export declare const pictoTutorials: string;

export declare const pictoTwoCircles: string;

export declare const pictoUniversity: string;

export declare const pictoUpdate: string;

export declare const pictoUpscale: string;

export declare const pictoValue: string;

export declare const pictoVectorSearch: string;

export declare const pictoVectorStores: string;

export declare const pictoVideoFile: string;

export declare const pictoVisualStudioCode: string;

export declare const pictoWasm: string;

export declare const pictoWindsurf: string;

export declare const pictoX: string;

export declare const pictoYoga: string;

export declare const pictoYoutube: string;

export declare const pictoYUApp: string;

export declare const pictoZapier: string;

export declare const pictoZed: string;

export declare const pictoZoomIn: string;

declare interface PortalEntry {
    key: string;
    component: ReactNode;
    container: HTMLElement;
}

declare type PortalListener = () => void;

/**
 * Manages React portals for ProseMirror NodeViews. Coordinates
 * between ProseMirror's synchronous DOM lifecycle and React's
 * async rendering via a portal registry and subscription model.
 */
export declare class PortalManager {
    private portals;
    private listeners;
    private cachedEntries;
    register(entry: PortalEntry): void;
    update(key: string, component: ReactNode): void;
    remove(key: string): void;
    getEntries(): PortalEntry[];
    subscribe(listener: PortalListener): () => void;
    private invalidate;
}

export declare function PortalOutlet({ manager }: {
    manager: PortalManager;
}): ReactNode;

export declare function PortalProvider({ manager, children, }: {
    manager: PortalManager;
    children: ReactNode;
}): ReactNode;

/**
 * Process highlight regions in code
 */
export declare function processHighlightRegions(code: string): {
    regions: HighlightRegion[];
    processedCode: string;
};

/** Schema for a single block prop with a default value. */
export declare interface PropDefault {
    default: string | number | boolean;
}

/**
 * Validate and process code attributes
 */
export declare function pushCode(attrs: Record<string, string>, value: string, lang?: string): CodeNode;

/**
 * Validate and process details attributes
 */
export declare function pushDetails(attrs: Record<string, string>): DetailsNode;

export declare function pushDiv(attrs: Record<string, string>): DivNode;

/**
 * Validate and process image attributes
 */
export declare function pushImage(attrs: Record<string, string>): ImageNode;

/**
 * Validate and process summary attributes
 */
export declare function pushSummary(attrs: Record<string, string>): SummaryNode;

export declare function RailroadDiagram({ ast, ...props }: RailroadDiagramProps): ReactNode;

export declare interface RailroadDiagramNode {
    type: "railroadDiagram";
    ast?: DiagramNode;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface RailroadDiagramProps extends BoxProps {
    ast?: DiagramNode;
}

export declare type RailroadNode = DiagramNode | SequenceNode | TerminalNode | NonTerminalNode | OptionalNode | ChoiceNode | OneOrMoreNode | ZeroOrMoreNode | CommentNode;

/** Props passed to React components rendered inside ProseMirror NodeViews. */
export declare interface ReactNodeViewProps {
    node: Node_2;
    view: EditorView_2;
    getPos: () => number | undefined;
    contentRef: (element: HTMLElement | null) => void;
    selected: boolean;
    updateAttrs: (attrs: Record<string, unknown>) => void;
}

/**
 * Read tag name from HTML tag starting at index
 * Returns tag name and end index
 */
export declare function readTagName(text: string, startIndex: number): {
    tagName: string;
    endIndex: number;
};

/**
 * Register all built-in block type definitions with the registry and
 * return the fully-built ProseMirror Schema.
 *
 * Performs a two-phase bootstrap:
 * 1. Registers nodeSpecs using a minimal stub schema (no input rules)
 * 2. Builds the real schema from the registry, then re-registers
 *    definitions with proper input rules that reference real node types.
 */
export declare function registerBuiltInBlocks(registry: BlockTypeRegistry, exclude?: string[]): Schema;

/**
 * Render parsed markdown AST to React elements
 * Direct AST-to-React conversion with component mapping
 */
export declare function RenderMarkdown({ ast, components, componentProps, ...props }: RenderMarkdownProps): React_2.ReactElement | null;

export declare interface RenderMarkdownProps extends StackProps {
    /**
     * Parsed markdown AST to render
     */
    ast: Root;
    /**
     * Optional custom component overrides
     */
    components?: Partial<ComponentMap>;
    componentProps?: MarkdownComponentProps;
}

export declare function resolveDropPosition(view: EditorView_2, clientY: number): number | null;

export declare interface Root {
    type: "root";
    children: BlockNode[];
}

declare interface SequenceNode {
    type: "Sequence";
    children: RailroadNode[];
}

/**
 * Set the contents of the editor
 *
 * @param editor The editor to set the text of
 * @param text The text to set the editor to
 */
export declare function setEditorText(editor: EditorView, text: string): void;

export declare function Since({ v, prefix, ...props }: SinceProps): ReactNode;

export declare interface SinceNode {
    type: "since";
    v: string;
    prefix?: string;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface SinceProps extends Omit<BadgeProps, "children"> {
    v: string;
    prefix?: string;
}

/** Describes an entry in the slash command menu. */
export declare interface SlashMenuItem {
    type: string;
    label: string;
    description?: string;
    icon?: ReactNode;
    shortcut?: string;
    /** Create a ProseMirror blockContainer node for this menu item. */
    createNode?: (schema: Schema, id: string) => Node_2;
}

export declare const slashMenuPluginKey: PluginKey<SlashMenuState>;

declare interface SlashMenuState {
    open: boolean;
    blockPos: number | null;
    triggerPos: number;
    query: string;
    selectedIndex: number;
    items: SlashMenuItem[];
}

export declare type SortDirection = "asc" | "desc" | undefined;

export declare interface SortHandle<T = DefaultSort> {
    column: keyof T | undefined;
    direction: SortDirection;
    toggle: (column: keyof T) => void;
}

export declare interface SortOptions<T = DefaultSort> {
    defaultColumn?: keyof T;
    defaultSort?: SortDirection;
}

export declare const Spacer: FC<BoxProps>;

export declare type StateFields = {
    [prop: string]: StateField<any>;
};

export declare interface StrongNode {
    type: "strong";
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

/**
 * Suggest completions at the start of each line
 */
export declare const suggestCompletions: Command;

export declare interface SummaryNode {
    type: "summary";
    children: InlineNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare interface SummaryProps extends Omit<BoxProps, "component" | "children"> {
    children: ReactNode;
}

export declare function SurrealistMini({ config, frameRef, ...props }: SurrealistMiniProps): ReactNode;

export declare interface SurrealistMiniNode {
    type: "surrealistMini";
    url?: string;
    dataset?: string;
    setup?: string;
    query?: string;
    variables?: string;
    theme?: string;
    orientation?: string;
    appearance?: string;
    transparent?: string;
    autorun?: string;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface SurrealistMiniProps extends BoxProps {
    config?: MiniConfig;
    frameRef?: RefObject<HTMLIFrameElement | null>;
}

export declare const SYNTAX_THEME_CONFIG: ThemeConfig;

export declare interface TabItem {
    label: string;
    icon?: string;
    content: ReactNode;
}

export declare interface TabItemNode {
    type: "tabItem";
    label: string;
    icon?: string;
    children: BlockNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare interface TableCellNode {
    type: "tableCell";
    children: AnyNode[];
    className?: string;
    id?: string;
    style?: string;
    isHeader: boolean;
}

export declare const tableCellSpec: NodeSpec;

export declare interface TableNode {
    type: "table";
    align?: Array<"left" | "right" | "center" | null>;
    children: TableRowNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare interface TableRowNode {
    type: "tableRow";
    children: TableCellNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare const tableRowSpec: NodeSpec;

export declare const tableSpec: NodeSpec;

export declare function Tabs({ items, syncKey, ...props }: TabsProps): ReactNode;

export declare interface TabsNode {
    type: "tabs";
    syncKey?: string;
    children: TabItemNode[];
    className?: string;
    id?: string;
    style?: string;
}

export declare interface TabsProps extends Omit<TabsProps_2, "children" | "value" | "onChange"> {
    items: TabItem[];
    syncKey?: string;
}

declare interface TerminalNode {
    type: "Terminal";
    text: string;
}

export declare const textBlockSpec: NodeSpec;

export declare interface TextNode {
    type: "text";
    value: string;
    className?: string;
    id?: string;
    style?: string;
}

/** Rich text style flags applied to inline text content. */
export declare interface TextStyles {
    bold?: boolean;
    italic?: boolean;
    underline?: boolean;
    strikethrough?: boolean;
    code?: boolean;
}

export declare interface ThematicBreakNode {
    type: "thematicBreak";
    className?: string;
    id?: string;
    style?: string;
}

export declare type ThemeConfig = {
    light: HighlightStyle;
    dark: HighlightStyle;
};

declare type ThemeConfig_2 = {
    light: HighlightStyle;
    dark: HighlightStyle;
};

/**
 * ThemedImage component that displays different images based on the current color scheme.
 * Extends Mantine's Image component with support for light/dark mode images.
 * Uses Mantine's useColorScheme hook to determine the current theme.
 * Users can override via the colorScheme prop.
 *
 * For pre-loading both images, consider adding <link rel="preload"> tags in your HTML head.
 */
export declare const ThemedImage: FC<ThemedImageProps>;

export declare interface ThemedImageProps extends ImageProps {
    darkSrc: string;
    colorScheme?: "light" | "dark";
}

/** Map a camelCase ProseMirror node name to the hyphenated BlockType string. */
export declare function toBlockType(nodeName: string): string;

/** Map a hyphenated BlockType string to the camelCase ProseMirror node name. */
export declare function toNodeName(blockType: string): string;

export declare const toolbarPluginKey: PluginKey<ToolbarState>;

declare interface ToolbarState {
    show: boolean;
    from: number;
    to: number;
}

/**
 * Type-specific visitor function
 */
export declare type TypeVisitor<T extends AnyNode> = (node: T, index: number | undefined, parent: AnyNode | Root | null) => undefined | boolean | void;

export declare function useEditor(options?: EditorOptions): EditorController;

/**
 * Trigger a new render and invoke the passed function
 * during this next call. Useful when you require the component
 * state to be updated before dispatching an action.
 *
 * @param doLater The callback to invoke
 * @returns The function to trigger invocation
 */
export declare function useLater<T extends unknown[]>(doLater: (...args: T) => unknown): (...args: T) => void;

export declare function useMiniController(): [RefObject<HTMLIFrameElement | null>, MiniController];

export declare function useSort<T = DefaultSort>(options?: SortOptions<T>): SortHandle<T>;

/**
 * Wraps the given unstable function in a stable callback.
 *
 * @param callback The unstable callback function
 * @returns The stable callback
 */
export declare function useStable<T extends AnyFn>(callback: T): T;

/**
 * A state used to track an active/inactive switch state (boolean)
 *
 * @param initialState The initial state of the switch
 * @param callbacks The callbacks to call when the switch is opened or closed
 * @returns
 */
export declare function useSwitch(initialState?: boolean, callbacks?: {
    onOpen?: () => void;
    onClose?: () => void;
}): readonly [boolean, BooleanHandle];

export declare function Version({ version, ...props }: VersionProps): ReactNode;

export declare interface VersionNode {
    type: "version";
    version?: string;
    className?: string;
    id?: string;
    style?: string;
}

export declare interface VersionProps extends CodeProps {
    version: string;
}

/**
 * Visit all nodes in the tree
 */
export declare function visit(tree: Root | AnyNode, visitor: Visitor): void;

export declare function visit<T extends AnyNode["type"]>(tree: Root | AnyNode, nodeType: T, visitor: TypeVisitor<NodeOfType<T>>): void;

/**
 * Generic visitor function
 */
export declare type Visitor = (node: AnyNode, index: number | undefined, parent: AnyNode | Root | null) => undefined | boolean | void;

/**
 * The default UI Kit editor theme
 */
export declare const VIVID_THEME: ThemeConfig_2;

declare interface ZeroOrMoreNode {
    type: "ZeroOrMore";
    child: RailroadNode;
    repeat?: RailroadNode;
}

export { }

declare module "@mantine/core" {
    type SurrealVariant = "surreal";
    type SurrealInputVariant = SurrealVariant | "filled";
    interface ActionIconProps {
        variant?: import("@mantine/core").ActionIconVariant | SurrealVariant;
    }
    interface ThemeIconProps {
        variant?: import("@mantine/core").ThemeIconVariant | SurrealVariant;
    }
    interface ButtonProps {
        variant?: import("@mantine/core").ButtonVariant | SurrealVariant;
    }
    interface TextInputProps {
        variant?: import("@mantine/core").InputVariant | SurrealInputVariant;
    }
    interface InputBaseProps {
        variant?: import("@mantine/core").InputVariant | SurrealInputVariant;
    }
    interface AutocompleteProps {
        variant?: import("@mantine/core").InputVariant | SurrealVariant;
    }
    interface DividerProps {
        variant?: import("@mantine/core").DividerVariant | SurrealVariant;
    }
    interface CloseButtonProps {
        variant?: import("@mantine/core").CloseButtonVariant | SurrealVariant;
    }
    interface AnchorProps {
        variant?: import("@mantine/core").AnchorVariant | SurrealVariant | "glow" | "vibrant";
    }
    interface SelectProps {
        variant?: import("@mantine/core").InputVariant | SurrealInputVariant;
    }
    interface BadgeProps {
        variant?: import("@mantine/core").BadgeVariant | SurrealVariant;
    }
    interface CheckboxProps {
        variant?: import("@mantine/core").CheckboxVariant | SurrealVariant | "gradient";
    }
    interface RadioProps {
        variant?: import("@mantine/core").RadioVariant | SurrealVariant | "gradient";
    }
    interface PasswordInputProps {
        variant?: import("@mantine/core").InputVariant | SurrealInputVariant;
    }
    interface NavLinkProps {
        variant?: import("@mantine/core").NavLinkVariant | SurrealVariant;
    }
    interface PaperProps {
        variant?: SurrealVariant | "glass" | "filled";
    }
    interface ScrollAreaProps {
        variant?: SurrealVariant;
    }
    interface TooltipProps {
        variant?: SurrealVariant;
    }
    interface PopoverDropdownProps {
        variant?: SurrealVariant | "transparent";
    }
    interface HoverCardDropdownProps {
        variant?: SurrealVariant | "transparent";
    }
    interface MenuDropdownProps {
        variant?: SurrealVariant;
    }
    interface LoaderProps {
        variant?: SurrealVariant;
    }
    interface ModalProps {
        variant?: SurrealVariant | "glass";
    }
    interface OverlayProps {
        variant?: SurrealVariant;
    }
    interface SkeletonProps {
        variant?: SurrealVariant;
    }
    interface SegmentedControlProps {
        variant?: SurrealVariant;
    }
    interface KbdProps {
        variant?: SurrealVariant;
    }
    interface SwitchProps {
        variant?: SurrealVariant | "gradient";
    }
    interface TitleProps {
        variant?: "gradient" | "surreal-gradient";
    }
    interface PaginationProps {
        variant?: SurrealVariant;
    }
    interface TabsProps {
        variant?: "default" | "outline" | "pills" | "gradient";
    }
    interface TableProps {
        variant?: SurrealVariant;
    }
    interface NotificationProps {
        variant?: SurrealVariant | "spaced";
    }
}

declare module "@mantine/core" {
    type ExtendedCustomColors = "obsidian" | "slate" | import("@mantine/core").DefaultMantineColor;
    interface MantineThemeColorsOverride {
        colors: Record<ExtendedCustomColors, import("@mantine/core").MantineColorsTuple>;
    }
}

declare module "@mantine/core" {
    type ExtendedCustomSizes = import("@mantine/core").DefaultMantineSize | "2xl" | "3xl";
    interface MantineThemeSizesOverride {
        spacing: Record<ExtendedCustomSizes, string>;
    }
}
