aboutsummaryrefslogtreecommitdiffstats
path: root/libmproxy/web/static/app.js
diff options
context:
space:
mode:
authorMaximilian Hils <git@maximilianhils.com>2015-03-22 15:29:55 +0100
committerMaximilian Hils <git@maximilianhils.com>2015-03-22 15:29:55 +0100
commit2acd77dea025b489d5d0ca19fc1c84901ac335d4 (patch)
tree9f56e707720c1ca684a128c46c7537e7178846e6 /libmproxy/web/static/app.js
parent39a8ac7e2a405b84edc55289cb8bdfb2ac1948fa (diff)
downloadmitmproxy-2acd77dea025b489d5d0ca19fc1c84901ac335d4.tar.gz
mitmproxy-2acd77dea025b489d5d0ca19fc1c84901ac335d4.tar.bz2
mitmproxy-2acd77dea025b489d5d0ca19fc1c84901ac335d4.zip
web: add content download
Diffstat (limited to 'libmproxy/web/static/app.js')
-rw-r--r--libmproxy/web/static/app.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/libmproxy/web/static/app.js b/libmproxy/web/static/app.js
index 84681403..83bb99ab 100644
--- a/libmproxy/web/static/app.js
+++ b/libmproxy/web/static/app.js
@@ -1416,10 +1416,14 @@ var ContentView = React.createClass({displayName: "ContentView",
return React.createElement(TooLarge, React.__spread({}, this.props, {onClick: this.displayLarge}));
}
+ var downloadUrl = MessageUtils.getContentURL(this.props.flow, message);
+
return React.createElement("div", null,
React.createElement(this.state.View, React.__spread({}, this.props)),
- React.createElement("div", {className: "text-center"},
- React.createElement(ViewSelector, {selectView: this.selectView, active: this.state.View, message: message})
+ React.createElement("div", {className: "view-options text-center"},
+ React.createElement(ViewSelector, {selectView: this.selectView, active: this.state.View, message: message}),
+ " ",
+ React.createElement("a", {className: "btn btn-default btn-xs", href: downloadUrl}, React.createElement("i", {className: "fa fa-download"}))
)
);
}