mirror of
https://github.com/Kpa-clawbot/meshcore-analyzer.git
synced 2026-08-14 12:09:52 +00:00
The buildBreakdown function was never ported when the Go backend replaced
Node.js. The server has returned breakdown:{} since the Go migration,
causing createColoredHexDump() and buildHexLegend() to render everything
as monochrome.
- Add BuildBreakdown() to decoder.go: computes labeled byte ranges for
Header, Transport Codes, Path Length, Path, and Payload sections.
ADVERT payloads are further broken down into PubKey, Timestamp,
Signature, Flags, Latitude, Longitude, and Name sub-ranges.
- Wire into handlePacketDetail in routes.go (was struct{}{}).
- Update PacketDetailResponse.Breakdown from interface{} to *Breakdown.
- Add per-section CSS classes (section-header/transport/path/payload) to
sectionRow() in packets.js so the field breakdown table also carries
distinct background tints per section.
- Add matching CSS rules in style.css.
- 8 new tests covering all section types, transport routes, zero-hop
packets, and ADVERT sub-fields (location, name).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>