mirror of
https://github.com/EFForg/rayhunter.git
synced 2026-04-28 00:20:00 -07:00
better controls, formatting, etc
This commit is contained in:
31
bin/web/src/lib/components/SystemStatsTable.svelte
Normal file
31
bin/web/src/lib/components/SystemStatsTable.svelte
Normal file
@@ -0,0 +1,31 @@
|
||||
<script lang="ts">
|
||||
import { type SystemStats } from "$lib/systemStats";
|
||||
let { stats }: {
|
||||
stats: SystemStats;
|
||||
} = $props();
|
||||
|
||||
</script>
|
||||
|
||||
<div>
|
||||
<p class="text-xl">System Stats</p>
|
||||
<table class="table-auto border">
|
||||
<tbody>
|
||||
<tr class="border">
|
||||
<th class="border">
|
||||
Storage
|
||||
</th>
|
||||
<td class="border">
|
||||
{stats.disk_stats.used_percent} used ({stats.disk_stats.used_size} / {stats.disk_stats.available_size})
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="border-b">
|
||||
<th class="border">
|
||||
Memory (RAM)
|
||||
</th>
|
||||
<td class="border">
|
||||
Free: {stats.memory_stats.free}, Used: {stats.memory_stats.used}
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
Reference in New Issue
Block a user