JIT Spacetree节点间距问题

时间:2013-10-02 11:08:48

标签: spacing infovis thejit space-tree

我遇到了JIT Spacetree的问题,其中节点的空间相距很远,导致视图无法使用。前几个节点很好但是当您深入到树中时,子节点上的间距会增加。

我在JIT网站上使用非常类似于示例1的漂亮的vanilla配置 http://philogb.github.io/jit/static/v20/Jit/Examples/Spacetree/example1.html

这是一个截图,显示了一个片段,但问题甚至比这显示更糟糕,因为间距会随着其他节点的增加而进一步增加。

https://dl.dropboxusercontent.com/u/5454906/spacetree_issue.png

我已成功使用了一段时间,但从未遇到过这个问题。

有没有人有任何想法/想法?

由于

尼尔

这是一个生成的JSON集示例。

{
"id": "Class91240",
"name": "Cube Org - OrgID",
"data": {"nodeType": "reportObj"},
"children": [{
    "id": "001",
    "name": "Data Warehouse - Org",
    "data": {"nodeType": "dataRep"},
    "children": [
        {
            "id": "002",
            "name": "DataWarehouse Loader - Update Org Data",
            "data": {"nodeType": "interface"},
            "children": [{
                "id": "003",
                "name": "Staging Database - MasterOrg",
                "data": {"nodeType": "dataRep"},
                "children": [
                    {
                        "id": "Class90189",
                        "name": "Staging Interface - Update Master Org Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91838",
                            "name": "Staging Database - ExtractABC",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class93632",
                                "name": "Staging Interface - Rates Data",
                                "data": {"nodeType": "busLogic"},
                                "children": [{
                                    "id": "Class90125",
                                    "name": "Operational Data Stored Procedures - Data",
                                    "data": {"nodeType": "interface"},
                                    "children": [{
                                        "id": "Class90387",
                                        "name": "sim_xyz_rates",
                                        "data": {"nodeType": "feed"},
                                        "children": []
                                    }]
                                }]
                            }]
                        }]
                    },
                    {
                        "id": "Class90340",
                        "name": "Staging Interface - Update  Master tables Budget Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91889",
                            "name": "Staging Database - ExtractPQR_Fact01",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class90308",
                                "name": "Web UI Interface - Export Template Data",
                                "data": {"nodeType": "interface"},
                                "children": [{
                                    "id": "Class91942",
                                    "name": "HTC Staging Database - DEF_Template",
                                    "data": {"nodeType": "dataRep"},
                                    "children": []
                                }]
                            }]
                        }]
                    },
                    {
                        "id": "Class90342",
                        "name": "Staging Interface - Update  Master tables Forecast Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91889",
                            "name": "Staging Database - ExtractPQR_Fact01",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class90308",
                                "name": "Web UI Interface - Export Template Data",
                                "data": {"nodeType": "interface"},
                                "children": [{
                                    "id": "Class91942",
                                    "name": "HTC Staging Database - DEF_Template",
                                    "data": {"nodeType": "dataRep"},
                                    "children": []
                                }]
                            }]
                        }]
                    }
                ]
            }]
        },
        {
            "id": "Class90324",
            "name": "DataWarehouse Loader - Update  Discovery  Tables Budget Data",
            "data": {"nodeType": "interface"},
            "children": [{
                "id": "003",
                "name": "Staging Database - MasterOrg",
                "data": {"nodeType": "dataRep"},
                "children": [
                    {
                        "id": "Class90189",
                        "name": "Staging Interface - Update Master Org Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91838",
                            "name": "Staging Database - ExtractABC",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class93632",
                                "name": "Staging Interface - Rates Data",
                                "data": {"nodeType": "busLogic"},
                                "children": [{
                                    "id": "Class90125",
                                    "name": "Operational Data Stored Procedures - Data",
                                    "data": {"nodeType": "interface"},
                                    "children": [{
                                        "id": "Class90387",
                                        "name": "sim_xyz_rates",
                                        "data": {"nodeType": "feed"},
                                        "children": []
                                    }]
                                }]
                            }]
                        }]
                    },
                    {
                        "id": "Class90340",
                        "name": "Staging Interface - Update  Master tables Budget Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91889",
                            "name": "Staging Database - ExtractPQR_Fact01",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class90308",
                                "name": "Web UI Interface - Export Template Data",
                                "data": {"nodeType": "interface"},
                                "children": [{
                                    "id": "Class91942",
                                    "name": "HTC Staging Database - DEF_Template",
                                    "data": {"nodeType": "dataRep"},
                                    "children": []
                                }]
                            }]
                        }]
                    },
                    {
                        "id": "Class90342",
                        "name": "Staging Interface - Update  Master tables Forecast Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91889",
                            "name": "Staging Database - ExtractPQR_Fact01",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class90308",
                                "name": "Web UI Interface - Export Template Data",
                                "data": {"nodeType": "interface"},
                                "children": [{
                                    "id": "Class91942",
                                    "name": "HTC Staging Database - DEF_Template",
                                    "data": {"nodeType": "dataRep"},
                                    "children": []
                                }]
                            }]
                        }]
                    }
                ]
            }]
        },
        {
            "id": "Class90331",
            "name": "DataWarehouse Loader - Update  Discovery Tables Forecast Data",
            "data": {"nodeType": "interface"},
            "children": [{
                "id": "003",
                "name": "Staging Database - MasterOrg",
                "data": {"nodeType": "dataRep"},
                "children": [
                    {
                        "id": "Class90189",
                        "name": "Staging Interface - Update Master Org Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91838",
                            "name": "Staging Database - ExtractABC",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class93632",
                                "name": "Staging Interface - Rates Data",
                                "data": {"nodeType": "busLogic"},
                                "children": [{
                                    "id": "Class90125",
                                    "name": "Operational Data Stored Procedures - Data",
                                    "data": {"nodeType": "interface"},
                                    "children": [{
                                        "id": "Class90387",
                                        "name": "sim_xyz_rates",
                                        "data": {"nodeType": "feed"},
                                        "children": []
                                    }]
                                }]
                            }]
                        }]
                    },
                    {
                        "id": "Class90340",
                        "name": "Staging Interface - Update  Master tables Budget Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91889",
                            "name": "Staging Database - ExtractPQR_Fact01",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class90308",
                                "name": "Web UI Interface - Export Template Data",
                                "data": {"nodeType": "interface"},
                                "children": [{
                                    "id": "Class91942",
                                    "name": "HTC Staging Database - DEF_Template",
                                    "data": {"nodeType": "dataRep"},
                                    "children": []
                                }]
                            }]
                        }]
                    },
                    {
                        "id": "Class90342",
                        "name": "Staging Interface - Update  Master tables Forecast Data",
                        "data": {"nodeType": "interface"},
                        "children": [{
                            "id": "Class91889",
                            "name": "Staging Database - ExtractPQR_Fact01",
                            "data": {"nodeType": "dataRep"},
                            "children": [{
                                "id": "Class90308",
                                "name": "Web UI Interface - Export Template Data",
                                "data": {"nodeType": "interface"},
                                "children": [{
                                    "id": "Class91942",
                                    "name": "HTC Staging Database - DEF_Template",
                                    "data": {"nodeType": "dataRep"},
                                    "children": []
                                }]
                            }]
                        }]
                    }
                ]
            }]
        }
    ]
}]

}

1 个答案:

答案 0 :(得分:0)

这可能不是您的问题的原因,但您的json结构中有重复的节点。在JIT中,ID必须是唯一的SpaceTrees