We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fd4ab00 commit 4b5ba3cCopy full SHA for 4b5ba3c
1 file changed
packages/codemirror/src/Editor.ts
@@ -124,6 +124,16 @@ export class Editor extends HTMLWidget {
124
return this;
125
}
126
127
+ addLineClass(options: { lineNum: number, where?: "text" | "background" | "gutter", cssClass: string }): this {
128
+ this._codemirror.addLineClass(this._codemirror.getLineHandle(options.lineNum), options.where ?? "background", options.cssClass);
129
+ return this;
130
+ }
131
+
132
+ removeLineClass(options: { lineNum: number, where?: "text" | "background" | "gutter", cssClass: string }): this {
133
+ this._codemirror.removeLineClass(this._codemirror.getLineHandle(options.lineNum), options.where ?? "background", options.cssClass);
134
135
136
137
removeAllHighlight(): this {
138
for (const marked of this._markedText) {
139
marked.clear();
0 commit comments