import type { InkThemeAdapter } from "../theme-adapter.js";
/**
 * The shape {@link formatToken} (and the tool-body highlighter) consume. It is a
 * deliberately small surface: ask whether a language is known, then hand back a
 * chalk-ANSI rendering of the code. Keeping it behind an interface means the
 * markdown formatter never imports highlight.js directly and a caller can pass
 * `null` to disable highlighting entirely.
 */
export interface CliHighlight {
    /** Whether highlight.js has a grammar registered for `language`. */
    supportsLanguage: (language: string) => boolean;
    /** Render `code` as a chalk-ANSI string, colouring scopes via the theme. */
    highlight: (code: string, options: {
        language: string;
    }) => string;
}
/**
 * Build a {@link CliHighlight} bound to a theme. The returned object paints each
 * highlight.js scope via the theme's syntax roles ({@link ThemeRole}); unknown
 * languages and any internal failure fall back to the raw code, never throwing.
 */
export declare function createHighlighter(theme: InkThemeAdapter): CliHighlight;
/**
 * Highlight `code` keyed on a file path's extension. Used by the read/write/edit
 * tool bodies, which know the file but not a fenced ```lang tag. Resolves the
 * extension to a highlight.js language, falling back to the plain code when the
 * extension is unknown or unsupported.
 */
export declare function highlightByPath(code: string, filePath: string, theme: InkThemeAdapter): string;
/** Resolve a file path to a highlight.js language id, or null when unknown. */
export declare function languageFromPath(filePath: string): string | null;
