Add known/unknown device ratio next to the device count
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -186,6 +186,12 @@ body {
|
|||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.device-ratio {
|
||||||
|
color: #8b949e;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
.device-table {
|
.device-table {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
|
|||||||
@@ -65,7 +65,12 @@ export function Dashboard({ username, onLoggedOut }: { username: string; onLogge
|
|||||||
))}
|
))}
|
||||||
<section>
|
<section>
|
||||||
<h2>
|
<h2>
|
||||||
Network Devices <span className="device-count">({devices.length})</span>
|
Network Devices <span className="device-count">({devices.length})</span>{" "}
|
||||||
|
{devices.length > 0 && (
|
||||||
|
<span className="device-ratio">
|
||||||
|
{devices.filter((d) => d.known).length} known / {devices.filter((d) => !d.known).length} unknown
|
||||||
|
</span>
|
||||||
|
)}
|
||||||
</h2>
|
</h2>
|
||||||
<DeviceTable devices={devices} onDeviceChanged={poll} />
|
<DeviceTable devices={devices} onDeviceChanged={poll} />
|
||||||
</section>
|
</section>
|
||||||
|
|||||||
Reference in New Issue
Block a user