You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
882 B
36 lines
882 B
import React from 'react';
|
|
import { basiliskConnection } from '../../../actions/actionCreators';
|
|
import Store from '../../../store';
|
|
import WalletsBasiliskConnectionRender from './walletsBasiliskConnection.render';
|
|
|
|
class WalletsBasiliskConnection extends React.Component {
|
|
constructor(props) {
|
|
super(props);
|
|
this.basiliskConnectionAction = this.basiliskConnectionAction.bind(this);
|
|
}
|
|
|
|
basiliskConnectionAction() {
|
|
Store.dispatch(basiliskConnection(false));
|
|
}
|
|
|
|
handleKeydown(e) {
|
|
if (e.key === 'Escape') {
|
|
this.basiliskConnectionAction();
|
|
}
|
|
}
|
|
|
|
isBasiliskConnection() {
|
|
return this.props &&
|
|
this.props.Dashboard.basiliskConnection;
|
|
}
|
|
|
|
render() {
|
|
if (this.isBasiliskConnection()) {
|
|
return WalletsBasiliskConnectionRender.call(this);
|
|
} else {
|
|
return null;
|
|
}
|
|
}
|
|
}
|
|
|
|
export default WalletsBasiliskConnection;
|
|
|