Display state in color
This commit is contained in:
@@ -49,7 +49,12 @@ export function WSDebugRoute(): React.ReactElement {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<MatrixGWRouteContainer label={"WebSocket Debug"}>
|
<MatrixGWRouteContainer label={"WebSocket Debug"}>
|
||||||
State: {state}
|
<div>
|
||||||
|
State:{" "}
|
||||||
|
<span style={{ color: state == State.Connected ? "green" : "red" }}>
|
||||||
|
{state}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
{messages.map((msg, id) => (
|
{messages.map((msg, id) => (
|
||||||
<div style={{ margin: "10px", backgroundColor: "black" }}>
|
<div style={{ margin: "10px", backgroundColor: "black" }}>
|
||||||
<JsonView
|
<JsonView
|
||||||
|
|||||||
Reference in New Issue
Block a user