export interface SaveElementOptions { /** Filename for the downloaded file, without the extension. */ filename?: string; /** File type of the saved document. Accepted values are "png", "jpg", and "svg". */ type?: "png" | "jpg" | "svg"; /** Function to be invoked after saving is complete. */ callback?: () => void; } export interface SaveElementRenderOptions { /** Background color for the rendered image. */ background?: string; /** Background color for the rendered image (alias). */ backgroundColor?: string; [key: string]: unknown; } /** Downloads an HTML Element as a bitmap PNG image. @param elem The DOM element or d3 selection to export. @param options Additional options to specify. @param options .filename = "download"] Filename for the downloaded file, without the extension. @param options .type = "png"] File type of the saved document. Accepted values are `"png"` and `"jpg"`. @param options .callback] Function to be invoked after saving is complete. @param renderOptions Custom options to be passed to the html-to-image function. */ export default function (elem: HTMLElement, options?: SaveElementOptions, renderOptions?: SaveElementRenderOptions): void;