@@ -5,7 +5,9 @@ import type {ReactNode} from 'react';
55import type { MarkupString } from '../common' ;
66import type { EscapeConfig , Extension } from '../core' ;
77import type { Logger2 } from '../logger' ;
8- import type { CreateCodemirrorParams , LineRange , YfmLangOptions } from '../markup' ;
8+ import type { CreateCodemirrorParams } from '../markup/codemirror/create' ;
9+ import type { MarkupLineNumbersConfig } from '../markup/codemirror/line-highlight/types' ;
10+ import type { YfmLangOptions } from '../markup/codemirror/yfm' ;
911import type { FileUploadHandler } from '../utils' ;
1012import type { DirectiveSyntaxContext , DirectiveSyntaxOption } from '../utils/directive' ;
1113import type { ParseInsertedUrlAsImage } from '../utils/upload' ;
@@ -117,19 +119,7 @@ export type MarkdownEditorExperimentalOptions = {
117119 */
118120 preserveMarkupFormatting ?: boolean ;
119121} ;
120-
121- export interface MarkupLineNumbersConfig {
122- /** Show line numbers in the gutter. Default: false */
123- enabled ?: boolean ;
124- /** Enable line highlighting (clickable line numbers + highlight decoration). Default: false */
125- highlightLines ?: boolean ;
126- /** Initial line range to highlight on mount (0-based, inclusive) */
127- initialSelectedLines ?: LineRange ;
128- /** Called when user clicks on a line number (only when highlightLines is true). 0-based line number. */
129- onLineClick ?: ( line : number ) => void ;
130- /** 0-based line number to scroll to on mount in markup mode */
131- scrollToLine ?: number ;
132- }
122+ export type { MarkupLineNumbersConfig } ;
133123
134124export type MarkdownEditorMarkupConfig = {
135125 /**
0 commit comments