Fixed an issue in the query tool where using multiple cursors to copy text resulted in only the first line being copied. #8691

This commit is contained in:
Pravesh Sharma
2025-05-30 14:45:48 +05:30
committed by GitHub
parent 63f2c7fe00
commit 3286b4e32f
3 changed files with 9 additions and 6 deletions
@@ -110,7 +110,7 @@ export default function CodeMirror({className, currEditor, showCopyBtn=false, cu
if (!onTextSelect) return;
const handleSelection = () => {
const selectedText = window.getSelection().toString();
const selectedText = editor.current?.getSelection();
if (selectedText) {
onTextSelect(selectedText);
} else {