mirror of
https://github.com/pomerium/pomerium.git
synced 2025-07-16 16:26:16 +02:00
adds success colors for statuses in the 200 range (#4314)
This commit is contained in:
parent
2f4005cc09
commit
f54b1a7d09
1 changed files with 5 additions and 4 deletions
|
@ -20,8 +20,7 @@ type PolicyEvaluationTraceDetailsProps = {
|
|||
trace: PolicyEvaluationTrace;
|
||||
} & ListItemProps;
|
||||
const PolicyEvaluationTraceDetails: FC<PolicyEvaluationTraceDetailsProps> = ({
|
||||
trace,
|
||||
...props
|
||||
trace
|
||||
}) => {
|
||||
return (
|
||||
<TableRow>
|
||||
|
@ -52,14 +51,16 @@ export type ErrorPageProps = {
|
|||
export const ErrorPage: FC<ErrorPageProps> = ({ data }) => {
|
||||
const traces =
|
||||
data?.policyEvaluationTraces?.filter((trace) => !!trace.id) || [];
|
||||
const status = data?.status || 500;
|
||||
|
||||
return (
|
||||
<Container maxWidth={false}>
|
||||
<Paper sx={{ overflow: "hidden" }}>
|
||||
<Stack>
|
||||
<Box sx={{ padding: "16px" }}>
|
||||
<Alert severity="error">
|
||||
<Alert severity={status < 200 || status >= 300 ? "error" : "success"}>
|
||||
<AlertTitle>
|
||||
{data?.status || 500}{" "}
|
||||
{status}{" "}
|
||||
{data?.statusText || "Internal Server Error"}
|
||||
</AlertTitle>
|
||||
{data?.description ? (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue