fix: CPU calc, disk card, lifespan, remove Google Fonts CDN, fix doc link

- Fix Docker container CPU % (multiply by num_cpus)
- Add missing Disk usage card to system status grid
- Replace deprecated @app.on_event with lifespan context manager
- Move `import requests` to module level
- Remove Google Fonts CDN dependency from CSS
- Update naming doc URL to real raw Gitea link

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-17 10:34:22 -04:00
co-authored by Claude Sonnet 4.6
parent 411038582a
commit 5b1eb9eec4
5 changed files with 19 additions and 8 deletions
+10
View File
@@ -63,6 +63,16 @@
</div>
</div>
<div class="stat-card">
<div class="stat-label">Disk usage</div>
<div class="stat-value" x-text="system.disk.percent + '%'"></div>
<div class="progress-bar">
<div class="progress-fill" :style="`width: ${system.disk.percent}%`"
:class="getProgressColor(system.disk.percent)"></div>
</div>
<div class="stat-detail" x-text="`${system.disk.used_gb} GB / ${system.disk.total_gb} GB`"></div>
</div>
<div class="stat-card">
<div class="stat-label">Docker containers</div>
<div class="stat-value" x-text="`${system.containers.running} / ${system.containers.total}`"></div>