/** Matches app-frontend `useCopyToClipboard` reset window. */ export declare const COPY_FEEDBACK_MS = 1500; /** Idle / copied labels — same strings as app-frontend `Code` copy button. */ export declare function copyButtonContent(isCopied: boolean, idleLabel?: string): { label: string; state: 'idle' | 'copied'; }; /** Expressive Code joins multi-line `data-code` with U+007F. */ export declare function ecDataCodeToText(dataCode: string): string; export type TryCopyTextDeps = { writeText?: (text: string) => Promise; }; /** * Copy text like app-frontend `useCopyToClipboard`: succeed → true; failure → false. * Inject `writeText` in tests; browser path uses `navigator.clipboard.writeText`. */ export declare function tryCopyText(text: string, deps?: TryCopyTextDeps): Promise; export declare function fileKindFromName(name: string): string | null; /** Fence language → tab label when the block has no `title="…"`. */ export declare function defaultTitleFromLang(lang: string): string; /** True when the title looks like a path/filename (not a bare language id). */ export declare function isFilePathTitle(title: string): boolean; /** Language id / filename → short chip (TS, JS, …). */ export declare function kindFromTitle(title: string): string | null; export declare function paintCopyButton(button: HTMLButtonElement, isCopied: boolean): void; /** Green “Copied!” then restore the idle label after COPY_FEEDBACK_MS. */ export declare function showCopySuccess(button: HTMLButtonElement): void; /** Idle chrome used by docs EC and explorer MCP / Try it copy controls. */ export declare function copyButtonMarkup(attrs?: { copyTarget?: string; copyValue?: string; id?: string; label?: string; }): string; export declare function enhanceCodeBlockTitles(root?: ParentNode): void;