aboutsummaryrefslogtreecommitdiffstats
path: root/web/src
diff options
context:
space:
mode:
authorJason <jason.daurus@gmail.com>2016-06-09 18:03:40 +0800
committerJason <jason.daurus@gmail.com>2016-06-09 18:03:40 +0800
commite24bf8d73f744319eeed99e7cae0b7f2c3947b8f (patch)
treeab5579d113fc27cd8b28ca20e2fc410cfb9355a4 /web/src
parentf306cfa8b6445dd04c5f7188d1a5022bcb747a62 (diff)
downloadmitmproxy-e24bf8d73f744319eeed99e7cae0b7f2c3947b8f.tar.gz
mitmproxy-e24bf8d73f744319eeed99e7cae0b7f2c3947b8f.tar.bz2
mitmproxy-e24bf8d73f744319eeed99e7cae0b7f2c3947b8f.zip
[web] fix shortcut for header fields
Diffstat (limited to 'web/src')
-rw-r--r--web/src/js/components/ProxyApp.jsx2
-rw-r--r--web/src/js/components/header.js1
2 files changed, 2 insertions, 1 deletions
diff --git a/web/src/js/components/ProxyApp.jsx b/web/src/js/components/ProxyApp.jsx
index 9f497a7d..465cf272 100644
--- a/web/src/js/components/ProxyApp.jsx
+++ b/web/src/js/components/ProxyApp.jsx
@@ -134,7 +134,7 @@ class ProxyAppMain extends Component {
if (name) {
const headerComponent = this.refs.header
- headerComponent.setState({active: MainMenu}, function () {
+ headerComponent.setState({ active: MainMenu }, () => {
headerComponent.refs.active.refs[name].select()
})
}
diff --git a/web/src/js/components/header.js b/web/src/js/components/header.js
index 4152e95c..afd295cf 100644
--- a/web/src/js/components/header.js
+++ b/web/src/js/components/header.js
@@ -442,6 +442,7 @@ export var Header = React.createClass({
</nav>
<div className="menu">
<this.state.active
+ ref="active"
settings={this.props.settings}
updateLocation={this.props.updateLocation}
query={this.props.query}