MeshDD-Bot/static/packets.html
ppfeiffer 6187bb4419 feat: v0.6.10 - Paket-Log-Seite und größeres Node-Modal
- Neue öffentliche Seite /packets: Echtzeit-Tabelle aller empfangenen
  Meshtastic-Pakete via WebSocket mit Typ-Filter, Pause und Clear
- DB: packets-Tabelle + insert_packet / get_recent_packets
- bot.py: alle Pakete loggen + WS-Broadcast (public)
- webserver.py: /packets Route + /api/packets + initial_packets im WS
- Sidebar: Eintrag 'Pakete' (öffentlich)
- Node-Modal: modal-xl + scrollable, Kartenhöhe 250→300px

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-18 17:17:14 +01:00

85 lines
4.2 KiB
HTML

<!DOCTYPE html>
<html lang="de" data-bs-theme="dark">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>MeshDD-Bot Paket-Log</title>
<link href="https://cdn.jsdelivr.net/npm/@tabler/core@1.4.0/dist/css/tabler.min.css" rel="stylesheet">
<link href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css" rel="stylesheet">
<link rel="stylesheet" href="/static/css/style.css">
</head>
<body class="antialiased">
<!-- Top Navbar -->
<nav class="top-navbar d-flex align-items-center px-3">
<button class="btn btn-link text-body p-0 me-2 d-lg-none" id="sidebarToggle">
<i class="bi bi-list fs-5"></i>
</button>
<span class="fw-bold me-auto">
<i class="bi bi-broadcast-pin text-info me-1"></i>MeshDD-Bot
</span>
<div class="d-flex align-items-center gap-2">
<span class="d-flex align-items-center gap-1">
<span class="status-dot" id="statusDot"></span>
<small class="text-body-secondary" id="statusText">Verbinde...</small>
</span>
<span id="userMenu" class="d-none">
<small class="text-body-secondary me-1"><i class="bi bi-person-fill me-1"></i><span id="userName"></span></small>
<a href="/auth/logout" class="btn btn-sm btn-outline-secondary py-0 px-1" title="Abmelden">
<i class="bi bi-box-arrow-right" style="font-size:.75rem"></i>
</a>
</span>
<a href="/login" id="loginBtn" class="btn btn-sm btn-outline-info py-0 px-1 d-none">
<i class="bi bi-person" style="font-size:.75rem"></i> Login
</a>
<button class="btn btn-sm btn-outline-secondary py-0 px-1" id="themeToggle" title="Theme wechseln">
<i class="bi bi-sun-fill" id="themeIcon" style="font-size:.75rem"></i>
</button>
</div>
</nav>
<aside class="sidebar" id="sidebar"></aside>
<div class="sidebar-backdrop" id="sidebarBackdrop"></div>
<main class="content-wrapper">
<div class="card card-outline">
<div class="card-header py-2 d-flex align-items-center gap-2 flex-wrap">
<i class="bi bi-reception-4 me-1"></i>
<span class="fw-semibold">Paket-Log</span>
<small class="text-body-secondary" id="pktCount"></small>
<div class="ms-auto d-flex gap-1 flex-wrap" id="pktFilterBar"></div>
<button class="btn btn-sm btn-outline-secondary py-0 px-2" id="pktPauseBtn" title="Pause">
<i class="bi bi-pause-fill" style="font-size:.75rem"></i>
</button>
<button class="btn btn-sm btn-outline-danger py-0 px-2" id="pktClearBtn" title="Löschen">
<i class="bi bi-trash" style="font-size:.75rem"></i>
</button>
</div>
<div class="card-body p-0">
<div class="table-responsive" style="max-height:calc(100vh - 130px);overflow-y:auto" id="pktTableWrapper">
<table class="table table-sm table-hover mb-0" id="pktTable">
<thead class="sticky-top">
<tr>
<th style="width:80px">Zeit</th>
<th style="width:90px">Von</th>
<th style="width:90px">An</th>
<th style="width:140px">Typ</th>
<th style="width:45px">Ch</th>
<th style="width:55px">SNR</th>
<th style="width:60px">RSSI</th>
<th style="width:45px">Hops</th>
<th>Info</th>
</tr>
</thead>
<tbody id="pktBody"></tbody>
</table>
</div>
</div>
</div>
</main>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
<script src="/static/js/app.js"></script>
<script src="/static/js/packets.js"></script>
</body>
</html>