mathpix-markdown-it
Version:
Mathpix-markdown-it is an open source implementation of the mathpix-markdown spec written in Typescript. It relies on the following open source libraries: MathJax v3 (to render math with SVGs), markdown-it (for standard Markdown parsing)
28 lines (27 loc) • 1.07 kB
TypeScript
export type TParselines = {
cLines: Array<Array<string>>;
cSpaces: Array<Array<string>>;
sLines: Array<string>;
};
export declare const getContent: (content: string, onlyOne?: boolean, skipTrim?: boolean) => string;
export declare const generateUniqueId: (onlyUuid?: boolean) => string;
export declare const getColumnLines: (str: string, numCol?: number) => Array<string>;
export declare const getColumnAlign: (align: string) => string[] | [
];
export type TAlignData = {
cAlign: Array<string>;
vAlign: Array<string>;
cWidth: Array<string>;
};
export declare const getVerticallyColumnAlign: (align: string, numCol: number) => TAlignData;
export declare const getParams: (str: string, i: number) => {
align: string;
index: number;
};
export type TDecimal = {
l: number;
r: number;
};
export declare const getDecimal: (cAlign: Array<string>, cellsAll: Array<string>) => Array<TDecimal>;
export declare const getCellsAll: (rows: string[]) => string[];
export declare const getRowLines: (rows: string[], numCol: number) => TParselines;