Add scrolling into view to insertAtCursor syscall

pull/1232/head
Zef Hemel 2025-02-06 08:36:56 +01:00
parent 9ccfe13818
commit 12d5f0beba
1 changed files with 5 additions and 2 deletions

View File

@ -272,8 +272,11 @@ export function moveCursorToLine(
* Insert text at the cursor position in the editor
* @param text the text to insert
*/
export function insertAtCursor(text: string): Promise<void> {
return syscall("editor.insertAtCursor", text);
export function insertAtCursor(
text: string,
scrollIntoView = false,
): Promise<void> {
return syscall("editor.insertAtCursor", text, scrollIntoView);
}
/**