Skip to content

Commit 01c2d12

Browse files
authored
Fixed an issue where selecting all in the Query Tool's Messages tab would select the entire page content. #8992
1 parent e5cf456 commit 01c2d12

File tree

1 file changed

+6
-3
lines changed
  • web/pgadmin/tools/sqleditor/static/js/components/sections

1 file changed

+6
-3
lines changed

web/pgadmin/tools/sqleditor/static/js/components/sections/Messages.jsx

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,19 @@ import React from 'react';
1111
import { QueryToolEventsContext } from '../QueryToolComponent';
1212
import { QUERY_TOOL_EVENTS } from '../QueryToolConstants';
1313

14-
const StyledDiv = styled('div')(({theme}) => ({
14+
const StyledTextarea = styled('textarea')(({theme}) => ({
1515
whiteSpace: 'pre-wrap',
1616
fontFamily: '"Source Code Pro", SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',
1717
padding: '5px 10px',
1818
overflow: 'auto',
1919
height: '100%',
20+
width: '100%',
2021
fontSize: '12px',
21-
userSelect: 'text',
2222
backgroundColor: theme.palette.background.default,
2323
color: theme.palette.text.primary,
24+
border: 'none',
25+
outline: 'none',
26+
resize: 'none',
2427
...theme.mixins.fontSourceCode,
2528
}));
2629

@@ -38,5 +41,5 @@ export function Messages() {
3841
});
3942
});
4043
}, []);
41-
return <StyledDiv tabIndex="0">{messageText}</StyledDiv>;
44+
return <StyledTextarea value={messageText} readOnly/>;
4245
}

0 commit comments

Comments
 (0)