mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-26 02:10:59 +00:00
[web] ErrorView
This commit is contained in:
parent
2b7923b4f4
commit
e400e9f513
File diff suppressed because one or more lines are too long
@ -2,7 +2,7 @@ import React, { Component } from 'react'
|
||||
import _ from 'lodash'
|
||||
|
||||
import Nav from './FlowView/Nav'
|
||||
import { Request, Response, Error } from './FlowView/Messages'
|
||||
import { Request, Response, ErrorView as Error } from './FlowView/Messages'
|
||||
import Details from './FlowView/Details'
|
||||
import Prompt from './Prompt'
|
||||
|
||||
|
@ -152,3 +152,20 @@ export class Response extends Component {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ErrorView.propTypes = {
|
||||
flow: PropTypes.object.isRequired,
|
||||
}
|
||||
|
||||
export function ErrorView({ flow }) {
|
||||
return (
|
||||
<section>
|
||||
<div className="alert alert-warning">
|
||||
{flow.error.msg}
|
||||
<div>
|
||||
<small>{formatTimeStamp(flow.error.timestamp)}</small>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user