ng2-json-editor
Version:
Angular2 component for editing large json documents
20 lines (19 loc) • 771 B
TypeScript
export declare class KatexService {
private delimiters;
/**
*
* Receives text that can contain LaTeX formulas. The formulas will be
* identified using `this.delimiters` and rendered inside the passed
* HTMLElement
*
* NOTE: The HTMLElement is expected to have a single child and this
* will be replaced by the HTML with formatted LaTeX
*
* @param {string} text - text to be formatted with LaTeX
* @param {HTMLElement} el - the HTMLElement where the LaTeX should be rendered
*/
renderMathInText(text: string, el: HTMLElement): void;
private findEndOfMath(delimiter, text, startIndex);
private splitAtDelimiters(startData, leftDelim, rightDelim, display);
private splitWithDelimiters(text, delimiters);
}