(box: HierarchyBox, x: number, z: number)
| 288 | packHierarchy(root); |
| 289 | const platforms: SemanticPlatform[] = []; |
| 290 | const place = (box: HierarchyBox, x: number, z: number) => { |
| 291 | if (box.node) { box.node.position = [x, box.level * 1.6 + 0.08, z]; return; } |
| 292 | if (box.level) platforms.push({ id: `hierarchy:${box.key}`, path: box.path, |
| 293 | label: box.unknown ? 'Unknown source' : box.path, position: [x, box.level * 1.6, z], width: box.width, depth: box.depth, level: box.level }); |
| 294 | for (const child of box.children) place(child, x + child.x, z + child.z); |
| 295 | }; |
| 296 | place(root, 0, 0); |
| 297 | return platforms; |
| 298 | } |
no test coverage detected