import { type ComponentProps, type ReactNode } from 'react';
import type { GDSComponentProps } from '@graphprotocol/gds-css';
import { type Stringifiable } from '../utils/index.ts';
import { type AddonValue } from './base/Addon.tsx';
import { CodeBlockMeta } from './CodeBlock.meta.ts';
import { type TabSetTabProps } from './TabSet.tsx';
export declare const LANGUAGES: readonly ["text", ...("html" | "ruby" | "go" | "bash" | "css" | "gql" | "graphql" | "java" | "javascript" | "js" | "json" | "jsx" | "markdown" | "md" | "mermaid" | "php" | "py" | "python" | "rs" | "rust" | "sh" | "shell" | "shellscript" | "solidity" | "sql" | "swift" | "toml" | "ts" | "tsx" | "typescript" | "vue" | "yaml" | "yml" | "zsh")[]];
type Language = (typeof LANGUAGES)[number];
interface SharedProps extends GDSComponentProps<typeof CodeBlockMeta> {
    highlight?: string | string[] | undefined;
    secret?: string | string[] | undefined;
    /** @default true */
    masked?: boolean | undefined;
    onMaskedChange?: ((masked: boolean) => void) | undefined;
    /** @default true */
    copy?: boolean | string | undefined;
    onCopy?: ((value: string) => void) | undefined;
    /**
     * Whether to style diff-formatted lines. When this is `true`, each line of the passed code is
     * expected to be prefixed with a diff marker:
     *
     * - `+` for added lines.
     * - `-` for deleted lines.
     * - ` ` (space) for unchanged lines.
     *
     * Note that the diff markers and deleted lines are excluded from the code when copied via the
     * copy button, but are included when selected manually.
     *
     * @default false
     */
    diff?: boolean | undefined;
}
export interface CodeBlockProps extends Omit<ComponentProps<'div'>, 'onCopy'>, SharedProps {
    /** @default 'text' */
    language?: Language | undefined;
    /** Defaults to an icon that matches the `language`. */
    icon?: AddonValue | undefined;
    label?: ReactNode | undefined;
    children: Stringifiable;
}
export declare function CodeBlockRoot({ language, icon: passedIcon, label, highlight: passedHighlight, secret: passedSecret, masked: controlledMasked, onMaskedChange, copy: passedCopy, onCopy: passedOnCopy, wrap: passedWrap, diff: passedDiff, lineNumbers: passedLineNumbers, rows: passedRows, className, style, children, ...props }: CodeBlockProps): import("react/jsx-runtime").JSX.Element | null;
export declare namespace CodeBlockRoot {
    var displayName: string;
}
type Tab<T extends string = string> = T | {
    value: T;
    label?: TabSetTabProps['children'];
    addonBefore?: TabSetTabProps['addonBefore'];
    addonAfter?: TabSetTabProps['addonAfter'];
    disabled?: TabSetTabProps['disabled'];
};
type TabValue<T extends Tab> = T extends {
    value: infer V;
} ? V : T;
export interface CodeBlockTabsProps<Tabs extends readonly Tab[] = readonly Tab[], T extends TabValue<Tabs[number]> = TabValue<Tabs[number]>> extends Omit<ComponentProps<'div'>, 'onChange' | 'onCopy'>, SharedProps {
    tabs: Tabs & readonly Tab[];
    value?: T | undefined;
    defaultValue?: T | undefined;
    onChange?: ((value: T) => void) | undefined;
}
export declare function CodeBlockTabs<const Tabs extends readonly Tab[], T extends TabValue<Tabs[number]>>({ ref: passedRef, tabs: passedTabs, value, defaultValue, onChange, highlight, secret, masked: controlledMasked, onMaskedChange, copy, onCopy, wrap, diff, lineNumbers, rows, className, children, ...props }: CodeBlockTabsProps<Tabs, T>): import("react/jsx-runtime").JSX.Element;
export declare namespace CodeBlockTabs {
    var displayName: string;
}
export {};
//# sourceMappingURL=CodeBlock.parts.d.ts.map