mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-08-01 20:52:27 +08:00
36 lines
979 B
TypeScript
36 lines
979 B
TypeScript
import type Math from './math.js';
|
|
import MathCommand from './mathcommand.js';
|
|
import MathEditing from './mathediting.js';
|
|
import MathUI from './mathui.js';
|
|
import { KatexOptions } from './typings-external.js';
|
|
|
|
declare module 'ckeditor5' {
|
|
interface PluginsMap {
|
|
[ Math.pluginName ]: Math;
|
|
[ MathEditing.pluginName ]: MathEditing;
|
|
[ MathUI.pluginName ]: MathUI;
|
|
}
|
|
|
|
interface CommandsMap {
|
|
math: MathCommand;
|
|
}
|
|
|
|
interface EditorConfig {
|
|
math?: {
|
|
engine?:
|
|
| 'mathjax'
|
|
| 'katex'
|
|
| ( ( equation: string, element: HTMLElement, display: boolean ) => void )
|
|
| undefined;
|
|
lazyLoad?: undefined | ( () => Promise<void> );
|
|
outputType?: 'script' | 'span' | undefined;
|
|
className?: string | undefined;
|
|
forceOutputType?: boolean | undefined;
|
|
enablePreview?: boolean | undefined;
|
|
previewClassName?: Array<string> | undefined;
|
|
popupClassName?: Array<string> | undefined;
|
|
katexRenderOptions?: Partial<KatexOptions> | undefined;
|
|
};
|
|
}
|
|
}
|