Skip to content

Commit 5664844

Browse files
authored
CodeQL model editor: Don't highlight row when clicking inside text box (#3264)
1 parent 9644e5d commit 5664844

1 file changed

Lines changed: 12 additions & 1 deletion

File tree

extensions/ql-vscode/src/view/model-editor/ModelTypeTextbox.tsx

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ type Props = {
1515
"aria-label"?: string;
1616
};
1717

18+
const stopClickPropagation = (e: React.MouseEvent) => {
19+
e.stopPropagation();
20+
};
21+
1822
export const ModelTypeTextbox = ({
1923
modeledMethod,
2024
typeInfo,
@@ -48,5 +52,12 @@ export const ModelTypeTextbox = ({
4852
500,
4953
);
5054

51-
return <VSCodeTextField value={value} onInput={handleChange} {...props} />;
55+
return (
56+
<VSCodeTextField
57+
value={value}
58+
onInput={handleChange}
59+
onClick={stopClickPropagation}
60+
{...props}
61+
/>
62+
);
5263
};

0 commit comments

Comments
 (0)