mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-12 14:15:22 +03:00
Show number of items instead of dot
This commit is contained in:
parent
3e1861e2ce
commit
dfde663b49
@ -243,41 +243,78 @@ export default function EventView({
|
|||||||
} // don't allow the severity to be unselected
|
} // don't allow the severity to be unselected
|
||||||
>
|
>
|
||||||
<ToggleGroupItem
|
<ToggleGroupItem
|
||||||
className={`${severityToggle == "alert" ? "" : "text-muted-foreground"}`}
|
className={cn(severityToggle != "alert" && "text-muted-foreground")}
|
||||||
value="alert"
|
value="alert"
|
||||||
aria-label="Select alerts"
|
aria-label="Select alerts"
|
||||||
>
|
>
|
||||||
<MdCircle className="size-2 text-severity_alert md:mr-[10px]" />
|
{isDesktop ? (
|
||||||
<div className="hidden md:flex md:flex-row md:items-center">
|
<>
|
||||||
Alerts
|
<MdCircle className="size-2 text-severity_alert md:mr-[10px]" />
|
||||||
{reviewCounts.alert > -1 ? (
|
<div className="hidden md:flex md:flex-row md:items-center">
|
||||||
` ∙ ${reviewCounts.alert}`
|
Alerts
|
||||||
) : (
|
{reviewCounts.alert > -1 ? (
|
||||||
<ActivityIndicator className="ml-2 size-4" />
|
` ∙ ${reviewCounts.alert}`
|
||||||
)}
|
) : (
|
||||||
</div>
|
<ActivityIndicator className="ml-2 size-4" />
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
) : (
|
||||||
|
<div
|
||||||
|
className={cn(
|
||||||
|
"flex size-6 items-center justify-center rounded text-severity_alert",
|
||||||
|
severityToggle == "alert" ? "font-semibold" : "font-medium",
|
||||||
|
)}
|
||||||
|
>
|
||||||
|
{reviewCounts.alert > -1 ? (
|
||||||
|
reviewCounts.alert
|
||||||
|
) : (
|
||||||
|
<ActivityIndicator className="size-4" />
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</ToggleGroupItem>
|
</ToggleGroupItem>
|
||||||
<ToggleGroupItem
|
<ToggleGroupItem
|
||||||
className={`${severityToggle == "detection" ? "" : "text-muted-foreground"}`}
|
className={cn(
|
||||||
|
severityToggle != "detection" && "text-muted-foreground",
|
||||||
|
)}
|
||||||
value="detection"
|
value="detection"
|
||||||
aria-label="Select detections"
|
aria-label="Select detections"
|
||||||
>
|
>
|
||||||
<MdCircle className="size-2 text-severity_detection md:mr-[10px]" />
|
{isDesktop ? (
|
||||||
<div className="hidden md:flex md:flex-row md:items-center">
|
<>
|
||||||
Detections
|
<MdCircle className="size-2 text-severity_detection md:mr-[10px]" />
|
||||||
{reviewCounts.detection > -1 ? (
|
<div className="hidden md:flex md:flex-row md:items-center">
|
||||||
` ∙ ${reviewCounts.detection}`
|
Detections
|
||||||
) : (
|
{reviewCounts.detection > -1 ? (
|
||||||
<ActivityIndicator className="ml-2 size-4" />
|
` ∙ ${reviewCounts.detection}`
|
||||||
)}
|
) : (
|
||||||
</div>
|
<ActivityIndicator className="ml-2 size-4" />
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
) : (
|
||||||
|
<div
|
||||||
|
className={cn(
|
||||||
|
"flex size-6 items-center justify-center rounded text-severity_detection",
|
||||||
|
severityToggle == "detection"
|
||||||
|
? "font-semibold"
|
||||||
|
: "font-medium",
|
||||||
|
)}
|
||||||
|
>
|
||||||
|
{reviewCounts.detection > -1 ? (
|
||||||
|
reviewCounts.detection
|
||||||
|
) : (
|
||||||
|
<ActivityIndicator className="size-4" />
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</ToggleGroupItem>
|
</ToggleGroupItem>
|
||||||
<ToggleGroupItem
|
<ToggleGroupItem
|
||||||
className={`rounded-lg px-3 py-4 ${
|
className={cn(
|
||||||
severityToggle == "significant_motion"
|
"rounded-lg px-3 py-4",
|
||||||
? ""
|
severityToggle != "significant_motion" && "text-muted-foreground",
|
||||||
: "text-muted-foreground"
|
)}
|
||||||
}`}
|
|
||||||
value="significant_motion"
|
value="significant_motion"
|
||||||
aria-label="Select motion"
|
aria-label="Select motion"
|
||||||
>
|
>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user