Correction CSS Swup, types WS et création fichier de suivi

- Extraction de tous les styles inline en css/pages.css (chargé globalement)
  pour corriger le CSS cassé lors des navigations Swup
- Correction types WebSocket : proxmox_resources → resources_update
  et msg.data → msg.payload (format réel du hub Go)
- Ajout d'un fetch HTTP immédiat dans dashboardPage/proxmoxPage
  pour éviter l'attente du premier tick (10s) du polling WS
- Correction msg.payload pour les updates (update_output/done/error)
- Ajout class terminal-wrapper sur .main-layout de terminal.html
  pour le fullscreen height sans affecter les autres pages
- Création SUIVI.md : état d'implémentation vs instruction.md

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
enzo 2026-03-21 17:49:33 +01:00
parent a4b5b06f04
commit 9739dbaee8
11 changed files with 640 additions and 258 deletions

View file

@ -8,6 +8,7 @@
<link rel="stylesheet" href="/css/neu.css" />
<link rel="stylesheet" href="/css/dark.css" />
<link rel="stylesheet" href="/css/light.css" />
<link rel="stylesheet" href="/css/pages.css" />
<script src="/js/vendors/htmx.min.js"></script>
<script src="/js/vendors/swup.iife.js"></script>
<script src="/js/app.js"></script>
@ -125,35 +126,5 @@
</main>
</div>
<style>
[x-cloak]{display:none!important}
.main-layout{display:flex;flex-direction:column;flex:1;margin-left:var(--sidebar-width,240px);transition:margin-left .2s}
.sidebar.collapsed~.main-layout{margin-left:var(--sidebar-width-collapsed,64px)}
.stats-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:1rem;margin-bottom:1.5rem}
.stat-card{padding:1.25rem;text-align:center}
.stat-icon{font-size:1.5rem;margin-bottom:.5rem;color:var(--neu-primary)}
.stat-value{font-size:2rem;font-weight:700}
.stat-label{font-size:.8rem;color:var(--neu-text-muted)}
.ws-status{padding:.5rem 1rem;border-radius:.5rem;font-size:.8rem;margin-bottom:1rem;background:var(--neu-surface)}
.ws-status.ok{color:var(--neu-success)}
.ws-status.disconnected,.ws-status.error{color:var(--neu-warning)}
.resource-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:1rem}
.resource-card{padding:1rem}
.resource-header{display:flex;align-items:center;gap:.5rem;margin-bottom:.75rem}
.resource-name{font-weight:600;flex:1}
.resource-id{font-size:.75rem;color:var(--neu-text-muted)}
.resource-badge{font-size:.7rem;padding:.2rem .5rem;border-radius:.25rem;text-transform:uppercase}
.resource-badge.running{background:rgba(34,197,94,.15);color:var(--neu-success)}
.resource-badge.stopped{background:rgba(239,68,68,.1);color:var(--neu-danger)}
.metric{display:flex;align-items:center;gap:.5rem;margin-bottom:.4rem}
.metric-label{font-size:.7rem;color:var(--neu-text-muted);min-width:30px}
.metric-bar{flex:1;height:6px;border-radius:3px;background:var(--neu-surface);overflow:hidden}
.metric-fill{height:100%;border-radius:3px;background:var(--neu-primary);transition:width .5s}
.metric-val{font-size:.7rem;min-width:36px;text-align:right}
.section{margin-bottom:2rem}
.section-title{font-size:1rem;font-weight:600;margin-bottom:.75rem;color:var(--neu-text-muted);text-transform:uppercase;letter-spacing:.05em}
.empty-state{color:var(--neu-text-muted);font-size:.875rem}
.loading{color:var(--neu-text-muted);font-size:.875rem}
</style>
</body>
</html>