import * as Immutable from "immutable"; export declare type ExecutionCount = number | null; export declare type PrimitiveImmutable = string | number | boolean | null; export declare type JSONType = PrimitiveImmutable | JSONObject | JSONArray; export interface JSONObject { [key: string]: JSONType; } export declare type JSONArray = Array; export declare type CellId = string; export declare function createCellId(): CellId; export declare type MultiLineString = string | string[]; /** * A mime-type keyed dictionary of data. * See https://nbformat.readthedocs.io/en/latest/format_description.html#cell-attachments for docs * and https://github.com/jupyter/nbformat/blob/b23aad6e29d8c3909a1b04a7edc9ae541096dc7b/nbformat/v4/nbformat.v4.schema.json#L442 * for the schema */ export interface MimeBundle { [mime_type: string]: TPayload; } export declare type ImmutableJSONType = PrimitiveImmutable | ImmutableJSONMap | ImmutableJSONList; export declare type ImmutableJSONMap = Immutable.Map; export declare type ImmutableJSONList = Immutable.List; /** * Media Bundles as they exist on disk from the notebook format * See https://nbformat.readthedocs.io/en/latest/format_description.html#display-data for docs * and https://github.com/jupyter/nbformat/blob/master/nbformat/v4/nbformat.v4.schema.json for the schema */ export interface OnDiskMediaBundle { "text/plain"?: MultiLineString; "text/html"?: MultiLineString; "text/latex"?: MultiLineString; "text/markdown"?: MultiLineString; "application/javascript"?: MultiLineString; "image/png"?: MultiLineString; "image/jpeg"?: MultiLineString; "image/gif"?: MultiLineString; "image/svg+xml"?: MultiLineString; "application/json"?: string | string[] | {}; "application/vdom.v1+json"?: {}; "application/vnd.dataresource+json"?: {}; "text/vnd.plotly.v1+html"?: MultiLineString | {}; "application/vnd.plotly.v1+json"?: {}; "application/geo+json"?: {}; "application/x-nteract-model-debug+json"?: {}; "application/vnd.vega.v2+json"?: {}; "application/vnd.vega.v3+json"?: {}; "application/vnd.vega.v4+json"?: {}; "application/vnd.vega.v5+json"?: {}; "application/vnd.vegalite.v1+json"?: {}; "application/vnd.vegalite.v2+json"?: {}; "application/vnd.vegalite.v3+json"?: {}; "application/vnd.vegalite.v4+json"?: {}; [key: string]: string | string[] | {} | undefined; } export interface MediaBundle { "text/plain"?: string; "text/html"?: string; "text/latex"?: string; "text/markdown"?: string; "application/javascript"?: string; "image/png"?: string; "image/jpeg"?: string; "image/gif"?: string; "image/svg+xml"?: string; "application/json"?: { [key: string]: any; }; "application/vdom.v1+json"?: { [key: string]: any; }; "application/vnd.dataresource+json"?: { [key: string]: any; }; "text/vnd.plotly.v1+html"?: string | { [key: string]: any; }; "application/vnd.plotly.v1+json"?: { [key: string]: any; }; "application/geo+json"?: { [key: string]: any; }; "application/x-nteract-model-debug+json"?: { [key: string]: any; }; "application/vnd.vega.v2+json"?: { [key: string]: any; }; "application/vnd.vega.v3+json"?: { [key: string]: any; }; "application/vnd.vega.v4+json"?: { [key: string]: any; }; "application/vnd.vega.v5+json"?: { [key: string]: any; }; "application/vnd.vegalite.v1+json"?: { [key: string]: any; }; "application/vnd.vegalite.v2+json"?: { [key: string]: any; }; "application/vnd.vegalite.v3+json"?: { [key: string]: any; }; "application/vnd.vegalite.v4+json"?: { [key: string]: any; }; [key: string]: string | string[] | {} | undefined; } /** * Normalize line endings to \n line feed to be consistent across OS platforms. */ export declare function normalizeLineEndings(text?: string): string | undefined; /** * Turn nbformat multiline strings (arrays of strings for simplifying diffs) * into strings */ export declare function demultiline(s: string | string[]): string; /** * Split string into a list of strings delimited by newlines; useful for on-disk * git comparisons; and is the expectation for jupyter notebooks on disk */ export declare function remultiline(s: string | string[]): string[]; declare type DeepReadonly = { readonly [P in keyof T]: DeepReadonly; }; export declare function deepFreeze(object: T): DeepReadonly; export declare function createFrozenMediaBundle(mediaBundle: OnDiskMediaBundle): Readonly; export declare function createOnDiskMediaBundle(mediaBundle: Readonly): OnDiskMediaBundle; export {};