@ym-han/monaco-error-lens
Version:
Error Lens for Monaco Editor, adapted from the VSCode Error Lens extension: makes diagnostics more visible with inline messages, line highlighting, and gutter icons. WARNING: Very experimental; use with caution.
41 lines • 1.13 kB
TypeScript
import { ErrorLensConfig, MonacoEditor, MonacoMarkerData } from './types';
/**
* Decoration manager for Monaco Error Lens
* Handles the creation and management of Monaco editor decorations
*/
export declare class DecorationManager {
private editor;
private config;
private decorations;
private lastDecorationCount;
constructor(editor: MonacoEditor, config: ErrorLensConfig);
/**
* Update all decorations based on current markers
*/
updateDecorations(markers: MonacoMarkerData[]): void;
/**
* Clear all decorations
*/
clearDecorations(): void;
/**
* Get the current decoration count
*/
getDecorationCount(): number;
/**
* Create Monaco decorations from markers
*/
private createDecorations;
/**
* Create a decoration for an entire line
*/
private createLineDecoration;
/**
* Group markers by line number with sorted markers per line
*/
private groupMarkersByLine;
/**
* Update configuration
*/
updateConfig(config: ErrorLensConfig): void;
}
//# sourceMappingURL=decorations.d.ts.map