/** @jsx React.DOM */ var TLSColumn = React.createClass({ statics: { renderTitle: function(){ return ; } }, render: function(){ var flow = this.props.flow; var ssl = (flow.request.scheme == "https"); var classes = React.addons.classSet({ "col-tls": true, "col-tls-https": ssl, "col-tls-http": !ssl }); return ; } }); var IconColumn = React.createClass({ statics: { renderTitle: function(){ return ; } }, render: function(){ var flow = this.props.flow; return
; } }); var PathColumn = React.createClass({ statics: { renderTitle: function(){ return Path; } }, render: function(){ var flow = this.props.flow; return {flow.request.scheme + "://" + flow.request.host + flow.request.path}; } }); var MethodColumn = React.createClass({ statics: { renderTitle: function(){ return Method; } }, render: function(){ var flow = this.props.flow; return {flow.request.method}; } }); var StatusColumn = React.createClass({ statics: { renderTitle: function(){ return Status; } }, render: function(){ var flow = this.props.flow; var status; if(flow.response){ status = flow.response.code; } else { status = null; } return {status}; } }); var SizeColumn = React.createClass({ statics: { renderTitle: function(){ return Size; } }, render: function(){ var flow = this.props.flow; var size = formatSize( flow.request.contentLength + (flow.response.contentLength || 0)); return {size}; } }); var TimeColumn = React.createClass({ statics: { renderTitle: function(){ return Time; } }, render: function(){ var flow = this.props.flow; var time; if(flow.response){ time = Math.round(1000 * (flow.response.timestamp_end - flow.request.timestamp_start))+"ms"; } else { time = "..."; } return {time}; } }); var all_columns = [ TLSColumn, IconColumn, PathColumn, MethodColumn, StatusColumn, SizeColumn, TimeColumn];