/**
 * @param {CreateRenderer} createRenderer
 */
export function createPlugin(
  createRenderer: CreateRenderer
): (
  this: import('unified').Processor<void, import('hast').Root, void, void>,
  options?: void | Options | undefined
) =>
  | void
  | import('unified').Transformer<import('hast').Root, import('hast').Root>
export type Root = import('hast').Root
export type Element = import('hast').Element
/**
 * Markers to use for math.
 * See: <http://docs.mathjax.org/en/latest/options/input/tex.html#the-configuration-block>
 */
export type MathNotation = [string, string]
/**
 * <http://docs.mathjax.org/en/latest/options/output/svg.html#the-configuration-block>
 */
export type OutputSvgOptions = {
  scale?: number | undefined
  minScale?: number | undefined
  mtextInheritFont?: boolean | undefined
  merrorInheritFont?: boolean | undefined
  mathmlSpacing?: boolean | undefined
  skipAttributes?: Record<string, boolean> | undefined
  exFactor?: number | undefined
  displayAlign?: 'left' | 'center' | 'right' | undefined
  displayIndent?: string | undefined
  fontCache?: 'local' | 'global' | undefined
  localID?: string | null | undefined
  internalSpeechTitles?: boolean | undefined
  titleID?: number | undefined
}
/**
 * <http://docs.mathjax.org/en/latest/options/output/chtml.html#the-configuration-block>
 */
export type OutputCHtmlOptions = {
  scale?: number | undefined
  minScale?: number | undefined
  matchFontHeight?: boolean | undefined
  mtextInheritFont?: boolean | undefined
  merrorInheritFont?: boolean | undefined
  mathmlSpacing?: boolean | undefined
  skipAttributes?: Record<string, boolean> | undefined
  exFactor?: number | undefined
  displayAlign?: 'left' | 'center' | 'right' | undefined
  displayIndent?: string | undefined
  fontURL: string
  adaptiveCSS?: boolean | undefined
}
/**
 * <http://docs.mathjax.org/en/latest/options/input/tex.html#the-configuration-block>
 */
export type InputTexOptions = {
  packages?: string[] | undefined
  inlineMath?: MathNotation[] | undefined
  displayMath?: MathNotation[] | undefined
  processEscapes?: boolean | undefined
  processEnvironments?: boolean | undefined
  processRefs?: boolean | undefined
  digits?: RegExp | undefined
  tags?: 'none' | 'ams' | 'all' | undefined
  tagSide?: 'left' | 'right' | undefined
  tagIndent?: string | undefined
  useLabelIds?: boolean | undefined
  multlineWidth?: string | undefined
  maxMacros?: number | undefined
  maxBuffer?: number | undefined
  baseURL?: string | undefined
  formatError?: ((jax: any, error: any) => string) | undefined
}
/**
 * Configuration.
 */
export type Options = {
  /**
   * Configuration for the input TeX.
   */
  tex?: InputTexOptions | undefined
  /**
   * Configuration for the output (when CHTML).
   */
  chtml?: OutputCHtmlOptions | undefined
  /**
   * Configuration for the output (when SVG).
   */
  svg?: OutputSvgOptions | undefined
}
export type Renderer = {
  render: (
    node: Element,
    options: {
      display: boolean
    }
  ) => void
  styleSheet?: (() => Element) | undefined
}
export type CreateRenderer = (options: Options) => Renderer
