Graph:Packet - Add ability to change packet color on a per-packet basis. #6143
Labels
Status: Triage
Needs to be verified, categorized, etc
Type: Enhancement
New feature or request
Type: New Diagram
Proposal
No real bug. Want ability to edit color.
Current example shown works great. Love the feature.
The ability that would make this FIRE is to be able to make each section its own color.
For example,
See the first three packet blocks below. The intent would be to color those green, blue and orange.
If easier could simply make it a hex color as well, so something like ":::#FFD700".
Also the syntax doesnt hugely matter either. Could be "color-id:" or triple colon":::" or whatever.
title: "TCP Packet"
packet-beta
0-15: "Source Port":::green
16-31: "Destination Port":::blue
32-63: "Sequence Number":::orange
64-95: "Acknowledgment Number"
96-99: "Data Offset"
100-105: "Reserved"
106: "URG"
107: "ACK"
108: "PSH"
109: "RST"
110: "SYN"
111: "FIN"
112-127: "Window"
128-143: "Checksum"
144-159: "Urgent Pointer"
160-191: "(Options and Padding)"
192-255: "Data (variable length)"
Use Cases
Network engineers and anyone that does detailed analysis of packets. Often these are drawn and redrawn based on syntax updates, or custom fields and having COLORs in the diagram is a huge benefit.
Screenshots
Example done by editing the XML.
Course that is the not ideal scenario.
Syntax
Same syntax, just add a color feature.
Could be a triple colon ":::" or even "color-id:" or something like that to append existing syntax.
Final syntax would ideally look something like...
title: "TCP Packet"
packet-beta
0-15: "Source Port":::green
16-31: "Destination Port":::blue
OR
32-63: "Sequence Number" color-id:#FFD700
Implementation
This is a proposal which I'd love to see built into mermaid by the wonderful community.
The text was updated successfully, but these errors were encountered: