Fix General Info Model

This commit is contained in:
DomySh
2022-06-12 19:03:56 +02:00
parent d08a82e311
commit a568fbe5eb
3 changed files with 4 additions and 5 deletions

View File

@@ -12,7 +12,7 @@ import AddNewService from '../AddNewService';
function Header() {
const [generalStats, setGeneralStats] = useState<GeneralStats>({closed:0, regex:0, services:0});
const [generalStats, setGeneralStats] = useState<GeneralStats>({closed:0, regexes:0, services:0});
const location = useLocation()
const navigator = useNavigate()
@@ -41,7 +41,7 @@ function Header() {
<div className="flex-spacer" />
<Badge color="green" size="lg" variant="filled">Services: {generalStats.services}</Badge>
<Badge style={{marginLeft:"10px"}} size="lg" color="yellow" variant="filled">Filtered Connections: {generalStats.closed}</Badge>
<Badge style={{marginLeft:"10px"}} size="lg" color="violet" variant="filled">Regexes: {generalStats.regex}</Badge>
<Badge style={{marginLeft:"10px"}} size="lg" color="violet" variant="filled">Regexes: {generalStats.regexes}</Badge>
<div style={{marginLeft:"20px"}}></div>
{ location.pathname !== "/"?
<ActionIcon color="teal" style={{marginRight:"10px"}}

View File

@@ -6,7 +6,7 @@ export const notification_time = 2000;
export type GeneralStats = {
services:number,
closed:number,
regex:number
regexes:number
}
export type Service = {
@@ -24,7 +24,6 @@ export type ServiceAddForm = {
port:number
}
export type ServerResponse = {
status:string
}