dashboard: flatten the agent list, drop dead topology-tree machinery (#4638)
The backend dropped the agent hierarchy's parent field, so every container is a root and buildAgentTree/treePrefixDom could only ever produce a single-level flat list — the .tree-prefix CSS lane rules already matched nothing. Replaced with sortedContainerRows, a plain alphabetical sort, and dropped the now-dead .tree-prefix/.tree-lane/ data-depth CSS and the depth/isLast/ancestorIsLast fields from the row fingerprint and buildContainerLi's signature. No visible behavior change - the rendered list was already flat, just via dead machinery. Docs updated to describe the simpler implementation directly instead of narrating the removal (kept the heading name since swarm.js still points a comment at it).
This commit is contained in:
parent
c9e12ffcc0
commit
6b5c8cc51a
3 changed files with 21 additions and 170 deletions
|
|
@ -976,11 +976,14 @@ identically.)
|
|||
|
||||
### Topology tree
|
||||
|
||||
Nothing nests. `swarm.js::buildAgentTree` returns every container at
|
||||
depth 0 in alphabetical order, and the row builder emits no prefix
|
||||
column for a depth-0 row — so a container row carries no indent, no
|
||||
joint and no continuation bar, and the SW4RM list reads as a flat
|
||||
roster. The `.tree-prefix` lane rules in `dashboard.css` match nothing.
|
||||
Nothing nests. `swarm.js::sortedContainerRows` returns every container
|
||||
in alphabetical order, full stop — the SW4RM list is a flat roster, no
|
||||
indent, no joint, no continuation bar. This used to be a real forest
|
||||
walk (`buildAgentTree`, keyed on each container's `parent` field) with
|
||||
a DOM-painted `.tree-prefix` indent ladder. Once the backend dropped
|
||||
the `parent` field entirely, every container became a root and the
|
||||
tree machinery could only ever produce this same flat order — so it
|
||||
was removed rather than kept as code that draws a tree with one level.
|
||||
|
||||
## Selection bar
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue