mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Set focus to server log control in System Console when loading panel (#4912)
remove import
This commit is contained in:
committed by
Joram Wilander
parent
599869b3ca
commit
c96a36e9b3
@@ -24,12 +24,14 @@ export default class Logs extends React.Component {
|
||||
componentDidMount() {
|
||||
AdminStore.addLogChangeListener(this.onLogListenerChange);
|
||||
AsyncClient.getLogs();
|
||||
this.refs.logPanel.focus();
|
||||
}
|
||||
|
||||
componentDidUpdate() {
|
||||
// Scroll Down to get the latest logs
|
||||
var node = this.refs.logPanel;
|
||||
node.scrollTop = node.scrollHeight;
|
||||
node.focus();
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
@@ -100,6 +102,7 @@ export default class Logs extends React.Component {
|
||||
/>
|
||||
</button>
|
||||
<div
|
||||
tabIndex='-1'
|
||||
ref='logPanel'
|
||||
className='log__panel'
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user