aboutsummaryrefslogtreecommitdiffstats
path: root/libmproxy/web/static/js
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2014-09-15 18:39:25 +0200
committerMaximilian Hils <git@maximilianhils.com>2014-09-15 18:39:25 +0200
commit1d9b1f79a11feb57043be1d9d656f4c1638d3357 (patch)
treeb1339c77d8761f7014424d7f73fb92c6fd600126 /libmproxy/web/static/js
parentcbf18320cdbd05197f232da69b3c9a5391735156 (diff)
downloadmitmproxy-1d9b1f79a11feb57043be1d9d656f4c1638d3357.tar.gz
mitmproxy-1d9b1f79a11feb57043be1d9d656f4c1638d3357.tar.bz2
mitmproxy-1d9b1f79a11feb57043be1d9d656f4c1638d3357.zip
web: eventlog ui
Diffstat (limited to 'libmproxy/web/static/js')
-rw-r--r--libmproxy/web/static/js/app.js13
1 files changed, 9 insertions, 4 deletions
diff --git a/libmproxy/web/static/js/app.js b/libmproxy/web/static/js/app.js
index 7873046a..72bb5ff8 100644
--- a/libmproxy/web/static/js/app.js
+++ b/libmproxy/web/static/js/app.js
@@ -232,14 +232,13 @@ var MainMenu = React.createClass({displayName: 'MainMenu',
mixins: [SettingsMixin],
handleSettingsChange:function() {
SettingsActions.update({
- showEventLog: this.refs.showEventLogInput.getDOMNode().checked
+ showEventLog: !this.state.settings.showEventLog
});
},
render:function(){
return React.DOM.div(null,
- React.DOM.label(null,
- React.DOM.input({type: "checkbox", ref: "showEventLogInput", checked: this.state.settings.showEventLog, onChange: this.handleSettingsChange}),
- "Show Event Log"
+ React.DOM.button({className: "btn " + (this.state.settings.showEventLog ? "btn-primary" : "btn-default"), onClick: this.handleSettingsChange},
+ React.DOM.i({className: "fa fa-database"}), " Display Event Log"
)
);
}
@@ -355,10 +354,16 @@ var TrafficTable = React.createClass({displayName: 'TrafficTable',
/** @jsx React.DOM */
var EventLog = React.createClass({displayName: 'EventLog',
+ close:function(){
+ SettingsActions.update({
+ showEventLog: false
+ });
+ },
render:function(){
return (
React.DOM.div({className: "eventlog"},
React.DOM.pre(null,
+ React.DOM.i({className: "fa fa-close close-button", onClick: this.close}),
"much log."
)
)